(function (app) { app.factory('myService', ['$http', 'config', "util", function ($http, config, util) { return { logout:function(){ return $http({ url:config.server + "api/auth/logout", method:"get" }) }, setPassword: function (password) { return $http({ url: config.server + '/api/auth/password', method: "post", data: { password: password } }) }, testcharge:function(number,type){ return $http({ url:config.server + "api/my/recharge?coin="+number, method:"post" }) }, charge:function(number,type){ return $http({ url:config.server + "api/pay/charge", method:"post", data: { number:number,goods:1,type:type} }) }, orderStatus:function(number,type){ return $http({ url:config.server + "api/pay/order_status", method:"post", data: { number:number,goods:1,type:type} }) }, setting:function(){ return $http({ url:config.server + "api/my/setting", method:"get" }) }, systemInfo:function(){ return $http({ url:config.server + "api/my/dream_info", method:"get" }) }, replyMy:function(){ return $http({ url:config.server + "api/my/sup_info", method:"get" }) }, collect:function(){ return $http({ url:config.server + "api/my/collection", method:"get" }) }, myDream:function(){ return $http({ url:config.server + "api/my/dream", method:"get" }) }, myReplay:function(data){ return $http({ url: config.server + '/api/my/my_reply', method: "post", data: data }) }, sendLetter:function(data){ return $http({ url: config.server + '/api/my/letter/store', method: "post", data: data }) }, letterDetail:function(id){ return $http({ url: config.server + 'api/my/letter/show?id=' + id, method: "get" }) }, myMes:function(){ return $http({ url:config.server + "api/my/persona", method:"get" }) }, myInfo:function(){ return $http({ url:config.server + "api/my/show", method:"get" }) }, replayMes:function(data){ return $http({ url:config.server + "api/interaction/comment", method:"post", data:data }) }, toprofile:function(){ return $http({ url:config.server + "api/my/persona", method:"get" }) }, myMaterial:function(){ return $http({ url:config.server + "api/my/update", method:"get" }) }, saveMaterial:function(data){ return $http({ url:config.server + "api/my/update", method:"post", data:data }) }, attention:function(){ return $http({ url:config.server + "api/my/care", method:"get" }) }, careMe:function(){ return $http({ url:config.server + "api/my/careme", method:"get" }) }, toMyUserDetail:function(id){ return $http({ url:config.server + "api/user/show?user_id=" + id , method:"get" }) }, addAccount:function(data){ return $http({ url:config.server + "api/my/bank/create", method:"post", data:data }) }, showAccount:function(){ return $http({ url:config.server + "api/my/bank/list", method:"get" }) }, destroyAccount:function(id){ return $http({ url:config.server + "api/my/bank/delete?id=" + id , method:"get" }) }, withdraw:function(data){ return $http({ url:config.server + "api/my/cash", method:"post", data:data }) }, contact:function(data){ return $http({ url:config.server + "api/my/suggest", method:"post", data:data }) }, payExplain:function(){ return $http({ url:config.server + "api/my/account_log", method:"get" }) }, addQrcode:function(data){ return $http({ url:config.server + "api/my/bank/qrcode", method:"post", data:data }) }, aboutMiao:function(){ return $http({ url:config.server + "api/my/miao", method:"get" }) }, messageInfo:function(){ return $http({ url:config.server + "api/my/info", method:"get" }) }, notRead:function(){ return $http({ url:config.server + "api/my/read", method:"get" }) }, letter:function(){ return $http({ url:config.server + "api/my/system_info", method:"get" }) }, sure_meet:function(dream_id,value){ return $http({ url:config.server + "api/my/sure_meet?dream_id=" + dream_id + '&value=' + value, method:"get" }) }, sure_meet2:function(to_user_id,value){ return $http({ url:config.server + "api/my/sure_meet2?to_user_id=" + to_user_id + '&value=' + value, method:"get" }) } }; }]); })(angular.module('app.services'));