From 8fce5ff2df873f524eddb833f273e0a69081e94a Mon Sep 17 00:00:00 2001 From: puriphatt Date: Tue, 24 Sep 2024 11:26:22 +0700 Subject: [PATCH] refactor/feat: i18n & constant --- src/i18n/eng/index.ts | 26 +++++++++++++++++++++++++- src/i18n/tha/index.ts | 26 +++++++++++++++++++++++++- src/pages/05_quotation/constants.ts | 10 ++++++++++ 3 files changed, 60 insertions(+), 2 deletions(-) diff --git a/src/i18n/eng/index.ts b/src/i18n/eng/index.ts index ec6d9fe7..bdee015d 100644 --- a/src/i18n/eng/index.ts +++ b/src/i18n/eng/index.ts @@ -73,6 +73,13 @@ export default { view: 'View {msg}', attachment: 'Attachment', about: 'About', + total: 'Total', + discount: 'Discount', + totalAfterDiscount: 'Total after discount', + totalVatExcluded: 'Tax exemption amount', + totalVatIncluded: 'Taxable amount', + vat: 'VAT {msg}', + totalAmount: 'Total amount', }, menu: { @@ -575,7 +582,7 @@ export default { quotation: { title: 'Quotation', customerName: 'Customer Name', - reporter: 'Reporter', + actor: 'Actor', totalPrice: 'Total (Baht)', receipt: 'Receipt/Tax Invoice', branch: 'Branch that issues the quotation', @@ -583,6 +590,22 @@ export default { newCustomer: 'New Customer', employeeList: 'Employee List', employee: 'Employee', + workName: 'Work Name', + contactName: 'Contact Name', + documentReceivePoint: 'Document Drop-Off Point"', + dueDate: 'Quotation Due Date', + + paymentCondition: 'Payment Terms', + payType: 'Payment Methods', + bank: 'Select Payment Account', + paySplitCount: 'Number of Installments', + payTotal: 'Total {msg}', + + summary: 'Total Summary', + periodNo: 'Installment No."', + amount: 'Amount', + payDueDate: 'Pay Due Date', + callDueDate: 'Call Due Date', type: { all: 'All', fullAmountCash: 'Full Amount Cash', @@ -677,6 +700,7 @@ export default { validateError: 'Validate Error', codeMisMatch: 'Code Mismatch', userExists: 'User already exits.', + crossCompanyNotPermit: 'Cannot move between different headoffice', }, }, }; diff --git a/src/i18n/tha/index.ts b/src/i18n/tha/index.ts index c223f284..1c6258b5 100644 --- a/src/i18n/tha/index.ts +++ b/src/i18n/tha/index.ts @@ -73,6 +73,13 @@ export default { view: 'ดู{msg}', attachment: 'เอกสาร', about: 'เกี่ยวกับ', + total: 'ยอดรวม', + discount: 'ส่วนลด', + totalAfterDiscount: 'จำนวนเงินหลังหักส่วนลด', + totalVatExcluded: 'จำนวนเงินยกเว้นภาษี', + totalVatIncluded: 'จำนวนเงินที่คำนวณภาษี', + vat: 'ภาษีมูลค่าเพิ่ม {msg}', + totalAmount: 'จำนวนเงินรวมทั้งสิ้น', }, menu: { @@ -573,7 +580,7 @@ export default { quotation: { title: 'ใบเสนอราคา', customerName: 'ชื่อลูกค้า', - reporter: 'ผู้ที่ทำรายงาน', + actor: 'ผู้ที่ทำรายงาน', totalPrice: 'ยอดรวมสุทธิ(บาท)', receipt: 'ใบเสร็จ/กำกับภาษี', branch: 'สาขาที่ออกใบเสนอราคา', @@ -581,6 +588,22 @@ export default { newCustomer: 'ลูกค้าใหม่', employeeList: 'รายชื่อแรงงาน', employee: 'แรงงาน', + workName: 'ชื่องาน', + contactName: 'ชื่อผู้ติดต่อ', + documentReceivePoint: 'จุดรับเอกสาร', + dueDate: 'วันครบกำหนดใบเสนอราคา', + + paymentCondition: 'เงื่อนไขการชำระเงิน', + payType: 'วิธีการชำระเงิน', + bank: 'เลือกบัญชีชำระเงิน', + paySplitCount: 'จำนวนงวด', + payTotal: 'ยอดชำระ {msg}', + + summary: 'สรุปยอดทั้งหมด', + periodNo: 'งวดที่', + amount: 'จำนวนเงิน', + payDueDate: 'วันที่กำหนดจ่าย', + callDueDate: 'วันที่ครบกำหนดเรียก', type: { all: 'ทั้งหมด', fullAmountCash: 'เงินสดเต็มจำนวน', @@ -672,6 +695,7 @@ export default { validateError: 'เกิดข้อผิดพลาดจากการตรวจสอบ', codeMisMatch: 'รหัสไม่ตรงกัน', userExists: 'ชื่อผู้ใช้นี้มีอยู่ในระบบอยู่แล้ว', + crossCompanyNotPermit: 'ไม่สามารถดำเนินการระหว่างสำนักงานใหญ่อื่นได้', }, }, }; diff --git a/src/pages/05_quotation/constants.ts b/src/pages/05_quotation/constants.ts index 61634565..9e248f20 100644 --- a/src/pages/05_quotation/constants.ts +++ b/src/pages/05_quotation/constants.ts @@ -18,3 +18,13 @@ export const productTreeDecoration = [ fg: 'var(--teal-10)', }, ]; + +export const pageTabs = [ + 'all', + 'fullAmountCash', + 'installmentsCash', + 'fullAmountBill', + 'installmentsBill', +]; + +export const fieldSelectedOption = [{ label: 'general.type', value: 'value' }];