Task #19826
openPrepopulate Sales Charges in File Reference (HBL Level)
100%
Description
Enable automatic population of Sales Charges in File Reference (House BL level) using Charges Template.
Functional Requirements¶
-
Upon selecting the Shipment Reference from the File Reference screen:When user adds House BL information, the Sales Charges section should be prepopulated using the Sales Amount from the Charges Template.The matching criteria should be the same as the Shipment Cost template logic.
-
User must still be able to:Update prepopulated sales chargesDelete sales chargesAdd additional sales charges manually
Acceptance Criteria¶
Sales Charges are auto-populated correctlyMatching logic works same as Shipment CostOnly Sales Amount is usedPrepopulated values are editableUser can delete any chargeUser can add additional chargesNo restriction from template logic
Scenario 1 – File Reference Pulls Sales Charges¶
Given~~ File Reference is linked to a Shipment Reference
When user adds House BL information
Then Sales Charges are prepopulated using Sales Amount from the template.~~
Scenario 2 – Sales Charges Remain Editable¶
Given~~ sales charges are prepopulated
When user updates, deletes, or adds charges
Then system allows the changes successfully.~~
Technical Notes¶
Reuse existing template matching logicFetchSalesAmountinstead ofCostAmount
The existing requirement was to automatically populate Sales Charges in the File Reference / House BL level using the Charges Template when the Shipment Reference is selected.
After discussion with the development team, the approach has been revised.
Instead of auto-populating the Sales Charges immediately, the system will provide a new button above the Sales Charges grid. The user can click this button to fetch sales charges from the Charges Template when required.
Requirement¶
Add a new button above the Sales Charges grid:
Refresh Charges from Template
When the user clicks this button, the system should fetch matching sales charges from the Charges Template and populate them in the Sales Charges grid.
Functional Requirements¶
1. Add New Button¶
Add a new button above the Sales Charges grid:
Refresh Charges from Template
Suggested placement:
- Above the Sales Charges grid
- Button should be clearly visible to the user
2. Fetch Sales Charges from Charges Template¶
When the user clicks Refresh Charges from Template, the system should retrieve charges from the Charges Template based on the same matching criteria used in Shipment Cost.
Matching criteria should include, where applicable:
- Cargo Type
- Shipping Line
- Container Type
- Type of Shipment
- Effective Date Range
- Status = Active
When user clicks Refresh Charges from Template:
- System fetches matching Sales Charges from the Charges Template.
- System appends the fetched charges to the existing Sales Charges grid.
- Existing charges remain unchanged.
- Duplicate charges are allowed.
- User can manually delete unwanted charges.
3. Use Sales Amount Only¶
The system must fetch only the Sales Amount from the Charges Template.
The Cost Amount must not be used in the Sales Charges grid.
4. Populate Sales Charges Grid¶
After fetching the matching template charges, the system should populate the Sales Charges grid with the retrieved sales charges.
The following details should be populated where available:
- Charge Code
- Charge Description
- Freight Type
- Currency
- Sales Amount
- VAT Type
- VAT Amount
- Total
- Unit of Measure
- Any other standard fields already used in the Sales Charges grid
5. User Control After Fetching¶
After the charges are fetched and displayed, the user must still be able to:
- Update prepopulated sales charges
- Delete prepopulated sales charges
- Add additional sales charges manually
There should be no restriction preventing the user from changing the fetched values.
6. Duplicate Handling / Append Behaviour
As discussed with the development team, the system will continue to auto-populate the Sales Charges grid with the same charges retrieved for Shipment Cost, based on the existing shipment cost template logic.
In addition, when the user clicks Refresh Charges from Template, the system will append the matching Sales Charges from the Charges Template to the existing Sales Charges grid.
If the same charge already exists in the Sales Charges grid:
- The system should still append the charge again.
- The system should not block duplicate charges.
- The system should not overwrite existing charges.
- The user will manually delete any charge lines that are not required.
This approach gives the user full control over the final Sales Charges list.
Acceptance Criteria¶
1 – Button Display¶
Given user is in the File Reference / House BL Sales Charges section
Then the system displays a button named Refresh Charges from Template above the Sales Charges grid.
2 – Fetch Matching Template Charges¶
Given a valid Shipment Reference / File Reference exists
And matching active Charges Template records exist
When user clicks Refresh Charges from Template
Then the system retrieves matching sales charges based on the same criteria as Shipment Cost.
3 – Sales Amount Only¶
Given Charges Template contains both Cost Amount and Sales Amount
When sales charges are fetched
Then only the Sales Amount is used to populate the Sales Charges grid.
4 – Cost Amount Not Used¶
Given a template charge has only Cost Amount and no Sales Amount
When user clicks Refresh Charges from Template
Then that charge should not be inserted into the Sales Charges grid.
5 – Sales-Only Charges¶
Given a template charge has Sales Amount and no Cost Amount
When user clicks Refresh Charges from Template
Then the charge should be inserted into the Sales Charges grid.
6 – Editable Sales Charges¶
Given charges are fetched from the template
When user edits a fetched charge
Then the system allows the update.
7 – Delete Sales Charges¶
Given charges are fetched from the template
When user deletes a fetched charge
Then the system allows the deletion.
8 – Add Manual Charges¶
Given charges are fetched from the template
When user adds an additional sales charge manually
Then the system allows the new charge to be added.
9 – Append Charges Even If Same Charge Exists¶
Given the Sales Charges grid already contains one or more charges
When user clicks Refresh Charges from Template
Then the system appends the matching charges from the Charges Template to the existing list.
10 – Duplicate Charges Allowed¶
Given a charge already exists in the Sales Charges grid
When the same charge is fetched again from the Charges Template
Then the system should still add the charge as a new line.
11 – Existing Charges Not Overwritten¶
Given the Sales Charges grid contains existing charges
When user clicks Refresh Charges from Template
Then the existing charges should remain unchanged.
12 – User Can Manually Remove Unwanted Charges¶
Given duplicate or unwanted charges exist in the Sales Charges grid
When user deletes selected charge lines manually
Then the system removes only the selected charge lines.
Validation / Warning Messages¶
No Matching Template Found¶
If no matching template charges are found, display:
“No matching sales charges found in Charges Template.”
Refresh Confirmation¶
Before refreshing charges, display:
“This action will fetch sales charges from the Charges Template. Do you want to continue?”
Duplicate Handling Message¶
If matching charges already exist, display either:
“Some charges already exist and will be duplicated. Do you want to continue?”
GitLab Sync Log
[{"id": "43685", "author": "Ra-ees Peeroo", "hours": 40.0, "created": "2026-05-06T07:47:37.044Z", "log_date": "2026-05-06", "comment": "Imported from GitLab by @Ra-ees Peeroo on 2026-05-06T07:47:37.044Z: 40h-(40.0)h spend at: 2026-05-06", "status": "deleted", "deleted_by": "", "redmine_entry_id": 13427}, {"id": "44202", "author": "Ra-ees Peeroo", "hours": 6.0, "created": "2026-05-12T11:03:30.202Z", "log_date": "2026-05-11", "comment": "Imported from GitLab by @Ra-ees Peeroo on 2026-05-12T11:03:30.202Z: 6h-(6.0)h spend at: 2026-05-11", "status": "active", "deleted_by": "", "redmine_entry_id": 13552}, {"id": "44201", "author": "Ra-ees Peeroo", "hours": 3.0, "created": "2026-05-12T11:03:12.391Z", "log_date": "2026-05-10", "comment": "Imported from GitLab by @Ra-ees Peeroo on 2026-05-12T11:03:12.391Z: 3h-(3.0)h spend at: 2026-05-10", "status": "active", "deleted_by": "", "redmine_entry_id": 13553}, {"id": "44885", "author": "Ra-ees Peeroo", "hours": 4.0, "created": "2026-05-22T06:06:45.019Z", "log_date": "2026-05-20", "comment": "Imported from GitLab by @Ra-ees Peeroo on 2026-05-22T06:06:45.019Z: 4h-(4.0)h spend at: 2026-05-20", "status": "active", "deleted_by": "", "redmine_entry_id": 13705}, {"id": "44884", "author": "Ra-ees Peeroo", "hours": 4.0, "created": "2026-05-22T06:06:39.374Z", "log_date": "2026-05-18", "comment": "Imported from GitLab by @Ra-ees Peeroo on 2026-05-22T06:06:39.374Z: 4h-(4.0)h spend at: 2026-05-18", "status": "active", "deleted_by": "", "redmine_entry_id": 13706}, {"id": "44882", "author": "Ra-ees Peeroo", "hours": 7.0, "created": "2026-05-22T06:06:22.664Z", "log_date": "2026-05-18", "comment": "Imported from GitLab by @Ra-ees Peeroo on 2026-05-22T06:06:22.664Z: 7h-(7.0)h spend at: 2026-05-18", "status": "deleted", "deleted_by": "44883", "redmine_entry_id": 13707}, {"id": "44881", "author": "Ra-ees Peeroo", "hours": 7.0, "created": "2026-05-22T06:06:15.559Z", "log_date": "2026-05-17", "comment": "Imported from GitLab by @Ra-ees Peeroo on 2026-05-22T06:06:15.559Z: 7h-(7.0)h spend at: 2026-05-17", "status": "active", "deleted_by": "", "redmine_entry_id": 13708}, {"id": "44955", "author": "Ra-ees Peeroo", "hours": 6.25, "created": "2026-05-25T05:30:04.457Z", "log_date": "2026-05-21", "comment": "Imported from GitLab by @Ra-ees Peeroo on 2026-05-25T05:30:04.457Z: 6h 15m-(6.25)h spend at: 2026-05-21", "status": "active", "deleted_by": "", "redmine_entry_id": 13735}, {"id": "45120", "author": "Ra-ees Peeroo", "hours": 6.0, "created": "2026-05-27T11:41:28.391Z", "log_date": "2026-05-26", "comment": "Imported from GitLab by @Ra-ees Peeroo on 2026-05-27T11:41:28.391Z: 6h-(6.0)h spend at: 2026-05-26", "status": "active", "deleted_by": "", "redmine_entry_id": 13768}, {"id": "45118", "author": "Ra-ees Peeroo", "hours": 7.0, "created": "2026-05-27T11:41:14.482Z", "log_date": "2026-05-25", "comment": "Imported from GitLab by @Ra-ees Peeroo on 2026-05-27T11:41:14.482Z: 7h-(7.0)h spend at: 2026-05-25", "status": "active", "deleted_by": "", "redmine_entry_id": 13769}, {"id": "45117", "author": "Ra-ees Peeroo", "hours": 7.0, "created": "2026-05-27T11:41:06.146Z", "log_date": "2026-05-24", "comment": "Imported from GitLab by @Ra-ees Peeroo on 2026-05-27T11:41:06.146Z: 7h-(7.0)h spend at: 2026-05-24", "status": "active", "deleted_by": "", "redmine_entry_id": 13770}]
Updated by Redmine Admin 4 months ago
- GitLab Time Logged changed from 0 to 144000
Updated by Redmine Admin 4 months ago
- Estimated time changed from 0:00 h to 40:00 h
- GitLab Time Logged changed from 144000 to 0
Updated by Redmine Admin 4 months ago
- % Done changed from 0 to 22
- GitLab Time Logged changed from 0 to 32400
Updated by Redmine Admin 3 months ago
- % Done changed from 22 to 60
- GitLab Time Logged changed from 32400 to 86400
Updated by Redmine Admin 3 months ago
- % Done changed from 60 to 75
- GitLab Time Logged changed from 86400 to 108900
Updated by Redmine Admin 3 months ago
- Estimated time changed from 40:00 h to 50:00 h
- GitLab Time Logged changed from 108900 to 180900
- % Done changed from 75 to 100