Browse Source

修改样式

lex-xin 2 months ago
parent
commit
d2783e55e1

+ 11 - 0
miniprogram/pages/address/index.less

@@ -6,6 +6,17 @@
   background: #F5F6F7;
 
   --popup-round-border-radius: 20rpx !important;
+  position: relative;
+
+  &::before {
+    content: '';
+    position: absolute;
+    top: 0;
+    left: 0;
+    right: 0;
+    height: 254rpx;
+    background: linear-gradient(180deg, #FDEC00 0%, #FAD400 100%);
+  }
 }
 
 .record-list {

+ 9 - 0
miniprogram/pages/orders/order-detail.less

@@ -429,6 +429,15 @@ page {
   .users {
     font-size: 32rpx;
     color: #777;
+    display: flex;
+
+    .username{
+      display: inline-block;
+      max-width: 250rpx;
+      white-space: nowrap;
+      overflow: hidden;
+      text-overflow: ellipsis;
+    }
 
     text {
       color: #131415;

+ 1 - 1
miniprogram/pages/orders/order-detail.wxml

@@ -66,7 +66,7 @@
 
       <view class="buyUsers" wx:if="{{ userBeneficiaryId && goodsInfo.orderNo }}">
         <view class="users">
-          <text>{{ userBeneficiaryInfo.name }}</text>{{ userBeneficiaryInfo.phoneNumber }}
+          <text class="username">{{ userBeneficiaryInfo.name }}</text>{{ userBeneficiaryInfo.phoneNumber }}
         </view>
         <view class="detail">{{userBeneficiaryInfo.schoolInfo}}</view>
 

+ 4 - 4
miniprogram/pages/orders/order-result.ts

@@ -130,12 +130,12 @@ Page({
       return ''
     }
     const template: any = {
-      DAY: "天",
-      MONTH: "月",
-      YEAR: "年"
+      DAY: "天",
+      MONTH: "月",
+      YEAR: "年"
     }
     if (type === "YEAR" && num >= 99) {
-      return '永久'
+      return '永久'
     }
     return num + template[type]
   },

+ 3 - 0
miniprogram/pages/select-goods/index.less

@@ -419,6 +419,9 @@
     font-size: 36rpx;
     box-sizing: border-box;
   }
+  button[disabled] {
+    opacity: 0.7;
+  }
 
   .btn-prices {
     font-size: 32rpx;

+ 4 - 0
miniprogram/pages/select-goods/index.ts

@@ -21,6 +21,7 @@ Page({
       typeName: '',
       showSalePrice: '', // 显示的现价
       originalPrice: 0, // 原价
+      showOriginalPrice: '', // 显示的原价
       salePrice: 0, // 现价
       discountPrice: '' // 已省
     } as any, // 格式化所有选中的数据
@@ -181,6 +182,7 @@ Page({
       typeName: '',
       showSalePrice: '' as any, // 显示的现价
       originalPrice: 0, // 原价
+      showOriginalPrice: '' as any, // 显示的原价
       salePrice: 0, // 现价
       discountPrice: '' as any, // 已省
       integerPart: '',
@@ -191,6 +193,7 @@ Page({
       params.typeName = selected.typeName
       params.showSalePrice = selected.showSalePrice
       params.originalPrice = selected.originalPrice
+      params.showOriginalPrice = formatPrice(Number(selected.originalPrice || 0), 'ALL')
       params.salePrice = selected.salePrice
       params.discountPrice = selected.discountPrice
 
@@ -202,6 +205,7 @@ Page({
     if (selectedInstrument.id) {
       params.typeName = selected.typeName ? selected.typeName + '+' + selectedInstrument.name : selectedInstrument.name
       params.originalPrice = Number(selected.originalPrice) + Number(selectedInstrument.originalPrice)
+      params.showOriginalPrice = formatPrice(Number(selected.originalPrice) + Number(selectedInstrument.originalPrice), 'ALL')
       params.salePrice = Number(selected.salePrice) + Number(selectedInstrument.salePrice)
       params.showSalePrice = formatPrice(params.salePrice, "ALL");
       params.discountPrice = formatPrice(

+ 5 - 5
miniprogram/pages/select-goods/index.wxml

@@ -8,17 +8,17 @@
     <view class="select-good-img">
       <image src="{{ selected.pic }}"></image>
     </view>
-    <view class="good-info">
+    <view class="good-info" wx:if="{{ selected.id }}">
       <view class="good-name">{{ selected.name }}</view>
       <view class="good-price">
         <!-- <view class="desc">共计</view> -->
         <view class="currentPrice">
           <text class="stuff">¥</text>
-          <text class="priceZ">{{ formatSelectGood.integerPart }}</text>
-          <text class="priceF">.{{ formatSelectGood.decimalPart }}</text>
+          <text class="priceZ">{{ selected.integerPart }}</text>
+          <text class="priceF">.{{ selected.decimalPart }}</text>
         </view>
         <text class="line"></text>
-        <text class="discountPrice">优惠前 ¥{{ formatSelectGood.originalPrice }}</text>
+        <text class="discountPrice">优惠前 ¥{{ selected.originalPrice }}</text>
       </view>
 
       <!-- <image class="img_back" bind:tap="onBack" src="./images/icon-back.png"></image> -->
@@ -107,7 +107,7 @@
         <text>¥ {{ formatSelectGood.showSalePrice }}</text>
       </view>
       <view class="btnGroup">
-        <button type="primary" catch:tap="onSubmit">
+        <button type="primary" catch:tap="onSubmit" disabled="{{ isOverSaled }}">
           <view class="btn-prices">
             立即支付<text class="stuff">¥</text>
             <text class="priceZ">{{ formatSelectGood.integerPart || 0 }}</text>