Riverscapes / QRAVEPlugin

QGIS Plugin for viewing Riverscapes projects
0 stars 0 forks source link

Opening two projects with the same name #60

Closed philipbaileynar closed 2 years ago

philipbaileynar commented 2 years ago

Background

Picture two projects on disk of the same type and for the same HUC, but they are physically different. A good example would be the channel area projects for the MHFD that we created with different waterbody options.

When these two projects currently get added to the project tree they have the same name. Worse, when you start adding layers to the map, RAVE gets confused and can add the layers to either top level project in the map ToC.

Desired Behaviour

  1. When you open a project, check if another project is already open with the same label in the project tree. If it is then add a distinguishing label suffix to the end of the label (e.g. VBET For 17020304 Copy 01). Note the word "Copy" will help separate the integer from any HUC codes.
  2. The integer suffix will get reused. Picture adding three projects as shown below. Then the user closes Copy 01. Should they add a fourth project project with the same name it will reuse "Copy 01" label. (This is how windows explorer works.)
    • VBET For 17020304
    • VBET For 17020304 Copy 01
    • VBET For 17020304 Copy 02
  3. Adding the projects will use the project label from the tree in the map (e.g. VBET For 17020304 Copy 01). This should ensure that adding layers from any project always finds the correct top level item in the ToC.
philipbaileynar commented 2 years ago

This is now implemented in ArcRAVE. Here's a video demonstration.

KellyMWhitehead commented 2 years ago

Also now in QRave (eff22739d2dc70e4927c9047eab1b15937eb158d)