Ver código fonte

全校开课计划

新疆影视学院高职
zhangli 2 anos atrás
pai
commit
d9eddebfbb
7 arquivos alterados com 303 adições e 0 exclusões
  1. +31
    -0
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/ClassPlanController.cs
  2. +44
    -0
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/ClassPlan/IndexSchool.cshtml
  3. +129
    -0
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/ClassPlan/IndexSchool.js
  4. +2
    -0
      Learun.Framework.Ultimate V7/Learun.Application.Web/Learun.Application.Web.csproj
  5. +26
    -0
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/ClassPlan/ClassPlanBLL.cs
  6. +1
    -0
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/ClassPlan/ClassPlanIBLL.cs
  7. +70
    -0
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/ClassPlan/ClassPlanService.cs

+ 31
- 0
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/ClassPlanController.cs Ver arquivo

@@ -42,6 +42,15 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers
{
return View();
}
/// <summary>
/// 全校开课计划
/// <summary>
/// <returns></returns>
[HttpGet]
public ActionResult IndexSchool()
{
return View();
}

#endregion

@@ -68,6 +77,28 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers
};
return Success(jsonData);
}
/// <summary>
/// 全校开课计划
/// </summary>
/// <param name="pagination"></param>
/// <param name="queryJson"></param>
/// <returns></returns>
[HttpGet]
[AjaxOnly]
public ActionResult GetPageListForSchool(string pagination, string queryJson)
{
Pagination paginationobj = pagination.ToObject<Pagination>();
var data = classPlanIBLL.GetPageListForSchool(paginationobj, queryJson);
var jsonData = new
{
rows = data,
total = paginationobj.total,
page = paginationobj.page,
records = paginationobj.records
};
return Success(jsonData);
}

/// <summary>
/// 获取表单数据
/// </summary>


+ 44
- 0
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/ClassPlan/IndexSchool.cshtml Ver arquivo

@@ -0,0 +1,44 @@
@{
ViewBag.Title = "开课计划";
Layout = "~/Views/Shared/_Index.cshtml";
}
<div class="lr-layout ">
<div class="lr-layout-center">
<div class="lr-layout-wrap lr-layout-wrap-notitle ">
<div class="lr-layout-tool">
<div class="lr-layout-tool-left">
<div class="lr-layout-tool-item">
<div id="multiple_condition_query">
<div class="lr-query-formcontent">
<div class="col-xs-6 lr-form-item">
<div class="lr-form-item-title">学年</div>
<div id="AcademicYearNo"></div>
</div>
<div class="col-xs-6 lr-form-item">
<div class="lr-form-item-title">学期</div>
<div id="Semester"></div>
</div>
<div class="col-xs-12 lr-form-item">
<div class="lr-form-item-title">年级</div>
<div id="Grade"></div>
</div>
<div class="col-xs-12 lr-form-item">
<div class="lr-form-item-title">课程</div>
<div id="LessonNo"></div>
</div>
</div>
</div>
</div>
</div>
<div class="lr-layout-tool-right">
<div class=" btn-group btn-group-sm">
<a id="lr_refresh" class="btn btn-default"><i class="fa fa-refresh"></i></a>
</div>
</div>
</div>
<div class="lr-layout-body" id="gridtable"></div>
</div>
</div>
</div>

@Html.AppendJsFile("/Areas/EducationalAdministration/Views/ClassPlan/IndexSchool.js")

+ 129
- 0
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/ClassPlan/IndexSchool.js Ver arquivo

@@ -0,0 +1,129 @@
/* * 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架(http://www.learun.cn)
* Copyright (c) 2013-2020 力软信息技术(苏州)有限公司
* 创建人:超级管理员
* 日 期:2021-11-29 11:43
* 描 述:开课计划
*/
var refreshGirdData;
var bootstrap = function ($, learun) {
"use strict";
var cddeptname = '';
var page = {
init: function () {
page.initGird();
page.bind();
},
bind: function () {
$('#multiple_condition_query').lrMultipleQuery(function (queryJson) {
page.search(queryJson);
}, 250, 400);
//$('#F_SchoolId').lrDataSourceSelect({ code: 'company', value: 'f_companyid', text: 'f_fullname' });
$('#AcademicYearNo').lrselect({
placeholder: "请选择学年",
allowSearch: true,
url: top.$.rootUrl + '/EducationalAdministration/EADateArrange/GetAcademicYearNo',
value: 'value',
text: 'text'
});
//年级
$('#Grade').lrselect({
placeholder: "请选择年级",
allowSearch: true,
url: top.$.rootUrl + '/EducationalAdministration/StuInfoFresh/GetGradeData',
value: 'value',
text: 'text'
});
$('#Semester').lrDataItemSelect({ code: 'Semester' });
$("#MajorNo").lrselect();

$('#LessonNo').lrDataSourceSelect({ code: 'LessonInfo', value: 'lessonno', text: 'lessonname' });
// 刷新
$('#lr_refresh').on('click', function () {
location.reload();
});
},
// 初始化列表
initGird: function () {
$('#gridtable').jfGrid({
url: top.$.rootUrl + '/EducationalAdministration/ClassPlan/GetPageListForSchool',
headData: [
{ label: "学年", name: "AcademicYearNo", width: 80, align: "left" },
{
label: "学期", name: "Semester", width: 50, align: "left",
formatterAsync: function (callback, value, row, op, $cell) {
learun.clientdata.getAsync('dataItem', {
key: value,
code: 'Semester',
callback: function (_data) {
callback(_data.text);
}
});
}
},
{ label: "年级", name: "Grade", width: 50, align: "left" },
{ label: "课程编码", name: "LessonNo", width: 200, align: "left" },
{ label: "课程名称", name: "LessonName", width: 200, align: "left" },
{
label: "课程类型", name: "LessonTypeId", width: 200, align: "left",
formatterAsync: function (callback, value, row, op, $cell) {
learun.clientdata.getAsync('custmerData', {
url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'CdLessonType',
key: value,
keyId: 'ltid',
callback: function (_data) {
callback(_data['lessontypename']);
}
});
}
},
{
label: "状态", name: "State", width: 100, align: "left",
formatter: function (cellvalue, row) {
if (cellvalue == 0) {
return '<span class=\"label label-warning\">未排课</span>';
} if (cellvalue == 1) {
return '<span class=\"label label-success\">已排课</span>';
}
}
},
{ label: "拟开教学班数", name: "TeachClassNum", width: 100, align: "left" },
//{ label: "人数", name: "StuNum", width: 80, align: "left" },
{ label: "周课时", name: "WeekLessonHour", width: 80, align: "left" },
{ label: "教室课时", name: "WeekHourClassroom", width: 80, align: "left" },
{ label: "上机课时", name: "PracticeHour", width: 80, align: "left" },
{ label: "起始周次", name: "StartWeek", width: 80, align: "left" },
//{ label: "结束周次", name: "EndWeek", width: 80, align: "left" },
//{
// label: "负责开课院系", name: "TeachDeptNo", width: 100, align: "left",
// formatterAsync: function (callback, value, row, op, $cell) {
// learun.clientdata.getAsync('custmerData', {
// url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'CdDeptInfo',
// key: value,
// keyId: 'deptno',
// callback: function (_data) {
// callback(_data['deptname']);
// }
// });
// }
//},
{ label: "学分", name: "StudyScore", width: 80, align: "left" },
{ label: "备注", name: "Remark", width: 100, align: "left" },
],
mainId: 'ID',
sidx: 'MakeDate desc',
isPage: true
});
page.search();
},
search: function (param) {
param = param || {};
param.DeptNo = cddeptname;
$('#gridtable').jfGridSet('reload', { queryJson: JSON.stringify(param) });
}
};
refreshGirdData = function () {
$('#gridtable').jfGridSet('reload');
};
page.init();
}

+ 2
- 0
Learun.Framework.Ultimate V7/Learun.Application.Web/Learun.Application.Web.csproj Ver arquivo

@@ -965,6 +965,7 @@
<Content Include="Areas\EducationalAdministration\Views\ClassPlanTeach\TeachFormQZ.js" />
<Content Include="Areas\EducationalAdministration\Views\ClassPlanTeach\TeachForm.js" />
<Content Include="Areas\EducationalAdministration\Views\ClassPlan\Form.js" />
<Content Include="Areas\EducationalAdministration\Views\ClassPlan\IndexSchool.js" />
<Content Include="Areas\EducationalAdministration\Views\ClassPlan\Index.js" />
<Content Include="Areas\EducationalAdministration\Views\Dispatch\Form.js" />
<Content Include="Areas\EducationalAdministration\Views\Dispatch\FormView.js" />
@@ -7833,6 +7834,7 @@
<Content Include="Areas\EducationalAdministration\Views\Sys_PsychologicalCounse\IndexRecive.cshtml" />
<Content Include="Areas\EducationalAdministration\Views\Sys_PsychologicalCounse\FormViewReceive.cshtml" />
<Content Include="Areas\EducationalAdministration\Views\Sys_PsychologicalCounse\FormViewReceiveData.cshtml" />
<Content Include="Areas\EducationalAdministration\Views\ClassPlan\IndexSchool.cshtml" />
<None Include="Properties\PublishProfiles\CustomProfile.pubxml" />
<None Include="Properties\PublishProfiles\FolderProfile.pubxml" />
<Content Include="Views\Login\Default-beifen.cshtml" />


+ 26
- 0
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/ClassPlan/ClassPlanBLL.cs Ver arquivo

@@ -43,6 +43,32 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration
}
}


/// <summary>
/// 获取页面显示列表数据
/// </summary>
/// <param name="pagination">分页参数</param>
/// <param name="queryJson">查询参数</param>
/// <returns></returns>
public IEnumerable<OpenLessonPlanEntity> GetPageListForSchool(Pagination pagination, string queryJson)
{
try
{
return classPlanService.GetPageListForSchool(pagination, queryJson);
}
catch (Exception ex)
{
if (ex is ExceptionEx)
{
throw;
}
else
{
throw ExceptionEx.ThrowBusinessException(ex);
}
}
}

/// <summary>
/// 获取OpenLessonPlan表实体数据
/// </summary>


+ 1
- 0
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/ClassPlan/ClassPlanIBLL.cs Ver arquivo

@@ -21,6 +21,7 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration
/// <param name="queryJson">查询参数</param>
/// <returns></returns>
IEnumerable<OpenLessonPlanEntity> GetPageList(Pagination pagination, string queryJson);
IEnumerable<OpenLessonPlanEntity> GetPageListForSchool(Pagination pagination, string queryJson);
/// <summary>
/// 获取OpenLessonPlan表实体数据
/// </summary>


+ 70
- 0
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/ClassPlan/ClassPlanService.cs Ver arquivo

@@ -89,6 +89,76 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration
}
}

/// <summary>
/// 全校开课计划
/// </summary>
/// <param name="pagination"></param>
/// <param name="queryJson"></param>
/// <returns></returns>
public IEnumerable<OpenLessonPlanEntity> GetPageListForSchool(Pagination pagination, string queryJson)
{
try
{
var strSql = new StringBuilder();
strSql.Append("SELECT ");
strSql.Append(@" t.AcademicYearNo,t.Semester,t.Grade,t.LessonNo,t.LessonName,l.LessonTypeId,t.TeachClassNum,t.WeekLessonHour,t.WeekHourClassroom,t.PracticeHour,t.StartWeek,t.StudyScore,t.Remark,t.MakeDate ");
strSql.Append(" FROM OpenLessonPlan t ");
strSql.Append(" left join lessoninfo l on t.lessonno=l.lessonno ");
strSql.Append(" where l.CheckMark=1 ");
var queryParam = queryJson.ToJObject();
// 虚拟参数
var dp = new DynamicParameters(new { });
if (!queryParam["F_SchoolId"].IsEmpty())
{
dp.Add("F_SchoolId", queryParam["F_SchoolId"].ToString(), DbType.String);
strSql.Append(" AND t.F_SchoolId = @F_SchoolId ");
}
if (!queryParam["AcademicYearNo"].IsEmpty())
{
dp.Add("AcademicYearNo", queryParam["AcademicYearNo"].ToString(), DbType.String);
strSql.Append(" AND t.AcademicYearNo = @AcademicYearNo ");
}
if (!queryParam["Semester"].IsEmpty())
{
dp.Add("Semester", queryParam["Semester"].ToString(), DbType.String);
strSql.Append(" AND t.Semester = @Semester ");
}
if (!queryParam["DeptNo"].IsEmpty())
{
dp.Add("DeptNo", queryParam["DeptNo"].ToString(), DbType.String);
strSql.Append(" AND t.DeptNo = @DeptNo ");
}
if (!queryParam["MajorNo"].IsEmpty())
{
dp.Add("MajorNo", queryParam["MajorNo"].ToString(), DbType.String);
strSql.Append(" AND t.MajorNo = @MajorNo ");
}
if (!queryParam["Grade"].IsEmpty())
{
dp.Add("Grade", "%" + queryParam["Grade"].ToString() + "%", DbType.String);
strSql.Append(" AND t.Grade Like @Grade ");
}
if (!queryParam["LessonNo"].IsEmpty())
{
dp.Add("LessonNo", queryParam["LessonNo"].ToString(), DbType.String);
strSql.Append(" AND t.LessonNo = @LessonNo ");
}
strSql.Append(" group by t.AcademicYearNo,t.Semester,t.Grade,t.LessonNo,t.LessonName,l.LessonTypeId,t.State, t.TeachClassNum, t.WeekLessonHour, t.WeekHourClassroom, t.PracticeHour, t.StartWeek, t.StudyScore, t.Remark,t.MakeDate ");
return this.BaseRepository("CollegeMIS").FindList<OpenLessonPlanEntity>(strSql.ToString(), dp, pagination);
}
catch (Exception ex)
{
if (ex is ExceptionEx)
{
throw;
}
else
{
throw ExceptionEx.ThrowServiceException(ex);
}
}
}

/// <summary>
/// 获取OpenLessonPlan表实体数据
/// </summary>


Carregando…
Cancelar
Salvar