สมอง SML

คลังความรู้ / คำศัพท์ไทย ↔ โค้ด

#glossary#tax#branch#master

เลขผู้เสียภาษี และสาขา

ในระบบนี้คืออะไร

คำว่า "สาขา" ในระบบใช้ใน สองความหมาย

  1. สถานประกอบการตามภาษี ระบุว่าเป็นสำนักงานใหญ่หรือสาขาที่เท่าไร ใช้พิมพ์ในใบกำกับและรายงานภาษี เก็บใน branch_type และ branch_code ของคู่ค้า บริษัท และแถว VAT
  2. สาขาภายในบริษัท (erp_branch_list, จอ "กำหนดรายละเอียดสาขา" smlMenu.json:70, icMasterSchemas.ts:459) ใช้แยกข้อมูลเอกสาร เก็บใน ic_trans.branch_code (trans.go:111)

คอลัมน์

ป้ายบนจอ ลูกหนี้ ar_customer เจ้าหนี้ บริษัท erp_company_profile แถว VAT/WHT
เลขประจำตัวผู้เสียภาษี tax_id (arCustomer.ts:174) tax_id (apSupplierDetail.ts:155) tax_number "เลขที่ผู้เสียภาษี" (companyProfile.ts:83) VAT: tax_no, WHT: tax_number
เลขที่บัตรประชาชน card_id (:180) card_id (:161) — WHT: card_number
สถานประกอบการ branch_type 0 สำนักงานใหญ่ / 1 สาขา (:186) branch_type (:167) branch_type (:90) branch_type (journaltax.go:42)
เลขที่สาขา branch_code (:191) branch_code (:176) branch_code "สาขาลำดับที่" (:99) branch_code
  • บริษัทมีสวิตช์ "ใช้ระบบสาขา" branch_status (companyProfile.ts:105)
  • แท็บภาษีบนจอมีตัวเลือก BRANCH_TYPES = สำนักงานใหญ่ / สาขา (JournalTaxTabs.tsx:226)
  • ชื่อ ที่อยู่ และเลขภาษีในแถว WHT ดึงจาก master ผู้ใช้แก้ไม่ได้ (journaltax.go:53-54)

ข้อควรระวัง

  • ชื่อคอลัมน์เลขภาษีไม่เหมือนกันในแต่ละตาราง (tax_id, tax_no, tax_number) ควรค้นทั้งสามชื่อ
  • branch_code ของคู่ค้า (เลขสาขาตามภาษี) กับ ic_trans.branch_code (สาขาภายใน) เป็นคนละความหมาย แม้ชื่อคอลัมน์จะเหมือนกัน

ลิงก์

ลูกหนี้/ลูกค้า และเจ้าหนี้/ผู้จำหน่าย (party / cust_code / ar_customer / ap_supplier) · ประเภทภาษี แยกนอก/รวมใน และภาษีซื้อ-ขาย (VAT type / vat_type / gl_journal_vat_buy / gl_journal_vat_sale) · ภาษีหัก ณ ที่จ่าย / ภาษีถูกหัก (withholding tax / gl_wht_list) · erp_branch_list — ทะเบียนสาขา · erp_company_profile — ข้อมูลบริษัท (แถวเดียว) · glossary-overview

ที่มาในโค้ด

  • frontend/src/config/schemas/arCustomer.ts:174-191
  • frontend/src/config/schemas/apSupplierDetail.ts:155, :161, :167, :176
  • frontend/src/config/schemas/companyProfile.ts:83, :90, :99, :105
  • frontend/account/transaction/JournalTaxTabs.tsx:226
  • backend/internal/application/process/journaltax.go:42, :53-54, :247-248
  • backend/internal/application/process/trans.go:111
  • frontend/src/config/smlMenu.json:70; frontend/src/config/schemas/icMasterSchemas.ts:459