zhangjie 1 жил өмнө
parent
commit
e39e839817

+ 1 - 0
src/assets/style/base.less

@@ -116,6 +116,7 @@
 // empty-none
 .empty-none {
   text-align: center;
+  padding: 10px 0;
 }
 
 /* table */

+ 2 - 1
src/components/select-agent/index.vue

@@ -6,6 +6,7 @@
     :disabled="disabled"
     :options="optionList"
     filter-option
+    popup-container="body"
     v-bind="attrs"
     @change="onChange"
   >
@@ -59,7 +60,7 @@
             selected.value && (selected.value as number[]).includes(item.value)
         )
       : optionList.value.filter((item) => selected.value === item.value);
-    emit('update:modelValue', selected.value);
+    emit('update:modelValue', selected.value || null);
     emit('change', props.multiple ? selectedData : selectedData[0]);
   };
 

+ 2 - 1
src/components/select-task/index.vue

@@ -6,6 +6,7 @@
     :disabled="disabled"
     :options="optionList"
     filter-option
+    popup-container="body"
     v-bind="attrs"
     @change="onChange"
   >
@@ -57,7 +58,7 @@
             selected.value && (selected.value as number[]).includes(item.value)
         )
       : optionList.value.filter((item) => selected.value === item.value);
-    emit('update:modelValue', selected.value);
+    emit('update:modelValue', selected.value || null);
     emit('change', props.multiple ? selectedData : selectedData[0]);
   };
 

+ 6 - 2
src/components/select-teaching/index.vue

@@ -6,10 +6,13 @@
     :disabled="disabled"
     :options="optionList"
     filter-option
+    popup-container="body"
     v-bind="attrs"
     @change="onChange"
   >
-    <template v-if="prefix" #prefix>教学点</template>
+    <template v-if="prefix || prefixStr" #prefix>{{
+      prefixStr || '教学点'
+    }}</template>
   </a-select>
 </template>
 
@@ -30,6 +33,7 @@
     placeholder?: string;
     multiple?: boolean;
     prefix?: boolean;
+    prefixStr?: string;
   }>();
   const emit = defineEmits(['update:modelValue', 'change']);
   const attrs = useAttrs();
@@ -58,7 +62,7 @@
             selected.value && (selected.value as number[]).includes(item.value)
         )
       : optionList.value.filter((item) => selected.value === item.value);
-    emit('update:modelValue', selected.value);
+    emit('update:modelValue', selected.value || null);
     emit('change', props.multiple ? selectedData : selectedData[0]);
   };
 

+ 2 - 1
src/utils/day.ts

@@ -1,5 +1,6 @@
 import dayjs from 'dayjs';
 
 export function getBeforeWeek() {
-  return [dayjs().add(-1, 'week').valueOf(), dayjs().valueOf()];
+  const now = dayjs().format('YYYY-MM-DD HH:mm');
+  return [dayjs(now).add(-1, 'week').valueOf(), dayjs(now).valueOf()];
 }

+ 1 - 0
src/views/base/agent-manage/index.vue

@@ -14,6 +14,7 @@
         v-model="searchModel.enable"
         placeholder="请选择"
         allow-clear
+        popup-container="body"
         :options="ableOptions"
       >
         <template #prefix>状态</template>

+ 3 - 0
src/views/base/agent-manage/modifyAgent.vue

@@ -16,6 +16,7 @@
           v-model.trim="formData.name"
           placeholder="请输入"
           allow-clear
+          :max-length="50"
         ></a-input>
       </a-form-item>
       <a-form-item field="code" label="考点代码">
@@ -23,6 +24,7 @@
           v-model.trim="formData.code"
           placeholder="请输入"
           allow-clear
+          :max-length="50"
         ></a-input>
       </a-form-item>
       <a-form-item field="address" label="考点地址">
@@ -30,6 +32,7 @@
           v-model.trim="formData.address"
           placeholder="请输入"
           allow-clear
+          :max-length="100"
         ></a-input>
       </a-form-item>
       <a-form-item field="teachingId" label="教学点">

+ 1 - 0
src/views/base/room-manage/index.vue

@@ -21,6 +21,7 @@
         v-model="searchModel.enable"
         placeholder="请选择"
         allow-clear
+        popup-container="body"
         :options="ableOptions"
       >
         <template #prefix>状态</template>

+ 3 - 0
src/views/base/room-manage/modifyRoom.vue

@@ -16,6 +16,7 @@
           v-model.trim="formData.name"
           placeholder="请输入"
           allow-clear
+          :max-length="50"
         ></a-input>
       </a-form-item>
       <a-form-item field="code" label="考场代码">
@@ -23,6 +24,7 @@
           v-model.trim="formData.code"
           placeholder="请输入"
           allow-clear
+          :max-length="50"
         ></a-input>
       </a-form-item>
       <a-form-item field="address" label="考场地址">
@@ -30,6 +32,7 @@
           v-model.trim="formData.address"
           placeholder="请输入"
           allow-clear
+          :max-length="100"
         ></a-input>
       </a-form-item>
       <a-form-item field="capacity" label="机房容量">

+ 1 - 0
src/views/base/teaching-manage/index.vue

@@ -12,6 +12,7 @@
         placeholder="请选择"
         allow-clear
         :options="ableOptions"
+        popup-container="body"
       >
         <template #prefix>状态</template>
       </a-select>

+ 3 - 0
src/views/base/teaching-manage/modifyTeaching.vue

@@ -16,6 +16,7 @@
           v-model.trim="formData.name"
           placeholder="请输入"
           allow-clear
+          :max-length="50"
         ></a-input>
       </a-form-item>
       <a-form-item field="code" label="教学点代码">
@@ -23,6 +24,7 @@
           v-model.trim="formData.code"
           placeholder="请输入"
           allow-clear
+          :max-length="50"
         ></a-input>
       </a-form-item>
       <a-form-item field="capacity" label="容量">
@@ -41,6 +43,7 @@
           placeholder="请选择"
           filter-option
           allow-clear
+          popup-container="body"
           :options="[]"
         >
         </a-select>

+ 7 - 2
src/views/order/order-record-manage/index.vue

@@ -11,7 +11,7 @@
         v-model="searchModel.teachingId"
         placeholder="请选择"
         allow-clear
-        prefix
+        prefix-str="所约教学点"
       />
       <SelectAgent
         v-model="searchModel.agentId"
@@ -173,10 +173,15 @@
       width: 160,
     },
     {
-      title: '教学点',
+      title: '"所属教学点',
       dataIndex: 'teachingName',
       width: 200,
     },
+    {
+      title: '所约教学点',
+      dataIndex: 'applyTeachingName',
+      width: 200,
+    },
     {
       title: '考点',
       dataIndex: 'agentName',

+ 5 - 1
src/views/order/order-record-manage/printDialog.vue

@@ -33,6 +33,7 @@
           :allow-clear="false"
           :options="optionList"
           filter-option
+          popup-container="body"
         >
         </a-select>
       </a-form-item>
@@ -92,6 +93,8 @@
 
   const optionList = ref<Options[]>([]);
   async function getTimes() {
+    if (optionList.value.length) return;
+
     const res = await orderRecordPrintTimeListPage();
     optionList.value = (res || []).map((item) => {
       return {
@@ -100,7 +103,6 @@
       };
     });
   }
-  getTimes();
 
   /* confirm */
   const { loading, setLoading } = useLoading();
@@ -122,6 +124,8 @@
   }
   /* init modal */
   function modalBeforeOpen() {
+    getTimes();
+
     objModifyAssign(formData, defaultFormData);
     nextTick(() => {
       formRef.value?.clearValidate();

+ 1 - 0
src/views/order/task-manage/ruleForm.vue

@@ -6,6 +6,7 @@
           v-model.trim="formData.name"
           placeholder="请输入"
           allow-clear
+          :max-length="50"
         ></a-input>
       </a-form-item>
       <a-form-item field="allowApplyCancelDays" label="学生自主操作限制">