Hello,
So I tried to do soft delete and it works fine. My question is that I want to do hard delete if the user deleted the English or Arabic version of the news,
(What I did was that when user deletes English or Arabic version it only does soft delete to the deleted version only either it was Arabic or English and if the user decides to delete the other version it will delete using hard delete?)
Another question that I'm trying to Assign role to the user when creating one but it gives me this error although I assigned the id created for the role.
Thanks.
Hello
I have Updated Your Logic, here we have used one filter in a aggregate on our delete /update server action,
and fetch the data that is been deleted, if there is some data then empty property will be false
else empty will be true, according to that I have created a Logic and deleted the record.
Updated Oml attached
I hope this helps
Best Rgegards
Tousif Khan
Hy in the second question, are you creating data in the role user entity before create the user?
I'm assigning the role to user while creating the user, I don't know if this is your question.
Hi Mohamed Zakaria ,
For second question you assign wrong UserID in assign role parameter.
here should be assign Created UserId .
I update your oap file please check it.
Thanks
That's worked for the second question thanks.
As You have mentioned that you want to do hard delete, can you be more clear
1 If User deleted Arabic taking it as a example, so in that case do you want to delete it permanently or just sof t delete?
2) When one Language is deleted and if user delete another one as well, So in that Case what you want to do ?
Please let me know so that I'll answer it accordingly
Hello Tousif,
If the user deleted Arabic for example, I want it to be soft deleted and I already did that.
But when one language is deleted and if user delete another one as well I want to fully delete it from database (both Arabic and English).
Thanks a lot for your help it works fine now, but can you please explain to me what is this filter doing exactly?
Hi Mohamed,
You ask 2 different questions in one. This makes the discussion very complicated, nor can you now mark replies for both questions as solution, if a solution is provided.
Please consider creating separate questions next time.
Regards,
Daniel
Hi Daniel,
I'm sorry for that, I will make sure to separate questions next time.