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

Changeset 12608


Ignore:
Timestamp:
Aug 12, 2009, 12:34:49 PM (10 years ago)
Author:
kiwa
Message:

#4227:携帯版アルバムにあるほぼ全ての画像変更・削除処理でWarningが発生していたのを修正 (trunk)

Location:
OpenPNE/trunk/webapp
Files:
6 edited

Legend:

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

    r11363 r12608  
    160160}
    161161
    162 function db_image_data_copy($filename, $new_filename)
     162function db_image_data_copy($filename, $new_filename, $c_member_id, $filesize)
    163163{
    164164    if (!$filename) return false;
     
    174174    $type = $c_image[0]['type'];
    175175
    176     return db_image_insert_c_image($new_filename, $bin, $type);
     176    return db_image_insert_c_image($new_filename, $bin, $filesize, $c_member_id, null, $type);
    177177}
    178178
  • OpenPNE/trunk/webapp/lib/mail/sns.php

    r11777 r12608  
    10031003            //アルバムデータの変更
    10041004            $c_album_cover = $c_album['album_cover_image'];
    1005             db_album_image_data_delete($c_album_cover);
     1005            $c_member_id = $c_album['c_member_id'];
     1006            db_album_image_data_delete($c_album_cover, $c_member_id);
    10061007            db_album_update_c_album_album_cover_image($c_album_id,$filename);
    10071008        } else {
  • OpenPNE/trunk/webapp/modules/ktai/do/h_album_cover_image_copy.php

    r11112 r12608  
    4040        $ext = $path_parts['extension'];
    4141        $new_filename = 'a_' . $target_c_album_id . '_1_' . time() . '.' . $ext;
    42         $c_image_id = db_image_data_copy($image_filename, $new_filename);
     42        $c_image_id = db_image_data_copy($image_filename, $new_filename, $u, $target_c_album_image['filesize']);
     43
    4344        if (!$c_image_id) {
    4445            openpne_redirect('ktai', 'page_h_err_fh_album');
     
    4647
    4748        $c_album_cover = $c_album['album_cover_image'];
    48         db_album_image_data_delete($c_album_cover);
     49        db_album_image_data_delete($c_album_cover, $u);
    4950        db_album_update_c_album_album_cover_image($target_c_album_id, $new_filename);
    5051
  • OpenPNE/trunk/webapp/modules/ktai/do/h_album_cover_image_delete.php

    r10986 r12608  
    2727
    2828        $c_album_cover = $c_album['album_cover_image'];
    29         db_album_image_data_delete($c_album_cover);
     29        db_album_image_data_delete($c_album_cover, $u);
    3030        db_album_update_c_album_album_cover_image($target_c_album_id,'');
    3131
  • OpenPNE/trunk/webapp/modules/ktai/do/h_album_image_delete.php

    r10986 r12608  
    3636        //---
    3737
    38         db_album_delete_c_album_image($target_c_album_image_id);
     38        db_album_delete_c_album_image($target_c_album_image_id, $u);
    3939
    4040        $p = array('target_c_album_id' => $target_c_album_id);
  • OpenPNE/trunk/webapp/modules/pc/do/h_album_image_edit_insert_c_album_image.php

    r11363 r12608  
    7575
    7676            if (!db_album_is_insertable4c_member_id($u, $filesize - $c_album_image['filesize'])) {
    77                 db_album_image_data_delete($filename);
     77                db_album_image_data_delete($filename, $u);
    7878
    7979                $msg = 'これ以上写真を投稿することができません。';
     
    9191            }
    9292
    93             db_album_image_data_delete($c_album_image['image_filename']);
     93            db_album_image_data_delete($c_album_image['image_filename'], $u);
    9494        }
    9595
Note: See TracChangeset for help on using the changeset viewer.