Procházet zdrojové kódy

修改基本信息

zs před 1 rokem
rodič
revize
c8ab7cb3c2
1 změnil soubory, kde provedl 11 přidání a 1 odebrání
  1. 11 1
      src/views/config/info/index.vue

+ 11 - 1
src/views/config/info/index.vue

@@ -20,6 +20,16 @@
                 @change="onUpload"
               ></cUpload>
             </template>
+            <template #logo_url="{ item }">
+              <cUpload
+                :model="item.model"
+                :limit="6"
+                url="/files/travel/config/upload"
+                :list="form[item.model]"
+                listType="picture-card"
+                @change="onUpload"
+              ></cUpload>
+            </template>
             <template #video="{ item }">
               <cUpload :model="item.model" :limit="6" url="/files/travel/config/upload" :list="form[item.model]" @change="onUpload"></cUpload>
             </template>
@@ -59,6 +69,7 @@ let fields: Ref<any[]> = ref([
   { label: '隐私政策', model: 'secret', type: 'textarea' },
   { label: '简介', model: 'brief', custom: true },
   { label: '图片', model: 'file', custom: true },
+  { label: '首页图片', model: 'logo_url', custom: true },
   { label: '视频', model: 'video', custom: true },
   { label: '底部文案', model: 'bottom_title' },
   { label: '状态', model: 'status', type: 'select' }
@@ -85,7 +96,6 @@ const onUpload = (e: { model: string; value: Array<[]> }) => {
 };
 const toSave = async (data: any) => {
   let res: IQueryResult;
-  console.log(data);
   if (data._id) res = await configAxios.update(data);
   else res = await configAxios.create(data);
   if (res.errcode == 0) {