Browse Source

图片上传返回格式统一

zhouna 6 years ago
parent
commit
82365a70d9
1 changed files with 9 additions and 1 deletions
  1. 9 1
      src/components/icss/MedicineInfoPg.vue

+ 9 - 1
src/components/icss/MedicineInfoPg.vue

@@ -63,7 +63,15 @@
               },
               action: config.urls.promptServer,
               response: (res) => {
-                return config.imgHost+res.url;
+                if(res.code=='0'){
+                  return config.imgHost+res.data.url;
+                }else{
+                  this.$message({
+                    showClose: true,
+                    message: res.msg,
+                    type: 'warning'
+                  })
+                }
               }
             },
             toolbar: {