[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Fmsystem-commits] [9138]
From: |
Torstein |
Subject: |
[Fmsystem-commits] [9138] |
Date: |
Fri, 13 Apr 2012 07:20:42 +0000 |
Revision: 9138
http://svn.sv.gnu.org/viewvc/?view=rev&root=fmsystem&revision=9138
Author: vator
Date: 2012-04-13 07:20:40 +0000 (Fri, 13 Apr 2012)
Log Message:
-----------
Modified Paths:
--------------
trunk/controller/images/bg_expand_not_active.png
trunk/controller/images/bg_expand_not_active.psd
trunk/controller/inc/class.uicalendar.inc.php
trunk/controller/inc/class.uicheck_list.inc.php
trunk/controller/inc/model/class.check_list.inc.php
trunk/controller/templates/base/check_list/edit_check_list.xsl
trunk/controller/templates/base/css/base.css
Modified: trunk/controller/images/bg_expand_not_active.png
===================================================================
(Binary files differ)
Modified: trunk/controller/images/bg_expand_not_active.psd
===================================================================
(Binary files differ)
Modified: trunk/controller/inc/class.uicalendar.inc.php
===================================================================
--- trunk/controller/inc/class.uicalendar.inc.php 2012-04-12 18:19:04 UTC
(rev 9137)
+++ trunk/controller/inc/class.uicalendar.inc.php 2012-04-13 07:20:40 UTC
(rev 9138)
@@ -245,9 +245,8 @@
'period' =>
$year,
'year' =>
$year
);
- print_r( $controls_calendar_array );
-
self::render_template_xsl('calendar/view_calendar_year', $data);
+
self::render_template_xsl('calendar/view_calendar_year', $data);
self::add_javascript('controller', 'controller',
'jquery.js');
self::add_javascript('controller', 'controller',
'ajax.js');
}
Modified: trunk/controller/inc/class.uicheck_list.inc.php
===================================================================
--- trunk/controller/inc/class.uicheck_list.inc.php 2012-04-12 18:19:04 UTC
(rev 9137)
+++ trunk/controller/inc/class.uicheck_list.inc.php 2012-04-13 07:20:40 UTC
(rev 9138)
@@ -246,6 +246,46 @@
}
/**
+ * Public function for saving a check list
+ *
+ * @param HTTP:: location code, control id, status etc.. (check
list details)
+ * @return data array
+ */
+ function save_check_list(){
+ $location_code = phpgw::get_var('location_code');
+ $control_id = phpgw::get_var('control_id');
+ $status = (int)phpgw::get_var('status');
+
+ $deadline_date = phpgw::get_var('deadline_date',
'string');
+ $planned_date = phpgw::get_var('planned_date',
'string');
+ $completed_date = phpgw::get_var('completed_date',
'string');
+
+ $comment = phpgw::get_var('comment', 'string');
+
+ if($planned_date != '')
+ $planned_date_ts =
date_helper::get_timestamp_from_date( $planned_date, "d/m-Y" );
+
+ if($deadline_date != '')
+ $deadline_date_ts =
date_helper::get_timestamp_from_date( $deadline_date, "d/m-Y" );
+
+ if($completed_date != '')
+ $completed_date_ts =
date_helper::get_timestamp_from_date( $completed_date, "d/m-Y" );
+
+ $check_list = new controller_check_list();
+ $check_list->set_location_code($location_code);
+ $check_list->set_control_id($control_id);
+ $check_list->set_status($status);
+ $check_list->set_comment($comment);
+ $check_list->set_deadline( $deadline_date_ts );
+ $check_list->set_planned_date($planned_date_ts);
+ $check_list->set_completed_date($completed_date_ts);
+
+ $check_list_id = $this->so->store($check_list);
+
+ $this->redirect(array('menuaction' =>
'controller.uicheck_list.edit_check_list', 'check_list_id'=>$check_list_id));
+ }
+
+ /**
* Public function for displaying the edit check list form
*
* @param HTTP:: check list id
@@ -319,45 +359,7 @@
self::render_template_xsl(array('check_list/check_list_tab_menu',
'check_list/view_cases_for_check_list'), $data);
}
- /**
- * Public function for saving a check list
- *
- * @param HTTP:: location code, control id, status etc.. (check
list details)
- * @return data array
- */
- function save_check_list(){
- $location_code = phpgw::get_var('location_code');
- $control_id = phpgw::get_var('control_id');
- $status = (int)phpgw::get_var('status');
-
- $deadline_date = phpgw::get_var('deadline_date',
'string');
- $planned_date = phpgw::get_var('planned_date',
'string');
- $completed_date = phpgw::get_var('completed_date',
'string');
-
- $comment = phpgw::get_var('comment', 'string');
-
- if($planned_date != '')
- $planned_date_ts =
date_helper::get_timestamp_from_date( $planned_date, "d/m-Y" );
-
- if($deadline_date != '')
- $deadline_date_ts =
date_helper::get_timestamp_from_date( $deadline_date, "d/m-Y" );
-
- if($completed_date != '')
- $completed_date_ts =
date_helper::get_timestamp_from_date( $completed_date, "d/m-Y" );
-
- $check_list = new controller_check_list();
- $check_list->set_location_code($location_code);
- $check_list->set_control_id($control_id);
- $check_list->set_status($status);
- $check_list->set_comment($comment);
- $check_list->set_deadline( $deadline_date_ts );
- $check_list->set_planned_date($planned_date_ts);
- $check_list->set_completed_date($completed_date_ts);
-
- $check_list_id = $this->so->store($check_list);
-
- $this->redirect(array('menuaction' =>
'controller.uicheck_list.edit_check_list', 'check_list_id'=>$check_list_id));
- }
+
/**
* Public function for displaying the create message form
@@ -450,6 +452,7 @@
self::render_template_xsl(array('check_list/check_list_tab_menu','check_list/view_control_info'),
$data);
}
+ // Saves a check list that already exists. Returns status for
update as a JSON array with values update/not updated
public function update_check_list(){
$check_list_id = phpgw::get_var('check_list_id');
$status = (int)phpgw::get_var('status');
Modified: trunk/controller/inc/model/class.check_list.inc.php
===================================================================
--- trunk/controller/inc/model/class.check_list.inc.php 2012-04-12 18:19:04 UTC
(rev 9137)
+++ trunk/controller/inc/model/class.check_list.inc.php 2012-04-13 07:20:40 UTC
(rev 9138)
@@ -34,8 +34,8 @@
{
public static $so;
- const STATUS_OPEN = 0;
- const STATUS_CLOSED = 1;
+ const STATUS_UNDONE = 0;
+ const STATUS_DONE = 1;
const STATUS_CANCELED = 3;
protected $id;
Modified: trunk/controller/templates/base/check_list/edit_check_list.xsl
===================================================================
--- trunk/controller/templates/base/check_list/edit_check_list.xsl
2012-04-12 18:19:04 UTC (rev 9137)
+++ trunk/controller/templates/base/check_list/edit_check_list.xsl
2012-04-13 07:20:40 UTC (rev 9138)
@@ -43,38 +43,39 @@
<xsl:with-param
name="active_tab">view_details</xsl:with-param>
</xsl:call-template>
</div>
- <!-- ================== CHECKLIST DETAILS
===================== -->
+
+ <!-- ================== CHECKLIST DETAILS ===================== -->
+ <div id="check_list_details">
<h3 class="box_header">Sjekklistedetaljer</h3>
- <fieldset class="check_list_details">
<form id="frm_update_check_list"
action="index.php?menuaction=controller.uicheck_list.update_check_list"
method="post">
<xsl:variable name="check_list_id"><xsl:value-of
select="check_list/id"/></xsl:variable>
<input id="check_list_id" type="hidden"
name="check_list_id" value="{$check_list_id}" />
- <div class="col_1">
- <div>
+ <fieldset class="col_1">
+ <div class="row">
<label>ID</label>
<input class="id" disabled="disabled">
<xsl:attribute
name="name">check_list_id</xsl:attribute>
<xsl:attribute name="value"><xsl:value-of
select="check_list/id"/></xsl:attribute>
</input>
</div>
- <div>
+ <div class="row">
<label>Status</label>
<xsl:variable name="status"><xsl:value-of
select="check_list/status"/></xsl:variable>
<select name="status">
<xsl:choose>
<xsl:when
test="check_list/status = 0">
- <option value="0"
SELECTED="SELECTED">Utført</option>
- <option value="1" >Ikke
utført</option>
+ <option
value="1">Utført</option>
+ <option value="0"
SELECTED="SELECTED" >Ikke utført</option>
</xsl:when>
<xsl:when
test="check_list/status = 1">
- <option value="0"
SELECTED="SELECTED">Ikke utført</option>
- <option
value="1">Utført</option>
+ <option value="1"
SELECTED="SELECTED">Utført</option>
+ <option value="0">Ikke
utført</option>
</xsl:when>
</xsl:choose>
</select>
</div>
- <div>
+ <div class="row">
<label>Skal utføres innen</label>
<input class="date">
<xsl:attribute
name="id">deadline_date</xsl:attribute>
@@ -85,7 +86,7 @@
</xsl:if>
</input>
</div>
- <div>
+ <div class="row">
<label>Planlagt dato</label>
<input class="date">
<xsl:attribute
name="id">planned_date</xsl:attribute>
@@ -96,7 +97,7 @@
</xsl:if>
</input>
</div>
- <div>
+ <div class="row">
<label>Utført dato</label>
<input class="date">
<xsl:attribute
name="id">completed_date</xsl:attribute>
@@ -107,20 +108,20 @@
</xsl:if>
</input>
</div>
- </div>
- <div class="col_2">
- <div>
+ </fieldset>
+ <fieldset class="col_2">
+ <div class="row">
<label>Antall åpne saker</label>
<xsl:value-of
select="check_list/num_open_cases"/>
</div>
- <div>
+ <div class="row">
<label>Antall ventende saker</label>
<xsl:value-of
select="check_list/num_pending_cases"/>
</div>
- </div>
+ </fieldset>
- <div>
- <label class="comment">Kommentar</label>
+ <div class="comment">
+ <label>Kommentar</label>
<textarea>
<xsl:attribute
name="name">comment</xsl:attribute>
<xsl:value-of select="check_list/comment"/>
@@ -132,6 +133,6 @@
<input style="width: 170px;" class="btn
not_active" type="submit" name="save_control" value="Lagre detaljer" />
</div>
</form>
- </fieldset>
-</div>
+ </div>
+ </div>
</xsl:template>
Modified: trunk/controller/templates/base/css/base.css
===================================================================
--- trunk/controller/templates/base/css/base.css 2012-04-12 18:19:04 UTC
(rev 9137)
+++ trunk/controller/templates/base/css/base.css 2012-04-13 07:20:40 UTC
(rev 9138)
@@ -406,7 +406,6 @@
fieldset {
border-bottom:0px solid #ccc;
- padding:5px 0px 5px 10px;
}
textarea{
padding: 4px;
@@ -745,23 +744,12 @@
#main_content.groups{
cursor: default;
}
-#main_content fieldset{
- padding:0;
- margin:0;
-}
-
#main_content h1{
margin-top:0;
}
/* ======================================= CHECK LIST DETAILS
========================================= */
-#main_content fieldset.check_list_details {
- background: none repeat scroll 0 0 #EDF5FF;
- border: 1px solid #DBE5EF;
- padding: 15px;
-}
-
input.id {
background: none repeat scroll 0 0 #FFFFFF;
border: 1px solid #DDDDDD;
@@ -812,18 +800,51 @@
/* ======================================= CHECK LIST DETAILS
========================================= */
-fieldset.check_list_details{
- clear: both;
+#check_list_details form{
+ background: none repeat scroll 0 0 #EDF5FF;
+ border: 1px solid #DBE5EF;
+ padding: 15px;
+ clear: both;
+ margin:0;
}
-fieldset.check_list_details label{
+#check_list_details form .row {
+ padding: 0.1em 0;
+}
+
+#check_list_details label{
font-weight:bold;
width:150px;
+ display: inline-block;
}
-fieldset.check_list_details div{
- clear:left;
- margin:5px 0;
+#check_list_details .comment {
+ clear: both;
+ float: left;
+ margin-top: 20px;
}
-fieldset.tab_check_list_details label {
+#check_list_details .comment label {
+ vertical-align: top;
+}
+#check_list_details textarea{
+ width:400px;
+ height:100px;
+}
+
+/* ======================================= FORM UPDATE CHECK LIST
========================================= */
+
+#frm_update_check_list .col_1, #frm_update_check_list .col_2 {
+ float: left;
+ vertical-align: top;
+}
+#frm_update_check_list .col_2 {
+ margin-left: 15%;
+ width: 19%;
+}
+#frm_update_check_list input[type="submit"]{
+ width: 140px;
+}
+
+/* ======================================= TAB CHECK LIST DETAILS
========================================= */
+.tab_check_list_details label {
display: inline-block;
font-weight: bold;
width: 100px;
@@ -831,10 +852,9 @@
fieldset.tab_check_list_details {
padding: 0 0 10px 0;
}
-fieldset.check_list_details textarea{
- width:400px;
- height:100px;
-}
+
+/* ======================================= CHECK ITEM DETAILS
========================================= */
+
fieldset.check_item_details label{
font-weight:normal;
vertical-align:top;
@@ -845,21 +865,19 @@
font-weight: bold;
margin: 10px 0;
}
-fieldset.check_list_details label{
- display: inline-block;
- font-weight: bold;
- width: 150px;
+h3.check_item_details{
+ margin-bottom:0;
}
+
+
/* ======================================= CHECK ITEM
========================================= */
.check_item div{
margin: 5px 0;
clear:left;
}
-h3.check_item_details{
- margin-bottom:0;
-}
+
.check_item textarea {
display: block;
height: 100px;
@@ -867,8 +885,7 @@
width: 63%;
}.check_item label{
width:150px;
-}
-
+}
.new_item a#innertoolbar-button{
background: grey;
font-weight: bold;
@@ -1282,19 +1299,8 @@
overflow: hidden;
width: 900px;
}
-.col_1, .col_2{
- display:inline-block;
- vertical-align: top;
-}
-.col_2{
- padding-left: 17%;
-}
/* ====================== CASE DETAILS ========================== */
-
-#frm_update_check_list input[type="submit"]{
- width: 140px;
-}
#error_message_menu {
float: left;
margin-top: 50px;
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Fmsystem-commits] [9138],
Torstein <=