psMoneyHomeCtrl.js 1.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. angular.module('push')
  2. .controller('psMoneyHomeCtrl', function ($scope, AccountService, UtilService, UserService) {
  3. if($scope.app){
  4. $scope.setStatusBar(0);
  5. }
  6. $scope.defaultLan = UserService.defaultLan;
  7. // 我的普适积分
  8. $scope.totalcurrency = 0;
  9. if(UtilService.isDefined(UserService.user.pushIntegralModel.sysUsersPushvalue)){
  10. $scope.totalcurrency = UserService.user.pushIntegralModel.sysUsersPushvalue.pushintegral;
  11. }
  12. //常见问题展开/关闭
  13. $(".question_body").click(function () {
  14. var index = $(this).index() - 1;
  15. $(".question_body span:nth-child(1) em").eq(index).toggleClass("questionToggle");
  16. $(".question_body p").eq(index).toggle();
  17. });
  18. //普适币规则
  19. $scope.goPsMoneyEarnRule = function () {
  20. $scope.go("psMoneyEarnRule");
  21. };
  22. //充值
  23. $scope.goReChange = function () {
  24. $scope.go("reChange");
  25. };
  26. //收支明细
  27. $scope.goRevenExpandDetails = function () {
  28. $scope.go("RevenExpandDetails");
  29. };
  30. //普适币兑换服务
  31. $scope.goExchange = function () {
  32. $scope.go("psMoneyConsume", {totalcurrency: $scope.currency.totalcurrency});
  33. };
  34. /*var getPushCurrencyInfo = function () {
  35. $scope.showLoadingToast();
  36. AccountService.getMemberInfo().then(function (response) {
  37. $scope.currency = response;
  38. $scope.viplevel = UserService.viplevel = $scope.currency.memberid;
  39. console.log($scope.currency);
  40. $scope.hideLoadingToast();
  41. }, function () {
  42. $scope.hideLoadingToast();
  43. UtilService.showMess("网络不给力,请重试");
  44. });
  45. };
  46. getPushCurrencyInfo();*/
  47. });