Sfoglia il codice sorgente

Merge branch 'master' of http://47.107.245.0:3000/xiongxing/kyj-yanglao-web-new

unknown 3 settimane fa
parent
commit
4e17a6a52d

+ 1 - 1
src/main.ts

@@ -51,7 +51,7 @@ import { Flex } from 'ant-design-vue'
 import 'ant-design-vue/dist/reset.css'
 import fetchPlugin from './config/axios/fetch';
 //版本号
-export const MAIN_VERSION = '4.4.0'
+export const MAIN_VERSION = '4.4.3'
 
 // 创建实例
 const setupAll = async () => {

+ 52 - 36
src/views/elderly/fee/bill-pay/Form.vue

@@ -28,7 +28,7 @@
       <div class="header">
         <div class="left">{{ tTitle }}</div>
         <div class="right">
-          {{isDetail ? '已缴' : '小计'}}<span class="price">¥{{ formatNum(dataForm.totalMonthPrice) }}</span></div>
+          {{isDetail ? '已缴' : '小计'}}<span class="price">¥{{ formatNum(monthSubtotalAmount) }}</span></div>
       </div>
       <el-table
         ref="monthTableRef"
@@ -64,11 +64,12 @@
         <el-table-column prop="totalAmount" label="应收金额(元)" align="center">
           <template #default="scope">
 
-              <el-input-number  v-if="isEdit" @blur="handlePrice(scope.row, 1)" v-model="scope.row.totalAmount" controls-position="right"/>
-              <span v-else>{{ formatTotalMonth(scope.row) }}</span>
+              <el-input-number  v-if="isEdit && scope.row.payStatus == 0" @blur="handlePrice(scope.row, 1)" v-model="scope.row.totalAmount" controls-position="right"/>
+              <span v-else>{{ (scope.row.payStatus == 1 || scope.row.payStatus == 2) ? (formatTotalMonth(scope.row) - scope.row.payAmount).toFixed(2) : formatTotalMonth(scope.row) }}</span>
 
           </template>
         </el-table-column>
+        <el-table-column prop="payAmount" label="已缴费用" width="100" align="center" />
         <el-table-column prop="isShow" label="是否显示在单据上" align="center">
           <template #default="scope">
             <el-checkbox v-if="isEdit" v-model="scope.row.isShow" :checked="scope.row.isShow == 1" @change="handlePrice(scope.row, 1)"/>
@@ -86,7 +87,7 @@
         <div class="header">
           <div class="left">预备金费用(元)</div>
           <div class="right"
-            >{{isDetail ? '已缴' : '小计'}}<span class="price">¥{{ formatNum(dataForm.totalDepositPrice) }}</span></div
+            >{{isDetail ? '已缴' : '小计'}}<span class="price">¥{{ formatNum(depositSubtotalAmount) }}</span></div
           >
         </div>
         <el-table
@@ -122,11 +123,12 @@
           <el-table-column prop="count" label="数量" width="100" align="center" />
           <el-table-column prop="totalAmount" label="应收金额(元)" align="center">
             <template #default="scope">
-              <el-input-number  v-if="isEdit" @blur="handlePrice(scope.row, 2)" v-model="scope.row.totalAmount" controls-position="right"/>
-              <span v-else>{{ tableRowPay(scope.row) }}</span>
+              <el-input-number  v-if="isEdit && scope.row.payStatus == 0" @blur="handlePrice(scope.row, 2)" v-model="scope.row.totalAmount" controls-position="right"/>
+              <span v-else>{{ (scope.row.payStatus == 1 || scope.row.payStatus == 2) ? (tableRowPay(scope.row) - scope.row.payAmount).toFixed(2) : tableRowPay(scope.row) }}</span>
 
           </template>
           </el-table-column>
+          <el-table-column prop="payAmount" label="已缴费用" width="100" align="center" />
           <el-table-column prop="isShow" label="是否显示在单据上" align="center">
           <template #default="scope">
             <el-checkbox v-if="isEdit" v-model="scope.row.isShow" :checked="scope.row.isShow == 1" @change="handlePrice(scope.row, 2)"/>
@@ -143,7 +145,7 @@
         <div class="header">
           <div class="left">阶段性费用(元)</div>
           <div class="right"
-            >{{isDetail ? '已缴' : '小计'}}<span class="price">¥{{ formatNum(dataForm.totalStageExpandPrice) }}</span></div
+            >{{isDetail ? '已缴' : '小计'}}<span class="price">¥{{ formatNum(stageSubtotalAmount) }}</span></div
           >
         </div>
         <el-table
@@ -206,10 +208,11 @@
           <el-table-column prop="totalAmount" label="应收金额(元)" align="center">
             <template #default="scope">
               <el-input-number  v-if="isEdit" @blur="handlePrice(scope.row, 3)" v-model="scope.row.totalAmount" controls-position="right"/>
-              <span v-else>{{ tableRowPay(scope.row) }}</span>
+              <span v-else>{{ (scope.row.payStatus == 1 || scope.row.payStatus == 2) ? (tableRowPay(scope.row) - scope.row.payAmount).toFixed(2) : tableRowPay(scope.row) }}</span>
 
             </template>
           </el-table-column>
+          <el-table-column prop="payAmount" label="已缴费用" width="100" align="center" />
           <el-table-column prop="isShow" label="是否显示在单据上" align="center">
             <template #default="scope">
               <el-checkbox v-if="isEdit" v-model="scope.row.isShow" :checked="scope.row.isShow == 1" @change="handlePrice(scope.row, 3)"/>
@@ -221,7 +224,7 @@
         <div class="header">
           <div class="left">其他费用(元)</div>
           <div class="right"
-            >{{isDetail ? '已缴' : '小计'}}<span class="price">¥{{ formatNum(dataForm.totalOneTimeFeePrice) }}</span></div
+            >{{isDetail ? '已缴' : '小计'}}<span class="price">¥{{ formatNum(oneTimeSubtotalAmount) }}</span></div
           >
         </div>
         <el-table
@@ -257,11 +260,12 @@
           <el-table-column prop="count" label="数量" width="100" align="center" />
           <el-table-column prop="totalAmount" label="应收金额(元)" align="center">
             <template #default="scope">
-              <el-input-number  v-if="isEdit" @blur="handlePrice(scope.row, 5)" v-model="scope.row.totalAmount" controls-position="right"/>
-              <span v-else>{{ tableRowPay(scope.row) }}</span>
+              <el-input-number  v-if="isEdit && scope.row.payStatus == 0" @blur="handlePrice(scope.row, 5)" v-model="scope.row.totalAmount" controls-position="right"/>
+              <span v-else>{{ (scope.row.payStatus == 1 || scope.row.payStatus == 2) ? (tableRowPay(scope.row) - scope.row.payAmount).toFixed(2) : tableRowPay(scope.row) }}</span>
 
             </template>
           </el-table-column>
+          <el-table-column prop="payAmount" label="已缴费用" width="100" align="center" />
           <el-table-column prop="isShow" label="是否显示在单据上" align="center">
             <template #default="scope">
               <el-checkbox v-if="isEdit" v-model="scope.row.isShow" :checked="scope.row.isShow == 1" @change="handlePrice(scope.row, 5)"/>
@@ -353,10 +357,11 @@
           </el-table-column> -->
           <el-table-column prop="totalAmount" width="180" label="应收金额(元)" align="center">
             <template #default="scope">
-              <el-input-number  v-if="isEdit" @blur="handlePrice(scope.row, 5)" v-model="scope.row.totalAmount" controls-position="right"/>
-              <span v-else>{{ tableRowPay(scope.row) }}</span>
+              <el-input-number  v-if="isEdit && scope.row.payStatus == 0" @blur="handlePrice(scope.row, 5)" v-model="scope.row.totalAmount" controls-position="right"/>
+              <span v-else>{{ (scope.row.payStatus == 1 || scope.row.payStatus == 2) ? (tableRowPay(scope.row) - scope.row.payAmount).toFixed(2) : tableRowPay(scope.row) }}</span>
             </template>
           </el-table-column>
+          <el-table-column prop="payAmount" label="已缴费用" width="100" align="center" />
           <el-table-column prop="isShow" label="是否显示在单据上" align="center">
             <template #default="scope">
               <el-checkbox v-if="isEdit" v-model="scope.row.isShow" :checked="scope.row.isShow == 1" @change="handlePrice(scope.row, 5)"/>
@@ -374,7 +379,7 @@
         <div class="header">
           <div class="left">阶段性费用(元)</div>
           <div class="right"
-            >{{isDetail ? '已缴' : '小计'}}<span class="price">¥{{ formatNum(dataForm.totalStageExpandPrice) }}</span></div
+            >{{isDetail ? '已缴' : '小计'}}<span class="price">¥{{ formatNum(stageExpandSubtotalAmount) }}</span></div
           >
         </div>
         <el-table
@@ -436,11 +441,12 @@
           <el-table-column prop="count" label="数量" width="100" align="center" />
           <el-table-column prop="totalAmount" label="应收金额(元)" align="center">
             <template #default="scope">
-              <el-input-number  v-if="isEdit" @blur="handlePrice(scope.row, 3)" v-model="scope.row.totalAmount" controls-position="right"/>
-              <span v-else>{{ tableRowPay(scope.row) }}</span>
+              <el-input-number  v-if="isEdit && scope.row.payStatus == 0" @blur="handlePrice(scope.row, 3)" v-model="scope.row.totalAmount" controls-position="right"/>
+              <span v-else>{{ (scope.row.payStatus == 1 || scope.row.payStatus == 2) ? (tableRowPay(scope.row) - scope.row.payAmount).toFixed(2) : tableRowPay(scope.row) }}</span>
               <!-- <span class="underline" v-if="!settingStore.getRceivable||settingStore.getAdmissionBillRoundUp">{{ formatNum(scope.row.totalAmount) }}</span> -->
             </template>
           </el-table-column>
+          <el-table-column prop="payAmount" label="已缴费用" width="100" align="center" />
           <el-table-column prop="isShow" label="是否显示在单据上" align="center">
             <template #default="scope">
               <el-checkbox v-if="isEdit" v-model="scope.row.isShow" :checked="scope.row.isShow == 1" @change="handlePrice(scope.row, 3)"/>
@@ -594,6 +600,12 @@ const totalAllAmount = computed(()=>{
   return formatNum(dataForm.value.totalMonthPrice + dataForm.value.totalOneTimeFeePrice + dataForm.value.totalDepositPrice + dataForm.value.totalStageExpandPrice)
 })
 
+const monthSubtotalAmount = computed(() => monthSelected.value.length ? formatNum(dataForm.value.totalMonthPrice) : 0)
+const depositSubtotalAmount = computed(() => depositSelected.value.length ? formatNum(dataForm.value.totalDepositPrice) : 0)
+const oneTimeSubtotalAmount = computed(() => oneTimeSelected.value.length ? formatNum(dataForm.value.totalOneTimeFeePrice) : 0)
+const stageSubtotalAmount = computed(() => stageExpandSelected.value.length ? formatNum(dataForm.value.totalStageExpandPrice) : 0)
+const stageExpandSubtotalAmount = stageSubtotalAmount
+
 // 固定费用
 const formatTotalMonth = (item)=>{
   if(dataForm.value.type == 1){
@@ -644,6 +656,10 @@ const totalRoundAndTwoDecimalAmount = computed(()=>{
 
 // 账单总额 1.入院且入院配置了向上取整 2.账单四舍五入 3.账单实际金额 (需要减去长护险)
 const tAmount = computed(()=>{
+  let payAmountTotal = 0
+  dataForm.value.monthArr.map(item => {
+    payAmountTotal += item.payAmount ? Number(item.payAmount) : 0
+  })
   if(dataForm.value.type == 1){ //1入院,2月度
     return totalAllAmount.value
     // if(settingStore.getAdmissionBill == 2){ // 向上取整
@@ -655,11 +671,11 @@ const tAmount = computed(()=>{
   }else{
     console.log("取值",rounding.value,fixed2Num.value)
     if(rounding.value){
-      return formatRound(totalRoundAndTwoDecimalAmount.value.num)
+      return formatRound(totalRoundAndTwoDecimalAmount.value.num - payAmountTotal)
     }else if(fixed2Num.value){
-      return formatNum(totalRoundAndTwoDecimalAmount.value.decimal)
+      return formatNum(totalRoundAndTwoDecimalAmount.value.decimal - payAmountTotal)
     }else{
-      return formatNum(dataForm.value.actualAmount)
+      return formatNum(dataForm.value.actualAmount - payAmountTotal)
     }
   }
 })
@@ -797,7 +813,7 @@ const goToBill = () => {
 
 // 判断表格中那些数据可选
 const handleSelectable = (row) => {
-  return row.payStatus == 0
+  return row.payStatus == 0 || row.payStatus == 2
 }
 
 // 选中数据
@@ -809,21 +825,21 @@ const handleMonthSelectionChange = (val) => {
     if(item.isShow){
       if(dataForm.value.type == '1'){
         if(settingStore.getAdmissionBill == 2){ // 向上取整
-          total += formatDecimal(Number(formatCeil(item.totalAmount))) as number
+          total += formatDecimal(Number(formatCeil(item.totalAmount - (item.payAmount || 0)))) as number
         }else if(settingStore.getAdmissionBill == 3){ // 四舍五入保留两位
-          total += formatDecimal(formatNum(item.roundTwoDecimalAmount)) as number
+          total += formatDecimal(formatNum(item.roundTwoDecimalAmount - (item.payAmount || 0))) as number
         }else if(settingStore.getAdmissionBill == 4){ // 四舍五入取整
-          total += formatDecimal(formatNum(item.roundAmount)) as number
+          total += formatDecimal(formatNum(item.roundAmount - (item.payAmount || 0))) as number
         }else{ // 应收
-          total += formatDecimal(formatNum(item.totalAmount)) as number
+          total += formatDecimal(formatNum(item.totalAmount - (item.payAmount || 0))) as number
         }
       }else{
         if(rounding.value){ // 账单取整
-          total += formatDecimal(formatNum(item.roundAmount)) as number
+          total += formatDecimal(formatNum(item.roundAmount - (item.payAmount || 0))) as number
         } else if(fixed2Num.value){ // 四舍五入保留两位
-          total += formatDecimal(formatNum(item.roundTwoDecimalAmount)) as number
+          total += formatDecimal(formatNum(item.roundTwoDecimalAmount - (item.payAmount || 0))) as number
         } else{ // 实际应收
-          total += formatDecimal(formatNum(item.totalAmount)) as number
+          total += formatDecimal(formatNum(item.totalAmount - (item.payAmount || 0))) as number
         }
       }
     }
@@ -840,11 +856,11 @@ const handleDepositSelectionChange = (val) => {
   val.map((item) => {
     if(item.isShow){
       if(rounding.value){ // 账单取整
-        total += formatDecimal(formatNum(item.roundAmount)) as number
+        total += formatDecimal(formatNum(item.roundAmount - (item.payAmount || 0))) as number
       } else if(fixed2Num.value){ // 四舍五入保留两位
-        total += formatDecimal(formatNum(item.roundTwoDecimalAmount)) as number
+        total += formatDecimal(formatNum(item.roundTwoDecimalAmount - (item.payAmount || 0))) as number
       } else{ // 实际应收
-        total += formatDecimal(formatNum(item.totalAmount)) as number
+        total += formatDecimal(formatNum(item.totalAmount - (item.payAmount || 0))) as number
       }
     }
   })
@@ -860,11 +876,11 @@ const handleOneTimeSelectionChange = (val) => {
   val.map((item) => {
     if(item.isShow){
       if(rounding.value){ // 账单取整
-        total += formatDecimal(formatNum(item.roundAmount)) as number
+        total += formatDecimal(formatNum(item.roundAmount - (item.payAmount || 0))) as number
       } else if(fixed2Num.value){ // 四舍五入保留两位
-        total += formatDecimal(formatNum(item.roundTwoDecimalAmount)) as number
+        total += formatDecimal(formatNum(item.roundTwoDecimalAmount - (item.payAmount || 0))) as number
       } else{ // 实际应收
-        total += formatDecimal(formatNum(item.totalAmount)) as number
+        total += formatDecimal(formatNum(item.totalAmount - (item.payAmount || 0))) as number
       }
     }
   })
@@ -880,11 +896,11 @@ const handleStageExpandSelectionChange = (val) => {
     val.map((item) => {
       if(item.isShow){
         if(rounding.value){ // 账单取整
-          total += formatDecimal(formatNum(item.roundAmount)) as number
+          total += formatDecimal(formatNum(item.roundAmount - (item.payAmount || 0))) as number
         } else if(fixed2Num.value){ // 四舍五入保留两位
-          total += formatDecimal(formatNum(item.roundTwoDecimalAmount)) as number
+          total += formatDecimal(formatNum(item.roundTwoDecimalAmount - (item.payAmount || 0))) as number
         } else{ // 实际应收
-          total += formatDecimal(formatNum(item.totalAmount)) as number
+          total += formatDecimal(formatNum(item.totalAmount - (item.payAmount || 0))) as number
         }
       }
     })

+ 53 - 11
src/views/elderly/fee/bill-pay/pay.vue

@@ -60,13 +60,15 @@
             </el-select>
           </template>
         </el-table-column>
+
         <el-table-column prop="payAmount" label="收款金额">
           <template #default="scope">
             <TgInput
               placeholder="请输入收款金额"
               v-model="scope.row.payAmount"
               @blur="handleItemBlur(scope.row)"
-              :readonly="scope.$index == 0"
+              @change="handleItemChange(scope.row)"
+              :readonly="scope.$index == 0 && billForm.expenseOrderItems?.length > 1"
             />
           </template>
         </el-table-column>
@@ -217,14 +219,16 @@ const submitForm = async () => {
       message.error('请添加支付方式')
       return
     }
-    let total = 0
-    // 判断钱是否一致
-    billForm.value.items.map((item) => {
-      total += item.payAmount ? Number(item.payAmount) : 0
-    })
-    if (formatNum(total) != formatNum(billForm.value.payAmount)) {
-      message.error('收款金额与本次应缴不一致')
-      return
+    if (billForm.value.items.length > 1) {
+      let total = 0
+      // 判断钱是否一致
+      billForm.value.items.map((item) => {
+        total += item.payAmount ? Number(item.payAmount) : 0
+      })
+      if (formatNum(total) != formatNum(billForm.value.payAmount)) {
+        message.error('收款金额与本次应缴不一致')
+        return
+      }
     }
     // 判断如果为0不能缴费
     // if(total == 0){
@@ -243,7 +247,7 @@ const submitForm = async () => {
     })
 
     params.depositList = toRaw(depositList.value)
-    //console.log('缴费参数:',params)
+    console.log('缴费参数:',params)
     const res = await payExpenseOrder(params)
     if (res) {
       message.success(t('common.updateSuccess'))
@@ -267,12 +271,50 @@ const handleChange = () => {
   )
 }
 
+const handleItemChange = (row) => {
+  if (typeof row.payType == 'string' && (row.payType.indexOf("account_member_card") > -1 || row.payType == 'balance' || row.payType.indexOf("long_term_care_insurance") > -1) ) {
+    const item = options.value.find(item=>row.payType == item.value)
+    if (item) {
+      row.payAmount = row.payAmount > item.price ? item.price : row.payAmount
+    }
+  }
+
+  let allMoney = 0
+  if (billForm.value.expenseOrderItems?.length == 1) {
+    billForm.value.items.map((item, index) => {
+      allMoney += item.payAmount ? Number(item.payAmount) : 0
+    })
+    if(Number(formatNum(allMoney)) > Number(formatNum(actualAmount.value))){
+      message.error('收款金额不能大于账单总额')
+      row.payAmount = 0
+    }
+    billForm.value.payAmount = formatNum(allMoney)
+    return
+  }
+}
+
 // 比较最大值
 const handleItemBlur = (row) => {
   if (typeof row.payType == 'string' && (row.payType.indexOf("account_member_card") > -1 || row.payType == 'balance' || row.payType.indexOf("long_term_care_insurance") > -1) ) {
     const item = options.value.find(item=>row.payType == item.value)
-    row.payAmount = row.payAmount > item.price ? item.price : row.payAmount
+    if (item) {
+      row.payAmount = row.payAmount > item.price ? item.price : row.payAmount
+    }
   }
+
+  let allMoney = 0
+  if (billForm.value.expenseOrderItems?.length == 1) {
+    billForm.value.items.map((item, index) => {
+      allMoney += item.payAmount ? Number(item.payAmount) : 0
+    })
+    if(Number(formatNum(allMoney)) > Number(formatNum(actualAmount.value))){
+      message.error('收款金额不能大于账单总额')
+      row.payAmount = 0
+    }
+    billForm.value.payAmount = formatNum(allMoney)
+    return
+  }
+
   // 修改完后其余相加,扣减第一条的费用
   let firstTotal = 0
   // 判断钱是否一致

+ 3 - 2
src/views/elderly/restaurant/elderFood-order/index.vue

@@ -21,10 +21,11 @@
       <el-form-item label="房间号" prop="roomNo" label-width="65px">
         <el-input v-model="queryParams.roomNo" clearable class="!w-150px" />
       </el-form-item>
-      <el-form-item label="A/B套餐" prop="extraDishesOption" label-width="80px">
+      <el-form-item label="套餐类型" prop="extraDishesOption" label-width="80px">
         <el-select v-model="queryParams.extraDishesOption" clearable class="!w-150px" placeholder="请选择">
           <el-option label="A套餐" value="A" />
           <el-option label="B套餐" value="B" />
+          <el-option label="糖餐" value="糖" />
         </el-select>
       </el-form-item>
       <el-form-item label="时间段" prop="orderFoodDateRange" label-width="80px">
@@ -104,7 +105,7 @@ const elderFoodOrderColumns = reactive([
     label: '点餐日期',
     field: 'orderFoodDate',
   },
-  { label: 'A/B套餐', field: 'extraDishesOption' },
+  { label: '套餐类型', field: 'extraDishesOption' },
   { label: '附加菜名', field: 'extraDishes' },
 ])
 

+ 37 - 14
src/views/system/food/CateringPlan/AddForm.vue

@@ -153,11 +153,11 @@
             :options="foodLists"
             :props="{ label: 'foodName', value: 'foodName' }"
             multiple
-            :multiple-limit="2"
+            :multiple-limit="3"
             collapse-tags
             collapse-tags-tooltip
             v-model="scope.row.mondayExtra"
-            placeholder="附加菜品(最多2个)"
+            placeholder="附加菜品(最多3个)"
             style="width: 100%; margin-top: 6px"
           />
         </template>
@@ -182,11 +182,11 @@
             :options="foodLists"
             :props="{ label: 'foodName', value: 'foodName' }"
             multiple
-            :multiple-limit="2"
+            :multiple-limit="3"
             collapse-tags
             collapse-tags-tooltip
             v-model="scope.row.tuesdayExtra"
-            placeholder="附加菜品(最多2个)"
+            placeholder="附加菜品(最多3个)"
             style="width: 100%; margin-top: 6px"
           />
         </template>
@@ -211,11 +211,11 @@
             :options="foodLists"
             :props="{ label: 'foodName', value: 'foodName' }"
             multiple
-            :multiple-limit="2"
+            :multiple-limit="3"
             collapse-tags
             collapse-tags-tooltip
             v-model="scope.row.wednesdayExtra"
-            placeholder="附加菜品(最多2个)"
+            placeholder="附加菜品(最多3个)"
             style="width: 100%; margin-top: 6px"
           />
         </template>
@@ -240,11 +240,11 @@
             :options="foodLists"
             :props="{ label: 'foodName', value: 'foodName' }"
             multiple
-            :multiple-limit="2"
+            :multiple-limit="3"
             collapse-tags
             collapse-tags-tooltip
             v-model="scope.row.thursdayExtra"
-            placeholder="附加菜品(最多2个)"
+            placeholder="附加菜品(最多3个)"
             style="width: 100%; margin-top: 6px"
           />
         </template>
@@ -269,11 +269,11 @@
             :options="foodLists"
             :props="{ label: 'foodName', value: 'foodName' }"
             multiple
-            :multiple-limit="2"
+            :multiple-limit="3"
             collapse-tags
             collapse-tags-tooltip
             v-model="scope.row.fridayExtra"
-            placeholder="附加菜品(最多2个)"
+            placeholder="附加菜品(最多3个)"
             style="width: 100%; margin-top: 6px"
           />
         </template>
@@ -298,11 +298,11 @@
             :options="foodLists"
             :props="{ label: 'foodName', value: 'foodName' }"
             multiple
-            :multiple-limit="2"
+            :multiple-limit="3"
             collapse-tags
             collapse-tags-tooltip
             v-model="scope.row.saturdayExtra"
-            placeholder="附加菜品(最多2个)"
+            placeholder="附加菜品(最多3个)"
             style="width: 100%; margin-top: 6px"
           />
         </template>
@@ -327,11 +327,11 @@
             :options="foodLists"
             :props="{ label: 'foodName', value: 'foodName' }"
             multiple
-            :multiple-limit="2"
+            :multiple-limit="3"
             collapse-tags
             collapse-tags-tooltip
             v-model="scope.row.sundayExtra"
-            placeholder="附加菜品(最多2个)"
+            placeholder="附加菜品(最多3个)"
             style="width: 100%; margin-top: 6px"
           />
         </template>
@@ -410,6 +410,28 @@ const isLunchMeal = (mealTimes?: string) => {
   return mealTimes === '中餐' || mealTimes === '午餐'
 }
 
+const normalizeExtraDishes = (bean) => {
+  const extraFields = [
+    'mondayExtra',
+    'tuesdayExtra',
+    'wednesdayExtra',
+    'thursdayExtra',
+    'fridayExtra',
+    'saturdayExtra',
+    'sundayExtra'
+  ]
+
+  extraFields.forEach((field) => {
+    if (!Array.isArray(bean[field])) {
+      bean[field] = []
+      return
+    }
+    if (bean[field].length > 3) {
+      bean[field] = bean[field].slice(0, 3)
+    }
+  })
+}
+
 const createMealItem = (mealTimes: string, indexs?: number) => {
   const base = {
     mealTimes,
@@ -463,6 +485,7 @@ const parseWeekFields = (bean) => {
       bean[field] = []
     }
   })
+  normalizeExtraDishes(bean)
 }
 
 const stringifyWeekFields = (bean) => {