diff --git a/src/modules/02_users/components/RoleOrganization/DialogAddPerson.vue b/src/modules/02_users/components/RoleOrganization/DialogAddPerson.vue index cec60777..43b51b28 100644 --- a/src/modules/02_users/components/RoleOrganization/DialogAddPerson.vue +++ b/src/modules/02_users/components/RoleOrganization/DialogAddPerson.vue @@ -116,6 +116,7 @@ async function onSearchListPerson(newPage: boolean = false) { * เมื่อเพิ่มเสร็จจะดึงข้อมูลรายชื่อคนที่มีสิทธิ์จัดการโครงสร้างตามหน่วยงาน */ function onSubmitPerson() { + const arrayId = selected.value.map((e: DataProfile) => e.id); dialogConfirm( $q, async () => { @@ -123,7 +124,7 @@ function onSubmitPerson() { const person = selected.value[0]; const body = { nodeId: orgId.value, - personId: person.id, + personId: arrayId, }; await http .post(config.API.permissionOrg, body) @@ -232,13 +233,20 @@ watch( bordered dense :rows-per-page-options="[10, 25, 50, 100]" - selection="single" + selection="multiple" v-model:selected="selected" @update:pagination="updatePagination" >