use of de.metas.ui.web.view.ViewCloseReason in project metasfresh-webui-api by metasfresh.
the class SalesOrder2PurchaseViewFactory method onViewRemoved.
private final void onViewRemoved(final RemovalNotification<Object, Object> notification) {
final PurchaseView view = PurchaseView.cast(notification.getValue());
final ViewCloseReason closeReason = ViewCloseReason.fromCacheEvictedFlag(notification.wasEvicted());
view.close(closeReason);
if (closeReason == ViewCloseReason.USER_REQUEST) {
saveRowsAndEnqueueIfOrderCompleted(view);
}
}
Aggregations