Hi Savas,
That rule gets evaluated only once and the result is cached. The easiest way to
get what you want is probably to drop the rule and implement the
ERXGuardedObjectInterface, e.g.:
public boolean canDelete() {
return "cantBeDeleted".equals(status()) ? false : true;
}
Or you may want to use an er.directtoweb.ERDDelayedKeyValueAssignment to avoid
the caching behaviour. But that'll require an additional rule if I'm not
mistaken.
Fabian
> Am 08.04.2019 um 18:19 schrieb Savas Celik <[email protected]>:
>
> How can I make the Key: isEntityDeletable true or false depending on the
> objects status?
>
> for example: 100 : (pageConfiguration = 'ListUser' and object.status =
> “cantBeDeleted") => isEntityDeletable = “false"
> [com.webobjects.directtoweb.Assignment]
>
> This should make every User delete able except the once with the status =
> “cantBeDeleted”. But it does not work, it only applies it for the first item
> in the List.
>
> Savas
> _______________________________________________
> Do not post admin requests to the list. They will be ignored.
> Webobjects-dev mailing list ([email protected])
> Help/Unsubscribe/Update your Subscription:
> https://lists.apple.com/mailman/options/webobjects-dev/lists.fabian%40e-lumo.com
>
> This email sent to [email protected]
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list ([email protected])
Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com
This email sent to [email protected]