{layout name="manager/layout" /}
<div class="layuimini-container location-operate-page">
    <div class="layuimini-main">
        <div class="layui-form layuimini-form">
            <div class="layui-form-item">
                <label class="layui-form-label required">名称</label>
                <div class="layui-input-block">
                    <input type="text" name="name" placeholder="请输入名称" class="layui-input" value="{$item.name ?? ''}" maxlength="250">
                </div>
            </div>

            <div class="layui-form-item layui-row">
                <label class="layui-form-label required">封面图</label>
                <div class="layui-inline layui-col-xs12 layui-col-md8">
                    <div class="layui-row upload-file-div">
                        <div class=" layui-col-xs12 layui-col-md8">
                            <input class="layui-input upload-file-value" name="cover" type="text" value="{$item.cover ?? ''}">
                            <div class="layui-form-mid layui-word-aux">图片尺寸：xxx*xxx</div>
                        </div>
                        <div class="layui-col-xs12 layui-col-md3">
                            <span>
                                <button type="button" class="layui-btn layui-btn-danger upload-btn">
                                    <i class="fa fa-upload"></i> 上传
                                </button>
                            </span>
                            <span>
                                <button type="button" class="layui-btn layui-btn-primary upload-choose-btn" data-type="image" data-multiple="false">
                                    <i class="fa fa-list"></i> 选择
                                </button>
                            </span>
                        </div>
                        <ul class="layui-row layui-col-xs12 layui-col-md9 preview-list layui-col-space5"></ul>
                    </div>
                </div>
            </div>

            <div class="layui-form-item">
                <label class="layui-form-label required">内容</label>
                <div class="layui-input-block">
                    <textarea name="content" class="layui-textarea tinymce-editor">{$item.content ?? ''}</textarea>
                </div>
            </div>

            <div class="layui-form-item">
                <div class="layui-input-block">
                    <input type="hidden" name="id" value="{$item.id ?? 0}">
                    <button class="layui-btn layui-btn-normal" data-url="{%path%}/edit" lay-submit lay-filter="saveBtn">确认保存</button>
                </div>
            </div>
        </div>
    </div>
</div>

<script src="__MANAGER__/{%jsPath%}?v={:mt_rand()}"></script>