Information

  • The following workflow provides basic knowledge required to create an interface in PLANTA Project using the functions delivered.
  • The objective of this workflow is a web interface which deletes the logging records of the PLANTA link interfaces

Requirements

  • Basic customizing knowledge
  • Basic knowledge of REST

Notes

  • To be able to use web interfaces you have to activate and configure the PLANTA link webservices in the web.conf:
  • If you have not activated the webservices, the buttons for carrying out different actions which require webservices will not be displayed.
  • Web interfaces use the Fully Qualified Domain Name (FQDN) as an address by default. If the FQDN is not available, the host name of the machine will be used. If the host name is not available either, the IP of the machine will be used. An explicit host name can be defined using the global planta_link_hostname setting.

All fields in the web interface modules are case sensitive (observe upper/lower case spelling)!

Create Web Entity

Objective

  • To create a web entity which describes our data

Procedure

  • Open the Configuration panel
  • Insert a new entity in the Web Entities submodule
    • via the Insert→ Web entity menu entry or
    • by clicking on the Insert button.
  • Specify a name and select table 564 in the Data table field.
  • Save

Create Web Interface

Objective

  • To create a web interface which processes incoming requests and creates our tasks

Procedure

  • Open the Configuration panel
  • Create a new web interface
    • via the Insert→ Web interface menu entry or
    • by clicking on the Insert button.
  • Fill the fields as follows:
    • The name is arbitrary
    • The Active field must be activated before the interface is used.
    • Create a placeholder in the Url field, for example /interface/log/
    • Allocate an API key
    • Select the DefaultServiceImplementation DELETE implementation
    • The entity which was newly created in the previous step is selected in the Web entity field
  • Save

Test Web Interface

Objective

  • To test the newly created web interface

Procedure

  • Click on the earth button to open the Test Web Interface module
  • Select DELETE as HTTP-method
  • Click on the Execute button.
    • The placeholder in the URL is automatically replaced by the transferred value and the API key is passed on in the HTTP header..
  • In response to a successful query, the server responds with the number of deleted records.
    • Example: ={"result": "Deleted 29 objects"}=

Tip

  • You can restrict the amount of records to be deleted by using a URL filter
See also : Web Interface Workflows: GET, PUT, DELETE