[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Fmsystem-commits] [7961]
From: |
Torstein |
Subject: |
[Fmsystem-commits] [7961] |
Date: |
Fri, 28 Oct 2011 05:10:38 +0000 |
Revision: 7961
http://svn.sv.gnu.org/viewvc/?view=rev&root=fmsystem&revision=7961
Author: vator
Date: 2011-10-28 05:10:37 +0000 (Fri, 28 Oct 2011)
Log Message:
-----------
Added Paths:
-----------
trunk/controller/inc/class.socheck_list.inc.php
Added: trunk/controller/inc/class.socheck_list.inc.php
===================================================================
--- trunk/controller/inc/class.socheck_list.inc.php
(rev 0)
+++ trunk/controller/inc/class.socheck_list.inc.php 2011-10-28 05:10:37 UTC
(rev 7961)
@@ -0,0 +1,55 @@
+<?php
+phpgw::import_class('controller.socommon');
+
+//include_class('controller', 'control_group_list', 'inc/model/');
+
+class controller_socheck_list extends controller_socommon
+{
+ protected static $so;
+
+ /**
+ * Get a static reference to the storage object associated with this
model object
+ *
+ * @return controller_socontrol_group the storage object
+ */
+ public static function get_instance()
+ {
+ if (self::$so == null) {
+ self::$so = CreateObject('controller.socheck_list');
+ }
+ return self::$so;
+ }
+
+ public function get_check_list(){
+
+ $current_time = time();
+
+ $buffer_in_days = 3600*24*7*5;
+
+ $buffer_time = $current_time - $buffer_in_days;
+
+ $sql = "SELECT p.* FROM controller_control p WHERE
$current_time >= p.start_date AND p.start_date > $buffer_time";
+ $this->db->query($sql);
+
+ while ($this->db->next_record()) {
+ $start_date = date("d.m.Y",
$this->db->f('start_date'));
+
+ $result[] = array(
+ 'title' =>
$this->db->f('title'),
+ 'start_date' =>
$start_date
+ );
+ }
+
+ return $result;
+ }
+
+ function get_query(string $sort_field, boolean $ascending, string
$search_for, string $search_type, array $filters, boolean $return_count){}
+
+ function populate(int $object_id, &$object){}
+
+ function add(&$object){}
+
+ function update($object){}
+
+ function get_id_field_name(){}
+}
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Fmsystem-commits] [7961],
Torstein <=