Version 8.6 CP02P1 Changes

Version 8.6 CP02P1 Changes

Release Date: 6/14/23
Version: 8.6 and Above

Overview

Elliott generally follows a single-source strategy between versions 8.5 and 8.6, with source files maintained under G:\NSI.SRC\85. However, CP02P1.CBL is an exception.

During the Elliott 8.6 development, the legacy hard-coded pick ticket program (CP02P1.CBL) was refactored to share common logic with the new user-definable pick ticket program (CPPICPRT.CBL). Because this refactoring significantly changed the source structure, we chose not to apply it to the Elliott 8.5 version to avoid introducing risk for existing customers.

As a result:

  • G:\NSI.SRC\85\CP02P1.CBL is the original 8.5 implementation.

  • G:\NSI.SRC\86\CP02P1.CBL is the refactored 8.6 implementation that uses shared copybooks.

  • If a customer upgrading to Elliott 8.6 encounters issues with legacy pick ticket printing, they should temporarily use the Elliott 8.5 version while a fix is developed.

Program Structure

Legacy Pick Ticket

  • 8.5: CP02P1.CBL contains all processing logic.

  • 8.6: CP02P1.CBL and CPPICPRT.CBL shared common copybook CP02P1.PL.

User-Definable Pick Ticket

CPPICPRT.CBL handles user-definable pick tickets. Most of its logic resides in three copybooks:

  • CPPICPRT.WS

  • CPPICPRT.PL (form-printing logic)

  • CP02P1.PL (shared pick ticket processing)

CPPICPRT.CBL resides in G:\NSI.SRC\85, but it is only used by Elliott 8.6. Compiling it produces CPPICPRT.INT for both the 8.5 and 8.6 folders. Elliott 8.5 does not support the Expanded Laser Pick Ticket.

Maintenance Guidelines

Because CP02P1.PL is shared by both the legacy and user-definable pick ticket programs in Elliott 8.6, most future functional changes in Elliott 8.6 (excluding printing layout changes) should be made in CP02P1.PL.

It is unfortunately that when modifying CP02P1.CBL in the 8.5 source tree, you also need to review whether corresponding updates are also required for:

  • CPPICPRT.WS

  • CPPICPRT.PL

  • CP02P1.PL

  • G:\NSI.SRC\86\CP02P1.CBL

In many cases, only CP02P1.PL requires changes.

When making changes to shared pick ticket logic:

  1. Modify CP02P1.PL in G:\NSI.SRC\85.

  2. Apply any equivalent logic changes required by the standalone 8.5 CP02P1.CBL.

  3. Recompile CP02P1.CBL using PC.BAT. Ignore the warning about the existing 8.6 copy; the compile updates both 8.5 and 8.6.

  4. Recompile CPPICPRT.CBL using PC.BAT. Although its source resides in the 8.5 folder, it is only used by Elliott 8.6, and the compile updates both versions.

This version removes the repeated explanations about why the source trees differ, groups related information together, and focuses on the practical implications for developers maintaining the codebase.

Detail

Expanded laser picking ticket form support has been added for version 8.6. See https://support.netcellent.com/portal/en/kb/articles/feature-expanded-laser-picking-ticket for more information on this change.  The expanded laser form printing (CPPICPRT.CBL) is similar to CPINVPRT (invoice form printing). In Elliott 8.6, user can now define their own pick ticket layout instead of the original hard coded pick ticket (CP02P1.CBL).


To safeguard users who are running 8.5 and have not upgraded to version 8.6, the source code for CP02P1.CBL is different for versions 8.5 and 8.6.  Also, the new expanded laser picking ticket program, CPPICPRT.CBL, is only called under version 8.6 if Global Setup is configured to do so.

CS2305       IF ELLIOTT-VERSION > "8.5"
CS2305         IF WS-N38-PRINT-PICKTICK-FORM = "Y" AND
CS2305             WS-N38-PICKTICK-FORM NOT = ZERO
CS2305             MOVE "CPPICPRT" TO TASK-NAME
CS2305         ELSE
CS2306             MOVE "CP02P1" TO TASK-NAME
CS2305         END-IF
CS2305       ELSE
CC0401         MOVE "CP02P1" TO TASK-NAME
CS2305       END-IF


Version 8.5 called the original version of the program. To support printing on forms in version 8.6, the primary processing logic was commented out in the 8.6 version of CP02P1.CBL and was added to the copybook CP02P1.PL. A COPY statement for CP02P1.PL was added to the 8.6 version of CP02P1.CBL. See the diff below:



The new CP02P1.PL with the logic from CP02P1.CBL:



CPPICPRT.CBL, a new program with form logic, has been created for version 8.6. It shares the processing logic in CP02P1.PL. It also has a new copybook CPPICPRT.PL that contains all of the form logic.

Program

Version 8.5

Version 8.6

CP02P1.CBL

Contains original logic. Resides in 8.5 source code directory.

Resides in 8.6 source code directory. Processing logic commented out and moved to CP02P1.PL. Contains COPY statement for CP02P1.PL. Called if Global Setup flag = ā€œNā€ or blank or if form number not set up.

CP02P1.PL

Not used in 8.5 version of CP02P1.CBL but resides in the 8.5 source directory. 

Resides in the 8.5 source code directory. Contains processing logic to print picking ticket. Used when compiling CP02P1.CBL in 8.6 source directory and compiling CPPICPRT.CBL in 8.5 source directory.

CPPICPRT.CBL

Not used in version 8.5 but resides in 8.5 source directory.

Source resides in the 8.5 directory. Base program similar to CPINVPRT.CBL that contains mostly copybooks. Use both new CP02P1.PL and CPPICPRT.PL. Called if Global Setup flag = ā€œYā€ and a form number has been provided. 

CPPICPRT.PL

Not used in version 8.5 but resides in 8.5 source directory.

Source resides in the 8.5 directory. Contains printing logic for the laser form. Used by CPPICPRT.CBL.


When making changes to the picking ticket program you need to do the following:

Change the 8.5 Version of CP02P1.CBL

You can run a three-way Araxis merge between the G:\nsi.src\85\CP02P1.CBL, your working copy of CP02P1.CBL and your working copy of CP02P1.PL to determine the changes that were made. Apply the processing changes to CP02P1.PL.

For example, if the following lines in bold were changed in CP02P1.CBL:

CC1005   IF WS-NS3-CUST-CODE-CHK IS = "Y"
CC1005       IF ORDER-CUSTOMER-NO IS = WS-NS3-CUST-CODE-CREDIT(1) OR
CC1005         ORDER-CUSTOMER-NO IS = WS-NS3-CUST-CODE-CREDIT(2) OR
CC1005         ORDER-CUSTOMER-NO IS = WS-NS3-CUST-CODE-CREDIT(3) OR
CC1005         ORDER-CUSTOMER-NO IS = WS-NS3-CUST-CODE-CREDIT(4) OR
CC1005         ORDER-CUSTOMER-NO IS = WS-NS3-CUST-CODE-CREDIT(5)
CS2106         OR
CS2303         ((ORDER-BILL-TO-NO IS = WS-NS3-CUST-CODE-CREDIT(1) OR
CS2106         ORDER-BILL-TO-NO IS = WS-NS3-CUST-CODE-CREDIT(2) OR
CS2106         ORDER-BILL-TO-NO IS = WS-NS3-CUST-CODE-CREDIT(3) OR
CS2106         ORDER-BILL-TO-NO IS = WS-NS3-CUST-CODE-CREDIT(4) OR
CS2303         ORDER-BILL-TO-NO IS = WS-NS3-CUST-CODE-CREDIT(5)) AND
CS2303         ORDER-BILL-TO-NO NOT = SPACES)
CC1005         MOVE "Y" TO EXEMPT-CREDIT-FLAG
CC1005       END-IF
CC1005   END-IF.

A three-way merge between G:\nsi.src\85\CP02P1.CBL, your working copy of CP02P1.CBL and your working copy of CP02P1.PL would show that the change to CP02P1.CBL should be applied to CP02P1.PL:



If making changes to the printing logic, check to see if the changes are applicable to  CPPICPRT.PL.
Change the 8.6 version of CP02P1.CBL with any printing logic changes applied to the 8.5 version of CP02P1.CBL.

Changes to CPPICPRT.PL or CP02P1.PL will need to be tested under version 8.6 using both the standard (CP02P1.CBL) and the laser forms (CPPICPRT.CBL). See https://support.netcellent.com/portal/en/kb/articles/debugging-cobol-code-in-elliott-8-6  for more information on how to set up your 8.6 testing environment.

8.5 Changes/Testing

Copy CP02P1.CBL from G:\nsi.src\85 to your 8.5 working directory (such as F:\nsi.pjt\85\cls).
Make the changes.
Compile code for debugging.
Add code to RU850C.LBR, RU850V.LBR, or RU850E.LBR.
Test the code.
Apply any applicable changes to CP02P1.PL and CPPICPRT.PL.

8.6 Changes/Testing

Copy CP02P1.CBL from G:\nsi.src\86 to your 8.5 working directory (such as F:\nsi.pjt\86\cls).
Copy any changed copybooks from your 8.5 working directory (F:\nsi.pjt\85\cls) to your 8.6 working directory (F:\nsi.pjt\86\cls).
If you changed CP02P1.PL or CPPICPRT.PL, copy CPPICPRT.CBL from G:\nsi.src\85.
Make any changes.
Compile code for debugging including CPPICPRT.CBL if you changed CP02P1.PL or CPPICPRT.PL .
Add code to RU860C.LBR, RU860V.LBR, or RU860E.LBR.
Test the standard picking ticket and the picking ticket form.

Push Code

Copy programs and copybooks from 8.5 test directory to G:\nsi.src\85
Copy CP02P1.CBL from 8.6 test directory to G:\nsi.src\86 (only source code that originated in G:\nsi.src\86 should be copied)
Compile the changed programs from G:\nsi.src\85
Build the RU850U.LBR from G:\nsi.src\85. Run PUSHLBR.
Build the RU860U.LBR from G:\nsi.src\86. Run PUSHLBR.

    CLS