Newsletters multi-listing

This commit is contained in:
Jonathan Labreuille
2016-06-01 12:36:28 +02:00
parent dc6c973574
commit 3b97a26a8a
5 changed files with 120 additions and 28 deletions

View File

@@ -427,9 +427,13 @@ define(
this.clearSelection();
const action = (this.props.action !== undefined)
? this.props.action
: 'listing';
MailPoet.Ajax.post({
endpoint: this.props.endpoint,
action: 'listing',
action: action,
data: {
offset: (this.state.page - 1) * this.state.limit,
limit: this.state.limit,

View File

@@ -295,6 +295,31 @@ define(
limit={ mailpoet_listing_per_page }
params={ this.props.params }
endpoint="newsletters"
action="listingStandard"
onRenderItem={this.renderItem}
columns={columns}
bulk_actions={ bulk_actions }
item_actions={ item_actions }
messages={ messages }
auto_refresh={ true } />
<Listing
limit={ mailpoet_listing_per_page }
params={ this.props.params }
endpoint="newsletters"
action="listingWelcome"
onRenderItem={this.renderItem}
columns={columns}
bulk_actions={ bulk_actions }
item_actions={ item_actions }
messages={ messages }
auto_refresh={ true } />
<Listing
limit={ mailpoet_listing_per_page }
params={ this.props.params }
endpoint="newsletters"
action="listingNotification"
onRenderItem={this.renderItem}
columns={columns}
bulk_actions={ bulk_actions }