The DataType Users has a few fields, including Artists (which is a list of artists (a data type))
Then I have a DATA TYPE Artist.
Artist has three fields:
1.ArtistName (text field)
2. Series (list of texts)
3. Exhibitions (list of data type Exhibitions)
On my page I want to ADD data to these three fields.
Ah, No, I have all my data types and fields set up (correctly I hope).
I am trying to add data to the fields and lists.
So, in the Workflow, if I do it in “Create a new Artist” > “Series add This input’s value”
then I will also have to make a separate workflow to “User” (I suppose)
I’ve been trying this with "Make changes to a list of Users > Type: User > List to change > … and this is where I hit a red error whatever I try to do.
You can add “Series” when you create the Artist. That should work fine.
As long as you have already created Exhibition thing, you can do that as well. But if you need to create two things, and link them … you can do it further to the right in the list of actions.
Sorry, yes, I meant a second action within the same workflow. The problem is working out what to put in the dialogue box to add things to a list / make changes to a list / make changes to a User/Artist/Series etc.
It looks like you are making life a little complicated by using “value is changed” as the trigger on creating the thing. And then having other fields also triggering workflows when they change.
Might be simple to have a button to do the Add ? Then you can add the Artist and all the fields in one hit.
The problem with adding all fields in one hit, as I see it, it that Users will want to be adding new items to SOME of the fields, but not others, at a later date.
Is there some “technical” reason for NOT using “when value is changed” as a trigger for workflows?
Creating your thing when you enter the page (or enter some key data) and then appending to that as you go along is fine.
As I remember, Artist is your “key” so maybe make them enter that first, create the Artist thing. Then open up all the other fields.
The bit that I thought was going to make life complex was creating your Artist thing when ANY data changed. So if you just add Date of Birth … do you then need to set up an Artist if one doesn’t exist etc
Hmm… a User could have more than one Artist, but initially they will be limited to just one (no problem, just a quick conditional). So really, the FIRST thing a User will do is create an Artist, with DoB. The problem I’m having now it fixing any new data to that Artist.
Hence my suggestion to do it all at the same time to make it easier, you just refer to the step.
What you will have to do is store the Artist you have created somewhere. Maybe a group, or a custom state. Then refer to that when you do the updates. So on the “Create Artist” workflow, have a step that stores the Artist as a custom state.
Use a group then. Works the same, pop the optional fields in a group, set the group to be an Artists content, and set this when you create the Artists. Then you can refer to the Parent Group’s Artist in the Make Changes to Thing.
All you are doing there is setting the Group to be the Artist you are currently working on.
When you come to do the “Make Changes to thing” … the THING you want to change is the Group’s Artist. And change the field on that based upon the data changing.
So, you fix the Series data to the Artist by referring to the Group’s artist. The Artist is already fixed to the User (you did this when you added the Artist to the User List).