Преглед на файлове

bugfix:处理套餐购买价格显示错误问题

leo преди 1 година
родител
ревизия
7358accb75
променени са 1 файла, в които са добавени 13 реда и са изтрити 10 реда
  1. 13 10
      pages/claimCloudPhone/components/setMealItem.vue

+ 13 - 10
pages/claimCloudPhone/components/setMealItem.vue

@@ -16,8 +16,12 @@
             <div class="invited-info">
               <div>{{ packageType[item.phoneType] }}{{ item.day }}天套餐</div>
               <div>
-                <div><span>¥</span>{{ item.actualPrice }}</div>
-                <div v-if="item.originalPrice"><span>¥</span>{{ item.originalPrice }}</div>
+                <div class="actual-price">
+                  <span>¥</span>{{ item.actualPrice }}
+                </div>
+                <div v-if="item.originalPrice" class="original-price">
+                  <span>¥</span>{{ item.originalPrice }}
+                </div>
               </div>
             </div>
           </div>
@@ -72,15 +76,14 @@ export default {
       },
     };
   },
-  mounted() {
-  },
+  mounted() {},
   methods: {
     add(data) {
       if (this.type) {
-        this.$router.push('/claimCloudPhone/1?menuRuleId=' + data.id)
-        return 
-      } 
-      this.$emit('buy', data)
+        this.$router.push('/claimCloudPhone/1?menuRuleId=' + data.id);
+        return;
+      }
+      this.$emit('buy', data);
     },
   },
 };
@@ -135,11 +138,11 @@ export default {
                 line-height: 20px;
                 font-style: normal;
               }
-              & > div:first-of-type {
+              .actual-price {
                 font-size: 16px;
                 color: #f04646;
               }
-              & > div:last-of-type {
+              .original-price {
                 font-size: 12px;
                 color: #bbbbbb;
                 line-height: 23px;