ここの情報は古いです。ご理解頂いた上でお取り扱いください。

Ignore:
Timestamp:
Jul 10, 2007, 6:11:42 PM (15 years ago)
Author:
ToshihiroK
Message:

postgres対応

File:
1 edited

Legend:

Unmodified
Added
Removed
  • OpenPNE/branches/prj/postgres/2_8_1/webapp/lib/db/schedule.php

    r1856 r3402  
    5353    $sql = 'SELECT * FROM c_commu_topic WHERE c_commu_id IN ('.$ids.')' .
    5454            ' AND event_flag = 1 AND open_date > ? AND open_date <= ?';
     55    $max_day = date("t", mktime(0,0,0,intval($month),1,intval($year) ));
    5556    $params = array(
    56         sprintf('%04d-%02d', intval($year), intval($month)) . '-00',
    57         sprintf('%04d-%02d', intval($year), intval($month)) . '-31'
     57//        sprintf('%04d-%02d', intval($year), intval($month)) . '-00',
     58        sprintf('%04d-%02d', intval($year), intval($month)) . '-01',
     59        sprintf('%04d-%02d', intval($year), intval($month)) . '-' . $max_day
    5860    );
    5961    $list = db_get_all($sql, $params);
     
    9799        'end_date' => $end_date,
    98100        'end_time' => $end_time,
    99         'is_receive_mail' => (bool)$is_receive_mail,
     101        'is_receive_mail' => $is_receive_mail,
    100102    );
    101103    return db_insert('c_schedule', $data);
     
    117119        'end_date' => $end_date,
    118120        'end_time' => $end_time,
    119         'is_receive_mail' => (bool)$is_receive_mail,
     121        'is_receive_mail' => $is_receive_mail,
    120122    );
    121123    $where = array('c_schedule_id' => intval($c_schedule_id));
Note: See TracChangeset for help on using the changeset viewer.