airs-123_po_reason_code_for_buyer_by_supplier_modify_-_split_part
Table of Contents
AIRS-123 PO Reason Code for buyer by supplier modify - Split part
https://tasks.supplyon.de/browse/AIRS-123
Special case SPLIT (UI):
* Only if reason for modify is required by customer (flag on LE level is set), the split popup will contain a new field which has to be filled by the supplier by selecting the reason code from a dropdown list.
* This use case is independent from PO SL status – if conditions above are fulfilled, then every split action will require a reason code.
* Field is mandatory: if reason code is missing, split action can't be finished
* With split action, the selected reason code will be stored on both schedule lines (changed original line and new line). If on original line there already has been a reason code, it will be overwritten.
TODO
- - Extend “Split” dialog
- + Show “Reason Code” select box
- + Use nls key instead of a constant
- + Show “Reason Code” select box conditionally (only if flag “Reason Code Required” is set)
- + Fetch right selection
- + Adjust CSS (right width, paddings etc.)
- + Save the “Reason Code” and “Reason Code Description” into the splitted orders
- extend JSON with Reason Code (and Reason Code Description?)
poSplitWindow.js:551→checkAndMakeDataRecord()?
POOverviewActionScreen.doSplitSave()
- - Fetch flag “Reason Code Required” from customer organization
- - “Reason Code Required” is true
- - Show a field “Reason Code” in the split popup
- - Tests
- - Test PO with Reason Code Required flag set
- - Test with filled Reason Codes
- - Test without filled Reason Codes → Prevent splitting if the field is shown and not filled
- - Test PO without Reason Code Required flag set
- - Write JUnit tests
- - “Reason Code Required” is true, “Reason Code” is set to a valid value ⇒ split successful
- - “Reason Code Required” is true, “Reason Code” is set to an invalid value ⇒ split fails
- - “Reason Code Required” is true, “Reason Code” is set to an empty value ⇒ split fails
- - “Reason Code Required” is false ⇒ split successful
Code
Java
POManagerEJB.doSplitSave()POSplitUpdate- data container
JavaScript
js/cfg/po/podetailsCfg.js.jspsas.po.ov.copyAction()
js/cfg/po/pooverview.jsopenSplitDialog()sas.po.ov.checkActionServerSide()
js/cfg/po/podetails.jsjs/cfg/po/poSplitWindow.js- POSplitWindow classopen()- initialize and open dialog window
- NLS keys:
suiTranslations.js.jsp
Crib from Udo:
SASPropertyChooser.js- dialog to select reason code
How it works
- Button is defined in
pooverviewCfg.js.jsppodetailsCfg.js.jsp- NOT(!) in
polinedetailsCfg.js.jsp
- Button calls
sas.po.ov.copyAction()frompooverview.js copyAction()callssas.po.ov.doSplitPreCheck()doSplitPreCheck()calls the correspondent functionality on the server side, and if successfull, the call back will be called.- this callback calls
sas.po.ov.openSplitDialog() openSplitDialog()callsopen()method of an instance ofPOSplitWindowwhich is declared in the filepoSplitWindow.js- the
open()method creates a dialog with a form in it- this form should contain new field
Reason Code(if “Reason Code Required” for customer organization is set)
Notes
- Nur Lieferant kann splitten
- Um splitten zu können, muss bei der PO das Flag SplitAllowed gesetzt sein.
- Nach dem Splitten muss der Customer den Split bestätigen oder “ablehnen” (Penalise Split).
airs-123_po_reason_code_for_buyer_by_supplier_modify_-_split_part.txt · Last modified: by 127.0.0.1
