orderPay.vue 19 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768
  1. <template>
  2. <view class="container">
  3. <view class="address-info-box" @click="selectAddress()">
  4. <view class="address-icon">
  5. <text class="iconfont icondizhi"></text>
  6. </view>
  7. <view class="address-content">
  8. <text class="address-info">
  9. <text class="address-name">{{addressData.username}}</text>
  10. <text class="address-phone">{{addressData.phone}}</text>
  11. </text>
  12. <view class="address-detail">{{addressData.address}}</view>
  13. </view>
  14. <view class="address-link">
  15. <text class="iconfont iconfangxiang"></text>
  16. </view>
  17. </view>
  18. <view class="goods-info-box">
  19. <view class="shop-info">
  20. <text class="iconfont icondianpu"></text>
  21. <text class="shop-name">{{orderData.supplierName}}</text>
  22. <text class="iconfont iconfangxiang"></text>
  23. </view>
  24. <view class="goods-list">
  25. <view class="goods-row" v-for="(item, index) in orderData.goodsList" :key="index">
  26. <image class="goods-img" mode="aspectFill" :src="item.imgUrl"></image>
  27. <view class="goods-info">
  28. <view class="goods-name">{{item.productName}}</view>
  29. <view class="goods-type">
  30. 类型:{{item.productType == 1 ? '普通商品' : (item.productType == 2 ? '拍卖商品' : (item.productType == 3 ? '自助采摘' : '共享种植'))}}
  31. </view>
  32. <view class="plant-area" v-if="orderType == 3">面积:{{orderData.areaSize}}㎡</view>
  33. <view class="goods-price-number">
  34. <text class="goods-unit">¥</text>
  35. <text class="goods-price">{{orderType == 1 ? item.bizPrice : paySum}}</text>
  36. <text class="goods-number">x{{item.buyNum}}</text>
  37. <text class="plant-text" v-if="orderType == 3">有效期:{{orderData.term}}天</text>
  38. </view>
  39. </view>
  40. </view>
  41. </view>
  42. <view class="order-info">
  43. <u-cell-group :border="false">
  44. <u-cell-item title="商品金额" :arrow="false" :border-bottom="false" title-width="170" :title-style="{textAlign: 'right'}">
  45. <text class="order-text-right">¥{{orderType == 1 ? getAllGoodsInitialPrice() : paySum}}</text>
  46. </u-cell-item>
  47. <u-cell-item title="积分抵扣" :arrow="false" :border-bottom="false" title-width="170" :title-style="{textAlign: 'right'}"
  48. v-if="orderType == 1">
  49. <view>
  50. <text class="order-text-left">-{{getIntegral()+'积分'}}</text>
  51. <text class="order-text-right">-¥{{(getIntegral()/100).toFixed(2)}}</text>
  52. </view>
  53. </u-cell-item>
  54. <u-cell-item title="优惠券" :border-bottom="false" title-width="170" :title-style="{textAlign: 'right'}" @click="showCoupon()"
  55. v-if="orderType == 1">
  56. <view>
  57. <text class="order-text-left">{{coupon.couponName}}</text>
  58. <text class="order-text-right">{{couponList.length ? ('-¥'+coupon.discountAmount) : '无可用优惠券'}}</text>
  59. </view>
  60. </u-cell-item>
  61. <u-field label="备注" v-model="notes" placeholder="请输入备注" :border-bottom="false" label-align="right" label-width="170"
  62. :field-style="{marginLeft: '16px'}"></u-field>
  63. </u-cell-group>
  64. </view>
  65. <view class="pay-info">
  66. <text class="pay-text">共{{getAllGoodsNumber()}}件</text>
  67. <text class="pay-text">总计</text>
  68. <text class="pay-price">¥{{orderType == 1 ? getAllGoodsPrice() : paySum}}</text>
  69. </view>
  70. </view>
  71. <view class="handle-box">
  72. <view class="handle-info">
  73. <text class="handle-text" style="margin-right: 12px;">共{{getAllGoodsNumber()}}件</text>
  74. <text class="handle-text">合计:</text>
  75. <text class="handle-price">¥{{orderType == 1 ? getAllGoodsPrice() : paySum}}</text>
  76. </view>
  77. <view class="handle-button" @click="submitOrder()">提交订单</view>
  78. </view>
  79. <uni-popup ref="popup" type="bottom">
  80. <view class="coupon-box">
  81. <view class="coupon-row" v-for="(item, index) in couponList" :key="index" @click="selectCoupon(item)">
  82. <view class="coupon-left">
  83. <view class="coupon-left-price"><text style="font-size: 16px;">¥</text>{{item.discountAmount}}</view>
  84. <view class="coupon-left-text">满减金额</view>
  85. </view>
  86. <view class="coupon-info">
  87. <view class="coupon-text1">{{item.couponName}}</view>
  88. <view class="coupon-text1" style="margin-bottom: 4px;">满{{item.fullAmount}}减{{item.discountAmount}}</view>
  89. <view class="coupon-text2">{{item.couponType == 1 ? '仅限用于' + item.supplierName + '的店铺' : ''}}</view>
  90. <view class="coupon-text2" style="color: #999999;">有效期:{{item.publishStartTime}}~{{item.useEndTime}}</view>
  91. </view>
  92. </view>
  93. </view>
  94. </uni-popup>
  95. <u-top-tips ref="uTips"></u-top-tips>
  96. </view>
  97. </template>
  98. <script>
  99. const NET = require('@/utils/request')
  100. const API = require('@/config/api')
  101. export default {
  102. data() {
  103. return {
  104. flag: 1,
  105. orderType: 1,
  106. addressData: {
  107. memberAddressId: '',
  108. username: '',
  109. phone: '',
  110. province: '',
  111. city: '',
  112. area: '',
  113. address: '',
  114. },
  115. userData: {},
  116. orderData: {
  117. tenantCode: '',
  118. supplierName: '',
  119. areaSize: '',
  120. term: '',
  121. goodsList: []
  122. },
  123. integral: 0,
  124. coupon: {
  125. couponId: '',
  126. couponName: '',
  127. discountAmount: 0,
  128. couponType: '',
  129. },
  130. couponList: [],
  131. notes: '',
  132. paySum: 0,
  133. mineIntegral: {},
  134. orderId: ''
  135. }
  136. },
  137. onLoad(options) {
  138. this.orderType = options.orderType
  139. this.paySum = options.paySum ? options.paySum : 0
  140. this.flag = options.flag
  141. this.userData = uni.getStorageSync("userData")
  142. this.orderData = uni.getStorageSync("orderData")
  143. if (!uni.getStorageSync("defaultAddress")) {
  144. NET.request(API.getAddressList, {}, 'POST').then(res => {
  145. if (res.data.find(site => site.isDefault == 1)) {
  146. let address = res.data.find(site => site.isDefault == 1)
  147. this.addressData = {
  148. memberAddressId: address.id,
  149. username: address.username,
  150. phone: address.phone,
  151. province: address.province,
  152. city: address.city,
  153. area: address.area,
  154. address: address.address
  155. }
  156. }
  157. }).catch(error => {
  158. this.$refs.uTips.show({
  159. title: '获取默认地址失败',
  160. type: 'warning',
  161. })
  162. })
  163. }
  164. if (this.orderType == 1) {
  165. NET.request(API.getIntegral, {}, 'POST').then(res => {
  166. this.integral = res.data.usableIntegral
  167. }).catch(error => {
  168. this.$refs.uTips.show({
  169. title: '获取个人积分失败',
  170. type: 'warning',
  171. })
  172. })
  173. NET.request(API.getUsableCouponList, {
  174. tenantCode: this.orderData.tenantCode,
  175. totalPrice: this.getAllGoodsInitialPrice(),
  176. }, 'GET').then(res => {
  177. this.couponList = res.data
  178. }).catch(error => {
  179. this.$refs.uTips.show({
  180. title: res.msg,
  181. type: 'warning',
  182. })
  183. })
  184. }
  185. },
  186. onShow() {
  187. if (uni.getStorageSync("defaultAddress")) {
  188. this.addressData = uni.getStorageSync("defaultAddress")
  189. }
  190. },
  191. methods: {
  192. // 获取全部商品原价格
  193. getAllGoodsInitialPrice() {
  194. let price = this.orderData.goodsList.reduce((total, site) => {
  195. return total + site.bizPrice * site.buyNum
  196. }, 0)
  197. return price.toFixed(2)
  198. },
  199. // 获取全部价格
  200. getAllGoodsPrice() {
  201. let price = this.orderData.goodsList.reduce((total, site) => {
  202. return total + site.bizPrice * site.buyNum
  203. }, 0)
  204. return (price - this.coupon.discountAmount - (this.getIntegral() / 100)).toFixed(2)
  205. },
  206. // 获取全部商品数量
  207. getAllGoodsNumber() {
  208. let number = this.orderData.goodsList.reduce((total, site) => {
  209. return total + site.buyNum
  210. }, 0)
  211. return number
  212. },
  213. // 选择地址
  214. selectAddress() {
  215. uni.navigateTo({
  216. url: '/pagesMain/addressList?type=2'
  217. });
  218. },
  219. // 获取积分
  220. getIntegral() {
  221. let price = this.orderData.goodsList.reduce((total, site) => {
  222. return total + site.bizPrice * site.buyNum
  223. }, 0) - this.coupon.discountAmount
  224. if (this.integral / 100 > price) {
  225. return price * 100
  226. } else {
  227. return this.integral
  228. }
  229. },
  230. // 显示优惠券弹窗
  231. showCoupon() {
  232. if (!this.couponList.length) {
  233. return
  234. }
  235. this.$refs.popup.open()
  236. },
  237. // 选择优惠券
  238. selectCoupon(item) {
  239. this.coupon = {
  240. couponId: item.couponId,
  241. couponName: item.couponName,
  242. discountAmount: parseFloat(item.discountAmount).toFixed(2),
  243. couponType: item.couponType,
  244. }
  245. this.$refs.popup.close()
  246. },
  247. // 提交订单
  248. submitOrder() {
  249. if (!this.addressData.username) {
  250. this.$refs.uTips.show({
  251. title: '请选择地址',
  252. type: 'warning',
  253. })
  254. } else {
  255. let paySum = this.orderType == 1 ? this.getAllGoodsPrice() : this.paySum
  256. NET.request(API.submitOrder, {
  257. // 会员
  258. mid: this.userData.userId,
  259. nickname: this.userData.userName,
  260. // 地址
  261. ...this.addressData,
  262. // 商铺
  263. supplierName: this.orderData.supplierName,
  264. tenantCode: this.orderData.tenantCode,
  265. // 商品
  266. productIds: this.orderData.goodsList.map(site => {
  267. return site.productId
  268. }).join(','),
  269. productType: this.orderData.goodsList.map(site => {
  270. return site.productType
  271. }).join(','),
  272. products: this.orderData.goodsList.map(site => {
  273. return {
  274. ...site,
  275. supplierName: this.orderData.supplierName,
  276. tenantCode: this.orderData.tenantCode,
  277. bizPrice: this.orderType == 1 ? site.bizPrice : this.paySum,
  278. }
  279. }),
  280. // 优惠券
  281. couponId: this.orderType == 1 ? this.coupon.couponId : '',
  282. couponDiscountAmount: this.orderType == 1 ? this.coupon.discountAmount : '',
  283. couponType: this.orderType == 1 ? this.coupon.couponType : '',
  284. // 积分
  285. integralValue: this.orderType == 1 ? this.getIntegral() : 0,
  286. integralAmount: this.orderType == 1 ? this.getIntegral() / 100 : 0,
  287. // 金额
  288. discountAmount: this.orderType == 1 ? (parseFloat(this.coupon.discountAmount) + (this.getIntegral() / 100)) : 0,
  289. orderSum: this.orderType == 1 ? this.orderData.goodsList.reduce((total, site) => {
  290. return total + site.bizPrice * site.buyNum
  291. }, 0) : this.paySum,
  292. paySum: this.orderType == 1 ? this.getAllGoodsPrice() : this.paySum,
  293. // 支付类型
  294. flag: this.flag,
  295. orderType: this.orderType,
  296. // 备注
  297. notes: this.notes,
  298. }, 'POST').then(res => {
  299. if (res.isSuccess) {
  300. if (res.data) {
  301. this.orderId = res.data.orderId
  302. debugger
  303. if (paySum == '0.00') {
  304. this.$refs.uTips.show({
  305. title: '购买成功',
  306. type: 'success',
  307. })
  308. setTimeout(() => {
  309. uni.redirectTo({
  310. url: '/pagesMain/orderDetail?orderId=' + this.orderId + '&orderStatus=' + 1
  311. });
  312. }, 1000)
  313. return;
  314. }
  315. uni.requestPayment({
  316. provider: 'wxpay',
  317. timeStamp: res.data.timeStamp,
  318. nonceStr: res.data.nonceStr,
  319. package: res.data.packageValue,
  320. signType: res.data.signType,
  321. paySign: res.data.paySign,
  322. success: (payRes) => {
  323. console.log('success:' + JSON.stringify(payRes));
  324. uni.redirectTo({
  325. url: '/pagesMain/paySuccess?orderId=' + this.orderId
  326. });
  327. },
  328. fail: (error) => {
  329. console.log('fail:' + JSON.stringify(error));
  330. this.$refs.uTips.show({
  331. title: '支付未成功',
  332. type: 'warning',
  333. })
  334. setTimeout(() => {
  335. uni.redirectTo({
  336. url: '/pagesMain/orderDetail?orderId=' + this.orderId + '&orderStatus=' + 1
  337. });
  338. }, 1000)
  339. }
  340. })
  341. } else {
  342. uni.redirectTo({
  343. url: '/pagesMain/paySuccess'
  344. });
  345. }
  346. }
  347. }).catch(error => {
  348. console.log('error提交订单失败:', error);
  349. this.$refs.uTips.show({
  350. title: error.data.msg,
  351. type: 'warning',
  352. })
  353. })
  354. }
  355. },
  356. },
  357. }
  358. </script>
  359. <style lang="less" scoped>
  360. page {
  361. width: 100%;
  362. height: 100%;
  363. }
  364. .container {
  365. width: 100%;
  366. // height: 100%; // 100%不行,屏幕长时底下有留白
  367. height: 100vh;
  368. float: left;
  369. background-color: #f7f7f7;
  370. box-sizing: border-box;
  371. padding-bottom: 70px;
  372. overflow-y: auto;
  373. .address-info-box {
  374. width: calc(100% - 32px);
  375. float: left;
  376. box-sizing: border-box;
  377. padding: 16px 18px 16px 16px;
  378. margin: 10px 16px;
  379. background: #FFFFFF;
  380. border-radius: 10px;
  381. .address-icon {
  382. width: 36px;
  383. height: 40px;
  384. float: left;
  385. align-items: center;
  386. display: flex;
  387. .iconfont {
  388. color: #52A63A;
  389. font-size: 36px;
  390. }
  391. }
  392. .address-content {
  393. width: calc(100% - 66px);
  394. height: 40px;
  395. float: left;
  396. margin: 0 8px 0 12px;
  397. .address-info {
  398. height: 20px;
  399. font-family: PingFang SC;
  400. line-height: 20px;
  401. overflow: hidden;
  402. text-overflow: ellipsis;
  403. white-space: nowrap;
  404. .address-name {
  405. font-size: 16px;
  406. color: #333333;
  407. margin-right: 14px;
  408. }
  409. .address-phone {
  410. font-size: 12px;
  411. color: #666666;
  412. }
  413. }
  414. .address-detail {
  415. height: 20px;
  416. font-size: 16px;
  417. font-family: PingFang SC;
  418. color: #333333;
  419. line-height: 20px;
  420. overflow: hidden;
  421. text-overflow: ellipsis;
  422. white-space: nowrap;
  423. }
  424. }
  425. .address-link {
  426. width: 10px;
  427. height: 40px;
  428. float: left;
  429. align-items: center;
  430. display: flex;
  431. .iconfont {
  432. color: #999999;
  433. font-size: 12px;
  434. }
  435. }
  436. }
  437. .goods-info-box {
  438. width: calc(100% - 32px);
  439. float: left;
  440. margin: 0 16px 10px 16px;
  441. background: #FFFFFF;
  442. border-radius: 10px;
  443. .shop-info {
  444. width: 100%;
  445. height: 48px;
  446. float: left;
  447. box-sizing: border-box;
  448. padding: 13px 15px 12px 15px;
  449. border-bottom: 1px solid #EEEEEE;
  450. line-height: 22px;
  451. .icondianpu {
  452. font-size: 22px;
  453. color: #333333;
  454. }
  455. .shop-name {
  456. font-size: 15px;
  457. font-family: PingFang SC;
  458. color: #333333;
  459. margin: 0 8px 0 10px;
  460. }
  461. .iconshangjia {
  462. font-size: 12px;
  463. color: #999999;
  464. }
  465. }
  466. .goods-list {
  467. width: 100%;
  468. float: left;
  469. box-sizing: border-box;
  470. padding: 10px 15px 0 15px;
  471. .goods-row {
  472. width: 100%;
  473. height: 90px;
  474. float: left;
  475. display: flex;
  476. margin-bottom: 10px;
  477. .goods-img {
  478. width: 90px;
  479. height: 90px;
  480. border-radius: 5px;
  481. object-fit: cover;
  482. }
  483. .goods-info {
  484. width: calc(100% - 106px);
  485. height: 90px;
  486. margin-left: 16px;
  487. .goods-name {
  488. width: 100%;
  489. height: 36px;
  490. float: left;
  491. font-size: 14px;
  492. font-family: PingFang SC;
  493. color: #333333;
  494. line-height: 18px;
  495. overflow: hidden;
  496. text-overflow: ellipsis;
  497. display: -webkit-box;
  498. -webkit-line-clamp: 2;
  499. -webkit-box-orient: vertical;
  500. word-wrap: break-word;
  501. }
  502. .goods-type {
  503. height: 20px;
  504. float: left;
  505. background: #F0F0F0;
  506. border-radius: 4px;
  507. padding: 0 8px;
  508. margin: 6px 0;
  509. font-size: 10px;
  510. font-family: PingFang SC;
  511. color: #666666;
  512. line-height: 20px;
  513. }
  514. .plant-area {
  515. height: 20px;
  516. float: right;
  517. margin: 6px 0;
  518. font-size: 12px;
  519. font-family: PingFang SC;
  520. color: #333333;
  521. }
  522. .goods-price-number {
  523. width: 100%;
  524. height: 20px;
  525. float: left;
  526. line-height: 20px;
  527. font-family: PingFang SC;
  528. color: #333333;
  529. .goods-unit {
  530. font-size: 12px;
  531. }
  532. .goods-price {
  533. font-size: 15px;
  534. margin-right: 6px;
  535. }
  536. .goods-number {
  537. font-size: 12px;
  538. }
  539. }
  540. .plant-text {
  541. float: right;
  542. font-size: 12px;
  543. font-family: PingFang SC;
  544. color: #333333;
  545. }
  546. }
  547. }
  548. }
  549. .order-info {
  550. width: 100%;
  551. float: left;
  552. .order-text-left {
  553. font-size: 13px;
  554. font-family: PingFang SC;
  555. color: #666666;
  556. float: left;
  557. margin-left: 16px;
  558. }
  559. .order-text-right {
  560. font-size: 13px;
  561. font-family: PingFang SC;
  562. color: #52A63A;
  563. }
  564. /deep/.u-cell_title {
  565. color: #333333;
  566. }
  567. /deep/.u-label-text {
  568. color: #333333;
  569. }
  570. }
  571. .pay-info {
  572. width: 100%;
  573. height: 46px;
  574. float: left;
  575. box-sizing: border-box;
  576. border-top: 1px solid #EEEEEE;
  577. padding-right: 15px;
  578. line-height: 44px;
  579. font-family: PingFang SC;
  580. font-size: 14px;
  581. text-align: right;
  582. white-space: nowrap;
  583. .pay-text {
  584. color: #333333;
  585. margin-right: 6px;
  586. }
  587. .pay-price {
  588. color: #52A63A;
  589. }
  590. }
  591. }
  592. .handle-box {
  593. width: 100%;
  594. height: 70px;
  595. box-sizing: border-box;
  596. padding: 15px 0 15px 16px;
  597. position: fixed;
  598. bottom: 0;
  599. background: #FFFFFF;
  600. box-shadow: 0px 3px 13px 0px rgba(0, 0, 0, 0.15);
  601. .handle-info {
  602. width: calc(100% - 110px);
  603. height: 40px;
  604. float: left;
  605. line-height: 40px;
  606. font-family: PingFang SC;
  607. text-align: left;
  608. white-space: nowrap;
  609. .handle-text {
  610. font-size: 16px;
  611. color: #666666;
  612. }
  613. .handle-price {
  614. font-size: 15px;
  615. color: #52A63A;
  616. }
  617. }
  618. .handle-button {
  619. width: 100px;
  620. height: 40px;
  621. float: right;
  622. box-sizing: border-box;
  623. padding-left: 10px;
  624. background: #52A63A;
  625. border-radius: 20px 0px 0px 20px;
  626. font-size: 15px;
  627. font-family: PingFang SC;
  628. color: #FFFFFF;
  629. line-height: 40px;
  630. text-align: center;
  631. }
  632. }
  633. .coupon-box {
  634. width: 100vw;
  635. height: 500px;
  636. background-color: #FFFFFF;
  637. border-radius: 15px 15px 0px 0px;
  638. box-sizing: border-box;
  639. padding: 16px 16px 0 16px;
  640. overflow-y: auto;
  641. .coupon-row {
  642. width: 100%;
  643. height: 105px;
  644. float: left;
  645. margin-bottom: 10px;
  646. border-radius: 10px;
  647. background: #FFFFFF;
  648. box-shadow: 0px 0px 10px 0px rgba(103, 103, 103, 0.3);
  649. overflow: hidden;
  650. .coupon-left {
  651. width: 107px;
  652. height: 105px;
  653. box-sizing: border-box;
  654. padding-right: 10px;
  655. float: left;
  656. background-size: 107px 105px;
  657. background-position: center;
  658. background-repeat: no-repeat;
  659. background-image: url(@/static/images/couponHead.png);
  660. .coupon-left-price {
  661. width: 100%;
  662. height: 24px;
  663. float: left;
  664. margin: 28px 0 12px 0;
  665. font-size: 24px;
  666. font-family: PingFang SC;
  667. color: #FFFFFF;
  668. line-height: 24px;
  669. text-align: center;
  670. }
  671. .coupon-left-text {
  672. width: 100%;
  673. height: 20px;
  674. float: left;
  675. color: #FFFFFF;
  676. font-size: 12px;
  677. font-family: PingFang SC;
  678. line-height: 20px;
  679. text-align: center;
  680. }
  681. }
  682. .coupon-info {
  683. width: calc(100% - 115px);
  684. height: 100%;
  685. float: right;
  686. box-sizing: border-box;
  687. padding: 16px 0 12px 0;
  688. .coupon-text1 {
  689. width: 100%;
  690. height: 20px;
  691. float: right;
  692. font-size: 15px;
  693. font-family: PingFang SC;
  694. color: #333333;
  695. line-height: 20px;
  696. white-space: nowrap;
  697. text-overflow: ellipsis;
  698. overflow: hidden;
  699. }
  700. .coupon-text2 {
  701. width: 100%;
  702. height: 18px;
  703. float: right;
  704. font-size: 13px;
  705. font-family: PingFang SC;
  706. color: #EB5F2F;
  707. line-height: 18px;
  708. white-space: nowrap;
  709. text-overflow: ellipsis;
  710. overflow: hidden;
  711. }
  712. }
  713. }
  714. }
  715. }
  716. </style>