Bladeren bron

长阳分支中职
ndbs 1 week geleden
bovenliggende
commit
b3fb48b7e1
8 gewijzigde bestanden met toevoegingen van 102 en 50 verwijderingen
  1. +2
    -1
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/OfficeEquipment/Form.cshtml
  2. +39
    -12
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/OfficeEquipment/Form.js
  3. +2
    -2
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/OfficeEquipment/Index.cshtml
  4. +22
    -19
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/OfficeEquipment/Index.js
  5. +2
    -2
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/OfficeEquipment/IndexMy.cshtml
  6. +26
    -14
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/OfficeEquipment/IndexMy.js
  7. +4
    -0
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/OfficeEquipment/OfficeEquipmentEntity.cs
  8. +5
    -0
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/OfficeEquipment/OfficeEquipmentService.cs

+ 2
- 1
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/OfficeEquipment/Form.cshtml Bestand weergeven

@@ -6,10 +6,11 @@
<div class="col-xs-6 lr-form-item" data-table="OfficeEquipment">
<div class="lr-form-item-title">使用管理人<font face="宋体">*</font></div>
<div id="Name" isvalid="yes" checkexpession="NotNull"></div>
<input id="No" hidden="hidden"/>
</div>
<div class="col-xs-6 lr-form-item" data-table="OfficeEquipment">
<div class="lr-form-item-title">部门<font face="宋体">*</font></div>
<div id="Department" isvalid="yes" checkexpession="NotNull"></div>
<div id="Department" isvalid="yes" checkexpession="NotNull" readonly></div>
</div>
<div class="col-xs-6 lr-form-item" data-table="OfficeEquipment">
<div class="lr-form-item-title">资产编号<font face="宋体">*</font></div>


+ 39
- 12
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/OfficeEquipment/Form.js Bestand weergeven

@@ -15,16 +15,42 @@ var bootstrap = function ($, learun) {
page.initData();
},
bind: function () {
$('#Name').lrDataSourceSelect({ code: 'TeacherInfo',value: 'f_encode',text: 'f_realname' });
$('#Department').lrselect({
type: 'tree',
allowSearch: true,
url: top.$.rootUrl + '/LR_OrganizationModule/Department/GetTreeNoCheck',
param: {},
});
$('#Unit').lrDataItemSelect({ code: 'sldw', allowSearch: true });
$('#Types').lrDataItemSelect({ code: 'AssType' });
$('#Status').lrDataItemSelect({ code: 'AssState' });
$('#Department').lrDataSourceSelect({ code: 'classdata', value: 'id', text: 'name' });
$('#Name').lrGirdSelect({
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=teacheruserdata',
height: 500,
width: 400,
selectWord: 'f_realname',
value: 'f_realname',
text: 'f_realname',
headData:
[
{ label: "编号", name: "f_encode", width: 100, align: "left" },
{ label: "姓名", name: "f_realname", width: 100, align: "left" },
{
label: "部门", name: "f_departmentid", 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']);
}
});
}
},
],
select: function (item) {
////赋值
$("#Name").val(item.f_realname);
$("#No").val(item.f_encode);
$("#Department").lrselectSet(item.f_departmentid);
}
});
},
initData: function () {
if (!!keyValue) {
@@ -45,11 +71,12 @@ var bootstrap = function ($, learun) {
acceptClick = function (callBack) {
if (!$('body').lrValidform()) {
return false;
}
var postData = {
strEntity: JSON.stringify($('body').lrGetFormData())
};
$.lrSaveForm(top.$.rootUrl + '/EducationalAdministration/OfficeEquipment/SaveForm?keyValue=' + keyValue, postData, function (res) {
}
var postData = {};
var strEntity = $('body').lrGetFormData();
strEntity.Name = strEntity.No;
postData.strEntity = JSON.stringify(strEntity);
$.lrSaveForm(top.$.rootUrl + '/EducationalAdministration/OfficeEquipment/SaveForm?keyValue=' + keyValue, postData, function (res) {
// 保存成功后才回调
if (!!callBack) {
callBack();


+ 2
- 2
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/OfficeEquipment/Index.cshtml Bestand weergeven

@@ -35,8 +35,8 @@
<input id="Model" type="text" class="form-control" />
</div>
<div class="col-xs-6 lr-form-item">
<div class="lr-form-item-title">参数</div>
<input id="Argument" type="text" class="form-control" />
<div class="lr-form-item-title">使用状态</div>
<div id="Status"></div>
</div>
<div class="col-xs-6 lr-form-item">
<div class="lr-form-item-title">资产类别</div>


+ 22
- 19
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/OfficeEquipment/Index.js Bestand weergeven

@@ -18,6 +18,7 @@ var bootstrap = function ($, learun) {
}, 220, 400);
$('#Name').lrDataSourceSelect({ code: 'TeacherInfo',value: 'f_encode',text: 'f_realname' });
$('#Department').lrDataSourceSelect({ code: 'classdata',value: 'id',text: 'name' });
$('#Status').lrDataItemSelect({ code: 'AssState' });
$('#Types').lrDataItemSelect({ code: 'AssType' });
// 刷新
$('#lr_refresh').on('click', function () {
@@ -99,31 +100,21 @@ var bootstrap = function ($, learun) {
url: top.$.rootUrl + '/EducationalAdministration/OfficeEquipment/GetPageList',
headData: [
{
label: "资产类别", name: "Types", width: 100, align: "left",
label: "使用管理人", name: "Name", width: 100, align: "left",
formatterAsync: function (callback, value, row, op, $cell) {
learun.clientdata.getAsync('dataItem', {
learun.clientdata.getAsync('custmerData', {
url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'TeacherInfo',
key: value,
code: 'AssType',
keyId: 'f_encode',
callback: function (_data) {
callback(_data.text);
callback(_data['f_realname']);
}
});
}
},
{
label: "使用管理人", name: "Name", 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_encode',
callback: function (_data) {
callback(_data['f_realname']);
}
});
}},
{ label: "部门", name: "Department", width: 100, align: "left",
formatterAsync: function (callback, value, row, op,$cell) {
label: "部门", name: "Department", width: 100, align: "left",
formatterAsync: function (callback, value, row, op, $cell) {
learun.clientdata.getAsync('custmerData', {
url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'classdata',
key: value,
@@ -134,8 +125,20 @@ var bootstrap = function ($, learun) {
});
}
},
{ label: "资产编号", name: "Code", width: 100, align: "left"},
{ label: "资产名称", name: "DeviceName", width: 100, align: "left"},
{ label: "资产编号", name: "Code", width: 150, align: "left"},
{ label: "资产名称", name: "DeviceName", width: 150, align: "left" },
{
label: "资产类别", name: "Types", 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: "Description", width: 100, align: "left" },
{ label: "品牌", name: "Brand", width: 120, align: "left" },
{ label: "型号", name: "Model", width: 120, align: "left" },


+ 2
- 2
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/OfficeEquipment/IndexMy.cshtml Bestand weergeven

@@ -35,8 +35,8 @@
<input id="Model" type="text" class="form-control" />
</div>
<div class="col-xs-6 lr-form-item">
<div class="lr-form-item-title">参数</div>
<input id="Argument" type="text" class="form-control" />
<div class="lr-form-item-title">使用状态</div>
<div id="Status"></div>
</div>
<div class="col-xs-6 lr-form-item">
<div class="lr-form-item-title">资产类别</div>


+ 26
- 14
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/OfficeEquipment/IndexMy.js Bestand weergeven

@@ -18,6 +18,7 @@ var bootstrap = function ($, learun) {
}, 220, 400);
$('#Name').lrDataSourceSelect({ code: 'TeacherInfo', value: 'f_encode', text: 'f_realname' });
$('#Department').lrDataSourceSelect({ code: 'classdata', value: 'id', text: 'name' });
$('#Status').lrDataItemSelect({ code: 'AssState' });
$('#Types').lrDataItemSelect({ code: 'AssType' });
// 刷新
$('#lr_refresh').on('click', function () {
@@ -98,18 +99,6 @@ var bootstrap = function ($, learun) {
$('#gridtable').lrAuthorizeJfGridLei({
url: top.$.rootUrl + '/EducationalAdministration/OfficeEquipment/GetPageList',
headData: [
{
label: "资产类别", name: "Types", 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: "Name", width: 100, align: "left",
formatterAsync: function (callback, value, row, op, $cell) {
@@ -137,8 +126,19 @@ var bootstrap = function ($, learun) {
}
},
{ label: "资产编号", name: "Code", width: 100, align: "left" },
{ label: "资产名称", name: "DeviceName", width: 100, align: "left" },
//{ label: "配置描述", name: "Description", width: 100, align: "left" },
{ label: "资产名称", name: "DeviceName", width: 150, align: "left" },
{
label: "资产类别", name: "Types", width: 150, 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: "Model", width: 120, align: "left" },
{ label: "参数", name: "Argument", width: 120, align: "left" },
@@ -155,6 +155,18 @@ var bootstrap = function ($, learun) {
}
},
{ label: "数量", name: "Nuantity", width: 100, align: "left" },
{
label: "使用状态", name: "Status", width: 100, align: "left",
formatterAsync: function (callback, value, row, op, $cell) {
learun.clientdata.getAsync('dataItem', {
key: value,
code: 'AssState',
callback: function (_data) {
callback(_data.text);
}
});
}
},
{ label: "备注", name: "Remark", width: 100, align: "left" },
],
mainId: 'Id',


+ 4
- 0
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/OfficeEquipment/OfficeEquipmentEntity.cs Bestand weergeven

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


+ 5
- 0
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/OfficeEquipment/OfficeEquipmentService.cs Bestand weergeven

@@ -76,6 +76,11 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration
dp.Add("Brand", queryParam["Brand"].ToString(), DbType.String);
strSql.Append(" AND t.Brand = @Brand ");
}
if (!queryParam["Status"].IsEmpty())
{
dp.Add("Status", queryParam["Status"].ToString(), DbType.String);
strSql.Append(" AND t.Status = @Status ");
}
if (!LoginUserInfo.Get().isSystem)
{
if (!LoginUserInfo.Get().roleIds.Contains("5a6e22b1-2a08-4258-9964-3cb7fbb9ebee"))


Laden…
Annuleren
Opslaan