[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Fmsystem-commits] [10431]
From: |
Torstein |
Subject: |
[Fmsystem-commits] [10431] |
Date: |
Fri, 02 Nov 2012 10:55:20 +0000 |
Revision: 10431
http://svn.sv.gnu.org/viewvc/?view=rev&root=fmsystem&revision=10431
Author: vator
Date: 2012-11-02 10:55:19 +0000 (Fri, 02 Nov 2012)
Log Message:
-----------
Modified Paths:
--------------
trunk/logistic/inc/class.uiactivity.inc.php
trunk/logistic/inc/class.uirequirement_resource_allocation.inc.php
trunk/logistic/setup/phpgw_no.lang
trunk/logistic/templates/base/activity/activity_tabs.xsl
trunk/logistic/templates/base/activity/add_activity_item.xsl
Added Paths:
-----------
trunk/logistic/templates/base/allocation/book_resources.xsl
Removed Paths:
-------------
trunk/logistic/templates/base/allocation/allocation_suggestions.xsl
Modified: trunk/logistic/inc/class.uiactivity.inc.php
===================================================================
--- trunk/logistic/inc/class.uiactivity.inc.php 2012-11-02 10:02:53 UTC (rev
10430)
+++ trunk/logistic/inc/class.uiactivity.inc.php 2012-11-02 10:55:19 UTC (rev
10431)
@@ -200,7 +200,7 @@
'text' =>
lang('t_view_requirements'),
'action' =>
$GLOBALS['phpgw']->link('/index.php',array
(
- 'menuaction' =>
'logistic.uirequirement.index'
+ 'menuaction' =>
'logistic.uiactivity.view_resource_allocation'
)),
'parameters' =>
json_encode($parameters)
);
Modified: trunk/logistic/inc/class.uirequirement_resource_allocation.inc.php
===================================================================
--- trunk/logistic/inc/class.uirequirement_resource_allocation.inc.php
2012-11-02 10:02:53 UTC (rev 10430)
+++ trunk/logistic/inc/class.uirequirement_resource_allocation.inc.php
2012-11-02 10:55:19 UTC (rev 10431)
@@ -342,6 +342,7 @@
$so_entity =
CreateObject('property.soentity',$entity_id,$cat_id);
$allocation_suggestions =
$so_entity->get_eav_list($criterias_array);
+ $activity = $this->so_activity->get_single(
$requirement->get_activity_id() );
$data = array
(
@@ -351,8 +352,8 @@
'allocation_suggestions' =>
$allocation_suggestions,
'editable'
=> true
);
-
-
self::render_template_xsl(array('allocation/allocation_suggestions'), $data);
+
+
self::render_template_xsl(array('allocation/book_resources'), $data);
}
public function save()
Modified: trunk/logistic/setup/phpgw_no.lang
===================================================================
--- trunk/logistic/setup/phpgw_no.lang 2012-11-02 10:02:53 UTC (rev 10430)
+++ trunk/logistic/setup/phpgw_no.lang 2012-11-02 10:55:19 UTC (rev 10431)
@@ -74,4 +74,5 @@
Activity details logistic no Detaljer for aktivitet
Status requirement logistic no Status behov
select logistic no Velg
-Add project logistic no Nytt prosjekt
\ No newline at end of file
+Add project logistic no Nytt prosjekt
+Booking of resources logistic no Bestilling av ressurser
\ No newline at end of file
Modified: trunk/logistic/templates/base/activity/activity_tabs.xsl
===================================================================
--- trunk/logistic/templates/base/activity/activity_tabs.xsl 2012-11-02
10:02:53 UTC (rev 10430)
+++ trunk/logistic/templates/base/activity/activity_tabs.xsl 2012-11-02
10:55:19 UTC (rev 10431)
@@ -49,6 +49,8 @@
<xsl:when test="view = 'requirement_overview'">
<xsl:choose>
<xsl:when test="activity/id != '' or
activity/id != 0">
+
+ <!-- =========== HEADING ==============
-->
<h1 style="float:left;">
<span>
<xsl:value-of
select="php:function('lang', 'Add criterias')" />
@@ -57,11 +59,25 @@
<xsl:value-of
select="activity/name" />
</span>
</h1>
+
+ <!-- =========== BREADCRUMB
============== -->
+ <div id="breadcrumb">
+ <img
src="logistic/images/arrow_right.png" />
+ <xsl:value-of
disable-output-escaping="yes" select="breadcrumb" />
+ </div>
</xsl:when>
<xsl:otherwise>
+
+ <!-- =========== HEADING ==============
-->
<h1 style="float:left;">
<xsl:value-of
select="php:function('lang', 'Add criterias')" />
</h1>
+
+ <!-- =========== BREADCRUMB
============== -->
+ <div id="breadcrumb">
+ <img
src="logistic/images/arrow_right.png" />
+ <xsl:value-of
disable-output-escaping="yes" select="breadcrumb" />
+ </div>
</xsl:otherwise>
</xsl:choose>
Modified: trunk/logistic/templates/base/activity/add_activity_item.xsl
===================================================================
--- trunk/logistic/templates/base/activity/add_activity_item.xsl
2012-11-02 10:02:53 UTC (rev 10430)
+++ trunk/logistic/templates/base/activity/add_activity_item.xsl
2012-11-02 10:55:19 UTC (rev 10431)
@@ -32,28 +32,52 @@
<input type="hidden" name="parent_id"
value="{parent_activity/id}" />
<dl class="proplist-col">
- <xsl:if test="parent_activity/id >
0">
- <dt>
- <xsl:if test="editable">
- <div
style="margin-bottom: 1em;">
- <label
style="display:block;">Velg en annen hovedaktivitet</label>
- <select
id="select_activity" name="parent_activity_id" class="selectLocation">
-
<option>Velg aktivitet</option>
-
<xsl:for-each select="activities">
- <option value="{id}">
- <xsl:if
test="activity/parent_id = id">
-
<xsl:attribute name="selected">
-
selected
-
</xsl:attribute>
- </xsl:if>
- <xsl:value-of
disable-output-escaping="yes" select="name"/>
- </option>
-
</xsl:for-each>
- </select>
- </div>
- </xsl:if>
- </dt>
- </xsl:if>
+ <xsl:choose>
+ <xsl:when
test="parent_activity/id > 0">
+ <dt>
+ <xsl:if
test="editable">
+ <div
style="margin-bottom: 1em;">
+
<label style="display:block;">Velg en annen hovedaktivitet</label>
+
<select id="select_activity" name="parent_activity_id" class="selectLocation">
+
<option>Velg aktivitet</option>
+
<xsl:for-each select="activities">
+ <option
value="{id}">
+
<xsl:if test="activity/parent_id = id">
+
<xsl:attribute name="selected">
+
selected
+
</xsl:attribute>
+
</xsl:if>
+
<xsl:value-of disable-output-escaping="yes" select="name"/>
+
</option>
+
</xsl:for-each>
+
</select>
+ </div>
+
</xsl:if>
+ </dt>
+ </xsl:when>
+ <xsl:otherwise>
+ <dt>
+ <xsl:if
test="editable">
+ <div
style="margin-bottom: 1em;">
+
<label style="display:block;">Er aktiviteten en underaktivitet?</label>
+
<select id="select_activity" name="parent_activity_id" class="selectLocation">
+
<option>Velg hovedaktivitet</option>
+
<xsl:for-each select="activities">
+ <option
value="{id}">
+
<xsl:if test="activity/parent_id = id">
+
<xsl:attribute name="selected">
+
selected
+
</xsl:attribute>
+
</xsl:if>
+
<xsl:value-of disable-output-escaping="yes" select="name"/>
+
</option>
+
</xsl:for-each>
+
</select>
+ </div>
+
</xsl:if>
+ </dt>
+ </xsl:otherwise>
+ </xsl:choose>
<dt>
<label for="name"><xsl:value-of
select="php:function('lang','Activity name')" /></label>
</dt>
Deleted: trunk/logistic/templates/base/allocation/allocation_suggestions.xsl
===================================================================
--- trunk/logistic/templates/base/allocation/allocation_suggestions.xsl
2012-11-02 10:02:53 UTC (rev 10430)
+++ trunk/logistic/templates/base/allocation/allocation_suggestions.xsl
2012-11-02 10:55:19 UTC (rev 10431)
@@ -1,88 +0,0 @@
-<xsl:template match="data" xmlns:php="http://php.net/xsl">
-<xsl:variable name="date_format"><xsl:value-of
select="php:function('get_phpgw_info',
'user|preferences|common|dateformat')"/></xsl:variable>
-
-<xsl:call-template name="yui_phpgw_i18n"/>
-<div id="resource-allocation" class="yui-navset yui-navset-top">
- <h1>
- <xsl:value-of select="php:function('lang', 'Allocation of
requirement for')"/> <xsl:value-of select="activity/name"/>
- </h1>
-
- <div class="content-wrp">
-
- <div id="requirement-wrp">
- <ul>
- <li>
- <label
for="start_date">Startdato</label><span><xsl:value-of
select="php:function('date', $date_format,
number(requirement/start_date))"/></span>
- </li>
- <li>
- <label for="end_date">Sluttdato</label>
- <span><xsl:value-of
select="php:function('date', $date_format,
number(requirement/end_date))"/></span>
- </li>
- <li>
- <label for="no_of_items">Antall</label>
- <span><xsl:value-of
select="requirement/no_of_items" /></span>
- </li>
- </ul>
-
- <h3>Kriterier</h3>
- <xsl:for-each select="view_criterias_array">
- <ul>
- <li>
- <label><xsl:value-of
select="cust_attribute_data/input_text"/></label>
- <span
style="margin-right:5px;"><xsl:value-of select="operator"/></span>
- <xsl:choose>
- <xsl:when
test="cust_attribute_data/column_info/type = 'LB'">
-
<xsl:for-each select="cust_attribute_data/choice">
-
<xsl:if test="//value = id">
-
<span><xsl:value-of select="value"/></span>
-
</xsl:if>
-
</xsl:for-each>
- </xsl:when>
- <xsl:otherwise>
-
<span><xsl:value-of select="value"/></span>
- </xsl:otherwise>
- </xsl:choose>
- </li>
- </ul>
- </xsl:for-each>
- </div>
-
- <xsl:variable name="action_url">
- <xsl:value-of
select="php:function('get_phpgw_link', '/index.php',
'menuaction:logistic.uirequirement_resource_allocation.save')" />
- </xsl:variable>
- <form action="{$action_url}" method="post">
- <input type="hidden" name="requirement_id"
value="{requirement/id}" />
-
- <div id="resource-list">
- <div class="resource heading">
- <span class="desc">Kort
beskrivelse</span>
- <span
class="loc_id">Lokasjons id</span>
- <span
class="type">Type</span>
- <span
class="loc_code">Lokasjons kode</span>
- </div>
- <xsl:for-each
select="allocation_suggestions">
-
- <div>
- <xsl:choose>
- <xsl:when
test="(position() mod 2) != 1">
- <xsl:attribute
name="class">resource odd</xsl:attribute>
- </xsl:when>
- <xsl:otherwise>
- <xsl:attribute
name="class">resource even</xsl:attribute>
- </xsl:otherwise>
- </xsl:choose>
-
- <input type="checkbox"
value="{id}" name="chosen_resources[]" />
- <span
class="desc"><xsl:value-of select="short_description" /></span>
- <span
class="loc_id"><xsl:value-of select="location_id" /></span>
- <span
class="type"><xsl:value-of select="type_lokale" /></span>
- <span
class="loc_code"><xsl:value-of select="location_code" /></span>
- </div>
- </xsl:for-each>
- </div>
-
- <input type="submit" value="Lagre" />
- </form>
- </div>
-</div>
-</xsl:template>
\ No newline at end of file
Copied: trunk/logistic/templates/base/allocation/book_resources.xsl (from rev
10423, trunk/logistic/templates/base/allocation/allocation_suggestions.xsl)
===================================================================
--- trunk/logistic/templates/base/allocation/book_resources.xsl
(rev 0)
+++ trunk/logistic/templates/base/allocation/book_resources.xsl 2012-11-02
10:55:19 UTC (rev 10431)
@@ -0,0 +1,96 @@
+<xsl:template match="data" xmlns:php="http://php.net/xsl">
+<xsl:variable name="date_format"><xsl:value-of
select="php:function('get_phpgw_info',
'user|preferences|common|dateformat')"/></xsl:variable>
+
+<xsl:call-template name="yui_phpgw_i18n"/>
+<div id="resource-allocation" class="yui-navset yui-navset-top">
+ <h1>
+ <xsl:value-of select="php:function('lang', 'Booking of
resources')"/> for <xsl:value-of select="activity/name"/>
+ </h1>
+
+ <div class="content-wrp">
+
+ <div id="requirement-wrp">
+ <h3>Detaljer for behov</h3>
+ <ul>
+ <li>
+ <label
for="start_date">Startdato</label><span><xsl:value-of
select="php:function('date', $date_format,
number(requirement/start_date))"/></span>
+ </li>
+ <li>
+ <label for="end_date">Sluttdato</label>
+ <span><xsl:value-of
select="php:function('date', $date_format,
number(requirement/end_date))"/></span>
+ </li>
+ <li>
+ <label for="no_of_items">Antall</label>
+ <span><xsl:value-of
select="requirement/no_of_items" /></span>
+ </li>
+ </ul>
+
+ <h3 style="margin-bottom: 10px;">Kriterier</h3>
+ <xsl:choose>
+ <xsl:when
test="view_criterias_array/child::node()">
+ <xsl:for-each
select="view_criterias_array">
+ <ul>
+ <li>
+
<label><xsl:value-of select="cust_attribute_data/input_text"/></label>
+ <span
style="margin-right:5px;"><xsl:value-of select="operator"/></span>
+
<xsl:choose>
+
<xsl:when test="cust_attribute_data/column_info/type = 'LB'">
+
<xsl:for-each select="cust_attribute_data/choice">
+
<xsl:if test="//value = id">
+
<span><xsl:value-of select="value"/></span>
+
</xsl:if>
+
</xsl:for-each>
+
</xsl:when>
+
<xsl:otherwise>
+
<span><xsl:value-of select="value"/></span>
+
</xsl:otherwise>
+
</xsl:choose>
+ </li>
+ </ul>
+ </xsl:for-each>
+ </xsl:when>
+ <xsl:otherwise>
+ <p
style="margin-top:0;">Ingen kriterier lagt til</p>
+ </xsl:otherwise>
+ </xsl:choose>
+ </div>
+
+ <xsl:variable name="action_url">
+ <xsl:value-of
select="php:function('get_phpgw_link', '/index.php',
'menuaction:logistic.uirequirement_resource_allocation.save')" />
+ </xsl:variable>
+ <form action="{$action_url}" method="post">
+ <input type="hidden" name="requirement_id"
value="{requirement/id}" />
+
+ <div id="resource-list">
+ <div class="resource heading">
+ <span class="desc">Kort
beskrivelse</span>
+ <span
class="loc_id">Lokasjons id</span>
+ <span
class="type">Type</span>
+ <span
class="loc_code">Lokasjons kode</span>
+ </div>
+ <xsl:for-each
select="allocation_suggestions">
+
+ <div>
+ <xsl:choose>
+ <xsl:when
test="(position() mod 2) != 1">
+ <xsl:attribute
name="class">resource odd</xsl:attribute>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:attribute
name="class">resource even</xsl:attribute>
+ </xsl:otherwise>
+ </xsl:choose>
+
+ <input type="checkbox"
value="{id}" name="chosen_resources[]" />
+ <span
class="desc"><xsl:value-of select="short_description" /></span>
+ <span
class="loc_id"><xsl:value-of select="location_id" /></span>
+ <span
class="type"><xsl:value-of select="type_lokale" /></span>
+ <span
class="loc_code"><xsl:value-of select="location_code" /></span>
+ </div>
+ </xsl:for-each>
+ </div>
+
+ <input type="submit" value="Lagre" />
+ </form>
+ </div>
+</div>
+</xsl:template>
\ No newline at end of file
Property changes on: trunk/logistic/templates/base/allocation/book_resources.xsl
___________________________________________________________________
Added: svn:mime-type
+ text/plain
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Fmsystem-commits] [10431],
Torstein <=