|
|
|
@ -10,7 +10,6 @@ const props = defineProps({ |
|
|
|
|
type: Object, |
|
|
|
|
}, |
|
|
|
|
}) |
|
|
|
|
console.log(props.data, 'djegd ') |
|
|
|
|
const formModel = ref() |
|
|
|
|
const loading = ref() |
|
|
|
|
//抽屉true |
|
|
|
@ -19,6 +18,7 @@ const editForm = ref({ |
|
|
|
|
name: '', |
|
|
|
|
content: '', |
|
|
|
|
}) |
|
|
|
|
|
|
|
|
|
const readonlyField = computed(() => editForm.value.name) |
|
|
|
|
const editRowIndex = ref() |
|
|
|
|
const openEditDialog = (row) => { |
|
|
|
@ -46,14 +46,18 @@ const cancelEdit = () => { |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
onMounted(() => { |
|
|
|
|
if (props.data.roleId === 1) { |
|
|
|
|
if (props.data.roleId[0] === '1') { |
|
|
|
|
formModel.value = [ |
|
|
|
|
{ par: 'name', name: '姓名', content: props.data.name }, |
|
|
|
|
{ par: 'sex', name: '性别', content: props.data.sex }, |
|
|
|
|
{ par: 'nationality', name: '民族', content: props.data.nationality }, |
|
|
|
|
{ par: 'profession', name: '专业', content: props.data.profession }, |
|
|
|
|
{ par: 'education', name: '学历', content: props.data.education }, |
|
|
|
|
{ par: 'degree', name: '学位', content: props.data.degree }, |
|
|
|
|
{ |
|
|
|
|
par: 'academicDegree', |
|
|
|
|
name: '学位', |
|
|
|
|
content: props.data.academicDegree, |
|
|
|
|
}, |
|
|
|
|
{ |
|
|
|
|
par: 'professionalTitle', |
|
|
|
|
name: '职称', |
|
|
|
@ -75,7 +79,7 @@ onMounted(() => { |
|
|
|
|
content: props.data.politicalStatus, |
|
|
|
|
}, |
|
|
|
|
] |
|
|
|
|
} else if (props.data.roleId === 2) { |
|
|
|
|
} else if (props.data.roleId[0] === '2') { |
|
|
|
|
formModel.value = [ |
|
|
|
|
{ par: 'name', name: '姓名', content: props.data.name }, |
|
|
|
|
{ par: 'sex', name: '性别', content: props.data.sex }, |
|
|
|
|