From bf9eb65fa140bc588cf58c8317e3a668268f495a Mon Sep 17 00:00:00 2001
From: dy <dingyang@lnfxkj.tech>
Date: 星期三, 23 四月 2025 10:45:48 +0800
Subject: [PATCH] Merge branch 'dev' of http://192.168.50.149:8085/r/aps-kj-web into dev

---
 .env.staging                           |    6 
 .env.development                       |    5 
 package.json                           |    4 
 .env.production                        |    5 
 src/views/basicData/calendar/index.vue |  596 ++++++++++++++++++++++++++++++++++++++++++------
 vite.config.js                         |   91 +++++--
 6 files changed, 591 insertions(+), 116 deletions(-)

diff --git a/.env.development b/.env.development
index 77d95a3..1b0343a 100644
--- a/.env.development
+++ b/.env.development
@@ -6,7 +6,8 @@
 
 # 鑻ヤ緷绠$悊绯荤粺/寮�鍙戠幆澧�
 VITE_APP_BASE_API = '/dev-api'
-
+VITE_API_URL = 'http://192.168.50.86:8080'
 # 鏍囪瘑鏈湴寮�鍙戞湇鍔★紝鐢ㄤ簬GateWay杞彂鍒版湰鍦版湇鍔�
 # 閰嶅悎鍚庣鏈嶅姟
-VITE_APP_LOCAL = 'int'
\ No newline at end of file
+# VITE_APP_LOCAL = 'int'
+VITE_APP_LOCAL = 'hjy'
diff --git a/.env.production b/.env.production
index 79b1f0a..7d77f07 100644
--- a/.env.production
+++ b/.env.production
@@ -12,4 +12,7 @@
 
 # 鏍囪瘑鏈湴寮�鍙戞湇鍔★紝鐢ㄤ簬GateWay杞彂鍒版湰鍦版湇鍔�
 # 閰嶅悎鍚庣鏈嶅姟
-VITE_APP_LOCAL = 'int'
\ No newline at end of file
+VITE_APP_LOCAL = 'int'
+
+# 椤甸潰鏍囬
+VITE_APP_TITLE = APS
diff --git a/.env.staging b/.env.staging
index b11336d..8e63f4e 100644
--- a/.env.staging
+++ b/.env.staging
@@ -6,6 +6,8 @@
 
 # 鑻ヤ緷绠$悊绯荤粺/鐢熶骇鐜
 VITE_APP_BASE_API = '/stage-api'
-
+VITE_API_URL = 'http://192.168.50.160:8080'
+VITE_APP_LOCAL = 'int'
 # 鏄惁鍦ㄦ墦鍖呮椂寮�鍚帇缂╋紝鏀寔 gzip 鍜� brotli
-VITE_BUILD_COMPRESS = gzip
\ No newline at end of file
+VITE_BUILD_COMPRESS = gzip
+
diff --git a/package.json b/package.json
index 870dd54..5e4665e 100644
--- a/package.json
+++ b/package.json
@@ -7,7 +7,9 @@
   "type": "module",
   "scripts": {
     "dev": "vite",
-    "build:prod": "vite build",
+    "dev:stage":"vite --mode staging",
+    "build:prod": "vite build --mode production",
+    "build:dev": "vite build --mode development",
     "build:stage": "vite build --mode staging",
     "preview": "vite preview"
   },
diff --git a/src/views/basicData/calendar/index.vue b/src/views/basicData/calendar/index.vue
index bb3b016..cdaef87 100644
--- a/src/views/basicData/calendar/index.vue
+++ b/src/views/basicData/calendar/index.vue
@@ -1,37 +1,78 @@
 <template>
   <div class="app-container">
-    <el-form :model="queryParams" ref="queryRef" :inline="true" v-show="showSearch" label-width="68px">
-      <el-form-item label="鎻忚堪" prop="description">
-        <el-input
-          v-model="queryParams.description"
-          placeholder="璇疯緭鍏ユ弿杩�"
-          clearable
-          @keyup.enter="handleQuery"
-        />
-      </el-form-item>
-      <el-form-item label="鏃ュ巻鐢熸晥鏃ユ湡" prop="effectiveDate">
-        <el-date-picker clearable
-          v-model="queryParams.effectiveDate"
-          type="date"
-          value-format="YYYY-MM-DD"
-          placeholder="璇烽�夋嫨鏃ュ巻鐢熸晥鏃ユ湡">
-        </el-date-picker>
-      </el-form-item>
-      <el-form-item label="澶辨晥鏃ユ湡" prop="expiringDate">
-        <el-date-picker clearable
+    <el-form
+      class="responsive-form"
+      :model="queryParams"
+      ref="queryRef"
+      :inline="true"
+      v-show="showSearch"
+      label-width="68px"
+    >
+      <el-row type="flex" justify="right">
+        <el-form-item label="鏃ュ巻鎻忚堪" prop="description">
+          <el-input
+            style="width: 140px"
+            v-model="queryParams.description"
+            placeholder="璇疯緭鍏ユ弿杩板叧閿瘝"
+            clearable
+            @keyup.enter="handleQuery"
+          />
+        </el-form-item>
+        <el-form-item label="鏃ュ巻绫诲瀷" prop="effectiveDate">
+          <el-select clearable v-model="dateType" style="width: 90px">
+            <el-option
+              v-for="(item, index) of dateTypeList"
+              :key="index"
+              :label="item.name"
+              :value="item.name"
+              >{{ item.name }}</el-option
+            >
+          </el-select>
+        </el-form-item>
+        <el-form-item label="鐢熸晥鏃ユ湡" prop="effectiveDate">
+          <el-date-picker
+            clearable
+            v-model="queryParams.effectiveDate"
+            type="date"
+            value-format="YYYY-MM-DD"
+            placeholder="閫夋嫨鏃ユ湡"
+          >
+          </el-date-picker>
+        </el-form-item>
+        <el-form-item label="閫傜敤宸ュ巶" prop="expiringDate">
+          <!-- <el-date-picker clearable
           v-model="queryParams.expiringDate"
           type="date"
           value-format="YYYY-MM-DD"
           placeholder="璇烽�夋嫨澶辨晥鏃ユ湡">
-        </el-date-picker>
-      </el-form-item>
-      <el-form-item>
-        <el-button type="primary" icon="Search" @click="handleQuery">鎼滅储</el-button>
-        <el-button icon="Refresh" @click="resetQuery">閲嶇疆</el-button>
-      </el-form-item>
+        </el-date-picker> -->
+          <el-input
+            style="width: 180px"
+            v-model="queryParams.description"
+            placeholder="璇疯緭鍏ュ伐鍘傚叧閿瘝"
+            clearable
+            @keyup.enter="handleQuery"
+          />
+        </el-form-item>
+      </el-row>
+      <el-row type="flex" justify="end">
+        <el-form-item class="column-with-margin">
+          <el-button type="primary" icon="Search" @click="handleQuery"
+            >鏌ヨ</el-button
+          >
+          <el-button icon="Refresh" @click="resetQuery">閲嶇疆</el-button>
+          <el-button
+            type="success"
+            icon="Plus"
+            @click="handleAdd"
+            v-hasPermi="['core:calendar:add']"
+            >鏂板鏃ュ巻</el-button
+          >
+        </el-form-item>
+      </el-row>
     </el-form>
 
-    <el-row :gutter="10" class="mb8">
+    <!-- <el-row :gutter="10" class="mb8">
       <el-col :span="1.5">
         <el-button
           type="primary"
@@ -39,7 +80,8 @@
           icon="Plus"
           @click="handleAdd"
           v-hasPermi="['core:calendar:add']"
-        >鏂板</el-button>
+          >鏂板</el-button
+        >
       </el-col>
       <el-col :span="1.5">
         <el-button
@@ -49,7 +91,8 @@
           :disabled="single"
           @click="handleUpdate"
           v-hasPermi="['core:calendar:edit']"
-        >淇敼</el-button>
+          >淇敼</el-button
+        >
       </el-col>
       <el-col :span="1.5">
         <el-button
@@ -59,7 +102,8 @@
           :disabled="multiple"
           @click="handleDelete"
           v-hasPermi="['core:calendar:remove']"
-        >鍒犻櫎</el-button>
+          >鍒犻櫎</el-button
+        >
       </el-col>
       <el-col :span="1.5">
         <el-button
@@ -68,40 +112,101 @@
           icon="Download"
           @click="handleExport"
           v-hasPermi="['core:calendar:export']"
-        >瀵煎嚭</el-button>
+          >瀵煎嚭</el-button
+        >
       </el-col>
-      <right-toolbar v-model:showSearch="showSearch" @queryTable="getList"></right-toolbar>
-    </el-row>
+      <right-toolbar
+        v-model:showSearch="showSearch"
+        @queryTable="getList"
+      ></right-toolbar>
+    </el-row> -->
 
-    <el-table v-loading="loading" :data="calendarList" @selection-change="handleSelectionChange">
-      <el-table-column type="selection" width="55" align="center" />
-      <el-table-column label="${comment}" align="center" prop="id" />
-      <el-table-column label="鎻忚堪" align="center" prop="description" />
-      <el-table-column label="绫诲瀷锛屽懆宸ヤ綔/鑺傚亣鏃�" align="center" prop="type" />
-      <el-table-column label="鏃ュ巻鐢熸晥鏃ユ湡" align="center" prop="effectiveDate" width="180">
+    <el-table
+      v-loading="loading"
+      :data="calendarList"
+      @selection-change="handleSelectionChange"
+    >
+      <!-- <el-table-column type="selection" width="55" align="center" /> -->
+      <!-- <el-table-column label="${comment}" align="center" prop="id" /> -->
+      <el-table-column label="鏃ュ巻鎻忚堪" align="center" prop="description" />
+      <el-table-column label="鏃ュ巻绫诲瀷" align="center" prop="type">
         <template #default="scope">
-          <span>{{ parseTime(scope.row.effectiveDate, '{y}-{m}-{d}') }}</span>
+          <!-- <dict-tag :options="sys_normal_disable" :value="scope.row.status" /> -->
+          <el-tag
+          :type="scope.row.type === '1' ? '' : 'success'"
+          disable-transitions
+          >{{ scope.row.type }}</el-tag
+        >
         </template>
       </el-table-column>
-      <el-table-column label="澶辨晥鏃ユ湡" align="center" prop="expiringDate" width="180">
+      <el-table-column
+        label="鏃ュ巻鐢熸晥鏃堕棿"
+        align="center"
+        prop="effectiveDate"
+        width="180"
+      >
         <template #default="scope">
-          <span>{{ parseTime(scope.row.expiringDate, '{y}-{m}-{d}') }}</span>
+          <span>{{ parseTime(scope.row.effectiveDate, "{y}-{m}-{d}") }}</span>
+        </template>
+      </el-table-column>
+      <el-table-column
+        label="鏃ュ巻澶辨晥鏃堕棿"
+        align="center"
+        prop="expiringDate"
+        width="180"
+      >
+        <template #default="scope">
+          <span>{{ parseTime(scope.row.expiringDate, "{y}-{m}-{d}") }}</span>
         </template>
       </el-table-column>
       <el-table-column label="鏃ュ巻鍐呭" align="center" prop="content" />
-      <el-table-column label="閫傜敤宸ュ巶" align="center" prop="applicableFactory" />
-      <el-table-column label="閫傜敤杞﹂棿" align="center" prop="applicableWorkshop" />
-      <el-table-column label="閫傜敤宸ュ簭" align="center" prop="applicableProcess" />
-      <el-table-column label="鎿嶄綔" align="center" class-name="small-padding fixed-width">
+      <el-table-column
+        label="閫傜敤宸ュ巶"
+        align="center"
+        prop="applicableFactory"
+      />
+      <!-- 閫傜敤杞﹂棿 -->
+      <el-table-column
+        label="閫傜敤杞﹂棿"
+        align="center"
+        prop="applicableWorkshop"
+      />
+      <!-- 閫傜敤宸ュ簭 -->
+      <el-table-column
+        label="閫傜敤宸ュ簭"
+        align="center"
+        prop="applicableProcess"
+      />
+      <el-table-column label="鍒涘缓鑰�" align="center" prop="createBy" />
+      <el-table-column label="鍒涘缓鏃堕棿" align="center" prop="createTime" />
+      <el-table-column
+        label="鎿嶄綔"
+        align="center"
+        class-name="small-padding fixed-width"
+      >
         <template #default="scope">
-          <el-button link type="primary" icon="Edit" @click="handleUpdate(scope.row)" v-hasPermi="['core:calendar:edit']">淇敼</el-button>
-          <el-button link type="primary" icon="Delete" @click="handleDelete(scope.row)" v-hasPermi="['core:calendar:remove']">鍒犻櫎</el-button>
+          <el-button
+            link
+            type="primary"
+            icon="Edit"
+            @click="handleUpdate(scope.row)"
+            v-hasPermi="['core:calendar:edit']"
+            >淇敼</el-button
+          >
+          <el-button
+            link
+            type="danger"
+            icon="Delete"
+            @click="handleDelete(scope.row)"
+            v-hasPermi="['core:calendar:remove']"
+            >鍒犻櫎</el-button
+          >
         </template>
       </el-table-column>
     </el-table>
-    
+
     <pagination
-      v-show="total>0"
+      v-show="total > 0"
       :total="total"
       v-model:page="queryParams.pageNum"
       v-model:limit="queryParams.pageSize"
@@ -110,34 +215,212 @@
 
     <!-- 娣诲姞鎴栦慨鏀规棩鍘嗙鐞嗗璇濇 -->
     <el-dialog :title="title" v-model="open" width="500px" append-to-body>
-      <el-form ref="calendarRef" :model="form" :rules="rules" label-width="80px">
-        <el-form-item label="鎻忚堪" prop="description">
+      <el-form
+        ref="calendarRef"
+        :model="form"
+        :rules="rules"
+        label-width="80px"
+      >
+        <el-form-item label="鏃ュ巻鎻忚堪" prop="description">
           <el-input v-model="form.description" placeholder="璇疯緭鍏ユ弿杩�" />
         </el-form-item>
-        <el-form-item label="鏃ュ巻鐢熸晥鏃ユ湡" prop="effectiveDate">
-          <el-date-picker clearable
+        <el-form-item label="鏃ュ巻绫诲瀷" prop="type">
+          <el-radio-group v-model="typeRadioNumber" @change="handleSwitchType">
+            <el-radio :label="1">鍛ㄥ伐浣�</el-radio>
+            <el-radio :label="2">鑺傚亣鏃�</el-radio>
+          </el-radio-group>
+        </el-form-item>
+        <el-form-item label="鐢熸晥鏃堕棿" prop="effectiveDate">
+          <el-date-picker
+            clearable
             v-model="form.effectiveDate"
             type="date"
             value-format="YYYY-MM-DD"
-            placeholder="璇烽�夋嫨鏃ュ巻鐢熸晥鏃ユ湡">
+            placeholder="閫夋嫨鏃ユ湡"
+          >
           </el-date-picker>
         </el-form-item>
-        <el-form-item label="澶辨晥鏃ユ湡" prop="expiringDate">
-          <el-date-picker clearable
+        <el-form-item label="澶辨晥鏃堕棿" prop="expiringDate">
+          <el-date-picker
+            clearable
             v-model="form.expiringDate"
             type="date"
             value-format="YYYY-MM-DD"
-            placeholder="璇烽�夋嫨澶辨晥鏃ユ湡">
+            placeholder="閫夋嫨鏃ユ湡"
+          >
           </el-date-picker>
         </el-form-item>
-        <el-form-item label="鏃ュ巻鍐呭" prop="content">
-          <el-input v-model="form.content" type="textarea" placeholder="璇疯緭鍏ュ唴瀹�" />
+        <div class="title_bar_line">
+          <div class="line_short"></div>
+          <div>鍛ㄥ伐浣滆缃�</div>
+          <div class="line_long"></div>
+        </div>
+        <div
+          class="week_flex"
+          v-for="(item, index) in weekDaysSettingList"
+          :key="index"
+        >
+          <div class="week_flex_item">{{item.chineseName}}</div>
+          <div class="week_flex_item">
+            <el-radio-group v-model="item.work" @change="handleSetWorkDays">
+              <el-radio :label="'y'">宸ヤ綔鏃�</el-radio>
+              <el-radio :label="'n'">闈炲伐浣滄棩</el-radio>
+            </el-radio-group>
+          </div>
+        </div>
+        <!-- <div class="week_flex">
+          <div class="week_flex_item">鏄熸湡浜�</div>
+          <div class="week_flex_item">
+            <el-radio-group v-model="tueType">
+              <el-radio :label="1">宸ヤ綔鏃�</el-radio>
+              <el-radio :label="2">闈炲伐浣滄棩</el-radio>
+            </el-radio-group>
+          </div>
+        </div>
+        <div class="week_flex">
+          <div class="week_flex_item">鏄熸湡涓�</div>
+          <div class="week_flex_item">
+            <el-radio-group v-model="wedType">
+              <el-radio :label="1">宸ヤ綔鏃�</el-radio>
+              <el-radio :label="2">闈炲伐浣滄棩</el-radio>
+            </el-radio-group>
+          </div>
+        </div>
+        <div class="week_flex">
+          <div class="week_flex_item">鏄熸湡鍥�</div>
+          <div class="week_flex_item">
+            <el-radio-group v-model="thuType">
+              <el-radio :label="1">宸ヤ綔鏃�</el-radio>
+              <el-radio :label="2">闈炲伐浣滄棩</el-radio>
+            </el-radio-group>
+          </div>
+        </div>
+        <div class="week_flex">
+          <div class="week_flex_item">鏄熸湡浜�</div>
+          <div class="week_flex_item">
+            <el-radio-group v-model="friType">
+              <el-radio :label="1">宸ヤ綔鏃�</el-radio>
+              <el-radio :label="2">闈炲伐浣滄棩</el-radio>
+            </el-radio-group>
+          </div>
+        </div>
+        <div class="week_flex">
+          <div class="week_flex_item">鏄熸湡鍏�</div>
+          <div class="week_flex_item">
+            <el-radio-group v-model="satType">
+              <el-radio :label="1">宸ヤ綔鏃�</el-radio>
+              <el-radio :label="2">闈炲伐浣滄棩</el-radio>
+            </el-radio-group>
+          </div>
+        </div>
+        <div class="week_flex">
+          <div class="week_flex_item">鏄熸湡鏃�</div>
+          <div class="week_flex_item">
+            <el-radio-group v-model="sunType">
+              <el-radio :label="1">宸ヤ綔鏃�</el-radio>
+              <el-radio :label="2">闈炲伐浣滄棩</el-radio>
+            </el-radio-group>
+          </div>
+        </div> -->
+        <el-form-item
+          label="閫傜敤宸ュ巶"
+          prop="applicableFactory"
+          class="factory_use_item"
+        >
+          <el-select
+            clearable
+            v-model="dateType"
+            style="width: 160px"
+            placeholder="璇疯緭鍏ラ�傜敤宸ュ巶"
+          >
+            <el-option
+              v-for="(item, index) of dateTypeList"
+              :key="index"
+              :label="item.name"
+              :value="item.name"
+              >{{ item.name }}</el-option
+            >
+          </el-select>
+        </el-form-item>
+        <el-form-item
+          label="閫傜敤杞﹂棿"
+          prop="applicableWorkshop"
+          class="factory_use_item"
+        >
+          <el-select
+            clearable
+            v-model="dateType"
+            style="width: 160px"
+            placeholder="璇疯緭鍏ラ�傜敤杞﹂棿"
+          >
+            <el-option
+              v-for="(item, index) of dateTypeList"
+              :key="index"
+              :label="item.name"
+              :value="item.name"
+              >{{ item.name }}</el-option
+            >
+          </el-select>
+        </el-form-item>
+        <el-form-item
+          label="閫傜敤宸ュ簭"
+          prop="applicableProcess"
+          class="factory_use_item"
+        >
+          <el-select
+            clearable
+            v-model="dateType"
+            style="width: 160px"
+            placeholder="璇疯緭鍏ラ�傜敤宸ュ簭"
+          >
+            <el-option
+              v-for="(item, index) of dateTypeList"
+              :key="index"
+              :label="item.name"
+              :value="item.name"
+              >{{ item.name }}</el-option
+            >
+          </el-select>
+        </el-form-item>
+        <el-form-item label="鍒涘缓鑰�" prop="createBy" class="factory_use_item">
+          <el-input type="text" v-model="form.createBy" placeholder="鍒涘缓鑰�" />
+        </el-form-item>
+        <el-form-item
+          label="鍒涘缓鏃堕棿"
+          prop="createTime"
+          class="factory_use_item"
+        >
+          <el-date-picker
+            clearable
+            v-model="form.createTime"
+            type="date"
+            value-format="YYYY-MM-DD"
+            placeholder="閫夋嫨鏃ユ湡"
+          >
+          </el-date-picker>
+        </el-form-item>
+        <el-form-item label="鏇存柊鑰�" prop="updateBy" class="factory_use_item">
+          <el-input type="text" v-model="form.updateBy" placeholder="鍒涘缓鑰�" />
+        </el-form-item>
+        <el-form-item
+          label="鏇存柊鏃堕棿"
+          prop="updateTime"
+          class="factory_use_item"
+        >
+          <el-date-picker
+            clearable
+            v-model="form.updateTime"
+            type="date"
+            value-format="YYYY-MM-DD"
+            placeholder="閫夋嫨鏃ユ湡"
+          >
+          </el-date-picker>
         </el-form-item>
       </el-form>
       <template #footer>
         <div class="dialog-footer">
-          <el-button type="primary" @click="submitForm">纭� 瀹�</el-button>
           <el-button @click="cancel">鍙� 娑�</el-button>
+          <el-button type="primary" @click="submitForm">淇濆瓨</el-button>
         </div>
       </template>
     </el-dialog>
@@ -145,7 +428,13 @@
 </template>
 
 <script setup name="Calendar">
-import { listCalendar, getCalendar, delCalendar, addCalendar, updateCalendar } from "@/api/core/calendar";
+import {
+  listCalendar,
+  getCalendar,
+  delCalendar,
+  addCalendar,
+  updateCalendar,
+} from "@/api/basicData/calendar";
 
 const { proxy } = getCurrentInstance();
 
@@ -174,15 +463,95 @@
     applicableProcess: null,
   },
   rules: {
-  }
+    description: [
+      {
+        required: true,
+        message: "璇疯緭鍏ユ棩鍘嗘弿杩�",
+        trigger: "blur",
+      },
+    ],
+    type: [
+      {
+        required: true,
+        message: "璇烽�夋嫨鏃ュ巻绫诲瀷",
+        trigger: "blur",
+      },
+    ],
+    effectiveDate: [
+      {
+        required: true,
+        message: "璇烽�夋嫨鏃ュ巻鐢熸晥鏃堕棿",
+        trigger: "blur",
+      },
+    ],
+    expiringDate: [
+      {
+        required: true,
+        message: "璇烽�夋嫨鏃ュ巻澶辨晥鏃堕棿",
+        trigger: "blur",
+      },
+    ],
+    applicableFactory: [
+      {
+        required: true,
+        message: "璇烽�夋嫨閫傜敤宸ュ巶",
+        trigger: "blur",
+      },
+    ],
+  },
 });
-
 const { queryParams, form, rules } = toRefs(data);
-
+const dateType = ref("鍛ㄥ伐浣�");
+const dateTypeList = ref([
+  {
+    name: "鍛ㄥ伐浣�",
+  },
+  {
+    name: "鑺傚亣鏃�",
+  },
+]);
+const typeRadioNumber = ref(1);
+const weekDaysSettingList = ref([
+  {
+    day: "Monday",
+    chineseName: "鏄熸湡涓�",
+    work:"y"
+  },
+  {
+    day: "TuesDay",
+    chineseName: "鏄熸湡浜�",
+    work:"y"
+  },
+  {
+    day: "Wednesday",
+    chineseName: "鏄熸湡涓�",
+    work:"y"
+  },
+  {
+    day: "Thursday",
+    chineseName: "鏄熸湡鍥�",
+    work:"y"
+  },
+  {
+    day:"Friday",
+    chineseName:"鏄熸湡浜�",
+    work:"y"
+  },
+  {
+    day:"Saturday",
+    chineseName:"鏄熸湡鍏�",
+    work:"y"
+  },
+  {
+    day:"Sunday",
+    chineseName:"鏄熸湡鏃�",
+    work:"y"
+  }
+]);
 /** 鏌ヨ鏃ュ巻绠$悊鍒楄〃 */
 function getList() {
   loading.value = true;
-  listCalendar(queryParams.value).then(response => {
+  listCalendar(queryParams.value).then((response) => {
     calendarList.value = response.rows;
     total.value = response.total;
     loading.value = false;
@@ -210,7 +579,7 @@
     createBy: null,
     createTime: null,
     updateBy: null,
-    updateTime: null
+    updateTime: null,
   };
   proxy.resetForm("calendarRef");
 }
@@ -229,7 +598,7 @@
 
 // 澶氶�夋閫変腑鏁版嵁
 function handleSelectionChange(selection) {
-  ids.value = selection.map(item => item.id);
+  ids.value = selection.map((item) => item.id);
   single.value = selection.length != 1;
   multiple.value = !selection.length;
 }
@@ -244,8 +613,8 @@
 /** 淇敼鎸夐挳鎿嶄綔 */
 function handleUpdate(row) {
   reset();
-  const _id = row.id || ids.value
-  getCalendar(_id).then(response => {
+  const _id = row.id || ids.value;
+  getCalendar(_id).then((response) => {
     form.value = response.data;
     open.value = true;
     title.value = "淇敼鏃ュ巻绠$悊";
@@ -254,16 +623,16 @@
 
 /** 鎻愪氦鎸夐挳 */
 function submitForm() {
-  proxy.$refs["calendarRef"].validate(valid => {
+  proxy.$refs["calendarRef"].validate((valid) => {
     if (valid) {
       if (form.value.id != null) {
-        updateCalendar(form.value).then(response => {
+        updateCalendar(form.value).then((response) => {
           proxy.$modal.msgSuccess("淇敼鎴愬姛");
           open.value = false;
           getList();
         });
       } else {
-        addCalendar(form.value).then(response => {
+        addCalendar(form.value).then((response) => {
           proxy.$modal.msgSuccess("鏂板鎴愬姛");
           open.value = false;
           getList();
@@ -276,20 +645,83 @@
 /** 鍒犻櫎鎸夐挳鎿嶄綔 */
 function handleDelete(row) {
   const _ids = row.id || ids.value;
-  proxy.$modal.confirm('鏄惁纭鍒犻櫎鏃ュ巻绠$悊缂栧彿涓�"' + _ids + '"鐨勬暟鎹」锛�').then(function() {
-    return delCalendar(_ids);
-  }).then(() => {
-    getList();
-    proxy.$modal.msgSuccess("鍒犻櫎鎴愬姛");
-  }).catch(() => {});
+  proxy.$modal
+    .confirm('鏄惁纭鍒犻櫎鏃ュ巻绠$悊缂栧彿涓�"' + _ids + '"鐨勬暟鎹」锛�')
+    .then(function () {
+      return delCalendar(_ids);
+    })
+    .then(() => {
+      getList();
+      proxy.$modal.msgSuccess("鍒犻櫎鎴愬姛");
+    })
+    .catch(() => {});
 }
 
 /** 瀵煎嚭鎸夐挳鎿嶄綔 */
 function handleExport() {
-  proxy.download('core/calendar/export', {
-    ...queryParams.value
-  }, `calendar_${new Date().getTime()}.xlsx`)
+  proxy.download(
+    "core/calendar/export",
+    {
+      ...queryParams.value,
+    },
+    `calendar_${new Date().getTime()}.xlsx`
+  );
 }
-
+function handleSwitchType(e) {
+  console.log(e, "鏃ユ湡绫诲瀷鍒囨崲");
+  typeRadioNumber.value = e;
+  form.value.effectiveDate = null;
+  form.value.expiringDate = null;
+  form.value.content = null;
+  form.value.applicableFactory = null;
+  form.value.applicableWorkshop = null;
+  form.value.applicableProcess = null;
+}
+// 璁剧疆鍛ㄥ伐浣滄棩
+function handleSetWorkDays(e) {
+  console.log(weekDaysSettingList.value,"璁剧疆鍛ㄥ伐浣滄棩")
+}
 getList();
 </script>
+<style lang="scss" scoped>
+.column-with-margin {
+  margin-right: 0px;
+}
+.title_bar_line {
+  display: flex;
+  justify-content: flex-start;
+  align-items: center;
+  color: #333;
+  margin-bottom: 10px;
+  .line_short {
+    width: 5%;
+    height: 1px;
+    margin-right: 20px;
+    border-top: 1px solid #ddd;
+  }
+  .line_long {
+    width: 60%;
+    height: 1px;
+    margin-left: 20px;
+    border-top: 1px solid #ddd;
+  }
+}
+.week_flex {
+  display: flex;
+  justify-content: flex-start;
+  align-content: center;
+  color: #333;
+  margin-left: 20px;
+  .week_flex_item {
+    &:nth-child(1) {
+      margin-top: 5px;
+    }
+    &:nth-child(2) {
+      margin-left: 20px;
+    }
+  }
+}
+.factory_use_item {
+  margin-top: 10px;
+}
+</style>
diff --git a/vite.config.js b/vite.config.js
index ff69a78..9c6e19f 100644
--- a/vite.config.js
+++ b/vite.config.js
@@ -1,58 +1,93 @@
-import { defineConfig, loadEnv } from 'vite'
-import path from 'path'
-import createVitePlugins from './vite/plugins'
+import { defineConfig, loadEnv } from "vite";
+import path from "path";
+import createVitePlugins from "./vite/plugins";
 
+// export default defineConfig({
+//   plugins: [vue()],
+//   server: {
+//     proxy: proxyConfig() // 浣跨敤鍔ㄦ�侀厤缃殑浠g悊
+//   }
+// });
 // https://vitejs.dev/config/
 export default defineConfig(({ mode, command }) => {
-  const env = loadEnv(mode, process.cwd())
-  const { VITE_APP_ENV } = env
+  const env = loadEnv(mode, process.cwd());
+  const { VITE_APP_ENV, VITE_APP_BASE_API, VITE_API_URL } = env;
+  console.log(VITE_APP_BASE_API, VITE_API_URL);
+  // 鏍规嵁鐜鍙橀噺鍔ㄦ�佽缃唬鐞�
+  const proxyConfig = () => {
+    const devProxy = {
+      "/dev-api": {
+        target: "http://192.168.50.86:8080", // 寮�鍙戠幆澧冪殑鍚庣鍦板潃
+        changeOrigin: true,
+        rewrite: (path) => path.replace(/^\/dev-api/, ""),
+      },
+    };
+
+    const testProxy = {
+      "/stage-api": {
+        target: "http://192.168.50.160:8080", // 娴嬭瘯鐜鐨勫悗绔湴鍧�
+        changeOrigin: true,
+        rewrite: (path) => path.replace(/^\/stage-api/, ""),
+      },
+    };
+
+    const prodProxy = {
+      "/stage-api": {
+        target: "http://192.168.50.160:8080", // 娴嬭瘯鐜鐨勫悗绔湴鍧�
+        changeOrigin: true,
+        rewrite: (path) => path.replace(/^\/stage-api/, ""),
+      },
+    };
+
+    switch (VITE_APP_ENV) {
+      case "development":
+        return devProxy;
+      case "staging":
+        return testProxy;
+      default: // 榛樿寮�鍙戠幆澧�
+        return prodProxy;
+    }
+  };
   return {
     // 閮ㄧ讲鐢熶骇鐜鍜屽紑鍙戠幆澧冧笅鐨刄RL銆�
     // 榛樿鎯呭喌涓嬶紝vite 浼氬亣璁句綘鐨勫簲鐢ㄦ槸琚儴缃插湪涓�涓煙鍚嶇殑鏍硅矾寰勪笂
     // 渚嬪 https://www.ruoyi.vip/銆傚鏋滃簲鐢ㄨ閮ㄧ讲鍦ㄤ竴涓瓙璺緞涓婏紝浣犲氨闇�瑕佺敤杩欎釜閫夐」鎸囧畾杩欎釜瀛愯矾寰勩�備緥濡傦紝濡傛灉浣犵殑搴旂敤琚儴缃插湪 https://www.ruoyi.vip/admin/锛屽垯璁剧疆 baseUrl 涓� /admin/銆�
-    base: VITE_APP_ENV === 'production' ? '/' : '/',
-    plugins: createVitePlugins(env, command === 'build'),
+    base: VITE_APP_ENV === "production" ? "/" : "/",
+    plugins: createVitePlugins(env, command === "build"),
     resolve: {
       // https://cn.vitejs.dev/config/#resolve-alias
       alias: {
         // 璁剧疆璺緞
-        '~': path.resolve(__dirname, './'),
+        "~": path.resolve(__dirname, "./"),
         // 璁剧疆鍒悕
-        '@': path.resolve(__dirname, './src')
+        "@": path.resolve(__dirname, "./src"),
       },
       // https://cn.vitejs.dev/config/#resolve-extensions
-      extensions: ['.mjs', '.js', '.ts', '.jsx', '.tsx', '.json', '.vue']
+      extensions: [".mjs", ".js", ".ts", ".jsx", ".tsx", ".json", ".vue"],
     },
     // vite 鐩稿叧閰嶇疆
     server: {
       port: 80,
       host: true,
       open: true,
-      proxy: {
-        // https://cn.vitejs.dev/config/#server-proxy
-        '/dev-api': {
-          target: 'http://192.168.50.160:8080',
-          changeOrigin: true,
-          rewrite: (p) => p.replace(/^\/dev-api/, '')
-        }
-      }
+      proxy: proxyConfig(),
     },
     //fix:error:stdin>:7356:1: warning: "@charset" must be the first rule in the file
     css: {
       postcss: {
         plugins: [
           {
-            postcssPlugin: 'internal:charset-removal',
+            postcssPlugin: "internal:charset-removal",
             AtRule: {
               charset: (atRule) => {
-                if (atRule.name === 'charset') {
+                if (atRule.name === "charset") {
                   atRule.remove();
                 }
-              }
-            }
-          }
-        ]
-      }
-    }
-  }
-})
+              },
+            },
+          },
+        ],
+      },
+    },
+  };
+});

--
Gitblit v1.9.3