([
{
name: "isCondition",
align: "left",
- label: "ตำแหน่งติดเงื่อนไง",
+ label: "ตำแหน่งติดเงื่อนไข",
sortable: false,
field: "isCondition",
headerStyle: "font-size: 14px",
@@ -256,7 +256,18 @@ async function fetchDataTable() {
const data = await res.data.result;
totalRow.value = data.total;
totalPage.value = Math.ceil(data.total / pageSize.value);
- rows.value = data.data;
+ rows.value = data.data.map((e: any) => ({
+ ...e,
+ profilePosition: e.profilePosition
+ ? e.profilePosition
+ : e.positions[0].positionName,
+ profilePostype: e.profilePostype
+ ? e.profilePostype
+ : e.positions[0].posTypeName,
+ profilePoslevel: e.profilePoslevel
+ ? e.profilePoslevel
+ : e.positions[0].posTypeName,
+ }));
})
.catch((err) => {
messageError($q, err);