{"size": 901, "ext": "js", "max_stars_repo_path": "src/components/administrator/places/place/images-tagging/images-tagging/images-tagging.service.js", "max_stars_repo_name": "wenzdey/dollar-street-cms-pages", "max_stars_repo_stars_event_min_datetime": "2018-12-29T11:07:44.000Z", "max_stars_repo_stars_event_max_datetime": "2018-12-29T11:07:44.000Z", "max_issues_repo_path": "src/components/administrator/places/place/images-tagging/images-tagging/images-tagging.service.js", "max_issues_repo_name": "wenzdey/dollar-street-cms-pages", "max_issues_repo_issues_event_min_datetime": "2017-08-15T10:31:26.000Z", "max_issues_repo_issues_event_max_datetime": "2020-09-04T09:57:47.000Z", "max_forks_repo_path": "src/components/administrator/places/place/images-tagging/images-tagging/images-tagging.service.js", "max_forks_repo_name": "wenzdey/dollar-street-cms-pages", "max_forks_repo_forks_event_min_datetime": "2018-10-15T08:04:07.000Z", "max_forks_repo_forks_event_max_datetime": "2019-10-06T22:52:22.000Z"}
{"max_stars_count": 1, "max_issues_count": 3, "max_forks_count": 2, "avg_line_length": 34.6538461538, "max_line_length": 95, "alphanum_fraction": 0.6603773585}
angular.module('job')
  .factory('ImagesTaggingService', ['$resource', 'cmsConfig', function ($resource, cmsConfig) {
    var ImagesTaggingServiceResource = $resource('', {}, {
      // serverUrl
      getImages: {method: 'GET', url: cmsConfig.serverApi + '/images-tagging/:placeId'},
      updateImages: {method: 'POST', url: cmsConfig.serverApi + '/images-tagging'}
    });

    function ImagesTaggingService() {
    }

    ImagesTaggingService.prototype.getImages = function (query, cb) {
      return ImagesTaggingServiceResource.getImages({placeId: query.placeId}, function (res) {
        return cb(res.error, res.data);
      });
    };

    ImagesTaggingService.prototype.updateImages = function (query, cb) {
      return ImagesTaggingServiceResource.updateImages(query, function (res) {
        return cb(res.error, res.data);
      });
    };

    return new ImagesTaggingService();
  }]);
