feat: agency personnel foreign address
Some checks failed
Spell Check / Spell Check with Typos (push) Failing after 5s

This commit is contained in:
puriphatt 2025-07-16 12:55:51 +07:00
parent 7f56a6219a
commit cdb38e301e
6 changed files with 323 additions and 36 deletions

View file

@ -14,6 +14,7 @@ export function formatAddress(opt: {
district?: District | null;
subDistrict?: SubDistrict | null;
en?: boolean;
zipCode?: string;
}) {
const { t } = useI18n();
let addressParts: string[];
@ -58,7 +59,9 @@ export function formatAddress(opt: {
// );
}
if (opt.subDistrict) addressParts.push(`${opt.subDistrict.zipCode}`);
if (opt.subDistrict && !opt.zipCode)
addressParts.push(`${opt.subDistrict.zipCode}`);
if (opt.zipCode) addressParts.push(`${opt.zipCode}`);
return addressParts.join(' ');
}