diff --git a/apps/web-antd/src/views/property/clean/cleanOrders/clean-detail-modal.vue b/apps/web-antd/src/views/property/clean/cleanOrders/clean-detail-modal.vue index 8ff8247e..45fb81d0 100644 --- a/apps/web-antd/src/views/property/clean/cleanOrders/clean-detail-modal.vue +++ b/apps/web-antd/src/views/property/clean/cleanOrders/clean-detail-modal.vue @@ -222,7 +222,7 @@ const [BasicModal, modalApi] = useVbenModal({ data.roomId = data.roomId .split(',') .filter((id: string) => id.trim() !== ''); - data.area = data.sumPeices / data.peices; + // data.area = data.sumPeices / data.peices; } else { isAdd.value = true; } diff --git a/apps/web-antd/src/views/property/clean/cleanOrders/clean-modal.vue b/apps/web-antd/src/views/property/clean/cleanOrders/clean-modal.vue index d9e63b5e..98058296 100644 --- a/apps/web-antd/src/views/property/clean/cleanOrders/clean-modal.vue +++ b/apps/web-antd/src/views/property/clean/cleanOrders/clean-modal.vue @@ -542,6 +542,7 @@ async function handleConfirm() { : await clean_orderAdd(data); resetInitialized(); emit('reload'); + currentUnitId.value = ''; //清空当前单位id modalApi.close(); } catch (error) { console.error(error); @@ -553,6 +554,7 @@ async function handleConfirm() { async function handleClosed() { await formApi.resetForm(); detailTable.value = []; //清空详情表格 + currentUnitId.value = ''; //清空当前单位id resetInitialized(); } // 获取服务地址 diff --git a/apps/web-antd/src/views/property/costManagement/houseCharge/houseCharge-add.vue b/apps/web-antd/src/views/property/costManagement/houseCharge/houseCharge-add.vue index 375f2ed9..ac87ba6c 100644 --- a/apps/web-antd/src/views/property/costManagement/houseCharge/houseCharge-add.vue +++ b/apps/web-antd/src/views/property/costManagement/houseCharge/houseCharge-add.vue @@ -20,8 +20,11 @@ import type { CostItemSettingVO } from '#/api/property/costManagement/costItemSe import { getDictOptions } from '#/utils/dict'; import { personList } from '#/api/property/resident/person'; import { renderDictValue } from '#/utils/render'; -import {resident_unitInfo, resident_unitList} from "#/api/property/resident/unit"; - +import { + resident_unitInfo, + resident_unitList, +} from '#/api/property/resident/unit'; +import dayjs from 'dayjs'; const emit = defineEmits<{ reload: [] }>(); const isUpdate = ref(false); @@ -74,7 +77,7 @@ const [BasicModal, modalApi] = useVbenModal({ if (isUpdate.value && id) { const record = await houseChargeInfo(id); - record.chargeTime =record.startTime?.substring(0,7); + record.chargeTime = record.startTime?.substring(0, 7); await formApi.setValues(record); } await markInitialized(); @@ -93,8 +96,12 @@ async function handleConfirm() { // getValues获取为一个readonly的对象 需要修改必须先深拷贝一次 const data = cloneDeep(await formApi.getValues()); if (data.chargeTime) { - data.startTime = data.chargeTime+'-01 00:00:00'; - data.endTime = data.chargeTime+'-31 23:59:59'; + data.startTime = dayjs(data.chargeTime) + .startOf('month') + .format('YYYY-MM-DD HH:mm:ss'); + data.endTime = dayjs(data.chargeTime) + .endOf('month') + .format('YYYY-MM-DD HH:mm:ss'); } await (isUpdate.value ? houseChargeUpdate(data) : houseChargeAdd(data)); resetInitialized(); @@ -115,7 +122,7 @@ async function handleClosed() { /** * 查询费用项设置 */ -async function queryCostItemOptions(costType: string|null) { +async function queryCostItemOptions(costType: string | null) { let params = { pageSize: 1000, pageNum: 1, @@ -157,7 +164,9 @@ async function initCostTypeOptions() { { componentProps: { // 费用类型不要保洁、会议、绿植 - options: getDictOptions('pro_expense_type').filter(item=>!(['1','3','4'].includes(item.value))), + options: getDictOptions('pro_expense_type').filter( + (item) => !['1', '3', '4'].includes(item.value), + ), onChange: async (value: string) => { if (value) { await queryCostItemOptions(value); @@ -207,7 +216,7 @@ async function queryUnitData() { }; const res = await resident_unitList(params); const options = res.rows.map((unit) => ({ - label:unit.name, + label: unit.name, value: unit.id, })); formApi.updateSchema([ @@ -229,8 +238,8 @@ async function queryUnitData() { } async function queryRoomByUnit(unitId: string) { - let unitInfo = await resident_unitInfo(unitId); - if(unitInfo&&unitInfo.locationDetail){ + let unitInfo = await resident_unitInfo(unitId); + if (unitInfo && unitInfo.locationDetail) { await formApi.setFieldValue('roomInfo', unitInfo.locationDetail); await formApi.setFieldValue('area', unitInfo.area); } @@ -241,14 +250,12 @@ async function queryRoomByUnit(unitId: string) {