|
@@ -14,6 +14,7 @@ import { stringNotBlank } from "@/utils/blank-utils";
|
|
|
import ExportTrueExcel from "@/views/settings/scheduling-class/ExportTrueExcel.vue";
|
|
|
import { useCompShallowRef } from "@/utils/useCompRef";
|
|
|
import ExportFalseExcel from "@/views/settings/scheduling-class/ExportFalseExcel.vue";
|
|
|
+import { useUserStore } from "@/pinia/user-store";
|
|
|
|
|
|
const store = reactive({
|
|
|
codes: [],
|
|
@@ -27,6 +28,8 @@ const store = reactive({
|
|
|
},
|
|
|
});
|
|
|
|
|
|
+const show = useUserStore().userInfo.deptCode === "3100000";
|
|
|
+
|
|
|
const trueExcelRef = useCompShallowRef(ExportTrueExcel);
|
|
|
const falseExcelRef = useCompShallowRef(ExportFalseExcel);
|
|
|
|
|
@@ -66,7 +69,10 @@ function handleSelectChange(value) {
|
|
|
|
|
|
function createByMonth() {
|
|
|
const month = dayjs(store.currentCalendar).format("YYYY-MM");
|
|
|
- createByMonthApi(month);
|
|
|
+ createByMonthApi(month).then(() => {
|
|
|
+ store.months[month] = {};
|
|
|
+ handleGetByMonth();
|
|
|
+ });
|
|
|
}
|
|
|
|
|
|
function refresh() {
|
|
@@ -210,7 +216,7 @@ onMounted(async () => {
|
|
|
</script>
|
|
|
|
|
|
<template>
|
|
|
- <div class="layout_container">
|
|
|
+ <div class="layout_container" v-if="show">
|
|
|
<ExportTrueExcel ref="trueExcelRef" />
|
|
|
<ExportFalseExcel ref="falseExcelRef" :dept-list="store.codes" />
|
|
|
<header>
|