fmsystem-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Fmsystem-commits] [9203]


From: Torstein
Subject: [Fmsystem-commits] [9203]
Date: Sun, 22 Apr 2012 08:29:23 +0000

Revision: 9203
          http://svn.sv.gnu.org/viewvc/?view=rev&root=fmsystem&revision=9203
Author:   vator
Date:     2012-04-22 08:29:22 +0000 (Sun, 22 Apr 2012)
Log Message:
-----------


Modified Paths:
--------------
    trunk/controller/inc/class.uicalendar.inc.php
    trunk/controller/js/controller/ajax.js
    trunk/controller/templates/base/calendar/check_list_status_checker.xsl
    trunk/controller/templates/base/calendar/view_calendar_month.xsl
    trunk/controller/templates/base/calendar/view_calendar_year.xsl
    trunk/controller/templates/base/check_list/add_check_list.xsl
    trunk/controller/templates/base/css/base.css

Added Paths:
-----------
    trunk/controller/templates/base/calendar/view_calendar_month_bac.xsl

Modified: trunk/controller/inc/class.uicalendar.inc.php
===================================================================
--- trunk/controller/inc/class.uicalendar.inc.php       2012-04-22 07:54:40 UTC 
(rev 9202)
+++ trunk/controller/inc/class.uicalendar.inc.php       2012-04-22 08:29:22 UTC 
(rev 9203)
@@ -167,7 +167,7 @@
                        self::add_javascript('controller', 'controller', 
'jquery.js');
                        self::add_javascript('controller', 'controller', 
'ajax.js');
                        
-                       
self::render_template_xsl('calendar/view_calendar_month', $data);
+                       
self::render_template_xsl(array('calendar/view_calendar_month', 
'calendar/check_list_status_checker'), $data);
                }
                
                public function view_calendar_for_year()
@@ -261,7 +261,7 @@
                                'year'                                    => 
$year
                        );
                        
-                       
self::render_template_xsl('calendar/view_calendar_year', $data);
+                       self::render_template_xsl( 
array('calendar/view_calendar_year', 'calendar/check_list_status_checker'), 
$data);
                        self::add_javascript('controller', 'controller', 
'jquery.js');
                        self::add_javascript('controller', 'controller', 
'ajax.js');
                }

Modified: trunk/controller/js/controller/ajax.js
===================================================================
--- trunk/controller/js/controller/ajax.js      2012-04-22 07:54:40 UTC (rev 
9202)
+++ trunk/controller/js/controller/ajax.js      2012-04-22 08:29:22 UTC (rev 
9203)
@@ -834,24 +834,7 @@
                return false;
        });
        
-       /* ============================ PUTS BORDER AROUND DATE WHEN ITS 
CLICKED  ======================== */
        
-       $("#calendar_dates span").click(function(){
-               var thisSpan = $(this);
-               
-               $("#calendar_dates span").css("border", "2px solid black");
-               $(thisSpan).css("border", "2px solid red");
-               
-               var date = $(thisSpan).text();
-               var day = date.substring(0, date.indexOf("/"));
-               var month = date.substring(date.indexOf("/")+1, 
date.indexOf("-"));
-               var year = date.substring(date.indexOf("-")+1, date.length);
-               
-               var valid_save_date = year + "-" + month + "-" + day;  
-               
-               $("#deadline_date").val(valid_save_date);
-       });
-       
        $(".frm_save_check_item").live("click", function(e){
                var thisForm = $(this);
                var submitBnt = $(thisForm).find("input[type='submit']");

Modified: trunk/controller/templates/base/calendar/check_list_status_checker.xsl
===================================================================
--- trunk/controller/templates/base/calendar/check_list_status_checker.xsl      
2012-04-22 07:54:40 UTC (rev 9202)
+++ trunk/controller/templates/base/calendar/check_list_status_checker.xsl      
2012-04-22 08:29:22 UTC (rev 9203)
@@ -1,19 +1,13 @@
 <!-- $Id: view_calendar_month.xsl 9200 2012-04-21 20:05:34Z vator $ -->
 <xsl:template name="check_list_status_checker" 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>
-<xsl:variable name="view_location_code"><xsl:value-of 
select="view_location_code"/></xsl:variable>
- -->
  
- <xsl:param name="status" />
+ 
  <xsl:param name="location_code" />
  
                <xsl:choose>
                        <xsl:when test="status = 'CONTROL_REGISTERED'">
                                <div>
                                <a>
-                               <!-- 
                                        <xsl:attribute name="href">
                                                
<xsl:text>index.php?menuaction=controller.uicheck_list.add_check_list</xsl:text>
                                                <xsl:text>&amp;date=</xsl:text>
@@ -23,12 +17,10 @@
                                                
<xsl:text>&amp;location_code=</xsl:text>
                                                <xsl:value-of 
select="$location_code"/>
                                        </xsl:attribute>
-                                        -->
                                        <img height="15" 
src="controller/images/status_icon_yellow_ring.png" />
                                </a>
                                </div>
                        </xsl:when>
-                       <!-- 
                        <xsl:when test="status = 'CONTROL_PLANNED'">
                                <div>
                                <a>
@@ -132,12 +124,9 @@
                                        <img height="15" 
src="controller/images/status_icon_red_cross.png" />
                                </div>
                        </xsl:when>
-                       -->
-                       
                        <xsl:otherwise>
                                <div></div>
                        </xsl:otherwise>
-                       
                </xsl:choose>
                                
 </xsl:template>

Modified: trunk/controller/templates/base/calendar/view_calendar_month.xsl
===================================================================
--- trunk/controller/templates/base/calendar/view_calendar_month.xsl    
2012-04-22 07:54:40 UTC (rev 9202)
+++ trunk/controller/templates/base/calendar/view_calendar_month.xsl    
2012-04-22 08:29:22 UTC (rev 9203)
@@ -107,131 +107,11 @@
                        </div>
                        <div class="days_wrp">
                                <xsl:for-each select="calendar_array">
-                                       <xsl:choose>
-                                                       <xsl:when test="status 
= 'CONTROL_REGISTERED'">
-                                                               <div>
-                                                               <a>
-                                                                       
<xsl:attribute name="href">
-                                                                               
<xsl:text>index.php?menuaction=controller.uicheck_list.add_check_list</xsl:text>
-                                                                               
<xsl:text>&amp;date=</xsl:text>
-                                                                               
<xsl:value-of select="info/date"/>
-                                                                               
<xsl:text>&amp;control_id=</xsl:text>
-                                                                               
<xsl:value-of select="info/control_id"/>
-                                                                               
<xsl:text>&amp;location_code=</xsl:text>
-                                                                               
<xsl:value-of select="$location_code"/>
-                                                                       
</xsl:attribute>
-                                                                       <img 
height="15" src="controller/images/status_icon_yellow_ring.png" />
-                                                               </a>
-                                                               </div>
-                                                       </xsl:when>
-                                                       <xsl:when test="status 
= 'CONTROL_PLANNED'">
-                                                               <div>
-                                                               <a>
-                                                                       
<xsl:attribute name="href">
-                                                                               
<xsl:text>index.php?menuaction=controller.uicheck_list.edit_check_list</xsl:text>
-                                                                               
<xsl:text>&amp;check_list_id=</xsl:text>
-                                                                               
<xsl:value-of select="info/check_list_id"/>
-                                                                       
</xsl:attribute>
-                                                                       <img 
height="15" src="controller/images/status_icon_yellow.png" />
-                                                               </a>
-                                                               </div>
-                                                       </xsl:when>
-                                                       <xsl:when test="status 
= 'CONTROL_NOT_DONE_WITH_PLANNED_DATE'">
-                                                               <div>
-                                                               <a>
-                                                                       
<xsl:attribute name="href">
-                                                                               
<xsl:text>index.php?menuaction=controller.uicheck_list.edit_check_list</xsl:text>
-                                                                               
<xsl:text>&amp;check_list_id=</xsl:text>
-                                                                               
<xsl:value-of select="info/check_list_id"/>
-                                                                       
</xsl:attribute>
-                                                                       <img 
height="15" src="controller/images/status_red_cross.png" />
-                                                               </a>
-                                                               </div>
-                                               </xsl:when>
-                                                       <xsl:when test="status 
= 'CONTROL_DONE_IN_TIME_WITHOUT_ERRORS'">
-                                                               <div>
-                                                                       <a>
-                                                                       
<xsl:attribute name="href">
-                                                                               
<xsl:text>index.php?menuaction=controller.uicheck_list.edit_check_list</xsl:text>
-                                                                               
<xsl:text>&amp;check_list_id=</xsl:text>
-                                                                               
<xsl:value-of select="info/check_list_id"/>
-                                                                       
</xsl:attribute>
-                                                                               
<span style="display:none"><xsl:value-of select="info/id"/></span>
-                                                                               
<img height="15" src="controller/images/status_icon_dark_green.png" />
-                                                                       </a>
-                                                               </div>
-                                                       </xsl:when>
-                                                       <xsl:when test="status 
= 'CONTROL_DONE_OVER_TIME_WITHOUT_ERRORS'">
-                                                               <div 
style="position:relative;">
-                                                               <div 
id="info_box"></div>
-                                                                       <a>
-                                                                       
<xsl:attribute name="href">
-                                                                               
<xsl:text>index.php?menuaction=controller.uicheck_list.edit_check_list</xsl:text>
-                                                                               
<xsl:text>&amp;check_list_id=</xsl:text>
-                                                                               
<xsl:value-of select="info/check_list_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 
= 'control_accomplished_with_errors'">
-                                                               <div 
style="position:relative;background: 
url(controller/images/status_icon_red_empty.png) no-repeat 50% 50%;">
-                                                                       <div 
id="info_box"></div>
-                                                               <a 
class="view_check_list">
-                                                                               
<xsl:attribute name="href">
-                                                                               
        
<xsl:text>index.php?menuaction=controller.uicheck_list.edit_check_list</xsl:text>
-                                                                               
        <xsl:text>&amp;check_list_id=</xsl:text>
-                                                                               
        <xsl:value-of select="info/check_list_id"/>
-                                                                               
</xsl:attribute>
-                                                                               
<span style="display:none">
-                                                                               
        <xsl:text>&amp;check_list_id=</xsl:text><xsl:value-of 
select="info/check_list_id"/>
-                                                                               
        <xsl:text>&amp;phpgw_return_as=json</xsl:text>
-                                                                               
</span>
-                                                                               
<xsl:value-of select="info/num_open_cases"/>
-                                                                       </a>
-                                                               </div>
-                                                       </xsl:when>
-                                                       <xsl:when test="status 
= 'control_not_accomplished_with_info'">
-                                                               <div 
style="position:relative;">
-                                                               <div 
id="info_box"></div>
-                                                                       <a>
-                                                                       
<xsl:attribute name="href">
-                                                                               
<xsl:text>index.php?menuaction=controller.uicheck_list.edit_check_list</xsl:text>
-                                                                               
<xsl:text>&amp;check_list_id=</xsl:text>
-                                                                               
<xsl:value-of select="info/check_list_id"/>
-                                                                       
</xsl:attribute>
-                                                                               
<span style="display:none"><xsl:value-of select="info/id"/></span>
-                                                                               
<img height="15" src="controller/images/status_icon_red_cross.png" />
-                                                                       </a>
-                                                               </div>
-                                                       </xsl:when>
-                                                       <xsl:when test="status 
= 'control_not_accomplished'">
-                                                               <div>
-                                                                       <a>
-                                                                               
<xsl:attribute name="href">
-                                                                               
        
<xsl:text>index.php?menuaction=controller.uicheck_list.add_check_list</xsl:text>
-                                                                               
        <xsl:text>&amp;date=</xsl:text>
-                                                                               
        <xsl:value-of select="info/date"/>
-                                                                               
        <xsl:text>&amp;control_id=</xsl:text>
-                                                                               
        <xsl:value-of select="info/control_id"/>
-                                                                               
        <xsl:text>&amp;location_code=</xsl:text>
-                                                                               
        <xsl:value-of select="$location_code"/>
-                                                                               
</xsl:attribute>
-                                                                               
<img height="15" src="controller/images/status_icon_red_cross.png" />
-                                                                       </a>
-                                                               </div>
-                                                       </xsl:when>
-                                                       <xsl:when test="status 
= 'control_canceled'">
-                                                               <div>
-                                                                       <img 
height="15" src="controller/images/status_icon_red_cross.png" />
-                                                               </div>
-                                                       </xsl:when>
-                                                       <xsl:otherwise>
-                                                               <div></div>
-                                                       </xsl:otherwise>
-                                               </xsl:choose>
                                        
+                                       <xsl:call-template 
name="check_list_status_checker" >
+                                               <xsl:with-param 
name="location_code"><xsl:value-of 
select="$view_location_code"/></xsl:with-param>
+                                       </xsl:call-template>
+                                       
                                </xsl:for-each>
                                </div>
                                </li>

Added: trunk/controller/templates/base/calendar/view_calendar_month_bac.xsl
===================================================================
--- trunk/controller/templates/base/calendar/view_calendar_month_bac.xsl        
                        (rev 0)
+++ trunk/controller/templates/base/calendar/view_calendar_month_bac.xsl        
2012-04-22 08:29:22 UTC (rev 9203)
@@ -0,0 +1,305 @@
+<!-- $Id: view_calendar_month.xsl 9174 2012-04-18 10:54:48Z vator $ -->
+<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>
+<xsl:variable name="view_location_code"><xsl:value-of 
select="view_location_code"/></xsl:variable>
+
+<div id="main_content">
+       <div id="control_plan">
+               <div class="col_1">
+                       <h1><xsl:value-of 
select="location_array/loc1_name"/></h1>
+                       <h3 style="margin:0;font-size:19px;">Kalenderoversikt 
for <xsl:value-of select="period"/><span style="margin-left:5px;"><xsl:value-of 
select="year"/></span></h3>
+               </div>
+               
+               <div class="col_2">
+                       <form action="#">
+                               <input type="hidden" name="period_type" 
value="view_year" />
+                               <input type="hidden" name="year">
+                             <xsl:attribute name="value">
+                               <xsl:value-of select="year"/>
+                             </xsl:attribute>
+                               </input>
+
+                               <select id="choose_my_location">
+                                       <xsl:for-each select="my_locations">
+                                               <xsl:variable 
name="loc_code"><xsl:value-of select="location_code"/></xsl:variable>
+                                               <xsl:choose>
+                                                       <xsl:when 
test="location_code = $view_location_code">
+                                                               <option 
value="{$loc_code}" selected="selected">
+                                                                       
<xsl:value-of disable-output-escaping="yes" select="loc1_name"/>
+                                                               </option>
+                                                       </xsl:when>
+                                                       <xsl:otherwise>
+                                                               <option 
value="{$loc_code}">
+                                                                       
<xsl:value-of disable-output-escaping="yes" select="loc1_name"/>
+                                                               </option>
+                                                       </xsl:otherwise>
+                                               </xsl:choose>
+                                       </xsl:for-each>
+                               </select>                                       
+                       </form>
+                                       
+                       <ul id="icon_color_map">
+                               <li><img height="15" 
src="controller/images/status_icon_yellow_ring.png" /><span>Kontroll satt 
opp</span></li>
+                               <li><img height="15" 
src="controller/images/status_icon_yellow.png" /><span>Kontroll har planlagt 
dato</span></li>
+                               <li><img height="15" 
src="controller/images/status_icon_dark_green.png" /><span>Kontroll gjennomført 
uten åpne saker før frist</span></li>
+                               <li><img height="15" 
src="controller/images/status_icon_light_green.png" /><span>Kontroll 
gjennomført uten åpne saker etter frist</span></li>
+                               <li><img height="15" 
src="controller/images/status_icon_red_empty.png" /><span>Kontroll gjennomført 
med åpne saker</span></li>
+                               <li><img height="15" 
src="controller/images/status_icon_red_cross.png" /><span>Kontroll ikke 
gjennomført</span></li>
+                       </ul>
+               </div>
+               
+               <div id="cal_wrp">
+               <script>
+                       $(document).ready(function() {
+                               $(".move_left").click(function(){
+                                       var leftStrVal = 
$("#days_view").css("left");
+                                       var leftNumVal = 
leftStrVal.substring(0, leftStrVal.indexOf('px'));
+                                       
+                                       if(leftNumVal == -417){
+                                               $("#days_view").stop().animate({
+                                   left: '-=93' 
+                                   }, 800);
+                                       }else if(leftNumVal > -417){
+                                               $("#days_view").stop().animate({
+                                   left: '-=417' 
+                                   }, 800);
+                                       }
+                               });
+                               
+                               $(".move_right").click(function(){
+                                       var leftStrVal = 
$("#days_view").css("left");
+                                       var leftNumVal = 
leftStrVal.substring(0, leftStrVal.indexOf('px'));
+                                       
+                                       if( leftNumVal != 0 ){
+                                               if(leftNumVal == -93){
+                                                       
$("#days_view").stop().animate({
+                                           left: '+=93' 
+                                           }, 800);
+                                               }else if( leftNumVal >= -510 ){
+                                                       
$("#days_view").stop().animate({
+                                           left: '+=417' 
+                                           }, 800);
+                                               }
+                                       }
+                               });
+                       });
+               </script>
+               
+                       <a style="font-weight: bold;font-size: 
14px;float:left;">
+                               <xsl:attribute name="href">
+                                       
<xsl:text>index.php?menuaction=controller.uicalendar.view_calendar_for_year</xsl:text>
+                                       <xsl:text>&amp;year=</xsl:text>
+                                       <xsl:value-of select="year"/>
+                                       <xsl:text>&amp;location_code=</xsl:text>
+                                       <xsl:value-of select="$location_code"/>
+                               </xsl:attribute>
+                               Årsoversikt
+                       </a>
+
+                       <!-- =========================  NAVIGATION BETWEEN 
FIRST AND LAST 14 DAYS IN DAYS CALENDAR  
============================================================= -->           
+                       <div class="nav">
+                               <a class="move_left" href="#"><img 
src="controller/images/arrow_right.png" width="16"/></a>
+                               <a class="move_right" href="#"><img 
src="controller/images/arrow_left.png" width="16"/></a>
+                       </div>
+                       <ul class="calendar month">
+                               <li class="heading">
+                                       <div class="id">ID</div>
+                                       <div class="title">Tittel</div>
+                                       <div class="assigned">Tildelt</div>
+                                       <div class="date">Startdato</div>
+                                       <div class="date">Sluttdato</div>
+                                       <div 
class="frequency">Frekvenstype</div>
+                                       <div 
class="frequency">Frekvensintervall</div>
+                               </li>
+                               <xsl:choose>    
+                                       <xsl:when 
test="controls_calendar_array/child::node()">
+                               <xsl:for-each select="controls_calendar_array">
+                                       <li>
+                                       <div class="id">
+                                               <xsl:value-of 
select="control/id"/>
+                                               </div>
+                                               <div class="title">
+                                               <xsl:value-of 
select="control/title"/>
+                                               </div>
+                                               <div class="assigned">
+                                               <xsl:value-of 
select="control/responsibility_name"/>
+                                               </div>
+                                               <div class="date">
+                                               <xsl:value-of 
select="php:function('date', $date_format, number(control/start_date))"/>
+                                               </div>
+                                               <div class="date">
+                                                       <xsl:choose>
+                                                               <xsl:when 
test="control/end_date != 0">
+                                                               <xsl:value-of 
select="php:function('date', $date_format, number(control/end_date))"/>
+                                                       </xsl:when>
+                                                       <xsl:otherwise>
+                                                               Løpende
+                                                       </xsl:otherwise>
+                                               </xsl:choose>
+                                               </div>
+                                               <div class="frequency">
+                                               <xsl:value-of 
select="control/repeat_type"/>
+                                               </div>
+                                               <div class="frequency">
+                                               <xsl:value-of 
select="control/repeat_interval"/>
+                                               </div>                          
                        
+                                       </li>
+                               </xsl:for-each>
+                                       </xsl:when>
+                                       <xsl:otherwise>
+                                               <div class="cal_info_msg">Ingen 
sjekklister for bygg i angitt periode</div>
+                                       </xsl:otherwise>
+                               </xsl:choose>
+                       </ul>
+                       
+                       <div id="days_wrp">
+                               <ul id="days_view" class="calendar days">
+                                       <li class="heading">
+                                               <xsl:for-each 
select="heading_array">
+                                                       <div 
class="cell"><xsl:value-of select="."/></div>
+                                               </xsl:for-each>
+                                       </li>
+                                       <xsl:choose>    
+                                       <xsl:when 
test="controls_calendar_array/child::node()">
+                                               <xsl:for-each 
select="controls_calendar_array">
+                                               <li>
+                                                       <xsl:for-each 
select="calendar_array">
+                                                               <xsl:choose>
+                                                                               
<xsl:when test="status = 'CONTROL_REGISTERED'">
+                                                                               
        <div class="cell">
+                                                                               
        <a>
+                                                                               
                <xsl:attribute name="href">
+                                                                               
                        
<xsl:text>index.php?menuaction=controller.uicheck_list.add_check_list</xsl:text>
+                                                                               
                        <xsl:text>&amp;date=</xsl:text>
+                                                                               
                        <xsl:value-of select="info/date"/>
+                                                                               
                        <xsl:text>&amp;control_id=</xsl:text>
+                                                                               
                        <xsl:value-of select="info/control_id"/>
+                                                                               
                        <xsl:text>&amp;location_code=</xsl:text>
+                                                                               
                        <xsl:value-of select="$location_code"/>
+                                                                               
                </xsl:attribute>
+                                                                               
                <img height="15" 
src="controller/images/status_icon_yellow_ring.png" />
+                                                                               
        </a>
+                                                                               
        </div>
+                                                                               
</xsl:when>
+                                                                               
<xsl:when test="status = 'CONTROL_PLANNED'">
+                                                                               
        <div class="cell">
+                                                                               
        <a>
+                                                                               
                <xsl:attribute name="href">
+                                                                               
                        
<xsl:text>index.php?menuaction=controller.uicheck_list.edit_check_list</xsl:text>
+                                                                               
                        <xsl:text>&amp;check_list_id=</xsl:text>
+                                                                               
                        <xsl:value-of select="info/check_list_id"/>
+                                                                               
                </xsl:attribute>
+                                                                               
                <img height="15" src="controller/images/status_icon_yellow.png" 
/>
+                                                                               
        </a>
+                                                                               
        </div>
+                                                                               
</xsl:when>
+                                                                               
<xsl:when test="status = 'CONTROL_NOT_DONE_WITH_PLANNED_DATE'">
+                                                                               
        <div class="cell">
+                                                                               
        <a>
+                                                                               
                <xsl:attribute name="href">
+                                                                               
                        
<xsl:text>index.php?menuaction=controller.uicheck_list.edit_check_list</xsl:text>
+                                                                               
                        <xsl:text>&amp;check_list_id=</xsl:text>
+                                                                               
                        <xsl:value-of select="info/check_list_id"/>
+                                                                               
                </xsl:attribute>
+                                                                               
                <img height="15" src="controller/images/status_red_cross.png" />
+                                                                               
        </a>
+                                                                               
        </div>
+                                                                       
</xsl:when>
+                                                                               
<xsl:when test="status = 'CONTROL_DONE_IN_TIME_WITHOUT_ERRORS'">
+                                                                               
        <div class="cell">
+                                                                               
                <a>
+                                                                               
                <xsl:attribute name="href">
+                                                                               
                        
<xsl:text>index.php?menuaction=controller.uicheck_list.edit_check_list</xsl:text>
+                                                                               
                        <xsl:text>&amp;check_list_id=</xsl:text>
+                                                                               
                        <xsl:value-of select="info/check_list_id"/>
+                                                                               
                </xsl:attribute>
+                                                                               
                        <span style="display:none"><xsl:value-of 
select="info/id"/></span>
+                                                                               
                        <img height="15" 
src="controller/images/status_icon_dark_green.png" />
+                                                                               
                </a>
+                                                                               
        </div>
+                                                                               
</xsl:when>
+                                                                               
<xsl:when test="status = 'CONTROL_DONE_OVER_TIME_WITHOUT_ERRORS'">
+                                                                               
        <div class="cell" style="position:relative;">
+                                                                               
        <div id="info_box"></div>
+                                                                               
                <a>
+                                                                               
                <xsl:attribute name="href">
+                                                                               
                        
<xsl:text>index.php?menuaction=controller.uicheck_list.edit_check_list</xsl:text>
+                                                                               
                        <xsl:text>&amp;check_list_id=</xsl:text>
+                                                                               
                        <xsl:value-of select="info/check_list_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 = 'control_accomplished_with_errors'">
+                                                                               
        <div class="cell" style="position:relative;background: 
url(controller/images/status_icon_red_empty.png) no-repeat 50% 50%;">
+                                                                               
                <div id="info_box"></div>
+                                                                               
        <a class="view_check_list">
+                                                                               
                        <xsl:attribute name="href">
+                                                                               
                                
<xsl:text>index.php?menuaction=controller.uicheck_list.edit_check_list</xsl:text>
+                                                                               
                                <xsl:text>&amp;check_list_id=</xsl:text>
+                                                                               
                                <xsl:value-of select="info/check_list_id"/>
+                                                                               
                        </xsl:attribute>
+                                                                               
                        <span style="display:none">
+                                                                               
                                
<xsl:text>&amp;check_list_id=</xsl:text><xsl:value-of 
select="info/check_list_id"/>
+                                                                               
                                <xsl:text>&amp;phpgw_return_as=json</xsl:text>
+                                                                               
                        </span>
+                                                                               
                        <xsl:value-of select="info/num_open_cases"/>
+                                                                               
                </a>
+                                                                               
        </div>
+                                                                               
</xsl:when>
+                                                                               
<xsl:when test="status = 'control_not_accomplished_with_info'">
+                                                                               
        <div class="cell" style="position:relative;">
+                                                                               
        <div id="info_box"></div>
+                                                                               
                <a>
+                                                                               
                <xsl:attribute name="href">
+                                                                               
                        
<xsl:text>index.php?menuaction=controller.uicheck_list.edit_check_list</xsl:text>
+                                                                               
                        <xsl:text>&amp;check_list_id=</xsl:text>
+                                                                               
                        <xsl:value-of select="info/check_list_id"/>
+                                                                               
                </xsl:attribute>
+                                                                               
                        <span style="display:none"><xsl:value-of 
select="info/id"/></span>
+                                                                               
                        <img height="15" 
src="controller/images/status_icon_red_cross.png" />
+                                                                               
                </a>
+                                                                               
        </div>
+                                                                               
</xsl:when>
+                                                                               
<xsl:when test="status = 'control_not_accomplished'">
+                                                                               
        <div class="cell">
+                                                                               
                <a>
+                                                                               
                        <xsl:attribute name="href">
+                                                                               
                                
<xsl:text>index.php?menuaction=controller.uicheck_list.add_check_list</xsl:text>
+                                                                               
                                <xsl:text>&amp;date=</xsl:text>
+                                                                               
                                <xsl:value-of select="info/date"/>
+                                                                               
                                <xsl:text>&amp;control_id=</xsl:text>
+                                                                               
                                <xsl:value-of select="info/control_id"/>
+                                                                               
                                <xsl:text>&amp;location_code=</xsl:text>
+                                                                               
                                <xsl:value-of select="$location_code"/>
+                                                                               
                        </xsl:attribute>
+                                                                               
                        <img height="15" 
src="controller/images/status_icon_red_cross.png" />
+                                                                               
                </a>
+                                                                               
        </div>
+                                                                               
</xsl:when>
+                                                                               
<xsl:when test="status = 'control_canceled'">
+                                                                               
        <div class="cell">
+                                                                               
                <img height="15" 
src="controller/images/status_icon_red_cross.png" />
+                                                                               
        </div>
+                                                                               
</xsl:when>
+                                                                               
<xsl:otherwise>
+                                                                               
        <div class="cell"></div>
+                                                                               
</xsl:otherwise>
+                                                                       
</xsl:choose>
+                                                               </xsl:for-each>
+                                                       </li>
+                                               </xsl:for-each>
+                                       </xsl:when>
+                                       <xsl:otherwise>
+                                               <div>Ingen sjekklister for bygg 
i angitt periode</div>
+                                       </xsl:otherwise>
+                               </xsl:choose>
+                               </ul>
+                       </div>
+               </div>
+</div>
+</div>
+</xsl:template>


Property changes on: 
trunk/controller/templates/base/calendar/view_calendar_month_bac.xsl
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Modified: trunk/controller/templates/base/calendar/view_calendar_year.xsl
===================================================================
--- trunk/controller/templates/base/calendar/view_calendar_year.xsl     
2012-04-22 07:54:40 UTC (rev 9202)
+++ trunk/controller/templates/base/calendar/view_calendar_year.xsl     
2012-04-22 08:29:22 UTC (rev 9203)
@@ -1,9 +1,9 @@
 <!-- $Id$ -->
-<xsl:template match="data" name="view_check_lists" 
xmlns:php="http://php.net/xsl";>
+<xsl:template match="data"  xmlns:php="http://php.net/xsl";>
 <xsl:variable name="date_format">d/m-Y</xsl:variable>
 <xsl:variable name="year"><xsl:value-of select="year"/></xsl:variable>
 <xsl:variable name="view_location_code"><xsl:value-of 
select="view_location_code"/></xsl:variable>
-
+       
 <div id="main_content">
 
        <div id="control_plan">
@@ -127,140 +127,13 @@
                                                </div>                          
        
                                                </div>          
                                                <div class="months_wrp">
-                                               <xsl:for-each 
select="calendar_array">
                                                
-                                                
-                                               <xsl:call-template 
name="check_list_status_checker" >
-                                               <!-- 
-                                                       <xsl:with-param 
name="status"><xsl:value-of select="status"/></xsl:with-param>
-                                                       <xsl:with-param 
name="location_code"><xsl:value-of 
select="$view_location_code"/></xsl:with-param>
-                                               -->
-                                               </xsl:call-template>
-                                               
-                                                       <!-- 
-                                                       <xsl:with-param 
name="active_tab">view_details</xsl:with-param>
-                                                        -->
-                                               
-                                               
-                                               <!-- 
-                                                       <xsl:choose>
-                                                                       
<xsl:when test="status = 'CONTROL_REGISTERED'">
-                                                                               
<div>
-                                                                               
<a>
-                                                                               
        <xsl:attribute name="href">
-                                                                               
                
<xsl:text>index.php?menuaction=controller.uicheck_list.add_check_list</xsl:text>
-                                                                               
                <xsl:text>&amp;date=</xsl:text>
-                                                                               
                <xsl:value-of select="info/date"/>
-                                                                               
                <xsl:text>&amp;control_id=</xsl:text>
-                                                                               
                <xsl:value-of select="info/control_id"/>
-                                                                               
                <xsl:text>&amp;location_code=</xsl:text>
-                                                                               
                <xsl:value-of select="$view_location_code"/>
-                                                                               
        </xsl:attribute>
-                                                                               
        <img height="15" src="controller/images/status_icon_yellow_ring.png" />
-                                                                               
</a>
-                                                                               
</div>
-                                                                       
</xsl:when>
-                                                                       
<xsl:when test="status = 'CONTROL_PLANNED'">
-                                                                               
<div>
-                                                                               
<a>
-                                                                               
        <xsl:attribute name="href">
-                                                                               
                
<xsl:text>index.php?menuaction=controller.uicheck_list.edit_check_list</xsl:text>
-                                                                               
                <xsl:text>&amp;check_list_id=</xsl:text>
-                                                                               
                <xsl:value-of select="info/check_list_id"/>
-                                                                               
        </xsl:attribute>
-                                                                               
        <img height="15" src="controller/images/status_icon_yellow.png" />
-                                                                               
</a>
-                                                                               
</div>
-                                                                       
</xsl:when>
-                                                                       
<xsl:when test="status = 'CONTROL_NOT_DONE_WITH_PLANNED_DATE'">
-                                                                               
        <div class="cell">
-                                                                               
        <a>
-                                                                               
                <xsl:attribute name="href">
-                                                                               
                        
<xsl:text>index.php?menuaction=controller.uicheck_list.edit_check_list</xsl:text>
-                                                                               
                        <xsl:text>&amp;check_list_id=</xsl:text>
-                                                                               
                        <xsl:value-of select="info/check_list_id"/>
-                                                                               
                </xsl:attribute>
-                                                                               
                <img height="15" src="controller/images/status_red_cross.png" />
-                                                                               
        </a>
-                                                                               
        </div>
-                                                                       
</xsl:when>
-                                                                       
<xsl:when test="status = 'CONTROL_DONE_IN_TIME_WITHOUT_ERRORS'">
-                                                                               
<div>
-                                                                               
        <a>
-                                                                               
        <xsl:attribute name="href">
-                                                                               
                
<xsl:text>index.php?menuaction=controller.uicheck_list.edit_check_list</xsl:text>
-                                                                               
                <xsl:text>&amp;check_list_id=</xsl:text>
-                                                                               
                <xsl:value-of select="info/check_list_id"/>
-                                                                               
        </xsl:attribute>
-                                                                               
                <span style="display:none"><xsl:value-of 
select="info/id"/></span>
-                                                                               
                <img height="15" 
src="controller/images/status_icon_dark_green.png" />
-                                                                               
        </a>
-                                                                               
</div>
-                                                                       
</xsl:when>
-                                                                       
<xsl:when test="status = 'CONTROL_DONE_OVER_TIME_WITHOUT_ERRORS'">
-                                                                               
<div style="position:relative;">
-                                                                               
<div id="info_box" style="position:absolute;display:none;"></div>
-                                                                               
        <a>
-                                                                               
        <xsl:attribute name="href">
-                                                                               
                
<xsl:text>index.php?menuaction=controller.uicheck_list.edit_check_list</xsl:text>
-                                                                               
                <xsl:text>&amp;check_list_id=</xsl:text>
-                                                                               
                <xsl:value-of select="info/check_list_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 = 'control_accomplished_with_errors'">
-                                                                               
        <div style="position:relative;background: 
url(controller/images/status_icon_red_empty.png) no-repeat 50% 50%;">
-                                                                               
                <div id="info_box" 
style="position:absolute;display:none;"></div>
-                                                                               
        <a class="view_check_list">
-                                                                               
                        <xsl:attribute name="href">
-                                                                               
                                
<xsl:text>index.php?menuaction=controller.uicheck_list.edit_check_list</xsl:text>
-                                                                               
                                <xsl:text>&amp;check_list_id=</xsl:text>
-                                                                               
                                <xsl:value-of select="info/check_list_id"/>
-                                                                               
                        </xsl:attribute>
-                                                                               
                        <span style="display:none">
-                                                                               
                                
<xsl:text>&amp;check_list_id=</xsl:text><xsl:value-of 
select="info/check_list_id"/>
-                                                                               
                                <xsl:text>&amp;phpgw_return_as=json</xsl:text>
-                                                                               
                        </span>
-                                                                               
                        <xsl:value-of select="info/num_open_cases"/>
-                                                                               
                </a>
-                                                                               
        </div>
-                                                                               
</xsl:when>
-                                                                       
<xsl:when test="status = 'controls_accomplished_with_errors'">
-                                                                               
<div style="position:relative;background: 
url(controller/images/status_icon_red_empty.png) no-repeat 50% 50%;">
-                                                                               
        <a class="view_check_list">
-                                                                               
                <xsl:value-of select="info"/>
-                                                                               
        </a>
-                                                                               
</div>
-                                                                       
</xsl:when>
-                                                                       
<xsl:when test="status = 'control_canceled'">
-                                                                               
<div>
-                                                                               
        <img height="12" src="controller/images/status_icon_red_cross.png" />
-                                                                               
</div>
-                                                                       
</xsl:when>
-                                                                       
<xsl:when test="status = 'control_not_accomplished'">
-                                                                               
<div>
-                                                                               
        <a>
-                                                                               
                <xsl:attribute name="href">
-                                                                               
                        
<xsl:text>index.php?menuaction=controller.uicheck_list.add_check_list</xsl:text>
-                                                                               
                        <xsl:text>&amp;date=</xsl:text>
-                                                                               
                        <xsl:value-of select="info/date"/>
-                                                                               
                        <xsl:text>&amp;control_id=</xsl:text>
-                                                                               
                        <xsl:value-of select="info/control_id"/>
-                                                                               
                        <xsl:text>&amp;location_code=</xsl:text>
-                                                                               
                        <xsl:value-of select="$view_location_code"/>
-                                                                               
                </xsl:attribute>
-                                                                               
                <img height="12" 
src="controller/images/status_icon_red_cross.png" />
-                                                                               
        </a>
-                                                                               
</div>
-                                                                       
</xsl:when>
-                                                                       
<xsl:otherwise>
-                                                                       
<div></div>
-                                                                       
</xsl:otherwise>
-                                                       </xsl:choose>
-                                                        -->
+                                               <xsl:for-each 
select="calendar_array">
+
+                                                       
+                                                       <xsl:call-template 
name="check_list_status_checker" >
+                                                               <xsl:with-param 
name="location_code"><xsl:value-of 
select="$view_location_code"/></xsl:with-param>
+                                                       </xsl:call-template>
                                                </xsl:for-each>
                                                </div>
                                        </li>   

Modified: trunk/controller/templates/base/check_list/add_check_list.xsl
===================================================================
--- trunk/controller/templates/base/check_list/add_check_list.xsl       
2012-04-22 07:54:40 UTC (rev 9202)
+++ trunk/controller/templates/base/check_list/add_check_list.xsl       
2012-04-22 08:29:22 UTC (rev 9203)
@@ -51,16 +51,6 @@
                        <input type="hidden" name="control_id" 
value="{$control_id}" />
                        <input type="hidden" name="location_code" 
value="{$location_code}" />
                        
-                       <!-- Shows dates that can be picked for setting a 
deadline date                 
-                       <div id="calendar_dates">
-                               <xsl:for-each select="calendar_array">
-                                       <xsl:variable 
name="cal_date"><xsl:value-of select="."/></xsl:variable>
-                                               
-                                       <span><xsl:value-of 
select="php:function('date', $date_format, number( $cal_date ) )"/></span>
-                               </xsl:for-each>
-                       </div>
-                       -->
- 
                        <fieldset>
                                <div class="row">
                                        <label>Status</label>

Modified: trunk/controller/templates/base/css/base.css
===================================================================
--- trunk/controller/templates/base/css/base.css        2012-04-22 07:54:40 UTC 
(rev 9202)
+++ trunk/controller/templates/base/css/base.css        2012-04-22 08:29:22 UTC 
(rev 9203)
@@ -919,8 +919,10 @@
    float:right;
 }
 #control_plan .middle {
-       border: 1px solid #DBE5EF;
-    background: none repeat scroll 0 0 #EDF5FF;    
+    background: none repeat scroll 0 0 #EDF5FF;
+    border-color: #DBE5EF #DBE5EF -moz-use-text-color;
+    border-style: solid solid none;
+    border-width: 1px 1px 0;
     clear: both;
     margin-top: 1em;
     overflow: hidden;
@@ -1028,25 +1030,6 @@
     padding: 40px 20px;        
 }
 
-
-
-
-/* ======================  CALENDAR  DATES ========================== */
-
-#calendar_dates{
-       margin:25px 0;  
-}
-#calendar_dates p{
-       font-weight: bold;
-       margin: 5px 0;  
-}
-#calendar_dates span {
-    border: 2px solid black;
-    margin-right: 10px;
-    padding: 1px 4px;
-    cursor: pointer;
-}
-
 /* ======================  CALENDAR INFO BOX ========================== */
 
 #info_box {




reply via email to

[Prev in Thread] Current Thread [Next in Thread]