| | |
| | | <!-- |
| | | * @Description: file content |
| | | * @Author: Ben Lin |
| | | * @version: |
| | | * @Date: 2024-06-18 15:09:48 |
| | | * @LastEditors: Ben Lin |
| | | * @LastEditTime: 2024-08-13 20:38:51 |
| | | --> |
| | | <template> |
| | | <BasicModal |
| | | v-bind="$attrs" |
| | | @register="registerModal" |
| | | :defaultFullscreen="true" |
| | | :title="title" |
| | | @ok="custFunction(isUpdate, 'rvSubmit', cType, setModalProps, closeModal, emit, slotName)" |
| | | @ok="custFunction(isUpdate, submitFn, cType, setModalProps, closeModal, emit, slotName)" |
| | | :width="width" |
| | | > |
| | | <!-- 这里嵌入router-view来展示路由页面 --> |
| | | <Route_View :rotId="rotId" /> |
| | | <Route_View :rotId="rotId" :rotType="rotType" :prodCode="prodCode" :custCode="custCode" /> |
| | | </BasicModal> |
| | | </template> |
| | | <script lang="ts" setup> |
| | | import { ref, unref, onMounted } from 'vue'; |
| | | import { GetSelectSuccess, OpenSelectItem, custFunction, getFormSchema } from './data'; |
| | | import { BasicModal, useModalInner, useModal } from '/@/components/Modal'; |
| | | import { ref, onMounted } from 'vue'; |
| | | import { custFunction } from './data'; |
| | | import { BasicModal, useModalInner } from '/@/components/Modal'; |
| | | import Route_View from '/@/views/tigerprojects/mes/eng/route/index.vue'; |
| | | |
| | | const emit = defineEmits(['success', 'register']); |
| | |
| | | const title = ref(''); |
| | | const width = ref(''); |
| | | const rotId = ref(''); |
| | | const rotType = ref(''); |
| | | const prodCode = ref(''); |
| | | const custCode = ref(''); |
| | | const submitFn = ref(''); |
| | | const slotName = ref(''); |
| | | |
| | | const [registerModal, { setModalProps, closeModal }] = useModalInner(async (data) => { |
| | | setModalProps({ confirmLoading: false }); |
| | | setModalProps({ confirmLoading: false, cancelText: '关闭', showOkBtn: false }); |
| | | rotId.value = data?.rotId; |
| | | rotType.value = data?.rotType; |
| | | prodCode.value = data?.prodCode; |
| | | custCode.value = data?.custCode; |
| | | slotName.value = data?.slotName; |
| | | submitFn.value = data?.submitFn; //'rvSubmit' |
| | | }); |
| | | |
| | | onMounted(() => {}); |