Subversion Repositories general

Compare Revisions

Ignore whitespace Rev 1427 → Rev 1428

/kickup/trunk/src/ak/kickup/core/action/ParticipantAction.java
144,6 → 144,7
showForm.set("transportComment", participant.getTransportComment());
showForm.set("freeSleep", StringConverter.toString(participant.getFreeSleep()));
showForm.set("sleepComment", participant.getSleepComment());
showForm.set("protectedComment", participant.getProtectedComment());
showForm.set("comment", participant.getComment());
 
request.setAttribute("participant", participant);
232,6 → 233,7
participant.setTransportComment((String)theForm.get("transportComment"));
participant.setFreeSleep(StringConverter.parseInteger(theForm.get("freeSleep")));
participant.setSleepComment((String)theForm.get("sleepComment"));
participant.setProtectedComment((String)theForm.get("protectedComment"));
participant.setComment((String)theForm.get("comment"));
 
ParticipantManager.getInstance().save(participant);
296,6 → 298,7
participant.setTransportComment((String)theForm.get("transportComment"));
participant.setFreeSleep(StringConverter.parseInteger(theForm.get("freeSleep")));
participant.setSleepComment((String)theForm.get("sleepComment"));
participant.setProtectedComment((String)theForm.get("protectedComment"));
participant.setComment((String)theForm.get("comment"));
 
ParticipantManager.getInstance().save(participant);
/kickup/trunk/src/ak/kickup/core/action/AdminParticipantAction.java
104,6 → 104,7
showForm.set("sleepComment", participant.getSleepComment());
showForm.set("payed", StringConverter.toCurrency(participant.getPayed()));
showForm.set("comment", participant.getComment());
showForm.set("protectedComment", participant.getProtectedComment());
showForm.set("privateComment", participant.getPrivateComment());
}
 
202,6 → 203,7
participant.setSleepComment((String)theForm.get("sleepComment"));
participant.setPayed(StringConverter.parseCurrency(theForm.get("payed")));
participant.setComment((String)theForm.get("comment"));
participant.setProtectedComment((String)theForm.get("protectedComment"));
participant.setPrivateComment((String)theForm.get("privateComment"));
 
ParticipantManager.getInstance().save(participant);
/kickup/trunk/src/ak/kickup/core/model/Participant.java
41,6 → 41,7
private String sleepComment;
private BigDecimal payed;
private String comment;
private String protectedComment;
private String privateComment;
private Collection acts; // Collection(ParticipantAct)
private Map actsMap = new HashMap(); // Map(Long id -> ParticipantAct)
314,6 → 315,20
 
/**
*
* @hibernate.property column="protected_comment"
*/
public String getProtectedComment()
{
return protectedComment;
}
 
public void setProtectedComment(String protectedComment)
{
this.protectedComment = protectedComment;
}
 
/**
*
* @hibernate.property column="private_comment"
*/
public String getPrivateComment()
/kickup/trunk/webapp/WEB-INF/struts-config.xml
108,6 → 108,7
<form-property name="sleepComment" type="java.lang.String" />
<form-property name="payed" type="java.lang.String" />
<form-property name="comment" type="java.lang.String" />
<form-property name="protectedComment" type="java.lang.String" />
<form-property name="privateComment" type="java.lang.String" />
<form-property name="acts" type="ak.kickup.core.form.ParticipantActBean[]"
size="1" />
131,6 → 132,7
<form-property name="freeSleep" type="java.lang.String" />
<form-property name="sleepComment" type="java.lang.String" />
<form-property name="comment" type="java.lang.String" />
<form-property name="protectedComment" type="java.lang.String" />
<form-property name="acts" type="ak.kickup.core.form.ParticipantActBean[]"
size="1" />
</form-bean>
152,6 → 154,7
<form-property name="freeSleep" type="java.lang.String" />
<form-property name="sleepComment" type="java.lang.String" />
<form-property name="comment" type="java.lang.String" />
<form-property name="protectedComment" type="java.lang.String" />
<form-property name="acts" type="ak.kickup.core.form.ParticipantActBean[]"
size="1" />
</form-bean>
/kickup/trunk/webapp/admin/participant/list.jsp
65,6 → 65,7
<th class="subHeader">Ник</th>
<th class="subHeader">e-mail</th>
<th class="subHeader">Имя</th>
<th class="subHeader">Город</th>
<th class="subHeader">Количество</th>
<th class="subHeader">Оплачено, евро</th>
<th class="subHeader" width=50>&nbsp;</th>
92,7 → 93,10
<bean:write name="p" property="name" />&nbsp;
</td>
<td class="listCell">
<bean:write name="p" property="persons" />&nbsp;
<bean:write name="p" property="fromCity" />&nbsp;
</td>
<td class="listCell">
<bean:write name="p" property="persons" />&nbsp;
</td>
<td class="listCell">
<bean:write name="p" property="payed" format="0.00" />&nbsp;
/kickup/trunk/webapp/admin/participant/edit.jsp
91,10 → 91,14
<td colspan=2><html:textarea property="sleepComment" cols="40" rows="8" style="width:100%" /></td>
</tr>
<tr class="even">
<th>Дополнительная информация</th>
<th>Дополнительная информация<br><span class="comment">видима для всех</span></th>
<td colspan=2><html:textarea property="comment" cols="40" rows="8" style="width:100%" /></td>
</tr>
<tr class="odd">
<th>Информация для организаторов<br><span class="comment">видима только данному участнику</span></th>
<td colspan=2><html:textarea property="comment" cols="40" rows="8" style="width:100%" /></td>
</tr>
<tr class="even">
<th>Оплачено, евро</th>
<td><html:text property="payed" style="width:100%" maxlength="10" /></td>
<td>
103,8 → 107,8
</logic:notEmpty>
</td>
</tr>
<tr class="even">
<th>Комментарии организаторов</th>
<tr class="odd">
<th>Комментарии организаторов<br><span class="comment">видимы только организаторам</span></th>
<td colspan=2><html:textarea property="privateComment" cols="40" rows="8" style="width:100%" /></td>
</tr>
 
/kickup/trunk/webapp/participant/list.jsp
35,6 → 35,8
<th class="headerCell">e-mail</th>
<th class="headerCell">Телефон</th>
<th class="headerCell">Количество</th>
<th class="headerCell">Откуда</th>
<th class="headerCell">Информация</th>
</tr>
 
<logic:iterate name="participants" id="p">
49,6 → 51,8
</td>
<td class="listCell"><bean:write name="p" property="phone" />&nbsp;</td>
<td class="listCell"><bean:write name="p" property="persons" />&nbsp;</td>
<td class="listCell"><bean:write name="p" property="fromCity" />&nbsp;</td>
<td class="listCell"><bean:write name="p" property="comment" />&nbsp;</td>
</tr>
</logic:iterate>
<tr>
/kickup/trunk/webapp/participant/register.jsp
62,6 → 62,14
<span class="obligatedText">обязательное поле</span>
</td>
</tr>
<tr>
<th>Дополнительная информация, видимая всем</th>
<td colspan=2><html:textarea property="comment" cols="40" rows="5" style="width:240px;" /></td>
</tr>
<tr>
<th>Дополнительная информация, видимая только организаторам</th>
<td colspan=2><html:textarea property="protectedComment" cols="40" rows="5" style="width:240px;" /></td>
</tr>
 
<tr>
<td colspan=3><div class="smallHeader">Если берете попутчиков</div></td>
117,10 → 125,6
<th>Телефон</th>
<td colspan=2><html:text property="phone" style="width:240px" maxlength="255" /></td>
</tr>
<tr>
<th>Дополнительная информация</th>
<td colspan=2><html:textarea property="comment" cols="40" rows="5" style="width:240px;" /></td>
</tr>
 
<logic:notEmpty name="actList" property="objects">
<tr>
/kickup/trunk/webapp/participant/edit.jsp
55,6 → 55,14
<th>Сколько вас</th>
<td colspan=2><html:text property="persons" style="width:240px" maxlength="10" /></td>
</tr>
<tr>
<th>Дополнительная информация,<br>видимая всем</th>
<td colspan=2><html:textarea property="comment" cols="40" rows="5" style="width:240px;" /></td>
</tr>
<tr>
<th>Дополнительная информация,<br>видимая только организаторам</th>
<td colspan=2><html:textarea property="protectedComment" cols="40" rows="5" style="width:240px;" /></td>
</tr>
 
<tr>
<td colspan=3><div class="smallHeader">Если берете попутчиков</div></td>
114,10 → 122,6
<th>Переведено и получено, евро</th>
<td colspan=2><bean:write name="participant" property="payed" format="0.00" /></td>
</tr>
<tr>
<th>Дополнительная информация</th>
<td colspan=2><html:textarea property="comment" cols="40" rows="5" style="width:240px;" /></td>
</tr>
 
<logic:notEmpty name="actList" property="objects">
<tr>
/kickup/trunk/sql/00.tables.sql
4,22 → 4,6
 
create sequence hibernate_sequence;
 
/* removed in this version
create table participants
(
id integer not null,
nick varchar(255) not null,
email varchar(255) not null,
name varchar(255),
phone varchar(255),
comment text,
mod_stamp timestamp,
 
constraint participants_prim primary key (id),
constraint participants_email unique(email)
);
*/
 
create table acts
(
id integer not null,
69,21 → 53,6
constraint events_name unique(name)
);
 
/*
create table event_files
(
id integer not null,
event integer not null,
name varchar(255) not null,
data file,
type char(1),
comment text,
mod_stamp timestamp,
 
constraint event_files_prim primary key (id)
);
*/
 
create table event_apartments
(
id integer not null,
111,27 → 80,6
constraint event_acts_act foreign key (act) references acts(id)
);
 
/* removed in this version
create table participant_events
(
participant integer not null,
event integer not null,
persons integer,
from_zip varchar(10),
from_city varchar(10),
departure datetime,
free_transport integer,
transport_comment integer,
free_sleep integer,
sleep_comment text,
payed char(1) default ' ',
comment text,
mod_stamp timestamp,
 
constraint participant_events_prim primary key (participant, event)
);
*/
 
create table participants
(
id integer not null,
151,8 → 99,9
free_sleep integer,
sleep_comment text,
payed decimal,
comment text,
private_comment text,
comment text, -- editeable by participant and visible for anybody
protected_comment text, -- editeable by participant and visible for admins only
private_comment text, -- editeable by admin and visible for admins only
mod_stamp timestamp,
 
constraint participants_prim primary key (id),