We'd like your advice on how to do this and are open to changing the way things are organized: We have a bunch of types of curriculum - 100s of checkboxes broken out into 3 subjects: Math, ELA, and Science. Some are considered "standards-aligned" and others are not but there is currently no way to associated the standards-aligned ones with the standards-aligned checkbox. There is a post form where users can edit or add curriculum but they often don't know if they are standards-aligned so we would like to be able to automatically associate the curriculum with checking or unchecking the standards-aligned checkbox. Or, could automatically categorize them based on the curriculum checked. Since there are so many curriculum and they change with some frequency, it would be great if this was easy to maintain. There are already several layers of parent-child relationships so we are hesitant to add another. Is there a way to do this were we wouldn't have to call out each individual curriculum checkbox option in code?
Hello. Thank you for contacting the Toolset support.
I see with the reference URL you shared there is a checkbox "Standards-Aligned Material":
- hidden link
I'm not sure exactly yet what you want to achieve. Do you mean that you want to automatically set the checkbox "Standards-Aligned Material" checked when you submit the form? If no:
- Can you please share bit more details maybe few screenshot and the workflow that should help me to understand the issue first.
On this page hidden link I would like to remove the checkbox for "standards-aligned" from the post form but keep it as a field (or use a category--I'm open to ideas). Then if a user submits this form with, let's say, the subject Science > "Option title 1" selected then the "standards-aligned" checkbox would be automatically checked on the back-end based on that selection (because that curriculum is standards-aligned). If Science > "Option title 2" was selected it wouldn't be checked because that curriculum is not "standards-aligned". Right now there are only a few items under the subject curriculum but there will be 100s and I'd like a way to associate the items under each ELA, Math, and Science with being either "standards-aligned" or not so that users do not have to know this information when they submit the form and so that the admins do not have to check and correct submissions.
Hi Minesh, I saw the cred_before_save_data option but it looks like this works best to say one value is selected so select another value. In our case there are 100s of options that could require checking the "standards-aligned" box and they will be changing with some frequency> I would like some advise on how to do this with many options and how to make it easy to maintain.
There is no automatic way as you will have to write if condition for all possible combination where you will have to set the "standards-aligned" checkbox. So, lets say you have 100s of combinations you will have to write all those combination using if conditional and you have to optimize the code the best way.
As there is no such mechanism you will have to maintain the code and if conditional combinations and make sure you set the "standards-aligned" checkbox on right conditional statement where the if condition is satisfied.