Move SP to Location Relationship Establishment from SP Record to Location Record

Description

Purpose: We had previously implemented the ability to add 0 to many locations to a service point record. But we have since realized that we need to require at least one service point per location. For this reason, we need to move the ability to establish the relationship to the location record.

User story:
As a user who is creating a location
I want to be required to add at least one (primary) service point to the location
Because, if a location doesn't have a service point, the system won't be able to know where it's home is (among other things)

Scenarios:

  1. Scenario CB: Moved to UISP-5

    • Given the service point create/edit forms at Settings > Organization > Service points

    • When displayed

    • Then the Assigned locations section should be read-only as shown in these mockups

  2. Scenario

    • Given the Location create/edit forms at Settings > Organization > Location setup > Locations

    • When displayed

    • Then new field should be added below Discovery display name labelled "Service point(s) *"

  3. Scenario

    • Given the Location create/edit forms at Settings > Organization > Location setup > Locations

    • When the new "Service point(s) *" field is displayed

    • Then a single dropdown menu should display:

      • Default value "Select service point"

      • Contains all service points (service points are added at Settings > Organization > Service points) in alphabetical order

      • Accompanied by a radio button indicating whether it is the primary service point for the location (when there is only one service point, the radio button is inactive) CB: I am not a fan of this radio button. I'll get Filip's thoughts in the comments.

      • Accompanied by an "+ Add service point" button

  4. Scenario

    • Given the Location create/edit forms at Settings > Organization > Location setup > Locations

    • Given the "+ Add service point" button

    • When clicked

    • Then a new dropdown menu should be displayed along with a "primary" radio button as shown in the below linked mockups

      • "Primary" radio buttons should become active when there is > 1 service point CB: I am not a fan of this radio button. I'll get Filip's thoughts in the comments.

      • New dropdown menu should be accompanied by a delete icon

        • Clicking the delete icon will remove the additional service point

        • It should not be possible to delete the last service point menu (when deletion is attempted, a red error should appear under the menu reading "Location must have at least one service point")

  5. Scenario

    • Given the Location create/edit forms at Settings > Organization > Location setup > Locations

    • When there is not at least one service point selected and save is attempted or focus moves to next field

    • Then:

      • Required field message should display "Please fill this in to continue"

      • Save should be disallowed

  6. Scenario

    • Given the Location create/edit forms at Settings > Organization > Location setup > Locations has an extraneous service point menu displaying with no service point is selected

    • When save is attempted

    • Then:

  7. Scenario

    • Given the Location view forms at Settings > Organization > Location setup > Locations

    • When the location is displayed after save (in edit and view modes)

    • Then "Service point(s)" should display as shown in the below linked mockups

  8. Scenario

    • Given Service Point C is made primary for the location

    • When the location is displayed after save (in edit and view modes)

    • Then Service Point C should display at the top of the list of service points

Mockups:

  1. https://drive.google.com/file/d/16afH-WsOhtHWSU72SSQPOyGurEGpyTbq/view

  2. https://drive.google.com/file/d/1RoJhEbh0TnYj5FdaZpeviYaHHFEF3avE/view

  3. https://drive.google.com/file/d/1D69Xlv7QxQLW_l-5bVYpJ5GZmSbD6Tpo/view

Environment

None

Potential Workaround

None

Attachments

12

Checklist

hide

TestRail: Results

Activity

Show:

Aditya matukumalli October 26, 2018 at 2:43 PM
Edited

I am not sure if i quite follow. So, from the screenshot you pasted, I am guessing if we select the second dropdown there, you have Circ Desk 2 as the only option there? But, its up to the user to assign that service point to the location right? He/She may not want to assign the SP to the location. So, basically what you have experienced there is what's mentioned in Scenario 6 in the story. Correct me if I got this wrong.

I will look into the focus thingy. Thanks.

Filip Jakobsen October 26, 2018 at 2:31 PM

, it would also be cool if we could focus and open the dropdown automatically when the user clicks "+ Add"

Filip Jakobsen October 26, 2018 at 2:31 PM

, I was looking at Snapshot Stable: If there is only one possible value left in the dropdown, can we make it select that automatically? I was able to select nothing, and save the record, as you can see in the screenshot above.

Cate Boerema October 26, 2018 at 10:14 AM

This is working great. Thanks !

+ as an FYI.

Filip Jakobsen October 24, 2018 at 10:31 AM

, I agree. , can you change the Selected Radio styling to have a white background and a black dot? Thanks!

Done

Details

Assignee

Reporter

Priority

Development Team

Prokopovych

Fix versions

TestRail: Cases

Open TestRail: Cases

TestRail: Runs

Open TestRail: Runs
Created September 27, 2018 at 4:21 PM
Updated December 12, 2018 at 8:07 PM
Resolved October 26, 2018 at 10:14 AM
TestRail: Cases
TestRail: Runs