瀏覽代碼

no message

linwenxin 7 月之前
父節點
當前提交
1297375241

+ 6 - 18
src/packageAttachment/pages/applyReturnOfNewPiece/index.vue

@@ -15,21 +15,7 @@
             <view class="input_module_as">
               <view class="input_module_as_title"> *申请类别 </view>
               <view class="input_module_as_en">
-                <radio-group
-                  @change="
-                    d => {
-                      form.applyCategory = d.detail.value
-                    }
-                  "
-                >
-                  <label style="margin-right: 20upx">
-                    <radio value="HOME" :checked="form.applyCategory === 'HOME'" />家用空调
-                  </label>
-                  <label> <radio value="TRADE" :checked="form.applyCategory === 'TRADE'" />商用空调 </label>
-                  <br />
-                  <br />
-                  <label> <radio value="ELEC" :checked="form.applyCategory === 'ELEC'" />生活电器(小家电) </label>
-                </radio-group>
+                {{ { HOME: '家用空调', TRADE: '商用空调', ELEC: '生活电器(小家电)' }[form.applyCategory] }}
               </view>
             </view>
             <view class="input_module_as">
@@ -189,11 +175,13 @@ export default {
   },
   data() {
     return {
-      form: null
+      form: null,
+      applyCategory: null
     }
   },
   onLoad(option) {
-    var { salesId, pushFlag, identity } = option
+    var { salesId, pushFlag, identity, applyCategory } = option
+    this.applyCategory = applyCategory
     this.getDetails({
       salesId,
       pushFlag,
@@ -303,7 +291,7 @@ export default {
               item.quantity = item.qty
             })
           }
-          this.form = res.data
+          this.form = { ...res.data, applyCategory: this.applyCategory }
         })
         .catch(() => {})
     },

+ 2 - 2
src/packageAttachment/pages/orderOfSales/card.vue

@@ -53,12 +53,12 @@ export default {
   },
   methods: {
     toUrl() {
-      var { id, pushFlag, identity } = this.item
+      var { id, pushFlag, identity, applyCategory } = this.item
       if (this.type === 'entryStock') {
         this.$navToPage({
           url: `/packageAttachment/pages/applyReturnOfNewPiece/index?salesId=${id}&pushFlag=${
             pushFlag || ''
-          }&identity=${identity}`
+          }&identity=${identity}&applyCategory=${applyCategory}`
         })
       } else {
         this.$navToPage({

+ 3 - 3
src/packageMaterial/pages/newSale/order.vue

@@ -22,11 +22,11 @@
         <view class="form-container card">
           <view class="item">
             <view class="label">其他费用</view>
-            <u--input placeholder="请输入单价" inputAlign="right" v-model="otherPrice"></u--input>
+            <u--input placeholder="请输入金额" inputAlign="right" v-model="otherPrice"></u--input>
           </view>
           <view class="item">
             <view class="label">服务费用</view>
-            <u--input placeholder="请输入单价" inputAlign="right" v-model="servicePrice"></u--input>
+            <u--input placeholder="请输入金额" inputAlign="right" v-model="servicePrice"></u--input>
           </view>
           <view class="total">
             <view class="text">合计:</view>
@@ -106,7 +106,7 @@ export default {
     },
     totalPrice() {
       let val = 0;
-      this.goodsList.forEach(item => {
+      this.goodsList.filter(item=>item.repairFlag=='OUTSIDE').forEach(item => {
         val = val + (item.num * (item.goodsAmount * 100) / 100);
       })
       return  val;