You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
90 lines
4.9 KiB
HTML
90 lines
4.9 KiB
HTML
5 years ago
|
<extend name="Public/base" />
|
||
|
<!-- 管理员用户组新增和编辑页面 -->
|
||
|
<block name="body">
|
||
|
<form action="{:U('Article/pop_rule_edit')}" enctype="application/x-www-form-urlencoded" method="POST"
|
||
|
class="form-horizontal form_info_ml">
|
||
|
<div class="formtitle"><span>编辑平台规则</span></div>
|
||
|
<ul class="form_info ">
|
||
|
<input type="hidden" name="id" value="{$rule.id}" />
|
||
|
<li>
|
||
|
<label>标题</label>
|
||
|
<input name="title" type="text" class="" placeholder="标题" value="{$rule.title}" />
|
||
|
</li>
|
||
|
<li>
|
||
|
<label>描述</label>
|
||
|
<textarea name="desc" class="" placeholder="描述" >{$rule.desc}</textarea>
|
||
|
</li>
|
||
|
<li>
|
||
|
<label>权重</label>
|
||
|
<input name="sort" type="text" class="txt" placeholder="权重" value="{$rule.sort}" />
|
||
|
</li>
|
||
|
<li>
|
||
|
<label>类型</label>
|
||
|
<select id="type" name="type" class="select_gallery" onchange="checkPopTime();">
|
||
|
<option value="0" <?php if ($rule['type'] == 0):?>selected<?php endif;?>>不弹窗</option>
|
||
|
<option value="1" <?php if ($rule['type'] == 1):?>selected<?php endif;?>>单次弹窗</option>
|
||
|
<option value="2" <?php if ($rule['type'] == 2):?>selected<?php endif;?>>循环弹窗</option>
|
||
|
</select>
|
||
|
</li>
|
||
|
<li id="li-pop-time"></li>
|
||
|
<li>
|
||
|
<label>内容</label>
|
||
|
<span class="form_textarea">
|
||
|
<textarea name="content">{$rule.content}</textarea>
|
||
|
{:hook('adminArticleEdit', array('name'=>'content','value'=>$rule['content']))}
|
||
|
</span>
|
||
|
</li>
|
||
|
<li>
|
||
|
<label> </label><input type="submit" id="submit" value="确认保存" target-form="form-horizontal" class="form_btn ajax-post">
|
||
|
</li>
|
||
|
</ul>
|
||
|
</form>
|
||
|
|
||
|
<div class="common_settings">
|
||
|
<span class="plus_icon"><span><img src="__IMG__/zwmimages/icon_jia.png"></span></span>
|
||
|
<form class="addShortcutIcon">
|
||
|
<input type="hidden" name="title" value="{$m_title}">
|
||
|
<input type="hidden" name="url" value="AuthManager/index">
|
||
|
</form>
|
||
|
<a class="ajax-post add-butn <notempty name='commonset'>addSIsetted</notempty>" href="javascript:;" target-form="addShortcutIcon" url="{:U('Think/addShortcutIcon')}"><img src="__IMG__/zwmimages/icon_jia.png"><span><notempty name='commonset'>已添加<else />添加至常用设置</notempty></span></a>
|
||
|
</div>
|
||
|
|
||
|
</block>
|
||
|
<block name="script">
|
||
|
<link href="__STATIC__/datetimepicker/css/datetimepicker.css" rel="stylesheet" type="text/css">
|
||
|
<php>if(C('COLOR_STYLE')=='blue_color') echo '
|
||
|
<link href="__STATIC__/datetimepicker/css/datetimepicker_blue.css" rel="stylesheet" type="text/css">
|
||
|
';
|
||
|
</php>
|
||
|
<link href="__STATIC__/datetimepicker/css/dropdown.css" rel="stylesheet" type="text/css">
|
||
|
<script type="text/javascript" src="__STATIC__/datetimepicker/js/bootstrap-datetimepicker.min.js"></script>
|
||
|
<script type="text/javascript" src="__STATIC__/datetimepicker/js/locales/bootstrap-datetimepicker.zh-CN.js"
|
||
|
charset="UTF-8"></script>
|
||
|
<script src="__STATIC__/layer/layer.js" type="text/javascript"></script>
|
||
|
<script type="text/javascript">
|
||
|
</script>
|
||
|
<script type="text/javascript">
|
||
|
highlight_subnav('{:U('Article/pop_rule_edit')}');
|
||
|
function checkPopTime()
|
||
|
{
|
||
|
$("#li-pop-time").html("");
|
||
|
var type_val = $("#type").val();
|
||
|
if (type_val == 0) {
|
||
|
//$('#li-pop-time').hide();
|
||
|
|
||
|
} else if (type_val == 1) {
|
||
|
$("#li-pop-time").html('<label>弹窗时间</label><input type="text" id="pop_time" name="pop_time" class="" value="{$rule.pop_time}" placeholder="弹窗时间" />');
|
||
|
$('#pop_time').datetimepicker({
|
||
|
format: 'yyyy-mm-dd',
|
||
|
language:"zh-CN",
|
||
|
minView:2,
|
||
|
autoclose:true
|
||
|
});
|
||
|
} else if (type_val == 2) {
|
||
|
//$('#li-pop-time').show();
|
||
|
$("#li-pop-time").html('<label>弹窗时间</label><select id="pop_time" name="pop_time" class="select_gallery"><option value="1" <?php if ($rule["pop_time"] == 1):?>selected<?php endif;?>>周一</option><option value="2" <?php if ($rule["pop_time"] == 2):?>selected<?php endif;?> >周二</option><option value="3" <?php if ($rule["pop_time"] == 3):?>selected<?php endif;?> >周三</option><option value="4" <?php if ($rule["pop_time"] == 4):?>selected<?php endif;?> >周四</option><option value="5" <?php if ($rule["pop_time"] == 5):?>selected<?php endif;?> >周五</option><option value="6" <?php if ($rule["pop_time"] == 6):?>selected<?php endif;?> >周六</option><option value="7" <?php if ($rule["pop_time"] == 7):?>selected<?php endif;?> >周日</option></select>');
|
||
|
}
|
||
|
}
|
||
|
checkPopTime();
|
||
|
</script>
|
||
|
</block>
|