Changeset 706


Ignore:
Timestamp:
Jan 27, 2015 10:50:04 AM (10 years ago)
Author:
namnd
Message:
 
Location:
pro-violet-viettel
Files:
8 edited

Legend:

Unmodified
Added
Removed
  • pro-violet-viettel/sourcecode/application/language/message/messages_lang.php

    r701 r706  
    147147                                                'Yên Bái',
    148148                                                'Phú Yên',
    149                                                 'TP Cần ThÆ¡',
    150                                                 'TP Đà Nẵng',
    151                                                 'TP Hải Phòng',
    152                                                 'TP Hà Nội',
    153                                                 'TP HCM');
     149                                                'Cần ThÆ¡',
     150                                                'Đà Nẵng',
     151                                                'Hải Phòng',
     152                                                'Hà Nội',
     153                                                'HCM');
  • pro-violet-viettel/sourcecode/application/modules/admin/models/user_model.php

    r690 r706  
    3535                                if ($data['status']==0){
    3636                                        if(strlen($data['daterange_start'])>0){
    37                                                 $sql.=" WHERE (cellphone LIKE '%".$data['keyword']."%' OR collaborator LIKE '%".$data['keyword']."%' OR acc_balanced LIKE '%".$data['keyword']."%' OR district LIKE '%".$data['keyword']."%' OR province LIKE '%".$data['keyword']."%') AND (created_time BETWEEN '".$data['daterange_start']."' AND '".$data['daterange_end']."')";
     37                                                $sql.=" WHERE (cellphone LIKE '%".$data['keyword']."%' OR collaborator LIKE '%".$data['keyword']."%' OR acc_balanced LIKE '%".$data['keyword']."%' OR province LIKE '%".$data['keyword']."%') AND (created_time BETWEEN '".$data['daterange_start']."' AND '".$data['daterange_end']."')";
    3838                                        }else
    3939                                        {
    40                                                 $sql.=" WHERE (cellphone LIKE '%".$data['keyword']."%' OR collaborator LIKE '%".$data['keyword']."%' OR acc_balanced LIKE '%".$data['keyword']."%' OR district LIKE '%".$data['keyword']."%' OR province LIKE '%".$data['keyword']."%')";
     40                                                $sql.=" WHERE (cellphone LIKE '%".$data['keyword']."%' OR collaborator LIKE '%".$data['keyword']."%' OR acc_balanced LIKE '%".$data['keyword']."%' OR province LIKE '%".$data['keyword']."%')";
    4141                                        }
    4242                                }else
    4343                                {
    4444                                        if(strlen($data['daterange_start'])>0){
    45                                                 $sql.=" AND (cellphone LIKE '%".$data['keyword']."%' OR collaborator LIKE '%".$data['keyword']."%' OR acc_balanced LIKE '%".$data['keyword']."%' OR district LIKE '%".$data['keyword']."%' OR province LIKE '%".$data['keyword']."%' OR acc_balanced LIKE '%".$data['keyword']."%' OR district LIKE '%".$data['keyword']."%' OR province LIKE '%".$data['keyword']."%') AND (created_time BETWEEN '".$data['daterange_start']."' AND '".$data['daterange_end']."')";
     45                                                $sql.=" AND (cellphone LIKE '%".$data['keyword']."%' OR collaborator LIKE '%".$data['keyword']."%' OR acc_balanced LIKE '%".$data['keyword']."%' OR province LIKE '%".$data['keyword']."%' OR acc_balanced LIKE '%".$data['keyword']."%' OR district LIKE '%".$data['keyword']."%' OR province LIKE '%".$data['keyword']."%') AND (created_time BETWEEN '".$data['daterange_start']."' AND '".$data['daterange_end']."')";
    4646                                        }else{
    47                                                 $sql.=" AND (cellphone LIKE '%".$data['keyword']."%' OR collaborator LIKE '%".$data['keyword']."%' OR acc_balanced LIKE '%".$data['keyword']."%' OR district LIKE '%".$data['keyword']."%' OR province LIKE '%".$data['keyword']."%' OR acc_balanced LIKE '%".$data['keyword']."%' OR district LIKE '%".$data['keyword']."%' OR province LIKE '%".$data['keyword']."%') ";
     47                                                $sql.=" AND (cellphone LIKE '%".$data['keyword']."%' OR collaborator LIKE '%".$data['keyword']."%' OR acc_balanced LIKE '%".$data['keyword']."%' OR province LIKE '%".$data['keyword']."%' OR acc_balanced LIKE '%".$data['keyword']."%' OR district LIKE '%".$data['keyword']."%' OR province LIKE '%".$data['keyword']."%') ";
    4848                                        }
    4949                                }
  • pro-violet-viettel/sourcecode/application/modules/admin/views/user/listview.php

    r690 r706  
    105105                                <th class="<?php if ($sorting_field == 'cellphone') {echo $sorting_order;} else {echo "sorting";}?>" id="cellphone" role="columnheader" tabindex="0" aria-controls="sample-table-2" rowspan="1" colspan="1" style="width: 156px;" aria-label="Số điện thoại: activate to sort column ascending">Số điện thoại</th>
    106106                                <th class="<?php if ($sorting_field == 'acc_balanced') {echo $sorting_order;} else {echo "sorting";}?>" id="acc_balanced" role="columnheader" tabindex="0" aria-controls="sample-table-2" rowspan="1" colspan="1" style="width: 156px;" aria-label="Tiền: activate to sort column ascending">Tài khoản (VNĐ)</th>
    107                                                                 <th style="width: 140px;">Quận/Huyện</th>
    108107                                                                <th style="width: 140px;">Tỉnh/TP</th>
    109108                                <th class="<?php if ($sorting_field == 'created_time') {echo $sorting_order;} else {echo "sorting";}?>" id="created_time" role="columnheader" tabindex="0" aria-controls="sample-table-2" rowspan="1" colspan="1" style="width: 156px;" aria-label="Ngày đăng kÜ: activate to sort column ascending">
     
    139138                                </td>
    140139                                <td class="hidden-480 "><?php echo number_format($user['acc_balanced'], 0); ?></td>
    141                                                                 <td><?php echo $user['district']; ?></td>
    142140                                                                <td><?php echo $user['province']; ?></td>
    143141                                <td class=" "><?php echo $user['created_time']; ?></td>
  • pro-violet-viettel/sourcecode/application/modules/frontend/controllers/user.php

    r701 r706  
    2525            $token = md5($us_id . self::TOKENPW);
    2626            $data = $this->get_data($src, $token, $us_id);
     27                        $data['can_edit'] = 0;
    2728            $u = $this->User_model->get_user_by_id($us_id);
     29                        if ($u['p_id'] < 1) {
     30                $data['can_edit'] = 1;
     31            }
     32            if ($data['fullname']=="")
     33            {
     34                $data['can_edit'] = 1;
     35            }
    2836            $data['current_tab'] = $this->uri->segment(4, 'edit-basic');
    2937            $data['packages'] = $this->Servicepackage_model->getAllPackages();
     
    5967            }
    6068           
     69                        if(strtotime($user['expire_date'])<strtotime(date('Y-m-d'))){
     70                                $result['can_edit'] = 1;
     71                        }
    6172            if ($user['p_id'] < 1) {
    6273                $result['can_edit'] = 1;
     
    133144        $user['expire_date'] = date('Y-m-d', strtotime("+" . $package['p_period'] . " ".$package['p_unit'], strtotime($currentExpireDate)));
    134145        $user['p_id'] = $package['p_id'];
    135                 $user['district'] = $input['district'];
     146                //$user['district'] = $input['district'];
    136147                $user['province'] = $input['province'];
    137148        $this->user_model->updateUser($us_id, $user);
  • pro-violet-viettel/sourcecode/application/modules/frontend/models/user_model.php

    r700 r706  
    166166                ), 'user' );
    167167                $u = array('province'=>$user['province'],
    168                                 'district'=>$user['district'],
    169168                                'updated_time'=>date('Y-m-d H:i:s')
    170169                                );
  • pro-violet-viettel/sourcecode/application/modules/frontend/views/package_register_modal.php

    r701 r706  
    5050                                                                <select name="province" id="form-field-province" class="input-large">
    5151                                                                <?php foreach (lang('_PROVINCES_') as $pro):?>
    52                                                                         <option value="<?php echo $pro;?>"><?php echo $pro; ?></option>
     52                                                                        <option value="<?php echo $pro;?>" <?php if($user['province'] == $pro) echo "selected"; ?> ><?php echo $pro; ?></option>
    5353                                                                <?php endforeach;?>
    5454                                                                </select>
    5555                                                        </div>
    5656                                                </div>
    57                                                 <div class="form-group">
     57                                                <!--div class="form-group">
    5858                                                        <label for="form-field-district" class="col-sm-4 control-label no-padding-right">Quận / Huyện</label>
    5959
    6060                                                        <div class="col-sm-8">
    61                                                                 <input type="text" name="district" value="<?php echo @$district; ?>" placeholder="Quận / Huyện" id="form-field-district" class="input-large">
     61                                                                <input type="text" name="district" value="<?php echo $user['district']; ?>" placeholder="Quận / Huyện" id="form-field-district" class="input-large">
    6262                                                        </div>
    63                                                 </div>
     63                                                </div-->
    6464
    6565<?php if ($can_edit == 1) { ?>
  • pro-violet-viettel/sourcecode/application/modules/frontend/views/user_profile.php

    r701 r706  
    7878                                                                                                               
    7979                                                                                                                <div class="col-sm-8">
    80                                                                                                                         <input type="text" name="fullname" value="<?php echo @$fullname; ?>" placeholder="Họ và tên" id="form-field-first" class="col-xs-12 col-sm-10" <?php if (isset($p_id)) echo 'disabled'; ?>>
     80                                                                                                                        <input type="text" name="fullname" value="<?php echo @$fullname; ?>" placeholder="Họ và tên" id="form-field-first" class="col-xs-12 col-sm-10" <?php if ($can_edit == 0) echo 'disabled'; ?>>
    8181
    8282                                                                                                                </div>
     
    109109                                                    </div>
    110110                                                </div>
    111                                                                                                 <div class="form-group">
     111                                                                                                <!--div class="form-group">
    112112                                                    <label for="form-field-username" class="col-sm-4 control-label no-padding-right">Quận / Huyện</label>
    113113
     
    115115                                                        <input type="text" name="district" value="<?php echo @$district; ?>" placeholder="Quận / Huyện" id="form-field-district" class="col-xs-12 col-sm-10">
    116116                                                    </div>
    117                                                 </div>
     117                                                </div-->
    118118                                               
    119119                                            </div>
Note: See TracChangeset for help on using the changeset viewer.