เอา บังคับ ออก
This commit is contained in:
parent
93a4124c89
commit
d1316ecb6a
2 changed files with 19 additions and 6 deletions
|
|
@ -82,6 +82,7 @@ export default {
|
|||
* รายการคำร้องขอแก้ไขข้อมูลทะเบียนประวัติ
|
||||
*/
|
||||
requestEdit: `${profileOrg}/edit/`,
|
||||
requestsEdit: `${profileOrg}/edit`,
|
||||
developmentUser: `${profileOrg}/development/user`,
|
||||
|
||||
upDateNumber:`${profileOrg}/updatePhoneNumber/user`,
|
||||
|
|
|
|||
|
|
@ -50,16 +50,24 @@ function closeDialog() {
|
|||
function onSubmit() {
|
||||
dialogConfirm(
|
||||
$q,
|
||||
() => {
|
||||
async () => {
|
||||
showLoader();
|
||||
http
|
||||
.post(config.API.requestEdit, {
|
||||
await http
|
||||
.post(config.API.requestsEdit, {
|
||||
topic: formData.topic,
|
||||
detail: formData.detail,
|
||||
profileId: profileId.value,
|
||||
})
|
||||
.then((res) => {
|
||||
createURLUpload(res.data.result, formData.document);
|
||||
.then(async (res) => {
|
||||
if (formData.document) {
|
||||
createURLUpload(res.data.result, formData.document);
|
||||
} else {
|
||||
formData.document = null;
|
||||
await props.fetchData?.();
|
||||
await success($q, "บันทึกข้อมูลสำเร็จ");
|
||||
closeDialog();
|
||||
hideLoader();
|
||||
}
|
||||
})
|
||||
.catch((err) => {
|
||||
messageError($q, err);
|
||||
|
|
@ -253,7 +261,11 @@ watch(
|
|||
: '.pdf,.xlsx,.docx'
|
||||
"
|
||||
hide-bottom-space
|
||||
:rules="[(val:any) => !!val || `${'กรุณาเลือกไฟล์'}`]"
|
||||
:rules="formData.topic !== 'ขอปรับปรุงข้อมูลจากกรมการปกครอง' &&
|
||||
formData.topic !== 'ขอแก้ไขอาชีพ คู่สมรส' &&
|
||||
formData.topic !== 'ขอแก้ไขอาชีพ บิดา' &&
|
||||
formData.topic !== 'ขอแก้ไขอาชีพ มารดา' &&
|
||||
formData.topic !== 'ขอแก้ไขที่อยู่ปัจจุบัน'?[(val:any) => !!val || `${'กรุณาเลือกไฟล์'}`]:''"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue