修改bug
This commit is contained in:
parent
a0a069be47
commit
59066b7615
|
@ -3,7 +3,7 @@
|
||||||
* @Description: logo component
|
* @Description: logo component
|
||||||
-->
|
-->
|
||||||
<template>
|
<template>
|
||||||
<div class="anticon" :class="getAppLogoClass" @click="goHome" style="text-align: center;">
|
<div class="anticon" :class="getAppLogoClass" @click="goHome" style="background: #e2edff !important;text-align: center;">
|
||||||
<img src="../../../assets/images/logo.png" />
|
<img src="../../../assets/images/logo.png" />
|
||||||
<div class="ml-2 truncate md:opacity-100" :class="getTitleClass" v-show="showTitle">
|
<div class="ml-2 truncate md:opacity-100" :class="getTitleClass" v-show="showTitle">
|
||||||
{{ shortTitle }}
|
{{ shortTitle }}
|
||||||
|
|
|
@ -11,7 +11,7 @@
|
||||||
/>
|
/>
|
||||||
<LayoutBreadcrumb v-if="getShowContent && getShowBread" :theme="getHeaderTheme" />
|
<LayoutBreadcrumb v-if="getShowContent && getShowBread" :theme="getHeaderTheme" />
|
||||||
<!-- 欢迎语 -->
|
<!-- 欢迎语 -->
|
||||||
<span v-if="getShowContent && getShowBreadTitle && !getIsMobile" style="" :class="[prefixCls, `${prefixCls}--${getHeaderTheme}`,'headerIntroductionClass']"> {{t('layout.header.welcomeIn')}} {{ title }} </span>
|
<span v-if="getShowContent && getShowBreadTitle && !getIsMobile" style="background:#e2edff !important" :class="[prefixCls, `${prefixCls}--${getHeaderTheme}`,'headerIntroductionClass']"> {{t('layout.header.welcomeIn')}} {{ title }} </span>
|
||||||
</div>
|
</div>
|
||||||
<!-- left end -->
|
<!-- left end -->
|
||||||
|
|
||||||
|
@ -266,5 +266,7 @@
|
||||||
// background-repeat: no-repeat;
|
// background-repeat: no-repeat;
|
||||||
// background-size: 100% auto;
|
// background-size: 100% auto;
|
||||||
// background-color: #f3f6fe !important;
|
// background-color: #f3f6fe !important;
|
||||||
|
|
||||||
|
background: linear-gradient(to right, #e2edff, #eef3f8) !important;
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
|
@ -47,7 +47,7 @@ import { BasicTable, useTable, TableAction } from '/@/components/Table';
|
||||||
import { useListPage } from '/@/hooks/system/useListPage';
|
import { useListPage } from '/@/hooks/system/useListPage';
|
||||||
import { columns, superQuerySchema } from './CanAddDirective.data';
|
import { columns, superQuerySchema } from './CanAddDirective.data';
|
||||||
import { list, deleteOne, batchDelete, getImportUrl, getExportUrl } from './CanAddDirective.api';
|
import { list, deleteOne, batchDelete, getImportUrl, getExportUrl } from './CanAddDirective.api';
|
||||||
import CanAddDirectiveModal from './components/CanAddDirectiveModal.vue'
|
import CanAddDirectiveModal from './components/CanAddDirectiveDetailModal.vue'
|
||||||
import { useUserStore } from '/@/store/modules/user';
|
import { useUserStore } from '/@/store/modules/user';
|
||||||
import JDictSelectTag from '/@/components/Form/src/jeecg/components/JDictSelectTag.vue';
|
import JDictSelectTag from '/@/components/Form/src/jeecg/components/JDictSelectTag.vue';
|
||||||
import { syncDirective } from '/@/views/synchronization/directive/serviceDirective/ConfigServiceDirective.api';
|
import { syncDirective } from '/@/views/synchronization/directive/serviceDirective/ConfigServiceDirective.api';
|
||||||
|
@ -112,6 +112,7 @@ const wrapperCol = reactive({
|
||||||
* 详情
|
* 详情
|
||||||
*/
|
*/
|
||||||
function handleDetail(record: Recordable) {
|
function handleDetail(record: Recordable) {
|
||||||
|
console.log("🚀 ~ handleDetail ~ record:", record)
|
||||||
registerModal.value.disableSubmit = true;
|
registerModal.value.disableSubmit = true;
|
||||||
registerModal.value.edit(record);
|
registerModal.value.edit(record);
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,315 @@
|
||||||
|
<template>
|
||||||
|
<a-spin :spinning="confirmLoading">
|
||||||
|
<JFormContainer>
|
||||||
|
<template #detail>
|
||||||
|
<a-form ref="formRef" class="antd-modal-form" :labelCol="labelCol" :wrapperCol="wrapperCol"
|
||||||
|
name="ConfigService2DirectiveForm">
|
||||||
|
<a-row v-show="isAudit">
|
||||||
|
<a-col :span="12">
|
||||||
|
<a-config-provider :disabled="false">
|
||||||
|
<a-form-item label="服务指令审核" v-bind="validateInfos.statusVal" id="ConfigServiceDirectiveForm-statusVal"
|
||||||
|
name="statusVal">
|
||||||
|
<a-select v-model:value="formData.statusVal" placeholder="请选择审核状态" style="width: 200px"
|
||||||
|
:disabled="false">
|
||||||
|
<a-select-option value="auditPass">审核通过</a-select-option>
|
||||||
|
<a-select-option value="auditFaild">审核不通过</a-select-option>
|
||||||
|
</a-select>
|
||||||
|
</a-form-item>
|
||||||
|
</a-config-provider>
|
||||||
|
</a-col>
|
||||||
|
</a-row>
|
||||||
|
</a-form>
|
||||||
|
</template>
|
||||||
|
</JFormContainer>
|
||||||
|
<JFormContainer :disabled="disabled" style="margin-top: -30px;">
|
||||||
|
<template #detail>
|
||||||
|
<a-form ref="formRef" class="antd-modal-form" :labelCol="labelCol" :wrapperCol="wrapperCol"
|
||||||
|
name="ConfigService2DirectiveForm">
|
||||||
|
<a-row v-show="!isEditMedia">
|
||||||
|
<a-col :span="12">
|
||||||
|
<a-form-item label="分类标签" v-bind="validateInfos.instructionTagId"
|
||||||
|
id="ConfigServiceDirectiveForm-instructionTagId" name="instructionTagId">
|
||||||
|
{{formData.instructionTag}}
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :span="12">
|
||||||
|
<a-form-item label="服务类别" v-bind="validateInfos.categoryId" id="ConfigServiceDirectiveForm-categoryId"
|
||||||
|
name="categoryId">
|
||||||
|
{{formData.category}}
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :span="12">
|
||||||
|
<a-form-item label="服务类型" v-bind="validateInfos.typeId" id="ConfigServiceDirectiveForm-typeId"
|
||||||
|
name="typeId">
|
||||||
|
{{formData.type}}
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :span="12">
|
||||||
|
<a-form-item label="服务指令名称" v-bind="validateInfos.directiveName"
|
||||||
|
id="ConfigServiceDirectiveForm-directiveName" name="directiveName">
|
||||||
|
{{formData.directiveName}}
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :span="12">
|
||||||
|
<a-form-item label="收费价格(元)" v-bind="validateInfos.tollPrice" id="ConfigServiceDirectiveForm-tollPrice"
|
||||||
|
name="tollPrice">
|
||||||
|
{{formData.tollPrice}}
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :span="12">
|
||||||
|
<a-form-item label="提成价格(元)" v-bind="validateInfos.comPrice" id="ConfigServiceDirectiveForm-comPrice"
|
||||||
|
name="comPrice">
|
||||||
|
{{formData.comPrice}}
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :span="12">
|
||||||
|
<a-form-item label="医保报销" v-bind="validateInfos.izReimbursement"
|
||||||
|
id="ConfigServiceDirectiveForm-izReimbursement" name="izReimbursement">
|
||||||
|
{{formData.izReimbursement=='1'?'报销':'不报销'}}
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :span="12">
|
||||||
|
<a-form-item label="机构优惠" v-bind="validateInfos.izPreferential"
|
||||||
|
id="ConfigServiceDirectiveForm-izPreferential" name="izPreferential">
|
||||||
|
{{formData.izPreferential=='1'?'参与':'不参与'}}
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :span="12">
|
||||||
|
<a-form-item label="周期类型" v-bind="validateInfos.cycleType" id="ConfigServiceDirectiveForm-cycleType"
|
||||||
|
name="cycleType">
|
||||||
|
<span v-if="formData.cycleType=='1'">日常护理</span>
|
||||||
|
<span v-if="formData.cycleType=='2'">周期护理</span>
|
||||||
|
<span v-if="formData.cycleType=='3'">即时护理</span>
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :span="12">
|
||||||
|
<a-form-item label="服务时长(分钟)" v-bind="validateInfos.serviceDuration"
|
||||||
|
id="ConfigServiceDirectiveForm-serviceDuration" name="serviceDuration">
|
||||||
|
{{formData.serviceDuration}}
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
</a-row>
|
||||||
|
<a-col :span="12">
|
||||||
|
<a-form-item label="服务指令描述" v-bind="validateInfos.serviceContent"
|
||||||
|
id="ConfigServiceDirectiveForm-serviceContent" name="serviceContent">
|
||||||
|
{{formData.serviceContent}}
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
</a-form>
|
||||||
|
</template>
|
||||||
|
</JFormContainer>
|
||||||
|
</a-spin>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script lang="ts" setup>
|
||||||
|
import { ref, reactive, defineExpose, nextTick, defineProps, computed, onMounted, watch } 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 { JCheckbox } from '/@/components/Form';
|
||||||
|
import JUpload from '/@/components/Form/src/jeecg/components/JUpload/JUpload.vue';
|
||||||
|
import JImageUpload from '/@/components/Form/src/jeecg/components/JImageUpload.vue';
|
||||||
|
import { getValueType } from '/@/utils';
|
||||||
|
import { Form } from 'ant-design-vue';
|
||||||
|
import JFormContainer from '/@/components/Form/src/container/JFormContainer.vue';
|
||||||
|
import { getFileAccessHttpUrl } from '/@/utils/common/compUtils';
|
||||||
|
|
||||||
|
const props = defineProps({
|
||||||
|
formDisabled: { type: Boolean, default: false },
|
||||||
|
formData: { type: Object, default: () => ({}) },
|
||||||
|
formBpm: { type: Boolean, default: true },
|
||||||
|
});
|
||||||
|
const bodyTagDictCode = ref(`nu_config_body_tag,tag_name,id,1=2`)
|
||||||
|
const emotionTagDictCode = ref(`nu_config_emotion_tag,tag_name,id,1=2`)
|
||||||
|
const formRef = ref();
|
||||||
|
const useForm = Form.useForm;
|
||||||
|
const emit = defineEmits(['register', 'ok']);
|
||||||
|
const formData = reactive<Record<string, any>>({
|
||||||
|
id: '',
|
||||||
|
categoryId: '',
|
||||||
|
typeId: '',
|
||||||
|
instructionTagId: '',
|
||||||
|
directiveName: '',
|
||||||
|
tollPrice: 0,
|
||||||
|
comPrice: 0,
|
||||||
|
izReimbursement: '0',
|
||||||
|
izPreferential: '0',
|
||||||
|
chargingFrequency: '',
|
||||||
|
cycleType: '',
|
||||||
|
sort: 99,
|
||||||
|
serviceContent: '',
|
||||||
|
serviceDuration: '5',
|
||||||
|
izEnabled: '0',
|
||||||
|
createBy: '',
|
||||||
|
createTime: '',
|
||||||
|
updateBy: '',
|
||||||
|
updateTime: '',
|
||||||
|
mp3File: '',
|
||||||
|
mp4File: '',
|
||||||
|
previewFile: '',
|
||||||
|
immediateFile: '',
|
||||||
|
status: '',
|
||||||
|
statusVal: undefined,
|
||||||
|
sysOrgCode: undefined,
|
||||||
|
instructionTag:'',
|
||||||
|
category:'',
|
||||||
|
type:'',
|
||||||
|
});
|
||||||
|
const { createMessage } = useMessage();
|
||||||
|
const labelCol = ref<any>({ xs: { span: 24 }, sm: { span: 8 } });
|
||||||
|
const wrapperCol = ref<any>({ xs: { span: 24 }, sm: { span: 16 } });
|
||||||
|
const confirmLoading = ref<boolean>(false);
|
||||||
|
const isEditMedia = ref(false)
|
||||||
|
const isAudit = ref(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;
|
||||||
|
});
|
||||||
|
const categoryDictCode = ref('')
|
||||||
|
const typeDictCode = ref('')
|
||||||
|
// 计算属性:是否可以上传预览图片
|
||||||
|
const canUploadPreviewImage = computed(() => {
|
||||||
|
return formData.instructionTagId &&
|
||||||
|
formData.categoryId &&
|
||||||
|
formData.typeId &&
|
||||||
|
formData.directiveName &&
|
||||||
|
formData.cycleType;
|
||||||
|
});
|
||||||
|
|
||||||
|
//分类标签名称
|
||||||
|
const instructionComDictCode = ref([])
|
||||||
|
function upInstructionDictCode(v_) {
|
||||||
|
instructionComDictCode.value = v_
|
||||||
|
}
|
||||||
|
//服务类别名称
|
||||||
|
const categoryComDictCode = ref([])
|
||||||
|
function upCategoryDictCode(v_) {
|
||||||
|
categoryComDictCode.value = v_
|
||||||
|
|
||||||
|
}
|
||||||
|
//服务类型名称
|
||||||
|
const typeComDictCode = ref([])
|
||||||
|
function upTypeDictCode(v_) {
|
||||||
|
typeComDictCode.value = v_
|
||||||
|
|
||||||
|
}
|
||||||
|
//周期类型名称
|
||||||
|
const cycleTypeComDictCode = ref([])
|
||||||
|
function upCycleTypeDictCode(v_) {
|
||||||
|
cycleTypeComDictCode.value = v_
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
watch([instructionComDictCode, categoryComDictCode, typeComDictCode, cycleTypeComDictCode], () => {
|
||||||
|
// 当这些字典数据变化时,强制重新计算 directiveBizPath
|
||||||
|
}, { deep: true });
|
||||||
|
|
||||||
|
const directiveBizPath = computed(() => {
|
||||||
|
if (!canUploadPreviewImage.value) return '';
|
||||||
|
|
||||||
|
// 获取各个字段的字典值
|
||||||
|
const instructionTagName_ = instructionComDictCode.value.filter(d => d.value == formData.instructionTagId)?.[0]?.label;
|
||||||
|
const categoryName_ = categoryComDictCode.value.filter(d => d.value == formData.categoryId)?.[0]?.label;
|
||||||
|
const typeName_ = typeComDictCode.value.filter(d => d.value == formData.typeId)?.[0]?.label;
|
||||||
|
const cycleTypeName_ = cycleTypeComDictCode.value.filter(d => d.value == formData.cycleType)?.[0]?.label;
|
||||||
|
|
||||||
|
// 构建路径
|
||||||
|
return 'directive/' + `${instructionTagName_}/${categoryName_}/${typeName_}/${formData.directiveName}/${cycleTypeName_}`;
|
||||||
|
});
|
||||||
|
|
||||||
|
watch(
|
||||||
|
() => formData.instructionTagId,
|
||||||
|
(newInstructionTagId) => {
|
||||||
|
if (!newInstructionTagId) {
|
||||||
|
formData.categoryId = ''
|
||||||
|
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 iz_enabled = 0 and iz_enabled = 0 and instruction_id = '${newInstructionTagId}' order by sort asc`;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
);
|
||||||
|
watch(
|
||||||
|
() => formData.categoryId,
|
||||||
|
(newCategoryId) => {
|
||||||
|
if (!newCategoryId) {
|
||||||
|
formData.typeId = ''
|
||||||
|
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 iz_enabled = 0 and category_id = '${newCategoryId}' order by sort asc`;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
);
|
||||||
|
/**
|
||||||
|
* 新增
|
||||||
|
*/
|
||||||
|
function add() {
|
||||||
|
edit({});
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 编辑
|
||||||
|
* isEditMedia_是否为编辑指令资源 (隐藏业务字段)
|
||||||
|
* isAudit_是否为服务指令那个审核 (隐藏业务字段)
|
||||||
|
*/
|
||||||
|
function edit(record, isEditMedia_ = false, isAudit_ = false) {
|
||||||
|
console.log("🌊 ~ edit ~ record:", record)
|
||||||
|
if (!!record.bodyTags) {
|
||||||
|
// 将逗号分隔的字符串转换为 "id = 'id1' or id = 'id2'" 格式
|
||||||
|
const bodyTagConditions = record.bodyTags.split(',')
|
||||||
|
.map(id => `id = '${id}'`)
|
||||||
|
.join(' or ');
|
||||||
|
bodyTagDictCode.value = `nu_config_body_tag,tag_name,id,del_flag = 0 and iz_enabled = 0 ` +
|
||||||
|
(bodyTagConditions ? ` and (${bodyTagConditions})` : '') +
|
||||||
|
` order by sort asc`;
|
||||||
|
}
|
||||||
|
if (!!record.emotionTags) {
|
||||||
|
// 将逗号分隔的字符串转换为 "id = 'id1' or id = 'id2'" 格式
|
||||||
|
const emotionTagConditions = record.emotionTags.split(',')
|
||||||
|
.map(id => `id = '${id}'`)
|
||||||
|
.join(' or ');
|
||||||
|
emotionTagDictCode.value = `nu_config_emotion_tag,tag_name,id,del_flag = 0 and iz_enabled = 0 ` +
|
||||||
|
(emotionTagConditions ? ` and (${emotionTagConditions})` : '') +
|
||||||
|
` order by sort asc`;
|
||||||
|
}
|
||||||
|
isEditMedia.value = isEditMedia_
|
||||||
|
isAudit.value = isAudit_
|
||||||
|
formData.bodyTags = ''
|
||||||
|
formData.emotionTags = ''
|
||||||
|
nextTick(() => {
|
||||||
|
resetFields();
|
||||||
|
const tmpData = {};
|
||||||
|
Object.keys(formData).forEach((key) => {
|
||||||
|
if (record.hasOwnProperty(key)) {
|
||||||
|
tmpData[key] = record[key]
|
||||||
|
}
|
||||||
|
})
|
||||||
|
//赋值
|
||||||
|
Object.assign(formData, tmpData);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
defineExpose({
|
||||||
|
add,
|
||||||
|
edit,
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style lang="less" scoped>
|
||||||
|
.antd-modal-form {
|
||||||
|
padding: 14px;
|
||||||
|
}
|
||||||
|
</style>
|
|
@ -0,0 +1,148 @@
|
||||||
|
<template>
|
||||||
|
<a-drawer :title="title" width="70vw" v-model:visible="visible" :footer-style="{ textAlign: 'right' }" @cancel="handleCancel"
|
||||||
|
cancelText="关闭" :maskClosable="true">
|
||||||
|
<template #footer>
|
||||||
|
<a-button @click="handleCancel">关闭</a-button>
|
||||||
|
</template>
|
||||||
|
<CanAddDirectiveForm ref="registerForm" v-if="visible" @ok="submitCallback" :formDisabled="disableSubmit"
|
||||||
|
:formBpm="false"></CanAddDirectiveForm>
|
||||||
|
</a-drawer>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script lang="ts" setup>
|
||||||
|
import { ref, nextTick, defineExpose, defineProps } from 'vue';
|
||||||
|
import CanAddDirectiveForm from './CanAddDirectiveDetail.vue'
|
||||||
|
import JModal from '/@/components/Modal/src/JModal/JModal.vue';
|
||||||
|
import { queryById } from '/@/views/synchronization/directive/serviceDirective/ConfigServiceDirective.api';
|
||||||
|
|
||||||
|
const props = defineProps({
|
||||||
|
});
|
||||||
|
const title = ref<string>('');
|
||||||
|
const visible = ref<boolean>(false);
|
||||||
|
const auditVisible = ref<boolean>(false);
|
||||||
|
const disableSubmit = ref<boolean>(false);
|
||||||
|
const registerForm = ref();
|
||||||
|
const auditListRef = ref();
|
||||||
|
const emit = defineEmits(['register', 'success']);
|
||||||
|
const opeType = ref('')//操作类型 add新增 edit编辑 editMedia主列表-指令资源 look详情 audit审核 auditMedia审核列表-指令资源
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 编辑
|
||||||
|
* @param record
|
||||||
|
*/
|
||||||
|
function edit(record) {
|
||||||
|
title.value = '详情';
|
||||||
|
visible.value = true;
|
||||||
|
queryById({ dataSourceCode: record.orgCode, id: record.directiveId }).then(res => {
|
||||||
|
res.instructionTag = record.instructionTag;
|
||||||
|
res.category = record.category;
|
||||||
|
res.type = record.type;
|
||||||
|
registerForm.value.edit(res);
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 审核列表 - 审核
|
||||||
|
* @param record
|
||||||
|
*/
|
||||||
|
function audit(record) {
|
||||||
|
title.value = '审核';
|
||||||
|
visible.value = true;
|
||||||
|
nextTick(() => {
|
||||||
|
registerForm.value.edit(record, false, true);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 打开审核列表
|
||||||
|
*/
|
||||||
|
function openAuditList() {
|
||||||
|
auditVisible.value = true;
|
||||||
|
auditListRef.value?.open();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 编辑指令资源
|
||||||
|
* @param record
|
||||||
|
*/
|
||||||
|
function editMedia(record) {
|
||||||
|
title.value = '编辑指令资源';
|
||||||
|
visible.value = true;
|
||||||
|
nextTick(() => {
|
||||||
|
registerForm.value.edit(record, true);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 确定按钮点击事件
|
||||||
|
*/
|
||||||
|
function handleOk() {
|
||||||
|
if (opeType.value == 'audit') {
|
||||||
|
registerForm.value.submitAudit();
|
||||||
|
} else {
|
||||||
|
registerForm.value.submitForm();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 暂存
|
||||||
|
*/
|
||||||
|
function handleSave() {
|
||||||
|
registerForm.value.submitForm();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 给审核对应的业务平台同步资源
|
||||||
|
*/
|
||||||
|
function handleMediaAsync() {
|
||||||
|
registerForm.value.syncMediaForBizFunc();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 给所有业务平台同步资源
|
||||||
|
*/
|
||||||
|
function handleMediaSyncAllPlat() {
|
||||||
|
registerForm.value.syncMediaForAllBizFunc();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* form保存回调事件
|
||||||
|
*/
|
||||||
|
function submitCallback() {
|
||||||
|
handleCancel();
|
||||||
|
emit('success');
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 取消按钮回调事件
|
||||||
|
*/
|
||||||
|
function handleCancel() {
|
||||||
|
visible.value = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 审核列表-关闭按钮回调事件
|
||||||
|
*/
|
||||||
|
function handleAuditCancel() {
|
||||||
|
auditVisible.value = false;
|
||||||
|
emit('success')
|
||||||
|
}
|
||||||
|
|
||||||
|
defineExpose({
|
||||||
|
edit,
|
||||||
|
editMedia,
|
||||||
|
disableSubmit,
|
||||||
|
audit,
|
||||||
|
openAuditList,
|
||||||
|
opeType,
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style lang="less">
|
||||||
|
/**隐藏样式-modal确定按钮 */
|
||||||
|
.jee-hidden {
|
||||||
|
display: none !important;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
<style lang="less" scoped></style>
|
Loading…
Reference in New Issue