(function (app) { app.factory('myService', ['$http', 'config', "util", function ($http, config, util) { return { setPassword: function (password) { return $http({ url: config.server + '/api/auth/password', method: "post", data: { password: password } }) }, add:function (data){ return $http({ url:config.server + 'api/my/add_dream', method:"post", data:data }) }, reset:function(data){ return $http({ url:config.server + "api/auth/avatar", method:"post", data:data }) }, recharge:function(){ return $http({ url:config.server + "api/my/recharge", method:"get" }) }, setting:function(){ return $http({ url:config.server + "api/my/setting", method:"get" }) }, systemInfo:function(){ return $http({ url:config.server + "api/my/system_info", method:"get" }) }, replyMy:function(){ return $http({ url:config.server + "api/my/reply_my", method:"get" }) }, }; }]); })(angular.module('app.services'));