diff --git a/src/views/biz/NuBizAdvisoryInfo/h5/AdvisoryInfo.vue b/src/views/biz/NuBizAdvisoryInfo/h5/AdvisoryInfo.vue index 5fe4a44..a2c31e0 100644 --- a/src/views/biz/NuBizAdvisoryInfo/h5/AdvisoryInfo.vue +++ b/src/views/biz/NuBizAdvisoryInfo/h5/AdvisoryInfo.vue @@ -5,7 +5,12 @@

机构名称:{{formData.sysOrgCodeName}}

入住类型:{{formData.advisoryTypeName}}

联系电话:{{formData.tel}}

-

审核状态:{{formData.statusName}}

+

老人姓名:{{formData.oldManName}}

+

老人年龄:{{formData.oldManAge}}

+

老人性别:{{formData.oldManSexName}}

+

医保类型:{{formData.medicalInsuranceTypeName}}

+

报销类型:{{formData.reimbTypeName}}

+

审核状态:{{formData.statusName}}

修改信息 办理入住 @@ -87,7 +92,8 @@ } .advisoryClass{ background-image: url(/@/assets/images/advisory.jpg); - width: 100%; - height: 100%; + background-size: cover; /* 确保图片覆盖整个元素 */ + background-position: center; /* 将图片居中显示 */ + min-height: 100vh; /* 确保至少为视口高度 */ } diff --git a/src/views/biz/NuBizAdvisoryInfo/h5/EditAdvisoryInfo.vue b/src/views/biz/NuBizAdvisoryInfo/h5/EditAdvisoryInfo.vue index 6425b24..07548fc 100644 --- a/src/views/biz/NuBizAdvisoryInfo/h5/EditAdvisoryInfo.vue +++ b/src/views/biz/NuBizAdvisoryInfo/h5/EditAdvisoryInfo.vue @@ -35,6 +35,33 @@ +

+ + + + + + + + + + + + + + + + + + + + + + + + + +
提交 @@ -139,6 +166,14 @@ model.wechatName = wechatName.value; model.status = '1';//强制在提交时把status置为1 审核中 console.log('model--->',model); + + if(model.advisoryType == '1'){ + if(!model.oldManName){ + + return createMessage.error("老人姓名不能为空"); + } + } + const serverUrl = formData.serverUrl; axios.post(serverUrl+"/h5Api/nuBizAdvisoryInfo/edit",model).then(response => { var data = response.data; @@ -185,7 +220,8 @@ } .advisoryClass{ background-image: url(/@/assets/images/advisory.jpg); - width: 100%; - height: 100%; + background-size: cover; /* 确保图片覆盖整个元素 */ + background-position: center; /* 将图片居中显示 */ + min-height: 100vh; /* 确保至少为视口高度 */ } diff --git a/src/views/biz/NuBizAdvisoryInfo/h5/RegisterAdvisoryInfo.vue b/src/views/biz/NuBizAdvisoryInfo/h5/RegisterAdvisoryInfo.vue index fad2be1..1cfce21 100644 --- a/src/views/biz/NuBizAdvisoryInfo/h5/RegisterAdvisoryInfo.vue +++ b/src/views/biz/NuBizAdvisoryInfo/h5/RegisterAdvisoryInfo.vue @@ -35,6 +35,41 @@ + + + + + + + + + + + + + + + 选择 + + + + + + + + + + + + + + + + + + + + 提交 @@ -42,6 +77,7 @@ + @@ -56,6 +92,9 @@ import { useGlobSetting } from "/@/hooks/setting"; import { useRouter } from 'vue-router' import axios from 'axios'; + import CheckNuListModal from '/@/views/biz/NuBizAdvisoryInfo/h5/components/CheckNuListModal.vue'; + + const router = useRouter(); const props = defineProps({ @@ -64,6 +103,7 @@ formBpm: { type: Boolean, default: true } }); const formRef = ref(); + const checkNuListModal = ref(); const useForm = Form.useForm; const emit = defineEmits(['register', 'ok']); const glob = useGlobSetting() @@ -73,15 +113,17 @@ const formData = reactive>({ id: '', name: '', - sex: '1', + sex: '', sysOrgCode: '', tel: '', - advisoryType: '1', - status: '1', + advisoryType: '', + status: '', content: '', serverUrl: '', openId: '', wechatName: '', + nuId: '', + nuName: '', }); const { createMessage } = useMessage(); const labelCol = ref({ xs: { span: 24 }, sm: { span: 5 } }); @@ -108,6 +150,26 @@ console.log('formData--->',formData); } +//选择入住单元 + function handleCheckNu(){ + var serverUrl = formData.serverUrl; + if(!serverUrl){ + createMessage.error('请先选择入住机构!'); + return; + } + checkNuListModal.value.disableSubmit = true; + console.log("🚀 ~ handleCheckNu ~ serverUrl:", serverUrl) + checkNuListModal.value.edit({serverUrl}); + } + +//选择入住单元后的回显 + function handleCheckNuOk(record){ + console.log("🚀 ~ handleCheckNuOk ~ record:", record) + formData.nuId = record.nuId; + formData.nuName = record.nuName; + + } + //提交信息 async function handleSubmit() { try { @@ -139,6 +201,14 @@ model.wechatName = wechatName.value; model.status = '1';//强制在提交时把status置为1 审核中 console.log('model--->',model); + + if(model.advisoryType == '1'){ + if(!model.oldManName){ + + return createMessage.error("老人姓名不能为空"); + } + } + const serverUrl = formData.serverUrl; axios.post(serverUrl+"/h5Api/nuBizAdvisoryInfo/add",model).then(response => { var data = response.data; @@ -188,7 +258,8 @@ } .advisoryClass{ background-image: url(/@/assets/images/advisory.jpg); - width: 100%; - height: 100%; + background-size: cover; /* 确保图片覆盖整个元素 */ + background-position: center; /* 将图片居中显示 */ + min-height: 100vh; /* 确保至少为视口高度 */ } diff --git a/src/views/biz/NuBizAdvisoryInfo/h5/components/CheckNuListForm.vue b/src/views/biz/NuBizAdvisoryInfo/h5/components/CheckNuListForm.vue new file mode 100644 index 0000000..0814882 --- /dev/null +++ b/src/views/biz/NuBizAdvisoryInfo/h5/components/CheckNuListForm.vue @@ -0,0 +1,70 @@ + + + + + diff --git a/src/views/biz/NuBizAdvisoryInfo/h5/components/CheckNuListModal.vue b/src/views/biz/NuBizAdvisoryInfo/h5/components/CheckNuListModal.vue new file mode 100644 index 0000000..88273e3 --- /dev/null +++ b/src/views/biz/NuBizAdvisoryInfo/h5/components/CheckNuListModal.vue @@ -0,0 +1,77 @@ + + + + + + diff --git a/src/views/monitor/datasource/DataSourceDrawer.vue b/src/views/monitor/datasource/DataSourceDrawer.vue index 67058ba..f0dcc5e 100644 --- a/src/views/monitor/datasource/DataSourceDrawer.vue +++ b/src/views/monitor/datasource/DataSourceDrawer.vue @@ -61,7 +61,6 @@ showFooter.value = data?.showFooter ?? true; setDrawerProps({ confirmLoading: false, showFooter: showFooter.value }); isUpdate.value = !!data?.isUpdate; - console.log(unref(isUpdate)); if (unref(isUpdate)){ await getDepartOptions(''); }else{ @@ -93,7 +92,6 @@ async function getDepartOptions(addFLag){ departOptions.value = []; const data = await queryDeparts({ addFLag : addFLag }); - console.log(data); Object.assign(departOptions.value, data); } diff --git a/src/views/monitor/datasource/datasource.api.ts b/src/views/monitor/datasource/datasource.api.ts index 7b9a0f6..76a5116 100644 --- a/src/views/monitor/datasource/datasource.api.ts +++ b/src/views/monitor/datasource/datasource.api.ts @@ -10,6 +10,7 @@ enum Api { testConnection = '/online/cgreport/api/testConnection', deleteBatch = '/sys/dataSource/deleteBatch', departList = '/sys/dataSource/departList', + getByCode = '/sys/dataSource/queryBySysOrgCode', // exportXlsUrl = 'sys/dataSource/exportXls', // importExcelUrl = 'sys/dataSource/importExcel', } @@ -90,3 +91,11 @@ export const batchDeleteDataSource = (params, handleSuccess) => { export const queryDeparts = (params) => { return defHttp.get({ url: Api.departList, params }); }; + +/** + * 查询数据源详情 + * @param params + */ +export const getDataSourceByCode = (params) => { + return defHttp.get({ url: Api.getByCode, params }); +}; diff --git a/src/views/monitor/datasource/datasource.data.ts b/src/views/monitor/datasource/datasource.data.ts index 8de6db7..b0624a1 100644 --- a/src/views/monitor/datasource/datasource.data.ts +++ b/src/views/monitor/datasource/datasource.data.ts @@ -187,7 +187,7 @@ export const formSchema: FormSchema[] = [ field: 'dbUrl', label: '数据源地址', required: true, - component: 'Input', + component: 'InputTextArea', }, { field: 'dbUsername', @@ -208,3 +208,80 @@ export const formSchema: FormSchema[] = [ component: 'InputTextArea', }, ]; + +// 数据源基础表单 +export function useDataSourceFormSchema() { + const dataSourceFormSchema: FormSchema[] = [ + { + field: 'id', + label: 'id', + component: 'Input', + show: false, + }, + { + field: 'sysOrgCode', + label: '所属机构', + component: 'Input', + required: true, + show: false, + }, + { + field: 'code', + label: '数据源编码', + component: 'Input', + // required: true, + dynamicDisabled: true + }, + { + field: 'name', + label: '数据源名称', + component: 'Input', + required: true, + }, + { + field: 'dbType', + label: '数据库类型', + component: 'JDictSelectTag', + required: true, + componentProps: ({ formModel }) => { + return { + dictCode: 'database_type', + onChange: (e: any) => { + formModel = Object.assign(formModel, dbDriverMap[e], dbUrlMap[e]); + }, + }; + }, + }, + { + field: 'dbDriver', + label: '驱动类', + required: true, + component: 'Input', + }, + { + field: 'dbUrl', + label: '数据源地址', + required: true, + component: 'InputTextArea', + }, + { + field: 'dbUsername', + label: '用户名', + required: true, + component: 'Input', + }, + { + field: 'dbPassword', + label: '密码', + required: true, + component: 'InputPassword', + slot: 'pwd', + }, + { + field: 'remark', + label: '备注', + component: 'InputTextArea', + }, + ]; + return { dataSourceFormSchema }; +} diff --git a/src/views/system/depart/components/DataSourceTab.vue b/src/views/system/depart/components/DataSourceTab.vue new file mode 100644 index 0000000..d91121a --- /dev/null +++ b/src/views/system/depart/components/DataSourceTab.vue @@ -0,0 +1,134 @@ + + + + diff --git a/src/views/system/depart/components/DepartLeftTree.vue b/src/views/system/depart/components/DepartLeftTree.vue index f4cad96..52a69a9 100644 --- a/src/views/system/depart/components/DepartLeftTree.vue +++ b/src/views/system/depart/components/DepartLeftTree.vue @@ -1,12 +1,12 @@