<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="GetScoreItemApp.aspx.cs" Inherits="AVA.ResourcesPlatform.WebUI.Tools.Subject.GetScoreItemApp" %> <%= Import.ScriptTheme("js/jquery.1.9.js")%> <%= Import.ScriptTheme("js/libs/jquery.rating.pack.js")%> <%= Import.ScriptTheme("js/libs/bootstrap-dropdown.js") %> <%= Import.ScriptTheme("js/libs/bootstrap-affix.js") %> <%= Import.ScriptTheme("js/libs/bootstrap-collapse.js")%> <%= Import.ScriptTheme("js/libs/bootstrap-transition.js")%> <%= Import.ScriptTheme("js/libs/bootstrap-tab.js")%> <%= Import.CSS("style.css")%> <%= Import.CSS("style/jquery.rating.css")%> <%= Import.Script("/global.aspx")%> <%= Import.Script("js", "/global.js")%>
<%if (this.ErrorCode != 1) { %> <% var ListSTScoreType = this.ListSTScoreItem.GroupBy(l => l.ParentSTScoreType) .Select(l => l.Key) .OrderBy(l => l.SortNumber) .ToList(); %>
<% for (int i = 0; i <= ListSTScoreType.Count - 1; i++) { %>
<% foreach (var stScoreItem in this.ListSTScoreItem.Where(l => l.ParentSTScoreType == ListSTScoreType[i]) .OrderBy(l => l.SortNumber) .ToList()) { %> <% } %>
要求 得分 权重
<%= stScoreItem.Name%>
<%--<%= llScoreItem.Description.RestoreHtml()%>--%>
<%= new HtmlHidden("STScoreItemGuid", stScoreItem.Guid)%> <%= new HtmlHidden("VideoGuid", this.Video == null ? "" : this.Video.Guid)%> <%= new HtmlHidden("STUserGuid", this.STUser == null ? "" : this.STUser.Guid)%>
<% var score = stScoreItem.ScoreRatio; var stars = 5;//表示星星数量 //找取当前用户的评分 double? localScore = null; var stUserScoreItem = CreateInstance.STUserScoreItemDao.Where(l => l.ParentSTUser == this.STUser && l.ParentVideo == this.Video && l.ParentSTScoreItem == stScoreItem) .ToList() .FirstResult(); if (stUserScoreItem != null) { localScore = stUserScoreItem.Score; } for (var j = 1; j <= stars * 1; j++) { %> <%= new HtmlRadio("frm" + stScoreItem.Guid, score * j / (1* 5), "0") { Class = "pingfen {split:2}", Checked = (localScore == score / stars * j ? true : false) }%> <% } %>
<%= stScoreItem.ScoreRatio%>
<%} %>
<% } else { %> ErrorCode = <%= this.ErrorCode %> Message = <%= this.Message %> <% } %> <%----%>