แก้ไข step 2 ประเมิน ไม่ได้ดึงข้อมูลสังกัดมาแสดงเป็นค่าเริ่มต้น
This commit is contained in:
parent
1db13be8b0
commit
d203a319b5
2 changed files with 19 additions and 16 deletions
|
|
@ -272,11 +272,13 @@ function getCommander() {
|
|||
.get(config.API.searchCommander)
|
||||
.then((res) => {
|
||||
const data = res.data.result;
|
||||
formCommand.author = data.fullname;
|
||||
formCommand.author = data.fullname;
|
||||
formCommand.commanderFullname = data.commanderFullname;
|
||||
formCommand.commanderPosition = data.commanderPosition;
|
||||
formCommand.commanderAboveFullname = data.commanderAboveFullname;
|
||||
formCommand.commanderAbovePosition = data.commanderAbovePosition;
|
||||
formCommand.commanderOrg = data.commanderOrg;
|
||||
formCommand.commanderAboveOrg = data.commanderAboveOrg;
|
||||
})
|
||||
.catch((e) => {
|
||||
console.log(e);
|
||||
|
|
@ -316,7 +318,6 @@ watch(
|
|||
onMounted(async () => {
|
||||
const user = await tokenParsed();
|
||||
|
||||
|
||||
try {
|
||||
showLoader();
|
||||
await Promise.all([
|
||||
|
|
|
|||
|
|
@ -195,20 +195,22 @@ async function checkDoc() {
|
|||
});
|
||||
}
|
||||
|
||||
function getCommander() {
|
||||
http
|
||||
.get(config.API.searchCommander)
|
||||
.then((res) => {
|
||||
const data = res.data.result;
|
||||
formCommand.commanderFullname = data.commanderFullname;
|
||||
formCommand.commanderPosition = data.commanderPosition;
|
||||
formCommand.commanderAboveFullname = data.commanderAboveFullname;
|
||||
formCommand.commanderAbovePosition = data.commanderAbovePosition;
|
||||
})
|
||||
.catch((e) => {
|
||||
messageError($q, e);
|
||||
});
|
||||
}
|
||||
// function getCommander() {
|
||||
// http
|
||||
// .get(config.API.searchCommander)
|
||||
// .then((res) => {
|
||||
// const data = res.data.result;
|
||||
// formCommand.commanderFullname = data.commanderFullname;
|
||||
// formCommand.commanderPosition = data.commanderPosition;
|
||||
// formCommand.commanderAboveFullname = data.commanderAboveFullname;
|
||||
// formCommand.commanderAbovePosition = data.commanderAbovePosition;
|
||||
// formCommand.commanderOrg = data.commanderOrg;
|
||||
// formCommand.commanderAboveOrg = data.commanderAboveOrg;
|
||||
// })
|
||||
// .catch((e) => {
|
||||
// messageError($q, e);
|
||||
// });
|
||||
// }
|
||||
|
||||
function onAddSubject() {
|
||||
formCommand.subject.push("");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue