<?php include ADMIN_COMMON_PATH.'/header.html';?>
<div class="layui-container fly-marginTop fly-user-main">
    <?php include ADMIN_COMMON_PATH.'/products-nav.html';?>
    <div class="fly-panel fly-panel-user" pad20>
        <div class="layui-tab layui-tab-brief" lay-filter="email">
            <ul class="layui-tab-title" id="LAY_mine">
                <li class="" lay-id="info"><a href="/<?php echo ADMIN_DIR;?>/productstype">产品类型</a></li>
                <li class="layui-this" lay-id="info">编辑</li>
            </ul>
            <div class="layui-tab-content" style="padding: 20px 0;">
                <div class="layui-form-pane layui-tab-item layui-show">
                    <form class="layui-form layui-show" method="post">
                        <div class="layui-form-item">
                            <label for="name" class="layui-form-label">分类地址</label>
                            <div class="layui-input-block">
                                <input type="text" disabled readonly="readonly" value="<?php echo $config['weburl'].'/group/'.$item['id'].".html";?>" class="layui-input">
                            </div>
                        </div>
                        <div class="layui-form-item">
                            <label for="name" class="layui-form-label">分类名称</label>
                            <div class="layui-input-inline">
                                <input type="text" id="name" name="name" lay-verify="required" autocomplete="off" value="<?php echo $item['name'];?>" class="layui-input">
                            </div>
                        </div>
                        <div class="layui-form-item layui-form-text">
                            <label for="description" class="layui-form-label">分类描述(请简单点)</label>
                            <div class="layui-input-block">
                                <input type="text" id="description" name="description" lay-verify="required" autocomplete="off" value="<?php echo $item['description'];?>" class="layui-input">
                            </div>
                        </div>
                        <div class="layui-form-item">
                            <label for="password" class="layui-form-label">分类密码</label>
                            <div class="layui-input-inline">
                                <input type="text" id="password" name="password" autocomplete="off" value="<?php echo $item['password'];?>" class="layui-input">
                            </div>
                        </div>
                        <div class="layui-form-item">
                            <label for="sort_num" class="layui-form-label">排序</label>
                            <div class="layui-input-inline">
                                <input type="number" id="sort_num" name="sort_num" lay-verify="required" autocomplete="off" value="<?php echo $item['sort_num'];?>" class="layui-input">
                            </div>
							<div class="layui-form-mid layui-word-aux">数字越大，越靠前</div>
                        </div>
                        <div class="layui-form-item">
                            <label class="layui-form-label">是否激活</label>
                            <div class="layui-input-block">
                                <input type="radio" name="active" value="1" title="激活" <?php if($item['active']=='1' ):?>checked=""<?php endif;?>>
                                <input type="radio" name="active" value="0" title="取消" <?php if($item['active']=='0' ):?>checked=""<?php endif;?>>
                            </div>
                        </div>
                        <div class="layui-form-item">
                            <input type="hidden" name="id" value="<?php echo $item['id'];?>">
                            <input type="hidden" name="method" value="edit">
                            <button class="layui-btn" key="set-mine" lay-filter="edit" lay-submit>确认修改</button>
                        </div>
                    </form>
                </div>
            </div>
        </div>
    </div>
</div>
<!--引入公共底文件-->
<?php include ADMIN_COMMON_PATH.'/footer.html';?>
<script>
layui.use('adminproductstype');
</script>