Edit D:\AVAWeike\AVAWeike\AVA.ResourcesPlatform.WebUI\Themes\ShiXun\Control\My\MyComparison.ascx
??<%@ Control Language="C#" AutoEventWireup="true" Inherits="AVA.ResourcesPlatform.WebUI.Control.My.MyComparison" %> <%= new MyGrowthPathNavTopInstance(this) { Local= MyGrowthPathNavTopItem.????? }.ToHtml()%> <hr class="hr-dashed"> <div class="well"> <% var userGuid = Request.QueryString["UserGuid"]; var listTeacher = CreateInstance.UserDao.Where(l => l.ParentUserType.TeacherEbable == true && l.Status == (int)AVA.ResourcesPlatform.Model.Pub.UserStatusEnum.??? && l.Verify == (int)AVA.ResourcesPlatform.Model.Pub.UserVerifyEnum.????? && l.ParentDomain == this.User.ParentDomain && l.Guid != CookieGroup.UserCode) .ToList(); %><form> <label for="">?????????</label> <%= new HtmlSelect("", "TrueName", "Guid", "Guid") { ID="ddlComparison", Option = listTeacher,OnChange="GoToComparison();" }.InsertOption("::?????::","",0)%> <script type="text/javascript"> function GoToComparison() { var guid = document.getElementById("ddlComparison").value; if (guid != "") { var url = '<%= WebUrl.MyComparison("Guid") %>'; var url = url.replace("Guid", guid); window.location.href = url; } } </script> </form> </div> <% if (!string.IsNullOrEmpty(userGuid)) { var otherUser = CreateInstance.UserDao.Get(userGuid); //var transformer = new Z.Core.NHibernateCore.TupleToPropertyResultTransformer<AVA.ResourcesPlatform.Model.Pub.Video> // ("TeacherRatio", "StudentRatio", "TransferRatio"); var critThis = CreateInstance.VideoDao.NHibernateSession.CreateCriteria<AVA.ResourcesPlatform.Model.Pub.Video>("_Alias"); critThis.Add(NHibernate.Criterion.Expression.Eq("Examine", (int)AVA.ResourcesPlatform.Model.Pub.VideoExamineEnum.??????)); critThis.Add(NHibernate.Criterion.Expression.Eq("Status", (int)AVA.ResourcesPlatform.Model.Pub.VideoStatusEnum.???)); critThis.CreateAlias("ParentUser", "_User"); critThis.Add(NHibernate.Criterion.Expression.Eq("_User.Guid", this.User.Guid)); critThis.Add(NHibernate.Criterion.Expression.Ge("TeacherRatio", 0)); critThis.Add(NHibernate.Criterion.Expression.Ge("StudentRatio", 0)); critThis.Add(NHibernate.Criterion.Expression.Ge("TransferRatio", 0)); critThis.SetProjection(NHibernate.Criterion.Projections.ProjectionList() .Add(NHibernate.Criterion.Projections.AvgDefaultDataType("TeacherRatio")) .Add(NHibernate.Criterion.Projections.AvgDefaultDataType("StudentRatio")) .Add(NHibernate.Criterion.Projections.AvgDefaultDataType("TransferRatio")) ); var thisVideo = critThis.List<object[]>() .FirstResult(); var thisTeacherRatio = 0; var thisStudentRatio = 0; var thisTransferRatio = 0; if (thisVideo != null) { thisTeacherRatio = thisVideo[0].ToInt(); thisStudentRatio = thisVideo[1].ToInt(); thisTransferRatio = thisVideo[2].ToInt(); } var critOther = CreateInstance.VideoDao.NHibernateSession.CreateCriteria<AVA.ResourcesPlatform.Model.Pub.Video>("_Alias"); critOther.Add(NHibernate.Criterion.Expression.Eq("Examine", (int)AVA.ResourcesPlatform.Model.Pub.VideoExamineEnum.??????)); critOther.Add(NHibernate.Criterion.Expression.Eq("Status", (int)AVA.ResourcesPlatform.Model.Pub.VideoStatusEnum.???)); critOther.CreateAlias("ParentUser", "_User"); critOther.Add(NHibernate.Criterion.Expression.Eq("_User.Guid", userGuid)); critOther.Add(NHibernate.Criterion.Expression.Ge("TeacherRatio", 0)); critOther.Add(NHibernate.Criterion.Expression.Ge("StudentRatio", 0)); critOther.Add(NHibernate.Criterion.Expression.Ge("TransferRatio", 0)); critOther.SetProjection(NHibernate.Criterion.Projections.ProjectionList() .Add(NHibernate.Criterion.Projections.AvgDefaultDataType("TeacherRatio")) .Add(NHibernate.Criterion.Projections.AvgDefaultDataType("StudentRatio")) .Add(NHibernate.Criterion.Projections.AvgDefaultDataType("TransferRatio")) ); var otherVideo = critOther.List<object[]>() .FirstResult(); var otherTeacherRatio = 0; var otherStudentRatio = 0; var otherTransferRatio = 0; if (otherVideo != null) { otherTeacherRatio = otherVideo[0].ToInt(); otherStudentRatio = otherVideo[1].ToInt(); otherTransferRatio = otherVideo[2].ToInt(); } %> <%--<div id="biyibi_chart"></div>--%> <div class="row"> <div class="span5"> <table class="table table-bordered"> <caption> ????????? </caption> <tr> <th>?????</th> <th class="">???</th> </tr> <tr> <td>??????</td> <td class=""><%= CreateInstance.VideoDao.Count(l=>l.ParentUser == this.User) %></td> </tr> <tr> <td>????????</td> <td class=""><%= CreateInstance.VideoDao.Where(l=>l.ParentUser == this.User).Sum(l=>l.VideoView) %></td> </tr> <tr> <td>?????????</td> <td class=""><%= CreateInstance.VideoDao.Where(l=>l.ParentUser == this.User).Sum(l=>l.CollectCount) %></td> </tr> <tr> <td>???????????</td> <td class=""><%= CreateInstance.VideoDao.Where(l=>l.ParentUser == this.User).Sum(l=>l.CommentCount) %></td> </tr> <tr> <td>?????????</td> <td class=""><%= CreateInstance.SubjectUserDao.Count(l=>l.ParentUser == this.User) %></td> </tr> <%-- <tr> <td><%= Define.Get("Client_???")%>???</td> <td class=""><%= CreateInstance.AlbumDao.Count(l=>l.ParentUser == this.User) %></td> </tr>--%> </table> </div> <div class="span5"> <table class="table table-bordered"> <caption> <%= otherUser.TrueName %>???????? </caption> <tr> <th>?????</th> <th class="">???</th> </tr> <tr> <td>??????</td> <td class=""><%= CreateInstance.VideoDao.Count(l=>l.ParentUser == otherUser) %></td> </tr> <tr> <td>????????</td> <td class=""><%= CreateInstance.VideoDao.Where(l=>l.ParentUser == otherUser).Sum(l=>l.VideoView) %></td> </tr> <tr> <td>?????????</td> <td class=""><%= CreateInstance.VideoDao.Where(l=>l.ParentUser == otherUser).Sum(l=>l.CollectCount) %></td> </tr> <tr> <td>???????????</td> <td class=""><%= CreateInstance.VideoDao.Where(l=>l.ParentUser == otherUser).Sum(l=>l.CommentCount) %></td> </tr> <tr> <td>?????????</td> <td class=""><%= CreateInstance.SubjectUserDao.Count(l=>l.ParentUser == otherUser) %></td> </tr> <%--<tr> <td><%= Define.Get("Client_???")%>???</td> <td class=""><%= CreateInstance.AlbumDao.Count(l=>l.ParentUser == otherUser) %></td> </tr>--%> </table> </div> </div> <script type="text/javascript"> <%--var systemSeries2 = { chart: { type: 'line', renderTo: 'biyibi_chart' // defaultSeriesType: 'column' }, title: { text: '?????' }, xAxis: { title: { text: '??????', align: 'left' }, categories: ['????????????', '????????????', '?????????' ] }, yAxis: { min: 0, title: { text: '??????', align: 'high' }, labels: { overflow: 'justify' }, }, tooltip: { valueSuffix: ' ' }, plotOptions: { bar: { dataLabels: { enabled: true } } }, legend: { layout: 'vertical', align: 'right', verticalAlign: 'top', x: -100, y: 100, floating: true, borderWidth: 1, backgroundColor: '#FFFFFF', shadow: true }, credits: { enabled: false }, series: [ { name: '???', data: [<%= thisTeacherRatio%>, <%= thisStudentRatio%>, <%= thisTransferRatio%>] }, { name: '<%= otherUser.TrueName %>', data: [<%= otherTeacherRatio%>, <%= otherStudentRatio%>, <%= otherTransferRatio%>] } ] };--%> <%--var biyibiSeries = { chart: { type: "bar", renderTo: "biyibi_chart", marginRight: 130, marginBottom: 25 }, title: { text: "?????", x: -20 //center }, subtitle: { text: "", x: -20 }, xAxis: { categories: ["??????", "????????", "?????????", "?????????", "???<%= Define.Get("Client_???")%>???", "<%= Define.Get("Client_???")%>???"] }, yAxis: { title: { text: "" }, plotLines: [{ value: 0, width: 1, color: "#808080" }] }, tooltip: { valueSuffix: "???" }, legend: { layout: "vertical", align: "right", verticalAlign: "top", x: -10, y: 100, borderWidth: 0 }, series: ([ <% var listViewVideo2 = CreateInstance.VideoDao.DayViewCount(new AVA.ResourcesPlatform.Config.TotalParameter() { DomainGuid = CookieGroup.DomainGuid, ResultCount = 10, TotalType = AVA.ResourcesPlatform.Config.TotalTypeEnum.?? }); foreach (var video in listViewVideo2) { %> { name: "<%= video.Name %>", data: [<%= video.VideoView %>, <%= video.CommentCount %>, <%= video.CollectCount %>] }, <% } %> { name: "", data: [] } ]).slice(0, -1) //end series }; $(document).ready(function () { var hc2 = new Highcharts.Chart(biyibiSeries); });--%> </script> <% } %>
Ms-Dos/Windows
Unix
Write backup
jsp File Browser version 1.2 by
www.vonloesch.de