head_data.vue 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990
  1. <template>
  2. <view>
  3. <view class="head_data row-justify-sb center m-lr30 m-t30">
  4. <view class="data_item page-box-bg-fff column-c r-30 p-tb25">
  5. <image class="wh-80" src="/static/img/task/task-all.png" mode=""></image>
  6. <view class="row-c p-tb20">
  7. <text class="size-40 sys-weight-600 text-color-E83">{{(moneyData.out_money).toFixed(2)}}</text>
  8. <text class="size-24 text-color-666 m-l10">万</text>
  9. </view>
  10. <text class="num r-10 sys-from-background-color size-24 text-color-666">放款{{moneyData.out_num}}笔</text>
  11. </view>
  12. <view class="data_item page-box-bg-fff column-c r-30 p-tb25">
  13. <image class="wh-80" src="/static/img/task/task-all.png" mode=""></image>
  14. <view class="row-c p-tb20">
  15. <text class="size-40 text-color-108 sys-weight-600">{{(moneyData.put_money).toFixed(2)}}</text>
  16. <text class="size-24 text-color-666 m-l10">万</text>
  17. </view>
  18. <text class="num r-10 sys-from-background-color size-24 text-color-666">回款{{moneyData.put_num}}笔</text>
  19. </view>
  20. </view>
  21. </view>
  22. </template>
  23. <script>
  24. import {getSysCashier} from "@/api/statistics";
  25. export default {
  26. name: 'head_filter',
  27. props:{
  28. 'dateTypeObj':{
  29. default:()=>{
  30. return {
  31. dateType:4,
  32. selectDate:'2023-02-25',
  33. money_type:1,
  34. censusUserType:0,
  35. product_id:5,
  36. }
  37. }
  38. }
  39. },
  40. watch:{
  41. 'dateTypeObj':function () {
  42. this.initData()
  43. }
  44. },
  45. mounted() {
  46. this.initData()
  47. },
  48. data() {
  49. return {
  50. moneyData:{
  51. out_money: 0,
  52. out_num: 0,
  53. put_money: 0,
  54. put_num: 0,
  55. }
  56. };
  57. },
  58. methods: {
  59. initData(){
  60. if(this.dateTypeObj.censusUserType>0){
  61. this.getSysCashier()
  62. }
  63. },
  64. getSysCashier(){
  65. getSysCashier(this.dateTypeObj).then((res)=>{
  66. if(res.code===1){
  67. this.moneyData=res.data
  68. }
  69. })
  70. }
  71. },
  72. }
  73. </script>
  74. <style lang="scss" scoped>
  75. .head_data {
  76. text-align: center;
  77. .data_item {
  78. width: 330rpx;
  79. .num{
  80. width: 140rpx;
  81. height: 50rpx;
  82. line-height: 50rpx;
  83. }
  84. }
  85. }
  86. </style>