Friday, December 8, 2023

Automating REST Authorization Calls

REST services provided by 3PL partners generally require a two-step process to use their service.  First a call must be made with secret credentials to obtain an authorization token.  Then the auth token is submitted with subsequent requests.

In Manage 2000 REST.SERVICES we can create one REST.SERVICES record to obtain the auth token and then reference it in another REST.SERVICES record:



GetAuthToken accepts JPATH expression parameters to identify the token and the expiration span. It then caches the token for the expiration span and uses the cached version until it expires before going back to the REST service to get a fresh token.

Services like the FEDEX Rates service accept a great many parameters.  These can be specified in the REST.SERVICES record:

A SCREEN.BUILD screen built with matching X_DATA_1 names makes it easy to map the inputs into the RS.COM area for calling the 3PL REST API for information.


The program needs to:

  • Call SUB.MT500 to run the screen
  • Overlay the variables from the screen to the REST common
  • Call REST.SERVICE
  • Parse the result with JPATH
  • Present the results to user, perhaps in the PWS Viewer using SUB.TEXT.OUTPUT.
And the result is a Manage 2000 look and feel function that gets live information from the 3PL REST service:




Tuesday, October 31, 2023

Virtual NUGM 2023 Tailoring Manage 2000 Web Portals

 NovoRoi Systems is in the middle of a month of virtual NUGM with sessions each Tuesday and Thursday from 2:00 to 3:00 pm central time.  This week is a bi-week so everyone can attend to Month End and finish their Halloween costumes.

I've done my two sessions with my co-host Linda McHenry.  The first on October 10 was on major development topics in recent service packs to Manage 2000 release 8.1.  The second on October 24 was on tailoring Manage 2000 Web Portals.

Here are a few slides about adding custom web functions to web portals menus:

Portal Menus Are Just Menus


Portal Menu Roots Are In DEFINE.PORTAL.LINKS


LJM.CM.INQS Is Now Part of CustomerPortal



The Secret to Passing the Portal Key


Adding news articles to web portal news panels:

Create a Feed in NEWS.FEEDS and Attach Articles

Create Your Own Articles in NEWS.ARTICLES

Attach the Feed to the Portal in DEFINE.PORTAL.VIEW

LOOK.AR Now Displays Feed 000018


And enabling MSO access in web functions:

Enabling MSOs Globally in Web Functions

LOOK.AR Now Has an Attachment Icon Menu

Quick Display Example

Navigation Shortcuts under ‘Web Functions’




Tuesday, August 1, 2023

Extending the browser based capabilities of Manage 2000

Manage 2000 8.1 contains 317 browser based functions compared to about 2200 PWS based functions.

A few of the browser based functions are abstract in that they can emulate a class of PWS based functions:

  • ReportBuildRpt, for instance, accepts a module and report name and then emulates that specific REPORT.BUILD report.  
  • BatchProcess accepts a PWS function name and then emulates MT420, presenting the screen as a web page and submitting the request to DJS or MASTER.AGENT.

Over half of PWS functions are MT420 functions such as, MRP.CALC.PN or SHOP.LOAD.SUM.WK or SALES.BY.ITEM. These types of batch functions can easily be published as web functions by creating the appropriate FN.BUILD record.

Given a PWS function name, BatchProcess will use the PWS SCREEN.BUILD definition referenced in the paragraph to generate a web page to gather user input. After prompting the user for input BatchProcess will submit the completed MT420 request to DJS or MASTER.AGENT.

By creating a record in FN.BUILD you are creating a web type pseudo-function, pre-configuring BatchProcess to run a specific MT420 function.  You just need to create a web type function pointing to /MT/BatchProcess/BatchProcess.aspx passing in a parameter named FunctionName with a value like SHOP.LOAD.SUM.WK, and directing it to always run in a batch queue like a Master Agent AdHoc queue.







BatchProcess will not support any possible MT420 request. In particular there is no provision for handling screen output like EOT Viewer inquiries. However, by sending the output to the spooler with an LPTR request, it will be available to the browser user in the MyPrintJobs web page.



Once the FN.BUILD record is created your web function can be added to any menu through MENU.BUILD.  You can add it to PWS menus, or just as easily to the web portal menu system.

Friday, May 19, 2023

Manage 2000 Release 8.1 Service Pack 6 Now Available

 Just in case you missed the official announcement...again!:

 "We are pleased to announce that Release 8.1 Service Pack 6 was released today, April 17th, 2023 and is now available for upgrades."

And yes, we already have 4 or 5 requests in for it.  So the glacier of Manage 2000 client releases continues to press forward.

We have had folks using the knowledgebase for a couple of years and while it is hard to imagine new classic Manage 2000 topics to add to the thousands of KB articles already created, it is pretty obvious that new features in recent service packs deserve some knowledge creation.  So, I am trying to remember the lessons of my technical writing course some years back...something about hushing the passive voice.

There is a school of thought that documentation should be done first and that development should drive off of the documentation.  What I experience is that knowledge creation drives bug fixes. 

When a developer is tasked with knowledge creation and actually has to find simple examples to put into how-tos, things that can go wrong generally do.  But that is why the patch system exists, to make Manage 2000 more resilient.

The other great excitement of the moment for me is a client doing beta testing on the web based ProductConfigurator. The ProductConfigurator was introduced in release 7.2.  The backend has been used by several clients to process custom front end request, but the standard user interface has never undergone a serious full beta test cycle with feedback to and correction by the development staff.

Driving a web experience off the same SCREEN.BUILD metadata that defines the user interface for PWS CTO.ENTRY is an ambitious undertaking.  The payoff for CTO technical folks is HUGE!  Their experience, skills, and techniques configuring models with CCVs applies equally to CTO.ENTRY and ProductConfigurator.

Lane and I have been experimenting with adding accumulator CCV types that can render running totals off of QPA.TABLE.CALC results. This supports running pricing displays as users configure an end item.

I feel we are finishing things started long ago.  And that is a good feeling.

Friday, February 24, 2023

Manage 2000 release 8.1 Service Pack 6 - sneak peek

The development cut is scheduled for Friday March 3rd.  Release Control processing will follow through the remainder of March.  And so expect GA sometime around the traditional April 15 timeframe.

Service pack 6 includes a number of important application features, more LINUX, and more Tools features.

AP.1099.AUDIT.ADDR

- a new function for 1099 year-end processing.

Retail Delivery Fee

- a new Sales Order feature to provide support for complying with new state RDF regulations.

Surcharge

- a new percent-based base extra charge code feature used in order and quote entry when an additional surcharge is needed. 

CountEntry

- a web version of cycle count COUNT.ENTRY. This is a major rewrite of the CountEntry web function first released with service pack 5.

ApproveCredit

- a web version of the CREDIT function.

Grand Totals Added to 30 Web Functions

CustArItems, CustOpenSalesOrders, VendorOpenInvoices, and many others now display grand totals for quick access to the customer's or vendor's overall position.

Fax Option on Red Hat Enterprise Linux

Conditional Support for running Manage 2000 on RHE Linux was announced with Manage 2000 release 8.1 service pack 5. However VSI-Fax features in Manage 2000 are NOT supported in that environment.

With service pack 6 the Manage 2000, faxing features like FXJ and QUICK.FAX are supported on RHE Linux via a Windows Server 2019 proxy.

Web Pseudo Functions

Wrapping web functions like LOOK.AR and LOOK.SO now accept type ahead parameters, so expressions like ‘LOOK.AR 1024’ can be used in the place of ‘CustomerPortal 1024’.

MyPrintJobs 

Now displays most recent print jobs first, and offers an option to delete the print job.

User Prompt Stack

Extended on primary key and validated prompts using the Most Recently Used list from the USER_CONTEXT file. This provides up-arrow-key access to recently used keys on many PWS screen prompts which matches the web function behavior.

REPORT.BUILD

Grand totals are now supported in the web interpreter page for REPORT.BUILD reports and in the roiHyperQueryControl, making them available on many user created web inquiries.

REST Provider API

Manage 2000 now provides 50 REST services covering:
  • Authentication and Authorization
  • Application Server Storage
  • Primary Key Selection
  • Data Validation and Formatting
  • Data Retrieval
  • Shopping Cart Operations
Manage 2000 REST Services have been tested and documented through Postman. Use the Manage 2000 function M2K.REST.SERVICES to access the API documentation and test cases in Postman.