UNPKG

zettapi_client

Version:

Client side CRUD operations in angular to use with zettapi_server rest api to get started quickly in any CMS project

18 lines (15 loc) 427 B
app.directive('zlNewsletter', function (zapiPath, blockUI, inform, $entity) { return { restrict: 'E', scope: true, replace: false, templateUrl: zapiPath + '/directives/newsletter/newsletter.html', controller: function ($scope, $newsletter) { $scope.saveEmail = function (item) { $newsletter.subscribe(item, function () { $scope.newsItem = {}; }); }; } }; });