FS 342649 GAP-142 Fix Load ID Generation
Partnerlink
Fix Load ID Generation
CALIDUS ePOD
24th April 2017 - 0.1
Reference: FS 342649 GAP-142
Contents
Functional Overview
Client Requirement
As reported by Ken Hayes:
GAP Project issue 142: Not able to transfer loads to LIVE portal
We have corrected the below issues and attempted to send a new load file, but after sending we can no longer see any loads on the portal.
Selecting Loads > Search now returns zero results.
I would be grateful if you could investigate first thing on Monday morning.
As mentioned to Murray, we are back in Paris on Monday and really need to have this issue closed as soon as possible, to enable store deliveries in the evening.
The issue is that a load with lower-case letters was imported into the database and any new loads created by the system are trying to create the Load ID by adding onto this load ID. As lower-case characters are not supported, the process is failing, which is affecting the Loads screen in C-ePOD Admin.
The data has been fixed (by creating a load with ID "ZZZZZZZZZZ", but a permanent fix is required.
Solution Overview
The current process is as follows:
The current database handles lowercase and uppercase index values as identical.
The current ID generation process doesn't handle lower-case characters, or any symbolic character not dash or underscore.
This leads to a problem when generating new IDs.
This is apparent when finding loads in the load header screen, as the process incorrectly calls the initialization of class EPOD_LOAD. If this is the case here, then this could also be present whenever IDs are generated on any class, most notably EPOD_JOB and EPOD_LOAD. We could fix the ID generation class, or we could find every instance where a DAL object is called to generate an ID, then check whether it called correctly. I choose the former.
So there are two fixes required:
- Fix the issue with the load header screen
- Fix the issue with the ID generation class.
Scope
Assumptions: Changes will be made to latest version of CALIDUS ePOD only, and will require an update to all application components and full system and user acceptance testing.
Set-up
Pre-requisites
N/A
Menu Structure
N/A
Data
N/A
Functional Description
When searching for Loads in the Admin Load screen (load_header.aspx.cs), the screen is creating a connection to the EPOD_LOAD table incorrectly - this should not be attempting to create a new EPOD_LOAD record, just create the connection. This code exists, and should be called instead.
The generic ID generation function (IncrementKeyValue) must be modified to handle lowercase characters (treating them as uppercase characters) and all symbolic characters (by checking them against the list of allowed characters). If the character being checked is not in the list of allowed characters, this will be replaced by a "0", which will then force the process (as now) to evaluate the previous character. If all characters are replaced with "0", the process will add a "0" to the returned ID string when returned - this is as now.
Detailed changes required:
EPOD_UTILS.cs:
private static char NextChar(char Char) { ... change this for the following line... //if (Char == '-' | Char == '_') if (CharList.IndexOf(Char) == -1)
public static string IncrementKeyValue(string CurrentValue, int MaxKeyLength) { ... change this for the following line... //char[] chr1 = CurrentValue.Trim().ToCharArray(); char[] chr1 = CurrentValue.Trim().ToUpper().ToCharArray();
load_header.aspx.cs:
protected void SearchBtn_Clicked(object sender, EventArgs e) { ... change this for the following line... //EPOD_LOAD EPOD_LOAD = new EPOD_LOAD(EPOD_DBCONNECTION, (string)Session["SITE"]); EPOD_LOAD EPOD_LOAD = new EPOD_LOAD(EPOD_DBCONNECTION);
Appendix A: TEST PLAN
Test Script / Scenario Reference | Fix Load ID Generation | Call Number(s): 342649 GAP-142 |
Test Script / Scenario Description | Testing New Load ID generation. | PASS / ISSUES / FAIL |
Menu Access | N/A | |
Pre-requisites | A system configured as Partnerlink GAP Test. | Tested By: |
Test Objective | To test: creation of Load ID is working as required. | Date: |
Step | Action | Result | Remarks | P/F |
1 | Admin System | |||
Create a load that is the last load in the system with an ID that ends "AZ-y" | ||||
1.01 | Search in the load screen. | The load screen displays data correctly. |
Step | Action | Result | Remarks | P/F |
2 | Load ID Generation. | |||
2.01 | Create a new load in the Load admin screen. | The load created should end "AZ-Z" | ||
2.02 | Create a new load in the Load admin screen. | The load created should end "B000" |
Appendix B: Quote & Document References
Cost Details | ||||
Activity | Estimate No. of Days |
No. of Days | Rate per Day (£) | Cost (£ Exc. VAT) |
Requirements | 0.00 | 0.00 | 650 | £0.00 |
Change Request Evaluation | 0.00 | 0.00 | 650 | £0.00 |
Functional Specification | 0.00 | 0.00 | 650 | £0.00 |
Technical Specification | 0.00 | 0.00 | 650 | £0.00 |
Development | 0.00 | 0.00 | 650 | £0.00 |
Testing and Release | 0.00 | 0.00 | 650 | £0.00 |
Implementation | 0.00 | 0.00 | 650 | £0.00 |
Project Management | 0.00 | 0.00 | 650 | £0.00 |
TOTAL | 0.00 | 0.00 | £0.00 |
Estimate excludes training, release to live and go live support. |
B.1 References
Ref No | Document Title & ID | Version | Date |
1 |
B.2 Glossary
Term | Definition |
---|---|
EPOD | Electronic Proof of Delivery. The OBS EPOD system is CALIDUS ePOD. |
CALIDUS eSERV | The OBS mobile system to complete Service functionality in the field. This is part of the CALIDUS ePOD system. |
PDA | The mobile device on which the C-ePOD system will run in the field. This can be a Phone, EDA or industrial PDA, running Android. |
DAL | Data Access Layer. A mechanism for accessing data by the system that is removed from the application, allowing for simplified access and providing protection to the data, as only approved DAL methods can be used to modify it. |
GPS | Global Positioning System. A mechanism of retrieving accurate positioning information in the form of Latitude and Longitude (Lat-Long) co-ordinates from a device. |
GPRS, 3G, HSDPA, Data Service | All terms referring to mobile device network connectivity, and the speed at which the device connects to the internet. |
B.3 Authorised By
Matt Turner | OBSL Account Manager | _____________________________ |
Ken Hayes | Customer Representative | _____________________________ |