by Scott.Pearce » Thu Aug 08, 2019 4:44 pm
It appears that you are "hi-jacking" the Serial Nos. cell at the UI level. The Serial Nos. cell is a read-only cell, so if you programmatically push values into it the underlying business logic will not be affected (and therefore will not save away the value you pushed in there). Further, you should not be using the UI for operations, but rather you should be manipulating the underlying business logic. Think of the UI layer (buttons, text fields, grids, etc.) as just a dumb layer that simply displays the information that is contained in the business logic layer.
The Serial Nos. cell shows which serial numbers have been taken from stock for those part lines. Here is an example of what happens using the Jiwa demonstration data:
1. Use Jiwa Demonstration data from 7.2.0.0
2. Go to Service Manager Job No. 0000000002
3. Add part 'SN1140409'. This is an inventory item which has been marked as "serialised", meaning each individual piece of stock-on-hand has a unique serial no.
4. A dialog appears asking for you to choose which serial numbers to grab from stock. Lets get 1 of serial number 343453 and 1 of 54157.
5. You will see that the part line is now in the grid, with a Qty of 2. This line is actually made up of 2 "detail" lines - one for each serial number. By clicking on the lookup button next to the Serial Nos. cell, we can see these "detail" lines (the lines with 0 quantity selected are not attached to the part line though). The Serial Nos. cell itself just displays a comma separated list of the "detail" line serial numbers.
So that's a primer on how serial numbers work with the parts grid in Service Manager.
Now, it sounds like you don't actually want to do anything with serial numbers as such, but in fact want to store some other piece of data against each part line. For this, a Service Manager Part Line custom field would be appropriate. I have attached a plugin that demonstrates use of a Service Manager Part Line custom field that gets populated whenever a part line is added.
- Attachments
-
- Plugin SM Part Custom Field.xml
- (33.52 KiB) Downloaded 104 times
Scott Pearce
Senior Analyst/Programmer
Jiwa Financials