All Downloads are FREE. Search and download functionalities are using the official Maven repository.

net.anotheria.anosite.gen.shared.action.WelcomePageMafAction Maven / Gradle / Ivy

There is a newer version: 4.1.2
Show newest version
/**
 ********************************************************************************
 *** WelcomePageMafAction.java                                                ***
 *** generated by AnoSiteGenerator (ASG), Version: 2.6.3                      ***
 *** Copyright (C) 2005 - 2010 Anotheria.net, www.anotheria.net               ***
 *** All Rights Reserved.                                                     ***
 ********************************************************************************
 *** Don't edit this code, if you aren't sure                                 ***
 *** that you do exactly know what you are doing!                             ***
 *** It's better to invest time in the generator, as into the generated code. ***
 ********************************************************************************
 */

package net.anotheria.anosite.gen.shared.action;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import net.anotheria.maf.action.ActionForward;
import net.anotheria.maf.action.ActionMapping;
import net.anotheria.maf.bean.FormBean;
import net.anotheria.webutils.bean.NavigationItemBean;
import net.anotheria.asg.util.DocumentChange;
import net.anotheria.asg.util.CmsChangesTracker;
import net.anotheria.anosite.gen.shared.filter.CMSMappingsConfigurator;
import net.anotheria.anosite.gen.shared.bean.DocumentChangeFB;
import java.util.Collections;
import java.util.Collection;
import java.util.List;
import java.util.ArrayList;
import net.anotheria.util.Date;


public class WelcomePageMafAction extends BaseAnositeAction{

// Generated by: class net.anotheria.asg.generator.view.action.IndexPageActionGenerator.generateBaseAction


	protected boolean isAuthorizationRequired() {
		return true;
	}

	public ActionForward anoDocExecute(ActionMapping aMapping, FormBean aAf, HttpServletRequest aReq, HttpServletResponse aRes) throws Exception {
		addBeanToRequest(aReq, FLAG_DISABLED_SEARCH, true);
		Collection changes = CmsChangesTracker.getChanges();
		List myList = new ArrayList();
		for (net.anotheria.asg.util.DocumentChange el:changes){
		DocumentChangeFB dcFB = new DocumentChangeFB();
		dcFB.setUserName(el.getUserName());
		dcFB.setDocumentName(el.getDocumentName());
		dcFB.setParentName(el.getParentName());
		dcFB.setDate(new Date(el.getTimestamp()));
		dcFB.setAction(el.getAction().toString());
		dcFB.setId(el.getId());
		dcFB.setDocumentLink(CMSMappingsConfigurator.getActionPath(el.getParentName(), el.getDocumentName()));
		myList.add(dcFB);
	} //closed for
	aReq.setAttribute("changes", myList);
	return aMapping.findForward("success");
}

@Override
	protected String getActiveMainNavi() {;
	return null;
}

@Override
protected List getSubNavigation() {
	return Collections.emptyList();
}

@Override
protected String getCurrentDocumentDefName() {
	return null;
} //getCurrentDocumentDefName

@Override
protected String getCurrentModuleDefName() {
	return null;
} //getCurrentModuleDefName

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy