BillPending.vue 24 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994
  1. <template>
  2. <view class="page">
  3. <u-tabs :list="tabs" @click="sectionChange" style="background-color: #fff;" :current=current
  4. :itemStyle="{'width':'250rpx','padding':'24rpx'}" lineHeight="2px" lineWidth="30px"></u-tabs>
  5. <!-- 账单明细 -->
  6. <view class="contain" v-show="cdshow==0">
  7. <view class="topbilledit">
  8. <view class="changetime1">
  9. <picker mode="date" :value="myday" fields="month" @change="dateChange">
  10. <view class="selestDate">{{myday}}</view>
  11. </picker>
  12. </view>
  13. <view class="changetime2">
  14. <u-icon name="arrow-down-fill" color="#999" size="20"></u-icon>
  15. </view>
  16. </view>
  17. <view style="padding:16rpx 0 16rpx 32rpx">
  18. 共有 <span style="color: red">{{totalnumber}}</span>条记录
  19. </view>
  20. <view class="u-listdata">
  21. <u-list @scrolltolower="scrolltolower" :pagingEnabled='true'
  22. style="height:400px;flex:1;padding-bottom: 49px;">
  23. <u-list-item v-for="(item, index) in indexList1" :key="index">
  24. <view class="paisong">
  25. <u-icon name="arrow-up" @click="item.showMore=false" class="iconBtn" size="20px"
  26. v-if="item.showMore" color="#999"></u-icon>
  27. <u-icon name="arrow-down" @click="item.showMore=true" class="iconBtn" size="22px"
  28. color="#999" v-else></u-icon>
  29. <checkbox :checked="item.check" class="check" @click="checkItem(item)" />
  30. <view class="title">
  31. 物业费: <span>¥{{item.amount}}</span>
  32. <view class="status s1" v-if='item.status==1'>
  33. 已支付
  34. </view>
  35. <view class="status s2" v-if='item.status==2'>
  36. 待支付
  37. </view>
  38. <view class="status s3" v-if='item.status==3'>
  39. 支付失败
  40. </view>
  41. </view>
  42. <template v-if="item.showMore">
  43. <view class="subtit" style="margin-top: 16rpx;">
  44. 管理费:{{item.billLists[0].amount}}
  45. </view>
  46. <view class="subtit">
  47. 中央空调使用费:{{item.billLists[1].amount}}
  48. </view>
  49. <view class="subtit">
  50. 电梯费:{{item.billLists[2].amount}}
  51. </view>
  52. </template>
  53. </view>
  54. </u-list-item>
  55. </u-list>
  56. </view>
  57. <view class="zhifu">
  58. <view class="zhifuright" @click="Immediatepayment">
  59. <view class="heji">
  60. 合计:<span>¥ {{heji}}</span>
  61. </view>
  62. <view class="likezhifu">
  63. <u-button type="primary" size='mini' shape='circle' text="立即支付"></u-button>
  64. </view>
  65. </view>
  66. </view>
  67. </view>
  68. <!-- 我的订单 -->
  69. <view class="contain" v-show="cdshow==1">
  70. <view class="topbilledit" @click="orderTypechange">
  71. <view class="changetime1">
  72. {{myorderType}}
  73. </view>
  74. <view class="changetime2">
  75. <u-icon name="arrow-down-fill" color="#999" size="20"></u-icon>
  76. </view>
  77. </view>
  78. <view class="u-listdata">
  79. <view style="padding:16rpx 0 16rpx 32rpx">
  80. 共有 <span style="color: red">{{orderTotalnumber}}</span>条记录
  81. </view>
  82. <u-list @scrolltolower="orderScrolltolower" :pagingEnabled='true' style="height:400px;flex:1;">
  83. <u-list-item v-for="(item, index) in orderList" :key="index">
  84. <view class="paisong2" @click="orderDetail(item)">
  85. <view class="status" v-if='item.status==0' style="background-color: #FF9C27;">
  86. 待支付
  87. </view>
  88. <view class="status" v-if='item.status==1'>
  89. 已支付
  90. </view>
  91. <view class="status" v-if="item.status=='-1'" style="background-color: #9DA0AC;">
  92. 已关闭
  93. </view>
  94. <view class="subtit" style="margin-top: 20rpx;">
  95. 支付金额: <span>¥{{item.payAmount}}</span>
  96. </view>
  97. <view class="subtit" v-if="status=='1'">
  98. 支付时间: {{item.payAt}}
  99. </view>
  100. <view class="subtit">
  101. 下单时间: {{item.createDate}}
  102. </view>
  103. <view class="subtit">
  104. 交易类型: 微信支付
  105. </view>
  106. <view class="operation" v-if="item.status==0">
  107. <text @click.stop="cancle(item.id,index)">取消订单</text>
  108. <text class="p2">继续付款</text>
  109. </view>
  110. </view>
  111. </u-list-item>
  112. </u-list>
  113. </view>
  114. </view>
  115. <!--缴费记录 -->
  116. <view class="contain" v-show="cdshow==2">
  117. <!-- 列表 -->
  118. <view class="u-listdata">
  119. <view class="topbilledit" @click="typechange">
  120. <view class="changetime1">
  121. {{mytype}}
  122. </view>
  123. <view class="changetime2">
  124. <u-icon name="arrow-down-fill" color="#999" size="20"></u-icon>
  125. </view>
  126. </view>
  127. <view style="padding:16rpx 0 0 30rpx">
  128. 共有 <span style="color: red">{{totalnumber}}</span>条记录
  129. </view>
  130. <u-list @scrolltolower="scrolltolower2" :pagingEnabled='true'
  131. style="height:400px;flex:1;padding-bottom: 49px;">
  132. <u-list-item v-for="(item, index) in indexList2" :key="index">
  133. <view class="paisong2">
  134. <view class="status" v-if="item.type=='Subsidy'">
  135. 补助
  136. </view>
  137. <view class="status s2" v-if="item.type=='PreStorage'">
  138. 预存
  139. </view>
  140. <view class="status s3" v-if="item.type=='Refund'">
  141. 退费
  142. </view>
  143. <view class="status s4" v-if="item.type=='Water'">
  144. 水费
  145. </view>
  146. <view class="status s4" v-if="item.type=='Elec'">
  147. 电费
  148. </view>
  149. <view class="status s4" v-if="item.type=='PropertyFee'">
  150. 物业费
  151. </view>
  152. <div class="title">{{item.tenantInfo.name}}</div>
  153. <view class="subtit">
  154. 扣缴金额:{{item.amount}}
  155. </view>
  156. <view class="subtit">
  157. 账户金额:{{item.surplus}}
  158. </view>
  159. <view class="subtit">
  160. 租户电话:{{item.tenantInfo.tel}}
  161. </view>
  162. <view class="subtit">
  163. 操作人:{{item.createName}}
  164. </view>
  165. <view class="subtit">
  166. 扣缴时间:{{item.createDate}}
  167. </view>
  168. </view>
  169. </u-list-item>
  170. </u-list>
  171. <view class="Predeposit" v-show="Predepositshow">
  172. <span @click="Predeposit">预存</span>
  173. </view>
  174. </view>
  175. </view>
  176. <u-picker :show="showtype" itemHeight="76" :columns="columnstype" keyName="dictLabel" @confirm="confirmtype"
  177. @cancel='canceltype'></u-picker>
  178. <!-- <text>请选择支付方式</text> -->
  179. <u-popup :show="showpay" @close="closepay" mode="bottom" :round="10" :closeable=true :closeOnClickOverlay=true>
  180. <view class="paytall">
  181. <view class="hejitop">
  182. ¥ {{heji}}
  183. </view>
  184. <view class="zhifufs">
  185. <u-radio-group v-model="zhifufangshi" placement="column" iconPlacement="right">
  186. <u-radio :customStyle="{marginBottom: '8px'}" v-for="(item, index) in radiolist1" :key="index"
  187. :label="item.name" :name="item.id">
  188. </u-radio>
  189. </u-radio-group>
  190. </view>
  191. <view style="margin: 0 30rpx;">
  192. <u-button type="primary" text="确认支付" @click="Confirmationpayment"></u-button>
  193. </view>
  194. </view>
  195. </u-popup>
  196. <!-- 充值提示框 -->
  197. <u-modal :show="showjiaofei" title="提示" content='当前账户余额不足,请问是否充值?' @confirm="jiaofeiconfirm"
  198. @cancel='cancleJiaofei()' :showCancelButton=true>
  199. </u-modal>
  200. <!-- 支付框 -->
  201. <view class="canys" v-if="zhifucanvas">
  202. <h4>请用微信扫码二维码</h4>
  203. <canvas class="zhifucanvas" canvas-id='canvas'></canvas>
  204. <view class="guanbi">
  205. <u-button type="primary" :plain="true" text="关闭" style="border:none" @click="guanbi"></u-button>
  206. </view>
  207. </view>
  208. <!-- 预存 -->
  209. <u-popup :show="showpayjine" @close="closepay1" mode="bottom" :round="10" :closeable=true
  210. :closeOnClickOverlay=true>
  211. <view class="paytall1" style="padding-bottom: 20rpx;">
  212. <view class="hejitop">
  213. 预存
  214. </view>
  215. <view class="zhifufs">
  216. <u--form labelWidth="30" labelPosition="left" :model="model1" :rules="rules" ref="uForm">
  217. <u-form-item label="¥" prop="userInfo.amount" ref="item1">
  218. <u--input v-model="model1.userInfo.amount" border="none" placeholder="点击输入金额"></u--input>
  219. </u-form-item>
  220. </u--form>
  221. </view>
  222. <view style="margin:0 32rpx">
  223. <u-button type="primary" text="确认支付" @click="Confirmationpaymentjine"></u-button>
  224. </view>
  225. </view>
  226. </u-popup>
  227. <!-- 订单类型 -->
  228. <u-picker :show="orderShowtype" :itemHeight="80" :columns="orderColumnstype" keyName="label"
  229. @confirm="orderConfirmtype" @cancel='orderCanceltype'>
  230. </u-picker>
  231. <u-notify ref="uNotify" message=""></u-notify>
  232. </view>
  233. </template>
  234. <script>
  235. import {
  236. methods
  237. } from '../../../uni_modules/uview-ui/libs/mixin/mixin';
  238. var QRCode = require('@/utils/qrcode.js');
  239. const BaseApi = require("@/http/baseApi.js");
  240. export default {
  241. name: 'Workordertodone',
  242. data() {
  243. const currentDate = this.getDate({
  244. format: 'yyyy-mm'
  245. })
  246. return {
  247. tabs: [{
  248. name: '账单明细',
  249. }, {
  250. name: '我的订单',
  251. }, {
  252. name: '扣缴记录'
  253. }],
  254. model1: {
  255. userInfo: {
  256. amount: '',
  257. },
  258. },
  259. rules: {
  260. 'userInfo.amount': {
  261. type: 'string',
  262. required: true,
  263. message: '请填写预存金额',
  264. trigger: ['blur', 'change']
  265. },
  266. },
  267. showMore: false,
  268. Predepositshow: true,
  269. showpayjine: false,
  270. zhifucanvas: false,
  271. radiolist1: [],
  272. radiovalue1: '微信',
  273. showjiaofei: false,
  274. showpay: false,
  275. myday: currentDate,
  276. totalnumber: 0,
  277. jfnodata: false,
  278. showtype: false,
  279. //账单明细
  280. billIds: [],
  281. // 订单
  282. myorderType: '类型',
  283. orderPd: true,
  284. orderShowtype: false,
  285. orderTotalnumber: 0,
  286. orderList: [],
  287. orderDataForm: {
  288. status: "",
  289. page: 1,
  290. limit: 10,
  291. },
  292. orderColumnstype: [
  293. [{
  294. label: '全部',
  295. id: ''
  296. }, {
  297. label: '已关闭',
  298. id: '-1'
  299. },
  300. {
  301. label: '待支付',
  302. id: '0'
  303. },
  304. {
  305. label: '已支付',
  306. id: '1'
  307. },
  308. ]
  309. ],
  310. //end
  311. //扣缴记录
  312. mytype: '扣缴类型',
  313. indexList2: [],
  314. dataForm: {
  315. tenantId: '',
  316. costCycle: currentDate,
  317. type: '',
  318. page: 1,
  319. limit: 10,
  320. },
  321. cdshow: 0,
  322. current: 0,
  323. zhanghuyue: 0,
  324. heji: 0,
  325. indexList1: [],
  326. nodata: true,
  327. pd: true,
  328. zhifufangshi: '',
  329. columnstype: [],
  330. PropertyType: [],
  331. }
  332. },
  333. //监听页面加载,其参数为上个页面传递的数据,参数类型为 Object(用于页面传参
  334. onLoad: function(options) { //option为object类型,会序列化上个页面传递的参数
  335. let userInfo = JSON.parse(decodeURIComponent(options.info));
  336. this.dataForm.tenantId = userInfo.tenantId;
  337. let getDictDataList = uni.getStorageSync('getDictDataList');
  338. for (let i = 0; i < getDictDataList.length; i++) {
  339. if (getDictDataList[i].dictType == 'PayType') {
  340. this.columnstype = [getDictDataList[i].dataList]
  341. }
  342. if (getDictDataList[i].dictType == 'PropertyType') {
  343. this.PropertyType = [getDictDataList[i].dataList]
  344. }
  345. }
  346. this.getpaisongdata(); //账单明细
  347. },
  348. //监听页面初次渲染完成。注意如果渲染速度快,会在页面进入动画完成前触发
  349. onReady() {},
  350. //监听页面隐藏
  351. onHide() {},
  352. //监听窗口尺寸变化
  353. onResize() {},
  354. //监听页面卸载
  355. onUnload() {},
  356. //监听用户下拉动作,一般用于下拉刷新
  357. onPullDownRefresh() {},
  358. methods: {
  359. guanbi() {
  360. this.zhifucanvas = false;
  361. this.dataForm.page = 1;
  362. this.indexList1 = [];
  363. this.getpaisongdata();
  364. },
  365. // 创建订单
  366. createOrder(postdata,type) {
  367. uni.request({
  368. url: BaseApi.BaseApi + '/pay/createOrder',
  369. method: "POST",
  370. data: postdata,
  371. header: {
  372. 'content-type': 'application/x-www-form-urlencoded',
  373. "token": uni.getStorageSync('tokendata'),
  374. },
  375. success: (res) => {
  376. if(type){
  377. let qrcode = new QRCode('canvas', {
  378. text: res.data.codeUrl, // weixin://wxpay/bizpayurl?pr=sZz****
  379. width: 213,
  380. height: 213,
  381. colorDark: "black",
  382. colorLight: "white",
  383. correctLevel: QRCode.CorrectLevel.H,
  384. });
  385. }
  386. }
  387. });
  388. },
  389. //确认预存
  390. Confirmationpaymentjine() {
  391. this.$refs.uForm.validate().then(res => {
  392. this.zhifucanvas = true;
  393. this.showpayjine = false;
  394. this.Predepositshow = false;
  395. let postdata = {
  396. totalFee: this.model1.userInfo.amount,
  397. tenantId: this.dataForm.tenantId,
  398. tradeType: 'NATIVE',
  399. billIds: ''
  400. }
  401. this.createOrder(postdata,1);
  402. }).catch(errors => {
  403. //Funi.$u.toast('校验失败')
  404. })
  405. },
  406. Predeposit() {
  407. this.showpayjine = true;
  408. },
  409. queryOrder1() {
  410. this.Predepositshow = true;
  411. this.zhifucanvas = false;
  412. this.indexList1 = [];
  413. this.dataForm.page = 1;
  414. this.getpaisongdata();
  415. },
  416. queryOrder2() {
  417. this.Predepositshow = true;
  418. this.zhifucanvas = false;
  419. this.indexList2 = [];
  420. this.dataForm.page = 1;
  421. this.getpayrecord();
  422. },
  423. //提交订单
  424. Confirmationpayment() {
  425. this.showpay=false;
  426. if (this.zhifufangshi == 'zhanghu') {
  427. //余额是否足够支付,不够提示充值
  428. let billIdslist = this.billIds;
  429. if (this.zhanghuyue >= this.heji) {
  430. let postdata = {
  431. amount: String(this.heji),
  432. tenantId: this.dataForm.tenantId,
  433. payType: 'Account',
  434. billIds: billIdslist
  435. }
  436. this.$api.post('/billinfo/billPay', postdata)
  437. .then(res => {
  438. if (res.data.code == 0) {
  439. this.$refs.uNotify.success(res.data.msg)
  440. this.showpay = false;
  441. this.indexList1 = [];
  442. this.dataForm.page = 1;
  443. this.getpaisongdata();
  444. } else {
  445. this.$refs.uNotify.error(res.data.msg)
  446. this.showpay = false;
  447. }
  448. })
  449. } else if (this.zhanghuyue < this.heji) {
  450. let postdata = {
  451. totalFee: this.heji,
  452. tenantId: this.dataForm.tenantId,
  453. tradeType: 'NATIVE',
  454. billIds: billIdslist
  455. }
  456. this.createOrder(postdata)
  457. this.showjiaofei = true;
  458. }
  459. } else if (this.zhifufangshi == 'weixin') {
  460. this.zhifucanvas = true;
  461. this.showpay = false;
  462. let billIdslist = this.billIds.join(',');
  463. let postdata = {
  464. totalFee:this.heji,
  465. tenantId: this.dataForm.tenantId,
  466. tradeType: 'NATIVE',
  467. billIds: billIdslist
  468. }
  469. this.createOrder(postdata,1);
  470. }
  471. this.heji=0;
  472. },
  473. //确认提前缴费
  474. jiaofeiconfirm() {
  475. this.showpayjine = true;
  476. this.showjiaofei = false;
  477. this.dataForm.page = 1;
  478. this.indexList1 = [];
  479. this.getpaisongdata();
  480. },
  481. // 取消缴费
  482. cancleJiaofei(){
  483. this.showjiaofei = false;
  484. this.dataForm.page = 1;
  485. this.indexList1 = [];
  486. this.getpaisongdata();
  487. },
  488. Immediatepayment() {
  489. //获取账户余额
  490. this.$api.get('/accountinfo/detail/' + this.dataForm.tenantId, {})
  491. .then(res => {
  492. this.zhanghuyue = res.data.data.amount;
  493. this.showpay = true;
  494. this.radiolist1 = [{
  495. name: '微信',
  496. disabled: false,
  497. id: 'weixin',
  498. },
  499. {
  500. name: '账户余额' + '(可用¥' + this.zhanghuyue + ')',
  501. disabled: false,
  502. id: 'zhanghu'
  503. },
  504. ]
  505. })
  506. },
  507. closepay() {
  508. this.showpay = false
  509. },
  510. closepay1() {
  511. this.showpayjine = false
  512. },
  513. //勾选账单明细
  514. checkItem(e) {
  515. e.check = !e.check;
  516. if (e.check) {
  517. this.heji += e.amount;
  518. for (let i = 0; i < e.billLists.length; i++) {
  519. this.billIds.push(e.billLists[i].id);
  520. }
  521. } else {
  522. if (this.heji > 0) {
  523. this.heji -= e.amount;
  524. }
  525. for (let i = 0; i < e.billLists.length; i++) {
  526. let ind = this.billIds.indexOf(e.billLists[i].id);
  527. if (ind > -1) {
  528. this.billIds.splice(ind, 1);
  529. }
  530. }
  531. }
  532. },
  533. // 我的订单
  534. cancle(id, ind) {
  535. let that=this;
  536. uni.request({
  537. url: BaseApi.BaseApi + '/pay/closeOrder/' + id,
  538. methods: 'get',
  539. success(res) {
  540. if (res.data.returnCode =="SUCCESS") {
  541. that.orderList.splice(ind, 1);
  542. }
  543. }
  544. })
  545. },
  546. dateChange(e) {
  547. this.myday = e.target.value;
  548. this.dataForm.costCycle = e.target.value;
  549. this.dataForm.page = 1;
  550. this.indexList1 = [];
  551. this.getpaisongdata();
  552. },
  553. sectionChange(val) {
  554. this.current = val.index;
  555. if (val.index == 0) {
  556. this.cdshow = 0;
  557. this.indexList1 = [];
  558. this.dataForm.page = 1;
  559. this.getpaisongdata();
  560. } else if (val.index == 1) {
  561. this.cdshow = 1;
  562. this.orderList = [];
  563. this.orderDataForm.page = 1;
  564. this.getorderList();
  565. } else if (val.index == 2) {
  566. this.cdshow = 2;
  567. this.indexList2 = [];
  568. this.dataForm.page = 1;
  569. this.getpayrecord();
  570. }
  571. },
  572. scrolltolower() {
  573. if (this.pd) {
  574. this.getpaisongdata();
  575. } else {
  576. return
  577. }
  578. },
  579. scrolltolower2() {
  580. if (this.pd) {
  581. this.getpayrecord();
  582. } else {
  583. return
  584. }
  585. },
  586. getpayrecord() {
  587. this.$api.get('/payrecord/page', this.dataForm)
  588. .then(res => {
  589. this.totalnumber = res.data.data.total;
  590. if (res.data.data.list.length != 0) {
  591. this.indexList2.push(...res.data.data.list);
  592. this.dataForm.page = this.dataForm.page + 1;
  593. this.pd = true;
  594. this.jfnodata = false;
  595. } else {
  596. uni.showToast({
  597. title: '暂无更多数据了',
  598. icon: 'none',
  599. duration: 1500
  600. })
  601. this.pd = false;
  602. }
  603. })
  604. },
  605. getpaisongdata() {
  606. this.$api.post('/billinfo/billDetail', this.dataForm)
  607. .then(res => {
  608. this.totalnumber = res.data.data.length;
  609. if (res.data.data.length != 0) {
  610. for (let i = 0; i < res.data.data.length; i++) {
  611. res.data.data[i].check = false;
  612. res.data.data[i].showMore = false;
  613. }
  614. this.indexList1.push(...res.data.data);
  615. this.dataForm.page = this.dataForm.page + 1;
  616. this.pd = true;
  617. this.jfnodata = false;
  618. } else {
  619. if(this.dataForm.page!=1){
  620. uni.showToast({
  621. title: '暂无更多数据了',
  622. icon: 'none',
  623. duration: 1500
  624. })
  625. }
  626. this.pd = false;
  627. }
  628. })
  629. },
  630. getDate(type) {
  631. const date = new Date();
  632. let year = date.getFullYear();
  633. let month = date.getMonth();
  634. if (type === 'start') {
  635. year = year - 60;
  636. } else if (type === 'end') {
  637. year = year + 2;
  638. }
  639. month = month > 9 ? month : '0' + month;
  640. // day = day > 9 ? day : '0' + day;
  641. return `${year}-${month}`;
  642. },
  643. typechange() {
  644. this.showtype = true;
  645. },
  646. confirmtype(e) {
  647. this.indexList2 = [];
  648. this.showtype = false;
  649. if (e.value[0].dictValue == 'all') {
  650. this.mytype = e.value[0].dictLabel;
  651. this.dataForm.type = '';
  652. this.dataForm.page = 1;
  653. this.getpayrecord();
  654. } else {
  655. this.mytype = e.value[0].dictLabel;
  656. this.dataForm.type = e.value[0].dictValue;
  657. this.dataForm.page = 1;
  658. this.getpayrecord();
  659. }
  660. },
  661. canceltype() {
  662. this.showtype = false;
  663. },
  664. // 订单
  665. orderDetail(e) {
  666. uni.navigateTo({
  667. url: `/pages/my/Myorder/Orderdetails/Orderdetails?companyOrgId=${e.id}`
  668. });
  669. },
  670. orderScrolltolower() {
  671. if (this.orderPd) {
  672. this.getorderList();
  673. } else {
  674. return
  675. }
  676. },
  677. getorderList() {
  678. this.$api.get('/order/page', this.orderDataForm)
  679. .then(res => {
  680. this.orderTotalnumber = res.data.data.total;
  681. if (res.data.data.list.length != 0) {
  682. this.orderList.push(...res.data.data.list);
  683. this.orderDataForm.page = this.orderDataForm.page + 1;
  684. this.orderPd = true;
  685. } else {
  686. uni.showToast({
  687. title: '暂无更多数据了',
  688. icon: 'none',
  689. duration: 1500
  690. })
  691. this.orderPd = false;
  692. }
  693. })
  694. },
  695. orderCanceltype() {
  696. this.orderShowtype = false;
  697. },
  698. orderConfirmtype(e) {
  699. this.orderShowtype = false;
  700. this.myorderType = e.value[0].label;
  701. this.orderDataForm.status = e.value[0].id;
  702. this.orderList = [];
  703. this.orderDataForm.page = 1;
  704. this.getorderList();
  705. },
  706. orderTypechange() {
  707. this.orderShowtype = true;
  708. },
  709. }
  710. }
  711. </script>
  712. <style lang="scss">
  713. .Predeposit {
  714. position: fixed;
  715. bottom: 0;
  716. left: 0;
  717. right: 0;
  718. height: 98rpx;
  719. line-height: 98rpx;
  720. width: 750rpx;
  721. background-color: #fff;
  722. text-align: center;
  723. color: #2E69EB;
  724. box-shadow: 0 -6px 12px 0 rgba(153, 153, 153, 0.10);
  725. }
  726. .nodata {
  727. text-align: center;
  728. padding-top: 400rpx;
  729. }
  730. .zhifucanvas {
  731. width: 400rpx;
  732. height: 400rpx;
  733. margin: 0 auto;
  734. }
  735. .canys {
  736. width: 500rpx;
  737. height: 600rpx;
  738. position: fixed;
  739. top: 30%;
  740. left: 0;
  741. right: 0;
  742. margin: 0 auto;
  743. background: #e6e6e6;
  744. h4 {
  745. width: 500rpx;
  746. text-align: center;
  747. height: 80rpx;
  748. line-height: 80rpx;
  749. }
  750. }
  751. .guanbi {
  752. margin-top: 50rpx;
  753. }
  754. .zhifufs {
  755. padding: 10rpx 60rpx 30px;
  756. ::v-deep .u-radio-label--right {
  757. margin-top: 30rpx;
  758. }
  759. ::v-deep .uni-input-placeholder {
  760. text-align: left
  761. }
  762. ::v-deep .u-radio__icon-wrap {
  763. width: 40rpx !important;
  764. height: 40rpx !important;
  765. }
  766. ::v-deep .u-radio__text {
  767. font-size: 32rpx !important;
  768. }
  769. }
  770. .hejitop {
  771. text-align: center;
  772. border-bottom: 1px solid #eee;
  773. padding: 48rpx 0 24rpx;
  774. font-size: 32rpx;
  775. }
  776. .paytall {
  777. padding: 12px 0;
  778. }
  779. .heji span {
  780. color: #ED3A25;
  781. }
  782. .likezhifu {
  783. margin-left: 20rpx;
  784. margin-right: 30rpx;
  785. }
  786. .zhifu {
  787. position: fixed;
  788. right: 0;
  789. bottom: 0;
  790. left: 0;
  791. height: 98rpx;
  792. background-color: #fff;
  793. display: flex;
  794. align-items: center;
  795. justify-content: flex-end;
  796. .zhifuright {
  797. display: flex;
  798. align-items: center;
  799. justify-content: flex-end;
  800. }
  801. }
  802. .page {
  803. height: 100%;
  804. overflow: hidden;
  805. .contain {
  806. height: calc(100% - 44px);
  807. padding: 0;
  808. display: flex;
  809. flex-direction: column;
  810. .u-listdata {
  811. height: 400px;
  812. flex: 1;
  813. display: flex;
  814. flex-direction: column;
  815. }
  816. }
  817. }
  818. .paisong,
  819. .paisong2 {
  820. display: flex;
  821. flex-direction: column;
  822. justify-content: center;
  823. background-color: #fff;
  824. margin: 0 16px 24rpx;
  825. padding: 12px 16px 12px 34px;
  826. border-radius: 4px;
  827. position: relative;
  828. .iconBtn {
  829. position: absolute;
  830. top: 32rpx;
  831. right: 32rpx;
  832. z-index: 1;
  833. }
  834. .title {
  835. width: 90%;
  836. font-size: 32rpx;
  837. color: #0C1935;
  838. margin-bottom: 16rpx;
  839. span {
  840. color: #FA5555;
  841. font-weight: 600;
  842. }
  843. .status {
  844. width: 50px;
  845. padding: 3px 3px 10px 3px;
  846. text-align: center;
  847. font-size: 13px;
  848. color: #fff;
  849. background-color: #09C700;
  850. border-radius: 11px;
  851. position: absolute;
  852. left: 40%;
  853. top: 6px;
  854. transform: scale(0.8);
  855. &.s1 {
  856. background: url('@/static/imgs/paySuccess.png') no-repeat;
  857. background-size: 100%;
  858. }
  859. &.s2 {
  860. background: url('@/static/imgs/payerror.png') no-repeat;
  861. background-size: 100%;
  862. }
  863. }
  864. }
  865. .subtit {
  866. color: #9DA0AC;
  867. margin-bottom: 6rpx;
  868. }
  869. .check {
  870. position: absolute;
  871. left: 16rpx;
  872. top: 24rpx;
  873. z-index: 1;
  874. font-size: 0;
  875. transform: scale(.7)
  876. }
  877. }
  878. .paisong2 {
  879. display: flex;
  880. flex-direction: column;
  881. justify-content: center;
  882. background-color: #fff;
  883. margin: 0 16px 24rpx;
  884. padding: 12px 16px;
  885. border-radius: 4px;
  886. position: relative;
  887. .status {
  888. position: absolute;
  889. width: 96rpx;
  890. height: 48rpx;
  891. border-radius: 0 8rpx 0 20rpx;
  892. right: 0;
  893. line-height: 48rpx;
  894. text-align: center;
  895. top: 0;
  896. z-index: 1;
  897. font-size: 22rpx;
  898. background-color: #30D3A2;
  899. color: #fff;
  900. &.s2 {
  901. background-color: #09C700;
  902. }
  903. &.s3 {
  904. background-color: #FA5555;
  905. }
  906. &.s4 {
  907. background-color: #FF9C27;
  908. }
  909. }
  910. }
  911. .topbilledit {
  912. display: flex;
  913. justify-content: center;
  914. align-items: center;
  915. background: #fff;
  916. height: 88rpx;
  917. }
  918. .changetime2 {
  919. padding-left: 10rpx;
  920. }
  921. .operation {
  922. text-align: right;
  923. margin-right: -32rpx;
  924. height: 70rpx;
  925. margin-top: 32rpx;
  926. text {
  927. padding: 6px 12px;
  928. font-size: 12px;
  929. border: 1px solid #D8D8D8;
  930. border-radius: 20px;
  931. margin-right: 16px;
  932. &.p2 {
  933. border-color: #2E69EB;
  934. color: #2E69EB;
  935. }
  936. }
  937. }
  938. </style>