contractdetail.vue 23 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015
  1. <template>
  2. <view>
  3. <view class="headboxcon">
  4. <view class="contractin">
  5. <text class="tis">合同基础信息</text>
  6. <view class="tip">
  7. <text class="yu">合同名称</text>
  8. <text class="yuna">{{msg.name}}</text>
  9. </view>
  10. <view class="tip">
  11. <text class="yu">合同编号</text>
  12. <text class="yuna">{{msg.contractNo}}</text>
  13. </view>
  14. <view class="tipup">
  15. <text class="yu">合同附件</text>
  16. <view class="upbox">
  17. <u-upload :fileList="fileList1" @afterRead="afterRead" @delete="deletePic" name="1" multiple
  18. :maxCount="fileList1.length" :deletable="false"></u-upload>
  19. </view>
  20. </view>
  21. <view class="tipup">
  22. <text class="yu">发票附件</text>
  23. <view class="upbox">
  24. <u-upload :fileList="fileList2" @afterRead="afterRead" @delete="deletePic" name="2" multiple
  25. :maxCount="fileList2.length" :deletable="false"></u-upload>
  26. </view>
  27. </view>
  28. <view class="tipup">
  29. <text class="yu">贸易合同</text>
  30. <view class="upbox">
  31. <u-upload :fileList="fileList3" @afterRead="afterRead" @delete="deletePic" name="3" multiple
  32. :maxCount="fileList3.length" :deletable="false"></u-upload>
  33. </view>
  34. </view>
  35. <view class="tip" style="border-top: 1rpx solid #E8E8E8;margin-top: 20rpx;padding-top: 30rpx;">
  36. <text class="yu">合同状态</text>
  37. <text v-if="msg.statusText=='待审核'" :style="{'color':'#D05C39;'}">{{msg.statusText}}</text>
  38. <text v-if="msg.statusText=='失败'" :style="{'color':'#1F242A'}">{{msg.statusText}}</text>
  39. <text v-if="msg.statusText=='已删除'" :style="{'color':'#1F242A'}">{{msg.statusText}}</text>
  40. <text v-if="msg.statusText=='成功'" :style="{'color':'#D8AB5A'}">{{msg.statusText}}</text>
  41. </view>
  42. <view class="">
  43. <view class="tipup " style="display: flex;flex-direction: column;">
  44. <text class="yu">审核反馈</text>
  45. <view>
  46. <textarea :placeholder="placehodertitle"
  47. style="background-color: #F6F6F6;width: 640rpx;height: 200rpx;border-radius: 20rpx;padding: 20rpx;box-sizing: border-box;margin:20rpx 0;margin-bottom: 30rpx;"
  48. v-model="feedback" :disabled="disabled"></textarea>
  49. </view>
  50. </view>
  51. <view class="tipup">
  52. <text class="yu">反馈截图</text>
  53. <view class="upbox" style="margin-bottom: 30rpx;" v-if="state==0">
  54. <u-upload :fileList="fileList4" @afterRead="afterRead" @delete="deletePic" name="4" multiple
  55. :maxCount="6" :disabled="disabled" :deletable="delablepic"></u-upload>
  56. </view>
  57. <view class="upbox" style="margin-bottom: 30rpx;" v-if="state==1">
  58. <u-upload :fileList="fileList4" @afterRead="afterRead" @delete="deletePic" name="4" multiple
  59. :maxCount="fileList4.length" :deletable="delablepic"></u-upload>
  60. </view>
  61. </view>
  62. </view>
  63. </view>
  64. </view>
  65. <view class="acpcardlist">
  66. <view class="lable " v-for="(item,index) in msg.contractDraft.result" :key="index">
  67. <view class="radiobox" v-if="editall">
  68. <radio :value="index" :checked="item.checked" color="#D8AB5A" @click="checkBox(item.id)" />
  69. </view>
  70. <view class="acpcard" @click="billDetail(item.id,index)">
  71. <view class="allmsg">
  72. <view class="acpcont">
  73. <view class="acpname">
  74. <view>
  75. <text style="flex: 1;">{{item.name}}</text>
  76. <text class="ardydele" v-if="item.draftStatus==1">已删除</text>
  77. </view>
  78. <view class="tag">{{item.statusText}}</view>
  79. </view>
  80. <view class="acpinfo ">
  81. <text class="pt">汇票号码:{{item.draftNo}}</text>
  82. <text class="pt">金额:¥ {{item.money}}</text>
  83. <text class="pt">服务费:¥ {{item.serviceMoney}}</text>
  84. <text class="pt">承兑人:{{item.acceptorName}}</text>
  85. </view>
  86. </view>
  87. </view>
  88. </view>
  89. </view>
  90. </view>
  91. <view class="totalmanage ">
  92. <text style="color:#68625B;font-size: 28rpx;">合计:{{msg.contractDraft.total?msg.contractDraft.total:''}}份</text>
  93. <view class=" maboxtitls" @click="editall=true" v-if="msg.statusText!='待审核'">
  94. <view class="managebox">
  95. <image src="/static/img/manage.png" mode="aspectFit"></image>
  96. </view>
  97. <text style="padding-left: 15rpx;">管理</text>
  98. </view>
  99. </view>
  100. <view style="padding-bottom:150rpx;"></view>
  101. <view class="safebt"></view>
  102. <!-- <view class="newbill flex1" v-if="state==1&&msg.statusText=='失败'" >
  103. <view class="newbillbtn" @click="addBill">
  104. <text>新增汇票</text>
  105. </view>
  106. </view> -->
  107. <view class="newbill flex1" v-if="state==1&&msg.statusText=='成功'">
  108. <view class="newbillbtn" @click="addBill">
  109. <text>新增汇票</text>
  110. </view>
  111. </view>
  112. <view class="newbill flex1" v-if="state==0">
  113. <view class="choosebtn" v-if="msg.statusText === '成功'? isShow ==1 : isShow == 0 ">
  114. <view class="delbtn flex1" @click="examineFail()">审核失败</view>
  115. <view class="succbtn flex1" @click="examineSuccess()">审核成功</view>
  116. </view>
  117. </view>
  118. <!-- <view class="newbill flex1" >
  119. <view class="newbillbtn" @click="tryAgain">
  120. <text>重新提交</text>
  121. </view>
  122. </view> -->
  123. <view class="newbill flex1" v-if="msg.statusText=='失败'&&state==1">
  124. <view class="choosebtn">
  125. <view class="delbtn flex1" @click="tryAgain()">重新提交</view>
  126. <view class="succbtn flex1" @click="addBill()">新增汇票</view>
  127. </view>
  128. </view>
  129. <!-- 底部删除 -->
  130. <u-popup :show="editall&&state==1" @close="closeEidt" @open="openEidt" :overlay="false">
  131. <view class="editbox">
  132. <view class="chooseall flex6">
  133. <view class="leftchoose ">
  134. <radio :checked="quan" @click="makeSureAll" color="#D8AB5A"></radio>
  135. <text>全选</text>
  136. </view>
  137. <view class="surebtn" @click="selectDown">
  138. 完成
  139. </view>
  140. </view>
  141. <view class="choosebtn">
  142. <view class="delbtn flex1" @click="dele()">刪除</view>
  143. <view class="restorebtn flex1" @click="restore()">复原</view>
  144. </view>
  145. </view>
  146. </u-popup>
  147. <!-- 底部删除 -->
  148. <u-popup :show="editall&&state==0" @close="closeEidt" @open="openEidt" :overlay="false">
  149. <view class="editbox">
  150. <view class="chooseall flex6">
  151. <view class="leftchoose ">
  152. <radio :checked="quan" @click="makeSureAll" color="#D8AB5A"></radio>
  153. <text>全选</text>
  154. </view>
  155. <view class="anniu">
  156. <text class="usa" @click="dele()">删除</text>
  157. <text class="usa" @click="restore()">复原</text>
  158. <text @click="selectDown" class="usa">完成</text>
  159. </view>
  160. </view>
  161. <view class="choosebtn">
  162. <view class="delbtn flex1" @click="examineBillFail()">审核失败</view>
  163. <view class="restorebtn flex1" @click="examineBillSuccess()">审核成功</view>
  164. </view>
  165. </view>
  166. </u-popup>
  167. </view>
  168. </template>
  169. <script>
  170. let that
  171. import {
  172. mainUrl
  173. } from '@/http/baseUrl.js';
  174. export default {
  175. data() {
  176. return {
  177. //审核成功后隐藏按钮
  178. isShow:0,
  179. editall: false,
  180. quan: false,
  181. state: 0,
  182. fileList1: [],
  183. fileList2: [],
  184. fileList3: [],
  185. fileList4: [],
  186. msg: '',
  187. id: '',
  188. fankui: '',
  189. feedback: '',
  190. disabled: false,
  191. delablepic: true,
  192. placehodertitle: '请输入审核反馈'
  193. }
  194. },
  195. onLoad(o) {
  196. that = this
  197. if (o.id) {
  198. this.id = o.id
  199. }
  200. this.state = this.$store.state.admin
  201. if (this.state == 1) {
  202. this.disabled = true
  203. this.delablepic = false
  204. }
  205. },
  206. onShow() {
  207. this.init()
  208. },
  209. methods: {
  210. init() {
  211. uni.showLoading()
  212. uni.$u.http.get(`/api/Contract/${this.id}`, {
  213. custom: {
  214. auth: true
  215. }
  216. }).then((res) => {
  217. uni.hideLoading()
  218. this.msg = res
  219. this.msg.contractDraft.result.forEach(item => {
  220. item.checked = false
  221. })
  222. const newData1 = res.picList.map((item) => {
  223. return {
  224. url: item,
  225. }
  226. })
  227. this.fileList1 = newData1
  228. const newData2 = res.invoicePicList.map((item) => {
  229. return {
  230. url: item,
  231. }
  232. })
  233. this.fileList2 = newData2
  234. const newData3 = res.tradePicList.map((item) => {
  235. return {
  236. url: item,
  237. }
  238. })
  239. this.fileList3 = newData3
  240. if (res.feedbackPics) {
  241. const newData4 = res.feedbackPics.map((item) => {
  242. return {
  243. url: item,
  244. }
  245. })
  246. this.fileList4 = newData4
  247. }
  248. if (this.state == 1) {
  249. if (res.feedback.length > 0) {
  250. this.feedback = res.feedback
  251. } else {
  252. this.feedback = "无"
  253. }
  254. } else {
  255. if (res.feedback.length > 0) {
  256. this.feedback = res.feedback
  257. } else {
  258. this.placehodertitle = "请输入审核反馈"
  259. }
  260. }
  261. }).catch((err) => {
  262. uni.hideLoading()
  263. console.log(err)
  264. })
  265. },
  266. openEidt() {
  267. this.editall = true
  268. },
  269. checkBox(id) {
  270. let list = this.msg.contractDraft.result
  271. list.forEach(item => {
  272. if (item.id == id) {
  273. item.checked = !item.checked
  274. }
  275. })
  276. this.msg.contractDraft.result = JSON.parse(JSON.stringify(list))
  277. },
  278. allSelect() {
  279. let list = this.msg.contractDraft.result
  280. if (this.quan) {
  281. list.forEach(item => {
  282. item.checked = true
  283. })
  284. } else {
  285. list.forEach(item => {
  286. item.checked = false
  287. })
  288. }
  289. this.msg.contractDraft.result = JSON.parse(JSON.stringify(list))
  290. },
  291. acpDetail() {
  292. uni.navigateTo({
  293. url: "/pages/alldeatil/acptdetail"
  294. })
  295. },
  296. addBill() {
  297. let obj = {
  298. contractId: this.id
  299. }
  300. uni.navigateTo({
  301. url: "/pages/alldeatil/addbill?obj=" + JSON.stringify(obj)
  302. })
  303. },
  304. billDetail(id, index) {
  305. // if(this.msg.statusText=="待审核"&&this.state==1){
  306. // return
  307. // }else{
  308. let obj = {
  309. id: id,
  310. index: index,
  311. contractId: this.id,
  312. statusText: this.msg.statusText
  313. }
  314. uni.navigateTo({
  315. url: "/pages/alldeatil/billdetail?obj=" + JSON.stringify(obj)
  316. })
  317. // }
  318. },
  319. makeSureAll() {
  320. this.quan = !this.quan
  321. this.allSelect()
  322. },
  323. selectDown() {
  324. this.editall = false
  325. this.quan = true
  326. let list = this.msg.contractDraft.result
  327. list.forEach(item => {
  328. item.checked = false
  329. })
  330. },
  331. tryAgain() {
  332. let obj = this.msg
  333. uni.navigateTo({
  334. url: "/pages/alldeatil/upcontract?obj=" + JSON.stringify(obj)
  335. })
  336. },
  337. examineSuccess() {
  338. // let ids = []
  339. // ids.push(this.id)
  340. console.log(111);
  341. uni.showModal({
  342. title: '提示',
  343. content: "是否审核成功?审核成功",
  344. success: function(res) {
  345. if (res.confirm) {
  346. let form = {
  347. id: Number(that.id),
  348. approveStatus: 1
  349. }
  350. if (that.fileList4.length > 0) {
  351. let feedbackPicList = []
  352. that.fileList4.forEach(item => {
  353. feedbackPicList.push(item.url)
  354. })
  355. form.feedbackPicList = feedbackPicList
  356. }
  357. let feedback = that.feedback
  358. if (feedback.length > 0) {
  359. form.feedback = feedback
  360. }
  361. // ={
  362. // feedback:feedback,
  363. // feedbackPicList:feedbackPicList
  364. // }
  365. uni.showLoading()
  366. uni.$u.http.post('api/Contract/approveContract', form, {
  367. custom: {
  368. auth: true
  369. }
  370. }).then((res) => {
  371. uni.hideLoading()
  372. that.editall = false
  373. that.quan = false
  374. that.$toast("操作成功")
  375. that.isShow = 1
  376. setTimeout(() => {
  377. that.init()
  378. }, 500)
  379. }).catch((err) => {
  380. uni.hideLoading()
  381. that.$toast(err.msg)
  382. })
  383. } else if (res.cancel) {
  384. }
  385. }
  386. })
  387. },
  388. examineFail() {
  389. uni.showModal({
  390. title: '提示',
  391. content: "是否审核失败?",
  392. success: function(res) {
  393. if (res.confirm) {
  394. let form = {
  395. id: Number(that.id),
  396. approveStatus: 2
  397. }
  398. if (that.fileList4.length > 0) {
  399. let feedbackPicList = []
  400. that.fileList4.forEach(item => {
  401. feedbackPicList.push(item.url)
  402. })
  403. form.feedbackPicList = feedbackPicList
  404. }
  405. let feedback = that.feedback
  406. if (feedback.length > 0) {
  407. form.feedback = feedback
  408. }
  409. // ={
  410. // feedback:feedback,
  411. // feedbackPicList:feedbackPicList
  412. // }
  413. uni.showLoading()
  414. uni.$u.http.post('api/Contract/approveContract', form, {
  415. custom: {
  416. auth: true
  417. }
  418. }).then((res) => {
  419. uni.hideLoading()
  420. that.editall = false
  421. that.quan = false
  422. that.$toast("操作成功")
  423. setTimeout(() => {
  424. that.init()
  425. }, 500)
  426. }).catch((err) => {
  427. uni.hideLoading()
  428. that.$toast(err.msg)
  429. })
  430. } else if (res.cancel) {
  431. }
  432. }
  433. })
  434. },
  435. examineBillSuccess() {
  436. let ids = []
  437. this.msg.contractDraft.result.forEach(item => {
  438. if (item.checked) {
  439. ids.push(item.id)
  440. }
  441. })
  442. if (ids.length == 0) {
  443. that.$toast("请选择汇票")
  444. return
  445. }
  446. uni.showModal({
  447. title: '提示',
  448. content: "是否批量审核成功?",
  449. success: function(res) {
  450. if (res.confirm) {
  451. uni.showLoading()
  452. uni.$u.http.post('/api/Contract/contractDraft/manager', {
  453. ids: ids,
  454. operateType: 3
  455. }, {
  456. custom: {
  457. auth: true
  458. }
  459. }).then((res) => {
  460. uni.hideLoading()
  461. that.editall = false
  462. that.quan = false
  463. that.$toast("操作成功")
  464. setTimeout(() => {
  465. that.init()
  466. }, 500)
  467. }).catch((err) => {
  468. uni.hideLoading()
  469. that.$toast(err.msg)
  470. })
  471. } else if (res.cancel) {
  472. }
  473. }
  474. })
  475. },
  476. examineBillFail() {
  477. let ids = []
  478. this.msg.contractDraft.result.forEach(item => {
  479. if (item.checked) {
  480. ids.push(item.id)
  481. }
  482. })
  483. if (ids.length == 0) {
  484. this.$toast("请选择汇票")
  485. return
  486. }
  487. uni.showModal({
  488. title: '提示',
  489. content: '是否审核失败?',
  490. success: function(res) {
  491. if (res.confirm) {
  492. uni.showLoading()
  493. uni.$u.http.post('/api/Contract/contractDraft/manager', {
  494. ids: ids,
  495. operateType: 4
  496. }, {
  497. custom: {
  498. auth: true
  499. }
  500. }).then((res) => {
  501. uni.hideLoading()
  502. that.editall = false
  503. that.quan = false
  504. that.$toast("操作成功")
  505. setTimeout(() => {
  506. that.init()
  507. }, 500)
  508. }).catch((err) => {
  509. uni.hideLoading()
  510. that.$toast(err.msg)
  511. })
  512. } else if (res.cancel) {
  513. console.log('用户点击取消');
  514. }
  515. }
  516. });
  517. },
  518. dele() {
  519. let ids = []
  520. this.msg.contractDraft.result.forEach(item => {
  521. if (item.checked) {
  522. ids.push(item.id)
  523. }
  524. })
  525. if (ids.length == 0) {
  526. that.$toast("请选择汇票")
  527. return
  528. }
  529. uni.showModal({
  530. title: '提示',
  531. content: "是否删除汇票?",
  532. success: function(res) {
  533. if (res.confirm) {
  534. uni.showLoading()
  535. uni.$u.http.post('/api/Contract/contractDraft/manager', {
  536. ids: ids,
  537. operateType: 1
  538. }, {
  539. custom: {
  540. auth: true
  541. }
  542. }).then((res) => {
  543. uni.hideLoading()
  544. that.editall = false
  545. that.quan = false
  546. that.$toast("操作成功")
  547. setTimeout(() => {
  548. that.init()
  549. }, 500)
  550. }).catch((err) => {
  551. uni.hideLoading()
  552. that.$toast(err.msg)
  553. })
  554. } else if (res.cancel) {
  555. }
  556. }
  557. })
  558. },
  559. restore() {
  560. let ids = []
  561. this.msg.contractDraft.result.forEach(item => {
  562. if (item.checked) {
  563. ids.push(item.id)
  564. }
  565. })
  566. if (ids.length == 0) {
  567. that.$toast("请选择汇票")
  568. return
  569. }
  570. uni.showModal({
  571. title: '提示',
  572. content: "是否复原汇票?",
  573. success: function(res) {
  574. if (res.confirm) {
  575. uni.showLoading()
  576. uni.$u.http.post('/api/Contract/contractDraft/manager', {
  577. ids: ids,
  578. operateType: 2
  579. }, {
  580. custom: {
  581. auth: true
  582. }
  583. }).then((res) => {
  584. uni.hideLoading()
  585. that.editall = false
  586. that.quan = false
  587. that.$toast("操作成功")
  588. setTimeout(() => {
  589. that.init()
  590. }, 500)
  591. }).catch((err) => {
  592. uni.hideLoading()
  593. that.$toast(err.msg)
  594. })
  595. } else if (res.cancel) {
  596. }
  597. }
  598. })
  599. },
  600. deleContract() {
  601. let ids = []
  602. this.msg.contractDraft.result.forEach(item => {
  603. if (item.checked) {
  604. ids.push(item.id)
  605. }
  606. })
  607. if (ids.length == 0) {
  608. that.$toast("请选择汇票")
  609. return
  610. }
  611. uni.showModal({
  612. title: '提示',
  613. content: "是否删除汇票?",
  614. success: function(res) {
  615. if (res.confirm) {
  616. uni.showLoading()
  617. uni.$u.http.post('/api/Contract/contractDraft/manager', {
  618. ids: ids,
  619. operateType: 1
  620. }, {
  621. custom: {
  622. auth: true
  623. }
  624. }).then((res) => {
  625. uni.hideLoading()
  626. that.editall = false
  627. that.quan = false
  628. that.$toast("操作成功")
  629. setTimeout(() => {
  630. that.init()
  631. }, 500)
  632. }).catch((err) => {
  633. uni.hideLoading()
  634. that.$toast(err.msg)
  635. })
  636. } else if (res.cancel) {
  637. }
  638. }
  639. })
  640. },
  641. restoreContract() {
  642. let ids = []
  643. this.msg.contractDraft.result.forEach(item => {
  644. if (item.checked) {
  645. ids.push(item.id)
  646. }
  647. })
  648. if (ids.length == 0) {
  649. that.$toast("请选择汇票")
  650. return
  651. }
  652. uni.showModal({
  653. title: '提示',
  654. content: "是否复原汇票?",
  655. success: function(res) {
  656. if (res.confirm) {
  657. uni.showLoading()
  658. uni.$u.http.post('/api/Contract/contractDraft/manager', {
  659. ids: ids,
  660. operateType: 2
  661. }, {
  662. custom: {
  663. auth: true
  664. }
  665. }).then((res) => {
  666. uni.hideLoading()
  667. that.editall = false
  668. that.quan = false
  669. that.$toast("操作成功")
  670. setTimeout(() => {
  671. that.init()
  672. }, 500)
  673. }).catch((err) => {
  674. uni.hideLoading()
  675. that.$toast(err.msg)
  676. })
  677. } else if (res.cancel) {
  678. }
  679. }
  680. })
  681. },
  682. // 删除图片
  683. deletePic(event) {
  684. this[`fileList${event.name}`].splice(event.index, 1)
  685. },
  686. // 新增图片
  687. async afterRead(event) {
  688. // 当设置 mutiple 为 true 时, file 为数组格式,否则为对象格式
  689. let lists = [].concat(event.file)
  690. let fileListLen = this[`fileList${event.name}`].length
  691. lists.map((item) => {
  692. this[`fileList${event.name}`].push({
  693. ...item,
  694. status: 'uploading',
  695. message: '上传中'
  696. })
  697. })
  698. for (let i = 0; i < lists.length; i++) {
  699. const result = await this.uploadFilePromise(lists[i].url)
  700. let item = this[`fileList${event.name}`][fileListLen]
  701. this[`fileList${event.name}`].splice(fileListLen, 1, Object.assign(item, {
  702. status: 'success',
  703. message: '',
  704. url: result
  705. }))
  706. fileListLen++
  707. }
  708. },
  709. uploadFilePromise(url) {
  710. return new Promise((resolve, reject) => {
  711. let a = uni.uploadFile({
  712. url: mainUrl + '/api/File', // 仅为示例,非真实的接口地址
  713. filePath: url,
  714. name: 'File',
  715. header: {
  716. "User-Agent": "apifox/1.0.0 (https://www.apifox.cn)"
  717. },
  718. formData: {
  719. File: JSON.stringify(url),
  720. },
  721. success: (res) => {
  722. let request = JSON.parse(res.data)
  723. setTimeout(() => {
  724. resolve(request.data.file)
  725. }, 1000)
  726. }
  727. });
  728. })
  729. },
  730. }
  731. }
  732. </script>
  733. <style lang="scss">
  734. page {
  735. background-color: #F6F6F6 !important;
  736. }
  737. .headboxcon {
  738. margin: 20rpx 30rpx;
  739. background-color: #fff;
  740. border-radius: 20rpx;
  741. padding: 0 30rpx;
  742. box-sizing: border-box;
  743. .tis {
  744. font-size: 36rpx;
  745. font-weight: 600;
  746. display: block;
  747. padding: 30rpx 0;
  748. // width: 120rpx;
  749. padding-top: 50rpx;
  750. }
  751. .tipup {
  752. display: flex;
  753. padding-bottom: 30rpx;
  754. }
  755. .upbox {
  756. margin-left: 30rpx;
  757. // width: 490rpx;
  758. }
  759. .yu {
  760. flex-shrink:0;
  761. // flex:/ 1;
  762. width: 130rpx;
  763. display: block;
  764. // width: 120rpx;
  765. color: #BEBDBB;
  766. }
  767. .tip {
  768. padding-bottom: 30rpx;
  769. font-size: 28rpx;
  770. display: flex;
  771. justify-content: space-between;
  772. .yuna {
  773. // flex-shrink:0;
  774. // width:400rpx;
  775. text-align:right;
  776. word-break: break-word;
  777. }
  778. }
  779. }
  780. .searchbox {
  781. padding-left: 30rpx;
  782. box-sizing: border-box;
  783. background-color: #ECECEC;
  784. border-radius: 38rpx;
  785. // width: 688rpx;
  786. flex: 1;
  787. height: 75rpx;
  788. margin: 0 auto;
  789. display: flex;
  790. align-items: center;
  791. justify-content: center;
  792. }
  793. .acpcardlist {
  794. // margin-top: 140rpx;
  795. .acpcard {
  796. flex: 1;
  797. // width: 690rpx;
  798. // height: 333rpx;
  799. margin: 0 30rpx;
  800. // margin-top: 20rpx;
  801. background-color: #fff;
  802. border-radius: 20rpx;
  803. box-shadow: 0px 8rpx 20rpx 1rpx rgba(31, 36, 42, 0.08);
  804. .allmsg {
  805. display: flex;
  806. padding: 40rpx 30rpx;
  807. box-sizing: border-box;
  808. width: 100%;
  809. .cicle {
  810. width: 28rpx;
  811. height: 28rpx;
  812. border-radius: 50%;
  813. background-color: #D8AB5A;
  814. margin-top: 8rpx;
  815. }
  816. .acpcont {
  817. margin-left: 20rpx;
  818. width: 100%;
  819. .acpname {
  820. box-sizing: border-box;
  821. display: flex;
  822. align-items: center;
  823. justify-content: space-between;
  824. padding-bottom: 30rpx;
  825. flex-grow: 1;
  826. width: 100%;
  827. // width: 572rpx;
  828. font-size: 36rpx;
  829. font-weight: 600;
  830. .ardydele {
  831. padding: 5rpx 8rpx;
  832. border-radius: 10rpx 0 10rpx 0;
  833. margin-left: 10rpx;
  834. box-sizing: border-box;
  835. background-color: rgb(219, 219, 219);
  836. font-size: 20rpx;
  837. color: #fff;
  838. }
  839. .tag {
  840. margin-left: 10rpx;
  841. font-weight: 500;
  842. border-radius: 10rpx;
  843. // font-size: 36rpx;
  844. color: #BEBDBB;
  845. text-align: center;
  846. }
  847. }
  848. }
  849. .acpinfo {
  850. border-top: 1rpx solid #E8E8E8;
  851. display: flex;
  852. flex: 1;
  853. flex-direction: column;
  854. font-size: 28rpx;
  855. color: #68625B;
  856. justify-content: space-between;
  857. box-sizing: border-box;
  858. .pt {
  859. padding-top: 20rpx;
  860. }
  861. }
  862. }
  863. }
  864. }
  865. .totalmanage {
  866. margin-top: 50rpx;
  867. margin-bottom: 100rpx;
  868. // position: fixed;
  869. bottom: 0;
  870. display: flex;
  871. justify-content: space-between;
  872. align-items: center;
  873. width: 100%;
  874. padding: 0 30rpx;
  875. box-sizing: border-box;
  876. .managebox {
  877. width: 23.8rpx;
  878. height: 29.7rpx;
  879. image {
  880. width: 100%;
  881. height: 100%;
  882. }
  883. }
  884. .maboxtitls {
  885. width: 160rpx;
  886. height: 60rpx;
  887. display: flex;
  888. align-items: center;
  889. justify-content: center;
  890. border-radius: 30rpx;
  891. background-color: #D9D9D9;
  892. // line-height: 60rpx;
  893. font-size: 28rpx;
  894. box-sizing: border-box;
  895. // align-items: center;
  896. }
  897. }
  898. .newbill {
  899. background-color: #fff;
  900. position: fixed;
  901. bottom: 0;
  902. padding-top: 10rpx;
  903. padding-bottom: 40rpx;
  904. width: 100%;
  905. z-index: 999;
  906. .newbillbtn {
  907. background: linear-gradient(to right, #FFE1AD, #D8AB5A);
  908. width: 474rpx;
  909. height: 88rpx;
  910. border-radius: 43rpx;
  911. box-shadow: 0 10rpx 20rpx 1rpx rgba(179, 116, 5, 0.2);
  912. line-height: 88rpx;
  913. color: #fff;
  914. text-align: center;
  915. }
  916. }
  917. </style>