<%@ Page Title="" Language="C#" MasterPageFile="~/Admin/MasterPage.master" AutoEventWireup="true" Inherits="Kesion.NET.WebSite.Admin.Exam.KS_ScoreConfig" Codebehind="KS.ScoreConfig.aspx.cs" %>

<%@ Import Namespace="Kesion.APPCode" %>
<%@ Import Namespace="Kesion.Publics" %>
<%@ Import Namespace="Kesion.Cache" %>
<%@ Import Namespace="Kesion.BLL" %>
<asp:Content ID="Content1" ContentPlaceHolderID="KSContent" runat="server">

    <div id="manage_top" class="menu_top_fixed">
        <ul class="titleTab">
            <li><a href="KS.Config.aspx">网站参数设置</a></li>
            <li><a href="KS.Safe.aspx">网站安全配置</a></li>
            <li><a href="KS.OrderConfig.aspx">订单相关设置</a></li>
             <%if (BaseFun.CheckModulePower("mall"))
                 { %>
            <li><a href="KS.ShopDelivery.aspx">配送管理</a></li>
            <%} %>
            <li class="curr"><a href="KS.ScoreConfig.aspx">网站积分配置</a></li>
            <li><a href="KS.ContactUS.aspx">联系方式配置</a></li>
             <li><a href="KS.Dirtywords.aspx">过滤脏话配置</a></li>
        </ul>
    </div>
    <div class="menu_top_fixed_height"></div>


    <div class="content-area">
        <div class="tab-page" id="SystemAskPanel">
            <script type="text/javascript">
                var tabPane1 = new WebFXTabPane(document.getElementById("SystemAskPanel"), 1)
            </script>

            <div class="tab-page" id="tab0">
                <h2 class="tab">基本参数</h2>
                <script type="text/javascript">
                    tabPane1.addTabPage(document.getElementById("tab0"));
                </script>
                <table id="tbs" width="100%" border="0" cellpadding="0" cellspacing="0" class="CTable no-borderTable">
                    <tr>
                        <td align="right" class="lefttd" height="30" style="width: 198px">
                            <strong>新用户注册赠送积分：</strong>
                        </td>
                        <td class="righttd">
                            <asp:TextBox CssClass="textbox" ID="UserRegAddScore" runat="server" Width="50" Style="width: 60px; text-align: center"></asp:TextBox>分</td>
                    </tr>
                    <tr>
                        <td align="right" class="lefttd" height="30" style="width: 198px">
                            <strong>推荐用户注册给推荐人：</strong>
                        </td>
                        <td class="righttd">
                            <asp:TextBox CssClass="textbox" ID="TxtTJScore" runat="server" Width="50" Style="width: 60px; text-align: center"></asp:TextBox>分</td>
                    </tr>
                      <%if (BaseFun.CheckModulePower("edu"))
                        {%>
                    <tr>
                        <td align="right" class="lefttd" height="30" style="width: 198px">
                            <strong>每日登录增加积分：</strong></td>
                        <td class="righttd">
                            <asp:TextBox ID="DailySetpoint" CssClass="textbox" runat="server" Style="width: 60px; text-align: center"></asp:TextBox>分
                        </td>
                    </tr>
                    <tr>
                        <td align="right" class="lefttd" height="30" style="width: 198px">
                            <strong>每日登录增加积分上限：</strong></td>
                        <td class="righttd">
                            <asp:TextBox ID="limitedpoint" CssClass="textbox" runat="server" Style="width: 60px; text-align: center"></asp:TextBox>分
                        </td>
                    </tr>
                  
                    <tr>
                        <td align="right" class="lefttd" height="30" style="width: 198px">
                            <strong>每日学习课件： </strong></td>
                        <td>
                            <asp:TextBox ID="learncount" CssClass="textbox" runat="server" Style="width: 60px; text-align: center"></asp:TextBox>分钟增加
               				<asp:TextBox ID="learnpoint" CssClass="textbox" runat="server" Style="width: 60px; text-align: center"></asp:TextBox>积分
               				&nbsp;学习课件<asp:TextBox ID="minutes" CssClass="textbox" runat="server" Style="width: 60px; text-align: center"></asp:TextBox>秒钟刷新数据库
                        </td>
                    </tr>
                    <tr>
                        <td align="right" class="lefttd" height="30" style="width: 198px">
                            <strong>每日学习课件增加积分上限：</strong></td>
                        <td class="righttd">
                            <asp:TextBox ID="learnlimitedpoint" CssClass="textbox" runat="server" Style="width: 60px; text-align: center"></asp:TextBox>分
                        </td>
                    </tr>
                    <tr>
                        <td align="right" class="lefttd" height="30" style="width: 198px">
                            <strong>每次练习分数不少于：</strong></td>
                        <td>
                            <asp:TextBox ID="examscore" CssClass="textbox" runat="server" Style="width: 60px; text-align: center"></asp:TextBox>分,积
                 			<asp:TextBox ID="exampoint" CssClass="textbox" runat="server" Style="width: 60px; text-align: center"></asp:TextBox>积分
                 			&nbsp; &nbsp;每日上限<asp:TextBox ID="examlimitpoint" CssClass="textbox" runat="server" Style="width: 60px; text-align: center"></asp:TextBox>积分
                        </td>
                    </tr>
                    <tr>
                        <td align="right" class="lefttd" height="30" style="width: 198px">
                            <strong>竞赛考试：</strong></td>
                        <td>
                            <asp:TextBox ID="score" CssClass="textbox" runat="server" Style="width: 60px; text-align: center"></asp:TextBox>积分以上参加竞赛
                        </td>
                    </tr>
                    <%} %>
                </table>
                <KS:Foot runat="server" CancelButtonVisible="false" ID="Foot1" OnSubmit="Foot1_Submit" />
            </div>

            <div class="tab-page" id="tab3">
                <h2 class="tab"<%=CommonJsonCache.CheckYunAPPHasAllow("plus.ask")?"":" style='display:none'" %>>问答系统积分配置</h2>
                <script type="text/javascript">
                    tabPane1.addTabPage(document.getElementById("tab3"));
                </script>
                <table width="100%" border="0" cellpadding="0" cellspacing="0" class="CTable no-borderTable">
                    <tr>
                        <td class="lefttd" height="30" align="right" style="width: 198px"><b>用户回答一个问题所得的积分：</b>
                            <div style="color: green"></div>
                        </td>
                        <td class="righttd">
                            <asp:TextBox ID="TxtAskScore1" CssClass="textbox" runat="server" Width="50px" Style="text-align: center" />
                            分
                            <span class="tips">同一个问题回只赠送积分一次，如果设置答案需要审核，则需要管理员审核通过才赠送积分。</span>
                        </td>
                    </tr>
                    <tr>
                        <td class="lefttd" height="30" align="right" style="width: 198px"><b>回答被提问者采纳所额外奖励的积分：</b>
                            <div style="color: green"></div>
                        </td>
                        <td class="righttd">
                            <asp:TextBox ID="TxtAskScore2" CssClass="textbox" runat="server" Width="50px" Style="text-align: center" />
                            分
                        </td>
                    </tr>
                    <tr>
                        <td class="lefttd" height="30" align="right" style="width: 198px"><b>用户处理问题所得的积分：</b>
                            <div style="color: green"></div>
                        </td>
                        <td class="righttd">
                            <asp:TextBox ID="TxtAskScore3" CssClass="textbox" runat="server" Width="50px" Style="text-align: center" />
                            分
                        <span class="tips">指提问者设置最佳答案的操作。</span></td>
                    </tr>

                    <tr>
                        <td class="lefttd" height="30" align="right" style="width: 198px"><b>问题被选为精彩推荐提问者所得的积分：</b>
                            <div style="color: green"></div>
                        </td>
                        <td class="righttd">
                            <asp:TextBox ID="TxtAskScore4" CssClass="textbox" runat="server" Width="50px" Style="text-align: center" />
                            分
                        </td>
                    </tr>

                    <tr>
                        <td class="lefttd" height="30" align="right" style="width: 198px"><b>问题被选为精彩推荐最佳回答者所得的积分：</b>
                            <div style="color: green"></div>
                        </td>
                        <td class="righttd">
                            <asp:TextBox ID="TxtAskScore5" CssClass="textbox" runat="server" Width="50px" Style="text-align: center" />
                            分
                        </td>
                    </tr>

                    <tr>
                        <td class="lefttd" height="30" align="right" style="width: 198px"><b>用户发表一个问题所获的积分：</b>
                            <div style="color: green"></div>
                        </td>
                        <td class="righttd">
                            <asp:TextBox ID="TxtAskScore6" CssClass="textbox" runat="server" Width="50px" Style="text-align: center" />
                            分
                            <span class="tips">设置成负数则表示提问题要消费,当设置需要审核则只有后台审核通过才赠送积分。</span>
                        </td>
                    </tr>

                    <tr>
                        <td class="lefttd" height="30" align="right" style="width: 198px"><b>问题被删除减去提问者积分：</b>
                            <div style="color: green"></div>
                        </td>
                        <td class="righttd">
                            <asp:TextBox ID="TxtAskScore7" CssClass="textbox" runat="server" Width="50px" Style="text-align: center" />
                            分
                            <span class="tips">指问题被后台管理员删除，扣除积分。</span>
                        </td>
                    </tr>

                    <tr>
                        <td class="lefttd" height="30" align="right" style="width: 198px"><b>删除答案减去回答者积分：</b>
                            <div style="color: green"></div>
                        </td>
                        <td class="righttd">
                            <asp:TextBox ID="TxtAskScore8" CssClass="textbox" runat="server" Width="50px" Style="text-align: center" />
                            分
                            <span class="tips">指回答的答案被提问者或是回答者自己删除时，扣除积分。</span>
                        </td>
                    </tr>
                    <tr>
                        <td class="lefttd" height="30" align="right" style="width: 198px"><b>删除最佳答案减去回答者积分：</b>
                            <div style="color: green"></div>
                        </td>
                        <td class="righttd">
                            <asp:TextBox ID="TxtAskScore9" CssClass="textbox" runat="server" Width="50px" Style="text-align: center" />
                            分
                            <span class="tips">仅后台管理员删除才有权限删除最佳答案</span>
                        </td>
                    </tr>
                    <tr>
                        <td class="lefttd" height="30" align="right" style="width: 198px"><b>删除未解决问题减去积分：</b>
                            <div style="color: green"></div>
                        </td>
                        <td class="righttd">
                            <asp:TextBox ID="TxtAskScore10" CssClass="textbox" runat="server" Width="50px" Style="text-align: center" />
                            分
                            <span class="tips">指会员在会员中心删除自己的问题，扣除积分。</span>
                        </td>
                    </tr>
                    <tr>
                        <td class="lefttd" height="30" align="right" style="width: 198px"><b>删除已解决问题减去积分：</b>
                            <div style="color: green"></div>
                        </td>
                        <td class="righttd">
                            <asp:TextBox ID="TxtAskScore11" CssClass="textbox" runat="server" Width="50px" Style="text-align: center" />
                            分
                            <span class="tips">指会员在会员中心删除自己的问题，扣除积分。</span>
                        </td>
                    </tr>
                </table>
                <KS:Foot runat="server" CancelButtonVisible="false" ID="Foot3" OnSubmit="Foot3_Submit" />
            </div>

            <div class="tab-page" id="tab2">
                <h2 class="tab"<%=CommonJsonCache.CheckYunAPPHasAllow("plus.group")?"":" style='display:none'" %>>小组积分管理</h2>
                <script type="text/javascript">
                    tabPane1.addTabPage(document.getElementById("tab2"));
                </script>
                   <div class="quickSearch clearfix">
                    <div class="SearchBox fl">
                        <asp:DropDownList ID="DropDownList1" runat="server" Style="margin-right: 8px;">
                            <asp:ListItem Value="1">小组名称</asp:ListItem>
                        </asp:DropDownList>
                        <asp:TextBox runat="server" ID="TextBox1" CssClass="textbox" />
                        <asp:Button ID="Button1" runat="server" CssClass="button" Text="开始搜索" OnClick="Button1_Click" />
                    </div>
                </div>
                <asp:Panel ID="Panel2" runat="server">
                    <asp:Repeater ID="list" runat="server">
                        <HeaderTemplate>
                            <table width="99%" align="center" cellpadding="0" cellspacing="0" class="CTable">
                                <tr class="CTitle">
                                    <th scope="col">
                                        <input type="checkbox" name="chkall" onclick="CheckBox(this.checked);" for="chkall" /></th>
                                    <th scope="col"><%=KSCMS.S("TypeInfo")=="1"?"分类":"小组" %>ID</th>
                                    <th scope="col"><%=KSCMS.S("TypeInfo")=="1"?"分类":"小组" %>图标</th>
                                    <th scope="col" style="text-align: left"><%=KSCMS.S("TypeInfo")=="1"?"分类":"小组" %>名称</th>
                                    <th scope="col">小组组长</th>
                                    <th scope="col"><%=KSCMS.S("TypeInfo")=="1"?"分类":"小组" %>简介</th>
                                    <th scope="col">所属分类</th>
                                    <th scope="col">积分配置</th>
                                </tr>
                        </HeaderTemplate>
                        <ItemTemplate>
                            <tr id='sub<%#Eval("BoardID") %>' onmouseover="jQuery('#a<%# Eval("BoardID") %>').show();this.className='CtrMouseOver'" onmouseout="jQuery('#a<%# Eval("BoardID") %>').hide();this.className='CtrMouseOut'" onclick="chk(this)">
                                <td class="Ctd" style="text-align: center; width: 30px;">
                                    <input type="checkbox" name="ids" value='<%#Eval("BoardID")%>' /></td>
                                <td class="Ctd" style="text-align: center; width: 50px;"><%# Eval("BoardID") %></td>
                                <td class="Ctd" align="center">
                                    <img src="<%# Eval("ico") %>" width="150px" height="125px" onerror="this.src='/sysimg/nopic.gif'" /></td>
                                <td class="Ctd" style="height: 30px; width: 150px;"><%# Eval("BoardName") %> </td>
                                <td class="Ctd" align="center" style="width: 100px;"><%# Eval("BoardMaster")==""?"--":Eval("BoardMaster") %></td>
                                <td class="Ctd" align="left"><%#Eval("intro") %>  </td>
                                <td class="Ctd" align="center"><%# BaseFun.CheckTableExists("KS_BBSBoard")?Kesion.BLL.DataFactory.GetOnlyValue("select top 1 BoardName from KS_BBSBoard where BoardID="+Eval("ParentID")):"" %></td>
                                <td class="Ctd link-operate" align="center">
                                    <a href="KS.ScoreConfig.Aspx?action=edit&BoardID=<%# Eval("BoardID") %>">积分配置</a>
                                </td>
                            </tr>
                        </ItemTemplate>
                        <FooterTemplate>
                            </table>
                    <tr>
                        <div class="empty" style="display: <%# bool.Parse((list.Items.Count==0).ToString())?"":"none"%>">查无数据</div>
                    </tr>
                        </FooterTemplate>
                    </asp:Repeater>
                    <KS:Page ID="Page1" runat="server" />
                </asp:Panel>

                <asp:Panel ID="Panel1" runat="server">
                    <table width="100%" border="0" cellpadding="0" cellspacing="0" class="CTable no-borderTable">
                        <tr>
                            <td height="30" align="right" class="lefttd" style="width: 145px">
                                <strong>发表话题</strong>：<br />
                            </td>
                            <td class="righttd">增加
                                <asp:TextBox ID="TxtScore1" Style="text-align: center" Text="0" runat="server" CssClass="textbox" Width="50px"></asp:TextBox>分 
                            <span class="tips">不送积分请设置“0”</span>
                            </td>
                        </tr>
                        <tr>
                            <td height="30" align="right" class="lefttd" style="width: 145px">
                                <strong>发表回复</strong>：<br />
                            </td>
                            <td class="righttd">增加
                            <asp:TextBox ID="TxtScore2" Style="text-align: center" Text="0" runat="server" CssClass="textbox" Width="50px"></asp:TextBox>分 
                            <span class="tips">不送积分请设置“0”，自问自答的话题回复不加积分。</span>
                            </td>
                        </tr>
                        <tr>
                            <td height="30" align="right" class="lefttd" style="width: 145px">
                                <strong>设置精华</strong>：<br />
                            </td>
                            <td class="righttd">增加
                            <asp:TextBox ID="TxtScore3" Style="text-align: center" Text="0" runat="server" CssClass="textbox" Width="50px"></asp:TextBox>分 
                            <span class="tips">不送积分请设置“0”</span>
                            </td>
                        </tr>
                        <tr>
                            <td height="30" align="right" class="lefttd" style="width: 145px">
                                <strong>设置小组置顶</strong>：<br />
                            </td>
                            <td class="righttd">增加
                            <asp:TextBox ID="TxtScore4" Style="text-align: center" Text="0" runat="server" CssClass="textbox" Width="50px"></asp:TextBox>分 
                            <span class="tips">不送积分请设置“0”</span>
                            </td>
                        </tr>
                        <tr>
                            <td height="30" align="right" class="lefttd" style="width: 145px">
                                <strong>设置总置顶</strong>：<br />
                            </td>
                            <td class="righttd">增加
                            <asp:TextBox ID="TxtScore5" Style="text-align: center" Text="0" runat="server" CssClass="textbox" Width="50px"></asp:TextBox>分 
                            <span class="tips">不送积分请设置“0”</span>
                            </td>
                        </tr>
                        <tr>
                            <td height="30" align="right" class="lefttd" style="width: 145px">
                                <strong>话题被删除</strong>：<br />
                            </td>
                            <td class="righttd">扣除
                            <asp:TextBox ID="TxtScore6" Style="text-align: center" Text="0" runat="server" CssClass="textbox" Width="50px"></asp:TextBox>分 
                            <span class="tips">不扣除积分请设置“0”</span>
                            </td>
                        </tr>
                        <tr>
                            <td height="30" align="right" class="lefttd" style="width: 145px">
                                <strong>回复被删除</strong>：<br />
                            </td>
                            <td class="righttd">扣除
                            <asp:TextBox ID="TxtScore7" Style="text-align: center" Text="0" runat="server" CssClass="textbox" Width="50px"></asp:TextBox>分 
                            <span class="tips">不扣除积分请设置“0”</span>
                            </td>
                        </tr>
                    </table>
                    <KS:Foot runat="server" CancelButtonVisible="true" ID="Foot4" OnSubmit="Foot4_Submit" />
                </asp:Panel>

            </div>

            <div class="tab-page" id="tab1">
                <h2 class="tab"<%=BaseFun.CheckModulePower("edu")?"":" style='display:none'" %>>课程相关积分配置</h2>
                <script type="text/javascript">
                    tabPane1.addTabPage(document.getElementById("tab1"));
                </script>
                <div class="quickSearch clearfix">
                    <div class="SearchBox fl">
                        <asp:DropDownList ID="DrpTJ" runat="server" Style="margin-right: 8px;">
                            <asp:ListItem Value="1">课程名称</asp:ListItem>
                        </asp:DropDownList>
                        <asp:TextBox runat="server" ID="TxtKeyWord" CssClass="textbox" />
                        <asp:Button ID="BtnSearch" runat="server" CssClass="button" Text="开始搜索" OnClick="BtnSearch_Click" />
                    </div>
                </div>
                <asp:Panel ID="Panel4" runat="server">
                    <asp:Repeater ID="list2" runat="server">
                        <HeaderTemplate>
                            <table width="99%" align="center" cellpadding="0" cellspacing="0" class="CTable">
                                <tr class="CTitle">
                                    <th scope="col">课程</th>
                                    <th scope="col">积分配置</th>
                                </tr>
                        </HeaderTemplate>
                        <ItemTemplate>
                            <tr>
                                <td class="Ctd" style="text-align: center; width: 200px;"><%#Eval("name")%></td>
                                <td style="text-align: center"><a href="KS.ScoreConfig.Aspx?action=cosedit&cosid=<%# Eval("courseid") %>">积分配置</a>
                                </td>
                            </tr>
                        </ItemTemplate>
                        <FooterTemplate>
                            </table>
                    <tr>
                        <div class="empty" style="display: <%# bool.Parse((list2.Items.Count==0).ToString())?"":"none"%>">查无数据</div>
                    </tr>
                        </FooterTemplate>
                    </asp:Repeater>
                    <KS:Page ID="Page2" runat="server" />
                </asp:Panel>



                <asp:Panel ID="Panel3" runat="server">
                    <table width="100%" border="0" cellpadding="0" cellspacing="0" class="CTable no-borderTable">
                        <tr>
                            <td align="right" class="lefttd" height="30"><strong>赠送积分：</strong></td>
                            <td class="righttd">
                                <asp:TextBox CssClass="textbox" ID="TxtScore" runat="server" Width="50px" Text="0"></asp:TextBox>分 
            					<span class="tips">成功购买本课程一门可以得到的积分。如这里设置1分,用户购买10件,则可以得10分。</span>
                            </td>
                        </tr>

                        <tr>
                            <td align="right" class="lefttd" height="30"><strong>推荐人赠送积分：</strong></td>
                            <td class="righttd">
                                <asp:TextBox CssClass="textbox" ID="RecScore" runat="server" Width="50px" Text="0"></asp:TextBox>分 
            					<span class="tips">学员成功购买该课程后，学员的推荐人获得积分。</span>
                            </td>
                        </tr>
                         <tr>
                            <td align="right" class="lefttd" height="30" >
                                <strong>学习课时赠送积分设置：</strong></td>
                            <td class="righttd">
                                <div class="message">
                                      <table class="PriceCTable">
                                       <tr>
                                           <td align="right" class="lefttd" height="30" style="width: 180px">学习课时分钟数：</td>
                                           <td class="righttd">
                                             <asp:TextBox CssClass="textbox" ID="TxtSpaceTime" runat="server" Width="80px" Text="0"></asp:TextBox>分钟 （设置“0”为不限）
                                           </td>
                                       </tr>
                                        <tr>
                                           <td align="right" class="lefttd" height="30" style="width: 180px">学习课时赠送积分：</td>
                                           <td class="righttd">
                                                 <asp:TextBox CssClass="textbox" ID="TxtLearnScore" runat="server" Width="80px" Text="0"></asp:TextBox>分 （设置“0”为不限）
                                           </td>
                                        </tr>
                                        <tr>
                                           <td align="right" class="lefttd" height="30" style="width: 180px">学习课时每日上限积分：</td>
                                           <td class="righttd">
                                                 <asp:TextBox CssClass="textbox" ID="TxtOnlineScore" runat="server" Width="80px" Text="0"></asp:TextBox>分 （设置“0”为不限）
                                           </td>
                                        </tr>
                                      </table>
                                    </div>
                                </td>
                        </tr>
                    </table>

                    <KS:Foot runat="server" CancelButtonVisible="true" ID="Foot5" OnSubmit="Foot5_Submit" Visible="TRUE" />
                </asp:Panel>
            </div>
        </div>
    </div>
</asp:Content>
