Browse Source

手机求购bug处理

yangc 8 years ago
parent
commit
b4b8d6b96f

+ 3 - 1
components/applyPurchase/PublishApply.vue

@@ -226,6 +226,7 @@
               inquiry.enUU = this.user.data.enterprise.uu
             }
             let date = new Date()
+            let currency = this.applyObj.currency === '不限' ? null : this.applyObj.currency
             inquiry.recorderUU = this.user.data.userUU
             inquiry.code = 'MALL' + date.getTime()
             inquiry.date = date
@@ -240,7 +241,7 @@
             inquiryItem.userTel = this.user.data.userTel
             inquiryItem.needquantity = this.applyObj.amount
             inquiryItem.inbrand = this.applyObj.brand
-            inquiryItem.currency = this.applyObj.unitPrice ? this.applyObj.currency : null
+            inquiryItem.currency = currency
             inquiryItem.cmpCode = (this.applyObj.code).toUpperCase()
             inquiryItem.unitPrice = this.applyObj.unitPrice
             inquiryItem.produceDate = this.applyObj.produceDate
@@ -250,6 +251,7 @@
             let inquiryItems = []
             inquiryItems.push(inquiryItem)
             inquiry.inquiryItems = inquiryItems
+            inquiry.currency = currency
             this.$http.post('/inquiry/buyer/save', inquiry)
               .then(response => {
                 this.$message.success('发布成功')

+ 3 - 1
components/mobile/applyPurchase/PublishSeek.vue

@@ -167,6 +167,7 @@
           }
           let date = new Date()
           let endDate = formatDate(this.applyObj.deadline, 'yyyy-MM-dd hh:mm:ss')
+          let currency = this.applyObj.currency === '不限' ? null : this.applyObj.currency
           inquiry.recorderUU = this.user.data.userUU
           inquiry.code = 'MALL' + date.getTime()
           inquiry.date = date
@@ -181,7 +182,7 @@
           inquiryItem.userTel = this.user.data.userTel
           inquiryItem.needquantity = this.applyObj.amount
           inquiryItem.inbrand = this.applyObj.brand
-          inquiryItem.currency = this.applyObj.currency === '不限' ? null : this.applyObj.currency
+          inquiryItem.currency = currency
           inquiryItem.cmpCode = (this.applyObj.code).toUpperCase()
           inquiryItem.unitPrice = this.applyObj.unitPrice
           inquiryItem.produceDate = this.applyObj.produceDate
@@ -191,6 +192,7 @@
           let inquiryItems = []
           inquiryItems.push(inquiryItem)
           inquiry.inquiryItems = inquiryItems
+          inquiry.currency = currency
           this.$http.post('/inquiry/buyer/save', inquiry)
             .then(response => {
 //              this.$message.success('发布成功')

+ 3 - 0
components/mobile/applyPurchase/SayPrice.vue

@@ -19,6 +19,9 @@
           <div class="content-line">
             币种:<span>{{purchaseDetail.currency || '不限'}}</span>
           </div>
+          <div class="content-line">
+            生产日期:<span>{{purchaseDetail.produceDate || '-'}}</span>
+          </div>
           <div class="content-line">
             截止日期:<span>{{purchaseDetail.endDate | date}}</span>
           </div>

+ 6 - 0
components/mobile/applyPurchase/SayPriceInfo.vue

@@ -20,6 +20,9 @@
             <div class="content-line">
               币种:<span>{{purchaseDetail.currency || '不限'}}</span>
             </div>
+            <div class="content-line">
+              生产日期:<span>{{purchaseDetail.produceDate || '-'}}</span>
+            </div>
             <div class="content-line">
               截止日期:<span>{{purchaseDetail.endDate | date}}</span>
             </div>
@@ -80,6 +83,9 @@
             <div class="content-line">
               币种:<span>{{purchaseDetail.currency || '不限'}}</span>
             </div>
+            <div class="content-line">
+              生产日期:<span>{{purchaseDetail.produceDate || '-'}}</span>
+            </div>
             <div class="content-line">
               截止日期:<span>{{purchaseDetail.endDate | date}}</span>
             </div>

+ 8 - 1
components/mobile/common/LoginBox.vue

@@ -3,7 +3,7 @@
     <div class="mobile-modal-box">
       <div class="mobile-modal-header">请登录后再操作<i @click="close" class="icon-guanbi iconfont"></i></div>
       <div class="mobile-modal-content">
-        <span @click="close">暂不登录</span><span @click="goLogin">马上登录</span>
+        <span @click="onRegisterClick">立即注册</span><span @click="goLogin">马上登录</span>
       </div>
     </div>
   </div>
@@ -17,6 +17,13 @@
       },
       goLogin: function () {
         this.$router.push('/auth/login?returnUrl=' + window.location.href)
+      },
+      onRegisterClick () {
+        this.$http.get('/register/page').then(response => {
+          if (response.data) {
+            window.location.href = response.data.content
+          }
+        })
       }
     }
   }