Page MenuHomePhabricator

MPIC: Schema type field not displayed when "Start from template" is selected
Open, MediumPublic2 Estimated Story Points

Description

Description

The Schema type is not displayed in the designs if “Start from template” is selected:

  • We should make sure to display the "Schema type" field in the "Start from template" scenario of Instrument forms.
  • We should add an inline message/help text to the "Schema type" field in the "Modify instrument" scenario to give users a heads-up about the consequences of updating the name of instruments .

Acceptance Criteria

  • Schema type is displayed when "Start from template" is selected
  • A warning message has been added to the "Schema type" field when modifying an instrument to warn about the consequences of changing its value

Event Timeline

Sfaci set the point value for this task to 2.Oct 22 2024, 11:23 AM

hi @Sfaci - this is a much bigger task than originally scoped - for one thing, I think we need 2 template vue files - one for instruments and one for experiments like there are for LaunchInstrument.vue, LaunchExperiment.vue and UpdateInstrument.vue, UpdateExperiment.vue

We need to think about this Get Started section -- right now it is a shared component for both instrument and experiment forms -- Function.vue. I think it needs to be separated for instruments and experiments. When I was trying to figure out what is actually going on for this particular ticket, I realized that both instrument and experiments need different field sets if they are both allowing users to start from a template.

If we keep this Start from template functionality, I think we need to do the following:

  • Decide if the wording of the Get Started fields need to be changed to specify instrument or experiment
  • Refactor the Function.vue component to be able to handle both instruments and experiments:
    • 2 separate function components?
    • Single function component that is able to handle both instruments and experiments << I have a feeling this will get very hairy quickly -- my recollection of working on this component was that it was really complex with just instruments alone. Trying to cascade pre-populated values in other sibling components based on field selections in the Function.vue component was not straightforward - I suspect it will be more than doubly harder trying to make it work on instruments AND experiments.
  • Restrict the allowable lookup to either instruments or experiments only
  • Make sure when an instrument or an experiment is selected, that the correct field sets are visible and populated correctly
  • TEST THOROUGHLY - make sure data is saved correctly for both instruments and experiments starting from template

Given where we are at with the alpha release, I suggest that we remove the Start from template option altogether and if it is still something that is wanted as part of the original designs, that we give ourselves more time to refactor the Start from template functionality -- I believe it was working at one point with instruments but I haven't tested thoroughly enough after experiments were introduced.

I can spin up another ticket to outline next steps once we decide how to move forward.

cc @Sarai-WMF @VirginiaPoundstone @Milimetric

Sfaci removed cjming as the assignee of this task.Mon, Dec 2, 7:18 PM
Sfaci moved this task from MPIC Alpha Scope to Metrics Platform Backlog on the Data Products board.
Sfaci added a subscriber: cjming.