<?php /* Smarty version 2.6.17, created on 2018-04-19 17:52:30 compiled from admin/activity/setPage_h5.html */ ?> <?php $_smarty_tpl_vars = $this->_tpl_vars; $this->_smarty_include(array('smarty_include_tpl_file' => "./admin/header.html", 'smarty_include_vars' => array())); $this->_tpl_vars = $_smarty_tpl_vars; unset($_smarty_tpl_vars); ?> <?php $_smarty_tpl_vars = $this->_tpl_vars; $this->_smarty_include(array('smarty_include_tpl_file' => "./admin/left.html", 'smarty_include_vars' => array())); $this->_tpl_vars = $_smarty_tpl_vars; unset($_smarty_tpl_vars); ?> <?php $_smarty_tpl_vars = $this->_tpl_vars; $this->_smarty_include(array('smarty_include_tpl_file' => "./admin/nav.html", 'smarty_include_vars' => array())); $this->_tpl_vars = $_smarty_tpl_vars; unset($_smarty_tpl_vars); ?> <?php $_smarty_tpl_vars = $this->_tpl_vars; $this->_smarty_include(array('smarty_include_tpl_file' => "get_kindeditor.html", 'smarty_include_vars' => array())); $this->_tpl_vars = $_smarty_tpl_vars; unset($_smarty_tpl_vars); ?> <style> .set-nav { margin: 0 auto; } .set-nav-hr { background-color: #ddd; height: 1px; position: relative; } .form-group label { font-weight: 600; } .checkbox-inline, .radio-inline { font-weight: 400!important; } .rowlabel { font-weight: 300!important; } .music_play_hide { display:none; } </style> <div id="activity_container"> <form id="activity_form"> <div class="activity_center"> <?php $_smarty_tpl_vars = $this->_tpl_vars; $this->_smarty_include(array('smarty_include_tpl_file' => "./admin/activity/common_nav.html", 'smarty_include_vars' => array())); $this->_tpl_vars = $_smarty_tpl_vars; unset($_smarty_tpl_vars); ?> <input name="events_id" type="hidden" value="<?php echo $this->_tpl_vars['events_Data']['events']['id']; ?> "> <div class="panel panel-default"> <div class="panel-body"> <div class="form-group"> <label class="control-label rowlabel">文章标题:</label> <input name="article_title" class="form-control" type="text" style="width:300px;" value="<?php echo $this->_tpl_vars['eventData']['article_title']; ?> "/> </div> <div class="form-group"> <label class="control-label rowlabel">作者:</label> <input name="article_author" class="form-control" type="text" style="width:300px;" value="<?php echo $this->_tpl_vars['eventData']['article_author']; ?> "/> </div> <div class="row"> <div class="form-group col-md-2"> <label class="control-label rowlabel">浏览量基数:</label> <input name="article_pass_base_num" class="form-control" type="text" value="<?php echo $this->_tpl_vars['eventData']['article_pass_base_num']; ?> "/> </div> <div class="form-group col-md-2"> <label class="control-label rowlabel">赞基数:</label> <input name="article_praise" class="form-control" type="text" value="<?php echo $this->_tpl_vars['eventData']['article_praise']; ?> "/> </div> </div> <div class="form-group"> <label class="control-label rowlabel">原文链接:</label> <input name="article_original_url" class="form-control" type="text" style="width:300px;" value="<?php echo $this->_tpl_vars['eventData']['article_original_url']; ?> "/> </div> <div class="form-group"> <label class="control-label rowlabel">正文内容:</label> <textarea name="article_text" style="width:100%;height:200px;"><?php echo $this->_tpl_vars['eventData']['article_text']; ?> </textarea> </div> <a id="activity_submit" href="javascript:;" class="button button-3d button-primary button-rounded"><i class="fa fa-refresh fa-spin" style="display:none;"></i> 保存设置</a> </div> </div> </div> <?php $_smarty_tpl_vars = $this->_tpl_vars; $this->_smarty_include(array('smarty_include_tpl_file' => "./admin/activity/common_right.html", 'smarty_include_vars' => array())); $this->_tpl_vars = $_smarty_tpl_vars; unset($_smarty_tpl_vars); ?> <div style="clear:both;"></div> </form> </div> <script> var editor; KISSY.use('node, io, event, jquery', function (S, Node, IO, Event, jQuery) { var $ = S.all; var activity_submit_status = false; //按钮状态 function submit_button_active() { activity_submit_status = true; $("#activity_submit").addClass('active').all('i').show(); } function submit_button_default() { activity_submit_status = false; $("#activity_submit").removeClass('active').all('i').hide(); } $("#activity_submit").on('click', function () { if (activity_submit_status) { return false; } submit_button_active(); var article_text = editor.html(); $("textarea[name=article_text]").val(article_text); formData = IO.serialize("#activity_form"); new IO({ type: "post" , url: VG.conf.root_domain + '/?c=Admin_Activity_SetPage&a=ReqUpArticle' , data: formData , success: function (data) { if (data.ok) { //ok location.href = location.href; } else { alert('操作失败,原因:'+data.msg); } return false; } , error: function (NULL, textStatus) { alert("请求服务器失败,原因:"+textStatus); } , dataType: "json" }); }); }); KindEditor.ready(function(K) { editor = K.create('textarea[name=article_text]', { allowFileManager : true, uploadJson : VG.conf.root_domain + '/?c=kindeditor&a=updateJson', fileManagerJson : VG.conf.root_domain + '/?c=kindeditor&a=fileManagerJson' }); }); </script> <?php $_smarty_tpl_vars = $this->_tpl_vars; $this->_smarty_include(array('smarty_include_tpl_file' => "./admin/bottom.html", 'smarty_include_vars' => array())); $this->_tpl_vars = $_smarty_tpl_vars; unset($_smarty_tpl_vars); ?>