roller-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From snoopd...@apache.org
Subject svn commit: r225579 - in /incubator/roller/branches/roller_2.0: metadata/xdoclet/ src/org/roller/business/ src/org/roller/business/hibernate/ src/org/roller/model/ src/org/roller/pojos/ src/org/roller/presentation/ src/org/roller/presentation/util/ src...
Date Wed, 27 Jul 2005 19:09:54 GMT
Author: snoopdave
Date: Wed Jul 27 12:09:35 2005
New Revision: 225579

URL: http://svn.apache.org/viewcvs?rev=225579&view=rev
Log:
Website Member Permissions page complete

Added:
    incubator/roller/branches/roller_2.0/src/org/roller/presentation/website/actions/CreateWebsiteAction.java
      - copied, changed from r225230, incubator/roller/branches/roller_2.0/src/org/roller/presentation/website/actions/NewWebsiteAction.java
    incubator/roller/branches/roller_2.0/src/org/roller/presentation/website/formbeans/CreateWebsiteForm.java
      - copied, changed from r225230, incubator/roller/branches/roller_2.0/src/org/roller/presentation/website/formbeans/NewWebsiteForm.java
    incubator/roller/branches/roller_2.0/src/org/roller/presentation/website/formbeans/MemberPermissionsForm.java
    incubator/roller/branches/roller_2.0/web/website/CreateWebsite.jsp
      - copied, changed from r225383, incubator/roller/branches/roller_2.0/web/website/NewWebsite.jsp
    incubator/roller/branches/roller_2.0/web/website/MemberPermissions.jsp
Modified:
    incubator/roller/branches/roller_2.0/metadata/xdoclet/global-forwards.xml
    incubator/roller/branches/roller_2.0/src/org/roller/business/UserManagerImpl.java
    incubator/roller/branches/roller_2.0/src/org/roller/business/hibernate/HibernateUserManagerImpl.java
    incubator/roller/branches/roller_2.0/src/org/roller/model/UserManager.java
    incubator/roller/branches/roller_2.0/src/org/roller/pojos/UserData.java
    incubator/roller/branches/roller_2.0/src/org/roller/pojos/WeblogEntryData.java
    incubator/roller/branches/roller_2.0/src/org/roller/pojos/WebsiteData.java
    incubator/roller/branches/roller_2.0/src/org/roller/presentation/BasePageModel.java
    incubator/roller/branches/roller_2.0/src/org/roller/presentation/util/StrutsUtil.java
    incubator/roller/branches/roller_2.0/src/org/roller/presentation/velocity/ContextLoader.java
    incubator/roller/branches/roller_2.0/src/org/roller/presentation/velocity/ExportRss.java
    incubator/roller/branches/roller_2.0/src/org/roller/presentation/website/actions/InviteMemberAction.java
    incubator/roller/branches/roller_2.0/src/org/roller/presentation/website/actions/MemberPermissionsAction.java
    incubator/roller/branches/roller_2.0/src/org/roller/presentation/website/actions/YourWebsitesAction.java
    incubator/roller/branches/roller_2.0/web/WEB-INF/classes/ApplicationResources.properties
    incubator/roller/branches/roller_2.0/web/WEB-INF/classes/ApplicationResources_is.properties
    incubator/roller/branches/roller_2.0/web/WEB-INF/classes/ApplicationResources_ja_JP.properties
    incubator/roller/branches/roller_2.0/web/WEB-INF/classes/ApplicationResources_nl.properties
    incubator/roller/branches/roller_2.0/web/WEB-INF/classes/ApplicationResources_zh_TW.properties
    incubator/roller/branches/roller_2.0/web/WEB-INF/editor-menu.xml
    incubator/roller/branches/roller_2.0/web/website/InviteMember.jsp
    incubator/roller/branches/roller_2.0/web/website/UserNew.jsp
    incubator/roller/branches/roller_2.0/web/website/YourProfile.jsp
    incubator/roller/branches/roller_2.0/web/website/YourWebsites.jsp
    incubator/roller/branches/roller_2.0/web/website/edit-website.jsp

Modified: incubator/roller/branches/roller_2.0/metadata/xdoclet/global-forwards.xml
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_2.0/metadata/xdoclet/global-forwards.xml?rev=225579&r1=225578&r2=225579&view=diff
==============================================================================
--- incubator/roller/branches/roller_2.0/metadata/xdoclet/global-forwards.xml (original)
+++ incubator/roller/branches/roller_2.0/metadata/xdoclet/global-forwards.xml Wed Jul 27 12:09:35 2005
@@ -21,8 +21,9 @@
 <forward name="importBookmarks"        path="/editor/importBookmarks.do"/>
 <forward name="importEntries"          path="/editor/importEntries.do?method=edit"/>
 <forward name="inviteMember"           path="/editor/inviteMember.do" />
+<forward name="memberPermissions"      path="/editor/memberPermissions.do" />
 <forward name="maintenance"            path="/editor/maintenance.do" />
-<forward name="newWebsite"             path="/editor/newWebsite.do?method=create" />
+<forward name="createWebsite"          path="/editor/createWebsite.do?method=create" />
 <forward name="editPages"              path="/editor/page.do?method=editPages"/>
 <forward name="editPage"               path="/editor/page.do?method=edit"/>
 <forward name="removePage"             path="/editor/page.do?method=remove"/>

Modified: incubator/roller/branches/roller_2.0/src/org/roller/business/UserManagerImpl.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_2.0/src/org/roller/business/UserManagerImpl.java?rev=225579&r1=225578&r2=225579&view=diff
==============================================================================
--- incubator/roller/branches/roller_2.0/src/org/roller/business/UserManagerImpl.java (original)
+++ incubator/roller/branches/roller_2.0/src/org/roller/business/UserManagerImpl.java Wed Jul 27 12:09:35 2005
@@ -50,7 +50,7 @@
     {
     }
             
-    public PermissionsData retrievePermissionsData(String inviteId) 
+    public PermissionsData retrievePermissions(String inviteId) 
         throws RollerException
     {
         return (PermissionsData)mStrategy.load(inviteId, PermissionsData.class);
@@ -233,7 +233,7 @@
             String description,
             String theme, 
             String locale, 
-            String timezone) throws RollerException
+            String timeZone) throws RollerException
     {
         Roller mRoller = RollerFactory.getRoller();
         UserManager umgr = mRoller.getUserManager();
@@ -259,7 +259,7 @@
             new Date());
         website.setEditorTheme(theme);
         website.setLocale(locale);
-        website.setTimezone(timezone);
+        website.setTimezone(timeZone);
         website.save();
 
         WeblogCategoryData rootCat = wmgr.createWeblogCategory(

Modified: incubator/roller/branches/roller_2.0/src/org/roller/business/hibernate/HibernateUserManagerImpl.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_2.0/src/org/roller/business/hibernate/HibernateUserManagerImpl.java?rev=225579&r1=225578&r2=225579&view=diff
==============================================================================
--- incubator/roller/branches/roller_2.0/src/org/roller/business/hibernate/HibernateUserManagerImpl.java (original)
+++ incubator/roller/branches/roller_2.0/src/org/roller/business/hibernate/HibernateUserManagerImpl.java Wed Jul 27 12:09:35 2005
@@ -548,5 +548,43 @@
             throw new RollerException(e);
         }
     }
+
+    /**
+     * Get all permissions of a website (pendings not including)
+     */
+    public List getAllPermissions(WebsiteData website) throws RollerException
+    {
+        Session session = ((HibernateStrategy)mStrategy).getSession();
+        Criteria criteria = session.createCriteria(PermissionsData.class);            
+        criteria.add(Expression.eq("website", website));
+        criteria.add(Expression.eq("pending", Boolean.FALSE));
+        try
+        {
+            return criteria.list();
+        }
+        catch (HibernateException e)
+        {
+            throw new RollerException(e);
+        }
+    }
+
+    /**
+     * Get all permissions of a user.
+     */
+    public List getAllPermissions(UserData user) throws RollerException
+    {
+        Session session = ((HibernateStrategy)mStrategy).getSession();
+        Criteria criteria = session.createCriteria(PermissionsData.class);            
+        criteria.add(Expression.eq("user", user));
+        criteria.add(Expression.eq("pending", Boolean.FALSE));
+        try
+        {
+            return criteria.list();
+        }
+        catch (HibernateException e)
+        {
+            throw new RollerException(e);
+        }
+    }
 }
 

Modified: incubator/roller/branches/roller_2.0/src/org/roller/model/UserManager.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_2.0/src/org/roller/model/UserManager.java?rev=225579&r1=225578&r2=225579&view=diff
==============================================================================
--- incubator/roller/branches/roller_2.0/src/org/roller/model/UserManager.java (original)
+++ incubator/roller/branches/roller_2.0/src/org/roller/model/UserManager.java Wed Jul 27 12:09:35 2005
@@ -69,7 +69,23 @@
     public PermissionsData getPermissions(
             WebsiteData website, UserData user) throws RollerException;
     
-    public PermissionsData retrievePermissionsData(String inviteId) 
+    /**
+     * Get all permissions in website
+     * @param website Website (not null)
+     * @return        PermissionsData object
+     */
+    public List getAllPermissions(
+            WebsiteData website) throws RollerException;
+    
+    /**
+     * Get all permissions of user
+     * @param user User (not null)
+     * @return     PermissionsData object
+     */
+    public List getAllPermissions(
+            UserData user) throws RollerException;
+    
+    public PermissionsData retrievePermissions(String inviteId) 
         throws RollerException;
 
     /**
@@ -128,7 +144,7 @@
      * @param description Description of new website
      * @param theme       Name of theme to be used
      * @param locale      Locale code of new website
-     * @param timezone    ID of timezone of new website
+     * @param timeZone    ID of timeZone of new website
      * @return            New website object (has been saved and committed)
      * @throws RollerException
      */
@@ -140,7 +156,7 @@
             String description,
             String theme, 
             String locale, 
-            String timezone) throws RollerException;
+            String timeZone) throws RollerException;
 
     public UserData retrieveUser(String id)throws RollerException;
     public void storeUser( UserData data ) throws RollerException;

Modified: incubator/roller/branches/roller_2.0/src/org/roller/pojos/UserData.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_2.0/src/org/roller/pojos/UserData.java?rev=225579&r1=225578&r2=225579&view=diff
==============================================================================
--- incubator/roller/branches/roller_2.0/src/org/roller/pojos/UserData.java (original)
+++ incubator/roller/branches/roller_2.0/src/org/roller/pojos/UserData.java Wed Jul 27 12:09:35 2005
@@ -59,7 +59,7 @@
 	public UserData( String id, String userName,
                      String password, String fullName,
                      String emailAddress, 
-                     String locale, String timezone,
+                     String locale, String timeZone,
                      Date dateCreated,
                      Boolean isEnabled)
 	{
@@ -70,7 +70,7 @@
          this.emailAddress = emailAddress;
          this.dateCreated = (Date)dateCreated.clone();
          this.locale = locale;
-         this.timeZone = timezone;
+         this.timeZone = timeZone;
          this.isEnabled = isEnabled;
 	}
 
@@ -242,7 +242,7 @@
    /**
     * Timezone of the user.
     * @ejb:persistent-field
-    * @hibernate.property column="timezone" non-null="true" unique="false"
+    * @hibernate.property column="timeZone" non-null="true" unique="false"
     */
    public String getTimeZone()
    {

Modified: incubator/roller/branches/roller_2.0/src/org/roller/pojos/WeblogEntryData.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_2.0/src/org/roller/pojos/WeblogEntryData.java?rev=225579&r1=225578&r2=225579&view=diff
==============================================================================
--- incubator/roller/branches/roller_2.0/src/org/roller/pojos/WeblogEntryData.java (original)
+++ incubator/roller/branches/roller_2.0/src/org/roller/pojos/WeblogEntryData.java Wed Jul 27 12:09:35 2005
@@ -325,9 +325,9 @@
      * <p>Publish time is the time that an entry is to be (or was) made available
      * for viewing by newsfeed readers and visitors to the Roller site.</p> 
      * 
-     * <p>Roller stores time using the timezone of the server itself. When
+     * <p>Roller stores time using the timeZone of the server itself. When
      * times are displayed  in a user's weblog they must be translated 
-     * to the user's timezone.</p>
+     * to the user's timeZone.</p>
      *
      * <p>NOTE: Times are stored using the SQL TIMESTAMP datatype, which on 
      * MySQL has only a one-second resolution.</p>
@@ -350,9 +350,9 @@
      * <p>Update time is the last time that an weblog entry was saved in the 
      * Roller weblog editor or via web services API (XML-RPC or Atom).</p> 
      *
-     * <p>Roller stores time using the timezone of the server itself. When
+     * <p>Roller stores time using the timeZone of the server itself. When
      * times are displayed  in a user's weblog they must be translated 
-     * to the user's timezone.</p>
+     * to the user's timeZone.</p>
      *
      * <p>NOTE: Times are stored using the SQL TIMESTAMP datatype, which on 
      * MySQL has only a one-second resolution.</p>

Modified: incubator/roller/branches/roller_2.0/src/org/roller/pojos/WebsiteData.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_2.0/src/org/roller/pojos/WebsiteData.java?rev=225579&r1=225578&r2=225579&view=diff
==============================================================================
--- incubator/roller/branches/roller_2.0/src/org/roller/pojos/WebsiteData.java (original)
+++ incubator/roller/branches/roller_2.0/src/org/roller/pojos/WebsiteData.java Wed Jul 27 12:09:35 2005
@@ -49,7 +49,7 @@
     protected String  emailAddress;
     protected String  editorTheme;
     protected String  locale;
-    protected String  timezone;
+    protected String  timeZone;
     protected String  mDefaultPlugins;
     protected Boolean isEnabled;
     protected Date dateCreated;
@@ -424,17 +424,17 @@
     /**
      * Timezone of the Website.
      * @ejb:persistent-field
-     * @hibernate.property column="timezone" non-null="true" unique="false"
+     * @hibernate.property column="timeZone" non-null="true" unique="false"
      */
     public String getTimezone()
     {
-        return this.timezone;
+        return this.timeZone;
     }
 
     /** @ejb:persistent-field */
-    public void setTimezone(String timezone)
+    public void setTimezone(String timeZone)
     {
-        this.timezone = timezone;
+        this.timeZone = timeZone;
     }
 
     /** 
@@ -515,7 +515,7 @@
                    "emailFromAddress=" + emailFromAddress + " " +
                    "editorTheme=" + editorTheme + " " +
                    "locale=" + locale + " " +
-                   "timezone=" + timezone + " " +
+                   "timeZone=" + timeZone + " " +
                    "defaultPlugins=" + mDefaultPlugins);
         str.append('}');
 
@@ -563,7 +563,7 @@
 
             lEquals = PojoUtil.equals(lEquals, this.locale, lTest.locale);
 
-            lEquals = PojoUtil.equals(lEquals, this.timezone, lTest.timezone);
+            lEquals = PojoUtil.equals(lEquals, this.timeZone, lTest.timeZone);
 
             lEquals = PojoUtil.equals(lEquals, this.mDefaultPlugins, lTest.mDefaultPlugins);
             
@@ -595,7 +595,7 @@
         result = PojoUtil.addHashCode(result, this.emailFromAddress);
         result = PojoUtil.addHashCode(result, this.editorTheme);
         result = PojoUtil.addHashCode(result, this.locale);
-        result = PojoUtil.addHashCode(result, this.timezone);
+        result = PojoUtil.addHashCode(result, this.timeZone);
         result = PojoUtil.addHashCode(result, this.mDefaultPlugins);
 
         return result;
@@ -626,7 +626,7 @@
         this.emailFromAddress = other.emailFromAddress;
         this.editorTheme = other.editorTheme;
         this.locale = other.locale;
-        this.timezone = other.timezone;
+        this.timeZone = other.timeZone;
         this.mDefaultPlugins = other.mDefaultPlugins;
         this.isEnabled = other.isEnabled;
         this.dateCreated = dateCreated;
@@ -665,13 +665,13 @@
     }
     
     /**
-     * Return TimeZone instance for value of timezone,
+     * Return TimeZone instance for value of timeZone,
      * otherwise return system default instance.
      * @return TimeZone
      */
     public TimeZone getTimeZoneInstance()
     {
-    	if (timezone == null) 
+    	if (timeZone == null) 
         {
             if (TimeZone.getDefault() != null) 
             {
@@ -682,7 +682,7 @@
                 this.setTimezone("America/New_York");
             }
         }
-        return TimeZone.getTimeZone(timezone);
+        return TimeZone.getTimeZone(timeZone);
     }
     
     /** 

Modified: incubator/roller/branches/roller_2.0/src/org/roller/presentation/BasePageModel.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_2.0/src/org/roller/presentation/BasePageModel.java?rev=225579&r1=225578&r2=225579&view=diff
==============================================================================
--- incubator/roller/branches/roller_2.0/src/org/roller/presentation/BasePageModel.java (original)
+++ incubator/roller/branches/roller_2.0/src/org/roller/presentation/BasePageModel.java Wed Jul 27 12:09:35 2005
@@ -33,7 +33,7 @@
         this.response = response;
         this.mapping = mapping;
         request.setAttribute("locales", StrutsUtil.getLocaleBeans());        
-        request.setAttribute("timezones", StrutsUtil.getTimeZoneBeans());        
+        request.setAttribute("timeZones", StrutsUtil.getTimeZoneBeans());        
     }
 
     public String getBaseURL()

Modified: incubator/roller/branches/roller_2.0/src/org/roller/presentation/util/StrutsUtil.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_2.0/src/org/roller/presentation/util/StrutsUtil.java?rev=225579&r1=225578&r2=225579&view=diff
==============================================================================
--- incubator/roller/branches/roller_2.0/src/org/roller/presentation/util/StrutsUtil.java (original)
+++ incubator/roller/branches/roller_2.0/src/org/roller/presentation/util/StrutsUtil.java Wed Jul 27 12:09:35 2005
@@ -14,7 +14,7 @@
 public class StrutsUtil
 {
     public static ArrayList locales;
-    public static ArrayList timezones;
+    public static ArrayList timeZones;
     
     //-----------------------------------------------------------------------
     /**
@@ -60,10 +60,10 @@
      */
     public static List getTimeZoneBeans() 
     {
-        if (timezones == null)
+        if (timeZones == null)
         {
             Date today = new Date();
-            timezones = new ArrayList();
+            timeZones = new ArrayList();
             TreeSet zoneTree = new TreeSet(new TimeZoneComparator());
             String[] zoneArray = TimeZone.getAvailableIDs();
             for (int i=0; i<zoneArray.length; i++)
@@ -78,11 +78,11 @@
                 sb.append(zone.getDisplayName(zone.inDaylightTime(today), TimeZone.SHORT));
                 sb.append(" - ");
                 sb.append(zone.getID());
-                timezones.add(new LabelValueBean(
+                timeZones.add(new LabelValueBean(
                    sb.toString(),
                    zone.getID()));
             }
         }
-        return timezones;
+        return timeZones;
     }
 }

Modified: incubator/roller/branches/roller_2.0/src/org/roller/presentation/velocity/ContextLoader.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_2.0/src/org/roller/presentation/velocity/ContextLoader.java?rev=225579&r1=225578&r2=225579&view=diff
==============================================================================
--- incubator/roller/branches/roller_2.0/src/org/roller/presentation/velocity/ContextLoader.java (original)
+++ incubator/roller/branches/roller_2.0/src/org/roller/presentation/velocity/ContextLoader.java Wed Jul 27 12:09:35 2005
@@ -440,6 +440,7 @@
            
             // setup Timezone for future rendering
             ctx.put("timezone", website.getTimeZoneInstance());
+            ctx.put("timeZone", website.getTimeZoneInstance());
         }
         else
         {
@@ -454,6 +455,7 @@
                 ((RollerPropertyData)props.get("site.adminemail")).getValue());
             ctx.put("locale", Locale.getDefault());
             ctx.put("timezone", TimeZone.getDefault());
+            ctx.put("timeZone", TimeZone.getDefault());
         }
         ctx.put("website", website );
 

Modified: incubator/roller/branches/roller_2.0/src/org/roller/presentation/velocity/ExportRss.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_2.0/src/org/roller/presentation/velocity/ExportRss.java?rev=225579&r1=225578&r2=225579&view=diff
==============================================================================
--- incubator/roller/branches/roller_2.0/src/org/roller/presentation/velocity/ExportRss.java (original)
+++ incubator/roller/branches/roller_2.0/src/org/roller/presentation/velocity/ExportRss.java Wed Jul 27 12:09:35 2005
@@ -1 +1 @@
-package org.roller.presentation.velocity;

import java.io.File;
import java.io.FileNotFoundException;
import java.io.FileOutputStream;
import java.io.IOException;
import java.io.StringWriter;
import java.text.SimpleDateFormat;
import java.util.Collection;
import java.util.Date;
import java.util.Locale;
import java.util.Properties;
import java.util.TimeZone;

import org.apache.velocity.Template;
import org.apache.velocity.VelocityContext;
import org.apache.velocity.app.VelocityEngine;
import org.apache.velocity.exception.ParseErrorException;
import org.apache.velocity.exception.ResourceNotFoundException;
import org.roller.RollerException;
import org.roller.model.RollerFactory;
import org.roller.pojos.UserData;
import org.roller.pojos.WebsiteData;
import org.roller.presentation.RollerContext;
import org.roller.util.RegexUtil;
import org.roller.util.StringUtils;
import org.roller.util.Utilities;

/**
 * Does a lot of the same work as ContextLoader in preparing
 * a VelocityContext for parsing.  However, it is ignorant of
 * any HttpServletRequest related features, and so has 
 * considerably trimmed down information.
 * 
 * Created on Mar 25, 2004
 * @author lance.lavandowska
 */
public class ExportRss
{
    private VelocityEngine ve = null;
    private VelocityContext ctx = null;
    private UserData user = null;
    private boolean exportAtom;
    
    private static final String RSS_TEMPLATE = "org/roller/presentation/velocity/export_rss.vm";
    private static final String ATOM_TEMPLATE = "org/roller/presentation/velocity/export_atom.vm";
    
    public ExportRss(WebsiteData website) throws Exception
    {
        Properties props = new Properties();
        props.load(RollerContext.getServletContext().
                   getResourceAsStream("/WEB-INF/velocity.properties"));
        ve = new VelocityEngine();
        ve.info("*******************************************");
        ve.info("Initializing VelocityEngine for ExportRss");
        ve.init( props );
        ve.info("Done initializing VelocityEngine for ExportRss");
        ve.info("************************************************");
        
        ctx = new VelocityContext();
        
        RollerContext rollerCtx = RollerContext.getRollerContext(
                                      RollerContext.getServletContext());
        loadPageHelper();
        
        loadDates(website);
        
        loadWebsiteInfo(rollerCtx, website);

        loadTheRest(rollerCtx);
    }
    
    public void setExportAtom(boolean atom)
    {
        exportAtom = atom;
    }
    
    /**
     * Export the given entries using export_rss.vm.
     * 
     * @param entries
     * @throws ResourceNotFoundException
     * @throws ParseErrorException
     * @throws Exception
     */
    public void exportEntries(Collection entries, String fileName) throws ResourceNotFoundException, ParseErrorException, Exception 
    {
        ctx.put("entries", entries);
        
        String templateFile = RSS_TEMPLATE;
        if (exportAtom) templateFile = ATOM_TEMPLATE;
        Template template = ve.getTemplate( templateFile, "utf-8" );
        StringWriter sw = new StringWriter();
        template.merge(ctx, sw);
        
        writeResultsToFile((String)ctx.get("uploadPath"), sw, fileName);
    }

    /**
     * @param sw
     */
    private void writeResultsToFile(String filePath, StringWriter sw, String fileName) 
        throws RollerException, IOException
    {
        filePath += "/" + user.getUserName();
        new java.io.File( filePath ).mkdirs(); // create dir path on drive
        
        filePath += "/" + fileName;
        
        File outputFile = new java.io.File( filePath );
        FileOutputStream out = null;
        try
        {
            //outputFile.createNewFile();
            out = new FileOutputStream( outputFile );
            out.write( sw.toString().getBytes() );
            out.flush();
        }
        catch ( FileNotFoundException e )
        {
            throw new RollerException( "Unable to write to: " + outputFile.getAbsolutePath(), e );
        }
        finally
        {
            try
            {
                if ( out != null )
                {
                    out.close();
                }
            }
            catch ( java.io.IOException ioe )
            {
                System.err.println( "ExportRss unable to close OutputStream" );
            }
        }
    }

    /**
     * Load miscellaneous values into the Context.
     * @param rollerCtx
     */
    private void loadTheRest(RollerContext rollerCtx)
    {
        ctx.put("utilities",       new Utilities() );
        ctx.put("stringUtils",     new StringUtils() );        
        ctx.put("entryLength",     new Integer(-1));
    }

    /**
     * Load information pertaining to the Website and
     * its associated User.
     * @param rollerCtx
     */
    private void loadWebsiteInfo(RollerContext rollerCtx, WebsiteData website)
    {
        ctx.put("website",       website);
        ctx.put("userName",      user.getUserName() );
        ctx.put("fullName",      user.getFullName() );
        ctx.put("emailAddress",  user.getEmailAddress() );

        ctx.put("encodedEmail",  RegexUtil.encode(user.getEmailAddress()));
        ctx.put("obfuscatedEmail",  RegexUtil.obfuscateEmail(user.getEmailAddress()));

        
        // custom figureResourcePath() due to no "request" object
        StringBuffer sb = new StringBuffer();
        String uploadDir = null;
        try {
            uploadDir = RollerFactory.getRoller().getFileManager().getUploadDir();
        } catch(Exception e) {}

        ctx.put("uploadPath", uploadDir);
    }

    /**
     * Load time-related information.
     * @param website
     */
    private void loadDates(WebsiteData website)
    {
        try
        {
            // Add current time and last updated times to context
            Date updateTime = RollerFactory.getRoller().getWeblogManager()
                .getWeblogLastPublishTime(website, null);                        
            ctx.put("updateTime",   updateTime);
        }
        catch (RollerException e)
        {                       
            ctx.put("updateTime",   new Date());
        }
        ctx.put("now",              new Date());
        
        // setup Locale for future rendering
        Locale locale = website.getLocaleInstance();
        ctx.put("locale", locale);
        
        // setup Timezone for future rendering
        ctx.put("timezone", website.getTimeZoneInstance());

        // date formats need to be run through the Localized
        // SimpleDateFormat and pulled back out as localized patterns.
        SimpleDateFormat sdf = new SimpleDateFormat("yyyyMMdd", locale);  
        sdf.setTimeZone( (TimeZone)ctx.get("timezone") );    
        ctx.put("plainFormat",     sdf.toLocalizedPattern());
        
        sdf.applyPattern("EEEE MMMM dd, yyyy");
        ctx.put("toStringFormat",  sdf.toLocalizedPattern());
        
        sdf.applyPattern("MMM dd yyyy, hh:mm:ss a z");
        ctx.put("timestampFormat", sdf.toLocalizedPattern());
        
        ctx.put("dateFormatter", sdf );
    }
    /**
     * Create a PageHelper.  Note that will have no values
     * necessary in parsing a Web request (such as /page) -
     * it is only useful for the restricted export_rss.vm
     * and has no PagePlugins either.  We want the exported
     * Entry.text to be the raw values.
     */
    private void loadPageHelper()
    {
        // Add Velocity page helper to context
        PageHelper pageHelper = new PageHelper(null, null, ctx);
        // set no PagePlugins - we *do not* want to render them.
        ctx.put("pageHelper", pageHelper );
    }
}
\ No newline at end of file
+package org.roller.presentation.velocity;

import java.io.File;
import java.io.FileNotFoundException;
import java.io.FileOutputStream;
import java.io.IOException;
import java.io.StringWriter;
import java.text.SimpleDateFormat;
import java.util.Collection;
import java.util.Date;
import java.util.Locale;
import java.util.Properties;
import java.util.TimeZone;

import org.apache.velocity.Template;
import org.apache.velocity.VelocityContext;
import org.apache.velocity.app.VelocityEngine;
import org.apache.velocity.exception.ParseErrorException;
import org.apache.velocity.exception.ResourceNotFoundException;
import org.roller.RollerException;
import org.roller.model.RollerFactory;
import org.roller.pojos.UserData;
import org.roller.pojos.WebsiteData;
import org.roller.presentation.RollerContext;
import org.roller.util.RegexUtil;
import org.roller.util.StringUtils;
import org.roller.util.Utilities;

/**
 * Does a lot of the same work as ContextLoader in preparing
 * a VelocityContext for parsing.  However, it is ignorant of
 * any HttpServletRequest related features, and so has 
 * considerably trimmed down information.
 * 
 * Created on Mar 25, 2004
 * @author lance.lavandowska
 */
public class ExportRss
{
    private VelocityEngine ve = null;
    private VelocityContext ctx = null;
    private UserData user = null;
    private boolean exportAtom;
    
    private static final String RSS_TEMPLATE = "org/roller/presentation/velocity/export_rss.vm";
    private static final String ATOM_TEMPLATE = "org/roller/presentation/velocity/export_atom.vm";
    
    public ExportRss(WebsiteData website) throws Exception
    {
        Properties props = new Properties();
        props.load(RollerContext.getServletContext().
                   getResourceAsStream("/WEB-INF/velocity.properties"));
        ve = new VelocityEngine();
        ve.info("*******************************************");
        ve.info("Initializing VelocityEngine for ExportRss");
        ve.init( props );
        ve.info("Done initializing VelocityEngine for ExportRss");
        ve.info("************************************************");
        
        ctx = new VelocityContext();
        
        RollerContext rollerCtx = RollerContext.getRollerContext(
                                      RollerContext.getServletContext());
        loadPageHelper();
        
        loadDates(website);
        
        loadWebsiteInfo(rollerCtx, website);

        loadTheRest(rollerCtx);
    }
    
    public void setExportAtom(boolean atom)
    {
        exportAtom = atom;
    }
    
    /**
     * Export the given entries using export_rss.vm.
     * 
     * @param entries
     * @throws ResourceNotFoundException
     * @throws ParseErrorException
     * @throws Exception
     */
    public void exportEntries(Collection entries, String fileName) throws ResourceNotFoundException, ParseErrorException, Exception 
    {
        ctx.put("entries", entries);
        
        String templateFile = RSS_TEMPLATE;
        if (exportAtom) templateFile = ATOM_TEMPLATE;
        Template template = ve.getTemplate( templateFile, "utf-8" );
        StringWriter sw = new StringWriter();
        template.merge(ctx, sw);
        
        writeResultsToFile((String)ctx.get("uploadPath"), sw, fileName);
    }

    /**
     * @param sw
     */
    private void writeResultsToFile(String filePath, StringWriter sw, String fileName) 
        throws RollerException, IOException
    {
        filePath += "/" + user.getUserName();
        new java.io.File( filePath ).mkdirs(); // create dir path on drive
        
        filePath += "/" + fileName;
        
        File outputFile = new java.io.File( filePath );
        FileOutputStream out = null;
        try
        {
            //outputFile.createNewFile();
            out = new FileOutputStream( outputFile );
            out.write( sw.toString().getBytes() );
            out.flush();
        }
        catch ( FileNotFoundException e )
        {
            throw new RollerException( "Unable to write to: " + outputFile.getAbsolutePath(), e );
        }
        finally
        {
            try
            {
                if ( out != null )
                {
                    out.close();
                }
            }
            catch ( java.io.IOException ioe )
            {
                System.err.println( "ExportRss unable to close OutputStream" );
            }
        }
    }

    /**
     * Load miscellaneous values into the Context.
     * @param rollerCtx
     */
    private void loadTheRest(RollerContext rollerCtx)
    {
        ctx.put("utilities",       new Utilities() );
        ctx.put("stringUtils",     new StringUtils() );        
        ctx.put("entryLength",     new Integer(-1));
    }

    /**
     * Load information pertaining to the Website and
     * its associated User.
     * @param rollerCtx
     */
    private void loadWebsiteInfo(RollerContext rollerCtx, WebsiteData website)
    {
        ctx.put("website",       website);
        ctx.put("userName",      user.getUserName() );
        ctx.put("fullName",      user.getFullName() );
        ctx.put("emailAddress",  user.getEmailAddress() );

        ctx.put("encodedEmail",  RegexUtil.encode(user.getEmailAddress()));
        ctx.put("obfuscatedEmail",  RegexUtil.obfuscateEmail(user.getEmailAddress()));

        
        // custom figureResourcePath() due to no "request" object
        StringBuffer sb = new StringBuffer();
        String uploadDir = null;
        try {
            uploadDir = RollerFactory.getRoller().getFileManager().getUploadDir();
        } catch(Exception e) {}

        ctx.put("uploadPath", uploadDir);
    }

    /**
     * Load time-related information.
     * @param website
     */
    private void loadDates(WebsiteData website)
    {
        try
        {
            // Add current time and last updated times to context
            Date updateTime = RollerFactory.getRoller().getWeblogManager()
                .getWeblogLastPublishTime(website, null);                        
            ctx.put("updateTime",   updateTime);
        }
        catch (RollerException e)
        {                       
            ctx.put("updateTime",   new Date());
        }
        ctx.put("now",              new Date());
        
        // setup Locale for future rendering
        Locale locale = website.getLocaleInstance();
        ctx.put("locale", locale);
        
        // setup Timezone for future rendering
        ctx.put("timeZone", website.getTimeZoneInstance());

        // date formats need to be run through the Localized
        // SimpleDateFormat and pulled back out as localized patterns.
        SimpleDateFormat sdf = new SimpleDateFormat("yyyyMMdd", locale);  
        sdf.setTimeZone( (TimeZone)ctx.get("timeZone") );    
        ctx.put("plainFormat",     sdf.toLocalizedPattern());
        
        sdf.applyPattern("EEEE MMMM dd, yyyy");
        ctx.put("toStringFormat",  sdf.toLocalizedPattern());
        
        sdf.applyPattern("MMM dd yyyy, hh:mm:ss a z");
        ctx.put("timestampFormat", sdf.toLocalizedPattern());
        
        ctx.put("dateFormatter", sdf );
    }
    /**
     * Create a PageHelper.  Note that will have no values
     * necessary in parsing a Web request (such as /page) -
     * it is only useful for the restricted export_rss.vm
     * and has no PagePlugins either.  We want the exported
     * Entry.text to be the raw values.
     */
    private void loadPageHelper()
    {
        // Add Velocity page helper to context
        PageHelper pageHelper = new PageHelper(null, null, ctx);
        // set no PagePlugins - we *do not* want to render them.
        ctx.put("pageHelper", pageHelper );
    }
}
\ No newline at end of file

Copied: incubator/roller/branches/roller_2.0/src/org/roller/presentation/website/actions/CreateWebsiteAction.java (from r225230, incubator/roller/branches/roller_2.0/src/org/roller/presentation/website/actions/NewWebsiteAction.java)
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_2.0/src/org/roller/presentation/website/actions/CreateWebsiteAction.java?p2=incubator/roller/branches/roller_2.0/src/org/roller/presentation/website/actions/CreateWebsiteAction.java&p1=incubator/roller/branches/roller_2.0/src/org/roller/presentation/website/actions/NewWebsiteAction.java&r1=225230&r2=225579&rev=225579&view=diff
==============================================================================
--- incubator/roller/branches/roller_2.0/src/org/roller/presentation/website/actions/NewWebsiteAction.java (original)
+++ incubator/roller/branches/roller_2.0/src/org/roller/presentation/website/actions/CreateWebsiteAction.java Wed Jul 27 12:09:35 2005
@@ -30,19 +30,19 @@
 import org.roller.presentation.RollerContext;
 import org.roller.presentation.RollerRequest;
 import org.roller.presentation.RollerSession;
-import org.roller.presentation.website.formbeans.NewWebsiteForm;
+import org.roller.presentation.website.formbeans.CreateWebsiteForm;
 
 /**
  * Allows user to create a new website.
  * 
- * @struts.action path="/editor/newWebsite" parameter="method" name="newWebsiteForm"
- * @struts.action-forward name="newWebsite.page" path="/website/NewWebsite.jsp"
- * @struts.action-forward name="newWebsiteDone.page" path="/website/NewWebsiteDone.jsp"
+ * @struts.action path="/editor/createWebsite" parameter="method" name="createWebsiteForm"
+ * @struts.action-forward name="createWebsite.page" path="/website/CreateWebsite.jsp"
+ * @struts.action-forward name="createWebsiteDone.page" path="/website/CreateWebsiteDone.jsp"
  */
-public class NewWebsiteAction extends DispatchAction
+public class CreateWebsiteAction extends DispatchAction
 {
     private static Log mLogger =
-        LogFactory.getFactory().getInstance(NewWebsiteAction.class);
+        LogFactory.getFactory().getInstance(CreateWebsiteAction.class);
     
     /** If method param is not specified, use HTTP verb to pick method to call */
     public ActionForward unspecified(
@@ -67,14 +67,14 @@
             HttpServletResponse response)
             throws IOException, ServletException
     {
-        NewWebsiteForm form = (NewWebsiteForm)actionForm;
+        CreateWebsiteForm form = (CreateWebsiteForm)actionForm;
         form.setLocale( Locale.getDefault().toString() );
         form.setTimeZone( TimeZone.getDefault().getID() );      
 
         request.setAttribute("model", 
-            new NewWebsitePageModel(request, response, mapping, null));
+            new CreateWebsitePageModel(request, response, mapping, null));
         
-        ActionForward forward = mapping.findForward("newWebsite.page");
+        ActionForward forward = mapping.findForward("createWebsite.page");
         return forward;
     }
     
@@ -86,7 +86,7 @@
             HttpServletResponse response)
             throws IOException, ServletException
     {
-        NewWebsiteForm form = (NewWebsiteForm)actionForm;
+        CreateWebsiteForm form = (CreateWebsiteForm)actionForm;
         ActionMessages msgs = new ActionMessages();
         ActionMessages errors = validate(form, new ActionErrors());
         if (!errors.isEmpty())
@@ -120,7 +120,7 @@
             //MainPageAction.flushMainPageCache();
             
             request.setAttribute("model", 
-                    new NewWebsitePageModel(request, response, mapping, website));                
+                    new CreateWebsitePageModel(request, response, mapping, website));                
         }
         catch (RollerException e)
         {
@@ -128,22 +128,22 @@
             saveErrors(request,errors);          
             mLogger.error("ERROR in createWebsite", e);
         }
-        ActionForward forward = mapping.findForward("newWebsiteDone.page");
+        ActionForward forward = mapping.findForward("createWebsiteDone.page");
         return forward;
     }
         
-    private ActionMessages validate(NewWebsiteForm form, ActionErrors errors)
+    private ActionMessages validate(CreateWebsiteForm form, ActionErrors errors)
     {
         return new ActionMessages();
     }
 
-    public static class NewWebsitePageModel extends BasePageModel
+    public static class CreateWebsitePageModel extends BasePageModel
     {
         private List themes; 
         private String contextURL = null;
         private String weblogURL = null;
         private String rssURL = null;
-        public NewWebsitePageModel(HttpServletRequest request,
+        public CreateWebsitePageModel(HttpServletRequest request,
                 HttpServletResponse response, ActionMapping mapping, WebsiteData wd)
         {
             super(request, response, mapping);

Modified: incubator/roller/branches/roller_2.0/src/org/roller/presentation/website/actions/InviteMemberAction.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_2.0/src/org/roller/presentation/website/actions/InviteMemberAction.java?rev=225579&r1=225578&r2=225579&view=diff
==============================================================================
--- incubator/roller/branches/roller_2.0/src/org/roller/presentation/website/actions/InviteMemberAction.java (original)
+++ incubator/roller/branches/roller_2.0/src/org/roller/presentation/website/actions/InviteMemberAction.java Wed Jul 27 12:09:35 2005
@@ -95,7 +95,8 @@
             }
             else
             {
-                umgr.inviteUser(website, user, PermissionsData.AUTHOR);
+                String mask = request.getParameter("permissionsMask");
+                umgr.inviteUser(website, user, Short.parseShort(mask));
                 // ROLLER_2.0: notify user by email of invitation
                 msgs.add(ActionMessages.GLOBAL_MESSAGE, 
                     new ActionMessage("inviteMembers.userInvited"));

Modified: incubator/roller/branches/roller_2.0/src/org/roller/presentation/website/actions/MemberPermissionsAction.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_2.0/src/org/roller/presentation/website/actions/MemberPermissionsAction.java?rev=225579&r1=225578&r2=225579&view=diff
==============================================================================
--- incubator/roller/branches/roller_2.0/src/org/roller/presentation/website/actions/MemberPermissionsAction.java (original)
+++ incubator/roller/branches/roller_2.0/src/org/roller/presentation/website/actions/MemberPermissionsAction.java Wed Jul 27 12:09:35 2005
@@ -1,8 +1,9 @@
 package org.roller.presentation.website.actions;
 
-import java.io.IOException;
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.List;
 
-import javax.servlet.ServletException;
 import javax.servlet.http.HttpServletRequest;
 import javax.servlet.http.HttpServletResponse;
 
@@ -12,11 +13,18 @@
 import org.apache.struts.action.ActionForward;
 import org.apache.struts.action.ActionMapping;
 import org.apache.struts.actions.DispatchAction;
+import org.roller.RollerException;
+import org.roller.model.Roller;
+import org.roller.model.RollerFactory;
+import org.roller.pojos.PermissionsData;
+import org.roller.pojos.WebsiteData;
+import org.roller.presentation.BasePageModel;
+import org.roller.presentation.RollerSession;
 
 /**
  * Allows website admin to change website member permissions.
  * 
- * @struts.action path="/editor/memberPermissions" parameter="method" 
+ * @struts.action path="/editor/memberPermissions" parameter="method" name="memberPermissionsForm"
  * @struts.action-forward name="memberPermissions.page" path="/website/MemberPermissions.jsp"
  */
 public class MemberPermissionsAction extends DispatchAction
@@ -44,8 +52,10 @@
             ActionForm          actionForm,
             HttpServletRequest  request,
             HttpServletResponse response)
-            throws IOException, ServletException
+            throws Exception
     {
+        request.setAttribute("model", 
+                new MemberPermissionsPageModel(request, response, mapping));
         ActionForward forward = mapping.findForward("memberPermissions.page");
         return forward;
     }
@@ -55,9 +65,49 @@
             ActionForm          actionForm,
             HttpServletRequest  request,
             HttpServletResponse response)
-            throws IOException, ServletException
+            throws Exception
     {
+        MemberPermissionsPageModel model = 
+            new MemberPermissionsPageModel(request, response, mapping);
+        Iterator iter = model.getPermissions().iterator();
+        while (iter.hasNext())
+        {
+            PermissionsData perms = (PermissionsData)iter.next();
+            String sval = request.getParameter("perm-" + perms.getId());
+            if (sval != null)
+            {
+                short val = Short.parseShort(sval);
+                if (val == -1) perms.remove();
+                else perms.setPermissionMask(val);
+                RollerFactory.getRoller().commit();
+            }
+        }
+        MemberPermissionsPageModel updatedModel = 
+            new MemberPermissionsPageModel(request, response, mapping);
+        request.setAttribute("model", updatedModel);
         ActionForward forward = mapping.findForward("memberPermissions.page");
         return forward;
     }
+    
+    public static class MemberPermissionsPageModel extends BasePageModel
+    {
+        private List permissions = new ArrayList();
+        public MemberPermissionsPageModel(HttpServletRequest request,
+          HttpServletResponse response, ActionMapping mapping) throws RollerException
+        {
+            super(request, response, mapping);
+            Roller roller = RollerFactory.getRoller();
+            RollerSession rollerSession = RollerSession.getRollerSession(request);
+            WebsiteData website = rollerSession.getCurrentWebsite();
+            permissions = roller.getUserManager().getAllPermissions(website);
+        }
+        public List getPermissions()
+        {
+            return permissions;
+        }
+        public void setWebsites(List permissions)
+        {
+            this.permissions = permissions;
+        }
+    }    
 }

Modified: incubator/roller/branches/roller_2.0/src/org/roller/presentation/website/actions/YourWebsitesAction.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_2.0/src/org/roller/presentation/website/actions/YourWebsitesAction.java?rev=225579&r1=225578&r2=225579&view=diff
==============================================================================
--- incubator/roller/branches/roller_2.0/src/org/roller/presentation/website/actions/YourWebsitesAction.java (original)
+++ incubator/roller/branches/roller_2.0/src/org/roller/presentation/website/actions/YourWebsitesAction.java Wed Jul 27 12:09:35 2005
@@ -95,7 +95,7 @@
         YourWebsitesForm form = (YourWebsitesForm)actionForm;
         Roller roller = RollerFactory.getRoller();
         PermissionsData perms = 
-            roller.getUserManager().retrievePermissionsData(form.getInviteId());
+            roller.getUserManager().retrievePermissions(form.getInviteId());
         
         perms.setPending(false);
         // ROLLER_2.0: notify inviter that invitee has accepted invitation  
@@ -117,7 +117,7 @@
         YourWebsitesForm form = (YourWebsitesForm)actionForm;
         Roller roller = RollerFactory.getRoller();
         PermissionsData perms = 
-            roller.getUserManager().retrievePermissionsData(form.getInviteId());
+            roller.getUserManager().retrievePermissions(form.getInviteId());
         
         perms.remove();
         // ROLLER_2.0: notify inviter that invitee has declined invitation  
@@ -128,10 +128,38 @@
         ActionForward forward = mapping.findForward("yourWebsites.page");
         return forward;
     }
+   
+    public ActionForward resign(
+            ActionMapping       mapping,
+            ActionForm          actionForm,
+            HttpServletRequest  request,
+            HttpServletResponse response)
+            throws Exception
+    {
+        YourWebsitesForm form = (YourWebsitesForm)actionForm;
+        Roller roller = RollerFactory.getRoller();
+        RollerSession rses = RollerSession.getRollerSession(request);
+        UserData user = rses.getAuthenticatedUser();
+        WebsiteData website = 
+            roller.getUserManager().retrieveWebsite(form.getWebsiteId());
+        PermissionsData perms = 
+            roller.getUserManager().getPermissions(website, user);
+        if (perms != null) 
+        {
+            // ROLLER_2.0: notify website members that user has resigned  
+            perms.remove();
+            roller.commit();
+        }
         
+        request.setAttribute("model",
+                new YourWebsitesPageModel(request, response, mapping));
+        ActionForward forward = mapping.findForward("yourWebsites.page");
+        return forward;
+    }
+    
     public static class YourWebsitesPageModel extends BasePageModel
     {
-        private List websites = new ArrayList();
+        private List permissions = new ArrayList();
         private List pendings = new ArrayList();
         public YourWebsitesPageModel(HttpServletRequest request,
           HttpServletResponse response, ActionMapping mapping) throws RollerException
@@ -140,16 +168,16 @@
             Roller roller = RollerFactory.getRoller();
             RollerSession rollerSession = RollerSession.getRollerSession(request);
             UserData user = rollerSession.getAuthenticatedUser();
-            websites = roller.getUserManager().getWebsites(user, Boolean.TRUE);
+            permissions = roller.getUserManager().getAllPermissions(user);
             pendings = roller.getUserManager().getPendingPermissions(user);
         }
-        public List getWebsites()
+        public List getPermissions()
         {
-            return websites;
+            return permissions;
         }
-        public void setWebsites(List websitePermissions)
+        public void setPermissions(List permissions)
         {
-            this.websites = websitePermissions;
+            this.permissions = permissions;
         }
         public List getPendings()
         {

Copied: incubator/roller/branches/roller_2.0/src/org/roller/presentation/website/formbeans/CreateWebsiteForm.java (from r225230, incubator/roller/branches/roller_2.0/src/org/roller/presentation/website/formbeans/NewWebsiteForm.java)
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_2.0/src/org/roller/presentation/website/formbeans/CreateWebsiteForm.java?p2=incubator/roller/branches/roller_2.0/src/org/roller/presentation/website/formbeans/CreateWebsiteForm.java&p1=incubator/roller/branches/roller_2.0/src/org/roller/presentation/website/formbeans/NewWebsiteForm.java&r1=225230&r2=225579&rev=225579&view=diff
==============================================================================
--- incubator/roller/branches/roller_2.0/src/org/roller/presentation/website/formbeans/NewWebsiteForm.java (original)
+++ incubator/roller/branches/roller_2.0/src/org/roller/presentation/website/formbeans/CreateWebsiteForm.java Wed Jul 27 12:09:35 2005
@@ -6,20 +6,20 @@
 import org.roller.pojos.WebsiteData;
 
 /**
- * @struts.form name="newWebsiteForm"
+ * @struts.form name="createWebsiteForm"
  * @author Dave M Johnson
  */
-public class NewWebsiteForm extends ActionForm
+public class CreateWebsiteForm extends ActionForm
 {
     private String handle;
     private String name;
     private String description;
     private String emailAddress;
     private String locale;
-    private String timezone;
+    private String timeZone;
     private String theme;
     
-    public NewWebsiteForm()
+    public CreateWebsiteForm()
     {
         
     }
@@ -73,11 +73,11 @@
     }
     public String getTimeZone()
     {
-        return timezone;
+        return timeZone;
     }
-    public void setTimeZone(String timezone)
+    public void setTimeZone(String timeZone)
     {
-        this.timezone = timezone;
+        this.timeZone = timeZone;
     }
     
     /**
@@ -90,6 +90,6 @@
         wd.setName(name);
         wd.setDescription(description);
         wd.setLocale(this.locale);
-        wd.setTimezone(timezone);
+        wd.setTimezone(timeZone);
     }
 }

Added: incubator/roller/branches/roller_2.0/src/org/roller/presentation/website/formbeans/MemberPermissionsForm.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_2.0/src/org/roller/presentation/website/formbeans/MemberPermissionsForm.java?rev=225579&view=auto
==============================================================================
--- incubator/roller/branches/roller_2.0/src/org/roller/presentation/website/formbeans/MemberPermissionsForm.java (added)
+++ incubator/roller/branches/roller_2.0/src/org/roller/presentation/website/formbeans/MemberPermissionsForm.java Wed Jul 27 12:09:35 2005
@@ -0,0 +1,20 @@
+package org.roller.presentation.website.formbeans;
+
+import org.apache.struts.action.ActionForm;
+
+/**
+ * @struts.form name="memberPermissionsForm"
+ * @author Dave M Johnson
+ */
+public class MemberPermissionsForm extends ActionForm
+{
+    private String websiteId; 
+    public String getWebsiteId()
+    {
+        return websiteId;
+    }
+    public void setWebsiteId(String websiteId)
+    {
+        this.websiteId = websiteId;
+    }
+}

Modified: incubator/roller/branches/roller_2.0/web/WEB-INF/classes/ApplicationResources.properties
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_2.0/web/WEB-INF/classes/ApplicationResources.properties?rev=225579&r1=225578&r2=225579&view=diff
==============================================================================
--- incubator/roller/branches/roller_2.0/web/WEB-INF/classes/ApplicationResources.properties (original)
+++ incubator/roller/branches/roller_2.0/web/WEB-INF/classes/ApplicationResources.properties Wed Jul 27 12:09:35 2005
@@ -166,6 +166,20 @@
 
 configForm.saved=Configuration settings saved
 
+# ------------------------------------------------------------------- Create website
+
+createWebsite.title=Create Website
+createWebsite.description=Create a new website by specifying handle, name, title, timezone/locale information and theme to be used.
+createWebsite.handle=Handle
+createWebsite.name=Name
+createWebsite.description=Description
+createWebsite.emailAddress=Email Address
+createWebsite.locale=Locale
+createWebsite.timeZone=Timezone
+createWebsite.theme=Theme
+
+createWebsite.button.save=Create
+
 # ------------------------------------------------------------------- Comment emails
 
 email.comment.wrote=wrote
@@ -306,6 +320,17 @@
 footer.macros=Macros
 footer.mailingLists=Mailing Lists
 
+# ------------------------------------------------------------------- Invite member
+
+inviteMember.title=Invite New Member
+inviteMember.description=You can invite any user to join this website
+inviteMember.userName=Username of user to be invited
+inviteMember.adminstrator=Admin
+inviteMember.author=Author
+inviteMember.limited=Limited
+
+inviteMember.button.save=Send invitation
+
 # --------------------------------------------------------------------------- Login
 
 loginPage.userName=Username
@@ -411,6 +436,18 @@
 maintenance.message.indexed=Successully scheduled search index rebuild for your Roller Website
 maintenance.message.flushed=Successfully flushed the page cache of your Roller Website
 
+# --------------------------------------------------------------- Member permissions
+
+memberPermissions.title=Website Member Permissions
+memberPermissions.description=You can change permissions of website members, or remove them from the website.
+memberPermissions.userName=Username
+memberPermissions.administrator=Admin
+memberPermissions.author=Author
+memberPermissions.limited=Limited
+memberPermissions.remove=Remove
+
+memberPermissions.button.save=Save
+
 # ------------------------------------------------------------ New user registation
 
 newUser.addNewUser=New User Registration
@@ -420,7 +457,7 @@
 newuser.eMailAddress=Email Address
 newuser.theme=Theme
 newuser.locale=Locale
-newuser.timezone=Time Zone
+newuser.timeZone=Time Zone
 newUser.created=New user successfully created. Create another?
 newUser.error.mismatchedPasswords=ERROR: passwords to not match
 
@@ -654,9 +691,9 @@
 # ---------------------------------------------------------------------- Tabbed Menu
 
 tabbedmenu.main=Main
-tabbedmenu.website.user=Your profile
-tabbedmenu.user.websites=Your websites
-tabbedmenu.newWebsite=New website
+tabbedmenu.website.user=Your Profile
+tabbedmenu.user.websites=Your Websites
+tabbedmenu.createWebsite=Create Website
 
 tabbedmenu.weblog=Weblog
 tabbedmenu.weblog.newEntry=New Entry
@@ -753,7 +790,7 @@
 userSettings.passwordConfirm=Password (Confirm)
 userSettings.email=Email
 userSettings.locale=Locale
-userSettings.timezone=Timezone
+userSettings.timeZone=Timezone
 userSettings.save=Save
 userSettings.cookieLogin=You cannot passwords when logging in with the <strong>Remember Me</strong> feature.  Please logout and log back in to change passwords.
 userSettings.passwordResetError=Password was not reset. Password fields did not match?
@@ -944,4 +981,26 @@
 welcome.rssAddressIs=Your main newsfeed address is
 welcome.clickHere=Click here
 welcome.toLoginAndPost=to login and post your first Weblog entry.
+
+# -------------------------------------------------------------------- Your profile
+
+yourProfile.title=Your Profile
+yourProfile.description=You can change your username, email and password here.
+
+yourProfile.button.save=Save
+
+# ------------------------------------------------------------------- Your websites
+
+yourWebsites.title=Your Websites
+yourWebsites.description=These are the websites of which you are a member. You may select one and it will become your current website. If you would like to end your membership, you may resign.
+yourWebsites.invited=You've been invited to join the website
+yourWebsites.accept=accept
+yourWebsites.decline=decline
+
+yourWebsites.tableTitle=Title
+yourWebsites.escription=Description
+yourWebsites.permissions=Permissions
+yourWebsites.select=Select
+yourWebsites.resign=Resign
+yourWebsites.confirmResignation=Are you sure you wish to resign from website
 

Modified: incubator/roller/branches/roller_2.0/web/WEB-INF/classes/ApplicationResources_is.properties
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_2.0/web/WEB-INF/classes/ApplicationResources_is.properties?rev=225579&r1=225578&r2=225579&view=diff
==============================================================================
--- incubator/roller/branches/roller_2.0/web/WEB-INF/classes/ApplicationResources_is.properties (original)
+++ incubator/roller/branches/roller_2.0/web/WEB-INF/classes/ApplicationResources_is.properties Wed Jul 27 12:09:35 2005
@@ -311,7 +311,7 @@
 newuser.eMailAddress=Tölvupóstfang
 newuser.theme=Stílsnið
 newuser.locale=Staðsetning
-newuser.timezone=Tímabelti
+newuser.timeZone=Tímabelti
 newUser.created=Nýr notandi búinn til. Annan?
 newUser.error.mismatchedPasswords=VILLA: lykilorðin eru ekki eins
 
@@ -467,7 +467,7 @@
 userSettings.passwordConfirm=Lykilorð (staðfesta)
 userSettings.email=Tölvupóstfang
 userSettings.locale=Staðsetning
-userSettings.timezone=Tímabelti
+userSettings.timeZone=Tímabelti
 userSettings.save=Vista
 userSettings.cookieLogin=Ekki er hægt að breyta lykilorði þegar <strong>'mundu mig'</strong> er virkt.  Vinsamlegast skráðu þig út og aftur inn til að breyta lykilorðinu.
 userSettings.passwordResetError=Lykilorðið var ekki uppfært. Voru báðir reitir eins?

Modified: incubator/roller/branches/roller_2.0/web/WEB-INF/classes/ApplicationResources_ja_JP.properties
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_2.0/web/WEB-INF/classes/ApplicationResources_ja_JP.properties?rev=225579&r1=225578&r2=225579&view=diff
==============================================================================
--- incubator/roller/branches/roller_2.0/web/WEB-INF/classes/ApplicationResources_ja_JP.properties (original)
+++ incubator/roller/branches/roller_2.0/web/WEB-INF/classes/ApplicationResources_ja_JP.properties Wed Jul 27 12:09:35 2005
@@ -302,7 +302,7 @@
 newuser.eMailAddress=Email\u30a2\u30c9\u30ec\u30b9
 newuser.theme=\u4f7f\u7528\u30c6\u30fc\u30de
 newuser.locale=\u30ed\u30b1\u30fc\u30eb
-newuser.timezone=\u30bf\u30a4\u30e0\u30be\u30fc\u30f3
+newuser.timeZone=\u30bf\u30a4\u30e0\u30be\u30fc\u30f3
 newUser.created=\u65b0\u898f\u30e6\u30fc\u30b6\u304c\u767b\u9332\u3055\u308c\u307e\u3057\u305f\u3002\u7d9a\u3051\u3066\u767b\u9332\u3057\u307e\u3059\u304b\uff1f
 
 # ------------------------------------------------------------ Navigation Bar
@@ -457,7 +457,7 @@
 userSettings.passwordConfirm=\u30d1\u30b9\u30ef\u30fc\u30c9 (\u78ba\u8a8d)
 userSettings.email=Email
 userSettings.locale=\u30ed\u30b1\u30fc\u30eb
-userSettings.timezone=\u30bf\u30a4\u30e0\u30be\u30fc\u30f3
+userSettings.timeZone=\u30bf\u30a4\u30e0\u30be\u30fc\u30f3
 userSettings.save=\u4fdd\u5b58
 userSettings.cookieLogin=\u3053\u3053\u3067\u306f <strong>\u30ed\u30b0\u30a4\u30f3\u60c5\u5831\u3092\u8a18\u61b6</strong> \u3067\u8a18\u61b6\u3055\u308c\u305f\u30d1\u30b9\u30ef\u30fc\u30c9\u306f\u4f7f\u3048\u307e\u305b\u3093\u3002\u4e00\u5ea6\u30ed\u30b0\u30a2\u30a6\u30c8\u3057\u3066\uff0c\u9055\u3046\u30d1\u30b9\u30ef\u30fc\u30c9\u3067\u30ed\u30b0\u30a4\u30f3\u3057\u76f4\u3057\u3066\u304f\u3060\u3055\u3044\u3002
 userSettings.passwordResetError=\u30d1\u30b9\u30ef\u30fc\u30c9\u306f\u30ea\u30bb\u30c3\u30c8\u3055\u308c\u3066\u3044\u307e\u305b\u3093\u3002\u30d1\u30b9\u30ef\u30fc\u30c9\u30d5\u30a3\u30fc\u30eb\u30c9\u304c\u4e00\u81f4\u3057\u3066\u3044\u306a\u3044\u306e\u304b\u3082\u77e5\u308c\u307e\u305b\u3093\u3002

Modified: incubator/roller/branches/roller_2.0/web/WEB-INF/classes/ApplicationResources_nl.properties
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_2.0/web/WEB-INF/classes/ApplicationResources_nl.properties?rev=225579&r1=225578&r2=225579&view=diff
==============================================================================
--- incubator/roller/branches/roller_2.0/web/WEB-INF/classes/ApplicationResources_nl.properties (original)
+++ incubator/roller/branches/roller_2.0/web/WEB-INF/classes/ApplicationResources_nl.properties Wed Jul 27 12:09:35 2005
@@ -290,7 +290,7 @@
 newuser.eMailAddress=Email adres
 newuser.theme=Thema
 newuser.locale=Taal/land
-newuser.timezone=Tijdszone
+newuser.timeZone=Tijdszone
 
 # ------------------------------------------------------------ Navigation Bar
 
@@ -425,7 +425,7 @@
 userSettings.password=Wachtwoord
 userSettings.email=Email
 userSettings.locale=Locale
-userSettings.timezone=Tijdszone
+userSettings.timeZone=Tijdszone
 userSettings.save=Bewaren
 userSettings.cookieLogin=Je kunt je wachtwoord niet wijzigen als je inlogd met de <strong>Bewaar gegevens</strong> optie.  Log uti en log weer in om je wachtwoord te wijzigen.
 

Modified: incubator/roller/branches/roller_2.0/web/WEB-INF/classes/ApplicationResources_zh_TW.properties
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_2.0/web/WEB-INF/classes/ApplicationResources_zh_TW.properties?rev=225579&r1=225578&r2=225579&view=diff
==============================================================================
--- incubator/roller/branches/roller_2.0/web/WEB-INF/classes/ApplicationResources_zh_TW.properties (original)
+++ incubator/roller/branches/roller_2.0/web/WEB-INF/classes/ApplicationResources_zh_TW.properties Wed Jul 27 12:09:35 2005
@@ -306,7 +306,7 @@
 newuser.eMailAddress=\u96fb\u5b50\u90f5\u4ef6\u5730\u5740
 newuser.theme=\u4e3b\u984c\u4f48\u666f
 newuser.locale=\u5730\u5340\u8207\u8a9e\u8a00\u8a2d\u5b9a
-newuser.timezone=\u6642\u5340
+newuser.timeZone=\u6642\u5340
 
 # ------------------------------------------------------------ Navigation Bar
 
@@ -448,7 +448,7 @@
 userSettings.password=\u5bc6\u78bc
 userSettings.email=Email
 userSettings.locale=\u5730\u5340\u8207\u8a9e\u8a00\u8a2d\u5b9a
-userSettings.timezone=\u6642\u5340
+userSettings.timeZone=\u6642\u5340
 userSettings.save=\u5b58\u6a94
 userSettings.cookieLogin=\u7576\u60a8\u767b\u5165\u6642\u958b\u555f\u4e86<strong> "\u8a18\u4f4f\u6211" </strong> \u9019\u9805\u529f\u80fd\u6642\uff0c\u60a8\u7121\u6cd5\u66f4\u6539\u5bc6\u78bc\uff0c\u8acb\u767b\u51fa\u518d\u767b\u5165\u4ee5\u4fee\u6539\u5bc6\u78bc(\u8acb\u5148\u95dc\u9589"\u8a18\u4f4f\u6211"\u529f\u80fd)
 

Modified: incubator/roller/branches/roller_2.0/web/WEB-INF/editor-menu.xml
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_2.0/web/WEB-INF/editor-menu.xml?rev=225579&r1=225578&r2=225579&view=diff
==============================================================================
--- incubator/roller/branches/roller_2.0/web/WEB-INF/editor-menu.xml (original)
+++ incubator/roller/branches/roller_2.0/web/WEB-INF/editor-menu.xml Wed Jul 27 12:09:35 2005
@@ -34,7 +34,7 @@
         <menu-item forward="yourWebsites" name="tabbedmenu.user.websites"
                                           perms="any"
                                           roles="editor,admin" />
-        <menu-item forward="newWebsite"   name="tabbedmenu.newWebsite"
+        <menu-item forward="createWebsite"   name="tabbedmenu.createWebsite"
                                           perms="any"
                                           roles="editor,admin" />
     </menu>

Copied: incubator/roller/branches/roller_2.0/web/website/CreateWebsite.jsp (from r225383, incubator/roller/branches/roller_2.0/web/website/NewWebsite.jsp)
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_2.0/web/website/CreateWebsite.jsp?p2=incubator/roller/branches/roller_2.0/web/website/CreateWebsite.jsp&p1=incubator/roller/branches/roller_2.0/web/website/NewWebsite.jsp&r1=225383&r2=225579&rev=225579&view=diff
==============================================================================
--- incubator/roller/branches/roller_2.0/web/website/NewWebsite.jsp (original)
+++ incubator/roller/branches/roller_2.0/web/website/CreateWebsite.jsp Wed Jul 27 12:09:35 2005
@@ -1,46 +1,46 @@
 <%@ include file="/taglibs.jsp" %><%@ include file="/theme/header.jsp" %>
 
-<h1><fmt:message key="newWebsite.title" /></h1>
+<h1><fmt:message key="createWebsite.title" /></h1>
 
 <br /> 
-<html:form action="/editor/newWebsite" method="post" focus="handle">
+<html:form action="/editor/createWebsite" method="post" focus="handle">
 
     <div class="formrow">
-       <label for="handle" class="formrow" /><fmt:message key="newWebsite.handle" /></label>
+       <label for="handle" class="formrow" /><fmt:message key="createWebsite.handle" /></label>
        <html:text property="handle" size="30" maxlength="30" />
     </div>
     
     <div class="formrow">
-       <label for="name" class="formrow" /><fmt:message key="newWebsite.name" /></label>
+       <label for="name" class="formrow" /><fmt:message key="createWebsite.name" /></label>
        <html:text property="name" size="30" maxlength="30" />
     </div>
     
     <div class="formrow">
-       <label for="description" class="formrow" /><fmt:message key="newWebsite.description" /></label>
+       <label for="description" class="formrow" /><fmt:message key="createWebsite.description" /></label>
        <html:text property="description" size="30" maxlength="30" />
     </div>   
      
     <div class="formrow">
-       <label for="emailAddress" class="formrow" /><fmt:message key="newWebsite.emailAddress" /></label>
+       <label for="emailAddress" class="formrow" /><fmt:message key="createWebsite.emailAddress" /></label>
        <html:text property="emailAddress" size="30" maxlength="30" />
     </div>
     
     <div class="formrow">
-       <label for="locale" class="formrow" /><fmt:message key="userSettings.locale" /></label>
+       <label for="locale" class="formrow" /><fmt:message key="createWebsite.locale" /></label>
        <html:select property="locale" size="1" >
           <html:options collection="locales" property="value" labelProperty="label"/>
        </html:select>
     </div>
     
     <div class="formrow">
-       <label for="timeZone" class="formrow" /><fmt:message key="userSettings.timezone" /></label>
+       <label for="timeZone" class="formrow" /><fmt:message key="createWebsite.timeZone" /></label>
        <html:select property="timeZone" size="1" >
-           <html:options collection="timezones" property="value" labelProperty="label"/>
+           <html:options collection="timeZones" property="value" labelProperty="label"/>
        </html:select>
     </div>
     
     <div class="formrow">
-       <label for="theme" class="formrow" /><fmt:message key="newuser.theme" /></label>
+       <label for="theme" class="formrow" /><fmt:message key="createWebsite.theme" /></label>
        <html:select property="theme" size="1" onchange="previewImage(this[selectedIndex].value)">
            <html:options name="model" property="themes" />
        </html:select>
@@ -53,7 +53,7 @@
     </div>    
     
     <div class="control">
-       <html:submit /></input>
+       <input type="submit" value='<fmt:message key="createWebsite.button.save" />'></input>
     </div>
     
 </html:form>

Modified: incubator/roller/branches/roller_2.0/web/website/InviteMember.jsp
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_2.0/web/website/InviteMember.jsp?rev=225579&r1=225578&r2=225579&view=diff
==============================================================================
--- incubator/roller/branches/roller_2.0/web/website/InviteMember.jsp (original)
+++ incubator/roller/branches/roller_2.0/web/website/InviteMember.jsp Wed Jul 27 12:09:35 2005
@@ -2,15 +2,28 @@
 
 <h1><fmt:message key="inviteMember.title" /></h1>
 
+<p><fmt:message key="inviteMember.description" /></p>
+
 <html:form action="/editor/inviteMember" method="post" focus="handle">
 
     <div class="formrow">
        <label for="userName" class="formrow" /><fmt:message key="inviteMember.userName" /></label>
        <html:text property="userName" size="30" maxlength="30" />
+    </div>    
+    
+    <div class="formrow">
+       <label for="userName" class="formrow" /><fmt:message key="inviteMember.userName" /></label>
+       <input type="radio" name="permissionsMask" value="3"  />
+       <fmt:message key="inviteMember.administrator" />
+       <input type="radio" name="permissionsMask" value="1" checked />
+       <fmt:message key="inviteMember.author" />
+       <input type="radio" name="permissionsMask" value="0" />
+       <fmt:message key="inviteMember.limited" />
     </div>
-
+                  
+    <br />      
     <div class="control">
-       <html:submit /></input>
+       <input type="submit" value='<fmt:message key="inviteMember.button.save" />'></input>
     </div>
     
 </html:form>

Added: incubator/roller/branches/roller_2.0/web/website/MemberPermissions.jsp
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_2.0/web/website/MemberPermissions.jsp?rev=225579&view=auto
==============================================================================
--- incubator/roller/branches/roller_2.0/web/website/MemberPermissions.jsp (added)
+++ incubator/roller/branches/roller_2.0/web/website/MemberPermissions.jsp Wed Jul 27 12:09:35 2005
@@ -0,0 +1,64 @@
+<%@ include file="/taglibs.jsp" %><%@ include file="/theme/header.jsp" %>
+
+<h1><fmt:message key="memberPermissions.title" /></h1>
+
+<p><fmt:message key="memberPermissions.description" /></p>
+
+<html:form action="/editor/memberPermissions" method="post" focus="handle">
+    <html:hidden property="websiteId" />
+    
+    <table class="rollertable">
+        <tr class="rHeaderTr">
+           <th class="rollertable" width="20%">
+               <fmt:message key="memberPermissions.userName" />
+           </th>
+           <th class="rollertable" width="20%">
+               <fmt:message key="memberPermissions.administrator" />
+           </th>
+           <th class="rollertable" width="20%">
+               <fmt:message key="memberPermissions.author" />
+           </th>
+           <th class="rollertable" width="20%">
+               <fmt:message key="memberPermissions.limited" />
+           </th>
+           <th class="rollertable" width="20%">
+               <fmt:message key="memberPermissions.remove" />
+           </th>
+        </tr>
+        <c:forEach var="permission" items="${model.permissions}">
+            <roller:row oddStyleClass="rollertable_odd" evenStyleClass="rollertable_even">                       
+                <td class="rollertable">
+	                <c:out value="${permission.user.userName}" />
+                </td>               
+                <td class="rollertable">
+                    <input type="radio" 
+                        <c:if test="${permission.permissionMask == 3}">checked</c:if>
+                        name='perm-<c:out value="${permission.id}" />' value="3" />
+                </td>
+                <td class="rollertable">
+	                <input type="radio" 
+                        <c:if test="${permission.permissionMask == 1}">checked</c:if>
+                        name='perm-<c:out value="${permission.id}" />' value="1" />
+                </td>                
+                <td class="rollertable">
+                    <input type="radio" 
+                        <c:if test="${permission.permissionMask == 0}">checked</c:if>
+                        name='perm-<c:out value="${permission.id}" />' value="0" />
+                </td>                
+                <td class="rollertable">
+                    <input type="radio" 
+                        name='perm-<c:out value="${permission.id}" />' value="-1" />
+                </td>
+           </roller:row>
+       </c:forEach>
+    </table>
+        
+    <div class="control">
+       <input type="submit" value='<fmt:message key="memberPermissions.button.save" />'></input>
+    </div>
+    
+</html:form>
+    
+<%@ include file="/theme/footer.jsp" %>
+
+

Modified: incubator/roller/branches/roller_2.0/web/website/UserNew.jsp
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_2.0/web/website/UserNew.jsp?rev=225579&r1=225578&r2=225579&view=diff
==============================================================================
--- incubator/roller/branches/roller_2.0/web/website/UserNew.jsp (original)
+++ incubator/roller/branches/roller_2.0/web/website/UserNew.jsp Wed Jul 27 12:09:35 2005
@@ -58,9 +58,9 @@
     </div>
 
     <div class="formrow">
-       <label for="timeZone" class="formrow" /><fmt:message key="userSettings.timezone" /></label>
+       <label for="timeZone" class="formrow" /><fmt:message key="userSettings.timeZone" /></label>
        <html:select property="timeZone" size="1" >
-           <html:options collection="timezones" property="value" labelProperty="label"/>
+           <html:options collection="timeZones" property="value" labelProperty="label"/>
        </html:select>
     </div>
     <br />

Modified: incubator/roller/branches/roller_2.0/web/website/YourProfile.jsp
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_2.0/web/website/YourProfile.jsp?rev=225579&r1=225578&r2=225579&view=diff
==============================================================================
--- incubator/roller/branches/roller_2.0/web/website/YourProfile.jsp (original)
+++ incubator/roller/branches/roller_2.0/web/website/YourProfile.jsp Wed Jul 27 12:09:35 2005
@@ -2,6 +2,8 @@
 
 <h1><fmt:message key="yourProfile.title" /></h1>
 
+<p><fmt:message key="yourProfile.description" /></p>
+
 <br /> 
 <html:form action="/editor/yourProfile" method="post" focus="fullName">
     <html:hidden property="method" value="save"/></input>
@@ -41,13 +43,13 @@
     <div class="formrow">
        <label for="timeZone" class="formrow" /><fmt:message key="userSettings.timeZone" /></label>
        <html:select property="timeZone" size="1" >
-           <html:options collection="timezones" property="value" labelProperty="label"/>
+           <html:options collection="timeZones" property="value" labelProperty="label"/>
        </html:select>
     </div>
 
-    <br />
+    <br />      
     <div class="control">
-       <input type="submit" value='<fmt:message key="userSettings.save" />' /></input>
+       <input type="submit" value='<fmt:message key="yourProfile.button.save" />'></input>
     </div>
     
 </html:form>

Modified: incubator/roller/branches/roller_2.0/web/website/YourWebsites.jsp
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_2.0/web/website/YourWebsites.jsp?rev=225579&r1=225578&r2=225579&view=diff
==============================================================================
--- incubator/roller/branches/roller_2.0/web/website/YourWebsites.jsp (original)
+++ incubator/roller/branches/roller_2.0/web/website/YourWebsites.jsp Wed Jul 27 12:09:35 2005
@@ -1,7 +1,5 @@
 <%@ include file="/taglibs.jsp" %><%@ include file="/theme/header.jsp" %>
 
-<h1><fmt:message key="yourWebsites.title" /></h1>
-    
 <script type="text/javascript">
 <!--
 function selectWebsite(id) 
@@ -21,35 +19,85 @@
     document.yourWebsitesForm.inviteId.value = id;
     document.yourWebsitesForm.submit();
 } 
+function resignWebsite(id,handle)
+{
+    if (confirm('<fmt:message key="yourWebsites.confirmResignation" /> [' + handle +"] ?"))
+    {
+        document.yourWebsitesForm.method.value = "resign";
+        document.yourWebsitesForm.websiteId.value = id;
+        document.yourWebsitesForm.submit();
+    }
+}
 -->
 </script>
 
+<h1><fmt:message key="yourWebsites.title" /></h1>
+    
+<p><fmt:message key="yourWebsites.description" /></p>
+
 <html:form action="/editor/yourWebsites" method="post">
     <input type="hidden" name="inviteId" value="" />
     <input type="hidden" name="websiteId" value="" />
     <input type="hidden" name="method" value="select" />		  
 
     <c:if test="${!empty model.pendings}">
-        <fmt:message key="yourWebsites.invitations" /><br />
-	    <c:forEach var="invite" items="${model.pendings}">
-            <c:out value="${invite.website.handle}" />
-            <a href='javascript:acceptInvite("<c:out value='${invite.id}'/>")'>
-                <fmt:message key="yourWebsites.accept" />
-            </a> 
-            &nbsp;|&nbsp;
-            <a href='javascript:acceptInvite("<c:out value='${invite.id}'/>")'>
-                <fmt:message key="yourWebsites.decline" />
-            </a><br />
-	    </c:forEach>
+        <div class="messages">
+		    <c:forEach var="invite" items="${model.pendings}">
+	            <c:out value="${invite.website.handle}" />
+	            <a href='javascript:acceptInvite("<c:out value='${invite.id}'/>")'>
+	                <fmt:message key="yourWebsites.accept" />
+	            </a> 
+	            &nbsp;|&nbsp;
+	            <a href='javascript:acceptInvite("<c:out value='${invite.id}'/>")'>
+	                <fmt:message key="yourWebsites.decline" />
+	            </a><br />
+		    </c:forEach>
+        </div>
     </c:if>
-
-    <p><fmt:message key="yourWebsites.websites" /></p>
-    <c:forEach var="website" items="${model.websites}">
-        <a href='javascript:selectWebsite("<c:out value='${website.id}'/>")'>
-            <c:out value="${website.handle}" /><br />
-        </a>
-    </c:forEach>
-
+    
+    <table class="rollertable">
+        <tr class="rHeaderTr">
+           <th class="rollertable" width="20%">
+               <fmt:message key="yourWebsites.tableTitle" />
+           </th>
+           <th class="rollertable" width="20%">
+               <fmt:message key="yourWebsites.tableDescription" />
+           </th>
+           <th class="rollertable" width="20%">
+               <fmt:message key="yourWebsites.permissions" />
+           </th>
+           <th class="rollertable" width="20%">
+               <fmt:message key="yourWebsites.select" />
+           </th>
+           <th class="rollertable" width="20%">
+               <fmt:message key="yourWebsites.resign" />
+           </th>
+        </tr>
+        <c:forEach var="perms" items="${model.permissions}">
+            <roller:row oddStyleClass="rollertable_odd" evenStyleClass="rollertable_even">  
+               <td class="rollertable">
+                   <c:out value="${perms.website.name}" />
+               </td>
+               <td class="rollertable">
+                   <c:out value="${perms.website.description}" />
+               </td>
+               <td class="rollertable">
+                   <c:out value="${perms.permissionMask}" />
+               </td>
+               <td class="rollertable">
+                   <a href='javascript:selectWebsite("<c:out value='${perms.website.id}'/>")'>
+                       <fmt:message key="yourWebsites.select" />
+                   </a>
+               </td>
+               <td class="rollertable">
+                   <a href='javascript:resignWebsite("<c:out value='${perms.website.id}'/>","<c:out value="${perms.website.handle}" />")'>
+                       <fmt:message key="yourWebsites.resign" />
+                   </a>
+               </td>
+            </roller:row>
+        </c:forEach>
+    </table>
+    
 </html:form>
 
 <%@ include file="/theme/footer.jsp" %>

Modified: incubator/roller/branches/roller_2.0/web/website/edit-website.jsp
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_2.0/web/website/edit-website.jsp?rev=225579&r1=225578&r2=225579&view=diff
==============================================================================
--- incubator/roller/branches/roller_2.0/web/website/edit-website.jsp (original)
+++ incubator/roller/branches/roller_2.0/web/website/edit-website.jsp Wed Jul 27 12:09:35 2005
@@ -9,7 +9,7 @@
     <html:hidden property="id"/></input>
     <html:hidden property="weblogDayPageId" />
     <html:hidden property="locale"/></input>
-    <html:hidden property="timezone"/></input>
+    <html:hidden property="timeZone"/></input>
     <html:hidden property="editorTheme"/></input>
     <html:hidden property="isEnabled"/></input>
 



Mime
View raw message