refund.vue 19 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825
  1. <template>
  2. <view class="refund-page">
  3. <!-- 红色提示信息 -->
  4. <view class="warning-tip" v-if="minusOrderRefund == 1">
  5. <view class="warning-icon">⚠</view>
  6. <text class="warning-text" v-if="minusOrderReason == 1">已过可售后时间,只能开负数订单售后</text>
  7. <text class="warning-text"v-else>
  8. <block v-if="Number(orderInfo.remainDebtPrice)<=0">订单已结账,只能开负数订单售后</block>
  9. <block v-else>订单已部分结账,只能开负数订单售后</block>
  10. </text>
  11. </view>
  12. <!-- 退款方式选择卡片 -->
  13. <view class="card-section">
  14. <view class="section-title">
  15. <text class="title-text">退款方式</text>
  16. </view>
  17. <view class="refund-type-buttons">
  18. <button
  19. class="admin-button-com big"
  20. :class="refundType==1?'blue':'default'"
  21. @tap="refundType=1">
  22. 退货并退款
  23. </button>
  24. <button
  25. class="admin-button-com big"
  26. :class="refundType==2?'blue':'default'"
  27. @tap="refundType=2">
  28. 只退款
  29. </button>
  30. </view>
  31. </view>
  32. <!-- 商品选择卡片 -->
  33. <view class="card-section">
  34. <view class="section-title">
  35. <text class="title-text">退货商品</text>
  36. </view>
  37. <view class="product-list-compact">
  38. <template v-if="!$util.isEmpty(goodsInfoList)">
  39. <view class="product-row" v-for="(res,i) in goodsInfoList" :key="i">
  40. <view class="product-basic-info">
  41. <text class="product-name-compact">{{res.name}}</text>
  42. <view class="product-meta">
  43. <text class="stock-info">{{parseFloat(res.num)}}份 X ¥{{parseFloat(res.unitPrice)}}</text>
  44. <text class="available-info">可退 {{Number(res.num)-Number(res.refundNum)}}份</text>
  45. </view>
  46. </view>
  47. <view class="refund-control">
  48. <view class="refund-input-group">
  49. <view class="input-item">
  50. <text class="input-label">数量</text>
  51. <input
  52. class="refund-input-compact"
  53. type="number"
  54. placeholder="0"
  55. v-model="res.refundCount"
  56. placeholder-style="color:#ccc"
  57. @focus="clearRefundCount(res)" />
  58. <text class="unit-label">份</text>
  59. </view>
  60. <view class="input-item">
  61. <text class="input-label">单价</text>
  62. <input
  63. class="refund-input-compact"
  64. type="digit"
  65. placeholder="0.00"
  66. v-model="res.perPrice"
  67. placeholder-style="color:#ccc"
  68. @focus="clearPerPrice(res)" />
  69. <text class="unit-label">元</text>
  70. </view>
  71. </view>
  72. </view>
  73. </view>
  74. </template>
  75. <template v-if="!$util.isEmpty(itemInfoList)">
  76. <view class="product-row" v-for="(res,i) in itemInfoList" :key="i">
  77. <view class="product-basic-info">
  78. <text class="product-name-compact">{{res.name}}</text>
  79. <view class="product-meta">
  80. <text class="stock-info">{{parseFloat(res.num)}}{{res.unitName}} X ¥{{parseFloat(res.unitPrice)}}</text>
  81. <text class="available-info">可退 {{Number(res.num)-Number(res.refundNum)}}{{res.unitName}}</text>
  82. </view>
  83. </view>
  84. <view class="refund-control">
  85. <view class="refund-input-group">
  86. <view class="input-item">
  87. <text class="input-label">数量</text>
  88. <input
  89. class="refund-input-compact"
  90. type="number"
  91. placeholder="0"
  92. v-model="res.refundCount"
  93. placeholder-style="color:#ccc"
  94. @focus="clearRefundCount(res)" />
  95. <text class="unit-label">{{res.unitName}}</text>
  96. </view>
  97. <view class="input-item">
  98. <text class="input-label">单价</text>
  99. <input
  100. class="refund-input-compact"
  101. type="digit"
  102. placeholder="0.00"
  103. v-model="res.perPrice"
  104. placeholder-style="color:#ccc"
  105. @focus="clearPerPrice(res)" />
  106. <text class="unit-label">元</text>
  107. </view>
  108. </view>
  109. </view>
  110. </view>
  111. </template>
  112. </view>
  113. </view>
  114. <!-- 金额信息卡片 -->
  115. <view class="card-section">
  116. <view class="section-title">
  117. <text class="title-text">金额信息</text>
  118. </view>
  119. <view class="amount-info">
  120. <view class="amount-row">
  121. <text class="amount-label">订单金额</text>
  122. <view class="amount-value">
  123. <text class="price-text">¥{{parseFloat(orderInfo.orderPrice)||0}}</text>
  124. </view>
  125. </view>
  126. <view class="amount-row" v-if="Number(orderInfo.tkPrice)>0">
  127. <text class="amount-label">已退金额</text>
  128. <view class="amount-value">
  129. <text class="refunded-text">¥{{orderInfo.tkPrice ? parseFloat(orderInfo.tkPrice) : 0}}</text>
  130. </view>
  131. </view>
  132. <view class="amount-row">
  133. <text class="amount-label">可退金额</text>
  134. <text class="amount-value available-amount">¥{{coundRefundPrice}}</text>
  135. </view>
  136. <view class="amount-row input-row">
  137. <text class="amount-label required">退款金额</text>
  138. <text class="amount-value refund-amount">¥{{refundMoney}}</text>
  139. </view>
  140. </view>
  141. </view>
  142. <!-- 备注卡片 -->
  143. <view class="card-section">
  144. <view class="section-title">
  145. <text class="title-text">备注</text>
  146. </view>
  147. <view class="remark-container">
  148. <textarea
  149. class="remark-textarea"
  150. v-model="remark"
  151. placeholder="选填"
  152. placeholder-style="color:#999"
  153. @focus="clearRemark" />
  154. </view>
  155. </view>
  156. <!-- 底部操作按钮 -->
  157. <view class="bottom-actions">
  158. <button class="action-btn cancel-btn" @tap="cancelRefund">取消</button>
  159. <button class="action-btn confirm-btn" @tap="askRefund">退款</button>
  160. </view>
  161. <!-- 退款确认弹框 -->
  162. <ModalModule
  163. :show="showRefundModal"
  164. :custom="true"
  165. :button="[]"
  166. width="90%"
  167. @click="handleRefundModalClick">
  168. <view class="refund-confirm-modal">
  169. <view class="modal-header">
  170. <text class="modal-title">提示</text>
  171. </view>
  172. <view class="modal-content">
  173. <view class="amount-display">
  174. <text class="amount-label">退款金额</text>
  175. <text class="amount-value">¥{{refundMoney}}</text>
  176. </view>
  177. <view class="confirm-text">
  178. <text v-if="minusOrderRefund == 0">确认要退款吗?</text>
  179. <text v-else>确认开负数订单退款吗?</text>
  180. </view>
  181. </view>
  182. <view class="modal-actions">
  183. <button class="modal-btn cancel-modal-btn" @tap="cancelRefundModal">取消</button>
  184. <button class="modal-btn confirm-modal-btn" @tap="executeRefund" v-if="minusOrderRefund == 0">确认退款</button>
  185. <button class="modal-btn confirm-modal-btn" @tap="executeRefund" v-else>确认开单退款</button>
  186. </view>
  187. </view>
  188. </ModalModule>
  189. </view>
  190. </template>
  191. <script>
  192. import { getDetail,refund } from "@/api/order/index";
  193. import ModalModule from "@/components/plugin/modal";
  194. export default {
  195. name: "orderDetail",
  196. components: { ModalModule },
  197. data() {
  198. return {
  199. goodsInfoList:[],
  200. itemInfoList:[],
  201. refundMoney:0,
  202. refundType:1,
  203. remark:'',
  204. orderInfo:{},
  205. coundRefundPrice:0,
  206. showRefundModal: false,
  207. minusOrderRefund:0,//0表示按正常流程售后,1表示开负数订单售后
  208. minusOrderReason:0,//只能开负数订单的几种情况:0、开的欠款单,并且已经全部或者部分结清,1、可售后时间到了
  209. };
  210. },
  211. computed:{
  212. refundPrice(){
  213. let price = 0
  214. if(!this.$util.isEmpty(this.goodsInfoList)){
  215. for (const item of this.goodsInfoList) {
  216. if(Number(item.refundCount)>0){
  217. let currentPrice = Number(item.refundCount)*Number(item.perPrice)
  218. currentPrice.toFixed(2)
  219. price = Number(price) + Number(currentPrice)
  220. price.toFixed(2)
  221. }
  222. }
  223. }
  224. if(!this.$util.isEmpty(this.itemInfoList)){
  225. for (const item of this.itemInfoList) {
  226. if(Number(item.refundCount)>0){
  227. let currentPrice = Number(item.refundCount)*Number(item.perPrice)
  228. currentPrice.toFixed(2)
  229. price = Number(price) + Number(currentPrice)
  230. price.toFixed(2)
  231. }
  232. }
  233. }
  234. this.refundMoney = parseFloat(price.toFixed(2))
  235. return price
  236. }
  237. },
  238. methods: {
  239. clearRefundCount(item) {
  240. this.$set(item, 'refundCount', '');
  241. },
  242. clearPerPrice(item) {
  243. this.$set(item, 'perPrice', '');
  244. },
  245. clearRefundMoney() {
  246. this.refundMoney = '';
  247. },
  248. clearRemark() {
  249. this.remark = '';
  250. },
  251. cancelRefund(){
  252. uni.navigateBack({delta: 1});
  253. },
  254. askRefund(){
  255. if(this.orderInfo.payWay == 3 && Number(this.orderInfo.remainDebtPrice)>0 && Number(this.refundMoney)>Number(this.orderInfo.remainDebtPrice)){
  256. //如果退款金额大于剩余欠款,则提醒走开负数订单方式退款
  257. this.$util.confirmModal({content:'售后金额超过剩余欠款,只能开负数订单方式售后'},() => {
  258. this.minusOrderRefund = 1
  259. this.confirmRefund()
  260. })
  261. }else{
  262. this.confirmRefund()
  263. }
  264. },
  265. confirmRefund(){
  266. let hasError = false
  267. let selectProduct = []
  268. if(!this.$util.isEmpty(this.goodsInfoList)){
  269. this.goodsInfoList.forEach(ele=>{
  270. let currentRefundCont = ele.refundCount ? Number(ele.refundCount) :0
  271. let currentNum = ele.num ? Number(ele.num) : 0
  272. let hasRefundNum = ele.refundNum ? Number(ele.refundNum) : 0
  273. let couldRefundNum = Number(currentNum) - Number(hasRefundNum)
  274. if(Number(currentRefundCont) > Number(couldRefundNum)){
  275. uni.showToast({title:ele.name+'超过可退数量',icon:'none'})
  276. hasError = true;
  277. return false
  278. }
  279. if(Number(ele.refundCount)>0){
  280. if(Number(ele.perPrice)>Number(ele.unitPrice)){
  281. uni.showToast({title:ele.name+' 退款单价不能大于原价',icon:'none'})
  282. hasError = true;
  283. return false
  284. }
  285. selectProduct.push({"productId":ele.goodsId,"num":ele.refundCount,"unitType":ele.unitType,unitName:ele.unitName,unitPrice:ele.perPrice || ele.unitPrice,property:0})
  286. }
  287. })
  288. }
  289. if(!this.$util.isEmpty(this.itemInfoList)){
  290. this.itemInfoList.forEach(ele=>{
  291. let currentRefundCont = ele.refundCount ? Number(ele.refundCount) :0
  292. let currentNum = ele.num ? Number(ele.num) : 0
  293. let hasRefundNum = ele.refundNum ? Number(ele.refundNum) : 0
  294. let couldRefundNum = Number(currentNum) - Number(hasRefundNum)
  295. if(Number(currentRefundCont) > Number(couldRefundNum)){
  296. uni.showToast({title:ele.name+'超过可退数量',icon:'none'})
  297. hasError = true;
  298. return false
  299. }
  300. if(Number(ele.refundCount)>0){
  301. if(Number(ele.perPrice)>Number(ele.unitPrice)){
  302. uni.showToast({title:ele.name+' 退款单价不能大于原价',icon:'none'})
  303. hasError = true;
  304. return false
  305. }
  306. selectProduct.push({"productId":ele.itemId,"num":ele.refundCount,"unitType":ele.unitType,unitName:ele.unitName,unitPrice:ele.perPrice || ele.unitPrice,property:1})
  307. }
  308. })
  309. }
  310. if(hasError){
  311. return
  312. }
  313. if(this.$util.isEmpty(selectProduct)){
  314. uni.showToast({title:'请选择商品',icon:'none'})
  315. return;
  316. }
  317. if(Number(this.refundMoney)<=0){
  318. this.$msg('请填写退款金额')
  319. return false
  320. }
  321. // 显示确认退款弹框
  322. this.showRefundModal = true
  323. },
  324. // 弹框相关方法
  325. handleRefundModalClick(e) {
  326. // 处理弹框点击事件
  327. },
  328. cancelRefundModal() {
  329. this.showRefundModal = false
  330. },
  331. executeRefund() {
  332. this.showRefundModal = false
  333. // 获取之前验证过的商品数据
  334. let selectProduct = []
  335. if(!this.$util.isEmpty(this.goodsInfoList)){
  336. this.goodsInfoList.forEach(ele=>{
  337. if(Number(ele.refundCount)>0){
  338. selectProduct.push({"productId":ele.goodsId,"num":ele.refundCount,"unitType":ele.unitType,unitName:ele.unitName,unitPrice:ele.perPrice || ele.unitPrice,property:0})
  339. }
  340. })
  341. }
  342. if(!this.$util.isEmpty(this.itemInfoList)){
  343. this.itemInfoList.forEach(ele=>{
  344. if(Number(ele.refundCount)>0){
  345. selectProduct.push({"productId":ele.itemId,"num":ele.refundCount,"unitType":ele.unitType,unitName:ele.unitName,unitPrice:ele.perPrice || ele.unitPrice,property:1})
  346. }
  347. })
  348. }
  349. let refundParams = {product:JSON.stringify(selectProduct),id: this.option.id,price:this.refundMoney,remark:this.remark,refundType:this.refundType,getOriginalItem:1,version:2}
  350. this.doRefund(refundParams)
  351. },
  352. doRefund(refundParams){
  353. uni.showLoading({mask:true})
  354. refund(refundParams).then(res => {
  355. uni.hideLoading()
  356. if(res.code == 1){
  357. this.$util.pageTo({url:'/common/success',query:{titleType:1},type:2})
  358. }
  359. })
  360. },
  361. async init() {
  362. const res = await getDetail({ id: this.option.id})
  363. this.orderInfo = res.data
  364. this.minusOrderRefund = this.orderInfo.minusOrderRefund?this.orderInfo.minusOrderRefund:0
  365. this.minusOrderReason = this.orderInfo.minusOrderReason?this.orderInfo.minusOrderReason:0
  366. this.coundRefundPrice = Number(res.data.orderPrice) - Number(res.data.tkPrice)
  367. this.coundRefundPrice = this.coundRefundPrice.toFixed(2)
  368. this.coundRefundPrice = parseFloat(this.coundRefundPrice)
  369. this.goodsInfoList = res.data.goodsInfoList.map(ele=>{
  370. return {...ele,refundCount:null,perPrice:''}
  371. })
  372. this.itemInfoList = res.data.itemInfoList.map(ele=>{
  373. return {...ele,refundCount:null,perPrice:''}
  374. })
  375. }
  376. }
  377. };
  378. </script>
  379. <style lang="scss" scoped>
  380. .refund-page {
  381. min-height: 100vh;
  382. background: #f5f6f8;
  383. padding: 20upx 0 200upx;
  384. }
  385. // 红色提示样式
  386. .warning-tip {
  387. background: #fff2f0;
  388. border: 1upx solid #ffccc7;
  389. border-radius: 8upx;
  390. margin: 0upx 20upx 20upx 20upx;
  391. padding: 20upx;
  392. display: flex;
  393. align-items: center;
  394. justify-content: center;
  395. gap: 15upx;
  396. .warning-icon {
  397. font-size: 40upx;
  398. color: #ff4757;
  399. font-weight: bold;
  400. line-height: 1;
  401. }
  402. .warning-text {
  403. font-size: 34upx;
  404. color: #ff4757;
  405. font-weight:bold;
  406. text-align: center;
  407. }
  408. }
  409. // 卡片样式
  410. .card-section {
  411. background: #fff;
  412. margin: 0 20upx 20upx;
  413. border-radius: 16upx;
  414. box-shadow: 0 2upx 12upx rgba(0, 0, 0, 0.08);
  415. overflow: hidden;
  416. }
  417. // 节标题
  418. .section-title {
  419. padding: 30upx 30upx 20upx;
  420. border-bottom: 1upx solid #f0f0f0;
  421. display: flex;
  422. align-items: center;
  423. .title-text {
  424. font-size: 32upx;
  425. font-weight:600;
  426. color: #333;
  427. }
  428. }
  429. // 退款方式按钮
  430. .refund-type-buttons {
  431. padding: 30upx 30upx 20upx;
  432. display: flex;
  433. gap: 30upx;
  434. .admin-button-com {
  435. flex: 1;
  436. border-radius: 12upx;
  437. font-weight: 500;
  438. transition: all 0.3s ease;
  439. }
  440. }
  441. // 紧凑商品列表
  442. .product-list-compact {
  443. margin-top:15upx;
  444. padding: 0 20upx 20upx;
  445. }
  446. .product-row {
  447. display: flex;
  448. align-items: center;
  449. justify-content: space-between;
  450. padding: 20upx;
  451. margin-bottom: 8upx;
  452. background: #fafbfc;
  453. border-radius: 8upx;
  454. border: 1upx solid #eef0f2;
  455. &:last-child {
  456. margin-bottom: 0;
  457. }
  458. }
  459. .product-basic-info {
  460. flex: 1;
  461. margin-right: 20upx;
  462. .product-name-compact {
  463. font-size: 32upx;
  464. font-weight: 600;
  465. color: #333;
  466. line-height: 1.3;
  467. display: block;
  468. margin-bottom: 8upx;
  469. overflow: hidden;
  470. text-overflow: ellipsis;
  471. white-space: nowrap;
  472. width: 380upx;
  473. }
  474. .product-meta {
  475. display: flex;
  476. gap: 12upx;
  477. flex-wrap: wrap;
  478. .stock-info {
  479. font-size: 28upx;
  480. color: #666;
  481. background: #f5f5f5;
  482. padding: 4upx 8upx;
  483. border-radius: 4upx;
  484. }
  485. .available-info {
  486. font-size: 28upx;
  487. color: #09c567;
  488. background: rgba(255, 107, 53, 0.1);
  489. padding: 4upx 8upx;
  490. border-radius: 4upx;
  491. }
  492. }
  493. }
  494. .refund-control {
  495. display: flex;
  496. align-items: center;
  497. gap: 8upx;
  498. .refund-input-group {
  499. display: flex;
  500. flex-direction: column;
  501. gap: 12upx;
  502. .input-item {
  503. display: flex;
  504. align-items: center;
  505. gap: 8upx;
  506. .input-label {
  507. font-size: 24upx;
  508. color: #666;
  509. min-width: 60upx;
  510. }
  511. }
  512. }
  513. .refund-input-compact {
  514. width: 100upx;
  515. height: 60upx;
  516. background: #fff;
  517. border: 1upx solid #ddd;
  518. border-radius: 6upx;
  519. text-align: center;
  520. font-size: 26upx;
  521. color: #333;
  522. font-weight: 500;
  523. &:focus {
  524. border-color: #09c567;
  525. }
  526. }
  527. .unit-label {
  528. font-size: 24upx;
  529. color: #666;
  530. min-width: 40upx;
  531. }
  532. }
  533. // 金额信息
  534. .amount-info {
  535. padding: 30upx;
  536. }
  537. .amount-row {
  538. display: flex;
  539. justify-content: space-between;
  540. align-items: center;
  541. padding: 20upx 0;
  542. border-bottom: 1upx solid #f0f0f0;
  543. &:last-child {
  544. border-bottom: none;
  545. }
  546. &.input-row {
  547. align-items: flex-start;
  548. padding-top: 30upx;
  549. }
  550. .amount-label {
  551. font-size: 28upx;
  552. color: #666;
  553. &.required::after {
  554. content: "*";
  555. color: #ff4757;
  556. margin-left: 5upx;
  557. }
  558. }
  559. .amount-value {
  560. display: flex;
  561. align-items: center;
  562. .price-text {
  563. font-size: 32upx;
  564. font-weight: 600;
  565. color: #333;
  566. }
  567. .refunded-text {
  568. font-size: 32upx;
  569. font-weight: 600;
  570. color: #666;
  571. }
  572. &.available-amount {
  573. font-size: 32upx;
  574. font-weight: 600;
  575. color: #09c567;
  576. }
  577. &.refund-amount {
  578. font-size: 32upx;
  579. font-weight: 600;
  580. color: #c59b0f;
  581. }
  582. }
  583. }
  584. .amount-input-wrapper {
  585. display: flex;
  586. align-items: center;
  587. background: #fafbfc;
  588. border: 1upx solid #ddd;
  589. border-radius: 8upx;
  590. padding: 0 20upx;
  591. width: 190upx;
  592. .currency-symbol {
  593. font-size: 28upx;
  594. color: #666;
  595. margin-right: 10upx;
  596. }
  597. .amount-input {
  598. flex: 1;
  599. height: 80upx;
  600. font-size: 28upx;
  601. color: #333;
  602. font-weight: 500;
  603. border: none;
  604. background: transparent;
  605. width: 115upx;
  606. }
  607. }
  608. // 备注输入框
  609. .remark-container {
  610. padding: 20upx 30upx 30upx;
  611. }
  612. .remark-textarea {
  613. width: 100%;
  614. height: 120upx;
  615. background: #fafbfc;
  616. border: 1upx solid #ddd;
  617. border-radius: 8upx;
  618. padding: 15upx;
  619. font-size: 28upx;
  620. color: #333;
  621. line-height: 1.2;
  622. box-sizing: border-box;
  623. resize: none;
  624. }
  625. // 底部操作按钮
  626. .bottom-actions {
  627. z-index:39;
  628. position: fixed;
  629. bottom: 0;
  630. left: 0;
  631. right: 0;
  632. background: #fff;
  633. padding: 30upx;
  634. border-top: 1upx solid #eee;
  635. display: flex;
  636. gap: 30upx;
  637. box-shadow: 0 -4upx 12upx rgba(0, 0, 0, 0.1);
  638. }
  639. .action-btn {
  640. flex: 1;
  641. height: 88upx;
  642. border-radius: 12upx;
  643. font-size: 32upx;
  644. font-weight: 600;
  645. border: none;
  646. transition: all 0.3s ease;
  647. &.cancel-btn {
  648. background: #f8f9fa;
  649. color: #666;
  650. border: 1upx solid #ddd;
  651. &:active {
  652. background: #e9ecef;
  653. }
  654. }
  655. &.confirm-btn {
  656. background: linear-gradient(135deg, #09c567 0%, #00b894 100%);
  657. color: #fff;
  658. box-shadow: 0 4upx 12upx rgba(9, 197, 103, 0.3);
  659. &:active {
  660. transform: translateY(2upx);
  661. box-shadow: 0 2upx 8upx rgba(9, 197, 103, 0.3);
  662. }
  663. }
  664. }
  665. // 退款确认弹框样式
  666. .refund-confirm-modal {
  667. background: #fff;
  668. border-radius: 20upx;
  669. overflow: hidden;
  670. .modal-header {
  671. padding: 40upx 30upx 20upx;
  672. text-align: center;
  673. border-bottom: 1upx solid #f0f0f0;
  674. .modal-title {
  675. font-size: 36upx;
  676. font-weight: 600;
  677. color: #333;
  678. }
  679. }
  680. .modal-content {
  681. padding: 40upx 30upx;
  682. text-align: center;
  683. .amount-display {
  684. margin-bottom: 30upx;
  685. .amount-label {
  686. display: block;
  687. font-size: 28upx;
  688. color: #666;
  689. margin-bottom: 15upx;
  690. }
  691. .amount-value {
  692. display: block;
  693. font-size: 60upx;
  694. font-weight: 700;
  695. color: #ff4757;
  696. text-shadow: 0 2upx 4upx rgba(255, 71, 87, 0.2);
  697. }
  698. }
  699. .confirm-text {
  700. font-size: 30upx;
  701. color: #333;
  702. line-height: 1.5;
  703. }
  704. }
  705. .modal-actions {
  706. display: flex;
  707. gap: 20upx;
  708. padding: 0 30upx 40upx;
  709. .modal-btn {
  710. flex: 1;
  711. height: 80upx;
  712. border-radius: 12upx;
  713. font-size: 30upx;
  714. font-weight: 600;
  715. border: none;
  716. transition: all 0.3s ease;
  717. &.cancel-modal-btn {
  718. background: #f8f9fa;
  719. color: #666;
  720. border: 1upx solid #ddd;
  721. &:active {
  722. background: #e9ecef;
  723. }
  724. }
  725. &.confirm-modal-btn {
  726. background: linear-gradient(135deg, #ff4757 0%, #ff3742 100%);
  727. color: #fff;
  728. box-shadow: 0 4upx 12upx rgba(255, 71, 87, 0.3);
  729. &:active {
  730. transform: translateY(2upx);
  731. box-shadow: 0 2upx 8upx rgba(255, 71, 87, 0.3);
  732. }
  733. }
  734. }
  735. }
  736. }
  737. </style>