This commit is contained in:
@@ -6,7 +6,7 @@ import {attachListAll} from '#/api/property/roomBooking/conferenceAddServices';
|
||||
import {meetInfo} from '#/api/property/roomBooking/conferenceSettings';
|
||||
import {defaultFormValueGetter, useBeforeCloseDiff} from '#/utils/popup';
|
||||
import {modalSchema} from './data';
|
||||
import type {conferenceSettingsDetail} from "#/api/property/roomBooking/conferenceSettings/model";
|
||||
import type {ConferenceSettingsDetail} from "#/api/property/roomBooking/conferenceSettings/model";
|
||||
import type {AttachVO} from "#/api/property/roomBooking/conferenceAddServices/model";
|
||||
import {addServiceColumns} from "./data";
|
||||
import {Table, InputNumber, TimeRangePicker} from "ant-design-vue";
|
||||
@@ -17,7 +17,7 @@ import {reservationAdd} from "#/api/property/roomBooking/conferenceReservations"
|
||||
import {ref} from "vue";
|
||||
|
||||
const emit = defineEmits<{ reload: [] }>();
|
||||
const conferenceSettingDetail = ref<conferenceSettingsDetail>()
|
||||
const conferenceSettingDetail = ref<ConferenceSettingsDetail>()
|
||||
const addServiceList = ref<AttachVO[]>([])
|
||||
const totalAmount = ref<number>(0)
|
||||
const [BasicForm, formApi] = useVbenForm({
|
||||
@@ -188,7 +188,7 @@ async function changeProjectNum() {
|
||||
conferenceSettingDetail.expenseType == '2' ? conferenceSettingDetail.basePrice + '元' :
|
||||
renderDictValue(conferenceSettingDetail.expenseType, 'wy_fyms')
|
||||
}}</span>
|
||||
<span>开放时段:{{ conferenceSettingDetail.openHours }}</span>
|
||||
<span>开放时段:{{ conferenceSettingDetail.openStartHours+'-'+conferenceSettingDetail.openEndHours }}</span>
|
||||
</div>
|
||||
</div>
|
||||
<BasicForm>
|
||||
|
@@ -53,7 +53,7 @@
|
||||
item.expenseType == '2' ? (item.basePrice+"元") : renderDictValue(item.expenseType, 'wy_fyms')
|
||||
}}
|
||||
</div>
|
||||
<div>开放时段: {{ item.openHours }}</div>
|
||||
<div>开放时段: {{ item.openStartHours+'-'+item.openEndHours }}</div>
|
||||
<div>配套设备: {{ item.baseService }}</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -102,14 +102,18 @@ const simpleImage = Empty.PRESENTED_IMAGE_SIMPLE;
|
||||
|
||||
const meetingList = ref<MeetVO[]>([])
|
||||
async function handleSearch() {
|
||||
let hours = '';
|
||||
let openStartHours = '';
|
||||
let openEndHours = '';
|
||||
if (formState.openHours && formState.openHours.length) {
|
||||
hours = formState.openHours[0]?.format("HH:mm") + '-' + formState.openHours[1]?.format("HH:mm");
|
||||
openStartHours=formState.openHours[0]?.format("HH:mm");
|
||||
openEndHours=formState.openHours[1]?.format("HH:mm");
|
||||
}
|
||||
const obj = {
|
||||
openHours: hours??undefined,
|
||||
personNumber: formState.personNumber,
|
||||
appointmentTime:formState.appointmentTime?formState.appointmentTime.format('YYYY-MM-DD'):undefined
|
||||
openStartHours: openStartHours??undefined,
|
||||
openEndHours:openEndHours??undefined,
|
||||
appointmentTime:formState.appointmentTime?formState.appointmentTime.format('YYYY-MM-DD'):undefined,
|
||||
meetingRoomType:formState.meetingRoomType
|
||||
}
|
||||
meetingList.value =await notlist(obj);
|
||||
}
|
||||
|
@@ -1,5 +1,7 @@
|
||||
<script setup lang="ts">
|
||||
import type {conferenceSettingsDetail} from '#/api/property/roomBooking/conferenceSettings/model';
|
||||
import type {
|
||||
ConferenceSettingsDetail,
|
||||
} from '#/api/property/roomBooking/conferenceSettings/model';
|
||||
import {shallowRef} from 'vue';
|
||||
import {useVbenModal} from '@vben/common-ui';
|
||||
import {Descriptions, DescriptionsItem} from 'ant-design-vue';
|
||||
@@ -19,7 +21,7 @@ const [BasicModal, modalApi] = useVbenModal({
|
||||
},
|
||||
});
|
||||
|
||||
const conferenceSettingsDetail = shallowRef<null | conferenceSettingsDetail>(null);
|
||||
const conferenceSettingsDetail = shallowRef<null | ConferenceSettingsDetail>(null);
|
||||
|
||||
async function handleOpenChange(open: boolean) {
|
||||
if (!open) {
|
||||
@@ -73,7 +75,7 @@ async function handleOpenChange(open: boolean) {
|
||||
/>
|
||||
</DescriptionsItem>
|
||||
<DescriptionsItem label="开放时段" :span="2">
|
||||
{{ conferenceSettingsDetail.openHours }}
|
||||
{{ conferenceSettingsDetail.openStartHours+'-'+ conferenceSettingsDetail.openEndHours}}
|
||||
</DescriptionsItem>
|
||||
<DescriptionsItem label="会议室描述" :span="2">
|
||||
{{ conferenceSettingsDetail.descs }}
|
||||
|
@@ -16,9 +16,10 @@ import { defaultFormValueGetter, useBeforeCloseDiff } from '#/utils/popup';
|
||||
import { modalSchema } from './data';
|
||||
import { TimeRangePicker } from 'ant-design-vue';
|
||||
import { renderDictValue } from '#/utils/render';
|
||||
import { personList } from '#/api/property/resident/person';
|
||||
import { communityTree } from '#/api/property/community';
|
||||
import dayjs from 'dayjs';
|
||||
import {userList} from "#/api/system/user";
|
||||
import {getDictOptions} from "#/utils/dict";
|
||||
const emit = defineEmits<{ reload: [] }>();
|
||||
|
||||
const isUpdate = ref(false);
|
||||
@@ -67,15 +68,15 @@ const [BasicModal, modalApi] = useVbenModal({
|
||||
});
|
||||
const { id } = modalApi.getData() as { id?: number | string };
|
||||
isUpdate.value = !!id;
|
||||
getDictOptions('sys_user_sex')
|
||||
await queryPerson();
|
||||
await initLocationOptions();
|
||||
if (isUpdate.value && id) {
|
||||
const record = await meetInfo(id);
|
||||
record.expenseType = record.expenseType.toString();
|
||||
record.isCheck = record.isCheck.toString();
|
||||
let hour = record.openHours.split('-');
|
||||
if (hour.length > 1) {
|
||||
record.openHours = [dayjs(hour[0], 'HH:mm'), dayjs(hour[1], 'HH:mm')];
|
||||
if (record.openStartHours&&record.openEndHours) {
|
||||
record.openHours = [dayjs(record.openStartHours, 'HH:mm'), dayjs(record.openEndHours, 'HH:mm')];
|
||||
}
|
||||
await formApi.setValues(record);
|
||||
}
|
||||
@@ -95,10 +96,8 @@ async function handleConfirm() {
|
||||
// getValues获取为一个readonly的对象 需要修改必须先深拷贝一次
|
||||
const data = cloneDeep(await formApi.getValues());
|
||||
if (data.openHours) {
|
||||
data.openHours =
|
||||
data.openHours[0]?.format('HH:mm') +
|
||||
'-' +
|
||||
data.openHours[1]?.format('HH:mm');
|
||||
data.openStartHours=data.openHours[0]?.format('HH:mm');
|
||||
data.openEndHours=data.openHours[1]?.format('HH:mm');
|
||||
}
|
||||
await (isUpdate.value ? meetUpdate(data) : meetAdd(data));
|
||||
resetInitialized();
|
||||
@@ -117,19 +116,18 @@ async function handleClosed() {
|
||||
}
|
||||
|
||||
async function queryPerson() {
|
||||
let params = {
|
||||
pageSize: 1000,
|
||||
const res = await userList({
|
||||
pageNum: 1,
|
||||
};
|
||||
const res = await personList(params);
|
||||
pageSize: 1000,
|
||||
});
|
||||
const options = res.rows.map((user) => ({
|
||||
label:
|
||||
user.userName +
|
||||
user.nickName +
|
||||
'-' +
|
||||
renderDictValue(user.gender, 'sys_user_sex') +
|
||||
renderDictValue(user.sex, 'sys_user_sex') +
|
||||
'-' +
|
||||
user.phone,
|
||||
value: user.id,
|
||||
user.phonenumber,
|
||||
value: user.userId,
|
||||
}));
|
||||
formApi.updateSchema([
|
||||
{
|
||||
@@ -143,6 +141,7 @@ async function queryPerson() {
|
||||
]);
|
||||
}
|
||||
|
||||
|
||||
const filterOption = (input: string, option: any) => {
|
||||
return option.label.toLowerCase().indexOf(input.toLowerCase()) >= 0;
|
||||
};
|
||||
|
@@ -76,6 +76,11 @@ export const columns: VxeGridProps['columns'] = [
|
||||
title: '开放时段',
|
||||
field: 'openHours',
|
||||
width:100,
|
||||
slots: {
|
||||
default: ({row}) => {
|
||||
return row.openStartHours+'-'+row.openEndHours;
|
||||
},
|
||||
},
|
||||
},
|
||||
{
|
||||
title: '状态',
|
||||
|
Reference in New Issue
Block a user