[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Fmsystem-commits] [14287]
From: |
Saul |
Subject: |
[Fmsystem-commits] [14287] |
Date: |
Thu, 05 Nov 2015 23:58:35 +0000 |
Revision: 14287
http://svn.sv.gnu.org/viewvc/?view=rev&root=fmsystem&revision=14287
Author: psaul
Date: 2015-11-05 23:58:34 +0000 (Thu, 05 Nov 2015)
Log Message:
-----------
Modified Paths:
--------------
branches/dev-syncromind/bookingfrontend/inc/class.uiallocation.inc.php
branches/dev-syncromind/bookingfrontend/inc/class.uiapplication.inc.php
branches/dev-syncromind/bookingfrontend/js/bookingfrontend/booking.js
branches/dev-syncromind/bookingfrontend/templates/base/allocation_cancel.xsl
branches/dev-syncromind/bookingfrontend/templates/base/allocation_delete.xsl
branches/dev-syncromind/bookingfrontend/templates/base/booking_edit.xsl
branches/dev-syncromind/bookingfrontend/templates/base/building.xsl
Added Paths:
-----------
branches/dev-syncromind/bookingfrontend/templates/base/application.xsl
branches/dev-syncromind/bookingfrontend/templates/base/application_edit.xsl
branches/dev-syncromind/bookingfrontend/templates/base/booking.xsl
Modified: branches/dev-syncromind/bookingfrontend/inc/class.uiallocation.inc.php
===================================================================
--- branches/dev-syncromind/bookingfrontend/inc/class.uiallocation.inc.php
2015-11-05 23:54:56 UTC (rev 14286)
+++ branches/dev-syncromind/bookingfrontend/inc/class.uiallocation.inc.php
2015-11-05 23:58:34 UTC (rev 14287)
@@ -105,6 +105,10 @@
$this->flash_form_errors($errors);
$allocation['cancel_link'] =
self::link(array('menuaction' => 'bookingfrontend.uibuilding.schedule', 'id' =>
$allocation['building_id']));
+ $allocation['from_'] = pretty_timestamp($allocation['from_']);
+ $allocation['to_'] = pretty_timestamp($allocation['to_']);
+ $GLOBALS['phpgw']->jqcal->add_listener('field_repeat_until',
'date');
+
// $this->use_yui_editor();
self::render_template('allocation_cancel',
array('allocation'=>$allocation));
Modified:
branches/dev-syncromind/bookingfrontend/inc/class.uiapplication.inc.php
===================================================================
--- branches/dev-syncromind/bookingfrontend/inc/class.uiapplication.inc.php
2015-11-05 23:54:56 UTC (rev 14286)
+++ branches/dev-syncromind/bookingfrontend/inc/class.uiapplication.inc.php
2015-11-05 23:58:34 UTC (rev 14287)
@@ -74,11 +74,14 @@
//Filter application comments only after update has
been attempted unless
//you wish to delete the comments not matching the
specified types
$this->filter_application_comments($application,
array('comment'));
+
+ $activity_path =
$this->activity_bo->get_path($application['activity_id']);
+ $top_level_activity = $activity_path ? $activity_path[0]['id'] :
-1;
$application['resource_ids'] = $resource_ids;
- $agegroups = $this->agegroup_bo->fetch_age_groups();
+ $agegroups =
$this->agegroup_bo->fetch_age_groups($top_level_activity);
$agegroups = $agegroups['results'];
- $audience = $this->audience_bo->fetch_target_audience();
+ $audience =
$this->audience_bo->fetch_target_audience($top_level_activity);
$audience = $audience['results'];
self::render_template('application',
array('application' => $application, 'audience' => $audience, 'agegroups' =>
$agegroups, 'frontend'=>'true'));
}
Modified: branches/dev-syncromind/bookingfrontend/js/bookingfrontend/booking.js
===================================================================
--- branches/dev-syncromind/bookingfrontend/js/bookingfrontend/booking.js
2015-11-05 23:54:56 UTC (rev 14286)
+++ branches/dev-syncromind/bookingfrontend/js/bookingfrontend/booking.js
2015-11-05 23:58:34 UTC (rev 14287)
@@ -83,7 +83,7 @@
function populateTableChkResources (building_id, selection) {
var url =
"index.php?menuaction=bookingfrontend.uiresource.index_json&sort=name&filter_building_id="
+ building_id + "&phpgw_return_as=json&";
var container = "resources_container";
- var colDefsResources = [{label: '', object: [{type: 'input', attrs:
[{name: 'type', value: 'checkbox'},{name: 'name', value: 'resource[]'},{name:
'data-validation', value: 'checkbox_group'},{name: 'data-validation-qty',
value: 'min1'},{name: 'data-validation-error-msg', value: 'Please choose at
least 1 resource'}]}], value: 'id', checked: selection},{key: 'name', label:
lang['Name']},{key: 'type', label: lang['Resource Type']}];
+ var colDefsResources = [{label: '', object: [{type: 'input', attrs:
[{name: 'type', value: 'checkbox'},{name: 'name', value: 'resources[]'},{name:
'data-validation', value: 'checkbox_group'},{name: 'data-validation-qty',
value: 'min1'},{name: 'data-validation-error-msg', value: 'Please choose at
least 1 resource'}]}], value: 'id', checked: selection},{key: 'name', label:
lang['Name']},{key: 'type', label: lang['Resource Type']}];
populateTableChk(url, container, colDefsResources);
}
Modified:
branches/dev-syncromind/bookingfrontend/templates/base/allocation_cancel.xsl
===================================================================
---
branches/dev-syncromind/bookingfrontend/templates/base/allocation_cancel.xsl
2015-11-05 23:54:56 UTC (rev 14286)
+++
branches/dev-syncromind/bookingfrontend/templates/base/allocation_cancel.xsl
2015-11-05 23:58:34 UTC (rev 14287)
@@ -18,115 +18,154 @@
<input id="field_from" name="from_" type="hidden"
value="{allocation/from_}" />
<input id="field_to" name="to_" type="hidden" value="{allocation/to_}"
/>
- <dl class="form-col">
-
- <dt><label for="field_building"><xsl:value-of
select="php:function('lang', 'Building')" /></label></dt>
- <dd>
- <div class="autocomplete">
- <xsl:value-of select="allocation/building_name"/>
+ <div class="pure-g">
+ <div class="pure-u-1 pure-u-md-2-5 pure-u-lg-1-4">
+ <dl class="form-col">
+ <dt><label for="field_building"><xsl:value-of
select="php:function('lang', 'Building')" /></label></dt>
+ <dd>
+ <div class="autocomplete">
+ <xsl:value-of select="allocation/building_name"/>
+ </div>
+ </dd>
+ </dl>
+ </div>
+ <div class="pure-u-1 pure-u-md-2-5 pure-u-lg-1-4">
+ <dl class="form-col">
+ <dt><label for="field_org"><xsl:value-of
select="php:function('lang', 'Organization')" /></label></dt>
+ <dd>
+ <div class="autocomplete">
+ <xsl:value-of
select="allocation/organization_name"/>
+ </div>
+ </dd>
+ </dl>
+ </div>
+ </div>
+
+ <div class="pure-g">
+ <div class="pure-u-1 pure-u-md-2-5 pure-u-lg-1-4">
+ <dl class="form-col">
+ <dt><label for="field_from"><xsl:value-of
select="php:function('lang', 'From')" /></label></dt>
+ <dd>
+ <div>
+ <xsl:value-of select="allocation/from_"/>
+ </div>
+ </dd>
+ </dl>
+ </div>
+ <div class="pure-u-1 pure-u-md-2-5 pure-u-lg-1-4">
+ <dl class="form-col">
+ <dt><label for="field_to"><xsl:value-of
select="php:function('lang', 'To')" /></label></dt>
+ <dd>
+ <div>
+ <xsl:value-of select="allocation/to_"/>
+ </div>
+ </dd>
+ </dl>
+ </div>
+ </div>
+
+ <div class="pure-g">
+ <div class="pure-u-1 pure-u-md-2-5 pure-u-lg-1-4">
+ <dl class="form-col">
+ <dt><label for="field_repeat_until"><xsl:value-of
select="php:function('lang', 'Recurring allocation deletion')" /></label></dt>
+ <dd>
+ <label>
+ <input type="checkbox" name="outseason"
id="outseason">
+ <xsl:if test="outseason='on'">
+ <xsl:attribute
name="checked">checked</xsl:attribute>
+ </xsl:if>
+ </input>
+ <xsl:value-of select="php:function('lang', 'Out
season')" />
+ </label>
+ </dd>
+ <dd>
+ <label>
+ <input type="checkbox" name="recurring"
id="recurring">
+ <xsl:if test="recurring='on'">
+ <xsl:attribute
name="checked">checked</xsl:attribute>
+ </xsl:if>
+ </input>
+ <xsl:value-of select="php:function('lang', 'Delete
until')" />
+ </label>
+ </dd>
+ <!--dd class="date-picker">
+ <input id="field_repeat_until" name="repeat_until"
type="text">
+ <xsl:attribute name="value"><xsl:value-of
select="repeat_until"/></xsl:attribute>
+ </input>
+ </dd-->
+ <dd>
+ <input class="datetime" id="field_repeat_until"
name="repeat_until" type="text">
+ <xsl:attribute name="value"><xsl:value-of
select="repeat_until"/></xsl:attribute>
+ </input>
+ </dd>
+ </dl>
+ </div>
+ </div>
+
+ <div class="pure-g">
+ <div class="pure-u-1 pure-u-md-2-5 pure-u-lg-1-4">
+ <dl class="form-col">
+ <dt><xsl:value-of select="php:function('lang',
'Interval')" /></dt>
+ <dd>
+ <xsl:value-of select="../field_interval" />
+ <select id="field_interval" name="field_interval">
+ <option value="1">
+ <xsl:if test="interval=1">
+ <xsl:attribute
name="selected">selected</xsl:attribute>
+ </xsl:if>
+ <xsl:value-of select="php:function('lang', '1
week')" />
+ </option>
+ <option value="2">
+ <xsl:if test="interval=2">
+ <xsl:attribute
name="selected">selected</xsl:attribute>
+ </xsl:if>
+ <xsl:value-of select="php:function('lang', '2
weeks')" />
+ </option>
+ <option value="3">
+ <xsl:if test="interval=3">
+ <xsl:attribute
name="selected">selected</xsl:attribute>
+ </xsl:if>
+ <xsl:value-of select="php:function('lang', '3
weeks')" />
+ </option>
+ <option value="4">
+ <xsl:if test="interval=4">
+ <xsl:attribute
name="selected">selected</xsl:attribute>
+ </xsl:if>
+ <xsl:value-of select="php:function('lang', '4
weeks')" />
+ </option>
+ </select>
+ </dd>
+ </dl>
+ </div>
+ </div>
+
+ <div class="pure-g">
+ <div class="pure-u-1 pure-u-md-2-5 pure-u-lg-1-4">
+ <dl class="form-col">
+ <dt><label for="field_message"><xsl:value-of
select="php:function('lang', 'Message')" /></label></dt>
+ <dd>
+ <textarea id="field-message" name="message"
type="text"><xsl:value-of select="message"/></textarea>
+ </dd>
+ </dl>
+ </div>
+ </div>
+
+ <div class="pure-g">
+ <div class="pure-u-1">
+ <div class="form-buttons">
+ <input type="submit">
+ <xsl:attribute name="value"><xsl:value-of
select="php:function('lang', 'Cancel allocation')"/></xsl:attribute>
+ </input>
+ <a class="cancel">
+ <xsl:attribute name="href"><xsl:value-of
select="allocation/cancel_link"/></xsl:attribute>
+ <xsl:value-of select="php:function('lang', 'Cancel')"
/>
+ </a>
</div>
- </dd>
+ </div>
+ </div>
+
+
-
- <dt><label for="field_from"><xsl:value-of
select="php:function('lang', 'From')" /></label></dt>
- <dd>
- <div>
- <xsl:value-of select="allocation/from_"/>
- </div>
- </dd>
- <dd>
- <div> </div>
- </dd>
- <dt><label for="field_repeat_until"><xsl:value-of
select="php:function('lang', 'Recurring allocation deletion')" /></label></dt>
- <dd>
- <label>
- <input type="checkbox" name="outseason"
id="outseason">
- <xsl:if test="outseason='on'">
- <xsl:attribute
name="checked">checked</xsl:attribute>
- </xsl:if>
- </input>
- <xsl:value-of
select="php:function('lang', 'Out season')" />
- </label>
- </dd>
- <dd>
- <label>
- <input type="checkbox" name="recurring"
id="recurring">
- <xsl:if test="recurring='on'">
- <xsl:attribute
name="checked">checked</xsl:attribute>
- </xsl:if>
- </input>
- <xsl:value-of
select="php:function('lang', 'Delete until')" />
- </label>
- </dd>
- <dd class="date-picker">
- <input id="field_repeat_until"
name="repeat_until" type="text">
- <xsl:attribute
name="value"><xsl:value-of select="repeat_until"/></xsl:attribute>
- </input>
- </dd>
- <dt><xsl:value-of select="php:function('lang',
'Interval')" /></dt>
- <dd>
- <xsl:value-of select="../field_interval" />
- <select id="field_interval"
name="field_interval">
- <option value="1">
- <xsl:if test="interval=1">
- <xsl:attribute
name="selected">selected</xsl:attribute>
- </xsl:if>
- <xsl:value-of
select="php:function('lang', '1 week')" />
- </option>
- <option value="2">
- <xsl:if test="interval=2">
- <xsl:attribute
name="selected">selected</xsl:attribute>
- </xsl:if>
- <xsl:value-of
select="php:function('lang', '2 weeks')" />
- </option>
- <option value="3">
- <xsl:if test="interval=3">
- <xsl:attribute
name="selected">selected</xsl:attribute>
- </xsl:if>
- <xsl:value-of
select="php:function('lang', '3 weeks')" />
- </option>
- <option value="4">
- <xsl:if test="interval=4">
- <xsl:attribute
name="selected">selected</xsl:attribute>
- </xsl:if>
- <xsl:value-of
select="php:function('lang', '4 weeks')" />
- </option>
- </select>
- </dd>
- </dl>
- <dl class="form-col">
- <dt><label for="field_org"><xsl:value-of
select="php:function('lang', 'Organization')" /></label></dt>
- <dd>
- <div class="autocomplete">
- <xsl:value-of select="allocation/organization_name"/>
- </div>
- </dd>
- <dt><label for="field_to"><xsl:value-of
select="php:function('lang', 'To')" /></label></dt>
- <dd>
- <div>
- <xsl:value-of select="allocation/to_"/>
- </div>
- </dd>
- </dl>
-
- <div style='clear:both; padding:0; margin:0'/>
-
- <dl class="form-col">
- <dt><label for="field_message"><xsl:value-of
select="php:function('lang', 'Message')" /></label></dt>
- <dd class="yui-skin-sam">
- <textarea id="field-message" name="message"
type="text"><xsl:value-of select="message"/></textarea>
- </dd>
- </dl>
-
- <div class="form-buttons">
- <input type="submit">
- <xsl:attribute name="value"><xsl:value-of
select="php:function('lang', 'Cancel allocation')"/></xsl:attribute>
- </input>
- <a class="cancel">
- <xsl:attribute name="href"><xsl:value-of
select="allocation/cancel_link"/></xsl:attribute>
- <xsl:value-of select="php:function('lang', 'Cancel')" />
- </a>
- </div>
</form>
</div>
<script type="text/javascript">
Modified:
branches/dev-syncromind/bookingfrontend/templates/base/allocation_delete.xsl
===================================================================
---
branches/dev-syncromind/bookingfrontend/templates/base/allocation_delete.xsl
2015-11-05 23:54:56 UTC (rev 14286)
+++
branches/dev-syncromind/bookingfrontend/templates/base/allocation_delete.xsl
2015-11-05 23:58:34 UTC (rev 14287)
@@ -34,7 +34,7 @@
<dt><label for="field_org"><xsl:value-of
select="php:function('lang', 'Organization')" /></label></dt>
<dd>
<div class="autocomplete">
- <xsl:value-of
select="allocation/organization_name"/>
+ <xsl:value-of
select="allocation/organization_name"/>
</div>
</dd>
</dl>
@@ -149,7 +149,7 @@
</div>
<div class="pure-g">
- <div class="pure-control-group">
+ <div class="pure-u-1">
<div class="form-buttons">
<input type="submit">
<xsl:attribute name="value"><xsl:value-of
select="php:function('lang', 'Delete')"/></xsl:attribute>
Added: branches/dev-syncromind/bookingfrontend/templates/base/application.xsl
===================================================================
--- branches/dev-syncromind/bookingfrontend/templates/base/application.xsl
(rev 0)
+++ branches/dev-syncromind/bookingfrontend/templates/base/application.xsl
2015-11-05 23:58:34 UTC (rev 14287)
@@ -0,0 +1,379 @@
+<func:function name="phpgw:conditional">
+ <xsl:param name="test"/>
+ <xsl:param name="true"/>
+ <xsl:param name="false"/>
+
+ <func:result>
+ <xsl:choose>
+ <xsl:when test="$test">
+ <xsl:value-of select="$true"/>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:value-of select="$false"/>
+ </xsl:otherwise>
+ </xsl:choose>
+ </func:result>
+</func:function>
+
+<xsl:template match="data" xmlns:php="http://php.net/xsl">
+ <div id="content">
+ <ul class="pathway">
+ <li>
+ <a>
+ <xsl:attribute
name="href"><xsl:value-of
select="application/applications_link"/></xsl:attribute>
+ <xsl:value-of
select="php:function('lang', 'Applications')" />
+ </a>
+ </li>
+ <li>#<xsl:value-of select="application/id"/></li>
+ <li>
+ <xsl:if test="frontend and
application/status='ACCEPTED'">
+ <form method="POST">
+ <input type="hidden"
name="print" value="ACCEPTED"/>
+ <input type="submit"
value="{php:function('lang', 'Print as PDF')}" />
+ </form>
+ </xsl:if>
+ </li>
+ </ul>
+
+ <xsl:call-template name="msgbox"/>
+ <!--xsl:call-template name="yui_booking_i18n"/-->
+
+ <xsl:if test="not(frontend)">
+ <div style="border: 3px solid red; padding: 3px
4px 3px 4px">
+ <xsl:choose>
+ <xsl:when
test="not(application/case_officer)">
+ <xsl:value-of
select="php:function('lang', 'In order to work with this application, you must
first')"/>
+ <xsl:text>
</xsl:text><a href="#assign"><xsl:value-of select="php:function('lang', 'assign
yourself')"/></a><xsl:text> </xsl:text>
+ <xsl:value-of
select="php:function('lang', 'as the case officer responsible for this
application.')"/>
+ </xsl:when>
+ <xsl:when
test="application/case_officer and
not(application/case_officer/is_current_user)">
+ <xsl:value-of
select="php:function('lang', 'The user currently assigned as the responsible
case officer for this application is')"/>'<xsl:text> </xsl:text><xsl:value-of
select="application/case_officer/name"/>'.
+ <br/>
+ <xsl:value-of
select="php:function('lang', 'In order to work with this application, you must
therefore first')"/>
+ <xsl:text>
</xsl:text><a href="#assign"><xsl:value-of select="php:function('lang', 'assign
yourself')"/></a><xsl:text> </xsl:text>
+ <xsl:value-of
select="php:function('lang', 'as the case officer responsible for this
application.')"/>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:attribute
name="style">display:none</xsl:attribute>
+ </xsl:otherwise>
+ </xsl:choose>
+ </div>
+ </xsl:if>
+
+ <xsl:if test="not(frontend)">
+ <dl class="proplist-col">
+ <dt><xsl:value-of select="php:function('lang', 'Status')"
/></dt>
+ <dd><xsl:value-of select="php:function('lang',
string(application/status))"/></dd>
+ </dl>
+ <dl class="proplist-col">
+ <dt><xsl:value-of select="php:function('lang', 'Created')"
/></dt>
+ <dd><xsl:value-of select="php:function('pretty_timestamp',
application/created)"/></dd>
+ </dl>
+ <dl class="proplist-col">
+ <dt><xsl:value-of select="php:function('lang', 'Modified')"
/></dt>
+ <dd><xsl:value-of select="php:function('pretty_timestamp',
application/modified)"/></dd>
+ </dl>
+ </xsl:if>
+ <xsl:if test="frontend">
+ <dl class="proplist">
+ <span style="font-size: 110%; font-weight: bold;">Din
søknad har status <xsl:value-of select="php:function('lang',
string(application/status))"/></span><span class="text">, opprettet
<xsl:value-of select="php:function('pretty_timestamp', application/created)"/>,
sist endret <xsl:value-of select="php:function('pretty_timestamp',
application/modified)"/></span>
+ <span class="text"><br />Melding fra saksbehandler
ligger under historikk, deretter vises kopi av din søknad.<br /> Skal du gi en
melding til saksbehandler skriver du denne inn i feltet under "Legg til en
kommentar"</span>
+ </dl>
+ </xsl:if>
+
+ <dl class="proplist">
+ <dt class="heading"><xsl:value-of select="php:function('lang',
'Add a comment')" /></dt>
+ <dd>
+ <form method="POST">
+ <textarea name="comment" style="width:
60%; height: 7em"></textarea><br/>
+ <input type="submit"
value="{php:function('lang', 'Add comment')}" />
+ </form>
+ </dd>
+ </dl>
+
+ <dl class="proplist">
+ <dt class="heading">1. <xsl:value-of select="php:function('lang',
'History and comments (%1)', count(application/comments/author))" /></dt>
+ <xsl:for-each select="application/comments[author]">
+ <dt>
+ <xsl:value-of
select="php:function('pretty_timestamp', time)"/>: <xsl:value-of
select="author"/>
+ </dt>
+ <xsl:choose>
+ <xsl:when
test='contains(comment,"bookingfrontend.uidocument_building.download")'>
+ <dd><xsl:value-of
select="comment" disable-output-escaping="yes"/></dd>
+ </xsl:when>
+ <xsl:otherwise>
+ <dd><div style="width:
80%;"><xsl:value-of select="comment"/></div></dd>
+ </xsl:otherwise>
+ </xsl:choose>
+ </xsl:for-each>
+ </dl>
+
+ <dl class="proplist">
+ <dt class="heading">2. <xsl:value-of select="php:function('lang',
'Why?')" /></dt>
+ <dt><xsl:value-of select="php:function('lang', 'Activity')" /></dt>
+ <dd><xsl:value-of select="application/activity_name"/></dd>
+ <dt><xsl:value-of select="php:function('lang', 'Description')"
/></dt>
+ <dd><div style="width: 80%;"><xsl:value-of
select="application/description"/></div></dd>
+ </dl>
+ <dl class="proplist-col">
+ <dt class="heading">3. <xsl:value-of select="php:function('lang',
'Where?')" /></dt>
+ <dt><xsl:value-of select="php:function('lang',
'Building')" /></dt>
+ <dd><xsl:value-of select="application/building_name"/>
+ (<a href="javascript: void(0)"
+
onclick="window.open('{application/schedule_link}',
+ '',
+ 'width=1048, height=600,
scrollbars=yes');
+ return
false;"><xsl:value-of select="php:function('lang', 'Building schedule')"
/></a>)</dd>
+ <dd><div id="resources_container"/></dd>
+ </dl>
+ <dl class="proplist-col">
+ <dt class="heading">4. <xsl:value-of select="php:function('lang',
'When?')" /></dt>
+ <script type="text/javascript">
+ var allocationParams = {};
+ var bookingParams = {};
+ var eventParams = {};
+ </script>
+ <xsl:for-each select="application/dates">
+ <dd><xsl:value-of select="php:function('lang',
'From')" />: <xsl:value-of select="php:function('pretty_timestamp',
from_)"/></dd>
+ <dd><xsl:value-of select="php:function('lang',
'To')" />: <xsl:value-of select="php:function('pretty_timestamp', to_)"/></dd>
+ <xsl:if test="../edit_link">
+ <script type="text/javascript">
+ allocationParams[<xsl:value-of
select="id"/>] = <xsl:value-of select="allocation_params"/>;
+ bookingParams[<xsl:value-of
select="id"/>] = <xsl:value-of select="booking_params"/>;
+ eventParams[<xsl:value-of
select="id"/>] = <xsl:value-of select="event_params"/>;
+ </script>
+ <select name="create"
onchange="if(this.selectedIndex==1)
YAHOO.booking.postToUrl('index.php?menuaction=booking.uiallocation.add',
allocationParams[{id}]); if(this.selectedIndex==2)
YAHOO.booking.postToUrl('index.php?menuaction=booking.uibooking.add',
eventParams[{id}]); if(this.selectedIndex==3)
YAHOO.booking.postToUrl('index.php?menuaction=booking.uievent.add',
eventParams[{id}]);">
+ <xsl:if
test="not(../case_officer/is_current_user)">
+ <xsl:attribute
name="disabled">disabled</xsl:attribute>
+ </xsl:if>
+
+ <option><xsl:value-of
select="php:function('lang', '- Actions -')" /></option>
+ <option><xsl:value-of
select="php:function('lang', 'Create allocation')" /></option>
+ <option><xsl:value-of
select="php:function('lang', 'Create booking')" /></option>
+ <option><xsl:value-of
select="php:function('lang', 'Create event')" /></option>
+ </select>
+ </xsl:if>
+ </xsl:for-each>
+ </dl>
+ <dl class="proplist-col">
+ <dt class="heading">5. <xsl:value-of select="php:function('lang',
'Who?')" /></dt>
+ <dt><xsl:value-of select="php:function('lang', 'Target audience')"
/></dt>
+ <dd>
+ <ul>
+ <xsl:for-each select="audience">
+ <xsl:if
test="../application/audience=id">
+ <li><xsl:value-of
select="name"/></li>
+ </xsl:if>
+ </xsl:for-each>
+ </ul>
+ </dd>
+ <dt><xsl:value-of select="php:function('lang', 'Number of
participants')" /></dt>
+ <dd>
+ <table id="agegroup">
+ <tr><th/><th><xsl:value-of
select="php:function('lang', 'Male')" /></th>
+ <th><xsl:value-of
select="php:function('lang', 'Female')" /></th></tr>
+ <xsl:for-each select="agegroups">
+ <xsl:variable
name="id"><xsl:value-of select="id"/></xsl:variable>
+ <tr>
+ <th><xsl:value-of
select="name"/></th>
+ <td><xsl:value-of
select="../application/agegroups/male[../agegroup_id = $id]"/></td>
+ <td><xsl:value-of
select="../application/agegroups/female[../agegroup_id = $id]"/></td>
+ </tr>
+ </xsl:for-each>
+ </table>
+ </dd>
+ </dl>
+ <div class="clr"/>
+ <dl class="form-col">
+ <div class="heading"><br />6. <xsl:value-of
select="php:function('lang', 'Contact information')" /></div>
+ <dt><label for="field_contact_name"><xsl:value-of
select="php:function('lang', 'Name')" /></label></dt>
+ <dd>
+ <xsl:value-of
select="application/contact_name"/>
+ </dd>
+ <dt><label for="field_contact_email"><xsl:value-of
select="php:function('lang', 'Email')" /></label></dt>
+ <dd>
+ <xsl:value-of
select="application/contact_email"/>
+ </dd>
+ <dt><label for="field_contact_phone"><xsl:value-of
select="php:function('lang', 'Phone')" /></label></dt>
+ <dd>
+ <xsl:value-of
select="application/contact_phone"/>
+ </dd>
+ </dl>
+ <dl class="form-col">
+ <div class="heading">7. <xsl:value-of
select="php:function('lang', 'responsible applicant')" /> / <xsl:value-of
select="php:function('lang', 'invoice information')" /></div>
+ <xsl:if test="application/customer_identifier_type =
'organization_number'">
+ <dt><label
for="field_organization_number"><xsl:value-of select="php:function('lang',
'organization number')" /></label></dt>
+ <dd><xsl:value-of
select="application/customer_organization_number"/></dd>
+ </xsl:if>
+ <xsl:if test="application/customer_identifier_type =
'ssn'">
+ <dt><label for="field_ssn_number"><xsl:value-of
select="php:function('lang', 'Date of birth or SSN')" /></label></dt>
+ <dd><xsl:value-of
select="application/customer_ssn"/></dd>
+ </xsl:if>
+ </dl>
+ <dl class="form-col">
+ <div class="heading"><br />8. <xsl:value-of
select="php:function('lang', 'Terms and conditions')" /></div>
+ <p><xsl:value-of select="php:function('lang', 'All that
borrow premises from Bergen Kommune must verify that they have read the terms
and conditions, this is usually fire regulations and house rules.')" /></p>
+ <br />
+ <div id='regulation_documents'> </div>
+ <br />
+ <p><xsl:value-of select="php:function('lang', 'To
borrow premises you must verify that you have read terms and conditions')"
/></p>
+ </dl>
+
+ <div class="clr"/>
+ <xsl:if test="application/edit_link">
+ <button>
+ <xsl:if
test="application/case_officer/is_current_user">
+ <xsl:attribute
name="onclick">window.location.href='<xsl:value-of
select="application/edit_link"/>'</xsl:attribute>
+ </xsl:if>
+ <xsl:if
test="not(application/case_officer/is_current_user)">
+ <xsl:attribute
name="disabled">disabled</xsl:attribute>
+ </xsl:if>
+ <xsl:value-of select="php:function('lang', 'Edit')" />
+ </button>
+ </xsl:if>
+ <xsl:if test="not(frontend)">
+ <dl class="proplist">
+ <dt class="heading"><xsl:value-of
select="php:function('lang', 'Associated items')" /></dt>
+ <dd><div id="associated_container"/></dd>
+ </dl>
+ </xsl:if>
+
+ <xsl:if test="application/edit_link">
+ <dl class="proplist">
+ <dt class="heading"><xsl:value-of
select="php:function('lang', 'Actions')" /></dt>
+
+ <dt>
+ <xsl:if
test="application/case_officer/is_current_user">
+ <form method="POST"
style="display:inline">
+ <input
type="hidden" name="unassign_user"/>
+ <input
type="submit" value="{php:function('lang', 'Unassign me')}"/>
+ </form>
+ <form method="POST"
style="display:inline">
+ <input
type="hidden" name="display_in_dashboard"
value="{phpgw:conditional(application/display_in_dashboard='1', '0', '1')}"/>
+ <input
type="submit" value="{php:function('lang',
phpgw:conditional(application/display_in_dashboard='1', 'Hide from my Dashboard
until new activity occurs', 'Display in my Dashboard'))}"/>
+ </form>
+ </xsl:if>
+
+ <xsl:if
test="not(application/case_officer/is_current_user)">
+ <a
name="assign"/>
+ <form
method="POST">
+ <input
type="hidden" name="assign_to_user"/>
+ <input
type="hidden" name="status" value="PENDING"/>
+ <input
type="submit" value="{php:function('lang',
phpgw:conditional(application/case_officer, 'Re-assign to me', 'Assign to
me'))}"/>
+
+ <xsl:if
test="application/case_officer">
+
<xsl:value-of select="php:function('lang', 'Currently assigned to user:')"/>
+
<xsl:text> </xsl:text>
+
<xsl:value-of select="application/case_officer/name"/>
+
</xsl:if>
+ </form>
+ </xsl:if>
+ </dt>
+
+ <xsl:if test="application/status!='REJECTED'">
+ <dt>
+ <form method="POST">
+ <input type="hidden"
name="status" value="REJECTED"/>
+ <input onclick="return
confirm('{php:function('lang', 'Are you sure you want to delete?')}')"
type="submit" value="{php:function('lang', 'Reject application')}">
+ <xsl:if
test="not(application/case_officer)">
+
<xsl:attribute name="disabled">disabled</xsl:attribute>
+ </xsl:if>
+ </input>
+ </form>
+ </dt>
+ </xsl:if>
+ <xsl:if test="application/status='PENDING'">
+ <xsl:if test="num_associations='0'">
+ <input type="submit"
disabled="" value="{php:function('lang', 'Accept application')}"/>
+ <xsl:value-of
select="php:function('lang', 'One or more bookings, allocations or events needs
to be created before an application can be Accepted')"/>
+ </xsl:if>
+ <xsl:if test="num_associations!='0'">
+ <dt>
+ <form method="POST">
+ <input
type="hidden" name="status" value="ACCEPTED"/>
+ <input
type="submit" value="{php:function('lang', 'Accept application')}">
+ <xsl:if
test="not(application/case_officer)">
+
<xsl:attribute name="disabled">disabled</xsl:attribute>
+
</xsl:if>
+ </input>
+ </form>
+ </dt>
+ </xsl:if>
+ </xsl:if>
+ <dd><br/><a
href="{application/dashboard_link}"><xsl:value-of select="php:function('lang',
'Back to Dashboard')" /></a></dd>
+ </dl>
+ </xsl:if>
+ </div>
+
+ <script type="text/javascript">
+ var resourceIds = '<xsl:value-of select="application/resource_ids" />';
+ if (!resourceIds || resourceIds == "") {
+ resourceIds = false;
+ }
+ var lang = <xsl:value-of select="php:function('js_lang', 'Resources',
'Resources Type', 'ID', 'Type', 'From', 'To', 'Document')" />;
+ var app_id = <xsl:value-of select="application/id" />;
+ var building_id = <xsl:value-of select="application/building_id" />;
+ var resources = <xsl:value-of select="application/resources" />;
+
+ <![CDATA[
+ var resourcesURL =
'index.php?menuaction=bookingfrontend.uiresource.index_json&sort=name&phpgw_return_as=json&'
+ resourceIds;
+ var applicationURL =
'index.php?menuaction=bookingfrontend.uiapplication.associated&phpgw_return_as=json&filter_application_id='
+ app_id;
+ var documentURL =
'index.php?menuaction=booking.uidocument_view.regulations&sort=name&phpgw_return_as=json&owner[]=building::'
+ building_id;
+ documentURL +=
'index.php?menuaction=booking.uidocument_view.regulations&sort=name&phpgw_return_as=json&owner[]=resource::'+
resources;
+
+ ]]>
+
+ if (resourceIds) {
+ var colDefsResource = [{key: 'name', label: lang['Resources'],
formatter: genericLink}, {key: 'type', label: lang['Resource Type']}];
+ createTable('resources_container', resourcesURL, colDefsResource,
'results');
+ var colDefsApplication = [
+ {key: 'id', label: lang['ID'], formatter: genericLink},
+ {key: 'type', label: lang['Type']},
+ {key: 'from_', label: lang['From']},
+ {key: 'to_', label: lang['To']}
+ ];
+ createTable('associated_container', applicationURL,
colDefsApplication);
+ }
+
+ var colDefsDocument = [{key: 'name', label: lang['Document'],
formatter: genericLink}];
+ createTable('regulation_documents', documentURL, colDefsDocument);
+
+
+ </script>
+
+<!--script type="text/javascript">
+ var resourceIds = '<xsl:value-of select="application/resource_ids"/>';
+ if (!resourceIds || resourceIds == "") {
+ resourceIds = false;
+ }
+ var lang = <xsl:value-of select="php:function('js_lang', 'Resources',
'Resource Type', 'ID', 'Type', 'From', 'To', 'Document')"/>;
+ var app_id = <xsl:value-of select="application/id"/>;
+ var building_id = <xsl:value-of select="application/building_id"/>;
+ var resources = <xsl:value-of select="application/resources"/>;
+
+YAHOO.util.Event.addListener(window, "load", function() {
+ <![CDATA[
+ var url3 =
'index.php?menuaction=booking.uidocument_view.regulations&sort=name&phpgw_return_as=json&owner[]=building::'
+ building_id;
+ url3 +=
'index.php?menuaction=booking.uidocument_view.regulations&sort=name&phpgw_return_as=json&owner[]=resource::'+
resources;
+
+ ]]>
+ var colDefs = [{key: 'name', label: lang['Document'], formatter:
YAHOO.booking.formatLink}];
+ YAHOO.booking.inlineTableHelper('regulation_documents', url3, colDefs);
+ if (resourceIds) {
+ <![CDATA[
+ var url =
'index.php?menuaction=booking.uiresource.index&sort=name&phpgw_return_as=json&'
+ resourceIds;
+ var url2 =
'index.php?menuaction=booking.uiapplication.associated&phpgw_return_as=json&filter_application_id='
+ app_id;
+ ]]>
+ var colDefs = [{key: 'name', label: lang['Resources'], formatter:
YAHOO.booking.formatLink}, {key: 'type', label: lang['Resource Type']}];
+ YAHOO.booking.inlineTableHelper('resources_container', url,
colDefs);
+ var colDefs = [
+ {key: 'id', label: lang['ID'], formatter:
YAHOO.booking.formatLink},
+ {key: 'type', label: lang['Type']},
+ {key: 'from_', label: lang['From']},
+ {key: 'to_', label: lang['To']}];
+ YAHOO.booking.inlineTableHelper('associated_container', url2,
colDefs);
+ }
+
+});
+</script-->
+</xsl:template>
Added:
branches/dev-syncromind/bookingfrontend/templates/base/application_edit.xsl
===================================================================
--- branches/dev-syncromind/bookingfrontend/templates/base/application_edit.xsl
(rev 0)
+++ branches/dev-syncromind/bookingfrontend/templates/base/application_edit.xsl
2015-11-05 23:58:34 UTC (rev 14287)
@@ -0,0 +1,250 @@
+<xsl:template match="data" xmlns:php="http://php.net/xsl">
+ <div id="content">
+
+ <h3><xsl:value-of select="php:function('lang', 'Application')"/>
(<xsl:value-of select="application/id"/>)</h3>
+ <xsl:call-template name="msgbox"/>
+ <!--xsl:call-template name="yui_booking_i18n"/-->
+
+ <form action="" method="POST" id='application_form'>
+
+ <div class="pure-g">
+ <div class="pure-u-1 pure-u-md-1-2 pure-u-lg-1-2">
+ <dl class="form-col">
+ <dt><label for="field_active"><xsl:value-of
select="php:function('lang', 'Active')"/></label></dt>
+ <dd>
+ <select id="field_active" name="active">
+ <option value="1">
+ <xsl:if test="application/active=1">
+ <xsl:attribute
name="selected">checked</xsl:attribute>
+ </xsl:if>
+ <xsl:value-of select="php:function('lang',
'Active')"/>
+ </option>
+ <option value="0">
+ <xsl:if test="application/active=0">
+ <xsl:attribute
name="selected">checked</xsl:attribute>
+ </xsl:if>
+ <xsl:value-of select="php:function('lang',
'Inactive')"/>
+ </option>
+ </select>
+ </dd>
+ </dl>
+ </div>
+ </div>
+
+ <div class="pure-g">
+ <div class="pure-u-1 pure-u-md-1-2 pure-u-lg-1-2">
+ <dl class="form-col">
+ <div class="heading">1. <xsl:value-of
select="php:function('lang', 'Why?')" /></div>
+ <dt><label for="field_activity"><xsl:value-of
select="php:function('lang', 'Activity')" /></label></dt>
+ <dd>
+ <select name="activity_id" id="field_activity">
+ <option value=""><xsl:value-of
select="php:function('lang', '-- select an activity --')" /></option>
+ <xsl:for-each select="activities">
+ <option>
+ <xsl:if test="../application/activity_id =
id">
+ <xsl:attribute
name="selected">selected</xsl:attribute>
+ </xsl:if>
+ <xsl:attribute name="value"><xsl:value-of
select="id"/></xsl:attribute>
+ <xsl:value-of select="name"/>
+ </option>
+ </xsl:for-each>
+ </select>
+ </dd>
+ <dt><label for="field_description"><xsl:value-of
select="php:function('lang', 'Description')" /></label></dt>
+ <dd>
+ <textarea id="field_description" class="full-width"
name="description"><xsl:value-of select="application/description"/></textarea>
+ </dd>
+ </dl>
+ </div>
+ </div>
+
+ <div class="pure-g">
+ <div class="pure-u-1 pure-u-md-1-2 pure-u-lg-1-3">
+ <dl class="form-col">
+ <div class="heading">2. <xsl:value-of
select="php:function('lang', 'Where?')" /></div>
+ <dt><label for="field_building"><xsl:value-of
select="php:function('lang', 'Building')" /></label></dt>
+ <dd>
+ <div class="autocomplete">
+ <input id="field_building_id" name="building_id"
type="hidden">
+ <xsl:attribute name="value"><xsl:value-of
select="application/building_id"/></xsl:attribute>
+ </input>
+ <input id="field_building_name"
name="building_name" type="text">
+ <xsl:attribute name="value"><xsl:value-of
select="application/building_name"/></xsl:attribute>
+ </input>
+ <div id="building_container"/>
+ </div>
+ </dd>
+ <dt><label for="field_resources"><xsl:value-of
select="php:function('lang', 'Resources')" /></label></dt>
+ <dd>
+ <div id="resources_container"><xsl:value-of
select="php:function('lang', 'Select a building first')" /></div>
+ </dd>
+ </dl>
+ </div>
+ <div class="pure-u-1 pure-u-md-1-2 pure-u-lg-1-3">
+ <dl class="form-col">
+ <div class="heading">3. <xsl:value-of
select="php:function('lang', 'When?')" /></div>
+ <div id="dates-container">
+ <xsl:for-each select="application/dates"><div
class="date-container">
+ <a href="#" class="close-btn">-</a>
+ <dt><label
for="field_{position()}_from"><xsl:value-of select="php:function('lang',
'From')" /></label></dt>
+ <dd class="datetime-picker">
+ <input id="field_{position()}_from"
name="from_[]" type="text">
+ <xsl:attribute name="value"><xsl:value-of
select="from_"/></xsl:attribute>
+ </input>
+ </dd>
+ <dt><label
for="field_{position()}_to"><xsl:value-of select="php:function('lang', 'To')"
/></label></dt>
+ <dd class="datetime-picker">
+ <input id="field_{position()}_to" name="to_[]"
type="text">
+ <xsl:attribute name="value"><xsl:value-of
select="to_"/></xsl:attribute>
+ </input>
+ </dd>
+ </div></xsl:for-each>
+ </div>
+ <dt><a href="#" id="add-date-link"><xsl:value-of
select="php:function('lang', 'Add another date')" /></a></dt>
+ </dl>
+ </div>
+ <div class="pure-u-1 pure-u-md-1-2 pure-u-lg-1-3">
+ <dl class="form-col">
+ <div class="heading">4. <xsl:value-of
select="php:function('lang', 'Who?')" /></div>
+ <dt><label for="field_from"><xsl:value-of
select="php:function('lang', 'Target audience')" /></label></dt>
+ <dd>
+ <ul id="audience">
+ <xsl:for-each select="audience">
+ <li>
+ <input type="radio" name="audience[]">
+ <xsl:attribute
name="value"><xsl:value-of select="id"/></xsl:attribute>
+ <xsl:if
test="../application/audience=id">
+ <xsl:attribute
name="checked">checked</xsl:attribute>
+ </xsl:if>
+ </input>
+ <label><xsl:value-of
select="name"/></label>
+ </li>
+ </xsl:for-each>
+ </ul>
+ </dd>
+ <dt><label for="field_from"><xsl:value-of
select="php:function('lang', 'Number of participants')" /></label></dt>
+ <dd>
+ <table id="agegroup" class="pure-table
pure-table-bordered">
+ <thead>
+ <tr><th/><th><xsl:value-of
select="php:function('lang', 'Male')" /></th>
+ <th><xsl:value-of select="php:function('lang',
'Female')" /></th></tr>
+ </thead>
+ <tbody id="agegroup_tbody">
+ <xsl:for-each select="agegroups">
+ <xsl:variable name="id"><xsl:value-of
select="id"/></xsl:variable>
+ <tr>
+ <th><xsl:value-of select="name"/></th>
+ <td>
+ <input type="text">
+ <xsl:attribute
name="name">male[<xsl:value-of select="id"/>]</xsl:attribute>
+ <xsl:attribute
name="value"><xsl:value-of select="../application/agegroups/male[../agegroup_id
= $id]"/></xsl:attribute>
+ </input>
+ </td>
+ <td>
+ <input type="text">
+ <xsl:attribute
name="name">female[<xsl:value-of select="id"/>]</xsl:attribute>
+ <xsl:attribute
name="value"><xsl:value-of
select="../application/agegroups/female[../agegroup_id = $id]"/></xsl:attribute>
+ </input>
+ </td>
+ </tr>
+ </xsl:for-each>
+ </tbody>
+ </table>
+ </dd>
+ </dl>
+ </div>
+ <div class="pure-u-1 pure-u-md-1-2 pure-u-1-3">
+ <dl class="form-col">
+ <div class="heading"><xsl:value-of
select="php:function('lang', 'Contact information')" /></div>
+ <dt><label for="field_contact_name"><xsl:value-of
select="php:function('lang', 'Name')" /></label></dt>
+ <dd>
+ <input id="field_contact_name" name="contact_name"
type="text">
+ <xsl:attribute name="value"><xsl:value-of
select="application/contact_name"/></xsl:attribute>
+ </input>
+ </dd>
+ <dt><label for="field_contact_email"><xsl:value-of
select="php:function('lang', 'Email')" /></label></dt>
+ <dd>
+ <input id="field_contact_email" name="contact_email"
type="text">
+ <xsl:attribute name="value"><xsl:value-of
select="application/contact_email"/></xsl:attribute>
+ </input>
+ </dd>
+ <dt><label for="field_contact_phone"><xsl:value-of
select="php:function('lang', 'Phone')" /></label></dt>
+ <dd>
+ <input id="field_contact_phone" name="contact_phone"
type="text">
+ <xsl:attribute name="value"><xsl:value-of
select="application/contact_phone"/></xsl:attribute>
+ </input>
+ </dd>
+ </dl>
+ </div>
+ <div class="pure-u-1 pure-u-md-1-2 pure-u-1-3">
+ <dl class="form-col">
+ <div class="heading"><xsl:value-of
select="php:function('lang', 'responsible applicant')" /> / <xsl:value-of
select="php:function('lang', 'invoice information')" /></div>
+ <xsl:copy-of
select="phpgw:booking_customer_identifier(application, '')"/>
+ </dl>
+ </div>
+ <div class="pure-u-1 pure-u-md-1-2 pure-u-1-3">
+ <dl class="form-col">
+ <div class="heading"><br /><xsl:value-of
select="php:function('lang', 'Terms and conditions')" /></div>
+ <br/>
+ <div id='regulation_documents'/>
+ </dl>
+ </div>
+ </div>
+ <div class="pure-g">
+ <div class="pure-u-1">
+ <div class="form-buttons">
+ <input type="submit">
+ <xsl:attribute name="value"><xsl:value-of
select="php:function('lang', 'Create')"/></xsl:attribute>
+ </input>
+ <a class="cancel">
+ <xsl:attribute name="href"><xsl:value-of
select="application/cancel_link"/></xsl:attribute>
+ <xsl:value-of select="php:function('lang', 'Cancel')"
/>
+ </a>
+ </div>
+ </div>
+ </div>
+
+
+
+
+
+
+
+
+ <!--dl class="form">
+
+ </dl>
+ <dl class="form">
+
+ </dl>
+ <div class="clr"/>
+ <dl class="form-col">
+
+ </dl>
+ <dl class="form-col">
+
+ </dl>
+ <dl class="form-col">
+
+ </dl>
+ <div class="clr"/>
+ <dl class="form-col">
+
+ </dl>
+ <dl class="form-col">
+
+ </dl>
+ <dl class="form-col">
+
+ </dl-->
+
+ </form>
+ </div>
+ <script type="text/javascript">
+ var initialDocumentSelection = <xsl:value-of
select="application/accepted_documents_json"/>;
+ var initialAcceptAllTerms = true;
+ var initialSelection = <xsl:value-of
select="application/resources_json"/>;
+ var initialAudience = <xsl:value-of
select="application/audience_json"/>;
+ var lang = <xsl:value-of select="php:function('js_lang',
'From', 'To', 'Resource Type', 'Name', 'Accepted', 'Document', 'You must accept
to follow all terms and conditions of lease first.')"/>;
+ </script>
+</xsl:template>
Added: branches/dev-syncromind/bookingfrontend/templates/base/booking.xsl
===================================================================
--- branches/dev-syncromind/bookingfrontend/templates/base/booking.xsl
(rev 0)
+++ branches/dev-syncromind/bookingfrontend/templates/base/booking.xsl
2015-11-05 23:58:34 UTC (rev 14287)
@@ -0,0 +1,67 @@
+<xsl:template match="data" xmlns:php="http://php.net/xsl">
+ <div id="content">
+ <ul class="pathway">
+ <li><a href="{booking/bookings_link}"><xsl:value-of
select="php:function('lang', 'Bookings')" /></a></li>
+ <li>#<xsl:value-of select="booking/id"/> (<xsl:value-of
select="booking/activity_name"/>)</li>
+ </ul>
+
+ <xsl:call-template name="msgbox"/>
+ <!--xsl:call-template name="yui_booking_i18n"/-->
+
+ <dl class="proplist-col">
+ <dt><xsl:value-of select="php:function('lang', 'From')" /></dt>
+ <dd><xsl:value-of select="php:function('pretty_timestamp',
booking/from_)"/></dd>
+ <dt><xsl:value-of select="php:function('lang', 'To')" /></dt>
+ <dd><xsl:value-of select="php:function('pretty_timestamp',
booking/to_)"/></dd>
+ <dt><xsl:value-of select="php:function('lang', 'Cost')" /></dt>
+ <dd><xsl:value-of select="booking/cost"/></dd>
+ </dl>
+ <dl class="proplist-col">
+ <dt><xsl:value-of select="php:function('lang', 'Season')" /></dt>
+ <dd><xsl:value-of select="booking/season_name"/></dd>
+ <dt><xsl:value-of select="php:function('lang', 'Group')" /></dt>
+ <dd><xsl:value-of select="booking/group_name"/></dd>
+ </dl>
+ <dl class="proplist-col">
+ <dt><xsl:value-of select="php:function('lang', 'Resources')"
/></dt>
+ <dd><div id="resources_container"/></dd>
+ </dl>
+
+ <div class="form-buttons">
+ <xsl:if test="booking/permission/write">
+ <button>
+ <xsl:attribute
name="onclick">window.location.href="<xsl:value-of
select="booking/edit_link"/>"</xsl:attribute>
+ <xsl:value-of select="php:function('lang', 'Edit')"
/>
+ </button>
+ <button>
+ <xsl:attribute
name="onclick">window.location.href="<xsl:value-of
select="booking/delete_link"/>"</xsl:attribute>
+ <xsl:value-of select="php:function('lang', 'Delete
booking')" />
+ </button>
+ </xsl:if>
+ </div>
+ </div>
+
+ <script type="text/javascript">
+ var resourcesIds = '<xsl:value-of select="booking/resource_ids" />';
+ var lang = <xsl:value-of select="php:function('js_lang', 'Name',
'Resource Type')" />;
+
+ <![CDATA[
+ var resourceURL =
'index.php?menuaction=bookingfrontend.uiresource.index_json&sort=name&phpgw_return_as=json&'
+ resourcesIds;
+ ]]>
+ var colDefsResources = [{key: 'name', label: lang['Name'], formatter:
genericLink}, {key: 'type', label: lang['Resource Type']}];
+ createTable('resources_container', resourceURL, colDefsResources,
'results');
+ </script>
+
+<!--script type="text/javascript">
+ var resourceIds = '<xsl:value-of select="booking/resource_ids"/>';
+ var lang = <xsl:value-of select="php:function('js_lang', 'Name',
'Resource Type')"/>;
+ <![CDATA[
+YAHOO.util.Event.addListener(window, "load", function() {
+ var url =
'index.php?menuaction=booking.uiresource.index&sort=name&phpgw_return_as=json&'
+ resourceIds;
+ var colDefs = [{key: 'name', label: lang['Name'], formatter:
YAHOO.booking.formatLink}, {key: 'type', label: lang['Resource Type']}];
+ YAHOO.booking.inlineTableHelper('resources_container', url, colDefs);
+});
+]]>
+</script-->
+
+</xsl:template>
Modified:
branches/dev-syncromind/bookingfrontend/templates/base/booking_edit.xsl
===================================================================
--- branches/dev-syncromind/bookingfrontend/templates/base/booking_edit.xsl
2015-11-05 23:54:56 UTC (rev 14286)
+++ branches/dev-syncromind/bookingfrontend/templates/base/booking_edit.xsl
2015-11-05 23:58:34 UTC (rev 14287)
@@ -71,6 +71,7 @@
<dl class="form-col">
<dt><label for="field_org"><xsl:value-of
select="php:function('lang', 'Organization')"/></label></dt>
<dd>
+ <input id="field_organization_id"
name="organization_id" type="hidden" value="{booking/organization_id}"/>
<xsl:value-of select="booking/organization_name"/>
</dd>
</dl>
Modified: branches/dev-syncromind/bookingfrontend/templates/base/building.xsl
===================================================================
--- branches/dev-syncromind/bookingfrontend/templates/base/building.xsl
2015-11-05 23:54:56 UTC (rev 14286)
+++ branches/dev-syncromind/bookingfrontend/templates/base/building.xsl
2015-11-05 23:58:34 UTC (rev 14287)
@@ -105,6 +105,10 @@
createTable('documents_container', documentURL,
colDefsDocument);
createTable('building_users_container', building_usersURL,
colDefsBuilding_users, rBuilding_users, '', paginatorTableBuilding_users);
//createnInlineImages('images_container',
'document_buildingURL');
+
+ $.get(document_buildingURL, function(data){
+ console.log(data);
+ });
/*
<![CDATA[
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Fmsystem-commits] [14287],
Saul <=