lilei 3 tháng trước cách đây
mục cha
commit
c3b4fdebec

+ 1 - 1
public/version.json

@@ -1,5 +1,5 @@
 {
   "message": "发现有新版本发布,确定更新系统?",
   "vendorJsVersion": "",
-  "version": 1742352345617
+  "version": 1742357396500
 }

+ 44 - 3
src/views/salesManagement/salesQueryNew/chooseProductModal.vue

@@ -64,9 +64,7 @@
             <a-col flex="2" v-if="$hasPermissions('B_salerVinFindProduct')&&sourceType !== 'TRANSFER_ORDER'">
               <a-form-model-item label="车架号(VIN)" prop="vinCode" class="vininputs">
                 <a-input id="productInfoList-vinCode" v-model.trim="queryParam.vinCode" allowClear placeholder="请输入车架号(VIN)">
-                  <a-upload slot="addonAfter" :before-upload="beforeUpload" listType="picture" accept="image/*" :showUploadList="false">
-                    <a-icon :type="vinLoading?'loading':'camera'" :style="{ fontSize: '18px', verticalAlign: 'bottom',cursor:'pointer',padding:'0 10px' }" title="拖动图片到这里识别VIN" />
-                  </a-upload>
+                  <a-icon slot="addonAfter" @click="showUploadImg=true" :type="vinLoading?'loading':'camera'" :style="{ fontSize: '18px', verticalAlign: 'bottom',cursor:'pointer',padding:'0 10px' }" title="点击拖动图片识别VIN" />
                 </a-input>
               </a-form-model-item>
             </a-col>
@@ -212,6 +210,28 @@
 
       <!-- 查看车辆信息 -->
       <car-info-modal ref="carInfoModal" :openModal="openCarInfoModal" :infoData="vinInfoData&&vinInfoData.carInfo" @close="openCarInfoModal=false" />
+      <!-- 上传图片弹窗 -->
+      <a-modal
+        v-model="showUploadImg"
+        class="uploadimg-modal"
+        title="上传图片识别VIN"
+        :footer="null"
+        centered
+        @ok="showUploadImg=false">
+        <a-upload-dragger :before-upload="beforeUpload" accept="image/*" :showUploadList="false">
+          <div class="ant-upload-box">
+            <p class="ant-upload-drag-icon">
+              <a-icon type="inbox" />
+            </p>
+            <p class="ant-upload-text">
+              单击或拖动文件到此区域进行上传
+            </p>
+            <p class="ant-upload-hint">
+              最多一张图片,支持JPG、PNG、BMP格式,最大50M。
+            </p>
+          </div>
+        </a-upload-dragger>
+      </a-modal>
     </a-spin>
   </a-drawer>
 </template>
@@ -283,6 +303,7 @@ export default {
       vinLoading: false, // vin识别loading
       productType: [], // 产品类型
       defImg, // 默认图片
+      showUploadImg: false, // 上传图片弹框
       queryParam: { //  查询条件
         customerSn: '', // 客户sn
         salesBillSn: '', // 销售单sn
@@ -575,6 +596,7 @@ export default {
               _this.queryParam.vinCode = obj.data || ''
               // 移除表单项的校验结果
               _this.$refs.ruleForm.clearValidate('vinCode')
+              _this.showUploadImg = false
             } else {
               _this.$notification.error({
                 message: '提示',
@@ -627,6 +649,25 @@ export default {
 </script>
 
 <style lang="less">
+.uploadimg-modal{
+  .ant-upload-box{
+    text-align: center;
+    width:100%;
+    .ant-upload-text {
+        margin: 0 0 4px;
+        color: rgba(0, 0, 0, .85);
+        font-size: 16px;
+    }
+    .ant-upload-hint {
+        color: rgba(0, 0, 0, .45);
+        font-size: 14px;
+    }
+    .ant-upload-drag-icon .anticon {
+        color: #40a9ff;
+        font-size: 48px;
+    }
+  }
+}
 .chooseProduct-drawer {
   .ant-drawer-header{
     padding: 13px 20px;