Created
October 14, 2013 13:13
-
-
Save swallentin/6975380 to your computer and use it in GitHub Desktop.
updating broadcast.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| (function () { | |
| 'use strict'; | |
| angular.module('admincms.broadcast') | |
| .factory('broadcastEnrichmentService', function ($http, $q, $log, $resource, broadcastSettings, settings) { | |
| var serviceEndPoint = [settings.adminApiBaseUrl, broadcastSettings.resourceEndPoints.broadcast, broadcastSettings.resourceEndPoints.enrichment].join(""), | |
| paramsDefault = { | |
| broadcastId: '@id', | |
| enrichmentId: 'like-tv-se', | |
| type: '@type' | |
| }, | |
| actions = { | |
| update: { | |
| method: "PUT" | |
| }, | |
| updateTwitter: { | |
| method: "PUT", | |
| params: { | |
| type: broadcastSettings.resourceEndPoints.twitter | |
| } | |
| }, | |
| updateFacebook: { | |
| method: "PUT", | |
| params: { | |
| type: broadcastSettings.resourceEndPoints.facebook | |
| } | |
| }, | |
| updateGoogle: { | |
| method: "PUT", | |
| params: { | |
| type: broadcastSettings.resourceEndPoints.google | |
| } | |
| }, | |
| updateImages: { | |
| method: "PUT", | |
| params: { | |
| type: broadcastSettings.resourceEndPoints.images | |
| } | |
| }, | |
| updateRoles: { | |
| method: "PUT", | |
| params: { | |
| type: broadcastSettings.resourceEndPoints.roles | |
| } | |
| } | |
| }; | |
| return $resource(serviceEndPoint, paramsDefault, actions); | |
| }); | |
| }()); | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment