Importing into a list based on a specific value of the parent
I'm trying to add functionality to a model where G3 items in a list are deleted and replaced with other items in that same list.
The model has the following Hierarchy:
In the G3 list, each Resource is either a resource in the current scenario or in the future scenario, this is achieved by the 'Type' property:
On a dashboard accessible by end users, there will be an action that deletes the current resources for a G2 site, and imports the future resources into the current resource property. I thought the best way to do this was by:
Import G3 Resources into a module --> Delete all children of the G2 site --> Import Current Resource (formerly Future) back into that G2 Site from the module.
The actions above will update the entire G3 list (for all sites). How can I create an action to import only the G3 Resources for one specified G2 Site? Is there a better way to achieve the functionality?
I have a few thoughts in this before answering your question:
1. What's your real objective of wanting to delete specific members of G3? Do you just want to make sure the transactional values carried by certain G3 do not appear in subsequent calculations and reports? There are other ways to achieve the latter without having to resort to deletion of members.
2. Please use System modules to replace 'Store', 'Category', 'Type' properties for G3. This is the 'S' in DISCO.
The model is a tool for end users to compare 2 different resource scenarios. End users add their current resources and their future resources to list G3. If they're happy with the future scenario and plan to implement it in their area, we'd want an action to delete the current scenario and replace it with the future scenario.
This means next time they open the tool, they wouldn't have to re-enter their current resources from scratch.
I still don't know what your requirements are, but to answer your question below, i have prepared something for your reference:
"Import G3 Resources into a module --> Delete all children of the G2 site --> Import Current Resource (formerly Future) back into that G2 Site from the module.
The actions above will update the entire G3 list (for all sites). How can I create an action to import only the G3 Resources for one specified G2 Site? Is there a better way to achieve the functionality?"
1. The 'Staging' module is where you Import G3 Resources into a module.
2. The 'City Code' i'm using below corresponds to your G3; and it rolls up to Country, which corresponds to your G2.
3. I have created 2 selection matrix, i.e. Valid Country and Valid Type.
4. Depending on what's entered in 'City Code, Type', 'Final Valid' will be TRUE or FALSE.
1. Final Valid is used to create a Saved View. You can then use this Saved View to help create the G3 that you need.
1. Below is the blueprint mode of 'Staging' module.