Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Documentation
  • Loading branch information
rog13002 committed Dec 9, 2015
1 parent 14520f4 commit 861e393
Show file tree
Hide file tree
Showing 3 changed files with 31 additions and 2 deletions.
9 changes: 8 additions & 1 deletion rapla/src/org/rapla/RaplaResources.xml
Expand Up @@ -2759,7 +2759,8 @@ See French text.
<text lang="pt">Evento</text>
<text lang="fi">Tapahtuma</text>
</entry>
<entry key="event">

<entry key="event">
<text lang="en">Event</text>
<text lang="de">Veranstaltung</text>
<text lang="fr">Événement</text>
Expand All @@ -2770,6 +2771,7 @@ See French text.
<text lang="pt">Evento</text>
<text lang="fi">Tapahtuma</text>
</entry>

<entry key="new_reservation">
<text lang="en">New Event...</text>
<text lang="de">Neue Veranstaltung</text>
Expand All @@ -2781,6 +2783,7 @@ See French text.
<text lang="pt">Novo evento</text>
<text lang="fi">Uusi tapahtuma...</text>
</entry>
</entry>

<entry key="eventname">
<text lang="en">eventname</text>
Expand Down Expand Up @@ -2828,6 +2831,10 @@ See French text.
<text lang="pt">Tipo de evento</text>
<text lang="fi">Tapahtumatyyppi</text>
</entry>
</entry>
<entry key= "subEvent_type">
<text lang="en">Sub - Event Type</text>

<entry key="edit_reservations">
<text lang="en">Edit own</text>
<text lang="de">eigene bearbeiten</text>
Expand Down
Expand Up @@ -12,17 +12,22 @@
*--------------------------------------------------------------------------*/
package org.rapla.entities.dynamictype;

// This class holds all of strings for the program
public interface DynamicTypeAnnotations
{
String KEY_NAME_FORMAT="nameformat";
String KEY_NAME_FORMAT_PLANNING="nameformat_planning";
String KEY_NAME_FORMAT_EXPORT="nameformat_export";

// This section contains strings that are applied to the organization of the calendar
String KEY_CLASSIFICATION_TYPE="classification-type";
String VALUE_CLASSIFICATION_TYPE_RESOURCE="resource";
String VALUE_CLASSIFICATION_TYPE_RESERVATION="reservation";
String VALUE_CLASSIFICATION_TYPE_PERSON="person";
String VALUE_CLASSIFICATION_TYPE_RAPLATYPE="rapla";
//Added enhancement, Creates a sub-Event string to be added to the calendar
// Our enhancement is added in this section, due to its organizational purposes
String VALUE_CLASSIFICATION_TYPE_SUBEVENT="subEvent";

String KEY_COLORS="colors";
String VALUE_COLORS_AUTOMATED = "rapla:automated";
Expand All @@ -39,6 +44,9 @@ public interface DynamicTypeAnnotations
String VALUE_TRANSFERED_TO_CLIENT_NEVER = "never";

String KEY_LOCATION="location";



}


Expand Down
16 changes: 15 additions & 1 deletion rapla/src/org/rapla/gui/internal/MenuFactoryImpl.java
Expand Up @@ -58,6 +58,9 @@ import org.rapla.gui.toolkit.MenuInterface;
import org.rapla.gui.toolkit.RaplaMenuItem;
import org.rapla.gui.toolkit.RaplaSeparator;


// This class controls most of the functioning in the program
// This is where we added part of our enhancement
public class MenuFactoryImpl extends RaplaGUIComponent implements MenuFactory
{
public void addReservationWizards( MenuInterface menu, MenuContext context, String afterId ) throws RaplaException
Expand Down Expand Up @@ -220,6 +223,7 @@ public class MenuFactoryImpl extends RaplaGUIComponent implements MenuFactory
addAllocatableMenuNew( menu, parent,p, focusedObject);
}
}
// This controls what is displayed when you right click the headings on the left side of the calendar
if ( isAdmin() )
{
boolean reservationNodeContext = reservationType || (focusedObject!= null && focusedObject.equals( getString("reservation_type" )));
Expand All @@ -237,25 +241,35 @@ public class MenuFactoryImpl extends RaplaGUIComponent implements MenuFactory
{
addUserMenuNew( menu , parent, p);
}

// Creates the menu tab of the new event and person under the parent type
if (allocatableNodeContext)
{
addTypeMenuNew(menu, DynamicTypeAnnotations.VALUE_CLASSIFICATION_TYPE_RESOURCE,parent, p);
addTypeMenuNew(menu, DynamicTypeAnnotations.VALUE_CLASSIFICATION_TYPE_PERSON,parent, p);

}
// Creates the menu tab of the new period under the parent type
if ( periodNodeContext)
{
addPeriodMenuNew( menu , parent, p );
}
// Creates the menu tab of the new category under the parent type
if ( categoryNodeContext )
{
addCategoryMenuNew( menu , parent, p, focusedObject );
}
// Creates the menu tab of the new event under the parent type
if ( reservationNodeContext)
{
addTypeMenuNew(menu, DynamicTypeAnnotations.VALUE_CLASSIFICATION_TYPE_RESERVATION,parent, p);
}

//added Enhancement, Creates the menu tab of the new sub-event under the parent type
if ( reservationNodeContext)
{
addTypeMenuNew(menu, DynamicTypeAnnotations.VALUE_CLASSIFICATION_TYPE_SUBEVENT,parent, p);
}

/*
*/
}
Expand Down

0 comments on commit 861e393

Please sign in to comment.