guhongwei há 4 anos atrás
pai
commit
b043eec282
1 ficheiros alterados com 6 adições e 12 exclusões
  1. 6 12
      src/views/info/base/auth.vue

+ 6 - 12
src/views/info/base/auth.vue

@@ -120,12 +120,11 @@ export default {
       handler(val) {
         if (val.ident_pics.length > 0) {
           val.ident_pics.map(item => {
-            console.log(item);
-
-            // let url = item.name.replace('/files', 'http://smart.cc-lotus.info/files');
-            // console.log(url);
-            let arr = item.name.split('.');
-            this.imgs[item.title] = item.name;
+            if (item.name.includes('yyzz')) {
+              this.imgs['yyzz'] = item.title;
+            } else if (item.name.includes('zzjgdm')) {
+              this.imgs['zzjgdm'] = item.title;
+            }
           });
         }
         this.$set(this, `identity`, val);
@@ -178,7 +177,7 @@ export default {
         if (key === 'logo_url') {
           this.identity.logo_url = this.imgs[key];
         } else {
-          arr.push({ name: this.imgs[key], title: key });
+          arr.push({ name: key, title: this.imgs[key] });
         }
       });
       this.identity.ident_pics = arr;
@@ -186,12 +185,7 @@ export default {
       this.$emit(`onSubmit`, { data: this.identity, type: 'identity' });
     },
     uploadSuccess({ type, data }) {
-      // if (type === 'logo_url') {
-      //   console.log(data);
-      //   this.$set(this.identity, type, data.uri);
-      // } else {
       this.imgs[type] = data.uri;
-      //}
     },
   },
 };