Merge branch 'feature-organization-yjl-1101' into dev

feature-JimuReport-1106-yjl
yujinlong 4 weeks ago
commit 23c54c7a63

@ -36,7 +36,7 @@
const isUpdate = ref(true) const isUpdate = ref(true)
const loading = ref(false) const loading = ref(false)
const rowId = ref('') const rowId = ref('')
const linkId = ref('') const orgId = ref('')
const { createMessage } = useMessage() const { createMessage } = useMessage()
const [registerForm, { resetFields, setFieldsValue, validate }] = useForm({ const [registerForm, { resetFields, setFieldsValue, validate }] = useForm({
labelWidth: 100, labelWidth: 100,
@ -48,7 +48,7 @@
resetFields() resetFields()
setModalProps({ confirmLoading: false, loading: true }) setModalProps({ confirmLoading: false, loading: true })
isUpdate.value = !!data?.isUpdate isUpdate.value = !!data?.isUpdate
linkId.value = data.linkId ? data.linkId : '' orgId.value = data.orgId ? data.orgId : ''
if (unref(isUpdate)) { if (unref(isUpdate)) {
rowId.value = data.record.id ? data.record.id : data.record.value rowId.value = data.record.id ? data.record.id : data.record.value
const res: API.DataResult = await getOrgAuthInfo({ id: unref(rowId) }) const res: API.DataResult = await getOrgAuthInfo({ id: unref(rowId) })
@ -77,7 +77,7 @@
try { try {
const values = await validate() const values = await validate()
setModalProps({ confirmLoading: true, loading: true }) setModalProps({ confirmLoading: true, loading: true })
values.linkId = values.linkId ? values.linkId : linkId.value values.orgId = values.orgId ? values.orgId : orgId.value
if (values.status) { if (values.status) {
values.status = 0 values.status = 0
} else { } else {

@ -334,7 +334,7 @@
}) })
}, },
beforeFetch: (p) => { beforeFetch: (p) => {
return formatParams(p) return formatParams({ ...p, orgId: rowId.value })
}, },
maxHeight: 400, maxHeight: 400,
columns: APIColumns, columns: APIColumns,
@ -355,13 +355,14 @@
isParent: false, isParent: false,
isUpdate: false, isUpdate: false,
orgFullName: getFieldsValue().orgFullName, orgFullName: getFieldsValue().orgFullName,
linkId: linkId.value, orgId: linkId.value,
}) })
} }
function EditAPIAuth(record: Recordable) { function EditAPIAuth(record: Recordable) {
openAPIModal(true, { openAPIModal(true, {
record, record,
isUpdate: true, isUpdate: true,
orgId: linkId.value,
}) })
} }
</script> </script>

@ -776,7 +776,7 @@ export const APIformSchema: FormSchema[] = [
}, },
{ {
label: '', label: '',
field: 'linkId', field: 'orgId',
component: 'Input', component: 'Input',
defaultValue: '', defaultValue: '',
show: false, show: false,

Loading…
Cancel
Save