PUZZLE HTML Report Plugin (14.0.0)

Download OpenAPI specification:Download

Changelog

Component Category Description Date
HTML Report Plugin 14.0.0 Dependency PUZZLE core version ${puzzle-core.version}.
Added Added parameters WebGL.ResourcesBasePath and WebGL.MonolithicMode. 2022-05-10
Breaking change HTML-File - Changed URL Query Parameter

highlightcolor renamed to currentSequenceColor.
2022-05-02
Added HTML-File - More URL Query Parameters

  • pastSequencesColor
  • viewType
  • ui

All parameters and its values are now evaluated case-insensitive.
2022-05-02
Added HTML-File - URL Query Parameters

The following parameters are planned, but not yet supported:
  • fadingcolor
  • viewtype
  • ui
2022-04-22
HTML Report Plugin 13.2.0 Dependency PUZZLE core version 48.0.0.
HTML Report Plugin 13.0.1 Dependency PUZZLE core version 47.0.0.

Description

Plugin for PUZZLE, that allows a client to create an interactive html report for the solutions of a job. The report contains a step-by-step simulation of the load of the loading devices.

A client can define the color of the loading device and the colors of the sides of the items. Please see the PUZZLE REST API Documentation for details.

Furthermore a client can provide parameters to the job to influence the way the HTML-file provided by this plugin is supplied.

Parameters

The following parameters can be added to the job in order to influence the way the HTML-file provided by this plugin is supplied.

Parameter Name Description Default Value
WebGL.MonolithicMode Toggles the html generation mode. If true a single independent html file will be generated. If false all styling and scripting information are referenced base on the WebGL.ResourcesBasePath parameter. This dramatically reduces the size of the generated html file. true
WebGL.ResourcesBasePath Base path of the html resources (styles and scripts). Must contain the protocol (e.g. https://foo.com). ""
(empty string)

HTML-File - URL Query Parameters

Prerequisite: You've got an html-file by using the endpoint /export/{jobId}.html that is described below.

You can use standard URL Query-String to query specific parts of the solutions in the HTML file.

General format: <path_to_html_file> ? key1=value1 & key2=value2...

Query Parameter
(case-insensitive)
Value Type
(case-insensitive)
Description Required Parameters
solution integer Defines the 1-based index of the complete solution list. -
sequenceNumber integer Defines the 1-based sequence number to display. Note: All sequence numbers up to the given one are displayed.
  • solution
currentSequenceColor hex color All items that match exactly the specified sequence number are rendered in the given color.
  • solution
    • sequenceNumber
pastSequencesColor hex color All items with a sequence number lower than the specified sequence number are rendered in the given color.
  • solution
    • sequenceNumber
mirror enum [none,x,y, xy, yx] Mirroring at the axis (can be used to consider the position of the packer).
  • solution
viewType enum [front,left,back,right,front_left,front_right,back_left,back_right,top] Defines the view direction (corners, side or top).
  • solution
ui boolean
(actual: 'true' and anything else is treated as 'false')
Defines if addition control buttons and details should be visible.
  • solution

Examples

Description Query Graphic
Display the second solution. file.html?solution=2
Full second solution.
Display the second solution mirrored at x-axis. file.html?solution=2&mirror=x
Packages are mirrored at the x-axis
Display the second solution mirrored at y-axis. file.html?solution=2&mirror=y
Packages are mirrored at the y-axis
Display the second solution mirrored at x- and y-axis. file.html?solution=2&mirror=xy
Packages are mirrored at the x- and y-axis
Display the second solution with sequences 1-9. file.html?solution=2&sequenceNumber=9
Sequences 1-9 are visible.
Display the second solution with sequences 1-9 and 9 hightlighted in red. file.html?solution=2&sequenceNumber=9&currentSequenceColor=f00 (any valid hex color)
Sequences 1-9 are visible and current sequence (9) is highlighted.
Display the second solution with sequences 1-9 and 9 hightlighted in red, all other in a reduced grey color. file.html?solution=2&sequenceNumber=9&currentSequenceColor=f00&pastSequencesColor=d3d3d3 (any valid hex color)
Sequences 1-9 are visible, current sequence (9) is highlighted, all past sequences are reduced.

/export/{jobId}.html

Precondition: the state of the job is DONE.

Returns the interactive html report for the job with HTTP status code 200.

If you specify an unknown jobId, PUZZLE returns an error with HTTP status code 404 (see response samples for 404).

If the job does not have the state expected in the precondition, PUZZLE returns an error with HTTP status code 500 (see response samples for 500).

path Parameters
jobId
required
integer <int64> >= 1

The Id of the job.

Responses

Response samples

Content type
application/json
{
  • "errorMessage": "PUZZLE cannot find job with id 123",
  • "additionalInformation": "",
  • "errorClass": "de.fraunhofer.iml.puzzle.adapter.execution.Exceptions.Rest.PuzzleJobNotFoundException"
}