Substitution mechanism support for screen history #PL-4870

This commit is contained in:
Alena Kovalenko 2015-03-27 06:18:17 +00:00
parent 9c84e5480a
commit aeff6341e1
4 changed files with 2 additions and 24 deletions

View File

@ -5,16 +5,8 @@
package com.haulmont.cuba.web.app.ui.security.history;
import com.haulmont.cuba.gui.AppConfig;
import com.haulmont.cuba.gui.components.AbstractFrame;
import com.haulmont.cuba.gui.components.Component;
import com.haulmont.cuba.gui.components.Label;
import com.haulmont.cuba.gui.components.Table;
import com.haulmont.cuba.gui.xml.layout.ComponentsFactory;
import com.haulmont.cuba.security.entity.ScreenHistoryEntity;
import com.haulmont.cuba.security.entity.User;
import javax.inject.Inject;
import java.util.Map;
/**
@ -23,9 +15,6 @@ import java.util.Map;
*/
public class EntityOpenHistoryFrame extends AbstractFrame {
@Inject
protected Table historyTable;
@Override
public void init(Map<String, Object> params) {
}

View File

@ -26,7 +26,7 @@ public class ScreenHistoryDatasource extends CollectionDatasourceImpl<ScreenHist
protected void loadData(Map<String, Object> params) {
UserSession userSession = AppBeans.get(UserSessionSource.class).getUserSession();
User user = null;
if(userSession.getSubstitutedUser() != null) {
if (userSession.getSubstitutedUser() != null) {
user = userSession.getSubstitutedUser();
} else {
user = userSession.getUser();

View File

@ -5,16 +5,8 @@
package com.haulmont.cuba.web.app.ui.security.history;
import com.haulmont.cuba.gui.AppConfig;
import com.haulmont.cuba.gui.components.AbstractFrame;
import com.haulmont.cuba.gui.components.Component;
import com.haulmont.cuba.gui.components.Label;
import com.haulmont.cuba.gui.components.Table;
import com.haulmont.cuba.gui.xml.layout.ComponentsFactory;
import com.haulmont.cuba.security.entity.ScreenHistoryEntity;
import com.haulmont.cuba.security.entity.User;
import javax.inject.Inject;
import java.util.Map;
/**
@ -24,9 +16,6 @@ import java.util.Map;
*/
public class EntityOpenHistoryFrame extends AbstractFrame {
@Inject
protected Table historyTable;
@Override
public void init(Map<String, Object> params) {
}

View File

@ -26,7 +26,7 @@ public class ScreenHistoryDatasource extends CollectionDatasourceImpl<ScreenHist
protected void loadData(Map<String, Object> params) {
UserSession userSession = AppBeans.get(UserSessionSource.class).getUserSession();
User user = null;
if(userSession.getSubstitutedUser() != null) {
if (userSession.getSubstitutedUser() != null) {
user = userSession.getSubstitutedUser();
} else {
user = userSession.getUser();