Ga naar inhoud

Form Kitting

  • Unit name: Forms.Kitting
  • Form name: KittingForm
  • Old form name: Unit89 (Form89)

Synopsis

Form to manage kit creation orders.

Functionalities

The form allows to create kits of articles. For this it displays 1. A supplier selection combobox. When supplier is selected, article combo box is cleared and focused. 2. An article editable combox box. As soon as a supplier is selected, a list of compound articles is retrieved for the supplier. 3. When supplier and article are chosen, a list of previous kit creations for the selected combination is shown in a grid. (view CGROUP in order of descending time) 4. A button allows to execute AddNewKit Action. 5. A button allows to execute DeleteKit action. 7. Below the grid with current/previous orders, the details of the selected order are displayed: 1. A grid with KitOrderDetails records. 2. A grid with KitSourceDetails records. (linked through the ID field of CGROUP)

  1. A report 'KittingStockInProduction' can be printed.
  2. A report 'KitLabels' can be printed. The current CGROUP ID is passed on as KitID and the number of copies is Qty from Cgroup, divided by 64.
  3. A button allows to execute MarkAsChecked action.
  4. A button allows to execute ModifyKitQuantity action.
  5. A button allows to execute ModifyKitArticleQuantity action.

Actions

AddNewKit.

Adds a new kit for the selected supplier/article. 1. Only active if a supplier/article is chosen. 2. When executed, a dialog pops up that asks for the following parameters: * Quantity
* Stock code (dropdown) * Location (optional, dropdown) * Comments 3. When the user clicks OK, the Kitting.CheckKitOrderPossible service call is executed: 1. If errors are reported: they are displayed to the user. 2. No errors are reported: the Kitting.CreateKitOrder call is executed. 3. When the call succeeds, the CGroup view is refreshed and the grid is placed on the newly created order.

DeleteKit

Delete the kit order.
1. Only active if a kit order is selected/active. 2. When executed, a dialog is displayed asking confirmation and whether the user wants to move the remaining components to a new location:

Move remaining parts of the kit to a new location ?
3. The user can type/select a location in this dialog. 4. When confirmed, the Kitting.DeleteKitOrder service call is executed, with the ID from the currently selected kit, and the selected moving location (if any)

MarkAsChecked

'Mark as checked' verifies current line. 1. Only active if a detail line is active and it is not checked yet. 2. Asks the user for confirmation 3. If user confirms, executes the service call Kitting.MarkAsVerified.

ModifyKitQuantity

'Modify Kit Quantity' modifies the quantity of the kit. 1. Only active when a kit is selected. 2. When executed, it asks for a new quantity using inputquery:

Enter new kit quantity:
It proposes the current quantity. 3. If the user confirms the quantity, and it is less than the current quantity of the kit, then the Kitting.ModifyKitQuantity call is executed. 4. After the call returns, the kit overview data is refreshed.

ModifyKitArticleQuantity

"Modify article Quantity' modifies the article quantity for the current article. 1. Only active when an article line is active. 2. When executed, asks for a new quantity using inputquery:

Enter new kit article ":Artcode" quantity:
3. It proposes the current quantity for the currently selected article as default. 4. If the user confirms the quantity, and it is less than the current quantity of the article, then the Kitting.ModifyKitArticleQuantity call is executed. 5. After the call returns, all detail data is refreshed.

Tables/Views

  • SUPPLIERS for the supplier combobox (global lookup)
  • KittingArticles for the article combobox (global lookup)
  • CGROUP for the list of previous orders.
  • LOCATION for a list locations (popup new kit, popup delete kit)
  • KitOrderDetails is the following view:
    Select
       A.LINKEDARTCODE as ArtCode,
       A.QTY as UnitQTY,
       sum(B.QTY) AS TQTY,
       sum(B.QTYCF) AS T_PK_QTY
    FROM
      ARTICLELINK A,
      INNER JOIN OUTDETAILS B ON
        (A.LINKEDARTCODE=B.ARTCODE)
        AND (B.AVIZNO='KG'+:ID)
    WHERE
      (A.ARTCODE=:ArtCode)
     GROUP BY
       A.LINKEDARTCODE , A.QTY
     ORDER BY
       LINKEDARTCODE ASC
    
  • KitSourceDetails is the following view:
    SELECT DISTINCT
      B.ArtCode, B.StockCode, A.Location,
      A.ExpiryDATE, A.Lotno, B.QTY, B.QTYCF as PKQTY, B.ID
    FROM
      INVDETAILS A,
      INNER JOIN OUTDETAILS B ON (A.ID=B.INVOICENO)
    WHERE
      (B.AVIZNO='KG'+:ID)
    ORDER BY B.ARTCODE, A.LOCATION ASC
    

Needed Service Calls

Kitting.CheckKitOrderPossible

To check whether an order is possible, article code, stock code and quantity must be passed. Returns an array of error conditions.

Kitting.CreateKitOrder

Create a new kit order in the database. Supplier, article code, stock code, comments optional location and quantity must be passed. Returns the ID of the newly created CGROUP record.

Kitting.DeleteKitOrder

Delete a new kit order in the database.

Kitting.ChangeKitQuantity

Delete a new kit order in the database.

Reports