瀏覽代碼

fix: 志愿者管理

chenjj 1 月之前
父節點
當前提交
529781d6ec

+ 5 - 4
src/views/components/DialogForm/index.vue

@@ -57,10 +57,10 @@
             </template>
 
 
-            <el-form-item v-if="form.appStatus === 3" label="驳回原因" prop="rejectReason" :rules="{ required: true, message: '请输入驳回原因', trigger: 'blur' }">
+            <el-form-item v-if="form.appStatus === '3'" label="驳回原因" prop="rejectReason" :rules="{ required: true, message: '请输入驳回原因', trigger: 'blur' }">
                     <el-input v-model="form.rejectReason" type="textarea"
                     :autosize="{ minRows: 2, maxRows: 4 }"
-                     :placeholder="'请输入驳回原因'" clearable  :disabled="disables.appStatus"/>
+                     placeholder="请输入驳回原因" clearable  :disabled="disables.appStatus"/>
                 </el-form-item>
         </el-form>
         <template #footer>
@@ -95,7 +95,7 @@ const emit = defineEmits(['submit']);
 
 const dialogFormRef = ref(null);
 
-const disables = reactive({});
+const disables = ref({});
 
 
 const getImages = (key) => {
@@ -149,6 +149,7 @@ const submitForm = () => {
 }
 const cancel = () => {
     open.value = false;
+    disables.value = {};
     dialogFormRef.value.resetFields();
     console.log('cancel');
 }
@@ -158,7 +159,7 @@ const initForm = (data,disableData) => {
     console.log('initForm',data);
     form.value = data;
     if(disableData){
-        Object.assign(disables,disableData)
+        disables.value = disableData;
     }
 }
 

+ 5 - 1
src/views/components/ListPage/Table.vue

@@ -2,7 +2,7 @@
     <div class="app-container">
         <!-- 表格数据 -->
         <el-table v-loading="loading" :data="data" @selection-change="handleSelectionChange">
-            <el-table-column type="selection" width="55" align="center" />
+            <el-table-column type="selection" width="55" align="center" v-if="isSelect"/>
             <template v-for="item in column" :key="item.prop">
 
                 <el-table-column v-if="item.type === 'img'" :label="item.label" :prop="item.tableProp || item.prop"
@@ -83,6 +83,10 @@ const props = defineProps({
     tableKey: {
         type: String,
         default: 'id',
+    },
+    isSelect:{
+        type: Boolean,
+        default: true
     }
 })
 

+ 5 - 1
src/views/components/ListPage/index.vue

@@ -7,7 +7,7 @@
             <Search :column="searchColumn" @submit="searchSubmit" @reset="resetForm" :searchBtns="searchBtns"/>
         </div>
         <div class="table-div">
-            <Table :tableKey="tableKey" ref="tableRef" :column="tableColumn" :data="tableData.list" :loading="loading" :scopeBtns="scopeBtns" />
+            <Table :tableKey="tableKey" ref="tableRef" :column="tableColumn" :data="tableData.list" :loading="loading" :scopeBtns="scopeBtns" :isSelect="isSelect" />
         </div>
         <div class="pagination-div">
             <pagination v-show="tableData.total > 0" :total="tableData.total" v-model:page="queryParams.pageNum"
@@ -52,6 +52,10 @@ const props = defineProps({
     tabsearchKey:{
         type: String,
         default: ''
+    },
+    isSelect:{
+        type: Boolean,
+        default: true
     }
 })
 const tabsValue = ref('2')

+ 3 - 2
src/views/staff/volunteer/manage/index.vue

@@ -27,7 +27,8 @@ const listPageData = reactive({
             prop: 'createTime',
             type: 'date',
             isSearch: false,
-            keys: ['start', 'end']
+            keys: ['start', 'end'],
+            width: '180px'
         },
         {
             label: '姓名',
@@ -98,7 +99,7 @@ const listPageData = reactive({
         // },
     ],
     tableApi: list,//接口地址
-    isSelect: true,//是否勾选
+    isSelect: false,//是否勾选
     scopeBtns: [
         {
             label: '审核',