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

Last change on this file since 773 was 773, checked in by namnd, 10 years ago
File size: 27.7 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                                                        <!--input type="text" name="province" value="<?php echo @$province; ?>" placeholder="Tỉnh / Thành phố" id="form-field-province" class="col-xs-12 col-sm-10"-->
104                                                                                                                <select name="province" id="form-field-province" class="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="form-group">
113                                                    <label for="form-field-username" class="col-sm-4 control-label no-padding-right">Quận / Huyện</label>
114
115                                                    <div class="col-sm-8">
116                                                        <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">
117                                                    </div>
118                                                </div-->
119                                               
120                                            </div>
121                                                                                        <div class="col-sm-3">
122                                                                                        <!--<h4><small><a href="#" data-toggle="modal" data-target="#changeProfile"><i>Đổi số điện thoại</i></a></small></h4>-->
123                                                                                        </div>
124                                        </div>
125                                        <div class="space-4"></div>
126
127                                        <div class="clearfix form-actions">
128                                            <div class="col-md-offset-3 col-md-9">
129                                                <button type="button" onclick="return updateInfo(<?php echo @$us_id; ?>);" class="btn btn-info">
130                                                    <i class="icon-ok bigger-110"></i>
131                                                    Cập nhật
132                                                </button>
133                                                                                               
134                                            </div>
135                                                                                        <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>
136                                                                                        </div>
137                                        </div>
138                                    </form>
139                                </div>
140
141
142                                <div class="tab-pane" id="edit-password">
143                                                                        <form id="frm2" class="form-horizontal" role="form">
144                                                                                <h4 class="header blue bolder smaller">Đổi mật khẩu</h4>
145                                                                                <div class="form-group">
146                                                                                        <label for="form-field-passwd" class="col-sm-3 control-label no-padding-right">Mật khẩu cÅ©</label>
147                                                                                        <div class="col-sm-9">
148                                                                                                <label class="block clearfix has-error">
149                                                                                                        <span class="input-icon">
150                                                                                                                <input type="password" name="passwd" id="form-field-pass1">
151                                                                                                                <i class="icon-lock blue"></i>
152                                                                                                        </span>
153
154                                                                                                        <small><div class="help-block" id="passwd_old_err"> </div></small>
155                                                                                                </label>
156                                                                                               
157                                                                                        </div>
158                                                                                </div>
159                                                                               
160                                                                                <div class="form-group">
161                                                                                        <label for="form-field-pass1" class="col-sm-3 control-label no-padding-right">Mật khẩu mới</label>
162
163                                                                                        <div class="col-sm-9">
164                                                                                                <label class="block clearfix has-error">
165                                                                                                        <span class="input-icon">
166                                                                                                                <input type="password" name="passwd_new" id="form-field-pass1">
167                                                                                                                <i class="icon-lock blue"></i>
168                                                                                                        </span>
169                                                                                                        <small><div class="help-block" id="passwd_new_err"> </div></small>
170                                                                                                </label>
171                                                                                        </div>
172                                                                                </div>
173
174                                                                                <div class="space-4"></div>
175
176                                                                                <div class="form-group">
177                                                                                        <label for="form-field-pass2" class="col-sm-3 control-label no-padding-right">Gõ lại mật khẩu mới</label>
178                                                                                        <div class="col-sm-9">
179                                                                                                <label class="block clearfix has-error">
180                                                                                                        <span class="input-icon">
181                                                                                                                <input type="password" name="confirm_passwd_new" id="form-field-pass2">
182                                                                                                        </span>
183                                                                                                        <small><div class="help-block" id="confirm_passwd_new_err"> </div></small>
184                                                                                                </label>
185                                                                                        </div>
186                                                                                </div>
187                                                                                <div class="clearfix form-actions">
188                                                                                        <div class="col-md-offset-3 col-md-9">
189                                                                                                <button type="button" onclick="return changePassword(<?php echo @$us_id; ?>);"  class="btn btn-info">
190                                                                                                        <i class="icon-ok bigger-110"></i>
191                                                                                                        Thay đổi
192                                                                                                </button>
193                                                                                        </div>
194                                                                                </div>
195                                                                               
196                                                                                </form>
197                               
198                                                                                <!--div class="alert alert-block alert-success">
199                                                                                       
200                                                                                        <p>
201                                                                                                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).
202                                                                                        <p/>
203                                                                                </div-->
204                                </div>
205
206                                <div class="tab-pane" id="account-info">
207                                    <form id="frm3" class="form-horizontal" role="form">
208                                        <h4 class="header blue bolder smaller">ThÃŽng tin tài khoản</h4>
209                                                                                <div class="col-sm-12">
210                                                                                        <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>
211
212                                        </div>                                                                 
213                                        <h4 class="header blue bolder smaller">Nạp tiền bằng thẻ cào</h4>
214                                        <div class="col-sm-8">
215                                            <div class="form-group">
216                                                <label for="form-field-pass1" class="col-sm-2 control-label no-padding-right">Mã thẻ</label>
217
218                                                <div class="col-sm-10">
219                                                    <input type="text" id="pin_card" name="pin_card" class="form-control">
220                                                </div>
221                                            </div>
222
223                                            <div class="space-4"></div>
224
225                                            <div class="form-group">
226                                                <label for="form-field-pass2" class="col-sm-2 control-label no-padding-right">Serial</label>
227
228                                                <div class="col-sm-10">
229                                                    <input type="text" id="card_serial" name="card_serial" class="form-control">
230                                                </div>
231                                            </div>
232                                        </div>
233                                        <div class="col-sm-4">
234                                            <button type="button" id="btn-charge" onclick="return chargeCard(<?php echo @$us_id; ?>);" class="btn btn-success">
235                                                <i class="icon-ok bigger-110"></i>
236                                                Tiếp tục
237                                            </button>
238                                                                                        <div class="space-4"></div>
239                                                                                        <label id="charging" style="display: none;"><span class="icon-refresh icon-refresh-animate"></span> Xin chờ...</label>
240                                            <div class="space-4"></div>
241                                            <a onclick="tradeHistory(<?php echo $us_id; ?>, 1);" data-toggle="modal"><i class="icon-archive"></i> Lịch sá»­ giao dịch</a>
242                                        </div>
243                                        <div class="clearfix">
244
245                                        </div>
246                                        <h4 class="header blue bolder smaller">Nạp tiền bằng tài khoản gốc</h4>
247                                        <div class="alert alert-block alert-success">                                           
248                                            <p>
249                                                <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/>
250                                                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>.
251         
252                                            </p>
253                                        </div>
254                                    </form>
255                                </div>
256                                <div class="tab-pane" id="services-register">
257                                    <!--<form action="<?php echo base_url();?>frontend/user/packageRegister"  class="form-horizontal" id="package_register"> -->
258                                    <form action="<?php echo base_url();?>frontend/user/packageRegister" method="POST" class="form-horizontal" id="package_register">
259                                        <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>
260                                                                                <div class="col-sm-6">
261                                            <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>
262                                        </div>
263                                                                                <div class="col-sm-6">
264                                            <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>
265                                        </div>
266
267                                        <h4 class="header blue bolder smaller">Đăng kÜ / Gia hạn dịch vụ</h4>
268
269                                        <h5>Mời QuÜ vị chọn các gói dịch vụ sau:</h5>
270                                        <div class="errors" id="package_register">
271                                           
272                                        </div>
273                                        <div class="alert alert-block alert-success">                                           
274                                            <table class="table">
275                                                <tbody>
276                                                    <?php foreach ($packages as $index=>$package)
277                                                    {
278                                                    ?>
279                                                    <tr>
280                                                        <td class="center">
281                                                            <label>
282                                                                <input <?php if($index==0) {echo "checked='checked'";}?> type="radio" value="<?php echo $package['p_id'];?>" name="p_id" class="ace" />
283                                                                <span class="lbl"></span>
284                                                            </label>
285                                                        </td>
286                                                        <td><?php echo $package['p_name'];?></td>
287                                                        <td><?php echo $package['p_period'],' tháng (', number_format($package['p_price'], 0); ?> VNĐ)</td>
288                                                       
289                                                    </tr>
290                                                    <?php } ?>
291                                                   
292                                                </tbody>
293                                            </table>
294                                            <button type="submit" class="btn btn-success">Tiếp tục</button>
295                                        </div>
296                                       
297                                               <?php if ($is_viettel==true) { ?>
298                                        <h4 class="header blue bolder smaller"></h4>
299                                        <div class="alert alert-block alert-success">                                           
300                                            <p>
301                                                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>)
302                                        </p>
303                                        </div>
304                                            <?php } ?>
305                                           
306                                       
307                                    </form>
308                                </div>
309
310                            </div>
311                        </div>
312                    </div><!-- /span -->
313                </div>
314
315                <!-- PAGE CONTENT ENDS -->
316            </div><!-- /.col -->
317        </div><!-- /.row -->
318    </div><!-- /.page-content -->
319</div><!-- /.main-content -->
320</div><!-- /.main-container-inner -->
321
322<!-- <a href="#" id="btn-scroll-up" class="btn-scroll-up btn btn-sm btn-inverse">
323    <i class="icon-double-angle-up icon-only bigger-110"></i>
324</a> -->
325</div><!-- /.main-container -->
326
327<div class="modal fade" id="trade-history" tabindex="-1" role="dialog"aria-hidden="true">
328    <div class="modal-dialog">
329        <div class="modal-content">
330            <div class="modal-header">
331                <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
332                <h4 class="modal-title">Lịch sá»­ giao dịch</h4>
333            </div>
334            <div class="modal-body">
335                <div class="table-responsive">
336                    <table id="sample-table-1" class="table table-striped table-bordered table-hover">
337                        <thead>
338                            <tr>
339                                <th class="center">
340                                                                        Từ
341                                </th>
342                                <th class="center">Số tiền (VNĐ)</th>
343                                <th>
344                                    <i class="icon-time bigger-110 hidden-480"></i>
345                                    Thời gian
346                                </th>
347                            </tr>
348                        </thead>
349                        <tbody id="content-trade-histoty">
350                        </tbody>
351                    </table>
352                                        <div>
353                                                <div class="dataTables_paginate paging_bootstrap">
354                                                        <ul class="pagination">
355                                                        </ul>
356                                                </div>
357                                        </div>
358                </div><!-- /.table-responsive -->
359            </div>
360        </div>
361    </div>
362</div>
363
364<div class="modal fade" id="package_register_modal" tabindex="-1" role="dialog"aria-hidden="true">
365    <div class="modal-dialog">
366        <div class="modal-content">
367            <div class="modal-header">
368                <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
369                <h4 class="modal-title">Đăng kÜ gói dịch vụ</h4>
370            </div>
371            <div class="modal-body">
372                <div class="alert alert-block alert-success">                                           
373                   
374                </div>
375            </div>
376        </div>
377    </div>
378</div>
379
380<div class="modal fade" id="changeProfile" tabindex="-1" role="dialog"aria-hidden="true">
381        <div class="modal-dialog">
382                <div class="modal-content">
383                        <div class="modal-header">
384                                <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
385                                <h4 class="modal-title">Thay đổi số điện thoại</h4>
386                                </div>
387                                <div class="modal-body">
388                                <div class="alert alert-block alert-success">                                           
389                                        <?php echo lang('_SBG_USER_PHONENUM_CHANGE_MSG'); ?>
390                                </div>
391                        </div>
392                </div>
393        </div>
394</div>
395
396<div class="modal fade" id="changePassSuccess" tabindex="-1" role="dialog"aria-hidden="true">
397        <div class="modal-dialog">
398                <div class="modal-content">
399                        <div class="modal-header">
400                                <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
401                                <h4 class="modal-title">Đổi mật khẩu</h4>
402                        </div>
403                        <div class="modal-body">
404                                <div class="alert alert-block alert-success"><center><?php echo lang('_SBG_USER_PASSWORD_CHANGE_SUCCESS_MSG'); ?></center></div>
405                                <center><button class="btn btn-primary" data-dismiss="modal">Đóng</button></center>
406                        </div>
407               
408                </div>
409        </div>
410</div>
411
412<div class="modal fade" id="updateInfoSuccess" tabindex="-1" role="dialog"aria-hidden="true">
413        <div class="modal-dialog">
414                <div class="modal-content">
415                        <div class="modal-header">
416                                <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
417                                <h4 class="modal-title">Cập nhật thÃŽng tin</h4>
418                        </div>
419                        <div class="modal-body">
420                                <div class="alert alert-block alert-success"><center><?php echo lang('_SBG_USER_UPDATE_INFO_SUCCESS_MSG'); ?><center></div>
421                                <center><button id="close" class="btn btn-primary" data-dismiss="modal">Đóng</button></center>
422                        </div>
423               
424                </div>
425        </div>
426</div>
427
428<div class="modal fade" id="success_package_register_modal" tabindex="-1" role="dialog"aria-hidden="true">
429        <div class="modal-dialog">
430                <div class="modal-content">
431                        <div class="modal-header">
432                                <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
433                                <h4 class="modal-title">Đăng kí thành cÃŽng</h4>
434                        </div>
435                        <div class="modal-body">
436                                <div id="success_package_register_content" class="alert alert-block alert-success"><center></center></div>
437                                <center><button id="package_register_finish_button" class="btn btn-primary" data-dismiss="modal">Đóng</button></center>
438                        </div>
439               
440                </div>
441        </div>
442</div>
443
444<div class="modal fade" id="success_charge" tabindex="-1" role="dialog"aria-hidden="true">
445        <div class="modal-dialog">
446                <div class="modal-content">
447                        <div class="modal-header">
448                                <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
449                                <h4 class="modal-title">Nạp tiền</h4>
450                        </div>
451                        <div class="modal-body">
452                                <div id="success_charge_info" class="alert alert-block alert-success"><center></center></div>
453                                <center><button id="package_register_finish_button" data-dismiss="modal" class="btn btn-primary" >Đóng</button></center>
454                        </div>
455               
456                </div>
457        </div>
458</div>
459
460<div class="modal fade" id="not_success_charge" tabindex="-1" role="dialog"aria-hidden="true">
461        <div class="modal-dialog">
462                <div class="modal-content">
463                        <div class="modal-header">
464                                <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
465                                <h4 class="modal-title">Nạp tiền</h4>
466                        </div>
467                        <div class="modal-body">
468                                <div id="no_success_charge_info" class="alert alert-block alert-success"><center></center></div>
469                                <center><button id="package_register_finish_button" data-dismiss="modal" class="btn btn-primary" >Đóng</button></center>
470                        </div>
471               
472                </div>
473        </div>
474</div>
475
476<div class="modal fade" id="regis-history" tabindex="-1" role="dialog"aria-hidden="true">
477    <div class="modal-dialog">
478        <div class="modal-content">
479            <div class="modal-header">
480                <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
481                <h4 class="modal-title">Lịch sá»­ đăng kÜ dịch vụ</h4>
482            </div>
483            <div class="modal-body">
484                <div class="table-responsive">
485                    <table id="sample-table-1" class="table table-striped table-bordered table-hover">
486                        <thead>
487                            <tr>
488                                <th class="center">
489                                                                        Từ
490                                </th>
491                                                                <th class="center">
492                                                                        Số tiền (VNĐ)
493                                </th>
494                                <th class="center"> Dịch vụ </th>
495                                <th>
496                                    <i class="icon-time bigger-110 hidden-480"></i>
497                                    Thời gian
498                                </th>
499                            </tr>
500                        </thead>
501                        <tbody id="content-regis-histoty">
502                        </tbody>
503                    </table>
504                                        <div>
505                                                <div class="dataTables_paginate paging_bootstrap">
506                                                        <ul class="pagination">
507                                                        </ul>
508                                                </div>
509                                        </div>
510                </div><!-- /.table-responsive -->
511            </div>
512        </div>
513    </div>
514</div>
515
516<script type="text/javascript">
517        var url="<?php echo base_url();?>";
518        var current_tab="<?php echo $current_tab;?>";
519        //var current_balanced = <?php echo $acc_balanced; ?>;
520</script>
521<?php
522$this->load->view('layout/frontend/footer', array('base_url' => $base_url, 'usjs' => array('assets/js/frontend/user.js')));
523?>
Note: See TracBrowser for help on using the repository browser.