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

Changeset 6642


Ignore:
Timestamp:
Apr 18, 2008, 11:56:46 PM (12 years ago)
Author:
ogawa
Message:

#2090:コーディング規約に合わせて修正

Location:
OpenPNE/trunk/webapp
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • OpenPNE/trunk/webapp/lib/db/diary.php

    r6633 r6642  
    11911191    $sql = 'SELECT c_diary_id FROM c_diary_comment_log'
    11921192         . ' WHERE c_member_id = ? AND c_diary_id = ?';
    1193     $params = array(intval($c_member_id),intval($c_diary_id));
    1194     $summary_id = db_get_one($sql,$params,'main');
    1195     if(!$summary_id){
     1193    $params = array(intval($c_member_id), intval($c_diary_id));
     1194    $log_id = db_get_one($sql, $params, 'main');
     1195    if (!$log_id) {
    11961196        $data = array(
    11971197            'c_member_id' => intval($c_member_id),
     
    11991199            'r_datetime' => db_now(),
    12001200        );
    1201         $ins_id = db_insert('c_diary_comment_log', $data);
    1202     }
     1201        return db_insert('c_diary_comment_log', $data);
     1202    }
     1203    return false;
    12031204}
    12041205
     
    12141215    );
    12151216    $where = array('c_diary_id' => intval($c_diary_id));
    1216     $rtn = db_update('c_diary_comment_log',$data,$where);
    1217     return array($ins_id,$rtn);
    1218 }
    1219 
     1217    return db_update('c_diary_comment_log', $data, $where);
     1218}
    12201219
    12211220/**
     
    12321231    $sql = 'SELECT COUNT(c_diary_comment_id) FROM c_diary_comment'
    12331232         . ' WHERE c_member_id = ? AND c_diary_id = ?';
    1234     $params = array(intval($c_member_id),intval($c_diary_id));
    1235     $count = db_get_one($sql,$params,'main');
     1233    $params = array(intval($c_member_id), intval($c_diary_id));
     1234    $count = db_get_one($sql, $params, 'main');
     1235
    12361236    // コメントが無ければ履歴削除
    1237     if(!$count){
     1237    if (!$count) {
    12381238        $sql = 'DELETE FROM c_diary_comment_log'
    12391239             . ' WHERE c_member_id = ? AND c_diary_id = ?';
    1240         $params = array(intval($c_member_id),intval($c_diary_id));
     1240        $params = array(intval($c_member_id), intval($c_diary_id));
    12411241        db_query($sql, $params);
    12421242    }
     
    12441244         . ' ORDER BY c_diary_comment_id DESC';
    12451245    $params = array(intval($c_diary_id));
    1246     $comment = db_get_row($sql,$params,'main');
     1246    $comment = db_get_row($sql, $params, 'main');
     1247
    12471248    // 最新コメントの日付で履歴更新
    12481249    $data = array(
     
    12501251    );
    12511252    $where = array('c_diary_id' => intval($c_diary_id));
    1252     $rtn = db_update('c_diary_comment_log',$data,$where);
     1253    return db_update('c_diary_comment_log', $data, $where);
    12531254}
    12541255
  • OpenPNE/trunk/webapp/lib/mail/sns.php

    r6641 r6642  
    428428        //日記コメント記入履歴追加
    429429        if ($u != $target_c_member_id) {
    430             db_diary_insert_c_diary_comment_log($u,$target_c_diary_id);
     430            db_diary_insert_c_diary_comment_log($u, $target_c_diary_id);
    431431        }
    432432        //日記コメント記入履歴更新
  • OpenPNE/trunk/webapp/modules/ktai/do/fh_diary_delete_c_diary_comment.php

    r6633 r6642  
    3535
    3636        //コメント記入履歴削除実行
    37         db_diary_delete_c_diary_comment_log($target_c_member_id,$c_diary_comment['c_diary_id']);
     37        db_diary_delete_c_diary_comment_log($target_c_member_id, $c_diary_comment['c_diary_id']);
    3838
    3939        $p = array('target_c_diary_id' => $c_diary['c_diary_id']);
  • OpenPNE/trunk/webapp/modules/ktai/do/fh_diary_insert_c_diary_comment.php

    r6633 r6642  
    4747        //日記コメント記入履歴追加
    4848        if ($u != $target_c_member_id) {
    49             db_diary_insert_c_diary_comment_log($u,$target_c_diary_id);
     49            db_diary_insert_c_diary_comment_log($u, $target_c_diary_id);
    5050        }
    5151        //日記コメント記入履歴更新
  • OpenPNE/trunk/webapp/modules/pc/do/fh_diary_delete_c_diary_comment.php

    r6633 r6642  
    3737
    3838            //コメント記入履歴削除実行
    39             db_diary_delete_c_diary_comment_log($target_c_diary_comment['c_member_id'],$target_c_diary_id);
     39            db_diary_delete_c_diary_comment_log($target_c_diary_comment['c_member_id'], $target_c_diary_id);
    4040        }
    4141
  • OpenPNE/trunk/webapp/modules/pc/do/fh_diary_insert_c_diary_comment.php

    r6633 r6642  
    5858        //日記コメント記入履歴更新
    5959        if ($u != $target_c_member_id) {
    60             db_diary_insert_c_diary_comment_log($u,$target_c_diary_id);
     60            db_diary_insert_c_diary_comment_log($u, $target_c_diary_id);
    6161        }
    6262        db_diary_update_c_diary_comment_log($target_c_diary_id);
Note: See TracChangeset for help on using the changeset viewer.