Skip to content

Conversation

TejInaco
Copy link
Contributor

@TejInaco TejInaco commented Aug 29, 2025

This PR will implement #140
This pull request introduces a three-phase workflow triggered by clicking the "Contribute To Catalog" button.

The workflow consists of the following steps:

  1. Metadata
    Users can edit the following Thing Model (TM) fields:
    Model (required)
    Author (required)
    Manufacturer (required)
    License
    Copyright Year
    Copyright Holder

Validation is performed on the required fields. Successful validation is mandatory to proceed to Step 2.

  1. Interaction
    This step allows users to test the TM. A Thing Description (TD) is generated in the background using values provided in the Instance and Gateway sections.
    It includes four subsections:
    2.1) Instance:
    Users can fill in all dynamic values, i.e., placeholders in the TM such as {{some_value}}.
    2.2) Gateway:
    Users can configure southbound and northbound settings, reusing the logic from the existing Settings component. A refactor was performed to enable component reuse.
    2.3) Value Verification:
    Users can interact with TM properties that include "readproperty" in the op key. These properties are displayed in a table with the following columns: Property Name; Title; Preview Value

Users can test properties individually or all at once. In case of errors:
The name of the failing property is displayed.
For multiple errors, the first failing property is shown along with a counter.
The page number in the table is highlighted in red.

2.4) Saving Results:
This feature will be implemented in a future issue.

All sections include error handling mechanisms.

  1. Submission
    This step retains previously implemented features and completes the workflow.

Additional Notes

A progress bar guides users through the workflow.
Components will be refactored for reuse and logic extraction to improve maintainability and extend unit test coverage.

Copy link

netlify bot commented Aug 29, 2025

Deploy Preview for editdor ready!

Name Link
🔨 Latest commit e0b5fb6
🔍 Latest deploy log https://app.netlify.com/projects/editdor/deploys/68dfd8ed4a181a0008f7becb
😎 Deploy Preview https://deploy-preview-148--editdor.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

Signed-off-by: Ricardo M G da Silva <[email protected]>
Signed-off-by: Ricardo M G da Silva <[email protected]>
Signed-off-by: Ricardo M G da Silva <[email protected]>
Signed-off-by: Ricardo M G da Silva <[email protected]>
Signed-off-by: Ricardo M G da Silva <[email protected]>
@egekorkan
Copy link
Contributor

Review on the UI-level:

  • The second page should have a close button
  • The ui items are centered to the left but they feel unbalanced.
  • All steps have Fullfil the form below to contribute your TM to the Catalog specified in the endpoint at the end. but it should reflect the current step. or it should simply say Please follow the steps below to contribute your TM to a Catalog.. Each step has a description underneath anyways.
  • Step numbers 1,2,3 should have a name. E.g., Metadata, Interaction, Submission ?
  • Important: If I want to fix something in my TM (e.g. modbus register number), I cannot just "hide" the current view. So I need to close the pop-up, fix, reenter metadata in the first step, which is annoying. There can be either a "hide" button or a checkbox in the first step that copies the metadata back into the TM. It is checked by default
  • When I did not configure an intermediary, I should be notified about this in the second step.
  • There is a behavior difference between single properties and test all properties without intermediary. Nothing happens when I click a single property but I get an error when I click all properties.
  • If there is one property on page 5 with an error, nothing is shown to the end user.

Signed-off-by: Ricardo M G da Silva <[email protected]>
@TejInaco
Copy link
Contributor Author

TejInaco commented Sep 9, 2025

Considerations from the Second Review:

  • Step 2: Make it possible to have a red brackground on the page number when a preview value gives an error
  • Step 2: Add the following text: "If you want to verify the correctness of your model, you can interact with a device instance here. To do so, please configure the proxy (northbound, southound, valuepath) and provide instance-specific information such as IP address"
  • Step 2: Add a numbered list with closing and opening transition with the following subtitles 2.1) Instance 2.2) Gateway 2.3) Table 2.4) Saving Results
  • Step 2: 2.1) Instance: Must show all values between {{}} (applied the same logic in other components)
  • Step 2: 2.2) Gateway: User confirmation of values same logic as in Settings. (if fiels are not http or https ) In case of empty values give the option to the user to fullfil them.
  • Step 2: Table - Preview Values - In order to make the sendRequests possibe the same logic as in Send Td and send to Southbound must be applied.

note: use of test tmcSubmission.json

@TejInaco TejInaco force-pushed the feature-3-phase-workflow-for-TM-contribution branch from 56d47af to f9ec046 Compare September 10, 2025 11:20
Signed-off-by: Ricardo M G da Silva <[email protected]>
Signed-off-by: Ricardo M G da Silva <[email protected]>
Signed-off-by: Ricardo M G da Silva <[email protected]>
@egekorkan
Copy link
Contributor

egekorkan commented Sep 25, 2025

Another review:

  • The review table should have property name and title and preview value
  • step 2.4, results should be "Save Values" with a message "a feature for saving the property values will be added later on"
  • The message at the top Fullfil the form below to contribute your TM to the Catalog specified in the endpoint at the end. should be Follow the steps below to contribute your TM to a Catalog specified in the last step.
  • Step 2.3 Test endpoints on properties should be Read property values from device instance and the step name should be Value Verification. Also If you want to verify the correctness of your model should be If you want to verify the correctness of your Thing Model

Signed-off-by: Ricardo M G da Silva <[email protected]>
Signed-off-by: Ricardo M G da Silva <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants