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

Changeset 1775


Ignore:
Timestamp:
Feb 6, 2007, 8:37:02 PM (13 years ago)
Author:
takanashi
Message:

#454
携帯から予定登録ができない

Location:
OpenPNE/branches/2_6/webapp_biz/modules/ktai_biz
Files:
14 edited

Legend:

Unmodified
Added
Removed
  • OpenPNE/branches/2_6/webapp_biz/modules/ktai_biz/do/fh_biz_schedule_delete.php

    r406 r1775  
    1212        $tail = $GLOBALS['KTAI_URL_TAIL'];
    1313        $target_id = $requests['target_id'];
    14 
     14       
     15        if (!biz_isPermissionSchedule($u, $requests['schedule_id'])) {
     16            handle_kengen_error();
     17        }
     18       
    1519        if ($requests['is_rep']) {
    1620            $rep_schedule = biz_getRepeatScheduleID($requests['schedule_id']);
  • OpenPNE/branches/2_6/webapp_biz/modules/ktai_biz/do/fh_biz_schedule_edit.php

    r406 r1775  
    1111        $u  = $GLOBALS['KTAI_C_MEMBER_ID'];
    1212        $tail = $GLOBALS['KTAI_URL_TAIL'];
    13 
     13       
     14        if (!biz_isPermissionSchedule($u, $requests['schedule_id'])) {
     15            handle_kengen_error();
     16        }
     17       
    1418        //ERROR----------------
    1519        //存在しない日付
     
    128132        $schedule_id = '';
    129133
    130         biz_editSchedule($requests['sc_title'], $u, $begin_date, $finish_date, $begin_time, $finish_time, $requests['sc_memo'], $rp_rule, 0, $requests['sc_j_mem'], $requests['sc_j_plc'], $requests['schedule_id']);
     134        biz_editSchedule($requests['sc_title'], $u, $begin_date, $finish_date, $begin_time, $finish_time, $requests['sc_memo'], $rp_rule, 0, $requests['sc_j_mem'], $requests['public_flag'], $requests['schedule_id']);
    131135        $schedule_id = $requests['schedule_id'];
    132136
  • OpenPNE/branches/2_6/webapp_biz/modules/ktai_biz/do/fhg_biz_schedule_add.php

    r406 r1775  
    2929                        '&sc_rp='.$requests['sc_rp'].
    3030                        '&sc_memo='.$requests['sc_memo'].
    31                         '&sc_j_mem_enc='.serialize($requests['sc_j_mem']).
     31                        '&biz_group_id='.serialize($requests['biz_group_id']).
    3232                        '&sc_rwk_enc='.serialize($requests['sc_rwk_enc']).
    3333                        '&sc_rcount='.$requests['sc_rcount'].
     
    3737            $_REQUEST['sc_rp'] = $requests['sc_rp'];
    3838            $_REQUEST['sc_memo'] = $requests['sc_memo'];
    39             $_REQUEST['sc_j_mem_enc'] = serialize($requests['sc_j_mem']);
     39            $_REQUEST['biz_group_id'] = serialize($requests['biz_group_id']);
    4040            $_REQUEST['sc_rwk_enc'] = serialize($requests['sc_rwk_enc']);
    4141            $_REQUEST['sc_rcount'] = $requests['sc_rcount'];
     
    6464                        '&sc_rp='.$requests['sc_rp'].
    6565                        '&sc_memo='.$requests['sc_memo'].
    66                         '&sc_j_mem_enc='.serialize($requests['sc_j_mem']).
     66                        '&biz_group_id='.serialize($requests['biz_group_id']).
    6767                        '&sc_rwk_enc='.serialize($requests['sc_rwk_enc']).
    6868                        '&sc_rcount='.$requests['sc_rcount'].
     
    7474            $_REQUEST['sc_rp'] = $requests['sc_rp'];
    7575            $_REQUEST['sc_memo'] = $requests['sc_memo'];
    76             $_REQUEST['sc_j_mem_enc'] = serialize($requests['sc_j_mem']);
     76            $_REQUEST['biz_group_id'] = serialize($requests['biz_group_id']);
    7777            $_REQUEST['sc_rwk_enc'] = serialize($requests['sc_rwk_enc']);
    7878            $_REQUEST['sc_rcount'] = $requests['sc_rcount'];
     
    8383        }   
    8484        //---------------------
    85 
    86         //施設、参加者のチェック
    87 
    88         if (!$requests['sc_j_mem']) {
    89             //「全員」が含まれている場合は、配列を空に
    90             $requests['sc_j_mem'] = array();
    91         } elseif ($requests['sc_j_mem'] == "my") {
    92             //本人またはフレンドのみの場合
    93             $requests['sc_j_mem']=array($requests['target_id']);
    94         } else {
    95             $join_group = biz_getGroupMember($requests['sc_j_mem']);
    96             $i = 0;
    97 
    98             $requests['sc_j_mem'] = array();
    99             foreach ($join_group as $key) {
    100                     $requests['sc_j_mem'][$i] = $key['c_member_id'];
    101                     $i++;
    102             }
    103         }
    10485
    10586        //日付のフォーマットを設定
     
    123104                        '&sc_rp='.$requests['sc_rp'].
    124105                        '&sc_memo='.$requests['sc_memo'].
    125                         '&sc_j_mem_enc='.serialize($requests['sc_j_mem']).
     106                        '&biz_group_id='.serialize($requests['biz_group_id']).
    126107                        '&sc_rwk_enc='.serialize($requests['sc_rwk_enc']).
    127108                        '&sc_rcount='.$requests['sc_rcount'].
     
    132113            $_REQUEST['sc_rp'] = $requests['sc_rp'];
    133114            $_REQUEST['sc_memo'] = $requests['sc_memo'];
    134             $_REQUEST['sc_j_mem_enc'] = serialize($requests['sc_j_mem']);
     115            $_REQUEST['biz_group_id'] = serialize($requests['biz_group_id']);
    135116            $_REQUEST['sc_rwk_enc'] = serialize($requests['sc_rwk_enc']);
    136117            $_REQUEST['sc_rcount'] = $requests['sc_rcount'];
     
    154135        if (!$requests['sc_rp']) {
    155136            //繰り返しをしない予定登録
    156             biz_insertSchedule($requests['sc_title'], $u, $begin_date, $finish_date, $begin_time, $finish_time, $requests['sc_memo'], $rp_rule, 0, $requests['sc_j_mem'], $requests['sc_j_plc']);
     137            biz_insertSchedule($requests['sc_title'], $u, $begin_date, $finish_date, $begin_time, $finish_time, $requests['sc_memo'], $rp_rule, 0, $requests['biz_group_id'], $requests['public_flag']);
    157138        } else {
    158139            //繰り返し予定
     
    163144                $tmp = date("Ymd", $nowday);
    164145                if ($rp_rule & (1 << date("w",$nowday))) {
    165                     biz_insertSchedule($requests['sc_title'], $u, $tmp, $tmp, $begin_time, $finish_time, $requests['sc_memo'], $rp_rule, $first_id, $requests['sc_j_mem'], $requests['sc_j_plc']);
     146                    biz_insertSchedule($requests['sc_title'], $u, $tmp, $tmp, $begin_time, $finish_time, $requests['sc_memo'], $rp_rule, $first_id, $requests['biz_group_id'], $requests['public_flag']);
    166147                }
    167148            }
  • OpenPNE/branches/2_6/webapp_biz/modules/ktai_biz/page/fh_biz_schedule_add.php

    r406 r1775  
    3535            'day' => date("d"));
    3636
    37         //参加しているグループ
    38         $jgroup = biz_getJoinGroup($target_id);
    39 
    40         foreach ($jgroup as $value) {
    41             $gname[$i] = $value['name'];
    42             $gid[$i] = $value['biz_group_id'];
    43             $i++;
    44         }
    45 
    4637        $this->set('now', $now);
    47         $this->set('jgroup', $jgroup);
    4838        $this->set('gname', $gname);
    4939        $this->set('gid', $gid);
    5040        $this->set('msg', $requests['msg']);
    5141        $this->set('t_id', $target_id);
     42
     43        $biz_group_count = biz_getGroupCount($target_id);
     44        $biz_group_list = biz_getJoinGroupList($target_id, 1, $biz_group_count);
     45
     46        $this->set('biz_group_list', $biz_group_list[0]);
    5247
    5348        return 'success';
  • OpenPNE/branches/2_6/webapp_biz/modules/ktai_biz/page/fh_biz_schedule_delete.php

    r269 r1775  
    1212        $u  = $GLOBALS['KTAI_C_MEMBER_ID'];
    1313        $this->set('tail', $GLOBALS['KTAI_URL_TAIL']);
    14 
     14       
     15        if (!biz_isPermissionSchedule($u, $requests['schedule_id'])) {
     16            handle_kengen_error();
     17        }
     18       
    1519        $this->set('schedule_id',$requests['schedule_id']);
    1620        $this->set("t_id", $requests['target_id']);
  • OpenPNE/branches/2_6/webapp_biz/modules/ktai_biz/page/fh_biz_schedule_edit.php

    r1268 r1775  
    1212        $this->set('tail', $GLOBALS['KTAI_URL_TAIL']);
    1313
     14        if (!biz_isPermissionSchedule($u, $requests['schedule_id'])) {
     15            handle_kengen_error();
     16        }
    1417
    1518        if (empty($requests['target_id']) || ($requests['target_id'] == $u)) {
     
    6265        $this->set('t_id', $target_id);
    6366        $this->set('msg', $requests['msg']);
     67        $this->set('public_flag', $requests['public_flag']);
    6468
    6569        return 'success';
  • OpenPNE/branches/2_6/webapp_biz/modules/ktai_biz/page/fh_biz_schedule_view.php

    r1268 r1775  
    1111        $u  = $GLOBALS['KTAI_C_MEMBER_ID'];
    1212        $this->set('tail', $GLOBALS['KTAI_URL_TAIL']);
     13
     14        if (!biz_isPermissionSchedule($u, $requests['id'])) {
     15            handle_kengen_error();
     16        }
    1317
    1418        if (empty($requests['target_id']) || ($requests['target_id'] == $u)) {
  • OpenPNE/branches/2_6/webapp_biz/modules/ktai_biz/templates/fh_biz_schedule_add.tpl

    r1018 r1775  
    2121タイトル:<input type="text" name='sc_title' size="30"><br>
    2222
    23 参加者:<select name='sc_j_mem'>
    24                 <option value="my">({if $is_f})フレンド({else})自分({/if})のみ</option>
    25                 <option value="">全ユーザー</option>
    26                 ({foreach item=nm from=$jgroup name=join})
    27                 <option value="({$nm.biz_group_id})">({$nm.name})
    28                 ({/foreach})
    29                
    30                 </select><br>
     23グループ:<select name="biz_group_id">
     24        <option type="radio" value="0">指定なし
     25({foreach from=$biz_group_list item=biz_group})
     26        <option type="radio" value="({$biz_group.biz_group_id})"({if $form_val.biz_group_id == $biz_group.biz_group_id}) selected({/if})>({$biz_group.name})
     27({/foreach})
     28</select><br>
     29公開範囲:<br>
     30<input type='radio' name='public_flag' value='public' checked>全体に公開<br>
     31<input type='radio' name='public_flag' value='group'>グループまで公開<br>
     32<input type='radio' name='public_flag' value='private'>公開しない<br><br>
    3133<center>
    3234
  • OpenPNE/branches/2_6/webapp_biz/modules/ktai_biz/templates/fh_biz_schedule_edit.tpl

    r543 r1775  
    2929詳細:({$value})<br>
    3030登録者:({$writer})<br>
     31公開範囲:<br>
     32<input type='radio' name='public_flag' value='public' ({if $public_flag == 'public'})checked({/if})>全体に公開<br>
     33<input type='radio' name='public_flag' value='group' ({if $public_flag == 'group'})checked({/if})>グループまで公開<br>
     34<input type='radio' name='public_flag' value='private' ({if $public_flag == 'private'})checked({/if})>公開しない<br>
     35<br>
    3136参加者:
    3237        ({foreach item=name key=id from=$member})
  • OpenPNE/branches/2_6/webapp_biz/modules/ktai_biz/templates/fh_biz_schedule_view.tpl

    r365 r1775  
    2323詳細:({$schedule.value})<br>
    2424登録者:<a href="({t_url m=ktai a=page_f_home})&amp;target_c_member_id=({$schedule.c_member_id})&amp;({$tail})">({$schedule.writer_name})</a><br>
     25公開範囲:
     26({if $schedule.public_flag == "public"})
     27全員に公開
     28({elseif $schedule.public_flag == "group"})
     29グループまで公開
     30({elseif $schedule.public_flag == "private"})
     31公開しない
     32({/if})<br>
    2533参加者:
    2634({foreach item=name key=id from=$jmembers})
     
    4553<input type="hidden" name="members" value="({$jmembers_enc})">
    4654<input type="hidden" name="schedule_id" value="({$schedule_id})">
     55<input type="hidden" name="public_flag" value="({$schedule.public_flag})">
    4756<input type="hidden" name="target_id" value="({$t_id})">
    4857<input value="編集" type="submit">
  • OpenPNE/branches/2_6/webapp_biz/modules/ktai_biz/validate/do/fh_biz_schedule_edit.ini

    r217 r1775  
    6060type="string"
    6161requeired = 0
     62
     63[public_flag]
     64type="string"
     65requeired = 1
  • OpenPNE/branches/2_6/webapp_biz/modules/ktai_biz/validate/do/fhg_biz_schedule_add.ini

    r217 r1775  
    3939capiton = "タイトル"
    4040
    41 [sc_j_mem]
     41[biz_group_id]
    4242type= "string"
    4343required = 0
    4444isarray= 1
    45 capiton = "メンバー"
     45capiton = "グループID"
    4646
    4747[target_id]
    4848tupe= "int"
    4949required= 0
     50
     51[public_flag]
     52type="string"
     53requeired = 1
  • OpenPNE/branches/2_6/webapp_biz/modules/ktai_biz/validate/page/fh_biz_schedule_add.ini

    r217 r1775  
    3434capiton = "タイトル"
    3535
    36 [sc_j_mem]
     36[biz_group_id]
    3737type= "string"
    3838is_array = 1
    3939required = 0
    40 capiton = "メンバー"
    41 
    42 [sc_j_mem_enc]
    43 type="string"
    44 required=0
     40capiton = "グループID"
    4541
    4642[begin_date]
  • OpenPNE/branches/2_6/webapp_biz/modules/ktai_biz/validate/page/fh_biz_schedule_edit.ini

    r217 r1775  
    3333[target_id]
    3434type="int"
     35
     36[public_flag]
     37type="string"
     38requeired = 1
Note: See TracChangeset for help on using the changeset viewer.