<?php /* Smarty version Smarty-3.1.8, created on 2015-11-24 16:55:45
         compiled from "D:\wwwroot\o2o\htdocs\themes\default\xiche\mcenter\pwd\forgot.html" */ ?>
<?php /*%%SmartyHeaderCode:27129565426110981b9-17886138%%*/if(!defined('SMARTY_DIR')) exit('no direct access allowed');
$_valid = $_smarty_tpl->decodeProperties(array (
  'file_dependency' => 
  array (
    '17b27c9e582173108cec0a65e8ebada40f15f13d' => 
    array (
      0 => 'D:\\wwwroot\\o2o\\htdocs\\themes\\default\\xiche\\mcenter\\pwd\\forgot.html',
      1 => 1447986608,
      2 => 'file',
    ),
  ),
  'nocache_hash' => '27129565426110981b9-17886138',
  'function' => 
  array (
  ),
  'has_nocache_code' => false,
  'version' => 'Smarty-3.1.8',
  'unifunc' => 'content_565426110cecc0_30458385',
),false); /*/%%SmartyHeaderCode%%*/?>
<?php if ($_valid && !is_callable('content_565426110cecc0_30458385')) {function content_565426110cecc0_30458385($_smarty_tpl) {?><?php if (!is_callable('smarty_function_link')) include 'D:\\wwwroot\\o2o\\htdocs\\system\\plugins/smarty\\function.link.php';
?><?php $_smarty_tpl->tpl_vars['tpl_title'] = new Smarty_variable('生活宝易车洗', null, 0);?>
<!DOCTYPE HTML>
<html>
<head>
<?php echo $_smarty_tpl->getSubTemplate ("xiche/mcenter/block/mheader.html", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, null, null, array(), 0);?>

</head>

<body>
<header>
	<i class="left"><a id="icon_goback" href="<?php echo smarty_function_link(array('ctl'=>'xiche/mcenter/main'),$_smarty_tpl);?>
"></a></i>
    <div class="title">修改登录密码</div>
    <i class="right"></i>
</header>
<section id="" class="page_center_box">
    <ul class="form_list_box mt10">
        <li class="pd">
        	<table width="100%">
            	<tr>
                	<th><em class="ico_3"></em></th>
                    <td>
                        <input type="text" id="password" name="password" placeholder="请输入原密码">
                    </td>
                </tr>
            </table>
        </li>
        <li class="pd">
        	<table>
            	<tr>
                	<th><em class="ico_3"></em></th>
                    <td>
                    	<input type="password" id="password_new" name="password_new" placeholder="请输入新密码">
                    </td>
                </tr>
            </table>
        </li>
        <li class="last pd">
        	<table>
            	<tr>
                	<th><em class="ico_3"></em></th>
                    <td>
                        <input type="password" id="password_re" name="password_re" placeholder="再次输入新密码">
                    </td>
                </tr>
            </table>
        </li>
    </ul>
    <div class="long_btn_box"><input class="long_btn" type="button" id="pwd_btn" value="确认修改"></div>
</section>

 <script type="text/javascript">
    require(["zepto", "underscore", "frozen"], function ($, _, fz) {
        $("#pwd_btn").click(function () {
            var password = $('#password').val();
            var password_new = $("#password_new").val();
            var password_re = $("#password_re").val();
            if(!password || !password_new || !password_re){
                $.tips({content:'内容没有输入完整',stayTime:2000});
                return false;
            }else if(password_new != password_re){
                $.tips({content:'两次密码输入不一致',stayTime:2000});
                return false;
            }else{     
                 var link = "<?php echo smarty_function_link(array('ctl'=>'xiche/mcenter/pwd/setpwd'),$_smarty_tpl);?>
";
                $.post(link,{password:password,password_new:password_new},function(ret){
                    if(ret.error){
                       $.tips({content: ret.message,stayTime:2000});
                    }else{
                        $.tips({content: ret.message,stayTime:2000});
                        setTimeout(function(){
                             window.location.href="<?php echo smarty_function_link(array('ctl'=>'xiche/mcenter'),$_smarty_tpl);?>
";
                        },2000)
                    }
                },'json');              
            }     
        });
    });
</script>

</body>
</html>
<?php }} ?>