123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192 |
- <{include file="./admin/header.html"}>
- <{include file="./admin/left.html"}>
- <{include file="./admin/nav.html"}>
- <{include file="get_kindeditor.html"}>
- <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;
- }
- .ke-container {
- width:640px!important
- }
- </style>
- <div id="activity_container">
- <form id="activity_form">
- <div class="activity_center">
- <{include file="./admin/activity/common_nav.html"}>
- <input name="events_id" type="hidden" value="<{$events_Data.events.id}>">
-
- <div class="panel panel-default">
- <div class="panel-body">
- <div class="form-group">
- <label class="control-label rowlabel">显示顶部数据栏目:</label>
- <{foreach from=$eventsTopData item=info key=key}>
- <label class="radio-inline">
- <input name="top_data" type="radio" value="<{$key}>" <{if $eventData.top_data == $key}>checked<{elseif !$eventData.top_data && $key == 1}>checked<{/if}>> <{$info.desc}>
- </label>
- <{/foreach}>
- </div>
- <div class="form-group">
- <label class="control-label rowlabel">显示分栏标签:</label>
- <input name="is_column_tag_1" type="checkbox" value="1" <{if $eventData.is_column_tag_1 == 1}>checked<{/if}>>
- <input name="column_tag_1" class="form-control" style="display:inline;width:150px;" type="text" value="<{if $eventData.column_tag_1}><{$eventData.column_tag_1}><{else}> 活动介绍<{/if}>"/>
- <input name="is_column_tag_2" type="checkbox" value="1" <{if $eventData.is_column_tag_2 == 1}>checked<{/if}>>
- <input name="column_tag_2" class="form-control" style="display:inline;width:150px;" type="text" value="<{if $eventData.column_tag_2}><{$eventData.column_tag_2}><{else}> 中奖信息<{/if}>"/>
- <input name="is_column_tag_3" type="checkbox" value="1" <{if $eventData.is_column_tag_3 == 1}>checked<{/if}>>
- <input name="column_tag_3" class="form-control" style="display:inline;width:150px;" type="text" value="<{if $eventData.column_tag_3}><{$eventData.column_tag_3}><{else}> 试用评价<{/if}>"/>
- </div>
- <div class="form-group">
- <label class="control-label rowlabel">正文内容:</label>
- <textarea name="events_tips" class="form-control" rows="15" style="width:;"><{$eventData.events_tips}></textarea>
- </div>
-
- <div class="form-group">
- <label class="control-label rowlabel">是否显示分享按钮:</label>
- <{foreach from=$eventsShareButton item=info key=key}>
- <label class="radio-inline">
- <input name="share_button" type="radio" value="<{$key}>" <{if $eventData.share_button == $key}>checked<{elseif !$eventData.share_button && $key == 1}>checked<{/if}>> <{$info.desc}>
- </label>
- <{/foreach}>
- <input name="share_button_tips" class="form-control" style="display:inline;width:300px;" type="text" value="<{if $eventData.share_button_tips}><{$eventData.share_button_tips}><{else}>分享优惠给好友<{/if}>"/>
- </div>
- <div class="form-group">
- <label class="control-label rowlabel">是否显示导购按钮:</label>
- <{foreach from=$eventsBuyButton item=info key=key}>
- <label class="radio-inline">
- <input name="buy_button" type="radio" value="<{$key}>" <{if $eventData.buy_button == $key}>checked<{elseif !$eventData.buy_button && $key == 1}>checked<{/if}>> <{$info.desc}>
- </label>
- <{/foreach}>
- <input name="buy_button_tips" class="form-control" style="display:inline;width:150px;" type="text" value="<{if $eventData.buy_button_tips}><{$eventData.buy_button_tips}><{else}>立即购买通道<{/if}>"/>
- <input name="buy_button_link" class="form-control" style="display:inline;width:150px;" type="text" value="<{if $eventData.buy_button_link}><{$eventData.buy_button_link}><{else}>微信链接<{/if}>"/>
- <input name="buy_button_app" class="form-control" style="display:inline;width:150px;" type="text" value="<{if $eventData.buy_button_app}><{$eventData.buy_button_app}><{else}>APP链接<{/if}>"/>
- </div>
- <div class="form-group">
- <label class="control-label rowlabel">互动提示语:</label>
- <input name="events_hd_tips" class="form-control" type="text" style="width:300px;" value="<{$eventData.events_hd_tips}>"/>
- </div>
- <div class="form-group">
- <label class="control-label rowlabel">活动规则提示语:</label>
- <input name="operationt_tips" class="form-control" type="text" style="width:300px;" value="<{$eventData.operationt_tips}>"/>
- </div>
- <div class="form-group">
- <label class="control-label rowlabel">活动规则:</label>
- <textarea name="events_rules" class="form-control" rows="15" style="width:;"><{$eventData.events_rules}></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>
- <{include file="./admin/activity/common_right.html"}>
- <div style="clear:both;"></div>
- </form>
- </div>
- <script>
- var tips_editor,rules_editor;
- KISSY.use('node, io, uri', function (S, Node, IO, Uri) {
- var $ = S.all;
- var Query = Uri.Query;
-
- 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 events_tips = tips_editor.html();
- var events_rules = rules_editor.html();
-
- formData = IO.serialize("#activity_form");
- formData = new Query(formData).set('events_tips', events_tips).toString();
- formData = new Query(formData).set('events_rules', events_rules).toString();
-
- new IO({
- type: "post"
- , url: VG.conf.root_domain + '/?c=Admin_Activity_SetPage&a=ReqUpRoutine'
- , data: formData
- , success: function (data) {
- if (data.ok) { //ok
- location.href = location.href;
- } else {
- alert('操作失败,原因:'+data.msg);
- location.href = location.href;
- }
- return false;
- }
- , error: function (NULL, textStatus) {
- alert("请求服务器失败,原因:"+textStatus);
- }
- , dataType: "json"
- });
- });
- });
- var KCONFIG = {
- allowFileManager : true,
- uploadJson : VG.conf.root_domain + '/?c=kindeditor&a=updateJson',
- fileManagerJson : VG.conf.root_domain + '/?c=kindeditor&a=fileManagerJson',
- items : [
- 'fontname', 'fontsize', '|', 'forecolor', 'hilitecolor', 'bold', 'italic', 'underline',
- 'removeformat', '|', 'justifyleft', 'justifycenter', 'justifyright', 'insertorderedlist',
- 'insertunorderedlist', '|', 'emoticons', 'image', 'link', 'lineheight', 'flash']
- }
- KindEditor.ready(function(K) {
- tips_editor = K.create('textarea[name=events_tips]', KCONFIG);
- });
- KindEditor.ready(function(K) {
- rules_editor = K.create('textarea[name=events_rules]', KCONFIG);
- });
- </script>
- <{include file="./admin/bottom.html"}>
|