source: pro-violet-viettel/sourcecode/application/modules/frontend/views/user_profile.php @ 838

Last change on this file since 838 was 838, checked in by namnd, 10 years ago
File size: 27.6 KB
Line 
1<?php
2$base_url = base_url();
3$this->load->view('layout/frontend/header', array('base_url' => $base_url, '$username' => @$username));
4$this->load->view('layout/frontend/sidebar', array('base_url' => $base_url));
5?>
6<div class="main-content">
7
8    <div class="page-content">
9        <div class="page-header">
10            <h1>
11                ThÃŽng tin cá nhân
12                <small>
13                    <i class="icon-double-angle-right"></i>
14                    <?php echo @$username; ?>
15                </small>
16            </h1>
17        </div><!-- /.page-header -->
18
19        <div class="row">
20            <div class="col-xs-12">
21                <!-- PAGE CONTENT BEGINS -->
22                <div class="user-profile row" id="user-profile-3">
23                    <div class="col-sm-offset-1 col-sm-10">
24
25                        <div class="tabbable">
26                            <ul class="nav nav-tabs padding-16">
27                                <li class="active" >
28                                    <a id="edit-basic-tab" href="#edit-basic" data-toggle="tab">
29                                        <i class="green icon-edit bigger-125"></i>
30                                        ThÃŽng tin cá nhân
31                                    </a>
32                                </li>
33
34                                <li >
35                                    <a id="edit-password-tab" href="#edit-password" data-toggle="tab">
36                                        <i class="blue icon-key bigger-125"></i>
37                                        Đổi mật khẩu
38                                    </a>
39                                </li>
40
41                                <li >
42                                    <a id="account-info-tab" href="#account-info" data-toggle="tab">
43                                        <img src="<?php echo $base_url; ?>assets/img/payment.png" width="16" class="img-responsive pull-left">
44                                        ThÃŽng tin tài khoản
45                                    </a>
46                                </li>
47                                <li >
48                                    <a id="services-register-tab" href="#services-register" data-toggle="tab">
49                                        <i class="blue icon-cog bigger-125"></i>
50                                        Đăng kÜ dịch vụ
51                                    </a>
52                                </li>
53                            </ul>
54
55                            <div class="tab-content profile-edit-tab-content">
56                                <div class="tab-pane in active" id="edit-basic">
57                                    <form id="frm1" role="form" class="form-horizontal">
58                                        <h4 class="header blue bolder smaller">ThÃŽng tin cá nhân</h4>
59
60                                        <div class="row">
61
62                                            <div class="vspace-xs"></div>
63
64                                            <div class="col-sm-9">
65                                                <div class="form-group">
66                                                    <label for="form-field-username" class="col-sm-4 control-label no-padding-right">Số điện thoại</label>
67
68                                                    <div class="col-sm-8">
69                                                        <input type="text" name="username" value="<?php echo @$username; ?>" placeholder="Số điện thoại" id="form-field-username" class="col-xs-12 col-sm-10" disabled>
70                                                    </div>
71                                                </div>
72
73                                                <div class="space-4"></div>
74                                                       
75                                                <div class="form-group">
76                                                    <label for="form-field-first" class="col-sm-4 control-label no-padding-right">Họ và tên</label>
77                                                                                                        <label class="block clearfix has-error">
78                                                                                                               
79                                                                                                                <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 ($can_edit == 0) echo 'disabled'; ?>>
81
82                                                                                                                </div>
83                                                                                                                <small><div class="col-sm-8 help-block" id="fullname_err"> </div></small>
84                                                                                                        </label>
85                                                </div>
86
87                                                <div class="space-4"></div>
88
89                                                <div class="form-group">
90                                                    <label for="form-field-username" class="col-sm-4 control-label no-padding-right">Đơn vị</label>
91
92                                                    <div class="col-sm-8">
93                                                        <input type="text" name="school" value="<?php echo @$school; ?>" placeholder="Đơn vị" id="form-field-username" class="col-xs-12 col-sm-10">
94                                                    </div>
95                                                </div>
96
97                                                <div class="space-4"></div>
98                                                                                               
99                                                <div class="form-group">
100                                                    <label for="form-field-username" class="col-sm-4 control-label no-padding-right">Tỉnh / Thành phố</label>
101
102                                                    <div class="col-sm-8">
103                                                     
104                                                                                                                <select name="province" id="form-field-province" class="form-field-province col-xs-12 col-sm-10">
105                                                                                                                        <option></option>
106                                                                                                                <?php foreach ($provinces as $key=>$pro):?>
107                                                                                                                        <option value="<?php echo $key;?>" <?php if($province==$key) echo "selected"; ?>><?php echo $pro; ?></option>
108                                                                                                                <?php endforeach;?>
109                                                                                                                </select>
110                                                    </div>
111                                                </div>
112                                                                                                <div class="space-4"></div>
113                                                                                                <div class="form-group">
114                                                    <label for="form-field-username" class="col-sm-4 control-label no-padding-right">Quận / Huyện</label>
115                                                                                                        <div class="col-sm-8">
116                                                                                                                <select name="district" id="form-field-district" class="form-field-district col-xs-12 col-sm-10">
117                                                                       
118                                                                                                                </select>
119                                                                                                        </div>
120                                                </div>
121                                                                                               
122                                               
123                                            </div>
124                                                                                        <div class="col-sm-3">
125                                                                                        <!--<h4><small><a href="#" data-toggle="modal" data-target="#changeProfile"><i>Đổi số điện thoại</i></a></small></h4>-->
126                                                                                        </div>
127                                        </div>
128                                        <div class="space-4"></div>
129
130                                        <div class="clearfix form-actions">
131                                            <div class="col-md-offset-3 col-md-9">
132                                                <button type="button" onclick="return updateInfo(<?php echo @$us_id; ?>);" class="btn btn-info">
133                                                    <i class="icon-ok bigger-110"></i>
134                                                    Cập nhật
135                                                </button>
136                                                                                               
137                                            </div>
138                                                                                        <div class="col-md-offset-3 col-md-9"><label id="updating" style="display: none;"><span class="icon-refresh icon-refresh-animate"></span> Đang xá»­ lÜ...</label>
139                                                                                        </div>
140                                        </div>
141                                    </form>
142                                </div>
143
144
145                                <div class="tab-pane" id="edit-password">
146                                                                        <form id="frm2" class="form-horizontal" role="form">
147                                                                                <h4 class="header blue bolder smaller">Đổi mật khẩu</h4>
148                                                                                <div class="form-group">
149                                                                                        <label for="form-field-passwd" class="col-sm-3 control-label no-padding-right">Mật khẩu cÅ©</label>
150                                                                                        <div class="col-sm-9">
151                                                                                                <label class="block clearfix has-error">
152                                                                                                        <span class="input-icon">
153                                                                                                                <input type="password" name="passwd" id="form-field-pass1">
154                                                                                                                <i class="icon-lock blue"></i>
155                                                                                                        </span>
156
157                                                                                                        <small><div class="help-block" id="passwd_old_err"> </div></small>
158                                                                                                </label>
159                                                                                               
160                                                                                        </div>
161                                                                                </div>
162                                                                               
163                                                                                <div class="form-group">
164                                                                                        <label for="form-field-pass1" class="col-sm-3 control-label no-padding-right">Mật khẩu mới</label>
165
166                                                                                        <div class="col-sm-9">
167                                                                                                <label class="block clearfix has-error">
168                                                                                                        <span class="input-icon">
169                                                                                                                <input type="password" name="passwd_new" id="form-field-pass1">
170                                                                                                                <i class="icon-lock blue"></i>
171                                                                                                        </span>
172                                                                                                        <small><div class="help-block" id="passwd_new_err"> </div></small>
173                                                                                                </label>
174                                                                                        </div>
175                                                                                </div>
176
177                                                                                <div class="space-4"></div>
178
179                                                                                <div class="form-group">
180                                                                                        <label for="form-field-pass2" class="col-sm-3 control-label no-padding-right">Gõ lại mật khẩu mới</label>
181                                                                                        <div class="col-sm-9">
182                                                                                                <label class="block clearfix has-error">
183                                                                                                        <span class="input-icon">
184                                                                                                                <input type="password" name="confirm_passwd_new" id="form-field-pass2">
185                                                                                                        </span>
186                                                                                                        <small><div class="help-block" id="confirm_passwd_new_err"> </div></small>
187                                                                                                </label>
188                                                                                        </div>
189                                                                                </div>
190                                                                                <div class="clearfix form-actions">
191                                                                                        <div class="col-md-offset-3 col-md-9">
192                                                                                                <button type="button" onclick="return changePassword(<?php echo @$us_id; ?>);"  class="btn btn-info">
193                                                                                                        <i class="icon-ok bigger-110"></i>
194                                                                                                        Thay đổi
195                                                                                                </button>
196                                                                                        </div>
197                                                                                </div>
198                                                                               
199                                                                                </form>
200                               
201                                                                                <!--div class="alert alert-block alert-success">
202                                                                                       
203                                                                                        <p>
204                                                                                                QuÜ vị cÅ©ng có thể thay đổi mật khẩu bằng cách dùng số điện thoại <strong><?php echo $username; ?></strong> và soạn tin theo cú pháp: <strong>SBG MK [MatKhauMoi]</strong> gá»­i tới <strong>8062</strong> (500đ/tin).
205                                                                                        <p/>
206                                                                                </div-->
207                                </div>
208
209                                <div class="tab-pane" id="account-info">
210                                    <form id="frm3" class="form-horizontal" role="form">
211                                        <h4 class="header blue bolder smaller">ThÃŽng tin tài khoản</h4>
212                                                                                <div class="col-sm-12">
213                                                                                        <h4>Số tiền trong tài khoản SBG Online: <b><span class="blue" id="topup-money"><?php echo number_format(@$acc_balanced, 0); ?> VNĐ <span></b></h4>
214
215                                        </div>                                                                 
216                                        <h4 class="header blue bolder smaller">Nạp tiền bằng thẻ cào</h4>
217                                        <div class="col-sm-8">
218                                            <div class="form-group">
219                                                <label for="form-field-pass1" class="col-sm-2 control-label no-padding-right">Mã thẻ</label>
220
221                                                <div class="col-sm-10">
222                                                    <input type="text" id="pin_card" name="pin_card" class="form-control">
223                                                </div>
224                                            </div>
225
226                                            <div class="space-4"></div>
227
228                                            <div class="form-group">
229                                                <label for="form-field-pass2" class="col-sm-2 control-label no-padding-right">Serial</label>
230
231                                                <div class="col-sm-10">
232                                                    <input type="text" id="card_serial" name="card_serial" class="form-control">
233                                                </div>
234                                            </div>
235                                        </div>
236                                        <div class="col-sm-4">
237                                            <button type="button" id="btn-charge" onclick="return chargeCard(<?php echo @$us_id; ?>);" class="btn btn-success">
238                                                <i class="icon-ok bigger-110"></i>
239                                                Tiếp tục
240                                            </button>
241                                                                                        <div class="space-4"></div>
242                                                                                        <label id="charging" style="display: none;"><span class="icon-refresh icon-refresh-animate"></span> Xin chờ...</label>
243                                            <div class="space-4"></div>
244                                            <a onclick="tradeHistory(<?php echo $us_id; ?>, 1);" data-toggle="modal"><i class="icon-archive"></i> Lịch sá»­ giao dịch</a>
245                                        </div>
246                                        <div class="clearfix">
247
248                                        </div>
249                                        <h4 class="header blue bolder smaller">Nạp tiền bằng tài khoản gốc</h4>
250                                        <div class="alert alert-block alert-success">                                           
251                                            <p>
252                                                <span <?php if(($is_viettel==1)) /*echo 'style="display: none;"'*/{?> >Sá»­ dụng thuê bao <strong><?php echo @$username; ?></strong> soạn tin nhắn: <strong>SBG NAP [SoTien] gá»­i 8062</strong>.<?php } ?> </span><br/>
253                                                Nếu QuÜ vị sá»­ dụng thuê bao Viettel khác thì soạn tin nhắn: <strong>SBG NAP [SoTien] <?php  echo $username; ?> gá»­i tới 8062</strong>.
254         
255                                            </p>
256                                        </div>
257                                    </form>
258                                </div>
259                                <div class="tab-pane" id="services-register">
260                                    <!--<form action="<?php echo base_url();?>frontend/user/packageRegister"  class="form-horizontal" id="package_register"> -->
261                                    <form action="<?php echo base_url();?>frontend/user/packageRegister" method="POST" class="form-horizontal" id="package_register">
262                                        <h4 class="header blue bolder smaller">ThÃŽng tin dịch vụ &nbsp;&nbsp;&nbsp;<a onclick="regisHistory(<?php echo $us_id; ?>, 1);" data-toggle="modal"><i class="icon-archive"></i> Lịch sá»­ đăng kÜ dịch vụ</a></h4>
263                                                                                <div class="col-sm-6">
264                                            <h4><b>Thời hạn sá»­ dụng</b></h4> <h3><b><span class="blue"><?php echo isset($expire_date) && strtotime($expire_date)>0 ? date('d/m/Y', strtotime($expire_date)) : '';?> </span></b></h3>
265                                        </div>
266                                                                                <div class="col-sm-6">
267                                            <h4>Số tiền trong tài khoản SBG Online</h4><h3> <span id="vip-regis-money"> <?php echo number_format(@$acc_balanced, 0); ?></span> VNĐ <span id="add_money" style="cursor:pointer" class="badge" >Nạp thêm tiền</span></h3>
268                                        </div>
269
270                                        <h4 class="header blue bolder smaller">Đăng kÜ / Gia hạn dịch vụ</h4>
271
272                                        <h5>Mời QuÜ vị chọn các gói dịch vụ sau:</h5>
273                                        <div class="errors" id="package_register">
274                                           
275                                        </div>
276                                        <div class="alert alert-block alert-success">                                           
277                                            <table class="table">
278                                                <tbody>
279                                                    <?php foreach ($packages as $index=>$package)
280                                                    {
281                                                    ?>
282                                                    <tr>
283                                                        <td class="center">
284                                                            <label>
285                                                                <input <?php if($index==0) {echo "checked='checked'";}?> type="radio" value="<?php echo $package['p_id'];?>" name="p_id" class="ace" />
286                                                                <span class="lbl"></span>
287                                                            </label>
288                                                        </td>
289                                                        <td><?php echo $package['p_name'];?></td>
290                                                        <td><?php echo $package['p_period'],' tháng (', number_format($package['p_price'], 0); ?> VNĐ)</td>
291                                                       
292                                                    </tr>
293                                                    <?php } ?>
294                                                   
295                                                </tbody>
296                                            </table>
297                                            <button type="submit" class="btn btn-success">Tiếp tục</button>
298                                        </div>
299                                       
300                                               <?php if ($is_viettel==true) { ?>
301                                        <h4 class="header blue bolder smaller"></h4>
302                                        <div class="alert alert-block alert-success">                                           
303                                            <p>
304                                                QuÜ vị cÅ©ng có thể sá»­ dụng số điện thoại&nbsp;<strong><?php echo $username;?></strong> và soạn tin theo cú pháp: <strong>SBG VIP 1</strong> (hay VIP 3, VIP 6, VIP 12) <strong>gá»­i tới 8062</strong> (Hệ thống sẜ trừ tiền trên tài khoản chính cá»§a số điện thoại&nbsp;<strong><?php echo $username;?></strong>)
305                                        </p>
306                                        </div>
307                                            <?php } ?>
308                                           
309                                       
310                                    </form>
311                                </div>
312
313                            </div>
314                        </div>
315                    </div><!-- /span -->
316                </div>
317
318                <!-- PAGE CONTENT ENDS -->
319            </div><!-- /.col -->
320        </div><!-- /.row -->
321    </div><!-- /.page-content -->
322</div><!-- /.main-content -->
323</div><!-- /.main-container-inner -->
324
325<!-- <a href="#" id="btn-scroll-up" class="btn-scroll-up btn btn-sm btn-inverse">
326    <i class="icon-double-angle-up icon-only bigger-110"></i>
327</a> -->
328</div><!-- /.main-container -->
329
330<div class="modal fade" id="trade-history" tabindex="-1" role="dialog"aria-hidden="true">
331    <div class="modal-dialog">
332        <div class="modal-content">
333            <div class="modal-header">
334                <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
335                <h4 class="modal-title">Lịch sá»­ giao dịch</h4>
336            </div>
337            <div class="modal-body">
338                <div class="table-responsive">
339                    <table id="sample-table-1" class="table table-striped table-bordered table-hover">
340                        <thead>
341                            <tr>
342                                <th class="center">
343                                                                        Từ
344                                </th>
345                                <th class="center">Số tiền (VNĐ)</th>
346                                <th>
347                                    <i class="icon-time bigger-110 hidden-480"></i>
348                                    Thời gian
349                                </th>
350                            </tr>
351                        </thead>
352                        <tbody id="content-trade-histoty">
353                        </tbody>
354                    </table>
355                                        <div>
356                                                <div class="dataTables_paginate paging_bootstrap">
357                                                        <ul class="pagination">
358                                                        </ul>
359                                                </div>
360                                        </div>
361                </div><!-- /.table-responsive -->
362            </div>
363        </div>
364    </div>
365</div>
366
367<div class="modal fade" id="package_register_modal" tabindex="-1" role="dialog"aria-hidden="true">
368    <div class="modal-dialog">
369        <div class="modal-content">
370            <div class="modal-header">
371                <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
372                <h4 class="modal-title">Đăng kÜ gói dịch vụ</h4>
373            </div>
374            <div class="modal-body">
375                <div class="alert alert-block alert-success">                                           
376                   
377                </div>
378            </div>
379        </div>
380    </div>
381</div>
382
383<div class="modal fade" id="changeProfile" tabindex="-1" role="dialog"aria-hidden="true">
384        <div class="modal-dialog">
385                <div class="modal-content">
386                        <div class="modal-header">
387                                <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
388                                <h4 class="modal-title">Thay đổi số điện thoại</h4>
389                                </div>
390                                <div class="modal-body">
391                                <div class="alert alert-block alert-success">                                           
392                                        <?php echo lang('_SBG_USER_PHONENUM_CHANGE_MSG'); ?>
393                                </div>
394                        </div>
395                </div>
396        </div>
397</div>
398
399<div class="modal fade" id="changePassSuccess" tabindex="-1" role="dialog"aria-hidden="true">
400        <div class="modal-dialog">
401                <div class="modal-content">
402                        <div class="modal-header">
403                                <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
404                                <h4 class="modal-title">Đổi mật khẩu</h4>
405                        </div>
406                        <div class="modal-body">
407                                <div class="alert alert-block alert-success"><center><?php echo lang('_SBG_USER_PASSWORD_CHANGE_SUCCESS_MSG'); ?></center></div>
408                                <center><button class="btn btn-primary" data-dismiss="modal">Đóng</button></center>
409                        </div>
410               
411                </div>
412        </div>
413</div>
414
415<div class="modal fade" id="updateInfoSuccess" tabindex="-1" role="dialog"aria-hidden="true">
416        <div class="modal-dialog">
417                <div class="modal-content">
418                        <div class="modal-header">
419                                <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
420                                <h4 class="modal-title">Cập nhật thÃŽng tin</h4>
421                        </div>
422                        <div class="modal-body">
423                                <div class="alert alert-block alert-success"><center><?php echo lang('_SBG_USER_UPDATE_INFO_SUCCESS_MSG'); ?><center></div>
424                                <center><button id="close" class="btn btn-primary" data-dismiss="modal">Đóng</button></center>
425                        </div>
426               
427                </div>
428        </div>
429</div>
430
431<div class="modal fade" id="success_package_register_modal" tabindex="-1" role="dialog"aria-hidden="true">
432        <div class="modal-dialog">
433                <div class="modal-content">
434                        <div class="modal-header">
435                                <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
436                                <h4 class="modal-title">Đăng kí thành cÃŽng</h4>
437                        </div>
438                        <div class="modal-body">
439                                <div id="success_package_register_content" class="alert alert-block alert-success"><center></center></div>
440                                <center><button id="package_register_finish_button" class="btn btn-primary" data-dismiss="modal">Đóng</button></center>
441                        </div>
442               
443                </div>
444        </div>
445</div>
446
447<div class="modal fade" id="success_charge" tabindex="-1" role="dialog"aria-hidden="true">
448        <div class="modal-dialog">
449                <div class="modal-content">
450                        <div class="modal-header">
451                                <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
452                                <h4 class="modal-title">Nạp tiền</h4>
453                        </div>
454                        <div class="modal-body">
455                                <div id="success_charge_info" class="alert alert-block alert-success"><center></center></div>
456                                <center><button id="package_register_finish_button" data-dismiss="modal" class="btn btn-primary" >Đóng</button></center>
457                        </div>
458               
459                </div>
460        </div>
461</div>
462
463<div class="modal fade" id="not_success_charge" tabindex="-1" role="dialog"aria-hidden="true">
464        <div class="modal-dialog">
465                <div class="modal-content">
466                        <div class="modal-header">
467                                <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
468                                <h4 class="modal-title">Nạp tiền</h4>
469                        </div>
470                        <div class="modal-body">
471                                <div id="no_success_charge_info" class="alert alert-block alert-success"><center></center></div>
472                                <center><button id="package_register_finish_button" data-dismiss="modal" class="btn btn-primary" >Đóng</button></center>
473                        </div>
474               
475                </div>
476        </div>
477</div>
478
479<div class="modal fade" id="regis-history" tabindex="-1" role="dialog"aria-hidden="true">
480    <div class="modal-dialog">
481        <div class="modal-content">
482            <div class="modal-header">
483                <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
484                <h4 class="modal-title">Lịch sá»­ đăng kÜ dịch vụ</h4>
485            </div>
486            <div class="modal-body">
487                <div class="table-responsive">
488                    <table id="sample-table-1" class="table table-striped table-bordered table-hover">
489                        <thead>
490                            <tr>
491                                <th class="center">
492                                                                        Từ
493                                </th>
494                                                                <th class="center">
495                                                                        Số tiền (VNĐ)
496                                </th>
497                                <th class="center"> Dịch vụ </th>
498                                <th>
499                                    <i class="icon-time bigger-110 hidden-480"></i>
500                                    Thời gian
501                                </th>
502                            </tr>
503                        </thead>
504                        <tbody id="content-regis-histoty">
505                        </tbody>
506                    </table>
507                                        <div>
508                                                <div class="dataTables_paginate paging_bootstrap">
509                                                        <ul class="pagination">
510                                                        </ul>
511                                                </div>
512                                        </div>
513                </div><!-- /.table-responsive -->
514            </div>
515        </div>
516    </div>
517</div>
518
519<script type="text/javascript">
520        var url="<?php echo base_url();?>";
521        var district_id = "<?php echo $district; ?>";
522        var current_tab="<?php echo $current_tab;?>";
523        //var current_balanced = <?php echo $acc_balanced; ?>;
524</script>
525<?php
526$this->load->view('layout/frontend/footer', array('base_url' => $base_url, 'usjs' => array('assets/js/frontend/user.js')));
527?>
Note: See TracBrowser for help on using the repository browser.