lex 2 سال پیش
والد
کامیت
522e53fc48

+ 1 - 1
src/school/approval-manage/batch-adjust.tsx

@@ -167,7 +167,7 @@ export default defineComponent({
             type="number"
             v-model={forms.adjustDay}
             placeholder="请输入调整天数"
-            v-slots={{ extra: () => '天' }}
+            v-slots={{ extra: () => <span style={{ paddingLeft: '6px' }}>天</span> }}
           />
         </CellGroup>
 

+ 10 - 7
src/school/approval-manage/course-adjust.tsx

@@ -1,5 +1,5 @@
 import OHeader from '@/components/o-header'
-import { CellGroup, Cell, Button, showToast, Field, Tag } from 'vant'
+import { CellGroup, Cell, Button, showToast, Field, Tag, showSuccessToast } from 'vant'
 import { defineComponent, reactive, ref, onMounted } from 'vue'
 import { postMessage } from '@/helpers/native-message'
 import styles from './course-adjust.module.less'
@@ -144,13 +144,16 @@ export default defineComponent({
         })
         reset()
         setTimeout(() => {
-          showToast('调整成功')
-          if (browser().isApp) {
-            postMessage({ api: 'back' })
-          } else {
-            router.back()
-          }
+          showSuccessToast('调整成功')
+          // if (browser().isApp) {
+          //   postMessage({ api: 'back' })
+          // } else {
+
+          // }
         }, 100)
+        setTimeout(() => {
+          router.back()
+        }, 1100)
       } catch (e: any) {
         showToast(e.message)
       }

+ 39 - 0
src/school/companion-teacher/companion-teacher-register.module.less

@@ -238,3 +238,42 @@ span {
   color: #f67146;
   padding: 9px 10px;
 }
+
+.wxPopupDialog {
+  // position: relative;
+  overflow: initial;
+  // margin-top: -160px;
+  &::before {
+    position: absolute;
+    content: ' ';
+    top: -73px;
+    left: 50%;
+    margin-left: -86px;
+    display: inline-block;
+    background: url('../../student/music-group/pre-apply/images/wx-no-top.png') no-repeat top center;
+    background-size: contain;
+    width: 172px;
+    height: 154px;
+  }
+}
+.popupContainer {
+  background: url('../../student/music-group/pre-apply/images/wx-no-bg.png') no-repeat top center !important;
+  background-size: cover;
+  border-radius: 20px;
+  overflow: hidden;
+  .title1 {
+    padding-top: 57px;
+    text-align: center;
+    font-size: 18px;
+    font-weight: 500;
+    color: #3b2300;
+  }
+  .popupTips {
+    padding-top: 12px;
+    padding-bottom: 47px;
+    text-align: center;
+    font-size: 15px;
+    color: #777777;
+    line-height: 21px;
+  }
+}

+ 22 - 1
src/school/companion-teacher/companion-teacher-register.tsx

@@ -29,6 +29,7 @@ import { checkPhone } from '@/helpers/validate'
 import OUpload from '@/components/o-upload'
 import router from '@/router'
 import dayjs from 'dayjs'
+import { browser } from '@/helpers/utils'
 
 export default defineComponent({
   name: 'companion-teacher-register',
@@ -71,7 +72,8 @@ export default defineComponent({
       countDownStatus: true, // 是否发送验证码
       countDownTime: 120, // 倒计时时间
       countDownRef: null as any, // 倒计时实例
-      imgCodeStatus: false
+      imgCodeStatus: false,
+      showPopup: false
     })
 
     const onSubmit = async () => {
@@ -190,6 +192,12 @@ export default defineComponent({
         showToast('信息获取失败,请联系老师')
       }
 
+      // 判断是否是微信,只能微信中打开
+      // if (!browser().weixin) {
+      //   state.showPopup = true
+      //   return
+      // }
+
       // t: route.query.t, // 过期时间
       try {
         if (state.t) {
@@ -624,6 +632,19 @@ export default defineComponent({
             onSendCode={onCodeSend}
           />
         ) : null}
+
+        <Popup
+          v-model:show={state.showPopup}
+          round
+          style={{ width: '88%' }}
+          closeOnClickOverlay={false}
+          class={styles.wxPopupDialog}
+        >
+          <div class={styles.popupContainer}>
+            <p class={styles.title1}>温馨提示</p>
+            <p class={styles.popupTips}>请使用微信打开</p>
+          </div>
+        </Popup>
       </div>
     )
   }

+ 39 - 0
src/school/manage-teacher/manage-teacher-register.module.less

@@ -239,3 +239,42 @@ span {
   color: #f67146;
   padding: 9px 10px;
 }
+
+.wxPopupDialog {
+  // position: relative;
+  overflow: initial;
+  // margin-top: -160px;
+  &::before {
+    position: absolute;
+    content: ' ';
+    top: -73px;
+    left: 50%;
+    margin-left: -86px;
+    display: inline-block;
+    background: url('../../student/music-group/pre-apply/images/wx-no-top.png') no-repeat top center;
+    background-size: contain;
+    width: 172px;
+    height: 154px;
+  }
+}
+.popupContainer {
+  background: url('../../student/music-group/pre-apply/images/wx-no-bg.png') no-repeat top center !important;
+  background-size: cover;
+  border-radius: 20px;
+  overflow: hidden;
+  .title1 {
+    padding-top: 57px;
+    text-align: center;
+    font-size: 18px;
+    font-weight: 500;
+    color: #3b2300;
+  }
+  .popupTips {
+    padding-top: 12px;
+    padding-bottom: 47px;
+    text-align: center;
+    font-size: 15px;
+    color: #777777;
+    line-height: 21px;
+  }
+}

+ 22 - 1
src/school/manage-teacher/manage-teacher-register.tsx

@@ -27,6 +27,7 @@ import iconClose from './images/icon-close.png'
 import topBanner1 from './images/top-banner.png'
 import { checkPhone } from '@/helpers/validate'
 import dayjs from 'dayjs'
+import { browser } from '@/helpers/utils'
 
 export default defineComponent({
   name: 'companion-teacher-register',
@@ -58,7 +59,8 @@ export default defineComponent({
       countDownStatus: true, // 是否发送验证码
       countDownTime: 120, // 倒计时时间
       // countDownRef: null as any, // 倒计时实例
-      imgCodeStatus: false
+      imgCodeStatus: false,
+      showPopup: false
     })
 
     const onSubmit = async () => {
@@ -119,6 +121,12 @@ export default defineComponent({
         showToast('信息获取失败,请联系老师')
       }
 
+      // 判断是否是微信,只能微信中打开
+      // if (!browser().weixin) {
+      //   state.showPopup = true
+      //   return
+      // }
+
       try {
         if (state.t) {
           const { data } = await request.get('/api-school/open/paramConfig/queryByParamName', {
@@ -396,6 +404,19 @@ export default defineComponent({
             onSendCode={onCodeSend}
           />
         ) : null}
+
+        <Popup
+          v-model:show={state.showPopup}
+          round
+          style={{ width: '88%' }}
+          closeOnClickOverlay={false}
+          class={styles.wxPopupDialog}
+        >
+          <div class={styles.popupContainer}>
+            <p class={styles.title1}>温馨提示</p>
+            <p class={styles.popupTips}>请使用微信打开</p>
+          </div>
+        </Popup>
       </div>
     )
   }

+ 2 - 2
src/school/orchestra/create-orchestra/index.tsx

@@ -78,7 +78,7 @@ export default defineComponent({
             temps.push({
               id: item.subjectId,
               name: item.subjectName,
-              code: item.code,
+              subjectCode: item.subjectCode,
               type: null,
               teacher: {}, // 老师信息
               students: [] as any // 选中的数据数
@@ -121,7 +121,7 @@ export default defineComponent({
       state.selectSubjects.forEach((item: any) => {
         console.log(item, 'item.name')
         tempStudents.push(...item.students)
-        if (item.code !== 'BARITONE' && item.code !== 'TUBA') {
+        if (item.subjectCode !== 'BARITONE' && item.subjectCode !== 'TUBA') {
           tempSelect.push(item)
         } else {
           // 获取学生

+ 6 - 2
src/school/train-planning/component/practice-detail/index.tsx

@@ -201,8 +201,12 @@ export default defineComponent({
                 formatter={onFormatterInt}
                 maxlength={3}
                 type="tel"
+                onUpdate:modelValue={(val: any) => {
+                  console.log(val)
+                  item.startTime = null
+                }}
               >
-                {{ extra: () => '分钟' }}
+                {{ extra: () => <span style={{ paddingLeft: '6px' }}>分钟</span> }}
               </Field>
               <Field
                 label="开始时间"
@@ -229,7 +233,7 @@ export default defineComponent({
                 maxlength={2}
                 type="tel"
               >
-                {{ extra: () => '课时' }}
+                {{ extra: () => <span style={{ paddingLeft: '6px' }}>课时</span> }}
               </Field>
               <Cell
                 title="训练班级"

+ 2 - 0
src/school/train-planning/component/practice/index.tsx

@@ -63,6 +63,8 @@ export default defineComponent({
     // }
 
     const onSubmit = () => {
+      showToast('请选择课程类型')
+      return
       // 判断是否有班级没有设置伴学指导
       if (forms.classList.length > 0) {
         forms.status = true

+ 6 - 4
src/student/music-group/goods-detail/index.tsx

@@ -7,6 +7,10 @@ import styles from './index.module.less'
 export default defineComponent({
   name: 'goods-detail',
   props: {
+    groupPrice: {
+      type: Number,
+      default: 0
+    },
     id: {
       type: String,
       defualt: ''
@@ -182,11 +186,9 @@ export default defineComponent({
                 <div class={styles.priceGroup}>
                   <span class={styles.price}>
                     <i>¥</i>
-                    {moneyFormat(this.getPrice)}
+                    {moneyFormat(this.groupPrice)}
                   </span>
-                  {/* <del class={styles.delPrice}>
-                    ¥{moneyFormat(product.originalPrice)}
-                  </del> */}
+                  <del class={styles.delPrice}>¥{moneyFormat(product.originalPrice)}</del>
                 </div>
               )
               // default: () => <div class={styles.stock}>销量4件</div>

+ 7 - 2
src/student/music-group/pre-apply/component/payment.tsx

@@ -45,7 +45,8 @@ export default defineComponent({
       },
       memberBaoStatus: false, // 团练宝详情状态
       goodsStatus: false, //
-      selectGoodsId: null as any
+      selectGoodsId: null as any,
+      currentPrice: 0
     })
 
     // 查询未支付订单
@@ -329,6 +330,7 @@ export default defineComponent({
                           onClick={(e: any) => {
                             e.stopPropagation()
                             state.selectGoodsId = state.goodsInfo.goodsId
+                            state.currentPrice = state.goodsInfo.currentPrice
                             state.goodsStatus = true
                           }}
                         />
@@ -425,6 +427,7 @@ export default defineComponent({
                           onClick={(e: any) => {
                             e.stopPropagation()
                             state.selectGoodsId = state.textBookInfo.goodsId
+                            state.currentPrice = state.textBookInfo.currentPrice
                             state.goodsStatus = true
                           }}
                         />
@@ -593,7 +596,9 @@ export default defineComponent({
         </OPopup>
 
         <OPopup v-model:modelValue={state.goodsStatus} position="right" destroy>
-          {state.goodsStatus && <GoodsDetail id={state.selectGoodsId} />}
+          {state.goodsStatus && (
+            <GoodsDetail id={state.selectGoodsId} groupPrice={state.currentPrice} />
+          )}
         </OPopup>
       </>
     )

+ 7 - 2
src/student/music-group/pre-apply/order-detail.tsx

@@ -39,7 +39,8 @@ export default defineComponent({
       authShow: false, // 是否进行实名认证
       memberBaoStatus: false, // 团练宝详情状态
       goodsStatus: false, //
-      selectGoodsId: null as any
+      selectGoodsId: null as any,
+      currentPrice: 0
     })
 
     const orderType = computed(() => {
@@ -391,7 +392,9 @@ export default defineComponent({
                   center
                   onClick={() => {
                     if (goods.goodsType === 'INSTRUMENTS' || goods.goodsType === 'TEXTBOOK') {
+                      console.log(goods)
                       state.selectGoodsId = goods.goodsId
+                      state.currentPrice = goods.currentPrice
                       state.goodsStatus = true
                     } else if (goods.goodsType === 'VIP') {
                       state.memberBaoStatus = true
@@ -552,7 +555,9 @@ export default defineComponent({
         </OPopup>
 
         <OPopup v-model:modelValue={state.goodsStatus} position="right" destroy>
-          {state.goodsStatus && <GoodsDetail id={state.selectGoodsId} />}
+          {state.goodsStatus && (
+            <GoodsDetail id={state.selectGoodsId} groupPrice={state.currentPrice} />
+          )}
         </OPopup>
       </>
     )

BIN
src/student/payment-result/images/icon_close.png


BIN
src/student/payment-result/images/icon_refunded.png


BIN
src/student/payment-result/images/icon_refunding.png


BIN
src/student/payment-result/images/icon_success.png


BIN
src/student/payment-result/images/icon_tradeing.png


+ 19 - 14
src/student/payment-result/index.module.less

@@ -1,43 +1,48 @@
 .paymentTitle {
-  min-height: 136px;
-  background: linear-gradient(180deg, #ffe4d4 0%, #ffffff 100%);
+  min-height: 177px;
+  background: linear-gradient(180deg, #f67146 0%, #ff8057 100%);
+  border-radius: 0px 0px 8px 8px;
 
   .orderType {
     padding-top: 35px;
     display: flex;
     align-items: center;
     justify-content: center;
+    color: #fff;
     .img {
-      width: 36px;
-      height: 36px;
-      margin-right: 10px;
+      width: 52px;
+      height: 52px;
+      margin-right: 14px;
     }
 
     span {
       font-size: 22px;
       font-weight: 500;
-      color: #1a1a1a;
       line-height: 30px;
     }
   }
 
   .orderPrice {
-    padding-bottom: 22px;
-    padding-top: 15px;
-    color: #333333;
+    padding-top: 2px;
     font-size: 22px;
     text-align: center;
-
-    span {
-      font-size: 16px;
-      line-height: 22px;
-    }
+    font-size: 14px;
   }
 }
 
+.mTop {
+  margin-top: -52px !important;
+}
+
 .cellGroup {
   margin: 10px 13px;
 
+  .brandName {
+    line-height: 18px;
+    font-size: 12px;
+    padding: 0 6px;
+    border-radius: 4px;
+  }
   :global {
     .van-cell {
       padding: 16px 17px;

+ 39 - 10
src/student/payment-result/index.tsx

@@ -2,7 +2,6 @@ import OHeader from '@/components/o-header'
 import { defineComponent, onMounted, reactive } from 'vue'
 import { Button, Cell, CellGroup, Image, showConfirmDialog, Tag } from 'vant'
 import styles from './index.module.less'
-import iconRefunded from './images/icon_refunded.png'
 import iconRefunding from './images/icon_refunding.png'
 import icon_success from './images/icon_success.png'
 import iconClose from './images/icon_close.png'
@@ -30,6 +29,7 @@ export default defineComponent({
         )
 
         state.orders = data || {}
+        // state.orders.status = 'REFUNDED'
         const tempGoods = data.goodsInfos || []
         tempGoods.forEach((item: any) => {
           const img = item.goodsUrl ? item.goodsUrl.split(',')[0] : ''
@@ -63,11 +63,25 @@ export default defineComponent({
         FAIL: iconClose,
         CLOSED: iconClose,
         REFUNDING: iconRefunding,
-        REFUNDED: iconRefunded
+        REFUNDED: icon_success
       }
       return template[type] || icon_success
     }
 
+    const formatOrderStatus = (status: string) => {
+      const temp = {
+        WAIT_PAY: '支付中',
+        PAYING: '支付中',
+        PAID: '支付成功',
+        TIMEOUT: '订单超时',
+        FAIL: '支付失败',
+        CLOSED: '订单关闭',
+        REFUNDING: '退款中',
+        REFUNDED: '已退款'
+      }
+      return temp[status]
+    }
+
     onMounted(() => {
       getDetails()
       useEventListener(document, 'scroll', () => {
@@ -88,17 +102,28 @@ export default defineComponent({
             <>
               <div class={styles.orderType}>
                 <Image class={styles.img} src={formatImg(state.orders.status)} />
-                <span>{orderStatus[state.orders.status]}</span>
-              </div>
-              <div class={styles.orderPrice}>
-                <span>¥</span>
-                {moneyFormat(state.orders.paymentCashAmount)}
+                <div class={styles.orderInfo}>
+                  <span>{formatOrderStatus(state.orders.status)}</span>
+                  {state.orders.status === 'PAID' || state.orders.status === 'REFUNDING' ? (
+                    <div class={styles.orderPrice}>
+                      实付金额:¥{moneyFormat(state.orders.paymentCashAmount)}
+                    </div>
+                  ) : (
+                    ''
+                  )}
+
+                  {state.orders.status === 'REFUNDED' && (
+                    <div class={styles.orderPrice}>
+                      退款金额:¥{moneyFormat(state.orders.paymentCashAmount)}
+                    </div>
+                  )}
+                </div>
               </div>
             </>
           )}
         </div>
 
-        <CellGroup inset class={styles.cellGroup}>
+        <CellGroup inset class={[styles.cellGroup, styles.mTop]}>
           <Cell>
             {{ title: () => '付款时间', value: () => <span>{state.orders.payTime || '--'}</span> }}
           </Cell>
@@ -112,13 +137,17 @@ export default defineComponent({
             <i></i> 购买详情
           </div>
           {state.goodsInfos.map((goods: any) => (
-            <Cell center>
+            <Cell>
               {{
                 icon: () => <Image class={styles.buyImg} src={goods.goodsUrl} />,
                 title: () => (
                   <div class={styles.buyContent}>
                     <p class={styles.goodsTitle}>{goods.goodsName}</p>
-                    <Tag color="#EEEEEE" textColor="#666666">
+                    <Tag
+                      color="linear-gradient(135deg, #FF8C4A 0%, #FF531C 100%)"
+                      textColor="#fff"
+                      class={styles.brandName}
+                    >
                       {goods.brandName}
                     </Tag>
                   </div>