Edit D:\AVA\AVAStandard\AVA.ResourcesPlatform.WebUI\Themes\DefaultTheme\Control\My\MyComparison.ascx
??<%@ Control Language="C#" AutoEventWireup="true" Inherits="AVA.ResourcesPlatform.WebUI.Control.My.MyComparison" %> <%= new MyGrowthPathNavTopInstance(this) { Local= MyGrowthPathNavTopItem.????? }.ToHtml()%> <hr class="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) .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> <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%>] } ] }; $(document).ready(function () { var hc2 = new Highcharts.Chart(systemSeries2); }); </script> <% } %>
Ms-Dos/Windows
Unix
Write backup
jsp File Browser version 1.2 by
www.vonloesch.de