Override Workflow by Document Type


在 iDempiere 單據按完成時,會由 DocAction 所定義的 AD_Process 去觸發所對應的 AD_Workflow _ID, 啟動 Workflow 流程. 它是以 Table / Column 基礎. iDempiere 有一個特色,多種單據共用一個 資料表(Table). 像銷售訂單, 報價單, 計劃訂單, 採購單…等等都定義在C_Order 資料表.

這樣會讓Workflow 流程設計起來變得很複雜, Workflow Start 後, 要先去判斷IsSOTrx 是銷售訂單或採購單. 甚至還要判斷單據類型C_DocumentType_ID來決定它是報價單還是正式訂單.

改良 Improvement

將Start Workflow Process 時, 進行流程轉換的動作.
透過 ProcessInfo 取後單據資訊, 包括 Record_ID , AD_Table_ID. 對檢測它的 Document Type 是否有含 AD_Workflow_ID. 若有的話. 進行Override 動作.


所有的單據都有一個 Default 的 AD_Workflow_ID.

若有特殊的需求, 可以指定AD_Workflow_ID 於 您要實作的 Document Type 欄位上.

Leave a comment

Production Generate Movement




Leave a comment

iDempiere Product Management

iDempiere ERP産品管理

  1. ITEM
    Physical goods that you buy or sell: The system will set an inventory for these goods. For example, Shirts and Dress cloth.
  2. Expense Type
    Physical or non physical goods that you buy or sell: The system will not set an inventory for thest goods. For exmple, stationery expenses.
  3. Service
    No physical goods are received or sent when we buy or sell this product type: It is just a service. Fro example, consulting fees.
  4. Resource
    This is like Service, but is restricted in terms of avilability. For example, hiring a consultant who will be avilable for a limited period only.
  5. Asset
Product TypeDr 借Cr 貸
ItemAsset (Product Asset)Not Invoiced Receipt
Expense Type, Service, ResourceExpenses (Product Expenses)Not Invoice Receipt

Leave a comment