refund.vue 20 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900
  1. <template>
  2. <view class="container">
  3. <!-- 退款商品选择 -->
  4. <view class="section-block product-section">
  5. <text class="section-title">选择退款商品</text>
  6. <view class="product-list">
  7. <view
  8. v-for="(product, index) in orderInfo.products"
  9. :key="index"
  10. :class="['product-item', { 'product-item-selected': selectedProducts.includes(index) }]"
  11. >
  12. <!-- 商品主体信息 -->
  13. <view class="product-main" @click="toggleProductSelect(index)">
  14. <view class="product-checkbox">
  15. <view :class="['checkbox-icon', { checked: selectedProducts.includes(index) }]">
  16. <text v-if="selectedProducts.includes(index)">✓</text>
  17. </view>
  18. </view>
  19. <view class="product-image">
  20. <image v-if="product.image" :src="product.image" mode="aspectFill"></image>
  21. <view v-else class="image-placeholder"></view>
  22. </view>
  23. <view class="product-detail">
  24. <view class="name-container" @click.stop="showProductName(product.name)">
  25. <text class="product-name">{{ product.name }}</text>
  26. <text v-if="product.name.length > 12" class="expand-tip">...</text>
  27. </view>
  28. <view class="product-meta">
  29. <text class="product-price">¥{{ (product.price || 0).toFixed(2) }}</text>
  30. <text class="product-quantity-label">购买数量:x{{ product.quantity }}</text>
  31. </view>
  32. </view>
  33. </view>
  34. <!-- 退款数量选择器(仅当商品被选中时显示,独立一行) -->
  35. <view v-if="selectedProducts.includes(index)" class="refund-quantity-selector">
  36. <view class="selector-row">
  37. <text class="selector-label">退款数量</text>
  38. <view class="quantity-control">
  39. <view
  40. :class="['control-btn', (product.refundQuantity || 1) > 1 ? '' : 'disabled']"
  41. @click.stop="decreaseQuantity(index)"
  42. >
  43. <text>-</text>
  44. </view>
  45. <view class="quantity-display">
  46. <text class="quantity-text">{{ product.refundQuantity || 1 }}</text>
  47. </view>
  48. <view
  49. :class="['control-btn', (product.refundQuantity || 1) < product.quantity ? '' : 'disabled']"
  50. @click.stop="increaseQuantity(index)"
  51. >
  52. <text>+</text>
  53. </view>
  54. </view>
  55. </view>
  56. <view class="refund-amount-preview">
  57. <text class="preview-label">退款金额</text>
  58. <text class="preview-value">¥{{ ((product.price || 0) * (product.refundQuantity || 1)).toFixed(2) }}</text>
  59. </view>
  60. </view>
  61. </view>
  62. </view>
  63. <view class="selected-tip">
  64. 已选择 {{ selectedProducts.length }} 件商品,共 {{ refundQuantity }} 件
  65. </view>
  66. </view>
  67. <!-- 退款原因 -->
  68. <view class="section-block reason-section">
  69. <text class="section-title">退款原因</text>
  70. <radio-group @change="handleReasonChange">
  71. <label class="radio-item" v-for="(reason, index) in refundReasons" :key="index">
  72. <view class="radio-wrapper">
  73. <radio :value="reason.value" :checked="selectedReason === reason.value" color="#999999" />
  74. </view>
  75. <text class="radio-label">{{ reason.label }}</text>
  76. </label>
  77. </radio-group>
  78. <!-- 其他原因的文本输入框 -->
  79. <view v-if="selectedReason === '4'" class="remark-input-wrapper">
  80. <textarea
  81. v-model="refundRemark"
  82. class="remark-textarea"
  83. placeholder="请详细描述您的问题或投诉内容"
  84. maxlength="100"
  85. :show-confirm-bar="false"
  86. />
  87. <text class="remark-count">{{ refundRemark.length }}/100</text>
  88. </view>
  89. </view>
  90. <!-- 退款信息 -->
  91. <view class="section-block info-section">
  92. <text class="section-title">退款信息</text>
  93. <view class="info-row">
  94. <text class="info-label">订单编号:</text>
  95. <text class="info-value">{{ orderInfo.orderNo || '-' }}</text>
  96. </view>
  97. <view class="info-row">
  98. <text class="info-label">订单总金额:</text>
  99. <text class="info-value">¥{{ (orderInfo.totalAmount || 0).toFixed(2) }}</text>
  100. </view>
  101. <view class="info-row">
  102. <text class="info-label">退款数量:</text>
  103. <text class="info-value">{{ refundQuantity }}</text>
  104. </view>
  105. <view class="info-row">
  106. <text class="info-label">退款总金额:</text>
  107. <text class="info-value refund-amount">¥{{ refundAmount.toFixed(2) }}</text>
  108. </view>
  109. <view class="info-row" v-if="orderInfo.payTime">
  110. <text class="info-label">退款期限:</text>
  111. <text :class="['info-value', isRefundExpired ? 'expired' : '']">{{ refundExpireText }}</text>
  112. </view>
  113. </view>
  114. <!-- 提示信息 -->
  115. <view class="section-block tip-section">
  116. <text class="tip-text">• 请选择需要退款的商品</text>
  117. <text class="tip-text">• 退款申请提交后,工作人员将尽快处理</text>
  118. <text class="tip-text">• 退款金额将原路返回至您的支付账户</text>
  119. </view>
  120. <!-- 确认提交按钮 -->
  121. <button class="submit-btn" @click="submitRefund">确认提交</button>
  122. </view>
  123. </template>
  124. <script setup lang="ts">
  125. import { ref, computed, onMounted } from 'vue';
  126. import { onLoad } from '@dcloudio/uni-app';
  127. import { checkAuth } from '../../utils/auth';
  128. import { getOrderDetail } from '../../api/order';
  129. import type { OrderInfo } from '../../api/order';
  130. import { post } from '../../utils/request';
  131. // 路由参数
  132. const orderId = ref<string>('');
  133. // 订单信息
  134. const orderInfo = ref<OrderInfo>({
  135. id: '',
  136. orderNo: '',
  137. outTradeNo: '',
  138. hahaOrderNo: '',
  139. deviceId: '',
  140. totalAmount: 0,
  141. payStatus: '',
  142. status: 0,
  143. createTime: '',
  144. products: []
  145. });
  146. // 选中的商品索引列表
  147. const selectedProducts = ref<number[]>([]);
  148. // 退款数量(根据选中商品的退款数量计算)
  149. const refundQuantity = computed(() => {
  150. return selectedProducts.value.reduce((sum, index) => {
  151. const product = orderInfo.value.products[index];
  152. return sum + (product.refundQuantity || 1);
  153. }, 0);
  154. });
  155. // 退款金额(根据选中商品的退款数量计算)
  156. const refundAmount = computed(() => {
  157. return selectedProducts.value.reduce((sum, index) => {
  158. const product = orderInfo.value.products[index];
  159. if (product) {
  160. return sum + (product.price || 0) * (product.refundQuantity || 1);
  161. }
  162. return sum;
  163. }, 0);
  164. });
  165. // 判断是否超过退款期限
  166. const isRefundExpired = computed(() => {
  167. if (!orderInfo.value.payTime) return false;
  168. const payTime = new Date(orderInfo.value.payTime);
  169. const now = new Date();
  170. const diffTime = now.getTime() - payTime.getTime();
  171. const diffDays = diffTime / (1000 * 60 * 60 * 24);
  172. return diffDays > 7;
  173. });
  174. // 退款期限提示文本
  175. const refundExpireText = computed(() => {
  176. if (!orderInfo.value.payTime) return '';
  177. const payTime = new Date(orderInfo.value.payTime);
  178. const now = new Date();
  179. const diffTime = now.getTime() - payTime.getTime();
  180. const diffDays = diffTime / (1000 * 60 * 60 * 24);
  181. if (diffDays > 7) {
  182. return '已超过退款期限';
  183. } else {
  184. const remainingDays = Math.ceil(7 - diffDays);
  185. return `剩余 ${remainingDays} 天`;
  186. }
  187. });
  188. const selectedReason = ref('');
  189. const refundRemark = ref('');
  190. const refundReasons = [
  191. { label: '订单扣款错误', value: '1' },
  192. { label: '扣款金额与实际金额不符', value: '2' },
  193. { label: '商品过期或变质', value: '3' },
  194. { label: '其他(请填写投诉内容)', value: '4' }
  195. ];
  196. const handleReasonChange = (e: any) => {
  197. selectedReason.value = e.detail.value;
  198. // 如果切换到非"其他"原因,清空备注内容
  199. if (selectedReason.value !== '4') {
  200. refundRemark.value = '';
  201. }
  202. };
  203. /**
  204. * 切换商品选中状态
  205. */
  206. const toggleProductSelect = (index: number) => {
  207. const selectedIndex = selectedProducts.value.indexOf(index);
  208. if (selectedIndex > -1) {
  209. // 取消选中:清除退款数量
  210. orderInfo.value.products[index].refundQuantity = undefined;
  211. selectedProducts.value.splice(selectedIndex, 1);
  212. } else {
  213. // 选中:初始化退款数量为 1
  214. if (!orderInfo.value.products[index].refundQuantity) {
  215. orderInfo.value.products[index].refundQuantity = 1;
  216. }
  217. selectedProducts.value.push(index);
  218. }
  219. };
  220. /**
  221. * 显示商品全称
  222. */
  223. const showProductName = (productName: string) => {
  224. uni.showModal({
  225. title: '商品名称',
  226. content: productName,
  227. showCancel: false,
  228. confirmText: '知道了'
  229. });
  230. };
  231. /**
  232. * 减少退款数量
  233. */
  234. const decreaseQuantity = (index: number) => {
  235. const product = orderInfo.value.products[index];
  236. if (product.refundQuantity && product.refundQuantity > 1) {
  237. product.refundQuantity--;
  238. }
  239. };
  240. /**
  241. * 增加退款数量
  242. */
  243. const increaseQuantity = (index: number) => {
  244. const product = orderInfo.value.products[index];
  245. if ((product.refundQuantity || 1) < product.quantity) {
  246. if (!product.refundQuantity) {
  247. product.refundQuantity = 2;
  248. } else {
  249. product.refundQuantity++;
  250. }
  251. }
  252. };
  253. /**
  254. * 显示商品详情
  255. */
  256. const showProductDetail = () => {
  257. // TODO: 跳转到商品详情页或弹出商品详情弹窗
  258. uni.showToast({
  259. title: '商品详情功能开发中',
  260. icon: 'none'
  261. });
  262. };
  263. /**
  264. * 加载订单详情
  265. */
  266. const loadOrderDetail = async () => {
  267. if (!orderId.value) {
  268. uni.showToast({
  269. title: '订单 ID 缺失',
  270. icon: 'none'
  271. });
  272. setTimeout(() => {
  273. uni.navigateBack();
  274. }, 1500);
  275. return;
  276. }
  277. try {
  278. const detail = await getOrderDetail({ orderId: orderId.value });
  279. orderInfo.value = detail;
  280. // 检查订单是否超过退款期限(7天)
  281. if (detail.payTime) {
  282. const payTime = new Date(detail.payTime);
  283. const now = new Date();
  284. const diffTime = now.getTime() - payTime.getTime();
  285. const diffDays = diffTime / (1000 * 60 * 60 * 24);
  286. if (diffDays > 7) {
  287. uni.showModal({
  288. title: '退款期限已过',
  289. content: '该订单已完成超过7天,不支持申请退款',
  290. showCancel: false,
  291. confirmText: '知道了',
  292. success: () => {
  293. uni.navigateBack();
  294. }
  295. });
  296. return;
  297. }
  298. }
  299. // 默认不选中任何商品(移除之前的默认全选逻辑)
  300. selectedProducts.value = [];
  301. } catch (error) {
  302. console.error('加载订单详情失败:', error);
  303. uni.showToast({
  304. title: '加载订单详情失败',
  305. icon: 'none'
  306. });
  307. setTimeout(() => {
  308. uni.navigateBack();
  309. }, 1500);
  310. }
  311. };
  312. /**
  313. * 页面加载时检查登录状态并加载订单详情
  314. */
  315. onMounted(() => {
  316. // 检查登录状态,未登录会自动跳转到登录页
  317. checkAuth();
  318. });
  319. /**
  320. * 监听页面加载参数
  321. */
  322. onLoad((options) => {
  323. if (options && options.orderId) {
  324. // 直接使用字符串类型的订单ID,避免精度丢失
  325. orderId.value = String(options.orderId);
  326. loadOrderDetail();
  327. } else {
  328. uni.showToast({
  329. title: '订单 ID 缺失',
  330. icon: 'none'
  331. });
  332. setTimeout(() => {
  333. uni.navigateBack();
  334. }, 1500);
  335. }
  336. });
  337. /**
  338. * 提交退款申请
  339. */
  340. const submitRefund = async () => {
  341. // 校验是否选择了商品
  342. if (selectedProducts.value.length === 0) {
  343. uni.showToast({
  344. title: '请选择要退款的商品',
  345. icon: 'none'
  346. });
  347. return;
  348. }
  349. // 校验退款原因
  350. if (!selectedReason.value) {
  351. uni.showToast({
  352. title: '请选择退款原因',
  353. icon: 'none'
  354. });
  355. return;
  356. }
  357. // 如果选择"其他"原因,校验备注内容
  358. if (selectedReason.value === '4' && !refundRemark.value.trim()) {
  359. uni.showToast({
  360. title: '请填写投诉内容',
  361. icon: 'none'
  362. });
  363. return;
  364. }
  365. // 映射前端退款原因到后端描述
  366. const reasonMap: Record<string, string> = {
  367. '1': '订单扣款错误',
  368. '2': '扣款金额与实际金额不符',
  369. '3': '商品过期或变质',
  370. '4': '其他'
  371. };
  372. let reasonText = reasonMap[selectedReason.value] || '用户申请退款';
  373. // 如果是"其他"原因,将备注内容附加到原因后面
  374. if (selectedReason.value === '4' && refundRemark.value.trim()) {
  375. reasonText = `其他:${refundRemark.value.trim()}`;
  376. }
  377. // 构建选中的商品信息(包含退款数量)
  378. const selectedProductIds = selectedProducts.value.map(index => {
  379. const product = orderInfo.value.products[index];
  380. return {
  381. productId: product.id,
  382. productName: product.name,
  383. quantity: product.refundQuantity || 1, // 使用用户选择的退款数量
  384. price: product.price
  385. };
  386. });
  387. try {
  388. // 调用后端退款 API
  389. const result = await post('/payment/refund', {
  390. orderId: orderId.value,
  391. reason: reasonText,
  392. products: selectedProductIds // 传递选中的商品信息
  393. });
  394. uni.showToast({
  395. title: '退款申请成功',
  396. icon: 'success'
  397. });
  398. setTimeout(() => {
  399. uni.navigateBack();
  400. }, 1500);
  401. } catch (error: any) {
  402. console.error('退款申请失败:', error);
  403. // 错误提示已在 request 拦截器中处理
  404. }
  405. };
  406. </script>
  407. <style>
  408. .container {
  409. min-height: 100vh;
  410. background-color: #f5f5f5;
  411. padding-top: 20rpx;
  412. padding-bottom: 40rpx;
  413. }
  414. /* 商品选择区域 */
  415. .product-section {
  416. margin-bottom: 20rpx;
  417. padding-bottom: 20rpx;
  418. }
  419. .product-list {
  420. display: flex;
  421. flex-direction: column;
  422. gap: 20rpx;
  423. }
  424. .product-item {
  425. display: flex;
  426. flex-direction: column;
  427. background-color: #ffffff;
  428. border-radius: 12rpx;
  429. padding: 24rpx;
  430. border: 2rpx solid transparent;
  431. transition: all 0.3s ease;
  432. }
  433. .product-item-selected {
  434. border-color: #07c160;
  435. background-color: #f6ffed;
  436. }
  437. .product-item:active {
  438. background-color: #fafafa;
  439. }
  440. .product-main {
  441. display: flex;
  442. align-items: center;
  443. width: 100%;
  444. }
  445. .product-checkbox {
  446. margin-right: 20rpx;
  447. flex-shrink: 0;
  448. }
  449. .checkbox-icon {
  450. width: 44rpx;
  451. height: 44rpx;
  452. border-radius: 50%;
  453. border: 3rpx solid #dddddd;
  454. display: flex;
  455. align-items: center;
  456. justify-content: center;
  457. transition: all 0.3s ease;
  458. }
  459. .checkbox-icon.checked {
  460. background-color: #07c160;
  461. border-color: #07c160;
  462. box-shadow: 0 4rpx 12rpx rgba(7, 193, 96, 0.3);
  463. }
  464. .checkbox-icon text {
  465. color: #ffffff;
  466. font-size: 26rpx;
  467. font-weight: bold;
  468. }
  469. .product-image {
  470. width: 140rpx;
  471. height: 140rpx;
  472. border-radius: 12rpx;
  473. overflow: hidden;
  474. flex-shrink: 0;
  475. margin-right: 20rpx;
  476. background-color: #f5f5f5;
  477. box-shadow: 0 2rpx 8rpx rgba(0, 0, 0, 0.06);
  478. }
  479. .product-image image {
  480. width: 100%;
  481. height: 100%;
  482. }
  483. .image-placeholder {
  484. width: 100%;
  485. height: 100%;
  486. background: linear-gradient(135deg, #f5f5f5 0%, #e0e0e0 100%);
  487. display: flex;
  488. align-items: center;
  489. justify-content: center;
  490. color: #999999;
  491. font-size: 40rpx;
  492. }
  493. .product-detail {
  494. flex: 1;
  495. display: flex;
  496. flex-direction: column;
  497. justify-content: center;
  498. min-width: 0;
  499. gap: 8rpx;
  500. }
  501. .name-container {
  502. position: relative;
  503. display: flex;
  504. align-items: center;
  505. cursor: pointer;
  506. max-width: 100%;
  507. }
  508. .product-name {
  509. font-size: 28rpx;
  510. color: #333333;
  511. line-height: 1.4;
  512. overflow: hidden;
  513. text-overflow: ellipsis;
  514. white-space: nowrap;
  515. flex: 1;
  516. min-width: 0;
  517. }
  518. .expand-tip {
  519. font-size: 26rpx;
  520. color: #1890ff;
  521. margin-left: 8rpx;
  522. flex-shrink: 0;
  523. padding: 4rpx 12rpx;
  524. background-color: #e6f7ff;
  525. border-radius: 6rpx;
  526. }
  527. .product-meta {
  528. display: flex;
  529. justify-content: space-between;
  530. align-items: center;
  531. flex-wrap: wrap;
  532. gap: 8rpx;
  533. }
  534. .product-price {
  535. font-size: 32rpx;
  536. color: #ff4400;
  537. font-weight: 600;
  538. }
  539. .product-quantity {
  540. font-size: 24rpx;
  541. color: #999999;
  542. }
  543. .product-quantity-label {
  544. font-size: 24rpx;
  545. color: #999999;
  546. background-color: #f5f5f5;
  547. padding: 4rpx 12rpx;
  548. border-radius: 6rpx;
  549. }
  550. /* 退款数量选择器 */
  551. .refund-quantity-selector {
  552. margin-top: 20rpx;
  553. margin-left: 56rpx;
  554. padding: 20rpx 24rpx;
  555. background-color: #fafffe;
  556. border-radius: 12rpx;
  557. border: 1rpx solid #d9f7be;
  558. }
  559. .selector-row {
  560. display: flex;
  561. align-items: center;
  562. justify-content: space-between;
  563. }
  564. .selector-label {
  565. font-size: 28rpx;
  566. color: #52c41a;
  567. font-weight: 500;
  568. flex-shrink: 0;
  569. }
  570. .quantity-control {
  571. display: flex;
  572. align-items: center;
  573. gap: 16rpx;
  574. }
  575. .control-btn {
  576. width: 60rpx;
  577. height: 60rpx;
  578. border-radius: 12rpx;
  579. background-color: #ffffff;
  580. border: 2rpx solid #e0e0e0;
  581. display: flex;
  582. align-items: center;
  583. justify-content: center;
  584. font-size: 36rpx;
  585. color: #333333;
  586. transition: all 0.2s;
  587. }
  588. .control-btn:active {
  589. background-color: #f0f0f0;
  590. transform: scale(0.95);
  591. }
  592. .control-btn.disabled {
  593. background-color: #fafafa;
  594. border-color: #f0f0f0;
  595. color: #cccccc;
  596. cursor: not-allowed;
  597. }
  598. .control-btn.disabled:active {
  599. background-color: #fafafa;
  600. transform: none;
  601. }
  602. .quantity-display {
  603. min-width: 80rpx;
  604. height: 60rpx;
  605. text-align: center;
  606. display: flex;
  607. align-items: center;
  608. justify-content: center;
  609. background-color: #ffffff;
  610. border: 2rpx solid #07c160;
  611. border-radius: 12rpx;
  612. padding: 0 16rpx;
  613. }
  614. .quantity-text {
  615. font-size: 32rpx;
  616. color: #07c160;
  617. font-weight: 600;
  618. }
  619. /* 退款金额预览 */
  620. .refund-amount-preview {
  621. display: flex;
  622. align-items: center;
  623. justify-content: space-between;
  624. margin-top: 16rpx;
  625. padding-top: 16rpx;
  626. border-top: 1rpx dashed #d9f7be;
  627. }
  628. .preview-label {
  629. font-size: 26rpx;
  630. color: #999999;
  631. }
  632. .preview-value {
  633. font-size: 30rpx;
  634. color: #ff4400;
  635. font-weight: 600;
  636. }
  637. /* 退款商品选择器 */
  638. .section-item {
  639. background-color: #ffffff;
  640. padding: 28rpx 30rpx;
  641. display: flex;
  642. align-items: center;
  643. justify-content: space-between;
  644. margin-bottom: 20rpx;
  645. }
  646. .section-label {
  647. font-size: 30rpx;
  648. color: #333333;
  649. }
  650. .arrow-right {
  651. font-size: 32rpx;
  652. color: #cccccc;
  653. }
  654. /* 区域块 */
  655. .section-block {
  656. background-color: #ffffff;
  657. padding: 30rpx;
  658. margin-bottom: 20rpx;
  659. }
  660. .section-title {
  661. font-size: 30rpx;
  662. color: #333333;
  663. font-weight: 500;
  664. margin-bottom: 30rpx;
  665. display: block;
  666. }
  667. /* 选项列表 */
  668. radio-group {
  669. display: block;
  670. }
  671. .radio-item {
  672. display: flex;
  673. align-items: center;
  674. margin-bottom: 32rpx;
  675. }
  676. .radio-item:last-child {
  677. margin-bottom: 0;
  678. }
  679. .radio-wrapper {
  680. margin-right: 16rpx;
  681. display: flex;
  682. align-items: center;
  683. }
  684. .radio-wrapper radio {
  685. transform: scale(1.1);
  686. }
  687. .radio-label {
  688. font-size: 28rpx;
  689. color: #333333;
  690. line-height: 1.5;
  691. }
  692. /* 备注输入框 */
  693. .remark-input-wrapper {
  694. margin-top: 24rpx;
  695. padding: 20rpx;
  696. background-color: #f9f9f9;
  697. border-radius: 12rpx;
  698. border: 2rpx solid #e8e8e8;
  699. }
  700. .remark-textarea {
  701. width: 100%;
  702. min-height: 160rpx;
  703. padding: 20rpx;
  704. background-color: #ffffff;
  705. border-radius: 8rpx;
  706. border: 2rpx solid #e0e0e0;
  707. font-size: 28rpx;
  708. color: #333333;
  709. line-height: 1.6;
  710. box-sizing: border-box;
  711. }
  712. .remark-textarea:focus {
  713. border-color: #1890ff;
  714. }
  715. .remark-count {
  716. display: block;
  717. text-align: right;
  718. font-size: 24rpx;
  719. color: #999999;
  720. margin-top: 12rpx;
  721. }
  722. /* 信息区域 */
  723. .info-section {
  724. padding-bottom: 20rpx;
  725. }
  726. .info-row {
  727. display: flex;
  728. align-items: center;
  729. padding: 18rpx 0;
  730. }
  731. .info-label {
  732. font-size: 28rpx;
  733. color: #999999;
  734. min-width: 200rpx;
  735. }
  736. .info-value {
  737. font-size: 28rpx;
  738. color: #333333;
  739. flex: 1;
  740. text-align: right;
  741. }
  742. .info-value.expired {
  743. color: #ff4444;
  744. font-weight: 600;
  745. }
  746. /* 提交按钮 */
  747. .submit-btn {
  748. margin: 40rpx 30rpx;
  749. background-color: #f8f8f8;
  750. border: 1rpx solid #e8e8e8;
  751. border-radius: 10rpx;
  752. font-size: 32rpx;
  753. color: #333333;
  754. padding: 24rpx 0;
  755. line-height: 1;
  756. font-weight: 500;
  757. }
  758. .submit-btn::after {
  759. border: none;
  760. }
  761. /* 商品信息 */
  762. .product-info {
  763. display: flex;
  764. align-items: center;
  765. gap: 16rpx;
  766. }
  767. .refund-amount {
  768. color: #ff4400;
  769. font-weight: 500;
  770. }
  771. /* 提示信息 */
  772. .tip-section {
  773. background-color: #fffbea;
  774. border: 1rpx solid #ffe58f;
  775. border-radius: 8rpx;
  776. padding: 24rpx 30rpx;
  777. margin: 30rpx;
  778. }
  779. .tip-text {
  780. display: block;
  781. font-size: 24rpx;
  782. color: #faad14;
  783. line-height: 1.8;
  784. }
  785. .selected-tip {
  786. text-align: right;
  787. font-size: 26rpx;
  788. color: #07c160;
  789. margin-top: 20rpx;
  790. padding: 16rpx 20rpx;
  791. background-color: #f6ffed;
  792. border-radius: 8rpx;
  793. font-weight: 500;
  794. }
  795. </style>