Compare commits
3 Commits
bdac1a6090
...
b9a516c469
Author | SHA1 | Date |
---|---|---|
|
b9a516c469 | |
|
33c1c9da9e | |
|
084eb789cf |
|
@ -199,11 +199,11 @@
|
|||
<a-radio-group v-model:value="splitVal" button-style="solid" size="small"
|
||||
@change="splitScreenChanged" style="margin-left: 5px;margin-right: 5px;"
|
||||
v-show="tabActiveKey == 'dataAsync'">
|
||||
<a-radio-button value="sc">源数据</a-radio-button>
|
||||
<a-radio-button value="sc">{{ screenModeTip_left }}</a-radio-button>
|
||||
<a-radio-button value="sc2sed1">分屏1</a-radio-button>
|
||||
<a-radio-button value="sc1sed1">分屏2</a-radio-button>
|
||||
<a-radio-button value="sc1sed2">分屏3</a-radio-button>
|
||||
<a-radio-button value="sed">已选择</a-radio-button>
|
||||
<a-radio-button value="sed">{{ screenModeTip_right }}</a-radio-button>
|
||||
</a-radio-group>
|
||||
<a-divider type="vertical" style="background-color: #CDCDCF" v-show="tabActiveKey == 'dataAsync'" />
|
||||
<a @click="toggleSearchStatus = !toggleSearchStatus" class="toggle-button"
|
||||
|
@ -296,6 +296,16 @@ const props = defineProps({
|
|||
type: String,
|
||||
default: '全部移除'
|
||||
},//全部移除按钮对应文字
|
||||
screenModeTip_left: {
|
||||
type: String,
|
||||
default: '源数据'
|
||||
},//分屏方式最左边提示文字
|
||||
screenModeTip_right: {
|
||||
type: String,
|
||||
default: '已选择'
|
||||
},//分屏方式最右边提示文字
|
||||
|
||||
|
||||
});
|
||||
const emit = defineEmits(['viewTypeChanged', 'orgChanged', 'handleAsync', 'handleAdd', 'handleBatchAdd', 'handleReload', 'handleAddAll', 'handleRemoveAll']);
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
<template>
|
||||
<Header :class="getHeaderClass" style="background-image: url('../../resource/img/bj.png');">
|
||||
<Header :class="getHeaderClass" style="background-image: url('../resource/img/bj.png');">
|
||||
<!-- left start -->
|
||||
<div :class="`${prefixCls}-left`" >
|
||||
<!-- logo -->
|
||||
|
|
|
@ -6,16 +6,16 @@ import { getWeekMonthQuarterYear } from '/@/utils';
|
|||
//列表数据
|
||||
export const columns: BasicColumn[] = [
|
||||
{
|
||||
title: '创建日期',
|
||||
title: '发版日期',
|
||||
align: "center",
|
||||
dataIndex: 'createTime',
|
||||
width: 180,
|
||||
width: 240,
|
||||
},
|
||||
{
|
||||
title: '发版类型',
|
||||
align: "center",
|
||||
dataIndex: 'issueType_dictText',
|
||||
width: 180,
|
||||
width: 240,
|
||||
},
|
||||
{
|
||||
title: '发版内容',
|
||||
|
|
|
@ -1,17 +1,49 @@
|
|||
<template>
|
||||
<div class="p-2">
|
||||
<!--查询区域-->
|
||||
<div class="jeecg-basic-table-form-container">
|
||||
<a-form ref="formRef" @keyup.enter.native="searchQuery" :model="queryParam" :label-col="labelCol"
|
||||
:wrapper-col="wrapperCol">
|
||||
<a-row :gutter="24">
|
||||
<a-col :lg="6">
|
||||
<a-form-item name="createTime">
|
||||
<template #label><span title="发版日期">发版日期</span></template>
|
||||
<a-range-picker value-format="YYYY-MM-DD" v-model:value="queryParam.createTime"
|
||||
class="query-group-cust" />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :lg="6">
|
||||
<a-form-item name="issueType">
|
||||
<template #label><span title="发版类型">发版类型</span></template>
|
||||
<j-select-multiple placeholder="请选择发版类型" v-model:value="queryParam.issueType" dictCode="issue_type"
|
||||
allow-clear />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :xl="6" :lg="7" :md="8" :sm="24">
|
||||
<span style="float: left; overflow: hidden" class="table-page-search-submitButtons">
|
||||
<a-col :lg="6">
|
||||
<a-button type="primary" preIcon="ant-design:search-outlined" @click="searchQuery">查询</a-button>
|
||||
<a-button type="primary" preIcon="ant-design:reload-outlined" @click="searchReset"
|
||||
style="margin-left: 8px">重置</a-button>
|
||||
</a-col>
|
||||
</span>
|
||||
</a-col>
|
||||
</a-row>
|
||||
</a-form>
|
||||
</div>
|
||||
<!--引用表格-->
|
||||
<BasicTable @register="registerTable" >
|
||||
<BasicTable @register="registerTable">
|
||||
<!--插槽:table标题-->
|
||||
<template #tableTitle>
|
||||
<a-button type="primary" v-auth="'IssueInfo:nu_issue_info:add'" @click="handleAdd" preIcon="ant-design:plus-outlined"> 新增</a-button>
|
||||
<a-button type="primary" v-auth="'IssueInfo:nu_issue_info:add'" @click="handleAdd"
|
||||
preIcon="ant-design:plus-outlined"> 新增</a-button>
|
||||
</template>
|
||||
<!--操作栏-->
|
||||
<template #action="{ record }">
|
||||
<TableAction :actions="getTableAction(record)" />
|
||||
</template>
|
||||
<template v-slot:bodyCell="{ column, record, index, text }">
|
||||
<template v-if="column.dataIndex==='content'">
|
||||
<template v-if="column.dataIndex === 'content'">
|
||||
<!--富文本件字段回显插槽-->
|
||||
<a-popover placement="top">
|
||||
<template #content>
|
||||
|
@ -22,7 +54,7 @@
|
|||
</template>
|
||||
<div v-html="text" class="view-container"></div>
|
||||
</a-popover>
|
||||
|
||||
|
||||
</template>
|
||||
</template>
|
||||
</BasicTable>
|
||||
|
@ -33,205 +65,237 @@
|
|||
</template>
|
||||
|
||||
<script lang="ts" name="IssueInfo-nuIssueInfo" setup>
|
||||
import { ref, reactive } from 'vue';
|
||||
import { BasicTable, useTable, TableAction } from '/@/components/Table';
|
||||
import { useListPage } from '/@/hooks/system/useListPage';
|
||||
import { columns, superQuerySchema } from './IssueInfo.data';
|
||||
import { list, deleteOne, batchDelete, getImportUrl, getExportUrl } from './IssueInfo.api';
|
||||
import { downloadFile } from '/@/utils/common/renderUtils';
|
||||
import NuIssueInfoModal from './components/IssueInfoModal.vue'
|
||||
import IssueInfoDetailModal from './components/IssueInfoDetailModal.vue'
|
||||
import { useUserStore } from '/@/store/modules/user';
|
||||
import { ref, reactive } from 'vue';
|
||||
import { BasicTable, useTable, TableAction } from '/@/components/Table';
|
||||
import { useListPage } from '/@/hooks/system/useListPage';
|
||||
import { columns, superQuerySchema } from './IssueInfo.data';
|
||||
import { list, deleteOne, batchDelete, getImportUrl, getExportUrl } from './IssueInfo.api';
|
||||
import { downloadFile } from '/@/utils/common/renderUtils';
|
||||
import NuIssueInfoModal from './components/IssueInfoModal.vue'
|
||||
import IssueInfoDetailModal from './components/IssueInfoDetailModal.vue'
|
||||
import { useUserStore } from '/@/store/modules/user';
|
||||
import JSelectMultiple from '/@/components/Form/src/jeecg/components/JSelectMultiple.vue';
|
||||
import { cloneDeep } from "lodash-es";
|
||||
|
||||
const formRef = ref();
|
||||
const queryParam = reactive<any>({});
|
||||
const toggleSearchStatus = ref<boolean>(false);
|
||||
const registerModal = ref();
|
||||
const issueInfoDetailModal = ref();
|
||||
const userStore = useUserStore();
|
||||
//注册table数据
|
||||
const { prefixCls, tableContext, onExportXls, onImportXls } = useListPage({
|
||||
tableProps: {
|
||||
title: '发版日志',
|
||||
api: list,
|
||||
columns,
|
||||
canResize:false,
|
||||
useSearchForm: false,
|
||||
showIndexColumn: true,
|
||||
actionColumn: {
|
||||
width: 150,
|
||||
fixed: 'right',
|
||||
},
|
||||
beforeFetch: async (params) => {
|
||||
return Object.assign(params, queryParam);
|
||||
},
|
||||
const formRef = ref();
|
||||
const queryParam = reactive<any>({});
|
||||
const toggleSearchStatus = ref<boolean>(false);
|
||||
const registerModal = ref();
|
||||
const issueInfoDetailModal = ref();
|
||||
const userStore = useUserStore();
|
||||
//注册table数据
|
||||
const { prefixCls, tableContext, onExportXls, onImportXls } = useListPage({
|
||||
tableProps: {
|
||||
title: '发版日志',
|
||||
api: list,
|
||||
columns,
|
||||
canResize: false,
|
||||
useSearchForm: false,
|
||||
showIndexColumn: true,
|
||||
actionColumn: {
|
||||
width: 150,
|
||||
fixed: 'right',
|
||||
},
|
||||
exportConfig: {
|
||||
name: "发版日志",
|
||||
url: getExportUrl,
|
||||
params: queryParam,
|
||||
beforeFetch: async (params) => {
|
||||
let rangerQuery = await setRangeQuery();
|
||||
return Object.assign(params, rangerQuery);
|
||||
},
|
||||
importConfig: {
|
||||
url: getImportUrl,
|
||||
success: handleSuccess
|
||||
},
|
||||
});
|
||||
const [registerTable, { reload, collapseAll, updateTableDataRecord, findTableDataRecord, getDataSource }, { rowSelection, selectedRowKeys }] = tableContext;
|
||||
const labelCol = reactive({
|
||||
xs:24,
|
||||
sm:4,
|
||||
xl:6,
|
||||
xxl:4
|
||||
});
|
||||
const wrapperCol = reactive({
|
||||
xs: 24,
|
||||
sm: 20,
|
||||
});
|
||||
},
|
||||
exportConfig: {
|
||||
name: "发版日志",
|
||||
url: getExportUrl,
|
||||
params: queryParam,
|
||||
},
|
||||
importConfig: {
|
||||
url: getImportUrl,
|
||||
success: handleSuccess
|
||||
},
|
||||
});
|
||||
const [registerTable, { reload, collapseAll, updateTableDataRecord, findTableDataRecord, getDataSource }, { rowSelection, selectedRowKeys }] = tableContext;
|
||||
const labelCol = reactive({
|
||||
xs: 24,
|
||||
sm: 4,
|
||||
xl: 6,
|
||||
xxl: 4
|
||||
});
|
||||
const wrapperCol = reactive({
|
||||
xs: 24,
|
||||
sm: 20,
|
||||
});
|
||||
|
||||
// 高级查询配置
|
||||
const superQueryConfig = reactive(superQuerySchema);
|
||||
// 高级查询配置
|
||||
const superQueryConfig = reactive(superQuerySchema);
|
||||
|
||||
/**
|
||||
* 高级查询事件
|
||||
*/
|
||||
function handleSuperQuery(params) {
|
||||
Object.keys(params).map((k) => {
|
||||
queryParam[k] = params[k];
|
||||
});
|
||||
searchQuery();
|
||||
}
|
||||
/**
|
||||
* 高级查询事件
|
||||
*/
|
||||
function handleSuperQuery(params) {
|
||||
Object.keys(params).map((k) => {
|
||||
queryParam[k] = params[k];
|
||||
});
|
||||
searchQuery();
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增事件
|
||||
*/
|
||||
function handleAdd() {
|
||||
registerModal.value.disableSubmit = false;
|
||||
registerModal.value.add();
|
||||
}
|
||||
|
||||
/**
|
||||
* 编辑事件
|
||||
*/
|
||||
function handleEdit(record: Recordable) {
|
||||
registerModal.value.disableSubmit = false;
|
||||
registerModal.value.edit(record);
|
||||
}
|
||||
|
||||
/**
|
||||
* 详情
|
||||
*/
|
||||
function handleDetail(record: Recordable) {
|
||||
issueInfoDetailModal.value.disableSubmit = true;
|
||||
issueInfoDetailModal.value.edit(record);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除事件
|
||||
*/
|
||||
async function handleDelete(record) {
|
||||
await deleteOne({ id: record.id }, handleSuccess);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除事件
|
||||
*/
|
||||
async function batchHandleDelete() {
|
||||
await batchDelete({ ids: selectedRowKeys.value }, handleSuccess);
|
||||
}
|
||||
|
||||
/**
|
||||
* 成功回调
|
||||
*/
|
||||
function handleSuccess() {
|
||||
(selectedRowKeys.value = []) && reload();
|
||||
}
|
||||
|
||||
/**
|
||||
* 操作栏
|
||||
*/
|
||||
function getTableAction(record) {
|
||||
return [
|
||||
{
|
||||
label: '编辑',
|
||||
onClick: handleEdit.bind(null, record),
|
||||
auth: 'IssueInfo:nu_issue_info:edit'
|
||||
/**
|
||||
* 新增事件
|
||||
*/
|
||||
function handleAdd() {
|
||||
registerModal.value.disableSubmit = false;
|
||||
registerModal.value.add();
|
||||
}
|
||||
|
||||
/**
|
||||
* 编辑事件
|
||||
*/
|
||||
function handleEdit(record: Recordable) {
|
||||
registerModal.value.disableSubmit = false;
|
||||
registerModal.value.edit(record);
|
||||
}
|
||||
|
||||
/**
|
||||
* 详情
|
||||
*/
|
||||
function handleDetail(record: Recordable) {
|
||||
issueInfoDetailModal.value.disableSubmit = true;
|
||||
issueInfoDetailModal.value.edit(record);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除事件
|
||||
*/
|
||||
async function handleDelete(record) {
|
||||
await deleteOne({ id: record.id }, handleSuccess);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除事件
|
||||
*/
|
||||
async function batchHandleDelete() {
|
||||
await batchDelete({ ids: selectedRowKeys.value }, handleSuccess);
|
||||
}
|
||||
|
||||
/**
|
||||
* 成功回调
|
||||
*/
|
||||
function handleSuccess() {
|
||||
(selectedRowKeys.value = []) && reload();
|
||||
}
|
||||
|
||||
/**
|
||||
* 操作栏
|
||||
*/
|
||||
function getTableAction(record) {
|
||||
return [
|
||||
{
|
||||
label: '编辑',
|
||||
onClick: handleEdit.bind(null, record),
|
||||
auth: 'IssueInfo:nu_issue_info:edit'
|
||||
},
|
||||
{
|
||||
label: '详情',
|
||||
onClick: handleDetail.bind(null, record),
|
||||
}, {
|
||||
label: '删除',
|
||||
popConfirm: {
|
||||
title: '是否确认删除',
|
||||
confirm: handleDelete.bind(null, record),
|
||||
placement: 'topLeft',
|
||||
},
|
||||
{
|
||||
label: '详情',
|
||||
onClick: handleDetail.bind(null, record),
|
||||
}, {
|
||||
label: '删除',
|
||||
popConfirm: {
|
||||
title: '是否确认删除',
|
||||
confirm: handleDelete.bind(null, record),
|
||||
placement: 'topLeft',
|
||||
},
|
||||
auth: 'IssueInfo:nu_issue_info:delete'
|
||||
auth: 'IssueInfo:nu_issue_info:delete'
|
||||
}
|
||||
];
|
||||
}
|
||||
|
||||
/**
|
||||
* 下拉操作栏
|
||||
*/
|
||||
function getDropDownAction(record) {
|
||||
return [
|
||||
|
||||
]
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询
|
||||
*/
|
||||
function searchQuery() {
|
||||
reload();
|
||||
}
|
||||
|
||||
/**
|
||||
* 重置
|
||||
*/
|
||||
function searchReset() {
|
||||
formRef.value.resetFields();
|
||||
selectedRowKeys.value = [];
|
||||
//刷新数据
|
||||
reload();
|
||||
}
|
||||
|
||||
|
||||
let rangeField = 'createTime,'
|
||||
|
||||
/**
|
||||
* 设置范围查询条件
|
||||
*/
|
||||
async function setRangeQuery() {
|
||||
let queryParamClone = cloneDeep(queryParam);
|
||||
if (rangeField) {
|
||||
let fieldsValue = rangeField.split(',');
|
||||
fieldsValue.forEach(item => {
|
||||
if (queryParamClone[item]) {
|
||||
let range = queryParamClone[item];
|
||||
queryParamClone[item + '_begin'] = range[0];
|
||||
queryParamClone[item + '_end'] = range[1];
|
||||
delete queryParamClone[item];
|
||||
} else {
|
||||
queryParamClone[item + '_begin'] = '';
|
||||
queryParamClone[item + '_end'] = '';
|
||||
}
|
||||
];
|
||||
})
|
||||
}
|
||||
|
||||
/**
|
||||
* 下拉操作栏
|
||||
*/
|
||||
function getDropDownAction(record) {
|
||||
return [
|
||||
|
||||
]
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询
|
||||
*/
|
||||
function searchQuery() {
|
||||
reload();
|
||||
}
|
||||
|
||||
/**
|
||||
* 重置
|
||||
*/
|
||||
function searchReset() {
|
||||
formRef.value.resetFields();
|
||||
selectedRowKeys.value = [];
|
||||
//刷新数据
|
||||
reload();
|
||||
}
|
||||
|
||||
|
||||
|
||||
return queryParamClone;
|
||||
}
|
||||
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped>
|
||||
.jeecg-basic-table-form-container {
|
||||
padding: 0;
|
||||
.table-page-search-submitButtons {
|
||||
display: block;
|
||||
margin-bottom: 24px;
|
||||
white-space: nowrap;
|
||||
}
|
||||
.query-group-cust{
|
||||
min-width: 100px !important;
|
||||
}
|
||||
.query-group-split-cust{
|
||||
width: 30px;
|
||||
display: inline-block;
|
||||
text-align: center
|
||||
}
|
||||
.ant-form-item:not(.ant-form-item-with-help){
|
||||
margin-bottom: 16px;
|
||||
height: 32px;
|
||||
}
|
||||
:deep(.ant-picker),:deep(.ant-input-number){
|
||||
width: 100%;
|
||||
}
|
||||
}
|
||||
.view-container{
|
||||
display: -webkit-box;
|
||||
-webkit-box-orient: vertical;
|
||||
-webkit-line-clamp: 1; /* 限制文本为1行 */
|
||||
overflow: hidden;
|
||||
height: 25px;
|
||||
.jeecg-basic-table-form-container {
|
||||
padding: 0;
|
||||
|
||||
.table-page-search-submitButtons {
|
||||
display: block;
|
||||
margin-bottom: 24px;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.query-group-cust {
|
||||
min-width: 100px !important;
|
||||
}
|
||||
|
||||
.query-group-split-cust {
|
||||
width: 30px;
|
||||
display: inline-block;
|
||||
text-align: center
|
||||
}
|
||||
|
||||
.ant-form-item:not(.ant-form-item-with-help) {
|
||||
margin-bottom: 16px;
|
||||
height: 32px;
|
||||
}
|
||||
|
||||
:deep(.ant-picker),
|
||||
:deep(.ant-input-number) {
|
||||
width: 100%;
|
||||
}
|
||||
}
|
||||
|
||||
.view-container {
|
||||
display: -webkit-box;
|
||||
-webkit-box-orient: vertical;
|
||||
-webkit-line-clamp: 1;
|
||||
/* 限制文本为1行 */
|
||||
overflow: hidden;
|
||||
height: 25px;
|
||||
}
|
||||
</style>
|
||||
|
|
|
@ -2,18 +2,23 @@
|
|||
<a-spin :spinning="confirmLoading">
|
||||
<JFormContainer :disabled="disabled">
|
||||
<template #detail>
|
||||
<a-form ref="formRef" class="antd-modal-form" :labelCol="labelCol" :wrapperCol="wrapperCol" name="NuIssueInfoForm">
|
||||
<a-form ref="formRef" class="antd-modal-form" :labelCol="labelCol" :wrapperCol="wrapperCol"
|
||||
name="NuIssueInfoForm">
|
||||
<a-row style="padding:14px;">
|
||||
<a-col :span="24" style="text-align: center;">
|
||||
<a-col :span="24" style="text-align: center;">
|
||||
<p>
|
||||
<span>发版类型:</span>
|
||||
<span>{{formData.issueType_dictText}}</span>
|
||||
<span>{{ formData.issueType_dictText }}</span>
|
||||
</p>
|
||||
</a-col>
|
||||
<a-col :span="24" style="margin-top: 20px;">
|
||||
<p>
|
||||
<span>发版日期:</span>
|
||||
<span>{{ formData.createTime }}</span>
|
||||
</p>
|
||||
</a-col>
|
||||
<a-col :span="24" style="margin-top: 20px;">
|
||||
<!-- <p>发版内容:</p> -->
|
||||
<div v-html="formData.content"></div>
|
||||
</a-col>
|
||||
</a-col>
|
||||
</a-row>
|
||||
</a-form>
|
||||
</template>
|
||||
|
@ -22,133 +27,134 @@
|
|||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import { ref, reactive, defineExpose, nextTick, defineProps, computed, onMounted } from 'vue';
|
||||
import { defHttp } from '/@/utils/http/axios';
|
||||
import { useMessage } from '/@/hooks/web/useMessage';
|
||||
import JDictSelectTag from '/@/components/Form/src/jeecg/components/JDictSelectTag.vue';
|
||||
import JEditor from '/@/components/Form/src/jeecg/components/JEditor.vue';
|
||||
import { getValueType } from '/@/utils';
|
||||
import { saveOrUpdate } from '../IssueInfo.api';
|
||||
import { Form } from 'ant-design-vue';
|
||||
import JFormContainer from '/@/components/Form/src/container/JFormContainer.vue';
|
||||
const props = defineProps({
|
||||
formDisabled: { type: Boolean, default: false },
|
||||
formData: { type: Object, default: () => ({})},
|
||||
formBpm: { type: Boolean, default: true }
|
||||
});
|
||||
const formRef = ref();
|
||||
const useForm = Form.useForm;
|
||||
const emit = defineEmits(['register', 'ok']);
|
||||
const formData = reactive<Record<string, any>>({
|
||||
id: '',
|
||||
issueType: '',
|
||||
issueType_dictText: '',
|
||||
content: '',
|
||||
});
|
||||
const { createMessage } = useMessage();
|
||||
const labelCol = ref<any>({ xs: { span: 24 }, sm: { span: 5 } });
|
||||
const wrapperCol = ref<any>({ xs: { span: 24 }, sm: { span: 16 } });
|
||||
const confirmLoading = ref<boolean>(false);
|
||||
//表单验证
|
||||
const validatorRules = reactive({
|
||||
});
|
||||
const { resetFields, validate, validateInfos } = useForm(formData, validatorRules, { immediate: false });
|
||||
import { ref, reactive, defineExpose, nextTick, defineProps, computed, onMounted } from 'vue';
|
||||
import { defHttp } from '/@/utils/http/axios';
|
||||
import { useMessage } from '/@/hooks/web/useMessage';
|
||||
import JDictSelectTag from '/@/components/Form/src/jeecg/components/JDictSelectTag.vue';
|
||||
import JEditor from '/@/components/Form/src/jeecg/components/JEditor.vue';
|
||||
import { getValueType } from '/@/utils';
|
||||
import { saveOrUpdate } from '../IssueInfo.api';
|
||||
import { Form } from 'ant-design-vue';
|
||||
import JFormContainer from '/@/components/Form/src/container/JFormContainer.vue';
|
||||
const props = defineProps({
|
||||
formDisabled: { type: Boolean, default: false },
|
||||
formData: { type: Object, default: () => ({}) },
|
||||
formBpm: { type: Boolean, default: true }
|
||||
});
|
||||
const formRef = ref();
|
||||
const useForm = Form.useForm;
|
||||
const emit = defineEmits(['register', 'ok']);
|
||||
const formData = reactive<Record<string, any>>({
|
||||
id: '',
|
||||
createTime: '',
|
||||
issueType: '',
|
||||
issueType_dictText: '',
|
||||
content: '',
|
||||
});
|
||||
const { createMessage } = useMessage();
|
||||
const labelCol = ref<any>({ xs: { span: 24 }, sm: { span: 5 } });
|
||||
const wrapperCol = ref<any>({ xs: { span: 24 }, sm: { span: 16 } });
|
||||
const confirmLoading = ref<boolean>(false);
|
||||
//表单验证
|
||||
const validatorRules = reactive({
|
||||
});
|
||||
const { resetFields, validate, validateInfos } = useForm(formData, validatorRules, { immediate: false });
|
||||
|
||||
// 表单禁用
|
||||
const disabled = computed(()=>{
|
||||
if(props.formBpm === true){
|
||||
if(props.formData.disabled === false){
|
||||
return false;
|
||||
}else{
|
||||
return true;
|
||||
// 表单禁用
|
||||
const disabled = computed(() => {
|
||||
if (props.formBpm === true) {
|
||||
if (props.formData.disabled === false) {
|
||||
return false;
|
||||
} else {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return props.formDisabled;
|
||||
});
|
||||
|
||||
|
||||
/**
|
||||
* 新增
|
||||
*/
|
||||
function add() {
|
||||
edit({});
|
||||
}
|
||||
|
||||
/**
|
||||
* 编辑
|
||||
*/
|
||||
function edit(record) {
|
||||
nextTick(() => {
|
||||
resetFields();
|
||||
const tmpData = {};
|
||||
Object.keys(formData).forEach((key) => {
|
||||
if (record.hasOwnProperty(key)) {
|
||||
tmpData[key] = record[key]
|
||||
}
|
||||
})
|
||||
//赋值
|
||||
Object.assign(formData, tmpData);
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* 提交数据
|
||||
*/
|
||||
async function submitForm() {
|
||||
try {
|
||||
// 触发表单验证
|
||||
await validate();
|
||||
} catch ({ errorFields }) {
|
||||
if (errorFields) {
|
||||
const firstField = errorFields[0];
|
||||
if (firstField) {
|
||||
formRef.value.scrollToField(firstField.name, { behavior: 'smooth', block: 'center' });
|
||||
}
|
||||
}
|
||||
return props.formDisabled;
|
||||
});
|
||||
|
||||
|
||||
/**
|
||||
* 新增
|
||||
*/
|
||||
function add() {
|
||||
edit({});
|
||||
return Promise.reject(errorFields);
|
||||
}
|
||||
|
||||
/**
|
||||
* 编辑
|
||||
*/
|
||||
function edit(record) {
|
||||
nextTick(() => {
|
||||
resetFields();
|
||||
const tmpData = {};
|
||||
Object.keys(formData).forEach((key) => {
|
||||
if(record.hasOwnProperty(key)){
|
||||
tmpData[key] = record[key]
|
||||
}
|
||||
})
|
||||
//赋值
|
||||
Object.assign(formData, tmpData);
|
||||
confirmLoading.value = true;
|
||||
const isUpdate = ref<boolean>(false);
|
||||
//时间格式化
|
||||
let model = formData;
|
||||
if (model.id) {
|
||||
isUpdate.value = true;
|
||||
}
|
||||
//循环数据
|
||||
for (let data in model) {
|
||||
//如果该数据是数组并且是字符串类型
|
||||
if (model[data] instanceof Array) {
|
||||
let valueType = getValueType(formRef.value.getProps, data);
|
||||
//如果是字符串类型的需要变成以逗号分割的字符串
|
||||
if (valueType === 'string') {
|
||||
model[data] = model[data].join(',');
|
||||
}
|
||||
}
|
||||
}
|
||||
await saveOrUpdate(model, isUpdate.value)
|
||||
.then((res) => {
|
||||
if (res.success) {
|
||||
createMessage.success(res.message);
|
||||
emit('ok');
|
||||
} else {
|
||||
createMessage.warning(res.message);
|
||||
}
|
||||
})
|
||||
.finally(() => {
|
||||
confirmLoading.value = false;
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* 提交数据
|
||||
*/
|
||||
async function submitForm() {
|
||||
try {
|
||||
// 触发表单验证
|
||||
await validate();
|
||||
} catch ({ errorFields }) {
|
||||
if (errorFields) {
|
||||
const firstField = errorFields[0];
|
||||
if (firstField) {
|
||||
formRef.value.scrollToField(firstField.name, { behavior: 'smooth', block: 'center' });
|
||||
}
|
||||
}
|
||||
return Promise.reject(errorFields);
|
||||
}
|
||||
confirmLoading.value = true;
|
||||
const isUpdate = ref<boolean>(false);
|
||||
//时间格式化
|
||||
let model = formData;
|
||||
if (model.id) {
|
||||
isUpdate.value = true;
|
||||
}
|
||||
//循环数据
|
||||
for (let data in model) {
|
||||
//如果该数据是数组并且是字符串类型
|
||||
if (model[data] instanceof Array) {
|
||||
let valueType = getValueType(formRef.value.getProps, data);
|
||||
//如果是字符串类型的需要变成以逗号分割的字符串
|
||||
if (valueType === 'string') {
|
||||
model[data] = model[data].join(',');
|
||||
}
|
||||
}
|
||||
}
|
||||
await saveOrUpdate(model, isUpdate.value)
|
||||
.then((res) => {
|
||||
if (res.success) {
|
||||
createMessage.success(res.message);
|
||||
emit('ok');
|
||||
} else {
|
||||
createMessage.warning(res.message);
|
||||
}
|
||||
})
|
||||
.finally(() => {
|
||||
confirmLoading.value = false;
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
defineExpose({
|
||||
add,
|
||||
edit,
|
||||
submitForm,
|
||||
});
|
||||
defineExpose({
|
||||
add,
|
||||
edit,
|
||||
submitForm,
|
||||
});
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped>
|
||||
.antd-modal-form {
|
||||
padding: 14px;
|
||||
}
|
||||
.antd-modal-form {
|
||||
padding: 14px;
|
||||
}
|
||||
</style>
|
||||
|
|
|
@ -2,18 +2,28 @@
|
|||
<a-spin :spinning="confirmLoading">
|
||||
<JFormContainer :disabled="disabled">
|
||||
<template #detail>
|
||||
<a-form ref="formRef" class="antd-modal-form" :labelCol="labelCol" :wrapperCol="wrapperCol" name="NuIssueInfoForm">
|
||||
<a-form ref="formRef" class="antd-modal-form" :labelCol="labelCol" :wrapperCol="wrapperCol"
|
||||
name="NuIssueInfoForm">
|
||||
<a-row>
|
||||
<a-col :span="24">
|
||||
<a-form-item label="发版类型" v-bind="validateInfos.issueType" id="NuIssueInfoForm-issueType" name="issueType">
|
||||
<j-dict-select-tag type='radio' v-model:value="formData.issueType" dictCode="issue_type" placeholder="请选择发版类型" allow-clear />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-item label="发版内容" v-bind="validateInfos.content" id="NuIssueInfoForm-content" name="content">
|
||||
<j-editor v-model:value="formData.content" :autoFocus="false"/>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-item label="发版类型" v-bind="validateInfos.issueType" id="NuIssueInfoForm-issueType"
|
||||
name="issueType">
|
||||
<j-dict-select-tag type='radio' v-model:value="formData.issueType" dictCode="issue_type"
|
||||
placeholder="请选择发版类型" allow-clear />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-item label="发版日期" v-bind="validateInfos.createTime" id="NuIssueInfoForm-createTime"
|
||||
name="createTime">
|
||||
<a-date-picker placeholder="请选择发版日期" v-model:value="formData.createTime" showTime
|
||||
value-format="YYYY-MM-DD HH:mm:ss" style="width: 100%" allow-clear />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-item label="发版内容" v-bind="validateInfos.content" id="NuIssueInfoForm-content" name="content">
|
||||
<j-editor v-model:value="formData.content" :autoFocus="false" />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
</a-form>
|
||||
</template>
|
||||
|
@ -22,134 +32,134 @@
|
|||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import { ref, reactive, defineExpose, nextTick, defineProps, computed, onMounted } from 'vue';
|
||||
import { defHttp } from '/@/utils/http/axios';
|
||||
import { useMessage } from '/@/hooks/web/useMessage';
|
||||
import JDictSelectTag from '/@/components/Form/src/jeecg/components/JDictSelectTag.vue';
|
||||
import JEditor from '/@/components/Form/src/jeecg/components/JEditor.vue';
|
||||
import { getValueType } from '/@/utils';
|
||||
import { saveOrUpdate } from '../IssueInfo.api';
|
||||
import { Form } from 'ant-design-vue';
|
||||
import JFormContainer from '/@/components/Form/src/container/JFormContainer.vue';
|
||||
const props = defineProps({
|
||||
formDisabled: { type: Boolean, default: false },
|
||||
formData: { type: Object, default: () => ({})},
|
||||
formBpm: { type: Boolean, default: true }
|
||||
});
|
||||
const formRef = ref();
|
||||
const useForm = Form.useForm;
|
||||
const emit = defineEmits(['register', 'ok']);
|
||||
const formData = reactive<Record<string, any>>({
|
||||
id: '',
|
||||
issueType: '',
|
||||
content: '',
|
||||
});
|
||||
const { createMessage } = useMessage();
|
||||
const labelCol = ref<any>({ xs: { span: 24 }, sm: { span: 5 } });
|
||||
const wrapperCol = ref<any>({ xs: { span: 24 }, sm: { span: 16 } });
|
||||
const confirmLoading = ref<boolean>(false);
|
||||
//表单验证
|
||||
const validatorRules = reactive({
|
||||
issueType: [{ required: true, message: '请选择发版类型!'},],
|
||||
content: [{ required: true, message: '请输入发版内容!'},],
|
||||
});
|
||||
const { resetFields, validate, validateInfos } = useForm(formData, validatorRules, { immediate: false });
|
||||
import { ref, reactive, defineExpose, nextTick, defineProps, computed, onMounted } from 'vue';
|
||||
import { defHttp } from '/@/utils/http/axios';
|
||||
import { useMessage } from '/@/hooks/web/useMessage';
|
||||
import JDictSelectTag from '/@/components/Form/src/jeecg/components/JDictSelectTag.vue';
|
||||
import JEditor from '/@/components/Form/src/jeecg/components/JEditor.vue';
|
||||
import { getValueType } from '/@/utils';
|
||||
import { saveOrUpdate } from '../IssueInfo.api';
|
||||
import { Form } from 'ant-design-vue';
|
||||
import JFormContainer from '/@/components/Form/src/container/JFormContainer.vue';
|
||||
const props = defineProps({
|
||||
formDisabled: { type: Boolean, default: false },
|
||||
formData: { type: Object, default: () => ({}) },
|
||||
formBpm: { type: Boolean, default: true }
|
||||
});
|
||||
const formRef = ref();
|
||||
const useForm = Form.useForm;
|
||||
const emit = defineEmits(['register', 'ok']);
|
||||
const formData = reactive<Record<string, any>>({
|
||||
id: '',
|
||||
issueType: '',
|
||||
content: '',
|
||||
});
|
||||
const { createMessage } = useMessage();
|
||||
const labelCol = ref<any>({ xs: { span: 24 }, sm: { span: 5 } });
|
||||
const wrapperCol = ref<any>({ xs: { span: 24 }, sm: { span: 16 } });
|
||||
const confirmLoading = ref<boolean>(false);
|
||||
//表单验证
|
||||
const validatorRules = reactive({
|
||||
issueType: [{ required: true, message: '请选择发版类型!' },],
|
||||
content: [{ required: true, message: '请输入发版内容!' },],
|
||||
});
|
||||
const { resetFields, validate, validateInfos } = useForm(formData, validatorRules, { immediate: false });
|
||||
|
||||
// 表单禁用
|
||||
const disabled = computed(()=>{
|
||||
if(props.formBpm === true){
|
||||
if(props.formData.disabled === false){
|
||||
return false;
|
||||
}else{
|
||||
return true;
|
||||
// 表单禁用
|
||||
const disabled = computed(() => {
|
||||
if (props.formBpm === true) {
|
||||
if (props.formData.disabled === false) {
|
||||
return false;
|
||||
} else {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return props.formDisabled;
|
||||
});
|
||||
|
||||
|
||||
/**
|
||||
* 新增
|
||||
*/
|
||||
function add() {
|
||||
edit({});
|
||||
}
|
||||
|
||||
/**
|
||||
* 编辑
|
||||
*/
|
||||
function edit(record) {
|
||||
nextTick(() => {
|
||||
resetFields();
|
||||
const tmpData = {};
|
||||
Object.keys(formData).forEach((key) => {
|
||||
if (record.hasOwnProperty(key)) {
|
||||
tmpData[key] = record[key]
|
||||
}
|
||||
})
|
||||
//赋值
|
||||
Object.assign(formData, tmpData);
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* 提交数据
|
||||
*/
|
||||
async function submitForm() {
|
||||
try {
|
||||
// 触发表单验证
|
||||
await validate();
|
||||
} catch ({ errorFields }) {
|
||||
if (errorFields) {
|
||||
const firstField = errorFields[0];
|
||||
if (firstField) {
|
||||
formRef.value.scrollToField(firstField.name, { behavior: 'smooth', block: 'center' });
|
||||
}
|
||||
}
|
||||
return props.formDisabled;
|
||||
});
|
||||
|
||||
|
||||
/**
|
||||
* 新增
|
||||
*/
|
||||
function add() {
|
||||
edit({});
|
||||
return Promise.reject(errorFields);
|
||||
}
|
||||
|
||||
/**
|
||||
* 编辑
|
||||
*/
|
||||
function edit(record) {
|
||||
nextTick(() => {
|
||||
resetFields();
|
||||
const tmpData = {};
|
||||
Object.keys(formData).forEach((key) => {
|
||||
if(record.hasOwnProperty(key)){
|
||||
tmpData[key] = record[key]
|
||||
}
|
||||
})
|
||||
//赋值
|
||||
Object.assign(formData, tmpData);
|
||||
confirmLoading.value = true;
|
||||
const isUpdate = ref<boolean>(false);
|
||||
//时间格式化
|
||||
let model = formData;
|
||||
if (model.id) {
|
||||
isUpdate.value = true;
|
||||
}
|
||||
//循环数据
|
||||
for (let data in model) {
|
||||
//如果该数据是数组并且是字符串类型
|
||||
if (model[data] instanceof Array) {
|
||||
let valueType = getValueType(formRef.value.getProps, data);
|
||||
//如果是字符串类型的需要变成以逗号分割的字符串
|
||||
if (valueType === 'string') {
|
||||
model[data] = model[data].join(',');
|
||||
}
|
||||
}
|
||||
}
|
||||
await saveOrUpdate(model, isUpdate.value)
|
||||
.then((res) => {
|
||||
if (res.success) {
|
||||
createMessage.success(res.message);
|
||||
emit('ok');
|
||||
} else {
|
||||
createMessage.warning(res.message);
|
||||
}
|
||||
})
|
||||
.finally(() => {
|
||||
confirmLoading.value = false;
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* 提交数据
|
||||
*/
|
||||
async function submitForm() {
|
||||
try {
|
||||
// 触发表单验证
|
||||
await validate();
|
||||
} catch ({ errorFields }) {
|
||||
if (errorFields) {
|
||||
const firstField = errorFields[0];
|
||||
if (firstField) {
|
||||
formRef.value.scrollToField(firstField.name, { behavior: 'smooth', block: 'center' });
|
||||
}
|
||||
}
|
||||
return Promise.reject(errorFields);
|
||||
}
|
||||
confirmLoading.value = true;
|
||||
const isUpdate = ref<boolean>(false);
|
||||
//时间格式化
|
||||
let model = formData;
|
||||
if (model.id) {
|
||||
isUpdate.value = true;
|
||||
}
|
||||
//循环数据
|
||||
for (let data in model) {
|
||||
//如果该数据是数组并且是字符串类型
|
||||
if (model[data] instanceof Array) {
|
||||
let valueType = getValueType(formRef.value.getProps, data);
|
||||
//如果是字符串类型的需要变成以逗号分割的字符串
|
||||
if (valueType === 'string') {
|
||||
model[data] = model[data].join(',');
|
||||
}
|
||||
}
|
||||
}
|
||||
await saveOrUpdate(model, isUpdate.value)
|
||||
.then((res) => {
|
||||
if (res.success) {
|
||||
createMessage.success(res.message);
|
||||
emit('ok');
|
||||
} else {
|
||||
createMessage.warning(res.message);
|
||||
}
|
||||
})
|
||||
.finally(() => {
|
||||
confirmLoading.value = false;
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
defineExpose({
|
||||
add,
|
||||
edit,
|
||||
submitForm,
|
||||
});
|
||||
defineExpose({
|
||||
add,
|
||||
edit,
|
||||
submitForm,
|
||||
});
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped>
|
||||
.antd-modal-form {
|
||||
padding: 14px;
|
||||
}
|
||||
.antd-modal-form {
|
||||
padding: 14px;
|
||||
}
|
||||
</style>
|
||||
|
|
|
@ -0,0 +1,79 @@
|
|||
import { defHttp } from '/@/utils/http/axios';
|
||||
import { useMessage } from "/@/hooks/web/useMessage";
|
||||
|
||||
const { createConfirm } = useMessage();
|
||||
|
||||
enum Api {
|
||||
list = '/admin/orginfo/list',
|
||||
save='/admin/orginfo/add',
|
||||
edit='/admin/orginfo/edit',
|
||||
deleteOne = '/admin/orginfo/delete',
|
||||
deleteBatch = '/admin/orginfo/deleteBatch',
|
||||
importExcel = '/admin/orginfo/importExcel',
|
||||
exportXls = '/admin/orginfo/exportXls',
|
||||
getOrgInfo = '/admin/orginfo/getOrgInfo',
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出api
|
||||
* @param params
|
||||
*/
|
||||
export const getExportUrl = Api.exportXls;
|
||||
|
||||
/**
|
||||
* 导入api
|
||||
*/
|
||||
export const getImportUrl = Api.importExcel;
|
||||
|
||||
/**
|
||||
* 列表接口
|
||||
* @param params
|
||||
*/
|
||||
export const list = (params) => defHttp.get({ url: Api.list, params });
|
||||
|
||||
/**
|
||||
* 删除单个
|
||||
* @param params
|
||||
* @param handleSuccess
|
||||
*/
|
||||
export const deleteOne = (params,handleSuccess) => {
|
||||
return defHttp.delete({url: Api.deleteOne, params}, {joinParamsToUrl: true}).then(() => {
|
||||
handleSuccess();
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除
|
||||
* @param params
|
||||
* @param handleSuccess
|
||||
*/
|
||||
export const batchDelete = (params, handleSuccess) => {
|
||||
createConfirm({
|
||||
iconType: 'warning',
|
||||
title: '确认删除',
|
||||
content: '是否删除选中数据',
|
||||
okText: '确认',
|
||||
cancelText: '取消',
|
||||
onOk: () => {
|
||||
return defHttp.delete({url: Api.deleteBatch, data: params}, {joinParamsToUrl: true}).then(() => {
|
||||
handleSuccess();
|
||||
});
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* 保存或者更新
|
||||
* @param params
|
||||
* @param isUpdate
|
||||
*/
|
||||
export const saveOrUpdate = (params, isUpdate) => {
|
||||
let url = isUpdate ? Api.edit : Api.save;
|
||||
return defHttp.post({ url: url, params }, { isTransformResponse: false });
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取机构详细信息
|
||||
* @param params orgCode 机构编码
|
||||
*/
|
||||
export const getOrgInfo = (params) => defHttp.get({ url: Api.getOrgInfo, params });
|
|
@ -0,0 +1,228 @@
|
|||
import {BasicColumn} from '/@/components/Table';
|
||||
import {FormSchema} from '/@/components/Table';
|
||||
import { rules} from '/@/utils/helper/validator';
|
||||
import { render } from '/@/utils/common/renderUtils';
|
||||
import { getWeekMonthQuarterYear } from '/@/utils';
|
||||
//列表数据
|
||||
export const columns: BasicColumn[] = [
|
||||
{
|
||||
title: '机构ID sys_depart.id 同管理端nu_org_apply_info.pk_id',
|
||||
align: "center",
|
||||
dataIndex: 'pkId'
|
||||
},
|
||||
{
|
||||
title: '微信id',
|
||||
align: "center",
|
||||
dataIndex: 'openId'
|
||||
},
|
||||
{
|
||||
title: '微信名称',
|
||||
align: "center",
|
||||
dataIndex: 'wechatName'
|
||||
},
|
||||
{
|
||||
title: '联系电话',
|
||||
align: "center",
|
||||
dataIndex: 'tel'
|
||||
},
|
||||
{
|
||||
title: '更新日期',
|
||||
align: "center",
|
||||
dataIndex: 'updateTime'
|
||||
},
|
||||
{
|
||||
title: '咨询人姓名',
|
||||
align: "center",
|
||||
dataIndex: 'name'
|
||||
},
|
||||
{
|
||||
title: '性别',
|
||||
align: "center",
|
||||
dataIndex: 'sex'
|
||||
},
|
||||
{
|
||||
title: '民族',
|
||||
align: "center",
|
||||
dataIndex: 'national'
|
||||
},
|
||||
{
|
||||
title: '出生日期',
|
||||
align: "center",
|
||||
dataIndex: 'birthDate',
|
||||
customRender:({text}) =>{
|
||||
text = !text ? "" : (text.length > 10 ? text.substr(0,10) : text);
|
||||
return text;
|
||||
},
|
||||
},
|
||||
{
|
||||
title: '住址',
|
||||
align: "center",
|
||||
dataIndex: 'idCardAddress'
|
||||
},
|
||||
{
|
||||
title: '身份证号',
|
||||
align: "center",
|
||||
dataIndex: 'idCard'
|
||||
},
|
||||
{
|
||||
title: '签发机关',
|
||||
align: "center",
|
||||
dataIndex: 'issuingAuthority'
|
||||
},
|
||||
{
|
||||
title: '有效开始日期',
|
||||
align: "center",
|
||||
dataIndex: 'startTime',
|
||||
customRender:({text}) =>{
|
||||
text = !text ? "" : (text.length > 10 ? text.substr(0,10) : text);
|
||||
return text;
|
||||
},
|
||||
},
|
||||
{
|
||||
title: '有效结束日期',
|
||||
align: "center",
|
||||
dataIndex: 'endTime',
|
||||
customRender:({text}) =>{
|
||||
text = !text ? "" : (text.length > 10 ? text.substr(0,10) : text);
|
||||
return text;
|
||||
},
|
||||
},
|
||||
{
|
||||
title: '身份证正面',
|
||||
align: "center",
|
||||
dataIndex: 'cardZmPath'
|
||||
},
|
||||
{
|
||||
title: '身份证反面',
|
||||
align: "center",
|
||||
dataIndex: 'cardFmPath'
|
||||
},
|
||||
{
|
||||
title: '营业执照照片',
|
||||
align: "center",
|
||||
dataIndex: 'comBusinessLicense'
|
||||
},
|
||||
{
|
||||
title: '企业名称',
|
||||
align: "center",
|
||||
dataIndex: 'comName'
|
||||
},
|
||||
{
|
||||
title: '企业注册地址',
|
||||
align: "center",
|
||||
dataIndex: 'comRegisterAddress'
|
||||
},
|
||||
{
|
||||
title: '企业信用代码',
|
||||
align: "center",
|
||||
dataIndex: 'comCreditCode'
|
||||
},
|
||||
{
|
||||
title: '企业法人',
|
||||
align: "center",
|
||||
dataIndex: 'comLegalPerson'
|
||||
},
|
||||
{
|
||||
title: '机构地址',
|
||||
align: "center",
|
||||
dataIndex: 'orgAddress'
|
||||
},
|
||||
{
|
||||
title: '机构位置坐标:经度',
|
||||
align: "center",
|
||||
dataIndex: 'orgCoordinateLo'
|
||||
},
|
||||
{
|
||||
title: '机构位置坐标:维度',
|
||||
align: "center",
|
||||
dataIndex: 'orgCoordinateLa'
|
||||
},
|
||||
{
|
||||
title: '机构负责人',
|
||||
align: "center",
|
||||
dataIndex: 'orgLeader'
|
||||
},
|
||||
{
|
||||
title: '机构负责人电话',
|
||||
align: "center",
|
||||
dataIndex: 'orgLeaderPhone'
|
||||
},
|
||||
{
|
||||
title: '机构楼宇牌号',
|
||||
align: "center",
|
||||
dataIndex: 'orgBuildingNumber'
|
||||
},
|
||||
{
|
||||
title: '机构房屋性质',
|
||||
align: "center",
|
||||
dataIndex: 'orgPropertyType'
|
||||
},
|
||||
{
|
||||
title: '机构建筑面积',
|
||||
align: "center",
|
||||
dataIndex: 'orgBuildingArea'
|
||||
},
|
||||
{
|
||||
title: '机构省份 sys_category.id',
|
||||
align: "center",
|
||||
dataIndex: 'orgProvince'
|
||||
},
|
||||
{
|
||||
title: '机构城市 sys_category.id',
|
||||
align: "center",
|
||||
dataIndex: 'orgCity'
|
||||
},
|
||||
{
|
||||
title: '机构区域 sys_category.id',
|
||||
align: "center",
|
||||
dataIndex: 'orgDistrict'
|
||||
},
|
||||
{
|
||||
title: '合同附件',
|
||||
align: "center",
|
||||
dataIndex: 'contract'
|
||||
},
|
||||
{
|
||||
title: '合同备注',
|
||||
align: "center",
|
||||
dataIndex: 'contractNote'
|
||||
},
|
||||
];
|
||||
|
||||
// 高级查询数据
|
||||
export const superQuerySchema = {
|
||||
pkId: {title: '机构ID sys_depart.id 同管理端nu_org_apply_info.pk_id',order: 0,view: 'text', type: 'string',},
|
||||
openId: {title: '微信id',order: 1,view: 'text', type: 'string',},
|
||||
wechatName: {title: '微信名称',order: 2,view: 'text', type: 'string',},
|
||||
tel: {title: '联系电话',order: 3,view: 'text', type: 'string',},
|
||||
updateTime: {title: '更新日期',order: 4,view: 'datetime', type: 'string',},
|
||||
name: {title: '咨询人姓名',order: 5,view: 'text', type: 'string',},
|
||||
sex: {title: '性别',order: 6,view: 'text', type: 'string',},
|
||||
national: {title: '民族',order: 7,view: 'text', type: 'string',},
|
||||
birthDate: {title: '出生日期',order: 8,view: 'date', type: 'string',},
|
||||
idCardAddress: {title: '住址(身份证上)',order: 9,view: 'text', type: 'string',},
|
||||
idCard: {title: '身份证号',order: 10,view: 'text', type: 'string',},
|
||||
issuingAuthority: {title: '签发机关',order: 11,view: 'text', type: 'string',},
|
||||
startTime: {title: '有效开始日期',order: 12,view: 'date', type: 'string',},
|
||||
endTime: {title: '有效结束日期',order: 13,view: 'date', type: 'string',},
|
||||
cardZmPath: {title: '身份证正面',order: 14,view: 'text', type: 'string',},
|
||||
cardFmPath: {title: '身份证反面',order: 15,view: 'text', type: 'string',},
|
||||
comBusinessLicense: {title: '营业执照照片',order: 16,view: 'text', type: 'string',},
|
||||
comName: {title: '企业名称',order: 17,view: 'text', type: 'string',},
|
||||
comRegisterAddress: {title: '企业注册地址',order: 18,view: 'text', type: 'string',},
|
||||
comCreditCode: {title: '企业信用代码',order: 19,view: 'text', type: 'string',},
|
||||
comLegalPerson: {title: '企业法人',order: 20,view: 'text', type: 'string',},
|
||||
orgAddress: {title: '机构地址',order: 21,view: 'text', type: 'string',},
|
||||
orgCoordinateLo: {title: '机构位置坐标:经度',order: 22,view: 'text', type: 'string',},
|
||||
orgCoordinateLa: {title: '机构位置坐标:维度',order: 23,view: 'text', type: 'string',},
|
||||
orgLeader: {title: '机构负责人',order: 24,view: 'text', type: 'string',},
|
||||
orgLeaderPhone: {title: '机构负责人电话',order: 25,view: 'text', type: 'string',},
|
||||
orgBuildingNumber: {title: '机构楼宇牌号',order: 26,view: 'text', type: 'string',},
|
||||
orgPropertyType: {title: '机构房屋性质',order: 27,view: 'text', type: 'string',},
|
||||
orgBuildingArea: {title: '机构建筑面积',order: 28,view: 'number', type: 'number',},
|
||||
orgProvince: {title: '机构省份 sys_category.id',order: 29,view: 'text', type: 'string',},
|
||||
orgCity: {title: '机构城市 sys_category.id',order: 30,view: 'text', type: 'string',},
|
||||
orgDistrict: {title: '机构区域 sys_category.id',order: 31,view: 'text', type: 'string',},
|
||||
contract: {title: '合同附件',order: 32,view: 'text', type: 'string',},
|
||||
contractNote: {title: '合同备注',order: 33,view: 'text', type: 'string',},
|
||||
};
|
|
@ -0,0 +1,268 @@
|
|||
<template>
|
||||
<div class="p-2">
|
||||
<!--查询区域-->
|
||||
<div class="jeecg-basic-table-form-container">
|
||||
<a-form ref="formRef" @keyup.enter.native="searchQuery" :model="queryParam" :label-col="labelCol" :wrapper-col="wrapperCol">
|
||||
<a-row :gutter="24">
|
||||
<a-col :lg="6">
|
||||
<a-form-item name="pkId">
|
||||
<template #label><span title="机构ID sys_depart.id 同管理端nu_org_apply_info.pk_id">机构ID</span></template>
|
||||
<a-input placeholder="请输入机构ID sys_depart.id 同管理端nu_org_apply_info.pk_id" v-model:value="queryParam.pkId" allow-clear ></a-input>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :lg="6">
|
||||
<a-form-item name="tel">
|
||||
<template #label><span title="联系电话">联系电话</span></template>
|
||||
<JInput v-model:value="queryParam.tel"/>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<template v-if="toggleSearchStatus">
|
||||
<a-col :lg="6">
|
||||
<a-form-item name="comName">
|
||||
<template #label><span title="企业名称">企业名称</span></template>
|
||||
<JInput v-model:value="queryParam.comName"/>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
</template>
|
||||
<a-col :xl="6" :lg="7" :md="8" :sm="24">
|
||||
<span style="float: left; overflow: hidden" class="table-page-search-submitButtons">
|
||||
<a-col :lg="6">
|
||||
<a-button type="primary" preIcon="ant-design:search-outlined" @click="searchQuery">查询</a-button>
|
||||
<a-button type="primary" preIcon="ant-design:reload-outlined" @click="searchReset" style="margin-left: 8px">重置</a-button>
|
||||
<a @click="toggleSearchStatus = !toggleSearchStatus" style="margin-left: 8px">
|
||||
{{ toggleSearchStatus ? '收起' : '展开' }}
|
||||
<Icon :icon="toggleSearchStatus ? 'ant-design:up-outlined' : 'ant-design:down-outlined'" />
|
||||
</a>
|
||||
</a-col>
|
||||
</span>
|
||||
</a-col>
|
||||
</a-row>
|
||||
</a-form>
|
||||
</div>
|
||||
<!--引用表格-->
|
||||
<BasicTable @register="registerTable" :rowSelection="rowSelection">
|
||||
<!--插槽:table标题-->
|
||||
<template #tableTitle>
|
||||
<a-button type="primary" v-auth="'nuorginfo:nu_org_info:add'" @click="handleAdd" preIcon="ant-design:plus-outlined"> 新增</a-button>
|
||||
<a-button type="primary" v-auth="'nuorginfo:nu_org_info:exportXls'" preIcon="ant-design:export-outlined" @click="onExportXls"> 导出</a-button>
|
||||
<j-upload-button type="primary" v-auth="'nuorginfo:nu_org_info:importExcel'" preIcon="ant-design:import-outlined" @click="onImportXls">导入</j-upload-button>
|
||||
<a-dropdown v-if="selectedRowKeys.length > 0">
|
||||
<template #overlay>
|
||||
<a-menu>
|
||||
<a-menu-item key="1" @click="batchHandleDelete">
|
||||
<Icon icon="ant-design:delete-outlined"></Icon>
|
||||
删除
|
||||
</a-menu-item>
|
||||
</a-menu>
|
||||
</template>
|
||||
<a-button v-auth="'nuorginfo:nu_org_info:deleteBatch'">批量操作
|
||||
<Icon icon="mdi:chevron-down"></Icon>
|
||||
</a-button>
|
||||
</a-dropdown>
|
||||
<!-- 高级查询 -->
|
||||
<super-query :config="superQueryConfig" @search="handleSuperQuery" />
|
||||
</template>
|
||||
<!--操作栏-->
|
||||
<template #action="{ record }">
|
||||
<TableAction :actions="getTableAction(record)" :dropDownActions="getDropDownAction(record)"/>
|
||||
</template>
|
||||
<template v-slot:bodyCell="{ column, record, index, text }">
|
||||
</template>
|
||||
</BasicTable>
|
||||
<!-- 表单区域 -->
|
||||
<OrgInfoModal ref="registerModal" @success="handleSuccess"></OrgInfoModal>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script lang="ts" name="nuorginfo-nuOrgInfo" setup>
|
||||
import { ref, reactive } from 'vue';
|
||||
import { BasicTable, useTable, TableAction } from '/@/components/Table';
|
||||
import { useListPage } from '/@/hooks/system/useListPage';
|
||||
import { columns, superQuerySchema } from './OrgInfo.data';
|
||||
import { list, deleteOne, batchDelete, getImportUrl, getExportUrl } from './OrgInfo.api';
|
||||
import { downloadFile } from '/@/utils/common/renderUtils';
|
||||
import OrgInfoModal from './components/OrgInfoModal.vue'
|
||||
import { useUserStore } from '/@/store/modules/user';
|
||||
import JInput from "/@/components/Form/src/jeecg/components/JInput.vue";
|
||||
|
||||
const formRef = ref();
|
||||
const queryParam = reactive<any>({});
|
||||
const toggleSearchStatus = ref<boolean>(false);
|
||||
const registerModal = ref();
|
||||
const userStore = useUserStore();
|
||||
//注册table数据
|
||||
const { prefixCls, tableContext, onExportXls, onImportXls } = useListPage({
|
||||
tableProps: {
|
||||
title: '机构附加信息',
|
||||
api: list,
|
||||
columns,
|
||||
canResize:false,
|
||||
useSearchForm: false,
|
||||
actionColumn: {
|
||||
width: 120,
|
||||
fixed: 'right',
|
||||
},
|
||||
beforeFetch: async (params) => {
|
||||
return Object.assign(params, queryParam);
|
||||
},
|
||||
},
|
||||
exportConfig: {
|
||||
name: "机构附加信息",
|
||||
url: getExportUrl,
|
||||
params: queryParam,
|
||||
},
|
||||
importConfig: {
|
||||
url: getImportUrl,
|
||||
success: handleSuccess
|
||||
},
|
||||
});
|
||||
const [registerTable, { reload, collapseAll, updateTableDataRecord, findTableDataRecord, getDataSource }, { rowSelection, selectedRowKeys }] = tableContext;
|
||||
const labelCol = reactive({
|
||||
xs:24,
|
||||
sm:4,
|
||||
xl:6,
|
||||
xxl:4
|
||||
});
|
||||
const wrapperCol = reactive({
|
||||
xs: 24,
|
||||
sm: 20,
|
||||
});
|
||||
|
||||
// 高级查询配置
|
||||
const superQueryConfig = reactive(superQuerySchema);
|
||||
|
||||
/**
|
||||
* 高级查询事件
|
||||
*/
|
||||
function handleSuperQuery(params) {
|
||||
Object.keys(params).map((k) => {
|
||||
queryParam[k] = params[k];
|
||||
});
|
||||
searchQuery();
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增事件
|
||||
*/
|
||||
function handleAdd() {
|
||||
registerModal.value.disableSubmit = false;
|
||||
registerModal.value.add();
|
||||
}
|
||||
|
||||
/**
|
||||
* 编辑事件
|
||||
*/
|
||||
function handleEdit(record: Recordable) {
|
||||
registerModal.value.disableSubmit = false;
|
||||
registerModal.value.edit(record);
|
||||
}
|
||||
|
||||
/**
|
||||
* 详情
|
||||
*/
|
||||
function handleDetail(record: Recordable) {
|
||||
registerModal.value.disableSubmit = true;
|
||||
registerModal.value.edit(record);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除事件
|
||||
*/
|
||||
async function handleDelete(record) {
|
||||
await deleteOne({ id: record.id }, handleSuccess);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除事件
|
||||
*/
|
||||
async function batchHandleDelete() {
|
||||
await batchDelete({ ids: selectedRowKeys.value }, handleSuccess);
|
||||
}
|
||||
|
||||
/**
|
||||
* 成功回调
|
||||
*/
|
||||
function handleSuccess() {
|
||||
(selectedRowKeys.value = []) && reload();
|
||||
}
|
||||
|
||||
/**
|
||||
* 操作栏
|
||||
*/
|
||||
function getTableAction(record) {
|
||||
return [
|
||||
{
|
||||
label: '编辑',
|
||||
onClick: handleEdit.bind(null, record),
|
||||
auth: 'nuorginfo:nu_org_info:edit'
|
||||
},
|
||||
];
|
||||
}
|
||||
|
||||
/**
|
||||
* 下拉操作栏
|
||||
*/
|
||||
function getDropDownAction(record) {
|
||||
return [
|
||||
{
|
||||
label: '详情',
|
||||
onClick: handleDetail.bind(null, record),
|
||||
}, {
|
||||
label: '删除',
|
||||
popConfirm: {
|
||||
title: '是否确认删除',
|
||||
confirm: handleDelete.bind(null, record),
|
||||
placement: 'topLeft',
|
||||
},
|
||||
auth: 'nuorginfo:nu_org_info:delete'
|
||||
}
|
||||
]
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询
|
||||
*/
|
||||
function searchQuery() {
|
||||
reload();
|
||||
}
|
||||
|
||||
/**
|
||||
* 重置
|
||||
*/
|
||||
function searchReset() {
|
||||
formRef.value.resetFields();
|
||||
selectedRowKeys.value = [];
|
||||
//刷新数据
|
||||
reload();
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped>
|
||||
.jeecg-basic-table-form-container {
|
||||
padding: 0;
|
||||
.table-page-search-submitButtons {
|
||||
display: block;
|
||||
margin-bottom: 24px;
|
||||
white-space: nowrap;
|
||||
}
|
||||
.query-group-cust{
|
||||
min-width: 100px !important;
|
||||
}
|
||||
.query-group-split-cust{
|
||||
width: 30px;
|
||||
display: inline-block;
|
||||
text-align: center
|
||||
}
|
||||
.ant-form-item:not(.ant-form-item-with-help){
|
||||
margin-bottom: 16px;
|
||||
height: 32px;
|
||||
}
|
||||
:deep(.ant-picker),:deep(.ant-input-number){
|
||||
width: 100%;
|
||||
}
|
||||
}
|
||||
</style>
|
|
@ -0,0 +1,384 @@
|
|||
<template>
|
||||
<a-spin :spinning="confirmLoading">
|
||||
<JFormContainer :disabled="disabled">
|
||||
<template #detail>
|
||||
<a-form ref="formRef" class="antd-modal-form" :labelCol="labelCol" :wrapperCol="wrapperCol"
|
||||
name="NuOrgInfoForm">
|
||||
<a-row>
|
||||
<a-col :span="24">
|
||||
<SectionDivider :title="'机构信息'" />
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-row>
|
||||
<a-col :span="24">
|
||||
<SectionDivider :title="'身份证'" />
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-row>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="身份证正面" v-bind="validateInfos.cardZmPath" id="OrgApplyInfoForm-cardZmPath"
|
||||
name="cardZmPath">
|
||||
<JImageUpload :fileMax="1" v-model:value="formData.cardZmPath" :disabled="true"></JImageUpload>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-row>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="姓名" v-bind="validateInfos.name" id="OrgApplyInfoForm-name" name="name">
|
||||
<a-input v-model:value="formData.name" :readOnly="true"></a-input>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="性别" v-bind="validateInfos.sex" id="OrgApplyInfoForm-sex" name="sex">
|
||||
<a-input v-model:value="formData.sex" :readOnly="true"></a-input>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="民族" v-bind="validateInfos.national" id="OrgApplyInfoForm-national" name="national">
|
||||
<a-input v-model:value="formData.national" :readOnly="true"></a-input>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="出生日期" v-bind="validateInfos.birthDate" id="OrgApplyInfoForm-birthDate"
|
||||
name="birthDate">
|
||||
<a-input placeholder="申请日期" v-model:value="formData.birthDate" style="width: 100%" readOnly />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="住址" v-bind="validateInfos.idCardAddress" id="OrgApplyInfoForm-idCardAddress"
|
||||
name="idCardAddress">
|
||||
<a-input v-model:value="formData.idCardAddress" :readOnly="true"></a-input>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="身份证号" v-bind="validateInfos.idCard" id="OrgApplyInfoForm-idCard" name="idCard">
|
||||
<a-input v-model:value="formData.idCard" :readOnly="true"></a-input>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-row>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="身份证反面" v-bind="validateInfos.cardFmPath" id="OrgApplyInfoForm-cardFmPath"
|
||||
name="cardFmPath">
|
||||
<JImageUpload :fileMax="1" v-model:value="formData.cardFmPath" :disabled="true"></JImageUpload>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-row>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="签发机关" v-bind="validateInfos.issuingAuthority" id="OrgApplyInfoForm-issuingAuthority"
|
||||
name="issuingAuthority">
|
||||
<a-input v-model:value="formData.issuingAuthority" :readOnly="true"></a-input>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="有效开始日期" v-bind="validateInfos.startTime" id="OrgApplyInfoForm-startTime"
|
||||
name="startTime">
|
||||
<a-input placeholder="申请日期" v-model:value="formData.startTime" style="width: 100%" readOnly />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="有效结束日期" v-bind="validateInfos.endTime" id="OrgApplyInfoForm-endTime" name="endTime">
|
||||
<a-input placeholder="申请日期" v-model:value="formData.endTime" style="width: 100%" readOnly />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<SectionDivider :title="'营业执照'" />
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-row>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="营业执照照片" v-bind="validateInfos.comBusinessLicense"
|
||||
id="OrgApplyInfoForm-comBusinessLicense" name="comBusinessLicense">
|
||||
<JImageUpload :fileMax="1" v-model:value="formData.comBusinessLicense" :disabled="true"></JImageUpload>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-row>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="企业名称" v-bind="validateInfos.comName" id="OrgApplyInfoForm-comName" name="comName">
|
||||
<a-input v-model:value="formData.comName" :readOnly="true"></a-input>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="企业注册地址" v-bind="validateInfos.comRegisterAddress"
|
||||
id="OrgApplyInfoForm-comRegisterAddress" name="comRegisterAddress">
|
||||
<a-textarea v-model:value="formData.comRegisterAddress" :readOnly="true"></a-textarea>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="企业信用代码" v-bind="validateInfos.comCreditCode" id="OrgApplyInfoForm-comCreditCode"
|
||||
name="comCreditCode">
|
||||
<a-input v-model:value="formData.comCreditCode" :readOnly="true"></a-input>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="企业法人" v-bind="validateInfos.comLegalPerson" id="OrgApplyInfoForm-comLegalPerson"
|
||||
name="comLegalPerson">
|
||||
<a-input v-model:value="formData.comLegalPerson" :readOnly="true"></a-input>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<SectionDivider :title="'机构信息'" />
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="机构所在地">
|
||||
<a-input v-model:value="cityViewValue" placeholder="请输入机构所在地" :readOnly="true"></a-input>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="机构地址" v-bind="validateInfos.orgAddress" id="OrgApplyInfoForm-orgAddress"
|
||||
name="orgAddress">
|
||||
<a-textarea v-model:value="formData.orgAddress" :readOnly="true"></a-textarea>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="机构负责人" v-bind="validateInfos.orgLeader" id="OrgApplyInfoForm-orgLeader"
|
||||
name="orgLeader">
|
||||
<a-input v-model:value="formData.orgLeader" :readOnly="true"></a-input>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="机构负责人电话" v-bind="validateInfos.orgLeaderPhone" id="OrgApplyInfoForm-orgLeaderPhone"
|
||||
name="orgLeaderPhone">
|
||||
<a-input v-model:value="formData.orgLeaderPhone" :readOnly="true"></a-input>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="机构房屋性质" v-bind="validateInfos.orgPropertyType" id="OrgApplyInfoForm-orgPropertyType"
|
||||
name="orgPropertyType">
|
||||
<a-input v-model:value="formData.orgPropertyType" :readOnly="true"></a-input>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="机构建筑面积" v-bind="validateInfos.orgBuildingArea" id="OrgApplyInfoForm-orgBuildingArea"
|
||||
name="orgBuildingArea">
|
||||
<a-input v-model:value="formData.orgBuildingArea" addon-after="平方米" style="width: 100%" readOnly />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<SectionDivider :title="'加盟审核'" />
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="联系电话" v-bind="validateInfos.tel" id="OrgApplyInfoForm-tel" name="tel">
|
||||
<a-input v-model:value="formData.tel" placeholder="请输入联系电话" :readOnly="true"></a-input>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-row>
|
||||
<a-col :span="24">
|
||||
<SectionDivider :title="'加盟合同'" />
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-row>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="加盟合同" v-bind="validateInfos.contract" id="OrgApplyInfoForm-contract">
|
||||
<JUpload v-model:value="formData.contract" :maxCount="1"></JUpload>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="备注信息" v-bind="validateInfos.contractNote" id="OrgApplyInfoForm-contractNote"
|
||||
name="contractNote">
|
||||
<a-textarea :autosize="{ minRows: 3 }" maxlength="100" show-count v-model:value="formData.contractNote"
|
||||
allow-clear placeholder="请填写备注信息"></a-textarea>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
</a-form>
|
||||
</template>
|
||||
</JFormContainer>
|
||||
</a-spin>
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import { ref, reactive, defineExpose, nextTick, defineProps, computed, onMounted } from 'vue';
|
||||
import { defHttp } from '/@/utils/http/axios';
|
||||
import { useMessage } from '/@/hooks/web/useMessage';
|
||||
import { getValueType } from '/@/utils';
|
||||
import { saveOrUpdate, getOrgInfo } from '../OrgInfo.api';
|
||||
import { Form } from 'ant-design-vue';
|
||||
import JFormContainer from '/@/components/Form/src/container/JFormContainer.vue';
|
||||
import JImageUpload from '/@/components/Form/src/jeecg/components/JImageUpload.vue';
|
||||
import JUpload from '/@/components/Form/src/jeecg/components/JUpload/JUpload.vue';
|
||||
|
||||
const props = defineProps({
|
||||
formDisabled: { type: Boolean, default: false },
|
||||
formData: { type: Object, default: () => ({}) },
|
||||
formBpm: { type: Boolean, default: true }
|
||||
});
|
||||
const formRef = ref();
|
||||
const useForm = Form.useForm;
|
||||
const emit = defineEmits(['register', 'ok']);
|
||||
const formData = reactive<Record<string, any>>({
|
||||
orgId: '',
|
||||
departName: '',
|
||||
orgCode: '',
|
||||
orgCategory: '',
|
||||
url: '',
|
||||
platType: '',
|
||||
payableAmount: '',
|
||||
operationStartTime: '',
|
||||
operationEndTime: '',
|
||||
contractStartTime: '',
|
||||
contractEndTime: '',
|
||||
mobile: '',
|
||||
fax: '',
|
||||
address: '',
|
||||
memo: '',
|
||||
picUrl: '',
|
||||
openId: '',
|
||||
wechatName: '',
|
||||
tel: '',
|
||||
status: '',
|
||||
buildStatus: '',
|
||||
content: '',
|
||||
createTime: '',
|
||||
updateTime: '',
|
||||
izEntry: '',
|
||||
name: '',
|
||||
sex: '',
|
||||
national: '',
|
||||
birthDate: '',
|
||||
idCardAddress: '',
|
||||
idCard: '',
|
||||
issuingAuthority: '',
|
||||
startTime: '',
|
||||
endTime: '',
|
||||
cardZmPath: '',
|
||||
cardFmPath: '',
|
||||
comBusinessLicense: '',
|
||||
comName: '',
|
||||
comRegisterAddress: '',
|
||||
comCreditCode: '',
|
||||
comLegalPerson: '',
|
||||
orgAddress: '',
|
||||
orgCoordinateLo: '',
|
||||
orgCoordinateLa: '',
|
||||
orgLeader: '',
|
||||
orgLeaderPhone: '',
|
||||
orgBuildingNumber: '',
|
||||
orgPropertyType: '',
|
||||
orgBuildingArea: undefined,
|
||||
orgProvince: '',
|
||||
orgCity: '',
|
||||
orgDistrict: '',
|
||||
orgProvince_dictText: '',
|
||||
orgCity_dictText: '',
|
||||
orgDistrict_dictText: '',
|
||||
franchiseTime: null,
|
||||
contract: null,
|
||||
});
|
||||
const { createMessage } = useMessage();
|
||||
const labelCol = ref<any>({ xs: { span: 24 }, sm: { span: 5 } });
|
||||
const wrapperCol = ref<any>({ xs: { span: 24 }, sm: { span: 16 } });
|
||||
const confirmLoading = ref<boolean>(false);
|
||||
//表单验证
|
||||
const validatorRules = reactive({
|
||||
});
|
||||
const { resetFields, validate, validateInfos } = useForm(formData, validatorRules, { immediate: false });
|
||||
|
||||
// 表单禁用
|
||||
const disabled = computed(() => {
|
||||
if (props.formBpm === true) {
|
||||
if (props.formData.disabled === false) {
|
||||
return false;
|
||||
} else {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return props.formDisabled;
|
||||
});
|
||||
|
||||
|
||||
/**
|
||||
* 新增
|
||||
*/
|
||||
function add() {
|
||||
edit({});
|
||||
}
|
||||
|
||||
/**
|
||||
* 编辑
|
||||
*/
|
||||
function edit(record) {
|
||||
nextTick(() => {
|
||||
resetFields();
|
||||
const tmpData = {};
|
||||
Object.keys(formData).forEach((key) => {
|
||||
if (record.hasOwnProperty(key)) {
|
||||
tmpData[key] = record[key]
|
||||
}
|
||||
})
|
||||
//赋值
|
||||
Object.assign(formData, tmpData);
|
||||
});
|
||||
}
|
||||
|
||||
function open(orgCode) {
|
||||
getOrgInfo({ orgCode }).then(res => {
|
||||
Object.assign(formData, res);
|
||||
})
|
||||
}
|
||||
|
||||
/**
|
||||
* 提交数据
|
||||
*/
|
||||
async function submitForm() {
|
||||
try {
|
||||
// 触发表单验证
|
||||
await validate();
|
||||
} catch ({ errorFields }) {
|
||||
if (errorFields) {
|
||||
const firstField = errorFields[0];
|
||||
if (firstField) {
|
||||
formRef.value.scrollToField(firstField.name, { behavior: 'smooth', block: 'center' });
|
||||
}
|
||||
}
|
||||
return Promise.reject(errorFields);
|
||||
}
|
||||
confirmLoading.value = true;
|
||||
const isUpdate = ref<boolean>(false);
|
||||
//时间格式化
|
||||
let model = formData;
|
||||
if (model.id) {
|
||||
isUpdate.value = true;
|
||||
}
|
||||
//循环数据
|
||||
for (let data in model) {
|
||||
//如果该数据是数组并且是字符串类型
|
||||
if (model[data] instanceof Array) {
|
||||
let valueType = getValueType(formRef.value.getProps, data);
|
||||
//如果是字符串类型的需要变成以逗号分割的字符串
|
||||
if (valueType === 'string') {
|
||||
model[data] = model[data].join(',');
|
||||
}
|
||||
}
|
||||
}
|
||||
await saveOrUpdate(model, isUpdate.value)
|
||||
.then((res) => {
|
||||
if (res.success) {
|
||||
createMessage.success(res.message);
|
||||
emit('ok');
|
||||
} else {
|
||||
createMessage.warning(res.message);
|
||||
}
|
||||
})
|
||||
.finally(() => {
|
||||
confirmLoading.value = false;
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
defineExpose({
|
||||
add,
|
||||
edit,
|
||||
submitForm,
|
||||
open,
|
||||
});
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped>
|
||||
.antd-modal-form {
|
||||
padding: 14px;
|
||||
}
|
||||
</style>
|
|
@ -0,0 +1,77 @@
|
|||
<template>
|
||||
<j-modal :title="title" :width="width" :visible="visible" @ok="handleOk" :okButtonProps="{ class: { 'jee-hidden': disableSubmit } }" @cancel="handleCancel" cancelText="关闭">
|
||||
<OrgInfoForm ref="registerForm" @ok="submitCallback" :formDisabled="disableSubmit" :formBpm="false"></OrgInfoForm>
|
||||
</j-modal>
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import { ref, nextTick, defineExpose } from 'vue';
|
||||
import OrgInfoForm from './OrgInfoForm.vue'
|
||||
import JModal from '/@/components/Modal/src/JModal/JModal.vue';
|
||||
|
||||
const title = ref<string>('');
|
||||
const width = ref<number>(800);
|
||||
const visible = ref<boolean>(false);
|
||||
const disableSubmit = ref<boolean>(false);
|
||||
const registerForm = ref();
|
||||
const emit = defineEmits(['register', 'success']);
|
||||
|
||||
/**
|
||||
* 新增
|
||||
*/
|
||||
function add() {
|
||||
title.value = '新增';
|
||||
visible.value = true;
|
||||
nextTick(() => {
|
||||
registerForm.value.add();
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* 编辑
|
||||
* @param record
|
||||
*/
|
||||
function edit(record) {
|
||||
title.value = disableSubmit.value ? '详情' : '编辑';
|
||||
visible.value = true;
|
||||
nextTick(() => {
|
||||
registerForm.value.edit(record);
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* 确定按钮点击事件
|
||||
*/
|
||||
function handleOk() {
|
||||
registerForm.value.submitForm();
|
||||
}
|
||||
|
||||
/**
|
||||
* form保存回调事件
|
||||
*/
|
||||
function submitCallback() {
|
||||
handleCancel();
|
||||
emit('success');
|
||||
}
|
||||
|
||||
/**
|
||||
* 取消按钮回调事件
|
||||
*/
|
||||
function handleCancel() {
|
||||
visible.value = false;
|
||||
}
|
||||
|
||||
defineExpose({
|
||||
add,
|
||||
edit,
|
||||
disableSubmit,
|
||||
});
|
||||
</script>
|
||||
|
||||
<style lang="less">
|
||||
/**隐藏样式-modal确定按钮 */
|
||||
.jee-hidden {
|
||||
display: none !important;
|
||||
}
|
||||
</style>
|
||||
<style lang="less" scoped></style>
|
|
@ -0,0 +1,72 @@
|
|||
import { defHttp } from '/@/utils/http/axios';
|
||||
import { useMessage } from "/@/hooks/web/useMessage";
|
||||
|
||||
const { createConfirm } = useMessage();
|
||||
|
||||
enum Api {
|
||||
list = '/workorder/workOrder/list',
|
||||
save='/workorder/workOrder/add',
|
||||
edit='/workorder/workOrder/edit',
|
||||
deleteOne = '/workorder/workOrder/delete',
|
||||
deleteBatch = '/workorder/workOrder/deleteBatch',
|
||||
importExcel = '/workorder/workOrder/importExcel',
|
||||
exportXls = '/workorder/workOrder/exportXls',
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出api
|
||||
* @param params
|
||||
*/
|
||||
export const getExportUrl = Api.exportXls;
|
||||
|
||||
/**
|
||||
* 导入api
|
||||
*/
|
||||
export const getImportUrl = Api.importExcel;
|
||||
|
||||
/**
|
||||
* 列表接口
|
||||
* @param params
|
||||
*/
|
||||
export const list = (params) => defHttp.get({ url: Api.list, params });
|
||||
|
||||
/**
|
||||
* 删除单个
|
||||
* @param params
|
||||
* @param handleSuccess
|
||||
*/
|
||||
export const deleteOne = (params,handleSuccess) => {
|
||||
return defHttp.delete({url: Api.deleteOne, params}, {joinParamsToUrl: true}).then(() => {
|
||||
handleSuccess();
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除
|
||||
* @param params
|
||||
* @param handleSuccess
|
||||
*/
|
||||
export const batchDelete = (params, handleSuccess) => {
|
||||
createConfirm({
|
||||
iconType: 'warning',
|
||||
title: '确认删除',
|
||||
content: '是否删除选中数据',
|
||||
okText: '确认',
|
||||
cancelText: '取消',
|
||||
onOk: () => {
|
||||
return defHttp.delete({url: Api.deleteBatch, data: params}, {joinParamsToUrl: true}).then(() => {
|
||||
handleSuccess();
|
||||
});
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* 保存或者更新
|
||||
* @param params
|
||||
* @param isUpdate
|
||||
*/
|
||||
export const saveOrUpdate = (params, isUpdate) => {
|
||||
let url = isUpdate ? Api.edit : Api.save;
|
||||
return defHttp.post({ url: url, params }, { isTransformResponse: false });
|
||||
}
|
|
@ -0,0 +1,65 @@
|
|||
import {BasicColumn} from '/@/components/Table';
|
||||
import {FormSchema} from '/@/components/Table';
|
||||
import { rules} from '/@/utils/helper/validator';
|
||||
import { render } from '/@/utils/common/renderUtils';
|
||||
import { getWeekMonthQuarterYear } from '/@/utils';
|
||||
//列表数据
|
||||
export const columns: BasicColumn[] = [
|
||||
{
|
||||
title: '机构名称',
|
||||
align: "center",
|
||||
dataIndex: 'orgName',
|
||||
width:260
|
||||
},
|
||||
{
|
||||
title: '平台类型',
|
||||
align: "center",
|
||||
dataIndex: 'platType_dictText'
|
||||
},
|
||||
{
|
||||
title: '标题',
|
||||
align: "center",
|
||||
dataIndex: 'title',
|
||||
width:260
|
||||
},
|
||||
{
|
||||
title: '提交人',
|
||||
align: "center",
|
||||
dataIndex: 'createBy'
|
||||
},
|
||||
{
|
||||
title: '提交时间',
|
||||
align: "center",
|
||||
dataIndex: 'createTime'
|
||||
},
|
||||
{
|
||||
title: '处理人',
|
||||
align: "center",
|
||||
dataIndex: 'handleBy'
|
||||
},
|
||||
{
|
||||
title: '回复时间',
|
||||
align: "center",
|
||||
dataIndex: 'replyTime'
|
||||
},
|
||||
{
|
||||
title: '工单状态',
|
||||
align: "center",
|
||||
dataIndex: 'status_dictText'
|
||||
},
|
||||
];
|
||||
|
||||
// 高级查询数据
|
||||
export const superQuerySchema = {
|
||||
orgId: {title: '机构ID',order: 0,view: 'text', type: 'string',},
|
||||
orgCode: {title: '机构编码',order: 1,view: 'text', type: 'string',},
|
||||
orgName: {title: '机构名称',order: 2,view: 'text', type: 'string',},
|
||||
platType: {title: '平台类型pc wechat pad',order: 3,view: 'text', type: 'string',},
|
||||
title: {title: '标题',order: 4,view: 'text', type: 'string',},
|
||||
content: {title: '描述',order: 5,view: 'text', type: 'string',},
|
||||
status: {title: '状态 0待接收 1处理中 3已解决 4工单异常 5外部原因',order: 6,view: 'text', type: 'string',},
|
||||
createBy: {title: '创建人',order: 7,view: 'text', type: 'string',},
|
||||
createTime: {title: '创建时间',order: 8,view: 'datetime', type: 'string',},
|
||||
replyTime: {title: '回复时间',order: 9,view: 'datetime', type: 'string',},
|
||||
handleBy: {title: '处理人',order: 10,view: 'text', type: 'string',},
|
||||
};
|
|
@ -0,0 +1,292 @@
|
|||
<template>
|
||||
<div class="p-2">
|
||||
<!--查询区域-->
|
||||
<div class="jeecg-basic-table-form-container">
|
||||
<a-form ref="formRef" @keyup.enter.native="searchQuery" :model="queryParam" :label-col="labelCol"
|
||||
:wrapper-col="wrapperCol">
|
||||
<a-row :gutter="24">
|
||||
<a-col :lg="6">
|
||||
<a-form-item name="orgName">
|
||||
<template #label><span title="机构名称">机构名称</span></template>
|
||||
<JInput v-model:value="queryParam.orgName" placeholder="请输入机构名称"/>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :lg="6">
|
||||
<a-form-item name="orgId">
|
||||
<template #label><span title="机构ID">机构ID</span></template>
|
||||
<a-input placeholder="请输入机构ID" v-model:value="queryParam.orgId" allow-clear></a-input>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :lg="6">
|
||||
<a-form-item name="orgCode">
|
||||
<template #label><span title="机构编码">机构编码</span></template>
|
||||
<a-input placeholder="请输入机构编码" v-model:value="queryParam.orgCode" allow-clear></a-input>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :lg="6">
|
||||
<a-form-item name="platType">
|
||||
<template #label><span title="平台类型">平台类型</span></template>
|
||||
<a-input placeholder="请输入平台类型" v-model:value="queryParam.platType" allow-clear></a-input>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :lg="6">
|
||||
<a-form-item name="status">
|
||||
<template #label><span title="工单状态">工单状态</span></template>
|
||||
<a-input placeholder="请输入状态 0待接收 1处理中 3已解决 4工单异常 5外部原因" v-model:value="queryParam.status"
|
||||
allow-clear></a-input>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :xl="6" :lg="7" :md="8" :sm="24">
|
||||
<span style="float: left; overflow: hidden" class="table-page-search-submitButtons">
|
||||
<a-col :lg="6">
|
||||
<a-button type="primary" preIcon="ant-design:search-outlined" @click="searchQuery">查询</a-button>
|
||||
<a-button type="primary" preIcon="ant-design:reload-outlined" @click="searchReset"
|
||||
style="margin-left: 8px">重置</a-button>
|
||||
</a-col>
|
||||
</span>
|
||||
</a-col>
|
||||
</a-row>
|
||||
</a-form>
|
||||
</div>
|
||||
<!--引用表格-->
|
||||
<BasicTable @register="registerTable">
|
||||
<!--插槽:table标题-->
|
||||
<template #tableTitle>
|
||||
<a-button type="primary" v-auth="'workorder:nu_work_order:add'" @click="handleAdd"
|
||||
preIcon="ant-design:plus-outlined"> 新增</a-button>
|
||||
<a-button type="primary" v-auth="'workorder:nu_work_order:exportXls'" preIcon="ant-design:export-outlined"
|
||||
@click="onExportXls"> 导出</a-button>
|
||||
<j-upload-button type="primary" v-auth="'workorder:nu_work_order:importExcel'"
|
||||
preIcon="ant-design:import-outlined" @click="onImportXls">导入</j-upload-button>
|
||||
<a-dropdown v-if="selectedRowKeys.length > 0">
|
||||
<template #overlay>
|
||||
<a-menu>
|
||||
<a-menu-item key="1" @click="batchHandleDelete">
|
||||
<Icon icon="ant-design:delete-outlined"></Icon>
|
||||
删除
|
||||
</a-menu-item>
|
||||
</a-menu>
|
||||
</template>
|
||||
<a-button v-auth="'workorder:nu_work_order:deleteBatch'">批量操作
|
||||
<Icon icon="mdi:chevron-down"></Icon>
|
||||
</a-button>
|
||||
</a-dropdown>
|
||||
</template>
|
||||
<!--操作栏-->
|
||||
<template #action="{ record }">
|
||||
<TableAction :actions="getTableAction(record)" :dropDownActions="getDropDownAction(record)" />
|
||||
</template>
|
||||
<template v-slot:bodyCell="{ column, record, index, text }">
|
||||
</template>
|
||||
</BasicTable>
|
||||
<!-- 表单区域 -->
|
||||
<WorkOrderModal ref="registerModal" @success="handleSuccess"></WorkOrderModal>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script lang="ts" name="workorder-workOrder" setup>
|
||||
import { ref, reactive } from 'vue';
|
||||
import { BasicTable, useTable, TableAction } from '/@/components/Table';
|
||||
import { useListPage } from '/@/hooks/system/useListPage';
|
||||
import { columns, superQuerySchema } from './WorkOrder.data';
|
||||
import { list, deleteOne, batchDelete, getImportUrl, getExportUrl } from './WorkOrder.api';
|
||||
import { downloadFile } from '/@/utils/common/renderUtils';
|
||||
import WorkOrderModal from './components/WorkOrderModal.vue'
|
||||
import { useUserStore } from '/@/store/modules/user';
|
||||
import JInput from "/@/components/Form/src/jeecg/components/JInput.vue";
|
||||
|
||||
const formRef = ref();
|
||||
const queryParam = reactive<any>({});
|
||||
const toggleSearchStatus = ref<boolean>(false);
|
||||
const registerModal = ref();
|
||||
const userStore = useUserStore();
|
||||
//注册table数据
|
||||
const { prefixCls, tableContext, onExportXls, onImportXls } = useListPage({
|
||||
tableProps: {
|
||||
title: '工单表',
|
||||
api: list,
|
||||
columns,
|
||||
canResize: false,
|
||||
useSearchForm: false,
|
||||
actionColumn: {
|
||||
width: 300,
|
||||
fixed: 'right',
|
||||
},
|
||||
beforeFetch: async (params) => {
|
||||
return Object.assign(params, queryParam);
|
||||
},
|
||||
},
|
||||
exportConfig: {
|
||||
name: "工单表",
|
||||
url: getExportUrl,
|
||||
params: queryParam,
|
||||
},
|
||||
importConfig: {
|
||||
url: getImportUrl,
|
||||
success: handleSuccess
|
||||
},
|
||||
});
|
||||
const [registerTable, { reload, collapseAll, updateTableDataRecord, findTableDataRecord, getDataSource }, { rowSelection, selectedRowKeys }] = tableContext;
|
||||
const labelCol = reactive({
|
||||
xs: 24,
|
||||
sm: 4,
|
||||
xl: 6,
|
||||
xxl: 4
|
||||
});
|
||||
const wrapperCol = reactive({
|
||||
xs: 24,
|
||||
sm: 20,
|
||||
});
|
||||
|
||||
// 高级查询配置
|
||||
const superQueryConfig = reactive(superQuerySchema);
|
||||
|
||||
/**
|
||||
* 高级查询事件
|
||||
*/
|
||||
function handleSuperQuery(params) {
|
||||
Object.keys(params).map((k) => {
|
||||
queryParam[k] = params[k];
|
||||
});
|
||||
searchQuery();
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增事件
|
||||
*/
|
||||
function handleAdd() {
|
||||
registerModal.value.disableSubmit = false;
|
||||
registerModal.value.add();
|
||||
}
|
||||
|
||||
/**
|
||||
* 编辑事件
|
||||
*/
|
||||
function handleEdit(record: Recordable) {
|
||||
registerModal.value.disableSubmit = false;
|
||||
registerModal.value.edit(record);
|
||||
}
|
||||
|
||||
/**
|
||||
* 工单详情
|
||||
*/
|
||||
function handleDetail(record: Recordable) {
|
||||
registerModal.value.disableSubmit = true;
|
||||
registerModal.value.edit(record);
|
||||
}
|
||||
|
||||
/**
|
||||
* 机构详情
|
||||
*/
|
||||
function handleOrgDetail(record: Recordable) {
|
||||
registerModal.value.disableSubmit = true;
|
||||
registerModal.value.orgDetail(record.orgCode);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除事件
|
||||
*/
|
||||
async function handleDelete(record) {
|
||||
await deleteOne({ id: record.id }, handleSuccess);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除事件
|
||||
*/
|
||||
async function batchHandleDelete() {
|
||||
await batchDelete({ ids: selectedRowKeys.value }, handleSuccess);
|
||||
}
|
||||
|
||||
/**
|
||||
* 成功回调
|
||||
*/
|
||||
function handleSuccess() {
|
||||
(selectedRowKeys.value = []) && reload();
|
||||
}
|
||||
|
||||
/**
|
||||
* 操作栏
|
||||
*/
|
||||
function getTableAction(record) {
|
||||
return [
|
||||
{
|
||||
label: '工单详情',
|
||||
onClick: handleDetail.bind(null, record)
|
||||
},
|
||||
{
|
||||
label: '机构详情',
|
||||
onClick: handleOrgDetail.bind(null, record)
|
||||
},
|
||||
{
|
||||
label: '接收',
|
||||
onClick: handleOrgDetail.bind(null, record)
|
||||
},
|
||||
{
|
||||
label: '反馈',
|
||||
onClick: handleOrgDetail.bind(null, record)
|
||||
},
|
||||
];
|
||||
}
|
||||
|
||||
/**
|
||||
* 下拉操作栏
|
||||
*/
|
||||
function getDropDownAction(record) {
|
||||
return [
|
||||
|
||||
]
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询
|
||||
*/
|
||||
function searchQuery() {
|
||||
reload();
|
||||
}
|
||||
|
||||
/**
|
||||
* 重置
|
||||
*/
|
||||
function searchReset() {
|
||||
formRef.value.resetFields();
|
||||
selectedRowKeys.value = [];
|
||||
//刷新数据
|
||||
reload();
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped>
|
||||
.jeecg-basic-table-form-container {
|
||||
padding: 0;
|
||||
|
||||
.table-page-search-submitButtons {
|
||||
display: block;
|
||||
margin-bottom: 24px;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.query-group-cust {
|
||||
min-width: 100px !important;
|
||||
}
|
||||
|
||||
.query-group-split-cust {
|
||||
width: 30px;
|
||||
display: inline-block;
|
||||
text-align: center
|
||||
}
|
||||
|
||||
.ant-form-item:not(.ant-form-item-with-help) {
|
||||
margin-bottom: 16px;
|
||||
height: 32px;
|
||||
}
|
||||
|
||||
:deep(.ant-picker),
|
||||
:deep(.ant-input-number) {
|
||||
width: 100%;
|
||||
}
|
||||
}
|
||||
</style>
|
|
@ -0,0 +1,212 @@
|
|||
<template>
|
||||
<a-spin :spinning="confirmLoading">
|
||||
<JFormContainer :disabled="disabled">
|
||||
<template #detail>
|
||||
<a-form ref="formRef" class="antd-modal-form" :labelCol="labelCol" :wrapperCol="wrapperCol"
|
||||
name="WorkOrderForm">
|
||||
<a-row>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="机构名称" v-bind="validateInfos.orgName" id="WorkOrderForm-orgName" name="orgName">
|
||||
<a-input v-model:value="formData.orgName" placeholder="请输入机构名称" allow-clear></a-input>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="机构ID" v-bind="validateInfos.orgId" id="WorkOrderForm-orgId" name="orgId">
|
||||
<a-input v-model:value="formData.orgId" placeholder="请输入机构ID" allow-clear></a-input>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="机构编码" v-bind="validateInfos.orgCode" id="WorkOrderForm-orgCode" name="orgCode">
|
||||
<a-input v-model:value="formData.orgCode" placeholder="请输入机构编码" allow-clear></a-input>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="平台类型" v-bind="validateInfos.platType" id="WorkOrderForm-platType"
|
||||
name="platType">
|
||||
<j-dict-select-tag v-model:value="formData.platType" dictCode="plat_type" placeholder="请选择平台类型" />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="标题" v-bind="validateInfos.title" id="WorkOrderForm-title" name="title">
|
||||
<a-textarea v-model:value="formData.title" placeholder="请输入标题" allow-clear></a-textarea>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="描述" v-bind="validateInfos.content" id="WorkOrderForm-content" name="content">
|
||||
<a-textarea v-model:value="formData.content" placeholder="请输入描述" allow-clear></a-textarea>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="提交人" v-bind="validateInfos.createBy" id="WorkOrderForm-createBy" name="createBy">
|
||||
<a-input v-model:value="formData.createBy" placeholder="请输入提交人" allow-clear></a-input>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="提交时间" v-bind="validateInfos.createTime" id="WorkOrderForm-createTime"
|
||||
name="createTime">
|
||||
<a-date-picker placeholder="请选择提交时间" v-model:value="formData.createTime" showTime
|
||||
value-format="YYYY-MM-DD HH:mm:ss" style="width: 100%" allow-clear />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="处理人" v-bind="validateInfos.handleBy" id="WorkOrderForm-handleBy" name="handleBy">
|
||||
<a-input v-model:value="formData.handleBy" placeholder="请输入处理人" allow-clear></a-input>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="回复时间" v-bind="validateInfos.replyTime" id="WorkOrderForm-replyTime" name="replyTime">
|
||||
<a-date-picker placeholder="请选择回复时间" v-model:value="formData.replyTime" showTime
|
||||
value-format="YYYY-MM-DD HH:mm:ss" style="width: 100%" allow-clear />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="工单状态" v-bind="validateInfos.status" id="WorkOrderForm-status" name="status">
|
||||
<j-dict-select-tag v-model:value="formData.status" dictCode="work_order_status" placeholder="请选择工单状态" />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
</a-form>
|
||||
</template>
|
||||
</JFormContainer>
|
||||
</a-spin>
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import { ref, reactive, defineExpose, nextTick, defineProps, computed, onMounted } from 'vue';
|
||||
import { defHttp } from '/@/utils/http/axios';
|
||||
import { useMessage } from '/@/hooks/web/useMessage';
|
||||
import { getValueType } from '/@/utils';
|
||||
import { saveOrUpdate } from '../WorkOrder.api';
|
||||
import { Form } from 'ant-design-vue';
|
||||
import JFormContainer from '/@/components/Form/src/container/JFormContainer.vue';
|
||||
import JDictSelectTag from '/@/components/Form/src/jeecg/components/JDictSelectTag.vue';
|
||||
|
||||
const props = defineProps({
|
||||
formDisabled: { type: Boolean, default: false },
|
||||
formData: { type: Object, default: () => ({}) },
|
||||
formBpm: { type: Boolean, default: true }
|
||||
});
|
||||
const formRef = ref();
|
||||
const useForm = Form.useForm;
|
||||
const emit = defineEmits(['register', 'ok']);
|
||||
const formData = reactive<Record<string, any>>({
|
||||
id: '',
|
||||
orgId: '',
|
||||
orgCode: '',
|
||||
orgName: '',
|
||||
platType: '',
|
||||
title: '',
|
||||
content: '',
|
||||
status: '',
|
||||
createBy: '',
|
||||
createTime: '',
|
||||
replyTime: '',
|
||||
handleBy: '',
|
||||
});
|
||||
const { createMessage } = useMessage();
|
||||
const labelCol = ref<any>({ xs: { span: 24 }, sm: { span: 5 } });
|
||||
const wrapperCol = ref<any>({ xs: { span: 24 }, sm: { span: 16 } });
|
||||
const confirmLoading = ref<boolean>(false);
|
||||
//表单验证
|
||||
const validatorRules = reactive({
|
||||
});
|
||||
const { resetFields, validate, validateInfos } = useForm(formData, validatorRules, { immediate: false });
|
||||
|
||||
// 表单禁用
|
||||
const disabled = computed(() => {
|
||||
if (props.formBpm === true) {
|
||||
if (props.formData.disabled === false) {
|
||||
return false;
|
||||
} else {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return props.formDisabled;
|
||||
});
|
||||
|
||||
|
||||
/**
|
||||
* 新增
|
||||
*/
|
||||
function add() {
|
||||
edit({});
|
||||
}
|
||||
|
||||
/**
|
||||
* 编辑
|
||||
*/
|
||||
function edit(record) {
|
||||
nextTick(() => {
|
||||
resetFields();
|
||||
const tmpData = {};
|
||||
Object.keys(formData).forEach((key) => {
|
||||
if (record.hasOwnProperty(key)) {
|
||||
tmpData[key] = record[key]
|
||||
}
|
||||
})
|
||||
//赋值
|
||||
Object.assign(formData, tmpData);
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* 提交数据
|
||||
*/
|
||||
async function submitForm() {
|
||||
try {
|
||||
// 触发表单验证
|
||||
await validate();
|
||||
} catch ({ errorFields }) {
|
||||
if (errorFields) {
|
||||
const firstField = errorFields[0];
|
||||
if (firstField) {
|
||||
formRef.value.scrollToField(firstField.name, { behavior: 'smooth', block: 'center' });
|
||||
}
|
||||
}
|
||||
return Promise.reject(errorFields);
|
||||
}
|
||||
confirmLoading.value = true;
|
||||
const isUpdate = ref<boolean>(false);
|
||||
//时间格式化
|
||||
let model = formData;
|
||||
if (model.id) {
|
||||
isUpdate.value = true;
|
||||
}
|
||||
//循环数据
|
||||
for (let data in model) {
|
||||
//如果该数据是数组并且是字符串类型
|
||||
if (model[data] instanceof Array) {
|
||||
let valueType = getValueType(formRef.value.getProps, data);
|
||||
//如果是字符串类型的需要变成以逗号分割的字符串
|
||||
if (valueType === 'string') {
|
||||
model[data] = model[data].join(',');
|
||||
}
|
||||
}
|
||||
}
|
||||
await saveOrUpdate(model, isUpdate.value)
|
||||
.then((res) => {
|
||||
if (res.success) {
|
||||
createMessage.success(res.message);
|
||||
emit('ok');
|
||||
} else {
|
||||
createMessage.warning(res.message);
|
||||
}
|
||||
})
|
||||
.finally(() => {
|
||||
confirmLoading.value = false;
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
defineExpose({
|
||||
add,
|
||||
edit,
|
||||
submitForm,
|
||||
});
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped>
|
||||
.antd-modal-form {
|
||||
padding: 14px;
|
||||
}
|
||||
</style>
|
|
@ -0,0 +1,106 @@
|
|||
<template>
|
||||
<j-modal :title="title" :width="'70vw'" :visible="visible" @ok="handleOk"
|
||||
:okButtonProps="{ class: { 'jee-hidden': disableSubmit } }" @cancel="handleCancel" cancelText="关闭">
|
||||
<WorkOrderForm ref="registerForm" @ok="submitCallback" :formDisabled="disableSubmit" :formBpm="false">
|
||||
</WorkOrderForm>
|
||||
</j-modal>
|
||||
<j-modal title="机构详情" :width="'70vw'" :visible="orgDetailVisible" @cancel="handleOrgDetailCancel">
|
||||
<template #footer>
|
||||
<a-button @click="handleOrgDetailCancel">关闭</a-button>
|
||||
</template>
|
||||
<OrgInfoForm ref="orgDetailRef" :formDisabled="true" :formBpm="false" />
|
||||
</j-modal>
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import { ref, nextTick, defineExpose } from 'vue';
|
||||
import WorkOrderForm from './WorkOrderForm.vue'
|
||||
import JModal from '/@/components/Modal/src/JModal/JModal.vue';
|
||||
import OrgInfoForm from '/@/views/admin/orginfo/components/OrgInfoForm.vue'
|
||||
|
||||
const title = ref<string>('');
|
||||
const width = ref<number>(800);
|
||||
const visible = ref<boolean>(false);
|
||||
const orgDetailVisible = ref<boolean>(false);
|
||||
const disableSubmit = ref<boolean>(false);
|
||||
const registerForm = ref();
|
||||
const orgDetailRef = ref();
|
||||
const emit = defineEmits(['register', 'success']);
|
||||
|
||||
/**
|
||||
* 新增
|
||||
*/
|
||||
function add() {
|
||||
title.value = '新增';
|
||||
visible.value = true;
|
||||
nextTick(() => {
|
||||
registerForm.value.add();
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* 编辑
|
||||
* @param record
|
||||
*/
|
||||
function edit(record) {
|
||||
title.value = disableSubmit.value ? '详情' : '编辑';
|
||||
visible.value = true;
|
||||
nextTick(() => {
|
||||
registerForm.value.edit(record);
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* 确定按钮点击事件
|
||||
*/
|
||||
function handleOk() {
|
||||
registerForm.value.submitForm();
|
||||
}
|
||||
|
||||
/**
|
||||
* form保存回调事件
|
||||
*/
|
||||
function submitCallback() {
|
||||
handleCancel();
|
||||
emit('success');
|
||||
}
|
||||
|
||||
/**
|
||||
* 取消按钮回调事件
|
||||
*/
|
||||
function handleCancel() {
|
||||
visible.value = false;
|
||||
}
|
||||
|
||||
/**
|
||||
* 查看机构详细信息
|
||||
*/
|
||||
function orgDetail(orgCode) {
|
||||
orgDetailVisible.value = true;
|
||||
nextTick(() => {
|
||||
orgDetailRef?.value?.open(orgCode);
|
||||
})
|
||||
}
|
||||
|
||||
/**
|
||||
* 关闭机构详情页
|
||||
*/
|
||||
function handleOrgDetailCancel() {
|
||||
orgDetailVisible.value = false;
|
||||
}
|
||||
|
||||
defineExpose({
|
||||
add,
|
||||
edit,
|
||||
disableSubmit,
|
||||
orgDetail,
|
||||
});
|
||||
</script>
|
||||
|
||||
<style lang="less">
|
||||
/**隐藏样式-modal确定按钮 */
|
||||
.jee-hidden {
|
||||
display: none !important;
|
||||
}
|
||||
</style>
|
||||
<style lang="less" scoped></style>
|
|
@ -10,11 +10,12 @@
|
|||
handleAsync:同步数据按钮
|
||||
handleBatchAdd:批量新增
|
||||
-->
|
||||
<SyncComponent ref="syncComRef" :syncType="'nuBaseInfo'" :selectedSize="listComRef?.getDataSource()?.length" :syncTipText="'同步(全部)'"
|
||||
:leftTableML="'1px'" :rightTableML="'22px'" :batchRemoveText="'移除选中'" :showBatchAddBtn="true"
|
||||
:leftListTipText="'已同步'" :rightListTipText="'待同步'" :showAddAllBtn="false" :showAddBtn="true"
|
||||
:showResetDataBtn="false" :hasSearchConditions="hasSearchConditions" :topTipText="'点击展开机构详情'"
|
||||
:showSelectedArea="false" @viewTypeChanged="viewTypeChanged" @orgChanged="orgChanged" @handleAdd="handleAdd"
|
||||
<SyncComponent ref="syncComRef" :syncType="'nuBaseInfo'" :selectedSize="listComRef?.getDataSource()?.length"
|
||||
:syncTipText="'同步(全部)'" :leftTableML="'1px'" :rightTableML="'22px'" :batchRemoveText="'移除选中'"
|
||||
:showBatchAddBtn="true" :leftListTipText="'已同步'" :rightListTipText="'待同步'" :showAddAllBtn="false"
|
||||
:showAddBtn="true" :showResetDataBtn="false" :hasSearchConditions="hasSearchConditions" :topTipText="'点击展开机构详情'"
|
||||
:screenModeTip_left="'已同步'" :screenModeTip_right="'待同步'" :showSelectedArea="false"
|
||||
@viewTypeChanged="viewTypeChanged" @orgChanged="orgChanged" @handleAdd="handleAdd"
|
||||
@handleBatchAdd="handleBatchAdd" @handleRemoveAll="handleRemoveAll" @handleAsync="handleAsync"
|
||||
@handleReload="handleReload">
|
||||
<!-- 业务机构数据列表 -->
|
||||
|
|
|
@ -2,20 +2,20 @@
|
|||
<a-spin :spinning="loading">
|
||||
<BasicForm @register="registerForm">
|
||||
<!-- 省份 -->
|
||||
<template #province="{ model, field }">
|
||||
<!-- <template #province="{ model, field }">
|
||||
<j-dict-select-tag @change="provinceChanged(model)" v-model:value="model[field]"
|
||||
:dictCode="getProvinceDictCode()" placeholder="请选择所在省份" :disabled="model.orgCategory != '1'" />
|
||||
</template>
|
||||
</template> -->
|
||||
<!-- 城市 -->
|
||||
<template #city="{ model, field }">
|
||||
<!-- <template #city="{ model, field }">
|
||||
<j-dict-select-tag @change="cityChanged(model)" v-model:value="model[field]" :dictCode="getCityDictCode(model)"
|
||||
placeholder="请选择所在城市" :disabled="model.orgCategory != '1' && !model.province" />
|
||||
</template>
|
||||
</template> -->
|
||||
<!-- 区县 -->
|
||||
<template #district="{ model, field }">
|
||||
<!-- <template #district="{ model, field }">
|
||||
<j-dict-select-tag v-model:value="model[field]" :dictCode="getDistrictDictCode(model)" placeholder="请选择所在区县"
|
||||
:disabled="model.orgCategory != '1' && (!model.province || !model.city)" />
|
||||
</template>
|
||||
</template> -->
|
||||
</BasicForm>
|
||||
<div class="j-box-bottom-button offset-20" style="margin-top: 30px">
|
||||
<div class="j-box-bottom-button-float" :class="[`${prefixCls}`]">
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
<a-card :bordered="false" style="height: 100%">
|
||||
<div class="j-table-operator" style="width: 100%">
|
||||
<a-button type="primary" preIcon="ant-design:plus-outlined" @click="onAddDepart">新增机构</a-button>
|
||||
<a-button type="primary" preIcon="ant-design:plus-outlined" @click="onAddChildDepart()">新增部门</a-button>
|
||||
<!-- <a-button type="primary" preIcon="ant-design:plus-outlined" @click="onAddChildDepart()">新增部门</a-button> -->
|
||||
<!-- <a-upload name="file" :showUploadList="false" :customRequest="onImportXls">
|
||||
<a-button type="primary" preIcon="ant-design:import-outlined">导入</a-button>
|
||||
</a-upload>
|
||||
|
|
|
@ -33,12 +33,12 @@ export function useBasicFormSchema() {
|
|||
placeholder: '请输入编码',
|
||||
},
|
||||
},
|
||||
{
|
||||
field: 'orgCategory',
|
||||
label: '类型',
|
||||
component: 'RadioButtonGroup',
|
||||
componentProps: { options: [] },
|
||||
},
|
||||
// {
|
||||
// field: 'orgCategory',
|
||||
// label: '类型',
|
||||
// component: 'RadioButtonGroup',
|
||||
// componentProps: { options: [] },
|
||||
// },
|
||||
{
|
||||
field: 'url',
|
||||
label: '协议域名',
|
||||
|
@ -50,33 +50,33 @@ export function useBasicFormSchema() {
|
|||
placeholder: '请输入协议域名',
|
||||
},
|
||||
},
|
||||
{
|
||||
field: 'province',
|
||||
label: '省份',
|
||||
component: 'Input',
|
||||
ifShow: (v_) => {
|
||||
return !v_.values.parentId;
|
||||
},
|
||||
slot: 'province',
|
||||
},
|
||||
{
|
||||
field: 'city',
|
||||
label: '城市',
|
||||
component: 'Input',
|
||||
ifShow: (v_) => {
|
||||
return !v_.values.parentId;
|
||||
},
|
||||
slot: 'city',
|
||||
},
|
||||
{
|
||||
field: 'district',
|
||||
label: '区县',
|
||||
component: 'Input',
|
||||
ifShow: (v_) => {
|
||||
return !v_.values.parentId;
|
||||
},
|
||||
slot: 'district',
|
||||
},
|
||||
// {
|
||||
// field: 'province',
|
||||
// label: '省份',
|
||||
// component: 'Input',
|
||||
// ifShow: (v_) => {
|
||||
// return !v_.values.parentId;
|
||||
// },
|
||||
// slot: 'province',
|
||||
// },
|
||||
// {
|
||||
// field: 'city',
|
||||
// label: '城市',
|
||||
// component: 'Input',
|
||||
// ifShow: (v_) => {
|
||||
// return !v_.values.parentId;
|
||||
// },
|
||||
// slot: 'city',
|
||||
// },
|
||||
// {
|
||||
// field: 'district',
|
||||
// label: '区县',
|
||||
// component: 'Input',
|
||||
// ifShow: (v_) => {
|
||||
// return !v_.values.parentId;
|
||||
// },
|
||||
// slot: 'district',
|
||||
// },
|
||||
{
|
||||
field: 'platType',
|
||||
label: '业务平台类型',
|
||||
|
@ -95,103 +95,103 @@ export function useBasicFormSchema() {
|
|||
},
|
||||
],
|
||||
},
|
||||
{
|
||||
field: 'payableAmount',
|
||||
label: '入住应缴金额',
|
||||
component: 'InputNumber',
|
||||
ifShow: (v_) => {
|
||||
return !v_.values.parentId;
|
||||
},
|
||||
rules: [
|
||||
{
|
||||
required: true,
|
||||
message: '请填写护理单元长者入住应缴金额',
|
||||
},
|
||||
],
|
||||
},
|
||||
{
|
||||
field: 'operationStartTime',
|
||||
label: '运营开始时间',
|
||||
component: 'DatePicker',
|
||||
ifShow: (v_) => {
|
||||
return !v_.values.parentId;
|
||||
},
|
||||
componentProps: {
|
||||
valueFormat: 'YYYY-MM-DD',
|
||||
style: {
|
||||
width: '100%',
|
||||
},
|
||||
},
|
||||
},
|
||||
{
|
||||
field: 'operationEndTime',
|
||||
label: '运营到期时间',
|
||||
component: 'DatePicker',
|
||||
ifShow: (v_) => {
|
||||
return !v_.values.parentId;
|
||||
},
|
||||
componentProps: {
|
||||
valueFormat: 'YYYY-MM-DD',
|
||||
style: {
|
||||
width: '100%',
|
||||
},
|
||||
},
|
||||
},
|
||||
{
|
||||
field: 'contractStartTime',
|
||||
label: '合同开始时间',
|
||||
component: 'DatePicker',
|
||||
ifShow: (v_) => {
|
||||
return !v_.values.parentId;
|
||||
},
|
||||
componentProps: {
|
||||
valueFormat: 'YYYY-MM-DD',
|
||||
style: {
|
||||
width: '100%',
|
||||
},
|
||||
},
|
||||
},
|
||||
{
|
||||
field: 'contractEndTime',
|
||||
label: '合同到期时间',
|
||||
component: 'DatePicker',
|
||||
ifShow: (v_) => {
|
||||
return !v_.values.parentId;
|
||||
},
|
||||
componentProps: {
|
||||
valueFormat: 'YYYY-MM-DD',
|
||||
style: {
|
||||
width: '100%',
|
||||
},
|
||||
},
|
||||
},
|
||||
{
|
||||
field: 'mobile',
|
||||
label: '电话',
|
||||
component: 'Input',
|
||||
componentProps: {
|
||||
placeholder: '请输入电话',
|
||||
},
|
||||
},
|
||||
{
|
||||
field: 'fax',
|
||||
label: '传真',
|
||||
component: 'Input',
|
||||
componentProps: {
|
||||
placeholder: '请输入传真',
|
||||
},
|
||||
},
|
||||
{
|
||||
field: 'address',
|
||||
label: '地址',
|
||||
component: 'Input',
|
||||
ifShow: (v_) => {
|
||||
return !v_.values.parentId;
|
||||
},
|
||||
componentProps: {
|
||||
placeholder: '请输入地址',
|
||||
},
|
||||
},
|
||||
// {
|
||||
// field: 'payableAmount',
|
||||
// label: '入住应缴金额',
|
||||
// component: 'InputNumber',
|
||||
// ifShow: (v_) => {
|
||||
// return !v_.values.parentId;
|
||||
// },
|
||||
// rules: [
|
||||
// {
|
||||
// required: true,
|
||||
// message: '请填写护理单元长者入住应缴金额',
|
||||
// },
|
||||
// ],
|
||||
// },
|
||||
// {
|
||||
// field: 'operationStartTime',
|
||||
// label: '运营开始时间',
|
||||
// component: 'DatePicker',
|
||||
// ifShow: (v_) => {
|
||||
// return !v_.values.parentId;
|
||||
// },
|
||||
// componentProps: {
|
||||
// valueFormat: 'YYYY-MM-DD',
|
||||
// style: {
|
||||
// width: '100%',
|
||||
// },
|
||||
// },
|
||||
// },
|
||||
// {
|
||||
// field: 'operationEndTime',
|
||||
// label: '运营到期时间',
|
||||
// component: 'DatePicker',
|
||||
// ifShow: (v_) => {
|
||||
// return !v_.values.parentId;
|
||||
// },
|
||||
// componentProps: {
|
||||
// valueFormat: 'YYYY-MM-DD',
|
||||
// style: {
|
||||
// width: '100%',
|
||||
// },
|
||||
// },
|
||||
// },
|
||||
// {
|
||||
// field: 'contractStartTime',
|
||||
// label: '合同开始时间',
|
||||
// component: 'DatePicker',
|
||||
// ifShow: (v_) => {
|
||||
// return !v_.values.parentId;
|
||||
// },
|
||||
// componentProps: {
|
||||
// valueFormat: 'YYYY-MM-DD',
|
||||
// style: {
|
||||
// width: '100%',
|
||||
// },
|
||||
// },
|
||||
// },
|
||||
// {
|
||||
// field: 'contractEndTime',
|
||||
// label: '合同到期时间',
|
||||
// component: 'DatePicker',
|
||||
// ifShow: (v_) => {
|
||||
// return !v_.values.parentId;
|
||||
// },
|
||||
// componentProps: {
|
||||
// valueFormat: 'YYYY-MM-DD',
|
||||
// style: {
|
||||
// width: '100%',
|
||||
// },
|
||||
// },
|
||||
// },
|
||||
// {
|
||||
// field: 'mobile',
|
||||
// label: '电话',
|
||||
// component: 'Input',
|
||||
// componentProps: {
|
||||
// placeholder: '请输入电话',
|
||||
// },
|
||||
// },
|
||||
// {
|
||||
// field: 'fax',
|
||||
// label: '传真',
|
||||
// component: 'Input',
|
||||
// componentProps: {
|
||||
// placeholder: '请输入传真',
|
||||
// },
|
||||
// },
|
||||
// {
|
||||
// field: 'address',
|
||||
// label: '地址',
|
||||
// component: 'Input',
|
||||
// ifShow: (v_) => {
|
||||
// return !v_.values.parentId;
|
||||
// },
|
||||
// componentProps: {
|
||||
// placeholder: '请输入地址',
|
||||
// },
|
||||
// },
|
||||
{
|
||||
field: 'memo',
|
||||
label: '备注',
|
||||
|
@ -206,14 +206,14 @@ export function useBasicFormSchema() {
|
|||
component: 'InputNumber',
|
||||
componentProps: {},
|
||||
},
|
||||
{
|
||||
field: 'picUrl',
|
||||
label: '机构图片',
|
||||
component: 'JImageUpload',
|
||||
ifShow: (v_) => {
|
||||
return !v_.values.parentId;
|
||||
},
|
||||
},
|
||||
// {
|
||||
// field: 'picUrl',
|
||||
// label: '机构图片',
|
||||
// component: 'JImageUpload',
|
||||
// ifShow: (v_) => {
|
||||
// return !v_.values.parentId;
|
||||
// },
|
||||
// },
|
||||
];
|
||||
return { basicFormSchema };
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue