locker-factory
Version:
Content Locker UI Builder
24 lines (19 loc) • 501 B
JavaScript
var Api = require( './Api' );
/*
* Actions dispatcher
*/
var Actions = {
/*
* Call the getCampaigns api method to retrieve campaigns that would show up in the locker.
* @param params - An object of key/value pairs that will become the request query parameters.
* @returns undefined
*/
getCampaigns: function( params, useTargetingEndpoint ) {
if( useTargetingEndpoint ) {
Api.getTargetedCampaigns( params );
} else {
Api.getCampaigns( params );
}
}
};
module.exports = Actions;