Bläddra i källkod

Merge branch '长阳分支中职' of http://8.141.155.183:3000/bjquanjiang/DigitalScholl into 长阳分支中职

枝江中职分支
yxq 1 månad sedan
förälder
incheckning
1d9c2f54eb
11 ändrade filer med 342 tillägg och 123 borttagningar
  1. +17
    -13
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StudentCompetition/Form.cshtml
  2. +1
    -0
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StudentCompetition/Form.js
  3. +2
    -2
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StudentCompetition/Index.cshtml
  4. +113
    -51
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StudentCompetition/Index.js
  5. +53
    -21
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/TrainEquipmentManage/Form.cshtml
  6. +19
    -2
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/TrainEquipmentManage/Form.js
  7. +15
    -6
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/TrainEquipmentManage/Index.cshtml
  8. +77
    -27
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/TrainEquipmentManage/Index.js
  9. +6
    -0
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StudentCompetition/StudentCompetitionEntity.cs
  10. +29
    -1
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/TrainEquipmentManage/TrainEquipmentManageEntity.cs
  11. +10
    -0
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/TrainEquipmentManage/TrainEquipmentManageService.cs

+ 17
- 13
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StudentCompetition/Form.cshtml Visa fil

@@ -3,55 +3,59 @@
Layout = "~/Views/Shared/_Form.cshtml";
}
<div class="lr-form-wrap" id="form">
<div class="col-xs-12 lr-form-item" data-table="StudentCompetition">
<div class="col-xs-6 lr-form-item" data-table="StudentCompetition">
<div class="lr-form-item-title">学年<font face="宋体">*</font></div>
<div id="AcademicYearNo" isvalid="yes" checkexpession="NotNull"></div>
</div>
<div class="col-xs-12 lr-form-item" data-table="StudentCompetition">
<div class="col-xs-6 lr-form-item" data-table="StudentCompetition">
<div class="lr-form-item-title">学期<font face="宋体">*</font></div>
<div id="Semester"></div>
</div>
<div class="col-xs-12 lr-form-item" data-table="StudentCompetition">
<div class="col-xs-6 lr-form-item" data-table="StudentCompetition">
<div class="lr-form-item-title">学生学号<font face="宋体">*</font></div>
<input id="StuNo" type="text" class="form-control" isvalid="yes" checkexpession="NotNull" />
</div>
<div class="col-xs-12 lr-form-item" data-table="StudentCompetition">
<div class="col-xs-6 lr-form-item" data-table="StudentCompetition">
<div class="lr-form-item-title">学生姓名<font face="宋体">*</font></div>
<input id="StuName" type="text" class="form-control" isvalid="yes" checkexpession="NotNull" />
</div>
<div class="col-xs-12 lr-form-item" data-table="StudentCompetition">
<div class="col-xs-6 lr-form-item" data-table="StudentCompetition">
<div class="lr-form-item-title">专业部<font face="宋体">*</font></div>
<div id="DeptNo" isvalid="yes" checkexpession="NotNull" readonly></div>
</div>
<div class="col-xs-12 lr-form-item" data-table="StudentCompetition">
<div class="col-xs-6 lr-form-item" data-table="StudentCompetition">
<div class="lr-form-item-title">专业<font face="宋体">*</font></div>
<div id="MajorNo" isvalid="yes" checkexpession="NotNull" readonly></div>
</div>
<div class="col-xs-12 lr-form-item" data-table="StudentCompetition">
<div class="col-xs-6 lr-form-item" data-table="StudentCompetition">
<div class="lr-form-item-title">班级<font face="宋体">*</font></div>
<div id="ClassNo" isvalid="yes" checkexpession="NotNull" readonly></div>
</div>
<div class="col-xs-12 lr-form-item" data-table="StudentCompetition">
<div class="col-xs-6 lr-form-item" data-table="StudentCompetition">
<div class="lr-form-item-title">赛事名称<font face="宋体">*</font></div>
<input id="SCName" type="text" class="form-control" isvalid="yes" checkexpession="NotNull" />
</div>
<div class="col-xs-12 lr-form-item" data-table="StudentCompetition">
<div class="col-xs-6 lr-form-item" data-table="StudentCompetition">
<div class="lr-form-item-title">赛事级别<font face="宋体">*</font></div>
<div id="SCLevel" isvalid="yes" checkexpession="NotNull"></div>
</div>
<div class="col-xs-12 lr-form-item" data-table="StudentCompetition">
<div class="col-xs-6 lr-form-item" data-table="StudentCompetition">
<div class="lr-form-item-title">赛事种类<font face="宋体">*</font></div>
<input id="SCType" type="text" class="form-control" isvalid="yes" checkexpession="NotNull" />
</div>
<div class="col-xs-12 lr-form-item" data-table="StudentCompetition">
<div class="col-xs-6 lr-form-item" data-table="StudentCompetition">
<div class="lr-form-item-title">奖次<font face="宋体">*</font></div>
<div id="EncouragementDegree" isvalid="yes" checkexpession="NotNull"></div>
</div>
<div class="col-xs-6 lr-form-item" data-table="StudentCompetition">
<div class="lr-form-item-title">颁发单位<font face="宋体">*</font></div>
<input id="Unit" type="text" class="form-control" isvalid="yes" checkexpession="NotNull" />
</div>
<div class="col-xs-12 lr-form-item" data-table="StudentCompetition">
<div class="col-xs-6 lr-form-item" data-table="StudentCompetition">
<div class="lr-form-item-title">分值<font face="宋体">*</font></div>
<input id="Score" type="text" class="form-control" isvalid="yes" checkexpession="NotNull" />
</div>
<div class="col-xs-12 lr-form-item" data-table="StudentCompetition">
<div class="col-xs-6 lr-form-item" data-table="StudentCompetition">
<div class="lr-form-item-title">获取时间<font face="宋体">*</font></div>
<input id="SCTime" type="text" class="form-control lr-input-wdatepicker" onfocus="WdatePicker({ dateFmt:'yyyy-MM-dd',onpicked: function () { $('#SCTime').trigger('change'); } })" isvalid="yes" checkexpession="NotNull" />
</div>


+ 1
- 0
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StudentCompetition/Form.js Visa fil

@@ -64,6 +64,7 @@ var bootstrap = function ($, learun) {
$('#ClassNo').lrDataSourceSelect({ code: 'bjsj', value: 'classno', text: 'classname' });
$('#Url').lrUploader();
$('#SCLevel').lrDataItemSelect({ code: 'Level' });
$('#EncouragementDegree').lrDataItemSelect({ code: 'EncouragementDegree' });

$('#StuNo').blur(function () {
learun.httpAsyncGet(top.$.rootUrl + '/EducationalAdministration/StudentCompetition/GetStuData?stuno=' + $('#StuNo').val(), function (res) {


+ 2
- 2
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StudentCompetition/Index.cshtml Visa fil

@@ -63,9 +63,9 @@
<a id="lr_add" class="btn btn-default"><i class="fa fa-plus"></i>&nbsp;新增</a>
<a id="lr_copy" class="btn btn-default"><i class="fa fa-plus"></i>&nbsp;复制</a>
<a id="lr_edit" class="btn btn-default"><i class="fa fa-pencil-square-o"></i>&nbsp;编辑</a>
<a id="lr_updscore" class="btn btn-default"><i class="fa fa-plus"></i>&nbsp;修改分值</a>
@*<a id="lr_updscore" class="btn btn-default"><i class="fa fa-plus"></i>&nbsp;修改分值</a>*@
<a id="lr_delete" class="btn btn-default"><i class="fa fa-trash-o"></i>&nbsp;删除</a>
<a id="lr_submit" class="btn btn-default"><i class="fa fa-plus"></i>&nbsp;提交</a>
@*<a id="lr_submit" class="btn btn-default"><i class="fa fa-plus"></i>&nbsp;提交</a>*@
<a id="lr_print" class="btn btn-default"><i class="fa fa-print"></i>&nbsp;打印</a>
</div>
</div>


+ 113
- 51
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StudentCompetition/Index.js Visa fil

@@ -17,9 +17,57 @@ var bootstrap = function ($, learun) {
$('#multiple_condition_query').lrMultipleQuery(function (queryJson) {
page.search(queryJson);
}, 240, 400);
$('#DeptNo').lrDataSourceSelect({ code: 'CdDeptInfo', value: 'deptno', text: 'deptname' });
$('#MajorNo').lrDataSourceSelect({ code: 'CdMajorInfo', value: 'majorno', text: 'majorname' });
$('#ClassNo').lrDataSourceSelect({ code: 'bjsj', value: 'classno', text: 'classname' });
$('#DeptNo').lrselect({
allowSearch: true,
value: "deptno",
text: "deptname",
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=CdDeptInfo',
select: function (item) {
if (item) {
$('#MajorNo').lrselectRefresh({
allowSearch: true,
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=CdMajorInfo',
param: { strWhere: "DeptNo='" + item.deptno + "' AND CheckMark=1" }
});
} else {
$('#MajorNo').lrselectRefresh({
allowSearch: true,
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=CdMajorInfo',
param: { strWhere: "1=1 AND CheckMark=1" }
});
}

}
});
$('#MajorNo').lrselect({
allowSearch: true,
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=CdMajorInfo',
value: "majorno",
text: "majorname",
param: { strWhere: "1=1 AND CheckMark=1" },
select: function (item) {
if (item) {
$('#ClassNo').lrselectRefresh({
allowSearch: true,
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=bjsj',
param: { strWhere: "majorno='" + item.majorno + "' AND CheckMark=1 order by classno desc" }
});
} else {
$('#ClassNo').lrselectRefresh({
allowSearch: true,
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=bjsj',
param: { strWhere: "1=1 AND CheckMark=1 order by classno desc" }
});
}
}
});
$('#ClassNo').lrselect({
allowSearch: true,
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=bjsj',
param: { strWhere: "1=1 AND CheckMark=1 order by classno desc" },
value: "classno",
text: "classname"
});
$('#SCLevel').lrDataItemSelect({ code: 'Level' });
//学年
$('#AcademicYearNo').lrselect({
@@ -47,8 +95,8 @@ var bootstrap = function ($, learun) {
id: 'form',
title: '新增',
url: top.$.rootUrl + '/EducationalAdministration/StudentCompetition/Form',
width: 1000,
height: 800,
width: 700,
height: 400,
callBack: function (id) {
var res = false;
// 验证数据
@@ -67,21 +115,21 @@ var bootstrap = function ($, learun) {
$('#lr_edit').on('click', function () {
var keyValue = $('#gridtable').jfGridValue('Id');
if (learun.checkrow(keyValue)) {
var Status = $('#gridtable').jfGridValue('Status');
if (Status == '2') {
learun.alert.warning("当前项目已审批通过!");
return;
}
if (Status != '0') {
learun.alert.warning("当前项目已提交,请耐心等待审批!");
return;
}
//var Status = $('#gridtable').jfGridValue('Status');
//if (Status == '2') {
// learun.alert.warning("当前项目已审批通过!");
// return;
//}
//if (Status != '0') {
// learun.alert.warning("当前项目已提交,请耐心等待审批!");
// return;
//}
learun.layerForm({
id: 'form',
title: '编辑',
url: top.$.rootUrl + '/EducationalAdministration/StudentCompetition/Form?keyValue=' + keyValue,
width: 1000,
height: 800,
width: 700,
height: 400,
callBack: function (id) {
var res = false;
// 验证数据
@@ -139,8 +187,8 @@ var bootstrap = function ($, learun) {
id: 'form',
title: '新增',
url: top.$.rootUrl + '/EducationalAdministration/StudentCompetition/Form?keyValue=' + keyValue + '&type=copy',
width: 1000,
height: 800,
width: 700,
height: 400,
callBack: function (id) {
var res = false;
// 验证数据
@@ -160,15 +208,15 @@ var bootstrap = function ($, learun) {
$('#lr_delete').on('click', function () {
var keyValue = $('#gridtable').jfGridValue('Id');
if (learun.checkrow(keyValue)) {
var Status = $('#gridtable').jfGridValue('Status');
if (Status == '2') {
learun.alert.warning("当前项目已审批通过!");
return;
}
if (Status != '0') {
learun.alert.warning("当前项目已提交,请耐心等待审批!");
return;
}
//var Status = $('#gridtable').jfGridValue('Status');
//if (Status == '2') {
// learun.alert.warning("当前项目已审批通过!");
// return;
//}
//if (Status != '0') {
// learun.alert.warning("当前项目已提交,请耐心等待审批!");
// return;
//}
learun.layerConfirm('是否确认删除该项!', function (res) {
if (res) {
learun.deleteForm(top.$.rootUrl + '/EducationalAdministration/StudentCompetition/DeleteForm', { keyValue: keyValue }, function () {
@@ -269,6 +317,18 @@ var bootstrap = function ($, learun) {
}
},
{ label: "赛事种类", name: "SCType", width: 100, align: "left" },
{
label: "奖次", name: "EncouragementDegree", width: 100, align: "left",
formatterAsync: function (callback, value, row, op, $cell) {
learun.clientdata.getAsync('dataItem', {
key: value,
code: 'EncouragementDegree',
callback: function (_data) {
callback(_data.text);
}
});
}
},
{ label: "颁发单位", name: "Unit", width: 100, align: "left" },
{ label: "分值", name: "Score", width: 100, align: "left" },
{
@@ -277,21 +337,22 @@ var bootstrap = function ($, learun) {
return learun.formatDate(cellvalue, 'yyyy-MM-dd');
}
},
{
label: "状态", name: "Status", width: 100, align: "left",
formatter: function (cellvalue, row) {
if (cellvalue === 1) {
return '<span class=\"label label-warning\">审批中</span>';
} else if (cellvalue === 2) {
return '<span class=\"label label-success\">审核通过</span>';
} else {
return '<span class=\"label label-default\" >草稿</span>';
}
}
},
//{
// label: "状态", name: "Status", width: 100, align: "left",
// formatter: function (cellvalue, row) {
// if (cellvalue === 1) {
// return '<span class=\"label label-warning\">审批中</span>';
// } else if (cellvalue === 2) {
// return '<span class=\"label label-success\">审核通过</span>';
// } else {
// return '<span class=\"label label-default\" >草稿</span>';
// }
// }
//},
],
mainId: 'Id',
isPage: true
isPage: true,
sidx: "SCTime desc"
});
page.search();
},
@@ -301,17 +362,18 @@ var bootstrap = function ($, learun) {
}
};
refreshGirdData = function (res, postData) {
if (res && res.code && res.code == 200) {
var postData = {
schemeCode: 'StudentCompetition',// 填写流程对应模板编号
processId: processId,
level: '1',
};
learun.httpAsync('Post', top.$.rootUrl + '/LR_NewWorkFlow/NWFProcess/CreateFlow', postData, function (data) {
learun.loading(false);
});
}
page.search();
$('#gridtable').jfGridSet('reload');
//if (res && res.code && res.code == 200) {
// var postData = {
// schemeCode: 'StudentCompetition',// 填写流程对应模板编号
// processId: processId,
// level: '1',
// };
// learun.httpAsync('Post', top.$.rootUrl + '/LR_NewWorkFlow/NWFProcess/CreateFlow', postData, function (data) {
// learun.loading(false);
// });
//}
//page.search();

};
page.init();


+ 53
- 21
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/TrainEquipmentManage/Form.cshtml Visa fil

@@ -3,37 +3,69 @@
Layout = "~/Views/Shared/_Form.cshtml";
}
<div class="lr-form-wrap" id="form">
<div class="col-xs-12 lr-form-item" data-table="TrainEquipmentManage" >
<div class="lr-form-item-title">专业部<font face="宋体">*</font></div>
<div id="DeptNo" isvalid="yes" checkexpession="NotNull" ></div>
<div class="col-xs-6 lr-form-item" data-table="TrainEquipmentManage">
<div class="lr-form-item-title">部<font face="宋体">*</font></div>
<div id="DeptNo" isvalid="yes" checkexpession="NotNull"></div>
</div>
<div class="col-xs-12 lr-form-item" data-table="TrainEquipmentManage" >
<div class="col-xs-6 lr-form-item" data-table="TrainEquipmentManage">
<div class="lr-form-item-title">实训室名称<font face="宋体">*</font></div>
<input id="TrainName" type="text" class="form-control" isvalid="yes" checkexpession="NotNull" />
</div>
<div class="col-xs-12 lr-form-item" data-table="TrainEquipmentManage" >
<div class="col-xs-6 lr-form-item" data-table="TrainEquipmentManage">
<div class="lr-form-item-title">设备名称<font face="宋体">*</font></div>
<input id="EquipmentName" type="text" class="form-control" isvalid="yes" checkexpession="NotNull" />
</div>
<div class="col-xs-12 lr-form-item" data-table="TrainEquipmentManage" >
<div class="lr-form-item-title">设备型号</div>
<input id="EquipmentModel" type="text" class="form-control" />
<div class="col-xs-6 lr-form-item" data-table="TrainEquipmentManage">
<div class="lr-form-item-title">类别</div>
<div id="EquipmentType" isvalid="yes" checkexpession="NotNull"></div>
</div>
<div class="col-xs-6 lr-form-item" data-table="TrainEquipmentManage">
<div class="lr-form-item-title">型号</div>
<input id="EquipmentModel" type="text" class="form-control" />
</div>
@*<div class="col-xs-12 lr-form-item" data-table="TrainEquipmentManage" >
<div class="lr-form-item-title">新增</div>
<input id="AddNum" type="number" class="form-control" />
<div class="lr-form-item-title">新增</div>
<input id="AddNum" type="number" class="form-control" />
</div>
<div class="col-xs-12 lr-form-item" data-table="TrainEquipmentManage" >
<div class="lr-form-item-title">损耗</div>
<input id="LossNum" type="number" class="form-control" />
</div>
<div class="col-xs-12 lr-form-item" data-table="TrainEquipmentManage">
<div class="lr-form-item-title">现存</div>
<input id="Inventory" type="number" class="form-control" />
</div>*@
<div class="col-xs-6 lr-form-item" data-table="TrainEquipmentManage">
<div class="lr-form-item-title">品牌</div>
<input id="Brand" type="text" class="form-control" />
</div>
<div class="col-xs-12 lr-form-item" data-table="TrainEquipmentManage" >
<div class="lr-form-item-title">损耗</div>
<input id="LossNum" type="number" class="form-control" />
</div>*@
<div class="col-xs-12 lr-form-item" data-table="TrainEquipmentManage" >
<div class="lr-form-item-title">现存</div>
<input id="Inventory" type="number" class="form-control" />
<div class="col-xs-6 lr-form-item" data-table="TrainEquipmentManage">
<div class="lr-form-item-title">参数</div>
<input id="Argument" type="text" class="form-control" />
</div>
<div class="col-xs-6 lr-form-item" data-table="TrainEquipmentManage">
<div class="lr-form-item-title">单位<font face="宋体">*</font></div>
<div id="Unit" isvalid="yes" checkexpession="NotNull"></div>
</div>
<div class="col-xs-6 lr-form-item" data-table="TrainEquipmentManage">
<div class="lr-form-item-title">数量<font face="宋体">*</font></div>
<input id="Nuantity" type="text" class="form-control" isvalid="yes" checkexpession="NotNull" value="0"/>
</div>
<div class="col-xs-6 lr-form-item" data-table="TrainEquipmentManage">
<div class="lr-form-item-title">单价(元)<font face="宋体">*</font></div>
<input id="Price" type="number" class="form-control" isvalid="yes" checkexpession="NotNull" value="0"/>
</div>
<div class="col-xs-6 lr-form-item" data-table="TrainEquipmentManage">
<div class="lr-form-item-title">金额(元)<font face="宋体">*</font></div>
<input id="EquipmentMoney" type="number" class="form-control" readonly value="0" />
</div>
<div class="col-xs-6 lr-form-item" data-table="TrainEquipmentManage">
<div class="lr-form-item-title">管理员<font face="宋体">*</font></div>
<div id="UserId" isvalid="yes" checkexpession="NotNull"></div>
</div>
<div class="col-xs-12 lr-form-item" data-table="TrainEquipmentManage">
<div class="lr-form-item-title">备注</div>
<textarea id="Remark" class="form-control" style="height:80px;"></textarea>
</div>
@*<div class="col-xs-12 lr-form-item" data-table="TrainEquipmentManage" >
<div class="lr-form-item-title">设备金额<font face="宋体">*</font></div>
<input id="EquipmentMoney" type="number" class="form-control" isvalid="yes" checkexpession="PositiveFloatintZero" />
</div>*@
</div>
@Html.AppendJsFile("/Areas/EducationalAdministration/Views/TrainEquipmentManage/Form.js")

+ 19
- 2
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/TrainEquipmentManage/Form.js Visa fil

@@ -15,14 +15,30 @@ var bootstrap = function ($, learun) {
page.initData();
},
bind: function () {
$('#DeptNo').lrDataSourceSelect({ code: 'CdDeptInfo', value: 'deptno', text: 'deptname' });
$('#DeptNo').lrDataSourceSelect({ code: 'classdata', value: 'id', text: 'name' });
$('#Unit').lrDataItemSelect({ code: 'sldw', allowSearch: true });
$('#EquipmentType').lrDataItemSelect({ code: 'AssType' });
$('#Status').lrDataItemSelect({ code: 'AssState' });
$('#UserId').lrDataSourceSelect({ code: 'TeacherInfo', value: 'f_userid', text: 'f_realname' });
$('#Nuantity').focus(function () { }).blur(function () {
var Nuantity = $('#Nuantity').val();
var Price = $('#Price').val();
var EquipmentMoney = parseFloat(Price) * parseFloat(Nuantity)
$('#EquipmentMoney').val(EquipmentMoney)
});
$('#Price').focus(function () { }).blur(function () {
var Price = $('#Price').val();
var Nuantity = $('#Nuantity').val();
var EquipmentMoney = parseFloat(Price) * parseFloat(Nuantity)
$('#EquipmentMoney').val(EquipmentMoney)
});
},
initData: function () {
if (!!keyValue) {
$.lrSetForm(top.$.rootUrl + '/EducationalAdministration/TrainEquipmentManage/GetFormData?keyValue=' + keyValue, function (data) {
for (var id in data) {
if (!!data[id].length && data[id].length > 0) {
$('#' + id ).jfGridSet('refreshdata', data[id]);
$('#' + id).jfGridSet('refreshdata', data[id]);
}
else {
$('[data-table="' + id + '"]').lrSetFormData(data[id]);
@@ -32,6 +48,7 @@ var bootstrap = function ($, learun) {
}
}
};

// 保存数据
acceptClick = function (callBack) {
if (!$('body').lrValidform()) {


+ 15
- 6
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/TrainEquipmentManage/Index.cshtml Visa fil

@@ -2,7 +2,7 @@
ViewBag.Title = "实训设备管理";
Layout = "~/Views/Shared/_Index.cshtml";
}
<div class="lr-layout " >
<div class="lr-layout ">
<div class="lr-layout-center">
<div class="lr-layout-wrap lr-layout-wrap-notitle ">
<div class="lr-layout-tool">
@@ -11,17 +11,25 @@
<div id="multiple_condition_query">
<div class="lr-query-formcontent">
<div class="col-xs-12 lr-form-item">
<div class="lr-form-item-title">专业部</div>
<div class="lr-form-item-title">部</div>
<div id="DeptNo"></div>
</div>
<div class="col-xs-12 lr-form-item">
<div class="col-xs-6 lr-form-item">
<div class="lr-form-item-title">实训室名称</div>
<input id="TrainName" type="text" class="form-control" />
</div>
<div class="col-xs-12 lr-form-item">
<div class="col-xs-6 lr-form-item">
<div class="lr-form-item-title">设备名称</div>
<input id="EquipmentName" type="text" class="form-control" />
</div>
<div class="col-xs-12 lr-form-item">
<div class="lr-form-item-title">类型</div>
<div id="EquipmentType"></div>
</div>
<div class="col-xs-12 lr-form-item">
<div class="lr-form-item-title">管理员</div>
<div id="UserId"></div>
</div>
</div>
</div>
</div>
@@ -31,9 +39,10 @@
<a id="lr_refresh" class="btn btn-default"><i class="fa fa-refresh"></i></a>
</div>
<div class=" btn-group btn-group-sm" learun-authorize="yes">
<a id="lr_add" class="btn btn-default"><i class="fa fa-plus"></i>&nbsp;新增</a>
<a id="lr_edit" class="btn btn-default"><i class="fa fa-pencil-square-o"></i>&nbsp;编辑</a>
<a id="lr_add" class="btn btn-default"><i class="fa fa-plus"></i>&nbsp;新增</a>
<a id="lr_edit" class="btn btn-default"><i class="fa fa-pencil-square-o"></i>&nbsp;编辑</a>
<a id="lr_delete" class="btn btn-default"><i class="fa fa-trash-o"></i>&nbsp;删除</a>
<a id="lr_print" class="btn btn-default"><i class="fa fa-print"></i>&nbsp;打印</a>
</div>
</div>
</div>


+ 77
- 27
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/TrainEquipmentManage/Index.js Visa fil

@@ -16,7 +16,9 @@ var bootstrap = function ($, learun) {
$('#multiple_condition_query').lrMultipleQuery(function (queryJson) {
page.search(queryJson);
}, 220, 400);
$('#DeptNo').lrDataSourceSelect({ code: 'CdDeptInfo', value: 'deptno', text: 'deptname' });
$('#DeptNo').lrDataSourceSelect({ code: 'classdata', value: 'id', text: 'name' });
$('#EquipmentType').lrDataItemSelect({ code: 'AssType' });
$('#UserId').lrDataSourceSelect({ code: 'TeacherInfo', value: 'f_userid', text: 'f_realname' });
// 刷新
$('#lr_refresh').on('click', function () {
location.reload();
@@ -28,7 +30,7 @@ var bootstrap = function ($, learun) {
title: '新增',
url: top.$.rootUrl + '/EducationalAdministration/TrainEquipmentManage/Form',
width: 600,
height: 400,
height: 420,
callBack: function (id) {
return top[id].acceptClick(refreshGirdData);
}
@@ -43,7 +45,7 @@ var bootstrap = function ($, learun) {
title: '编辑',
url: top.$.rootUrl + '/EducationalAdministration/TrainEquipmentManage/Form?keyValue=' + keyValue,
width: 600,
height: 400,
height: 420,
callBack: function (id) {
return top[id].acceptClick(refreshGirdData);
}
@@ -56,47 +58,95 @@ var bootstrap = function ($, learun) {
if (learun.checkrow(keyValue)) {
learun.layerConfirm('是否确认删除该项!', function (res) {
if (res) {
learun.deleteForm(top.$.rootUrl + '/EducationalAdministration/TrainEquipmentManage/DeleteForm', { keyValue: keyValue}, function () {
learun.deleteForm(top.$.rootUrl + '/EducationalAdministration/TrainEquipmentManage/DeleteForm', { keyValue: keyValue }, function () {
refreshGirdData();
});
}
});
}
});
// 打印
$('#lr_print').on('click', function () {
$('#gridtable').jqprintTable();
});
},
// 初始化列表
initGird: function () {
$('#gridtable').lrAuthorizeJfGrid({
$('#gridtable').lrAuthorizeJfGridLei({
url: top.$.rootUrl + '/EducationalAdministration/TrainEquipmentManage/GetPageList',
headData: [
{ label: "专业部", name: "DeptNo", 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: "TrainName", width: 100, align: "left"},
{ label: "设备名称", name: "EquipmentName", width: 100, align: "left"},
{ label: "设备型号", name: "EquipmentModel", width: 100, align: "left"},
{ label: "新增", name: "AddNum", width: 100, align: "left"},
{ label: "损耗", name: "LossNum", width: 100, align: "left"},
{ label: "现存", name: "ExistNum", width: 100, align: "left"},
{ label: "设备金额", name: "EquipmentMoney", width: 100, align: "left" },
{ label: "库存", name: "Inventory", width: 100, align: "left" },
{
label: "部门", name: "DeptNo", width: 100, align: "left",
formatterAsync: function (callback, value, row, op, $cell) {
learun.clientdata.getAsync('custmerData', {
url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'classdata',
key: value,
keyId: 'id',
callback: function (_data) {
callback(_data['name']);
}
});
}
},
{ label: "实训室名称", name: "TrainName", width: 100, align: "left" },
{ label: "设备名称", name: "EquipmentName", width: 100, align: "left" },
{
label: "类别", name: "EquipmentType", width: 100, align: "left",
formatterAsync: function (callback, value, row, op, $cell) {
learun.clientdata.getAsync('dataItem', {
key: value,
code: 'AssType',
callback: function (_data) {
callback(_data.text);
}
});
}
},
{ label: "品牌", name: "Brand", width: 120, align: "left" },
{ label: "型号", name: "EquipmentModel", width: 100, align: "left" },
{ label: "参数", name: "Argument", width: 120, align: "left" },
{
label: "单位", name: "Unit", width: 100, align: "left",
formatterAsync: function (callback, value, row, op, $cell) {
learun.clientdata.getAsync('dataItem', {
key: value,
code: 'sldw',
callback: function (_data) {
callback(_data.text);
}
});
}
},
//{ label: "新增", name: "AddNum", width: 100, align: "left"},
//{ label: "损耗", name: "LossNum", width: 100, align: "left"},
//{ label: "现存", name: "ExistNum", width: 100, align: "left"},
{ label: "数量", name: "Nuantity", width: 100, align: "left", statistics: true },
{ label: "单价(元)", name: "Price", width: 100, align: "left"},
{ label: "设备金额(元)", name: "EquipmentMoney", width: 100, align: "left", statistics: true },
{
label: "管理员", name: "UserId", width: 100, align: "left",
formatterAsync: function (callback, value, row, op, $cell) {
learun.clientdata.getAsync('custmerData', {
url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'TeacherInfo',
key: value,
keyId: 'f_userid',
callback: function (_data) {
callback(_data['f_realname']);
}
});
}
},
{ label: "备注", name: "Remark", width: 100, align: "left" },
],
mainId:'Id',
isPage: true
mainId: 'Id',
isPage: true,
sidx: "CreateTime desc"
});
page.search();
},
search: function (param) {
param = param || {};
$('#gridtable').jfGridSet('reload',{ queryJson: JSON.stringify(param) });
$('#gridtable').jfGridSet('reload', { queryJson: JSON.stringify(param) });
}
};
refreshGirdData = function () {


+ 6
- 0
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StudentCompetition/StudentCompetitionEntity.cs Visa fil

@@ -109,6 +109,12 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration
/// </summary>
[Column("SEMESTER")]
public string Semester { get; set; }
/// <summary>
/// 学期
/// </summary>
[Column("ENCOURAGEMENTDEGREE")]
public string EncouragementDegree { get; set; }

#endregion

#region 扩展操作


+ 29
- 1
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/TrainEquipmentManage/TrainEquipmentManageEntity.cs Visa fil

@@ -11,7 +11,7 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration
/// 日 期:2022-08-30 10:49
/// 描 述:实训设备管理
/// </summary>
public class TrainEquipmentManageEntity
public class TrainEquipmentManageEntity
{
#region 实体成员
/// <summary>
@@ -64,6 +64,30 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration
/// </summary>
[Column("INVENTORY")]
public decimal? Inventory { get; set; }
[Column("EQUIPMENTTYPE")]
public string EquipmentType { get; set; }
[Column("BRAND")]
public string Brand { get; set; }
[Column("ARGUMENT")]
public string Argument { get; set; }
[Column("UNIT")]
public string Unit { get; set; }
[Column("NUANTITY")]
public decimal? Nuantity { get; set; }
[Column("PRICE")]
public decimal? Price { get; set; }
[Column("USERID")]
public string UserId { get; set; }
[Column("CREATETIME")]
public DateTime? CreateTime { get; set; }
[Column("CREATEUSER")]
public string CreateUser { get; set; }
[Column("UPDATETIME")]
public DateTime? UpdateTime { get; set; }
[Column("UPDATEUSER")]
public string UpdateUser { get; set; }
[Column("REMARK")]
public string Remark { get; set; }

#endregion

@@ -74,6 +98,8 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration
public void Create()
{
this.Id = Guid.NewGuid().ToString();
this.CreateTime = DateTime.Now;
this.CreateUser = LoginUserInfo.Get().userId;
}
/// <summary>
/// 编辑调用
@@ -82,6 +108,8 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration
public void Modify(string keyValue)
{
this.Id = keyValue;
this.UpdateTime = DateTime.Now;
this.UpdateUser = LoginUserInfo.Get().userId;
}
#endregion
#region 扩展字段


+ 10
- 0
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/TrainEquipmentManage/TrainEquipmentManageService.cs Visa fil

@@ -51,6 +51,16 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration
dp.Add("EquipmentName", "%" + queryParam["EquipmentName"].ToString() + "%", DbType.String);
strSql.Append(" AND t.EquipmentName Like @EquipmentName ");
}
if (!queryParam["EquipmentType"].IsEmpty())
{
dp.Add("EquipmentType", queryParam["EquipmentType"].ToString(), DbType.String);
strSql.Append(" AND t.EquipmentType = @EquipmentType ");
}
if (!queryParam["UserId"].IsEmpty())
{
dp.Add("UserId", queryParam["UserId"].ToString(), DbType.String);
strSql.Append(" AND t.UserId = @UserId ");
}
return this.BaseRepository("CollegeMIS").FindList<TrainEquipmentManageEntity>(strSql.ToString(),dp, pagination);
}
catch (Exception ex)


Laddar…
Avbryt
Spara