Ignore:
Timestamp:
Nov 13, 2014 6:46:32 PM (11 years ago)
Author:
quyenla
Message:

package resgister

Location:
pro-violet-viettel/sourcecode/application/modules/frontend
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • pro-violet-viettel/sourcecode/application/modules/frontend/controllers/user.php

    r490 r491  
    4444                        $us_id = $user_info['us_id'];
    4545                        $user = $this->user_model->get_user_by_id($us_id);
     46                        $result['can_buy']=1;
     47                        $result['can_edit']=0;
     48                        if ($user['acc_balanced'] < $package['p_price'])
     49                        {
     50                        $result['can_buy']=0;   
     51                        }
     52                       
     53                        if ($user['p_id'] < 1)
     54                        {
     55                        $result['can_edit']=1;
     56                        }
    4657                        $result['user']=$user;
    4758                        $result['package']=$package;
  • pro-violet-viettel/sourcecode/application/modules/frontend/views/package_register_modal.php

    r490 r491  
    88            <div class="modal-body">
    99                <div class="alert alert-block alert-success">                                           
     10                    <?php if ($can_buy==0) {?>
     11                    QuÜ thầy cÃŽ khÃŽng có đủ tiền trong tài khoản để đăng kÜ gói dịch vụ này, vui lòng nạp thêm tiền hoặc chọn gói khác.
     12                    <?php } ?>
     13                    <?php if ($can_edit==0) {?>
    1014                    <p>
    11                         Quí vị cần điền đầy đủ Họ và tên chính xác bằng tiếng Việt có dấu, các tên đơn vị sẜ khÃŽng được chấp nhận.
     15                    QuÜ thầy cÃŽ kiểm tra thÃŽng tin cá nhân cá»§a mình, vui lòng điền đầy đủ họ tên.
    1216                    </p>
     17                        <?php } ?>
    1318                </div>
    14                 <form class="form-horizontal" action="#" method="POST">
     19                <form id="do_package_register" class="form-horizontal" action="#" method="POST">
    1520                    <div class="form-group">
    1621                        <label for="form-field-first" class="col-sm-4 control-label no-padding-right">
    1722                            Họ và tên</label>
    1823                        <div class="col-sm-8">
    19                             <input type="text" value="" placeholder="Họ" id="form-field-first" class="input-small">
    20                             <input type="text" value="" placeholder="Tên" id="form-field-last" class="input-small">
     24                            <input <?php if ($can_edit==0) {?>  disabled <?php } ?> type="text" value="<?php echo "ten"; $?>" placeholder="Họ" id="form-field-first" class="input-small">
     25                            <input <?php if ($can_edit==0) {?> disabled <?php } ?>type="text" value="" placeholder="Tên" id="form-field-last" class="input-small">
    2126                        </div>
    2227                    </div>
     
    3338                </form>
    3439                <div class="modal-footer">
     40                    <a href="#" class="btn btn-success" data-dismiss="modal">Quay lại</a>
     41                    <?php if ($can_buy==1) {?>
    3542                    <a href="#" class="btn btn-success" data-dismiss="modal">Đăng kÜ</a>
     43                    <?php } ?>
    3644                </div>
    3745            </div>
Note: See TracChangeset for help on using the changeset viewer.