huangxw 1 개월 전
부모
커밋
be7913e280
1개의 변경된 파일13개의 추가작업 그리고 15개의 파일을 삭제
  1. 13 15
      src/views/skill/group/public-notice/input.vue

+ 13 - 15
src/views/skill/group/public-notice/input.vue

@@ -2,7 +2,8 @@
     <div class="p-3">
         <div class="bg-fff flex1 ov-hd d-flex flex-cln">
             <div class="d-flex a-c pd-16 border-bottom">
-                <div class="f-s-20 c-333 f-w-7 mr-10">{{ form.id ? '编辑' : '新增' }}{{ selectDictLabel(new_type, form.newsType) }}</div>
+                <div class="f-s-20 c-333 f-w-7 mr-10">{{ form.id ? '编辑' : '新增' }}{{ selectDictLabel(new_type,
+                    form.newsType) }}</div>
                 <el-button @click="router.go(-1)" type="primary" text>
                     <el-icon>
                         <Back />
@@ -11,7 +12,8 @@
                 </el-button>
             </div>
             <div class="flex1 over-auto">
-                <el-form ref="formRef" label-width="auto" label-position="top" :model="form" :rules="rules" :disabled="disable">
+                <el-form ref="formRef" label-width="auto" label-position="top" :model="form" :rules="rules"
+                    :disabled="disable">
                     <div class="pd-16 border-bottom ov-hd">
                         <el-row :gutter="80">
                             <el-col :span="8">
@@ -34,11 +36,11 @@
                             </el-col>
                         </el-row>
                         <el-row>
-                            <el-col :span="8" v-if="form.newsType !== '15'">
+                            <!-- <el-col :span="8" v-if="form.newsType !== '15'">
                                 <el-form-item label="封面图" prop="newsImg">
                                     <imageUpload v-model="form.newsImg" :limit="1" isString :isShowTip="false"></imageUpload>
                                 </el-form-item>
-                            </el-col>
+                            </el-col> -->
                             <el-col :span="24">
                                 <el-form-item label="文章内容" prop="newsContent">
                                     <div class="flex1">
@@ -52,7 +54,8 @@
                             <el-col :span="24">
                                 <el-form-item label="管理办法附件" :prop="form.extraInfo ? 'extraInfo.accessory' : ''">
                                     <div class="flex1">
-                                        <FileUpload v-model="form.extraInfo.accessory" format="array" :fileSize="100" :span="8" :limit="100"></FileUpload>
+                                        <FileUpload v-model="form.extraInfo.accessory" format="array" :fileSize="100"
+                                            :span="8" :limit="100"></FileUpload>
                                     </div>
                                 </el-form-item>
                             </el-col>
@@ -88,7 +91,7 @@ const form = ref<any>({
     newsContent: '',
     newsImg: '',
     publishTime: '',
-    newsOrigin: '',
+    newsOrigin: '秘书处',
     newsType: '',
     extraInfo: {
         accessory: [],
@@ -107,15 +110,10 @@ const save = debounce(async () => {
     await formRef.value.validate();
     const res = form.value.id ? await editNews(form.value) : await addNews(form.value);
     if (res && res.code === 200) {
-        if (['29', '30', '31'].includes(form.value.newsType)) {
-            ElMessage({
-                message: '提交成功',
-                type: 'success',
-            })
-        } else {
-            router.go(-1);
-        }
-
+        ElMessage({
+            message: '提交成功',
+            type: 'success',
+        })
     }
 }, 500);