服务指令bug
This commit is contained in:
parent
46364fd7fa
commit
7bc34f1967
|
@ -18,6 +18,7 @@ enum Api {
|
|||
getOrgInfo = '/api/common/getOrgInfo', //根据机构编码获取机构信息
|
||||
changeDirectiveMain = '/sys/sysDepart/changeDirectiveMain', //变更指令库
|
||||
getDirectiveMain = '/sys/sysDepart/getDirectiveMain', //查询当前指令库机构信息
|
||||
getDMOrgInfo = '/api/common/getDMOrgInfo', //标准指令库信息
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -167,6 +168,11 @@ export const getOrgInfo = (params) => {
|
|||
return defHttp.get({ url: Api.getOrgInfo, params });
|
||||
};
|
||||
|
||||
//标准指令库信息
|
||||
export const getDMOrgInfo = () => {
|
||||
return defHttp.get({ url: Api.getDMOrgInfo });
|
||||
};
|
||||
|
||||
/**
|
||||
* 变更指令库
|
||||
* @param params
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
<a-form-item label="服务类别" v-bind="validateInfos.categoryId" id="ConfigServiceDirectiveForm-categoryId"
|
||||
name="categoryId">
|
||||
<j-dict-select-tag type="list" v-model:value="formData.categoryId"
|
||||
:dictCode="`nu_config_service_category,category_name,id,del_flag = 0 order by sort asc`"
|
||||
:dictCode="`nu_config_service_category,category_name,id,del_flag = 0 and iz_enabled = 0 order by sort asc`"
|
||||
placeholder="请选择服务类别" allow-clear />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
|
@ -37,14 +37,14 @@
|
|||
<a-form-item label="收费价格(元)" v-bind="validateInfos.tollPrice" id="ConfigServiceDirectiveForm-tollPrice"
|
||||
name="tollPrice">
|
||||
<a-input-number v-model:value="formData.tollPrice" placeholder="请输入收费价格" style="width: 100%"
|
||||
precision="4" />
|
||||
precision="2" />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="提成价格(元)" v-bind="validateInfos.comPrice" id="ConfigServiceDirectiveForm-comPrice"
|
||||
name="comPrice">
|
||||
<a-input-number v-model:value="formData.comPrice" placeholder="请输入提成价格" style="width: 100%"
|
||||
precision="4" />
|
||||
precision="2" />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
|
@ -251,9 +251,9 @@ watch(
|
|||
(newCategoryId) => {
|
||||
if (!newCategoryId) {
|
||||
formData.typeId = '';
|
||||
typeDictCode.value = 'nu_config_service_type,type_name,id,del_flag = 99 order by sort asc';
|
||||
typeDictCode.value = 'nu_config_service_type,type_name,id,1=2';
|
||||
} else {
|
||||
typeDictCode.value = `nu_config_service_type,type_name,id,del_flag = 0 and category_id = '${newCategoryId}' order by sort asc`;
|
||||
typeDictCode.value = `nu_config_service_type,type_name,id,del_flag = 0 and iz_enabled = 0 and category_id = '${newCategoryId}' order by sort asc`;
|
||||
}
|
||||
}
|
||||
);
|
||||
|
@ -319,7 +319,7 @@ async function submitForm() {
|
|||
}
|
||||
|
||||
//提成价格不能高于收费价格
|
||||
if (model.tollPrice <= model.comPrice) {
|
||||
if (model.tollPrice < model.comPrice) {
|
||||
createMessage.warning('提成价格不能高于收费价格!');
|
||||
confirmLoading.value = false;
|
||||
retrun;
|
||||
|
|
|
@ -25,7 +25,7 @@
|
|||
<a-form-item name="typeId">
|
||||
<template #label><span title="服务类型">服务类型</span></template>
|
||||
<j-dict-select-tag type="list" v-model:value="queryParam.typeId"
|
||||
:dictCode="`nu_config_service_type,type_name,id,del_flag = 0 and category_id = ${queryParam.categoryId || -1} order by sort asc`" placeholder="请选择服务类型"
|
||||
:dictCode="`nu_config_service_type,type_name,id,del_flag = 0 and iz_enabled = 0 and category_id = ${queryParam.categoryId || -1} order by sort asc`" placeholder="请选择服务类型"
|
||||
:ignoreDisabled="true" allowClear />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
<a-form-item name="instructionId">
|
||||
<template #label><span title="分类标签">分类标签</span></template>
|
||||
<j-dict-select-tag type='list' v-model:value="queryParam.instructionId"
|
||||
:dictCode="`nu_config_service_instruction_tag,instruction_name,id,del_flag = 0 order by sort asc`"
|
||||
:dictCode="`nu_config_service_instruction_tag,instruction_name,id,del_flag = 0 and iz_enabled = 0 order by sort asc`"
|
||||
:ignoreDisabled="true" placeholder="请选择服务类别" allowClear />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
<a-form-item label="分类标签" v-bind="validateInfos.instructionId" id="ConfigServiceTypeForm-instructionId"
|
||||
name="instructionId">
|
||||
<j-dict-select-tag type='list' v-model:value="formData.instructionId"
|
||||
:dictCode="`nu_config_service_instruction_tag,instruction_name,id,del_flag = 0 order by sort asc`"
|
||||
:dictCode="`nu_config_service_instruction_tag,instruction_name,id,del_flag = 0 and iz_enabled = 0 order by sort asc`"
|
||||
placeholder="请选择分类标签" allowClear />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
<a-form-item name="instructionTagId">
|
||||
<template #label><span title="分类标签">分类标签</span></template>
|
||||
<j-dict-select-tag v-model:value="queryParam.instructionTagId"
|
||||
:dictCode="`nu_config_service_instruction_tag,instruction_name,id,del_flag = 0 order by sort asc`"
|
||||
:dictCode="`nu_config_service_instruction_tag,instruction_name,id,del_flag = 0 and iz_enabled = 0 order by sort asc`"
|
||||
placeholder="请选择分类标签" allowClear :ignoreDisabled="true" />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
|
@ -27,7 +27,7 @@
|
|||
<a-form-item name="typeId">
|
||||
<template #label><span title="服务类型">服务类型</span></template>
|
||||
<j-dict-select-tag type="list" v-model:value="queryParam.typeId"
|
||||
:dictCode="`nu_config_service_type,type_name,id,del_flag = 0 and category_id = '${queryParam.categoryId || ''}' order by sort asc`"
|
||||
:dictCode="`nu_config_service_type,type_name,id,del_flag = 0 and iz_enabled = 0 and category_id = '${queryParam.categoryId || ''}' order by sort asc`"
|
||||
placeholder="请选择服务类型" allowClear :ignoreDisabled="true" />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
|
@ -41,7 +41,7 @@
|
|||
<a-form-item name="bodyTags">
|
||||
<template #label><span title="体型标签">体型标签</span></template>
|
||||
<j-dict-select-tag type='list' v-model:value="queryParam.bodyTags"
|
||||
:dictCode="`nu_config_body_tag,tag_name,id,del_flag = '0' order by sort asc`" :ignoreDisabled="true"
|
||||
:dictCode="`nu_config_body_tag,tag_name,id,del_flag = '0' and iz_enabled = 0 order by sort asc`" :ignoreDisabled="true"
|
||||
placeholder="请选择体型标签" allowClear />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
|
@ -49,7 +49,7 @@
|
|||
<a-form-item name="emotionTags">
|
||||
<template #label><span title="情绪标签">情绪标签</span></template>
|
||||
<j-dict-select-tag type="list" v-model:value="queryParam.emotionTags"
|
||||
:dictCode="`nu_config_emotion_tag,tag_name,id,del_flag = '0' order by sort asc`" :ignoreDisabled="true"
|
||||
:dictCode="`nu_config_emotion_tag,tag_name,id,del_flag = '0' and iz_enabled = 0 order by sort asc`" :ignoreDisabled="true"
|
||||
placeholder="请选择情绪标签" allowClear />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
|
|
|
@ -30,7 +30,7 @@
|
|||
<a-form-item label="分类标签" v-bind="validateInfos.instructionTagId"
|
||||
id="ConfigServiceDirectiveForm-instructionTagId" name="instructionTagId">
|
||||
<j-dict-select-tag v-model:value="formData.instructionTagId"
|
||||
:dictCode="`nu_config_service_instruction_tag,instruction_name,id,del_flag = 0 order by sort asc`"
|
||||
:dictCode="`nu_config_service_instruction_tag,instruction_name,id,del_flag = 0 and iz_enabled = 0 order by sort asc`"
|
||||
placeholder="请选择分类标签" allowClear @upDictCode="upInstructionDictCode" />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
|
@ -59,14 +59,14 @@
|
|||
<a-form-item label="收费价格(元)" v-bind="validateInfos.tollPrice" id="ConfigServiceDirectiveForm-tollPrice"
|
||||
name="tollPrice">
|
||||
<a-input-number v-model:value="formData.tollPrice" placeholder="请输入收费价格" style="width: 100%"
|
||||
precision="4" />
|
||||
precision="2" />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="提成价格(元)" v-bind="validateInfos.comPrice" id="ConfigServiceDirectiveForm-comPrice"
|
||||
name="comPrice">
|
||||
<a-input-number v-model:value="formData.comPrice" placeholder="请输入提成价格" style="width: 100%"
|
||||
precision="4" />
|
||||
precision="2" />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
|
@ -103,13 +103,13 @@
|
|||
<a-form-item label="体型标签" id="ConfigServiceDirectiveForm-typeId" :labelCol="labelCol2"
|
||||
:wrapperCol="wrapperCol2" name="typeId">
|
||||
<JCheckbox v-model:value="formData.bodyTags"
|
||||
:dictCode="`nu_config_body_tag,tag_name,id,del_flag = 0 order by sort asc`" />
|
||||
:dictCode="`nu_config_body_tag,tag_name,id,del_flag = 0 and iz_enabled = 0 order by sort asc`" />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-item label="情绪标签" :labelCol="labelCol2" :wrapperCol="wrapperCol2" name="emoTags">
|
||||
<JCheckbox v-model:value="formData.emotionTags"
|
||||
:dictCode="`nu_config_emotion_tag,tag_name,id,del_flag = 0 order by sort asc`" />
|
||||
:dictCode="`nu_config_emotion_tag,tag_name,id,del_flag = 0 and iz_enabled = 0 order by sort asc`" />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
|
@ -364,7 +364,7 @@ watch(
|
|||
formData.typeId = ''
|
||||
categoryDictCode.value = 'nu_config_service_category,category_name,id,1=2';
|
||||
} else {
|
||||
categoryDictCode.value = `nu_config_service_category,category_name,id,del_flag = 0 and instruction_id = '${newInstructionTagId}' order by sort asc`;
|
||||
categoryDictCode.value = `nu_config_service_category,category_name,id,del_flag = 0 and iz_enabled = 0 and instruction_id = '${newInstructionTagId}' order by sort asc`;
|
||||
}
|
||||
}
|
||||
);
|
||||
|
@ -373,9 +373,9 @@ watch(
|
|||
(newCategoryId) => {
|
||||
if (!newCategoryId) {
|
||||
formData.typeId = ''
|
||||
typeDictCode.value = 'nu_config_service_type,type_name,id,del_flag = 99 order by sort asc';
|
||||
typeDictCode.value = 'nu_config_service_type,type_name,id,1=2';
|
||||
} else {
|
||||
typeDictCode.value = `nu_config_service_type,type_name,id,del_flag = 0 and category_id = '${newCategoryId}' order by sort asc`;
|
||||
typeDictCode.value = `nu_config_service_type,type_name,id,del_flag = 0 and iz_enabled = 0 and category_id = '${newCategoryId}' order by sort asc`;
|
||||
}
|
||||
}
|
||||
);
|
||||
|
@ -446,7 +446,7 @@ async function submitForm() {
|
|||
}
|
||||
|
||||
//提成价格不能高于收费价格
|
||||
if (model.comPrice != 0 && model.tollPrice <= model.comPrice) {
|
||||
if (model.comPrice != 0 && model.tollPrice < model.comPrice) {
|
||||
createMessage.warning('提成价格不能高于收费价格!');
|
||||
confirmLoading.value = false;
|
||||
retrun;
|
||||
|
|
|
@ -139,12 +139,12 @@ const wrapperCol = reactive({
|
|||
});
|
||||
|
||||
// 计算 dictCode
|
||||
const instructionDictCode = 'nu_config_service_instruction_tag,instruction_name,id,del_flag = 0 order by sort asc';
|
||||
const instructionDictCode = 'nu_config_service_instruction_tag,instruction_name,id,del_flag = 0 and iz_enabled = 0 order by sort asc';
|
||||
const categoryDictCode = computed(() => {
|
||||
if (!queryParam.instructionId) {
|
||||
return 'nu_config_service_category,category_name,id,del_flag = 0';
|
||||
return 'nu_config_service_category,category_name,id,del_flag = 0 and iz_enabled = 0';
|
||||
}
|
||||
return `nu_config_service_category,category_name,id,del_flag = 0 and instruction_id = ${queryParam.instructionId} order by sort asc`;
|
||||
return `nu_config_service_category,category_name,id,del_flag = 0 and iz_enabled = 0 and instruction_id = ${queryParam.instructionId} order by sort asc`;
|
||||
});
|
||||
|
||||
// 监听 instructionId 变化,清空二级
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
<a-form-item label="分类标签" v-bind="validateInfos.instructionId" id="ConfigServiceTypeForm-instructionId"
|
||||
name="instructionId">
|
||||
<j-dict-select-tag type='list' v-model:value="formData.instructionId"
|
||||
:dictCode="`nu_config_service_instruction_tag,instruction_name,id,del_flag = 0 order by sort asc`"
|
||||
:dictCode="`nu_config_service_instruction_tag,instruction_name,id,del_flag = 0 and iz_enabled = 0 order by sort asc`"
|
||||
placeholder="请选择分类标签" allowClear />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
|
@ -92,7 +92,7 @@ const categoryDictCode = computed(() => {
|
|||
if (!formData.instructionId) {
|
||||
return 'nu_config_service_category,category_name,id,1=2';
|
||||
}
|
||||
return `nu_config_service_category,category_name,id,del_flag = 0 and instruction_id = ${formData.instructionId} order by sort asc`;
|
||||
return `nu_config_service_category,category_name,id,del_flag = 0 and iz_enabled = 0 and instruction_id = ${formData.instructionId} order by sort asc`;
|
||||
});
|
||||
|
||||
// 监听 instructionId 变化,清空 categoryId
|
||||
|
|
|
@ -14,16 +14,19 @@ export const columns: BasicColumn[] = [
|
|||
title: '分类标签',
|
||||
align: 'center',
|
||||
dataIndex: 'instructionTag',
|
||||
width: 170,
|
||||
},
|
||||
{
|
||||
title: '服务类别',
|
||||
align: 'center',
|
||||
dataIndex: 'category',
|
||||
width: 170,
|
||||
},
|
||||
{
|
||||
title: '服务类型',
|
||||
align: 'center',
|
||||
dataIndex: 'type',
|
||||
width: 170,
|
||||
},
|
||||
{
|
||||
title: '服务指令',
|
||||
|
@ -34,11 +37,13 @@ export const columns: BasicColumn[] = [
|
|||
title: '周期类型',
|
||||
align: 'center',
|
||||
dataIndex: 'cycleType',
|
||||
width: 120,
|
||||
},
|
||||
{
|
||||
title: '创建日期',
|
||||
align: 'center',
|
||||
dataIndex: 'createTime',
|
||||
width: 160,
|
||||
},
|
||||
];
|
||||
|
||||
|
|
|
@ -42,7 +42,7 @@
|
|||
</template>
|
||||
|
||||
<script lang="ts" name="canadddirective-canAddDirective" setup>
|
||||
import { ref, reactive } from 'vue';
|
||||
import { ref, reactive, onMounted } from 'vue';
|
||||
import { BasicTable, useTable, TableAction } from '/@/components/Table';
|
||||
import { useListPage } from '/@/hooks/system/useListPage';
|
||||
import { columns, superQuerySchema } from './CanAddDirective.data';
|
||||
|
@ -57,6 +57,7 @@ const props = defineProps({
|
|||
directiveMainOrgInfo: {},
|
||||
existDirectiveIds: [],
|
||||
})
|
||||
const emit = defineEmits(['refreshExistIds']);
|
||||
const { createMessage, createConfirm } = useMessage();
|
||||
const formRef = ref();
|
||||
const queryParam = reactive<any>({});
|
||||
|
@ -76,7 +77,7 @@ const { prefixCls, tableContext, onExportXls, onImportXls } = useListPage({
|
|||
fixed: 'right',
|
||||
},
|
||||
beforeFetch: async (params) => {
|
||||
queryParam.existDirectiveIds = props.existDirectiveIds.map(item => item.id)
|
||||
queryParam.existDirectiveIds = props.existDirectiveIds.map(item => item.id).join(',')
|
||||
return Object.assign(params, queryParam);
|
||||
},
|
||||
},
|
||||
|
@ -124,7 +125,7 @@ function handlePull(record) {
|
|||
createConfirm({
|
||||
iconType: 'warning',
|
||||
title: '镜像确认',
|
||||
content: '是否确认将服务指令【' + record.directiveName + '】同步给平台:' + props.directiveMainOrgInfo.departName,
|
||||
content: '请确认是否将' + record.orgCode_dictText + '新增的服务指令“' + record.directiveName + '”镜像给当前标准服务指令库:' + props.directiveMainOrgInfo.departName,
|
||||
okText: '确认',
|
||||
cancelText: '取消',
|
||||
onOk: () => {
|
||||
|
@ -138,6 +139,7 @@ function handlePull(record) {
|
|||
}
|
||||
).then(res => {
|
||||
createMessage.success('已开始自动同步,可在日志中查看同步结果!')
|
||||
emit('refreshExistIds', props.directiveMainOrgInfo)
|
||||
}).catch(() => {
|
||||
createMessage.error('镜像失败,请稍后再试')
|
||||
})
|
||||
|
@ -165,7 +167,7 @@ function getTableAction(record) {
|
|||
* 查询
|
||||
*/
|
||||
function searchQuery() {
|
||||
reload();
|
||||
emit('refreshExistIds', props.directiveMainOrgInfo, false)
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -175,14 +177,14 @@ function searchReset() {
|
|||
formRef.value.resetFields();
|
||||
selectedRowKeys.value = [];
|
||||
//刷新数据
|
||||
reload();
|
||||
emit('refreshExistIds', props.directiveMainOrgInfo, false)
|
||||
}
|
||||
|
||||
defineExpose({
|
||||
searchReset,
|
||||
reload,
|
||||
})
|
||||
|
||||
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped>
|
||||
|
|
|
@ -30,7 +30,7 @@
|
|||
<a-form-item label="分类标签" v-bind="validateInfos.instructionTagId"
|
||||
id="ConfigServiceDirectiveForm-instructionTagId" name="instructionTagId">
|
||||
<j-dict-select-tag v-model:value="formData.instructionTagId" :orgCode="formData?.sysOrgCode"
|
||||
:dictCode="`nu_config_service_instruction_tag,instruction_name,id,del_flag = 0 order by sort asc`"
|
||||
:dictCode="`nu_config_service_instruction_tag,instruction_name,id,del_flag = 0 and iz_enabled = 0 order by sort asc`"
|
||||
placeholder="请选择分类标签" allowClear @upDictCode="upInstructionDictCode" />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
|
@ -60,14 +60,14 @@
|
|||
<a-form-item label="收费价格(元)" v-bind="validateInfos.tollPrice" id="ConfigServiceDirectiveForm-tollPrice"
|
||||
name="tollPrice">
|
||||
<a-input-number v-model:value="formData.tollPrice" placeholder="请输入收费价格" style="width: 100%"
|
||||
precision="4" />
|
||||
precision="2" />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="提成价格(元)" v-bind="validateInfos.comPrice" id="ConfigServiceDirectiveForm-comPrice"
|
||||
name="comPrice">
|
||||
<a-input-number v-model:value="formData.comPrice" placeholder="请输入提成价格" style="width: 100%"
|
||||
precision="4" />
|
||||
precision="2" />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
|
@ -104,13 +104,13 @@
|
|||
<a-form-item label="体型标签" id="ConfigServiceDirectiveForm-typeId" :labelCol="labelCol2"
|
||||
:wrapperCol="wrapperCol2" name="typeId">
|
||||
<JCheckbox v-model:value="formData.bodyTags" :orgCode="formData?.sysOrgCode"
|
||||
:dictCode="`nu_config_body_tag,tag_name,id,del_flag = 0 order by sort asc`" />
|
||||
:dictCode="`nu_config_body_tag,tag_name,id,del_flag = 0 and iz_enabled = 0 order by sort asc`" />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-item label="情绪标签" :labelCol="labelCol2" :wrapperCol="wrapperCol2" name="emoTags">
|
||||
<JCheckbox v-model:value="formData.emotionTags" :orgCode="formData?.sysOrgCode"
|
||||
:dictCode="`nu_config_emotion_tag,tag_name,id,del_flag = 0 order by sort asc`" />
|
||||
:dictCode="`nu_config_emotion_tag,tag_name,id,del_flag = 0 and iz_enabled = 0 order by sort asc`" />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
|
@ -363,7 +363,7 @@ watch(
|
|||
formData.typeId = ''
|
||||
categoryDictCode.value = 'nu_config_service_category,category_name,id,1=2';
|
||||
} else {
|
||||
categoryDictCode.value = `nu_config_service_category,category_name,id,del_flag = 0 and instruction_id = '${newInstructionTagId}' order by sort asc`;
|
||||
categoryDictCode.value = `nu_config_service_category,category_name,id,del_flag = 0 and iz_enabled = 0 and iz_enabled = 0 and instruction_id = '${newInstructionTagId}' order by sort asc`;
|
||||
}
|
||||
}
|
||||
);
|
||||
|
@ -372,9 +372,9 @@ watch(
|
|||
(newCategoryId) => {
|
||||
if (!newCategoryId) {
|
||||
formData.typeId = ''
|
||||
typeDictCode.value = 'nu_config_service_type,type_name,id,del_flag = 99 order by sort asc';
|
||||
typeDictCode.value = 'nu_config_service_type,type_name,id,1=2';
|
||||
} else {
|
||||
typeDictCode.value = `nu_config_service_type,type_name,id,del_flag = 0 and category_id = '${newCategoryId}' order by sort asc`;
|
||||
typeDictCode.value = `nu_config_service_type,type_name,id,del_flag = 0 and iz_enabled = 0 and category_id = '${newCategoryId}' order by sort asc`;
|
||||
}
|
||||
}
|
||||
);
|
||||
|
|
|
@ -16,7 +16,7 @@
|
|||
<a-form-item label="服务类别" v-bind="validateInfos.categoryId" id="ConfigServiceDirectiveForm-categoryId"
|
||||
name="categoryId">
|
||||
<j-dict-select-tag type="list" v-model:value="formData.categoryId" :orgCode="orgCodeParam"
|
||||
:dictCode="`nu_config_service_category,category_name,id,del_flag = 0 order by sort asc`"
|
||||
:dictCode="`nu_config_service_category,category_name,id,del_flag = 0 and iz_enabled = 0 order by sort asc`"
|
||||
placeholder="请选择服务类别" allow-clear />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
|
@ -37,14 +37,14 @@
|
|||
<a-form-item label="收费价格(元)" v-bind="validateInfos.tollPrice" id="ConfigServiceDirectiveForm-tollPrice"
|
||||
name="tollPrice">
|
||||
<a-input-number v-model:value="formData.tollPrice" placeholder="请输入收费价格" style="width: 100%"
|
||||
precision="4" />
|
||||
precision="2" />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="提成价格(元)" v-bind="validateInfos.comPrice" id="ConfigServiceDirectiveForm-comPrice"
|
||||
name="comPrice">
|
||||
<a-input-number v-model:value="formData.comPrice" placeholder="请输入提成价格" style="width: 100%"
|
||||
precision="4" />
|
||||
precision="2" />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
|
@ -87,13 +87,13 @@
|
|||
<a-form-item label="体型标签" id="ConfigServiceDirectiveForm-typeId" :labelCol="labelCol2"
|
||||
:wrapperCol="wrapperCol2" name="typeId">
|
||||
<JCheckbox v-model:value="formData.bodyTags" :orgCode="orgCodeParam"
|
||||
:dictCode="`nu_config_body_tag,tag_name,id,del_flag = 0 order by sort asc`" />
|
||||
:dictCode="`nu_config_body_tag,tag_name,id,del_flag = 0 and iz_enabled = 0 order by sort asc`" />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-item label="情绪标签" :labelCol="labelCol2" :wrapperCol="wrapperCol2" name="emoTags">
|
||||
<JCheckbox v-model:value="formData.emotionTags" :orgCode="orgCodeParam"
|
||||
:dictCode="`nu_config_emotion_tag,tag_name,id,del_flag = 0 order by sort asc`" />
|
||||
:dictCode="`nu_config_emotion_tag,tag_name,id,del_flag = 0 and iz_enabled = 0 order by sort asc`" />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
|
@ -265,9 +265,9 @@ watch(
|
|||
(newCategoryId) => {
|
||||
if (!newCategoryId) {
|
||||
formData.typeId = '';
|
||||
typeDictCode.value = 'nu_config_service_type,type_name,id,del_flag = 99 order by sort asc';
|
||||
typeDictCode.value = 'nu_config_service_type,type_name,id,1=2';
|
||||
} else {
|
||||
typeDictCode.value = `nu_config_service_type,type_name,id,del_flag = 0 and category_id = '${newCategoryId}' order by sort asc`;
|
||||
typeDictCode.value = `nu_config_service_type,type_name,id,del_flag = 0 and iz_enabled = 0 and category_id = '${newCategoryId}' order by sort asc`;
|
||||
}
|
||||
}
|
||||
);
|
||||
|
@ -334,7 +334,7 @@ async function submitForm() {
|
|||
}
|
||||
|
||||
//提成价格不能高于收费价格
|
||||
if (model.comPrice != 0 && model.tollPrice <= model.comPrice) {
|
||||
if (model.comPrice != 0 && model.tollPrice < model.comPrice) {
|
||||
createMessage.warning('提成价格不能高于收费价格!');
|
||||
confirmLoading.value = false;
|
||||
retrun;
|
||||
|
|
|
@ -29,7 +29,7 @@
|
|||
<template #label><span title="服务类别">服务类别</span></template>
|
||||
<j-dict-select-tag type="list" v-model:value="queryParam.categoryId"
|
||||
:orgCode="sourceOrgCode"
|
||||
:dictCode="`nu_config_service_category,category_name,id,del_flag = 0 order by sort asc`"
|
||||
:dictCode="`nu_config_service_category,category_name,id,del_flag = 0 and iz_enabled = 0 order by sort asc`"
|
||||
:ignoreDisabled="true" placeholder="请选择服务类别" allow-clear />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
|
@ -37,7 +37,7 @@
|
|||
<a-form-item name="typeId">
|
||||
<template #label><span title="服务类型">服务类型</span></template>
|
||||
<j-dict-select-tag type="list" v-model:value="queryParam.typeId" :orgCode="sourceOrgCode"
|
||||
:dictCode="`nu_config_service_type,type_name,id,del_flag = 0 order by sort asc`"
|
||||
:dictCode="`nu_config_service_type,type_name,id,del_flag = 0 and iz_enabled = 0 order by sort asc`"
|
||||
placeholder="请选择服务类型" :ignoreDisabled="true" allowClear />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
|
@ -52,7 +52,7 @@
|
|||
<a-form-item name="bodyTags">
|
||||
<template #label><span title="体型标签">体型标签</span></template>
|
||||
<JSelectMultiple type="list" v-model:value="queryParam.bodyTags" :orgCode="sourceOrgCode"
|
||||
:dictCode="`nu_config_body_tag,tag_name,id,del_flag = '0' order by sort asc`"
|
||||
:dictCode="`nu_config_body_tag,tag_name,id,del_flag = '0' and iz_enabled = 0 order by sort asc`"
|
||||
:ignoreDisabled="true" placeholder="请选择体型标签" allowClear />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
|
@ -60,7 +60,7 @@
|
|||
<a-form-item name="emotionTags">
|
||||
<template #label><span title="情绪标签">情绪标签</span></template>
|
||||
<JSelectMultiple type="list" v-model:value="queryParam.emotionTags" :orgCode="sourceOrgCode"
|
||||
:dictCode="`nu_config_emotion_tag,tag_name,id,del_flag = '0' order by sort asc`"
|
||||
:dictCode="`nu_config_emotion_tag,tag_name,id,del_flag = '0' and iz_enabled = 0 order by sort asc`"
|
||||
:ignoreDisabled="true" placeholder="请选择情绪标签" allowClear />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
|
|
|
@ -7,49 +7,40 @@
|
|||
style="padding: 8px;">
|
||||
<a-card :class="{
|
||||
'selected-card': selectedOrgs.some(org => org.orgCode === item.orgCode),
|
||||
'directive-selected-card': directiveSelectedOrg?.orgCode === item.orgCode
|
||||
}" style="width: 100%; border-radius: 8px; " :headStyle="{ height: '60px', padding: '0 24px' }"
|
||||
:style="{ cursor: showChoose ? 'pointer' : 'default' }" :bodyStyle="{ padding: '24px 24px 4px 24px' }"
|
||||
@click="handleCardClick(item)">
|
||||
<template #title>
|
||||
<a-row style="font-weight: normal;">
|
||||
<a-col :span="props.layout == 'full' ? 22 : 21" style="font-size: 14px; padding-top: 4px;">
|
||||
'directive-selected-card': directiveMainSelectedOrg?.orgCode === item.orgCode,
|
||||
'org-card': (showChoose || showDirectiveChoose)
|
||||
}" style="width: 100%; border-radius: 8px; " :style="{ cursor: showChoose ? 'pointer' : 'default' }"
|
||||
:bodyStyle="{ padding: '24px' }" @click="handleCardClick(item)">
|
||||
<div>
|
||||
<a-row style="font-weight: normal; margin-bottom: 12px;">
|
||||
<a-col :span="props.layout == 'full' ? 16 : 13" style="font-size: 14px;">
|
||||
<div>
|
||||
<span style="font-weight: bold;">{{ item.departName }}</span>
|
||||
<!-- 如果是已选择,显示"已选择" -->
|
||||
<span style="color: green; font-size: 12px; margin-left: 8px;"
|
||||
v-if="selectedOrgs.some(org => org.orgCode === item.orgCode)">已选择</span>
|
||||
<span style="color: #d48806; font-size: 12px; margin-left: 8px;"
|
||||
v-if="directiveSelectedOrg?.orgCode === item.orgCode">指令库已选择</span>
|
||||
</div>
|
||||
</a-col>
|
||||
<a-col :span="props.layout == 'full' ? 2 : 3" style="text-align: center; padding-top: 4px;">
|
||||
<div class="zxClass">{{ item.orgCode }}</div>
|
||||
<a-col :span="props.layout == 'full' ? 8 : 11" style="text-align: right;">
|
||||
<div style="display: flex; align-items: center; justify-content: flex-end; gap: 8px;">
|
||||
<span v-if="selectedOrgs.some(org => org.orgCode === item.orgCode)"
|
||||
style="color: green; font-size: 12px; white-space: nowrap;">已选择</span>
|
||||
<span v-if="dmOrg?.orgCode === item.orgCode"
|
||||
style="color: green; font-size: 12px; font-weight: bold; white-space: nowrap;">标准指令库</span>
|
||||
<div class="zxClass" style="min-width: 35px;">{{ item.orgCode }}</div>
|
||||
</div>
|
||||
</a-col>
|
||||
</a-row>
|
||||
</template>
|
||||
<p>加盟时间:{{ item.franchiseTime?.substring(0, 10) }}</p>
|
||||
<p>机构负责人:{{ item.orgLeader }}</p>
|
||||
<p>负责人电话:{{ item.orgLeaderPhone }}</p>
|
||||
<p class="ellipsis-one-lines" :title="item.comRegisterAddress">机构地址:{{ item.comRegisterAddress }}</p>
|
||||
<a-divider />
|
||||
<p style="text-align:center;">
|
||||
<span v-show="showDetail" style="display:inline-block;cursor: pointer;" @click.stop="handleDetail(item)">
|
||||
<span class="tbClass"><img src="/@/assets/images/a14.png" style="width:20px;" /></span><br />
|
||||
<span class="antTitle">详情</span>
|
||||
</span>
|
||||
<!-- <span v-show="showDirectiveMain" style="display:inline-block;cursor: pointer;margin-left: 10px;"
|
||||
@click.stop="handleDetail(item)">
|
||||
<span class="tbClass"><img src="/@/assets/images/safety.png" style="width:20px;" /></span><br />
|
||||
<span class="antTitle">指令库</span>
|
||||
</span> -->
|
||||
<!-- 根据 showChoose 判断是否显示选择按钮 -->
|
||||
<!-- <span v-if="showChoose" style="display:inline-block; cursor: pointer; margin-left: 20px;"
|
||||
@click.stop="handleCardClick(item)">
|
||||
<span class="tbClass"><img src="/@/assets/images/choose.png" style="width:20px;" /></span><br />
|
||||
<span class="antTitle">选择</span>
|
||||
</span> -->
|
||||
</p>
|
||||
<a-divider />
|
||||
<div style="position: relative;">
|
||||
<div v-show="showDetail" style="text-align:center;position: absolute;top: 0px;right:0px">
|
||||
<a-button type="link" size="small" @click.stop="handleDetail(item)">详情</a-button>
|
||||
</div>
|
||||
<div>
|
||||
<p>加盟时间:{{ item.franchiseTime?.substring(0, 10) }}</p>
|
||||
<p>机构负责人:{{ item.orgLeader }}</p>
|
||||
<p>负责人电话:{{ item.orgLeaderPhone }}</p>
|
||||
<p class="ellipsis-one-lines" :title="item.comRegisterAddress">机构地址:{{ item.comRegisterAddress }}</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</a-card>
|
||||
</a-col>
|
||||
<a-col v-if="orgTableList.length == 0">
|
||||
|
@ -84,6 +75,7 @@ const props = defineProps({
|
|||
excludeOrgCode: { type: String, default: '' },//排除的机构(不展示)
|
||||
showDirectiveMain: { type: Boolean, default: false },//指令库按钮
|
||||
showDirectiveChoose: { type: Boolean, default: false }, // 新增:是否可以选择指令库
|
||||
showDMTip: { type: Boolean, default: false }, // 增加此属性可单独展示“标准指令库”提示
|
||||
})
|
||||
|
||||
const emit = defineEmits(['handleOrgDetail', 'handleOrgChoose'])
|
||||
|
@ -91,7 +83,8 @@ const emit = defineEmits(['handleOrgDetail', 'handleOrgChoose'])
|
|||
const orgTableList = ref<any>({ records: [], total: 0 })
|
||||
const queryParam = reactive<any>({})
|
||||
const pageParams = ref({ pageNo: 1, pageSize: props.pageSize })
|
||||
const directiveSelectedOrg = ref<any>(null)
|
||||
const directiveMainSelectedOrg = ref<any>(null)
|
||||
const dmOrg = ref('')//已设定标准指令库
|
||||
|
||||
// 当前选中的卡片 ID 数组
|
||||
const selectedOrgs = ref<string[]>([])
|
||||
|
@ -99,7 +92,7 @@ const selectedOrgs = ref<string[]>([])
|
|||
/** 点击卡片选择 */
|
||||
function handleCardClick(item: any) {
|
||||
if (props.showDirectiveChoose) {
|
||||
directiveSelectedOrg.value = item
|
||||
directiveMainSelectedOrg.value = item
|
||||
emit('handleOrgChoose', item)
|
||||
}
|
||||
if (props.showChoose) { // 判断是否可以选择
|
||||
|
@ -127,6 +120,7 @@ function handleDetail(item: any) {
|
|||
|
||||
/** 数据加载 */
|
||||
function reload() {
|
||||
directiveMainSelectedOrg.value = {}
|
||||
queryParam.pageSize = pageParams.value.pageSize
|
||||
queryParam.pageNo = pageParams.value.pageNo
|
||||
queryParam.title = props.title
|
||||
|
@ -137,10 +131,11 @@ function reload() {
|
|||
res.records = res.records.filter(o => o.orgCode != props.excludeOrgCode)
|
||||
orgTableList.value = res
|
||||
// 在reload函数中添加
|
||||
if (props.showDirectiveChoose) {
|
||||
if (props.showDirectiveChoose || props.showDMTip) {
|
||||
const defaultSelected = res.records.find(item => item.izDirectiveMain === '0')
|
||||
if (defaultSelected) {
|
||||
directiveSelectedOrg.value = defaultSelected
|
||||
dmOrg.value = defaultSelected
|
||||
// directiveMainSelectedOrg.value = defaultSelected
|
||||
emit('handleOrgChoose', defaultSelected)
|
||||
}
|
||||
}
|
||||
|
@ -204,6 +199,10 @@ defineExpose({
|
|||
height: 25px;
|
||||
color: white;
|
||||
line-height: 25px;
|
||||
padding: 0 8px;
|
||||
/* 增加内边距 */
|
||||
flex-shrink: 0;
|
||||
/* 防止被压缩 */
|
||||
}
|
||||
|
||||
.tbClass {
|
||||
|
@ -232,7 +231,20 @@ defineExpose({
|
|||
}
|
||||
|
||||
.directive-selected-card {
|
||||
border: 2px solid #d48806;
|
||||
box-shadow: 0 0 8px rgba(212, 136, 6, 0.3);
|
||||
border: 2px solid #1890FF;
|
||||
box-shadow: 0 0 8px rgba(37, 149, 255, 0.3);
|
||||
}
|
||||
|
||||
.org-card {
|
||||
&:hover {
|
||||
border-color: #55a9f8;
|
||||
/* 这是悬停时的蓝色边框 */
|
||||
box-shadow: 0 2px 8px rgba(37, 149, 255, 0.3);
|
||||
/* 这是悬停时的淡蓝色阴影 */
|
||||
}
|
||||
}
|
||||
|
||||
:deep .ant-divider {
|
||||
margin: 0 0 8px 0;
|
||||
}
|
||||
</style>
|
||||
|
|
|
@ -5,40 +5,48 @@
|
|||
<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-col :lg="6">
|
||||
<a-form-item name="instructionTagId">
|
||||
<template #label><span title="分类标签">分类标签</span></template>
|
||||
<j-dict-select-tag v-model:value="queryParam.instructionTagId" dictCode="instruction_tag" :ignoreDisabled="true"
|
||||
placeholder="请选分类标签" allowClear />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :lg="6">
|
||||
<a-form-item name="categoryId">
|
||||
<template #label><span title="服务类别">服务类别</span></template>
|
||||
<j-dict-select-tag type="list" v-model:value="queryParam.categoryId"
|
||||
:dictCode="`nu_config_service_category,category_name,id,del_flag = 0 order by sort asc`" :ignoreDisabled="true"
|
||||
placeholder="请选择服务类别" allow-clear />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :lg="6">
|
||||
<a-form-item name="typeId">
|
||||
<template #label><span title="服务类型">服务类型</span></template>
|
||||
<j-dict-select-tag type="list" v-model:value="queryParam.typeId"
|
||||
:dictCode="`nu_config_service_type,type_name,id,del_flag = 0 and category_id = ${queryParam.categoryId || -1} order by sort asc`"
|
||||
placeholder="请选择服务类型" :ignoreDisabled="true" allowClear />
|
||||
</a-form-item>
|
||||
</a-col> -->
|
||||
<j-dict-select-tag v-model:value="queryParam.instructionTagId"
|
||||
:dictCode="`nu_config_service_instruction_tag,instruction_name,id,del_flag = 0 and iz_enabled = 0 order by sort asc`"
|
||||
:orgCode="queryParam.dataSourceCode" :ignoreDisabled="true" placeholder="请选分类标签" allowClear />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :lg="6">
|
||||
<a-form-item name="categoryId">
|
||||
<template #label><span title="服务类别">服务类别</span></template>
|
||||
<j-dict-select-tag type="list" v-model:value="queryParam.categoryId" :orgCode="queryParam.dataSourceCode"
|
||||
:dictCode="`nu_config_service_category,category_name,id,del_flag = 0 and iz_enabled = 0 and instruction_id = '${queryParam.instructionTagId || ''}' order by sort asc`"
|
||||
:ignoreDisabled="true" placeholder="请选择服务类别" allow-clear />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :lg="6">
|
||||
<a-form-item name="typeId">
|
||||
<template #label><span title="服务类型">服务类型</span></template>
|
||||
<j-dict-select-tag type="list" v-model:value="queryParam.typeId" :orgCode="queryParam.dataSourceCode"
|
||||
:dictCode="`nu_config_service_type,type_name,id,del_flag = 0 and iz_enabled = 0 and category_id = '${queryParam.categoryId || ''}' order by sort asc`"
|
||||
placeholder="请选择服务类型" :ignoreDisabled="true" allowClear />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :lg="6">
|
||||
<a-form-item name="directiveName">
|
||||
<template #label><span title="服务指令">服务指令</span></template>
|
||||
<JInput v-model:value="queryParam.directiveName" placeholder="请输入服务指令名称" allowClear />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :lg="6">
|
||||
<a-form-item name="cycleType">
|
||||
<template #label><span title="周期类型">周期类型</span></template>
|
||||
<j-dict-select-tag type="list" v-model:value="queryParam.cycleType" :orgCode="queryParam.dataSourceCode"
|
||||
dictCode="period_type" placeholder="请选择周期类型" :ignoreDisabled="true" allowClear />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<!-- <a-col :lg="6">
|
||||
<a-form-item name="bodyTags">
|
||||
<template #label><span title="体型标签">体型标签</span></template>
|
||||
<j-dict-select-tag type='list' v-model:value="queryParam.bodyTags"
|
||||
:dictCode="`nu_config_body_tag,tag_name,id,del_flag = '0' order by sort asc`" :ignoreDisabled="true"
|
||||
:dictCode="`nu_config_body_tag,tag_name,id,del_flag = '0' and iz_enabled = 0 order by sort asc`" :ignoreDisabled="true"
|
||||
placeholder="请选择体型标签" allowClear />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
|
@ -46,7 +54,7 @@
|
|||
<a-form-item name="emotionTags">
|
||||
<template #label><span title="情绪标签">情绪标签</span></template>
|
||||
<j-dict-select-tag type="list" v-model:value="queryParam.emotionTags"
|
||||
:dictCode="`nu_config_emotion_tag,tag_name,id,del_flag = '0' order by sort asc`" :ignoreDisabled="true"
|
||||
:dictCode="`nu_config_emotion_tag,tag_name,id,del_flag = '0' and iz_enabled = 0 order by sort asc`" :ignoreDisabled="true"
|
||||
placeholder="请选择情绪标签" allowClear />
|
||||
</a-form-item>
|
||||
</a-col> -->
|
||||
|
|
|
@ -8,19 +8,20 @@
|
|||
<a-col :lg="5">
|
||||
<a-form-item name="instructionTagId">
|
||||
<template #label><span title="分类标签">分类标签</span></template>
|
||||
<j-dict-select-tag v-model:value="queryParam.instructionTagId" v-if="showJSCom"
|
||||
<j-dict-select-tag v-model:value="queryParam.instructionTagId" :disabled="!showJSCom"
|
||||
:orgCode="sourceOrgInfo?.orgCode"
|
||||
:dictCode="`nu_config_service_instruction_tag,instruction_name,id,del_flag = 0 order by sort asc`"
|
||||
:dictCode="`nu_config_service_instruction_tag,instruction_name,id,del_flag = 0 and iz_enabled = 0 order by sort asc`"
|
||||
placeholder="请选择分类标签" allowClear :ignoreDisabled="true" @select="reload()" />
|
||||
<!-- <span v-else>请选择源平台</span> -->
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
|
||||
<a-col :lg="5">
|
||||
<a-form-item name="categoryId">
|
||||
<template #label><span title="服务类别">服务类别</span></template>
|
||||
<j-dict-select-tag type="list" v-model:value="queryParam.categoryId" v-if="showJSCom"
|
||||
<j-dict-select-tag type="list" v-model:value="queryParam.categoryId" :disabled="!showJSCom"
|
||||
:orgCode="sourceOrgInfo?.orgCode"
|
||||
:dictCode="`nu_config_service_category,category_name,id,del_flag = 0 and instruction_id = '${queryParam.instructionTagId || ''}' order by sort asc`"
|
||||
:dictCode="`nu_config_service_category,category_name,id,del_flag = 0 and iz_enabled = 0 and instruction_id = '${queryParam.instructionTagId || ''}' order by sort asc`"
|
||||
placeholder="请选择服务类别" allowClear :ignoreDisabled="true" @select="reload()" />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
|
@ -28,9 +29,9 @@
|
|||
<a-col :lg="5">
|
||||
<a-form-item name="typeId">
|
||||
<template #label><span title="服务类型">服务类型</span></template>
|
||||
<j-dict-select-tag type="list" v-model:value="queryParam.typeId" v-if="showJSCom"
|
||||
<j-dict-select-tag type="list" v-model:value="queryParam.typeId" :disabled="!showJSCom"
|
||||
:orgCode="sourceOrgInfo?.orgCode"
|
||||
:dictCode="`nu_config_service_type,type_name,id,del_flag = 0 and category_id = '${queryParam.categoryId || ''}' order by sort asc`"
|
||||
:dictCode="`nu_config_service_type,type_name,id,del_flag = 0 and iz_enabled = 0 and category_id = '${queryParam.categoryId || ''}' order by sort asc`"
|
||||
placeholder="请选择服务类型" allowClear :ignoreDisabled="true" @select="reload()" />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
|
@ -44,7 +45,7 @@
|
|||
<a-form-item name="bodyTags">
|
||||
<template #label><span title="体型标签">体型标签</span></template>
|
||||
<j-dict-select-tag type='list' v-model:value="queryParam.bodyTags"
|
||||
:dictCode="`nu_config_body_tag,tag_name,id,del_flag = '0' order by sort asc`" :ignoreDisabled="true"
|
||||
:dictCode="`nu_config_body_tag,tag_name,id,del_flag = '0' and iz_enabled = 0 order by sort asc`" :ignoreDisabled="true"
|
||||
placeholder="请选择体型标签" allowClear />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
|
@ -52,7 +53,7 @@
|
|||
<a-form-item name="emotionTags">
|
||||
<template #label><span title="情绪标签">情绪标签</span></template>
|
||||
<j-dict-select-tag type="list" v-model:value="queryParam.emotionTags"
|
||||
:dictCode="`nu_config_emotion_tag,tag_name,id,del_flag = '0' order by sort asc`" :ignoreDisabled="true"
|
||||
:dictCode="`nu_config_emotion_tag,tag_name,id,del_flag = '0' and iz_enabled = 0 order by sort asc`" :ignoreDisabled="true"
|
||||
placeholder="请选择情绪标签" allowClear />
|
||||
</a-form-item>
|
||||
</a-col> -->
|
||||
|
@ -422,12 +423,12 @@ function cleanTargetSourceData() {
|
|||
function syncFunc() {
|
||||
if (props.targetChooseType == 'one') {
|
||||
if (!targetOrg.value || !targetOrg.value.orgCode) {
|
||||
createMessage.warning('请选择业务平台')
|
||||
createMessage.warning('请选择目标平台')
|
||||
return
|
||||
}
|
||||
} else {
|
||||
if (!props.targetOrgs.length) {
|
||||
createMessage.warning('请选择业务平台')
|
||||
createMessage.warning('请选择目标平台')
|
||||
return
|
||||
}
|
||||
}
|
||||
|
@ -452,18 +453,18 @@ function handleOk() {
|
|||
.map(item => item.id)
|
||||
.join(','),
|
||||
syncOrgCodes: targetOrg.value.orgCode,
|
||||
syncOption:syncOption.value,
|
||||
syncOption: syncOption.value,
|
||||
}
|
||||
} else {
|
||||
params = {
|
||||
syncIds: rightNeedAddList.value.map(item => item.id).join(','),
|
||||
upIds: '',
|
||||
syncOrgCodes: props.targetOrgs.map(item => item.orgCode).join(','),
|
||||
syncOption:syncOption.value,
|
||||
syncOption: syncOption.value,
|
||||
}
|
||||
}
|
||||
|
||||
syncDirective(sourceOrgInfo.value.orgCode,params)
|
||||
|
||||
syncDirective(sourceOrgInfo.value.orgCode, params)
|
||||
createMessage.success('已开始自动同步!')
|
||||
visible.value = false
|
||||
}
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
<template #label><span title="分类标签">分类标签</span></template>
|
||||
<j-dict-select-tag v-model:value="queryParam.instructionTagId" v-if="showJSCom"
|
||||
:orgCode="sourceOrgInfo?.orgCode"
|
||||
:dictCode="`nu_config_service_instruction_tag,instruction_name,id,del_flag = 0 order by sort asc`"
|
||||
:dictCode="`nu_config_service_instruction_tag,instruction_name,id,del_flag = 0 and iz_enabled = 0 order by sort asc`"
|
||||
placeholder="请选择分类标签" allowClear :ignoreDisabled="true" @select="reload()" />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
|
@ -20,7 +20,7 @@
|
|||
<template #label><span title="服务类别">服务类别</span></template>
|
||||
<j-dict-select-tag type="list" v-model:value="queryParam.categoryId" v-if="showJSCom"
|
||||
:orgCode="sourceOrgInfo?.orgCode"
|
||||
:dictCode="`nu_config_service_category,category_name,id,del_flag = 0 and instruction_id = '${queryParam.instructionTagId || ''}' order by sort asc`"
|
||||
:dictCode="`nu_config_service_category,category_name,id,del_flag = 0 and iz_enabled = 0 and instruction_id = '${queryParam.instructionTagId || ''}' order by sort asc`"
|
||||
placeholder="请选择服务类别" allowClear :ignoreDisabled="true" @select="reload()" />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
|
@ -30,7 +30,7 @@
|
|||
<template #label><span title="服务类型">服务类型</span></template>
|
||||
<j-dict-select-tag type="list" v-model:value="queryParam.typeId" v-if="showJSCom"
|
||||
:orgCode="sourceOrgInfo?.orgCode"
|
||||
:dictCode="`nu_config_service_type,type_name,id,del_flag = 0 and category_id = '${queryParam.categoryId || ''}' order by sort asc`"
|
||||
:dictCode="`nu_config_service_type,type_name,id,del_flag = 0 and iz_enabled = 0 and category_id = '${queryParam.categoryId || ''}' order by sort asc`"
|
||||
placeholder="请选择服务类型" allowClear :ignoreDisabled="true" @select="reload()" />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
|
@ -44,7 +44,7 @@
|
|||
<a-form-item name="bodyTags">
|
||||
<template #label><span title="体型标签">体型标签</span></template>
|
||||
<j-dict-select-tag type='list' v-model:value="queryParam.bodyTags"
|
||||
:dictCode="`nu_config_body_tag,tag_name,id,del_flag = '0' order by sort asc`" :ignoreDisabled="true"
|
||||
:dictCode="`nu_config_body_tag,tag_name,id,del_flag = '0' and iz_enabled = 0 order by sort asc`" :ignoreDisabled="true"
|
||||
placeholder="请选择体型标签" allowClear />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
|
@ -52,7 +52,7 @@
|
|||
<a-form-item name="emotionTags">
|
||||
<template #label><span title="情绪标签">情绪标签</span></template>
|
||||
<j-dict-select-tag type="list" v-model:value="queryParam.emotionTags"
|
||||
:dictCode="`nu_config_emotion_tag,tag_name,id,del_flag = '0' order by sort asc`" :ignoreDisabled="true"
|
||||
:dictCode="`nu_config_emotion_tag,tag_name,id,del_flag = '0' and iz_enabled = 0 order by sort asc`" :ignoreDisabled="true"
|
||||
placeholder="请选择情绪标签" allowClear />
|
||||
</a-form-item>
|
||||
</a-col> -->
|
||||
|
|
|
@ -22,7 +22,7 @@
|
|||
<a-button type="primary" preIcon="ant-design:file-text-twotone" @click="handleViewLogs"
|
||||
style="margin-right: 10px;">日志</a-button>
|
||||
<a-button type="primary" preIcon="ant-design:safety-certificate-twotone" @click="handleDirectiveMainFunc"
|
||||
style="margin-right: 10px;">指令库</a-button>
|
||||
style="margin-right: 10px;">标准指令库</a-button>
|
||||
<!-- <a-badge :count="609" style="margin-right: 10px;"> -->
|
||||
<a-button type="primary" preIcon="ant-design:eye-outlined" style="margin-right: 10px;"
|
||||
@click="handleLookNewDirectives">新增指令</a-button>
|
||||
|
@ -32,13 +32,14 @@
|
|||
</a-form>
|
||||
</div>
|
||||
|
||||
<OrgListCom ref="orgListComRef" :title="queryParam.title" @handleOrgDetail="handleDetail" :showDetail=true>
|
||||
<OrgListCom ref="orgListComRef" :title="queryParam.title" @handleOrgDetail="handleDetail" :showDetail=true
|
||||
:showDMTip="true">
|
||||
</OrgListCom>
|
||||
|
||||
<ConfigServiceDirectiveListModal ref="configServiceDirectiveListModal" />
|
||||
<SyncStepListModal ref="syncStepListModal" />
|
||||
<!-- <a-modal v-model:visible="logsVisible" title="日志" width="90vw"
|
||||
:bodyStyle="{ padding: '0', height: '70vh', display: 'flex', flexDirection: 'column', overflow: 'hidden' }"
|
||||
:bodyStyle="{ padding: '0', height: '70vh', display: 'flex', flexDirection: 'column', overflow: 'auto' }"
|
||||
wrapClassName="org-list-modal" @cancel="handleCancelLogs">
|
||||
<a-row>
|
||||
<a-col :span="2" :push="22" style="margin-top: 15px;margin-left: 60px;">
|
||||
|
@ -52,8 +53,8 @@
|
|||
</template>
|
||||
<AsyncListComponent ref="logsRef"></AsyncListComponent>
|
||||
</a-modal> -->
|
||||
<a-drawer title="日志" width="70vw" v-model:visible="logsVisible"
|
||||
:bodyStyle="{ padding: '0', height: '70vh', display: 'flex', flexDirection: 'column', overflow: 'hidden' }"
|
||||
<a-drawer title="日志" width="80vw" v-model:visible="logsVisible"
|
||||
:bodyStyle="{ padding: '0', height: '70vh', display: 'flex', flexDirection: 'column', overflow: 'auto' }"
|
||||
wrapClassName="org-list-modal" @cancel="handleCancelLogs">
|
||||
<a-row>
|
||||
<a-col :span="2" :push="22" style="margin-top: 15px;margin-left: 30px;">
|
||||
|
@ -67,9 +68,9 @@
|
|||
<a-button @click="handleCancelLogs" type="primary" style="float:right;">关闭</a-button>
|
||||
</template>
|
||||
</a-drawer>
|
||||
<!-- 指令库 -->
|
||||
<a-drawer v-model:visible="directiveMainVisible" title="指令库" width="80vw" :footer-style="{ textAlign: 'right' }"
|
||||
:bodyStyle="{ padding: '0', height: '70vh', display: 'flex', flexDirection: 'column', overflow: 'hidden' }"
|
||||
<!-- 标准指令库 -->
|
||||
<a-drawer v-model:visible="directiveMainVisible" title="标准指令库" width="80vw" :footer-style="{ textAlign: 'right' }"
|
||||
:bodyStyle="{ padding: '0', height: '70vh', display: 'flex', flexDirection: 'column', overflow: 'auto' }"
|
||||
wrapClassName="org-list-modal" @cancel="handleCanceldirectiveMain">
|
||||
<template #footer>
|
||||
<a-button @click="handleCanceldirectiveMain" type="primary" style="margin-right: 10px;">关闭</a-button>
|
||||
|
@ -80,15 +81,15 @@
|
|||
</OrgListCom>
|
||||
</a-drawer>
|
||||
<!-- 新增指令 -->
|
||||
<a-drawer v-model:visible="newDirectiveVisible" title="新增指令" width="80vw" :footer-style="{ textAlign: 'right' }"
|
||||
:bodyStyle="{ padding: '0', height: '70vh', display: 'flex', flexDirection: 'column', overflow: 'hidden' }"
|
||||
<a-drawer v-model:visible="newDirectiveVisible" title="新增指令" width="90vw" :footer-style="{ textAlign: 'right' }"
|
||||
:bodyStyle="{ padding: '0', height: '80vh', display: 'flex', flexDirection: 'column', overflow: 'auto' }"
|
||||
wrapClassName="org-list-modal" @cancel="handleCancelNewDirective">
|
||||
<template #footer>
|
||||
<a-button @click="handleCancelNewDirective" type="primary">关闭</a-button>
|
||||
<!-- <a-button @click="handleAsyncNewDirective" type="primary">同步</a-button> -->
|
||||
</template>
|
||||
<CanAddDirectiveList ref="canAddDirectiveRef" :directiveMainOrgInfo="directiveMainOrgInfo"
|
||||
:existDirectiveIds="existDirectiveIds"></CanAddDirectiveList>
|
||||
:existDirectiveIds="existDirectiveIds" @refreshExistIds="refreshDMExistedIds"></CanAddDirectiveList>
|
||||
</a-drawer>
|
||||
</div>
|
||||
</template>
|
||||
|
@ -111,6 +112,7 @@ import { useMessage } from '/@/hooks/web/useMessage';
|
|||
import AsyncListComponent from '@/components/dataAsync/AsyncMainList0731.vue'
|
||||
import { getDirectiveMain, changeDirectiveMain } from '/@/api/common/api'
|
||||
import { idListByDS } from '/@/views/synchronization/directive/serviceDirective/ConfigServiceDirective.api';
|
||||
import { nextTick } from 'process';
|
||||
|
||||
const { createMessage } = useMessage()
|
||||
const canAddDirectiveRef = ref()
|
||||
|
@ -191,6 +193,7 @@ function handleViewLogs() {
|
|||
|
||||
function handleLookNewDirectives() {
|
||||
newDirectiveVisible.value = true
|
||||
refreshDMExistedIds(directiveMainOrgInfo.value, true)
|
||||
}
|
||||
|
||||
//关闭日志模态框
|
||||
|
@ -232,11 +235,20 @@ function handleCanceldirectiveMain() {
|
|||
directiveMainVisible.value = false
|
||||
}
|
||||
|
||||
watch(directiveMainOrgInfo, (newValue, oldValue) => {
|
||||
idListByDS({ dataSourceCode: newValue.orgCode }).then(res => {
|
||||
//刷新已有指令库
|
||||
function refreshDMExistedIds(dmOrgInfo, izReset = false, izQuery = true) {
|
||||
idListByDS({ dataSourceCode: dmOrgInfo.orgCode }).then(res => {
|
||||
existDirectiveIds.value = res.records
|
||||
canAddDirectiveRef.value?.reload()
|
||||
if (izReset) {
|
||||
canAddDirectiveRef.value?.searchReset()
|
||||
} else {
|
||||
canAddDirectiveRef.value?.reload()
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
watch(directiveMainOrgInfo, (newValue, oldValue) => {
|
||||
refreshDMExistedIds(newValue)
|
||||
}, { deep: true })
|
||||
|
||||
const tempDM = ref()
|
||||
|
@ -251,23 +263,24 @@ function directiveMainFunc(orgInfo_) {
|
|||
* 确认指令库
|
||||
*/
|
||||
function handleAsyncdirectiveMain() {
|
||||
createConfirm({
|
||||
iconType: 'warning',
|
||||
title: '指令库变更提醒',
|
||||
content: '是否变更指令库为:' + tempDM.value.departName,
|
||||
okText: '确认',
|
||||
cancelText: '取消',
|
||||
onOk: () => {
|
||||
directiveMainOrgInfo.value = tempDM.value
|
||||
changeDirectiveMain(directiveMainOrgInfo.value.orgCode).then(() => {
|
||||
createMessage.success('指令库已变更')
|
||||
handleCanceldirectiveMain()
|
||||
canAddDirectiveRef.value?.reload()
|
||||
}).catch(() => {
|
||||
createMessage.error('指令库变更失败,请稍后再试')
|
||||
})
|
||||
}
|
||||
});
|
||||
// createConfirm({
|
||||
// iconType: 'warning',
|
||||
// title: '指令库变更提醒',
|
||||
// content: '是否变更指令库为:' + tempDM.value.departName,
|
||||
// okText: '确认',
|
||||
// cancelText: '取消',
|
||||
// onOk: () => {
|
||||
directiveMainOrgInfo.value = tempDM.value
|
||||
changeDirectiveMain(directiveMainOrgInfo.value.orgCode).then(() => {
|
||||
createMessage.success('标准指令库已变更')
|
||||
handleCanceldirectiveMain()
|
||||
canAddDirectiveRef.value?.reload()
|
||||
orgListComRef.value?.reload()
|
||||
}).catch(() => {
|
||||
createMessage.error('指令库变更失败,请稍后再试')
|
||||
})
|
||||
// }
|
||||
// });
|
||||
}
|
||||
|
||||
//获取指令库机构信息
|
||||
|
@ -283,6 +296,7 @@ function getDirectiveMainOrgInfo() {
|
|||
onMounted(() => {
|
||||
reload();
|
||||
getDirectiveMainOrgInfo()
|
||||
orgListComRef.value?.reload();
|
||||
});
|
||||
|
||||
</script>
|
||||
|
|
|
@ -82,7 +82,7 @@
|
|||
</div>
|
||||
</a-card>
|
||||
<a-modal v-model:visible="sourceOrgListVisible" title="请选择源平台" width="90vw"
|
||||
:bodyStyle="{ padding: '0', height: '70vh', display: 'flex', flexDirection: 'column', overflow: 'hidden' }"
|
||||
:bodyStyle="{ padding: '0', height: '70vh', display: 'flex', flexDirection: 'column', overflow: 'auto' }"
|
||||
wrapClassName="org-list-modal" @cancel="handleCancelSource">
|
||||
<template #footer>
|
||||
<a-button @click="handleCancelSource" type="primary">取消</a-button>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
<template>
|
||||
<j-modal :title="title" :visible="visible" :fullscreen="true" width="100vw" :bodyStyle="{ padding: 0 }"
|
||||
<!-- <j-modal :title="title" :visible="visible" :fullscreen="true" width="100vw" :bodyStyle="{ padding: 0 }"
|
||||
:maskClosable="false" :keyboard="false" wrapClassName="modal-fullscreen" @cancel="handleCancel">
|
||||
<template #footer>
|
||||
<a-button @click="handleCancel">关闭</a-button>
|
||||
|
@ -13,14 +13,14 @@
|
|||
</template>
|
||||
<SyncStepList ref="registerForm" v-if="visible" @ok="submitCallback" :formDisabled="disableSubmit" :formBpm="false"
|
||||
:fullscreen="true" style="height:100vh;" @closeModal="closeModal" @changeSyncText="changeSyncText"/>
|
||||
</j-modal>
|
||||
</j-modal> -->
|
||||
|
||||
<!-- <a-drawer :title="title" width="100vw" v-model:visible="visible" :closable="true" :bodyStyle="{ padding: 0 }" :maskClosable="false" :keyboard="false"
|
||||
<a-drawer :title="title" width="100vw" v-model:visible="visible" :closable="true" :bodyStyle="{ padding: 0 }" :maskClosable="false" :keyboard="false"
|
||||
:footer-style="{ textAlign: 'right' }" @close="handleCancel">
|
||||
<SyncStepList ref="registerForm" v-if="visible" @ok="submitCallback" :formDisabled="disableSubmit" :formBpm="false"
|
||||
:fullscreen="true" style="height:100vh;" @closeModal="closeModal" @changeSyncText="changeSyncText"/>
|
||||
<template #footer>
|
||||
<a-button @click="handleCancel">关闭</a-button>
|
||||
<a-button @click="handleCancel" style="margin-right: 10px;">关闭</a-button>
|
||||
<a-button @click="handleSyncFunc">{{syncText}}</a-button>
|
||||
<a-button @click="previousStep"
|
||||
v-show="!!registerForm && (registerForm?.stepVal == 1 || registerForm?.stepVal == 2 || registerForm?.stepVal == 3)">上一步</a-button>
|
||||
|
@ -29,7 +29,7 @@
|
|||
<a-button @click="registerForm?.syncFunc" type="primary"
|
||||
v-show="!!registerForm && registerForm?.stepVal == 3">确认</a-button>
|
||||
</template>
|
||||
</a-drawer> -->
|
||||
</a-drawer>
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
|
|
|
@ -161,7 +161,7 @@ watch(
|
|||
//开始同步
|
||||
function syncFunc() {
|
||||
if (!targetOrgListComRef.value?.selectedOrgs?.length) {
|
||||
createMessage.warning('请选择业务平台')
|
||||
createMessage.warning('请选择目标平台')
|
||||
} else {
|
||||
syncDirective({
|
||||
dataSourceCode: orgInfo.value[0].orgCode,
|
||||
|
|
Loading…
Reference in New Issue