Hello,
I have an icon a user clicks to "Mark the task as complete". I want to change the TaskStatus (a column in my local entity) of the record that the user clicked the icon on. I have an Onclick event for the icon, when clicked I gather the record that the user clicked (no issues here). My issue is how do I update only that one column?
Right now, I have a server action that grabs the taskstatus from the record I mentioned above. But what do I do in the server action? In the server action I created an input variable for the status. But I can't assign the status to anything other than the input variable I just created. Then I'm not sure how I would only update that one record. Any help is greatly appreciated.
You need to use the record and assign the new status to the record the new status, you pass that structure/record through the createOrUpdate server action to update that record.
If this doesn't help you, can you please share your OML?
Kind Regards,
Márcio
Hi Troy,
Yes, you can update only one column in your entity,
Suppose your entity name is Tasks and there is a column IsCompleted and if you click on a button then it should be set as True.
So, in your onClick action call the GetTasks entity action and pass TaskId/Primary key of Tasks entity then assign
GetTasks.List.Current.IsCompleted = True
Then after call UpdateTasks entity action and set source as GetTasks.List.Current, It'll update only IsCompleted column value.
I just gave an overview here might be your entity and column names are different.
I hope it'll help you.
ThanksDeep