[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Fmsystem-commits] [8355]
From: |
Torstein |
Subject: |
[Fmsystem-commits] [8355] |
Date: |
Sat, 17 Dec 2011 07:49:02 +0000 |
Revision: 8355
http://svn.sv.gnu.org/viewvc/?view=rev&root=fmsystem&revision=8355
Author: vator
Date: 2011-12-17 07:49:01 +0000 (Sat, 17 Dec 2011)
Log Message:
-----------
Modified Paths:
--------------
trunk/controller/inc/component/class.calendar_builder.inc.php
trunk/controller/templates/base/css/base.css
trunk/controller/templates/base/view_calendar_month.xsl
trunk/controller/templates/base/view_calendar_year.xsl
trunk/controller/templates/base/view_check_lists.xsl
Modified: trunk/controller/inc/component/class.calendar_builder.inc.php
===================================================================
--- trunk/controller/inc/component/class.calendar_builder.inc.php
2011-12-17 07:45:23 UTC (rev 8354)
+++ trunk/controller/inc/component/class.calendar_builder.inc.php
2011-12-17 07:49:01 UTC (rev 8355)
@@ -29,12 +29,12 @@
if( $period_type == "view_months" )
{
$calendar_array[ date("n", $date)
]["status"] = 0;
- $calendar_array[ date("n", $date)
]["info"] = array("date" => $date);
+ $calendar_array[ date("n", $date)
]["info"] = array("date" => $date, "control_id" => $control->get_id());
}
else if( $period_type == "view_days" )
{
$calendar_array[ date("j", $date)
]["status"] = 0;
- $calendar_array[ date("j", $date)
]["info"] = array("date" => $date);
+ $calendar_array[ date("j", $date)
]["info"] = array("date" => $date, "control_id" => $control->get_id());
}
}
@@ -47,34 +47,47 @@
if( $check_list->get_status() == 0 ){
$check_list_status_info->set_status(0);
+ $status = 0;
}
- else if( $check_list->get_status() == 1 &
$check_list->get_planned_date() == 0)
+ else if( $check_list->get_status() == 1)
{
$check_list_status_info->set_status(1);
+ $status = 1;
}
else if( $check_list->get_status() == 2 &
$check_list->get_completed_date() < $check_list->get_deadline() )
{
$check_list_status_info->set_status(2);
+ $status = 2;
}
else if( $check_list->get_status() == 3 &
$check_list->get_completed_date() > $check_list->get_deadline() )
{
$check_list_status_info->set_status(3);
+ $status = 3;
}
else if( $check_list->get_status() == 4 )
{
$check_list_status_info->set_status(4);
+ $status = 4;
}
+ else if( $check_list->get_status() == 5 )
+ {
+ $check_list_status_info->set_status(5);
+ $status = 5;
+ }
$check_list_status_info->set_deadline(
date("d/m-Y", $check_list->get_deadline()) );
+ echo " " . date("d/m-Y",
$check_list->get_deadline()) . " ";
+ echo $check_list_status_info->get_id();
+
if($period_type == "view_months")
{
- $calendar_array[ date("n",
$check_list->get_deadline()) ]["status"] = 1;
+ $calendar_array[ date("n",
$check_list->get_deadline()) ]["status"] = $status;
$calendar_array[ date("n",
$check_list->get_deadline()) ]["info"] = $check_list_status_info->serialize();
}
else if( $period_type == "view_days" )
{
- $calendar_array[ date("j",
$check_list->get_deadline()) ]["status"] = 1;
+ $calendar_array[ date("j",
$check_list->get_deadline()) ]["status"] = $status;
$calendar_array[ date("j",
$check_list->get_deadline()) ]["info"] = $check_list_status_info->serialize();
}
}
Modified: trunk/controller/templates/base/css/base.css
===================================================================
--- trunk/controller/templates/base/css/base.css 2011-12-17 07:45:23 UTC
(rev 8354)
+++ trunk/controller/templates/base/css/base.css 2011-12-17 07:49:01 UTC
(rev 8355)
@@ -989,4 +989,14 @@
}
#days_view div{
font-weight:bold;
-}
\ No newline at end of file
+}
+.calendar .months {
+ margin-left: 20px;
+ width: 440px;
+ padding:0;
+}
+.calendar .months a{
+ text-decoration: none;
+ color:#000;
+}
+
Modified: trunk/controller/templates/base/view_calendar_month.xsl
===================================================================
--- trunk/controller/templates/base/view_calendar_month.xsl 2011-12-17
07:45:23 UTC (rev 8354)
+++ trunk/controller/templates/base/view_calendar_month.xsl 2011-12-17
07:49:01 UTC (rev 8355)
@@ -1,6 +1,7 @@
<!-- $Id$ -->
<xsl:template match="data" name="view_check_lists"
xmlns:php="http://php.net/xsl">
<xsl:variable name="date_format">d/m-Y</xsl:variable>
+<xsl:variable name="location_code"><xsl:value-of
select="location_array/location_code"/></xsl:variable>
<div id="main_content">
@@ -52,7 +53,6 @@
<xsl:choose>
<xsl:when test="controls_calendar_array/child::node()">
-
<ul style="clear:left;" class="calendar info">
<li class="heading">
<div class="id">ID</div>
@@ -114,15 +114,29 @@
<xsl:text>&date=</xsl:text>
<xsl:value-of select="info/date"/>
<xsl:text>&control_id=</xsl:text>
-
<xsl:value-of select="//control/id"/>
+
<xsl:value-of select="info/control_id"/>
<xsl:text>&location_code=</xsl:text>
-
<xsl:value-of select="//location_array/location_code"/>
+
<xsl:value-of select="$location_code"/>
</xsl:attribute>
<img height="15" src="controller/images/status_icon_yellow.png" />
</a>
</div>
</xsl:when>
<xsl:when test="status = 1">
+
<div>
+
<a class="view_check_list">
+
<xsl:attribute name="href">
+
<xsl:text>index.php?menuaction=controller.uicheck_list.get_check_list_info</xsl:text>
+
<xsl:text>&phpgw_return_as=json</xsl:text>
+
<xsl:text>&check_list_id=</xsl:text>
+
<xsl:value-of select="info/id"/>
+
</xsl:attribute>
+
<span style="display:none"><xsl:value-of
select="info/id"/></span>
+
<img height="15"
src="controller/images/status_icon_light_green.png" />
+
</a>
+
</div>
+
</xsl:when>
+
<xsl:when test="status = 2">
<div style="position:relative;">
<div id="info_box" style="position:absolute;display:none;"></div>
<a class="view_check_list">
@@ -137,6 +151,11 @@
</a>
</div>
</xsl:when>
+
<xsl:when test="status = 5">
+
<div>
+
<img height="12" src="controller/images/status_icon_red_cross.png" />
+
</div>
+
</xsl:when>
<xsl:otherwise>
<div></div>
</xsl:otherwise>
Modified: trunk/controller/templates/base/view_calendar_year.xsl
===================================================================
--- trunk/controller/templates/base/view_calendar_year.xsl 2011-12-17
07:45:23 UTC (rev 8354)
+++ trunk/controller/templates/base/view_calendar_year.xsl 2011-12-17
07:49:01 UTC (rev 8355)
@@ -25,6 +25,7 @@
<div class="date">Slutt dato</div>
<div
class="frequency">Frekvenstype</div>
<div
class="frequency">Frekvensintervall</div>
+ <div class="months">
<xsl:for-each select="heading_array">
<div>
<a>
@@ -39,6 +40,7 @@
</a>
</div>
</xsl:for-each>
+ </div>
</li>
<xsl:for-each select="controls_calendar_array">
@@ -69,6 +71,7 @@
<div class="frequency">
<xsl:value-of
select="control/repeat_interval"/>
</div>
+ <div class="months">
<xsl:for-each
select="calendar_array">
<xsl:choose>
<xsl:when
test="status = 0">
@@ -120,6 +123,7 @@
</xsl:otherwise>
</xsl:choose>
</xsl:for-each>
+ </div>
</li>
</xsl:for-each>
</xsl:when>
Modified: trunk/controller/templates/base/view_check_lists.xsl
===================================================================
--- trunk/controller/templates/base/view_check_lists.xsl 2011-12-17
07:45:23 UTC (rev 8354)
+++ trunk/controller/templates/base/view_check_lists.xsl 2011-12-17
07:49:01 UTC (rev 8355)
@@ -12,11 +12,11 @@
<fieldset class="check_list_details">
<label>Tittel</label><xsl:value-of
select="control_as_array/title"/><br/>
<label>Startdato</label>
- <xsl:if test="control_as_array/start_date != ''">
+ <xsl:if test="control_as_array/start_date != 0">
<xsl:value-of select="php:function('date',
$date_format, number(control_as_array/start_date))"/><br/>
</xsl:if>
<label>Sluttdato</label>
- <xsl:if test="control_as_array/end_date != ''">
+ <xsl:if test="control_as_array/end_date != 0">
<xsl:value-of select="php:function('date',
$date_format, number(control_as_array/end_date))"/><br/>
</xsl:if>
<label>Frekvenstype</label><xsl:value-of
select="control_as_array/repeat_type"/><br/>
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Fmsystem-commits] [8355],
Torstein <=