| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116 |
- <!DOCTYPE HTML>
- <html xmlns:th="http://www.thymeleaf.org"
- xmlns:layout="http://www.ultraq.net.nz/thymeleaf/layout"
- layout:decorate="~{admin/common/common}">
- <head>
- <title>编辑导航</title>
- </head>
- <body layout:fragment="content">
- <article class="page-container">
- <form class="form form-horizontal" id="form-slides-edit">
- <input type="hidden" th:name="id" th:id="id" th:value="${navigation?.id}"/>
- <div class="row cl">
- <label class="form-label col-xs-4 col-sm-2"><span class="c-red">*</span>导航名称:</label>
- <div class="formControls col-xs-4 col-sm-4 title_input">
- <input type="text" class="input-text" th:value="${navigation?.name}" required th:id="name" th:name="name" disabled="disabled"/>
- </div>
- </div>
- <div class="row cl" th:if="${navigation.id==2}">
- <label class="form-label col-xs-4 col-sm-2"><span class="c-red">*</span>网站图标:</label>
- <div class="formControls col-xs-8 col-sm-9 ">
- <div class="uploader-thum-container">
- <div id="fileList" class="uploader-list"></div>
- <div id="filePicker" class="margin-right-10">重新选择图片</div>
- <div id="fileListPre"><img id="preImg" th:src="${fileUrl} +${navigation.fileDown.file_url}"/></div>
- </div>
- </div>
- </div>
- <div class="row cl">
- <label class="form-label col-xs-4 col-sm-2"><span class="c-red">*</span>显示顺序:</label>
- <div class="formControls col-xs-8 col-sm-9">
- <input type="number" min="1" class="input-text" th:value="${navigation?.sort}" th:id="sort" th:name="sort"/>
- </div>
- </div>
- <div class="row cl">
- <label class="form-label col-xs-4 col-sm-2"><span>状态:</span></label>
- <div class="formControls col-xs-8 col-sm-9">
- <input type="radio" th:checked="${navigation.is_start==true}" name="is_start" value="true">启用</input>
- <input type="radio" th:checked="${navigation.is_start==false}" name="is_start" value="false">禁用</input>
- </div>
- </div>
- <div class="row cl" th:if="${navigation.id==2}">
- <label class="form-label col-xs-4 col-sm-2"><span class="c-red">*</span>简介:</label>
- <div class="formControls col-xs-8 col-sm-9">
- <textarea id="content" name="content" th:name="content">[[${navigation.content}]]</textarea>
- </div>
- </div>
- <div class="row cl">
- <div class="col-xs-8 col-sm-9 col-xs-offset-4 col-sm-offset-2">
- <button class="btn btn-primary radius" type="submit"><i class="Hui-iconfont"></i>保存</button>
- <!--<button onClick="article_save();" class="btn btn-secondary radius" type="button"><i-->
- <!--class="Hui-iconfont"></i> 保存草稿-->
- <!--</button>-->
- <button onClick="removeIframe();" class="btn btn-default radius" type="button"> 取消 </button>
- </div>
- </div>
- </form>
- </article>
- <script type="text/javascript" th:src="@{/js/government/gps/gps_edit.js}"></script>
- <script th:inline="javascript">
- //富文本kindeditor初始化
- var editor;
- KindEditor.ready(function (K) {
- editor = K.create('#content', {
- uploadJson: pagePath+'/upload/kindEditorUpload',
- allowFileManager: false,
- allowUpload: true,
- width: "100%",
- height: "350px",
- items:array,
- syncType:"auto",
- afterBlur: function () {
- this.sync();
- }
- });
- });
- $(function () {
- // 初始化图片上传
- var options = {
- auto: false,
- uploadBtnId: '#filePicker',
- picturePreId: 'fileListPre',
- hiddenPictureUrl: 'fileDown.file_id',
- hiddenPictureName: 'imgName',
- accept: {
- title: 'Images',
- extensions: 'gif,jpg,jpeg,bmp,png',
- mimeTypes: 'image/gif,image/jpg,image/jpeg,image/bmp,image/png'
- },
- fileSizeLimit: 100 * 1024 * 1024,
- fileSingleSizeLimit: 100 * 1024 * 1024
- // fileNumLimit: 1
- };
- var webUploadPicture = new $WebUploadPicture(options);
- webUploadPicture.init();
- });
- /**
- * 取消
- */
- function removeIframe() {
- var index = parent.layer.getFrameIndex(window.name);
- parent.layer.close(index);
- }
- </script>
- </body>
- </html>
|