Преглед изворни кода

Merge branch 'master' of 123.57.209.16:bjquanjiang/DigitalScholl

中职版本
liangkun пре 4 година
родитељ
комит
9d723b08f6
22 измењених фајлова са 316 додато и 116 уклоњено
  1. +18
    -1
      Learun.Framework.Ultimate V7/Learun.Application.Mobile/www/pages/login/login.js
  2. +1
    -0
      Learun.Framework.Ultimate V7/Learun.Application.Mobile/www/pages/my/bindaccount/bindaccount.css
  3. +19
    -0
      Learun.Framework.Ultimate V7/Learun.Application.Mobile/www/pages/my/bindaccount/bindaccount.html
  4. +110
    -0
      Learun.Framework.Ultimate V7/Learun.Application.Mobile/www/pages/my/bindaccount/bindaccount.js
  5. +4
    -0
      Learun.Framework.Ultimate V7/Learun.Application.Mobile/www/pages/my/my.html
  6. +9
    -1
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/Ass_AssetsInfo/Form.cshtml
  7. +1
    -1
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/Ass_AssetsInfo/Index.js
  8. +9
    -3
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/Ass_AssetsInfoItem/Index.js
  9. +1
    -1
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/Ass_AssetsInfoItemApply/Form.cshtml
  10. +10
    -10
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/Ass_AssetsInfoItemApply/Form.js
  11. +1
    -5
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/Ass_AssetsOutItemApply/Form.cshtml
  12. +21
    -0
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/Ass_AssetsOutItemApply/Form.js
  13. +14
    -3
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/Ass_Receive/Form.js
  14. +4
    -0
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuSelectLessonListOfElective/QueryStuSelectResult.cshtml
  15. +12
    -4
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuSelectLessonListOfElective/QueryStuSelectResult.js
  16. +1
    -1
      Learun.Framework.Ultimate V7/Learun.Application.Web/Views/LR_Content/script/lr-clientdata.js
  17. +1
    -1
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.Excel/Import/ExcelImportBLL.cs
  18. +54
    -75
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/AssetManagementSystem/Ass_AssetsInfo/Ass_AssetsInfoService.cs
  19. +21
    -2
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/AssetManagementSystem/Ass_AssetsInfoApply/Ass_AssetsInfoApplyService.cs
  20. +1
    -1
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/AssetManagementSystem/Ass_AssetsInfoItem/Ass_AssetsInfoItemEntity.cs
  21. +2
    -0
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/AssetManagementSystem/Ass_AssetsInfoItem/Ass_AssetsInfoItemService.cs
  22. +2
    -7
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/AssetManagementSystem/Ass_Receive/Ass_ReceiveService.cs

+ 18
- 1
Learun.Framework.Ultimate V7/Learun.Application.Mobile/www/pages/login/login.js Прегледај датотеку

@@ -1,7 +1,24 @@
(function () {
var isBindAccountLogin = '';//切换账号登录
var bindUserName = '';//绑定账号
var bindUserPassword = '';//绑定账号密码

var page = {
headColor: '#ffffff',
init: function ($page) {
init: function ($page, param) {
//切换账号登录时:登录页赋值,触发登录事件;
isBindAccountLogin = param.isBindAccountLogin;
bindUserName = param.bindUserName;
bindUserPassword = param.bindUserPassword;
if (isBindAccountLogin == 1) {
$page.find('#account').val(bindUserName);
$page.find('#password').val(bindUserPassword);
var timer = setTimeout(function () {
$page.find('#loginBtn').trigger("tap");
clearTimeout(timer);
}, 3000);
}

var path = config.webapi;
learun.http.get(path + "Learun/adms/EducationalAdministration/EmpRegister/registerbutton",
{}, (res) => {


+ 1
- 0
Learun.Framework.Ultimate V7/Learun.Application.Mobile/www/pages/my/bindaccount/bindaccount.css Прегледај датотеку

@@ -0,0 +1 @@


+ 19
- 0
Learun.Framework.Ultimate V7/Learun.Application.Mobile/www/pages/my/bindaccount/bindaccount.html Прегледај датотеку

@@ -0,0 +1,19 @@
<div class="lr-page lr-EducationalAdministrationLoginUserBind-page">
<div class="lr-page-tool">
<div class="lr-tool-left">
总共<span class="lr-badge lr-badge-primary">0</span>条
</div>
<div class="lr-tool-right">
<div class="lr-tool-right-btn lr_multiple_search">
<i class="iconfont icon-searchlist"></i>
<div class="lr-tool-right-btn-content lr-form-container">
<div class="lr-form-row">
<label>绑定账号</label>
<input id="BindUserAccount" type="text">
</div>
</div>
</div>
</div>
</div>
<div class="lr-page-content" id="lr_EducationalAdministrationLoginUserBind_list"></div>
</div>

+ 110
- 0
Learun.Framework.Ultimate V7/Learun.Application.Mobile/www/pages/my/bindaccount/bindaccount.js Прегледај датотеку

@@ -0,0 +1,110 @@
/* * 版 本 Learun-ADMS-Ultimate V7.0.0 数字化智慧校园(http://www.learun.cn)
* Copyright (c) 2013-2018 北京泉江科技有限公司
* 创建人:超级管理员
* 日 期:2020-11-19 14:50
* 描 述:切换账号
*/
(function () {
var begin = '';
var end = '';
var multipleData = null;
var userinfo = null;
var page = {
grid: null,
init: function ($page) {
// 获取登录者信息
userinfo = learun.storage.get('userinfo');
begin = '';
end = '';
multipleData = null;
page.grid = $page.find('#lr_EducationalAdministrationLoginUserBind_list').lrpagination({
lclass: page.lclass,
rows: 10, // 每页行数
getData: function (param, callback) {// 获取数据 param 分页参数,callback 异步回调
param.multipleData = multipleData;
page.loadData(param, callback, $page);
},
renderData: function (_index, _item, _$item) {// 渲染数据模板
return page.rowRender(_index, _item, _$item, $page);
},
click: function (item, $item, $et) {// 列表行点击事件
if ($et.hasClass('lr-btn-danger')) {
page.btnClick(item, $item, $page);
}
else {
//page.rowClick(item, $item, $page);
}
},
btns: page.rowBtns
});
// 多条件查询
var $multiple = $page.find('.lr_multiple_search').multiplequery({
callback: function (data) {
begin = '';
end = '';
multipleData = data || {};
page.grid.reload();
}
});
},
lclass: 'lr-list',
loadData: function (param, callback, $page) {// 列表加载后台数据
var _postParam = {
pagination: {
rows: param.rows,
page: param.page,
sidx: 'CreateTime desc',
sord: 'DESC'
},
queryJson: JSON.stringify({ CreateUserId: learun.storage.get('userinfo').baseinfo.userId })
};
if (param.multipleData) {
multipleData.CreateUserId = learun.storage.get('userinfo').baseinfo.userId;
_postParam.queryJson = JSON.stringify(multipleData);
}
if (param.begin && param.end) {
_postParam.queryJson = JSON.stringify({ StartTime: param.begin, EndTime: param.end, CreateUserId: learun.storage.get('userinfo').baseinfo.userId });
}
learun.httpget(config.webapi + 'learun/EducationalAdministration/LoginUserBind/pagelist', _postParam, (data) => {
$page.find('.lr-badge').text('0');
if (data) {
$page.find('.lr-badge').text(data.records);
callback(data.rows, parseInt(data.records));
}
else {
callback([], 0);
}
});
},
rowRender: function (_index, _item, _$item, $page) {// 渲染列表行数据
_$item.addClass('lr-list-item lr-list-item-multi');
_$item.append($('<p class="lr-ellipsis"><span>绑定账号:</span></p>').dataFormatter({ value: _item.BindUserAccount }));
_$item.append($('<p class="lr-ellipsis"><span>绑定时间:</span></p>').dataFormatter({
value: _item.CreateTime,
type: 'datetime',
dateformat: 'yyyy-MM-dd hh:mm:ss'
}));
return '';
},
//rowClick: function (item, $item, $page) {// 列表行点击触发方法
// learun.nav.go({ path: 'EducationalAdministration/LoginUserBind/form', title: '详情', type: 'right', param: { keyValue: item.Id } });
//},
btnClick: function (item, $item, $page) {// 左滑按钮点击事件
//安全退出;自动登录;
learun.isOutLogin = true;
learun.storage.set('logininfo', null);
learun.nav.go({ path: 'login', isBack: false, isHead: false, param: { isBindAccountLogin: 1, bindUserName: item.BindUserAccount, bindUserPassword: item.BindUserPassword } });
if (learun.storage.get("Ip") != null && learun.storage.get("ACIp") != "") {
//Ip上网
sendToAc(learun.storage.get("ACIp"), 'logout', learun.storage.get("Ip"), userinfo.baseinfo.account, '');
}
if (learun.storage.get("Ip") != null && learun.storage.get("ACIp2") != "") {
//Ip上网
sendToAc(learun.storage.get("ACIp2"), 'logout', learun.storage.get("Ip"), userinfo.baseinfo.account, '');
}
},
rowBtns: ['<a class="lr-btn-danger">登录</a>'] // 列表行左滑按钮
};
return page;
})();

+ 4
- 0
Learun.Framework.Ultimate V7/Learun.Application.Mobile/www/pages/my/my.html Прегледај датотеку

@@ -19,6 +19,10 @@
<i class="iconfont icon-write"></i>
<a class="lr-nav-right">修改密码</a>
</div>
<div class="lr-list-item lr-list-item-icon" data-value="bindaccount">
<i class="iconfont icon-group"></i>
<a class="lr-nav-right">切换账号</a>
</div>
</div>
<div class="lr-list" style="margin-top:15px;">
<div class="lr-list-item" id="unbundweixin" style="padding-left:38px;">解绑微信</div>


+ 9
- 1
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/Ass_AssetsInfo/Form.cshtml Прегледај датотеку

@@ -4,7 +4,7 @@
}
<div class="lr-form-wrap">
<div class="col-xs-6 lr-form-item" data-table="Ass_AssetsInfo">
<div class="lr-form-item-title">资产类<font face="宋体">*</font></div>
<div class="lr-form-item-title">资产类<font face="宋体">*</font></div>
<div id="ATId" isvalid="yes" checkexpession="NotNull"></div>
</div>
<div class="col-xs-6 lr-form-item" data-table="Ass_AssetsInfo">
@@ -31,6 +31,14 @@
<div class="lr-form-item-title">生产厂家</div>
<input id="AManufacturer" type="text" class="form-control" />
</div>
<div class="col-xs-6 lr-form-item" data-table="Ass_AssetsInfo">
<div class="lr-form-item-title">用途</div>
<input id="AUse" type="text" class="form-control" />
</div>
<div class="col-xs-6 lr-form-item" data-table="Ass_AssetsInfo">
<div class="lr-form-item-title">规格</div>
<input id="ASpecification" type="text" class="form-control" />
</div>
<div class="col-xs-6 lr-form-item" data-table="Ass_AssetsInfo">
<div class="lr-form-item-title">资产来源</div>
<div id="ASource"></div>


+ 1
- 1
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/Ass_AssetsInfo/Index.js Прегледај датотеку

@@ -112,7 +112,7 @@ var bootstrap = function ($, learun) {
{ label: "资产编号", name: "ACode", width: 200, align: "left" },
{ label: "资产名称", name: "AName", width: 200, align: "left" },
{
label: "资产类", name: "ATId", width: 100, align: "left",
label: "资产类", name: "ATId", width: 100, align: "left",
formatterAsync: function (callback, value, row, op, $cell) {
learun.clientdata.getAsync('custmerData', {
url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'Ass_AssetsType',


+ 9
- 3
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/Ass_AssetsInfoItem/Index.js Прегледај датотеку

@@ -23,12 +23,18 @@ var bootstrap = function ($, learun) {
bind: function () {

// 初始化左侧树形数据lr_printBar
//$('#dataTree').lrtree({
// url: top.$.rootUrl + '/AssetManagementSystem/Ass_AssetsInfoItem/GetTree',
// nodeClick: function (item) {
// page.search({ AIAssType: item.value });
// }
//});
$('#dataTree').lrtree({
url: top.$.rootUrl + '/AssetManagementSystem/Ass_AssetsInfoItem/GetTree',
url: top.$.rootUrl + '/AssetManagementSystem/Ass_AssetsInfo/GetTree',
nodeClick: function (item) {
page.search({ AIAssType: item.value });
page.search({ AIASSClass: item.value });
}
});
});
$('#multiple_condition_query').lrMultipleQuery(function (queryJson) {
page.search(queryJson);
}, 400, 400);


+ 1
- 1
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/Ass_AssetsInfoItemApply/Form.cshtml Прегледај датотеку

@@ -59,7 +59,7 @@
</div>
<div class="col-xs-6 lr-form-item" data-table="Ass_AssetsInfoItemApply">
<div class="lr-form-item-title">数量单位</div>
<div id="AAIUnit" readonly="readonly"></div>
<div id="AAIUnit" ></div>
</div>
<div class="col-xs-6 lr-form-item" data-table="Ass_AssetsInfoItemApply">
<div class="lr-form-item-title">排序<font face="宋体">*</font></div>


+ 10
- 10
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/Ass_AssetsInfoItemApply/Form.js Прегледај датотеку

@@ -59,11 +59,11 @@ var bootstrap = function ($, learun) {
select: function (values, texts) {
if (values && values.length > 0) {
//绑定
$("#AAITId").attr("readonly", "readonly");
$("#AAICode").attr("readonly", "readonly");
$("#AAIName").attr("readonly", "readonly");
$("#AAIUnit").attr("readonly", "readonly");
$("#AAIHasDetail").attr("readonly", "readonly");
//$("#AAITId").attr("readonly", "readonly");
//$("#AAICode").attr("readonly", "readonly");
//$("#AAIName").attr("readonly", "readonly");
//$("#AAIUnit").attr("readonly", "readonly");
//$("#AAIHasDetail").attr("readonly", "readonly");
$.lrSetForm(top.$.rootUrl + '/AssetManagementSystem/Ass_AssetsInfo/GetFormData?keyValue=' + values[0], function (data) {
data = data.Ass_AssetsInfo;
$('#AAITId').lrselectSet(data.ATId);
@@ -80,11 +80,11 @@ var bootstrap = function ($, learun) {
},
unknowselect: function () {
$("#AAOldCode").find('span').text("");
$("#AAITId").removeAttr("readonly");
$("#AAICode").removeAttr("readonly");
$("#AAIName").removeAttr("readonly");
$("#AAIUnit").removeAttr("readonly");
$("#AAIHasDetail").removeAttr("readonly");
//$("#AAITId").removeAttr("readonly");
//$("#AAICode").removeAttr("readonly");
//$("#AAIName").removeAttr("readonly");
//$("#AAIUnit").removeAttr("readonly");
//$("#AAIHasDetail").removeAttr("readonly");
$('#AAITId').lrselectSet("");
$('#AAICode').val("");
$('#AAIName').val("");


+ 1
- 5
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/Ass_AssetsOutItemApply/Form.cshtml Прегледај датотеку

@@ -47,7 +47,7 @@
</div>
<div class="col-xs-6 lr-form-item" data-table="Ass_AssetsOutItemApply">
<div class="lr-form-item-title">用途</div>
<input id="AOIUse" type="text" class="form-control" readonly="readonly" />
<input id="AOIUse" type="text" class="form-control" />
</div>
<div class="col-xs-6 lr-form-item" data-table="Ass_AssetsOutItemApply">
<div class="lr-form-item-title">原使用部门</div>
@@ -73,10 +73,6 @@
<div class="lr-form-item-title">新库存位置<font face="宋体">*</font></div>
<div id="AOINewStorageId" isvalid="yes" checkexpession="NotNull" ></div>
</div>
<div class="col-xs-6 lr-form-item" data-table="Ass_AssetsOutItemApply">
<div class="lr-form-item-title">用途</div>
<input id="AOIUse" type="text" class="form-control" readonly="readonly" />
</div>
<div class="col-xs-12 lr-form-item" data-table="Ass_AssetsOutItemApply">
<div class="lr-form-item-title">数量单位</div>
<div id="AOIUnit" readonly="readonly"></div>


+ 21
- 0
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/Ass_AssetsOutItemApply/Form.js Прегледај датотеку

@@ -67,6 +67,27 @@ var bootstrap = function ($, learun) {
grid: [
{ label: '资产编号', name: 'aicodenumjy', width: 150, align: 'left' },
{ label: '资产名称', name: 'aiassname', width: 150, align: 'left' },
{
label: '使用部门', name: 'aidepartment', width: 150, align: 'left', formatterAsync: function (callback, value, row, op, $cell) {
learun.clientdata.getAsync('department', {
key: value,
callback: function (_data) {
callback(_data.name);
}
});
}
},
{
label: '使用人员', name: 'aiusepeople', width: 150, align: 'left',
formatterAsync: function (callback, value, row, op, $cell) {
learun.clientdata.getAsync('user', {
key: value,
callback: function (_data) {
callback(_data.name);
}
});
}
},
{
label: '所在库房', name: 'aiistorageid', width: 100, align: 'left', formatterAsync: function (callback, value, row, op, $cell) {
learun.clientdata.getAsync('custmerData', {


+ 14
- 3
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/Ass_Receive/Form.js Прегледај датотеку

@@ -39,7 +39,10 @@ var bootstrap = function ($, learun) {

},
{
label: "数量", name: "ANum", width: 100, align: "left",
label: "库存数量", name: "ACNum", width: 100, align: "left",
},
{
label: "领取数量", name: "ANum", width: 100, align: "left",
edit: {
type: 'input',
inputType: 'number',
@@ -111,6 +114,10 @@ var bootstrap = function ($, learun) {
$('.jfgrid-data-cell[colname="AID"][rowIndex="' + rowIndex + '"]').attr('title', data.AId).html(data.AId);
$('#Ass_ReceiveItem')[0].dfop.running.rowdata[rowIndex]['jfgridRowData']['AID'] = data.AId;

$('jfgrid_edit_Ass_ReceiveItem_' + 'ACNum').val(data.AId);
$('.jfgrid-data-cell[colname="ACNum"][rowIndex="' + rowIndex + '"]').attr('title', data.AStock).html(data.AStock);
$('#Ass_ReceiveItem')[0].dfop.running.rowdata[rowIndex]['jfgridRowData']['ACNum'] = data.AStock;

});
}
},
@@ -151,7 +158,7 @@ var bootstrap = function ($, learun) {
}
});
}
callback && callback();
callback && callback();
}
// 验证数据是否填写完整
validForm = function () {
@@ -174,7 +181,11 @@ var bootstrap = function ($, learun) {
$.each(itemList, function (i, item) {
if (item.ANum <= 0) {
learun.alert.warning("请填写<" + item.AName + ">的申请数量");
num++
num++;
}
if (item.ANum > item.ACNum) {
learun.alert.warning("领取数量不能大于库存数量!");
num++;
}
})
if (num > 0) {


+ 4
- 0
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuSelectLessonListOfElective/QueryStuSelectResult.cshtml Прегледај датотеку

@@ -34,6 +34,10 @@
<div class="lr-form-item-title">班级</div>
<div id="ClassNo"></div>
</div>
<div class="col-xs-12 lr-form-item">
<div class="lr-form-item-title">选修课程</div>
<div id="LessonNo"></div>
</div>
<div class="col-xs-6 lr-form-item">
<div class="lr-form-item-title">选课状态</div>
<div id="ElectiveSelectStatus"></div>


+ 12
- 4
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuSelectLessonListOfElective/QueryStuSelectResult.js Прегледај датотеку

@@ -24,7 +24,7 @@ var bootstrap = function ($, learun) {
return;
}
page.search(queryJson);
}, 250, 400);
}, 300, 400);
$('#AcademicYearNo').lrselect({
placeholder: "请选择学年",
allowSearch: true,
@@ -46,6 +46,13 @@ var bootstrap = function ($, learun) {
$('#DeptNo').lrDataSourceSelect({ code: 'CdDeptInfo', value: 'deptno', text: 'deptname' });
$('#MajorNo').lrDataSourceSelect({ code: 'CdMajorInfo', value: 'majorno', text: 'majorname' });
$('#ClassNo').lrDataSourceSelect({ code: 'bjsj', value: 'classno', text: 'classname' });
$('#LessonNo').lrselect({
allowSearch: true,
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=LessonInfo',
param: { strWhere: "1=1 AND LessonSortNo='2' " },
value: "lessonno",
text: "lessonname"
});
// 刷新
$('#lr_refresh').on('click', function () {
location.reload();
@@ -174,11 +181,12 @@ var bootstrap = function ($, learun) {
{
label: "上课节次", name: "LessonSection", width: 150, align: "left",
formatter: function (cellvalue, row) {
if (cellvalue != "") {
if (cellvalue.indexOf(',') == -1)
if (cellvalue != "" && cellvalue != undefined && cellvalue != null) {
if (cellvalue.indexOf(',') == -1) {
return "星期" + weekChina[cellvalue.slice(0, 1) - 1] + "第" + cellvalue.slice(1) + "节";
else
} else {
return "星期" + weekChina[cellvalue.slice(0, 1) - 1] + "第" + cellvalue.slice(1, 2) + "、" + cellvalue.slice(4) + "节";
}
}
}
},


+ 1
- 1
Learun.Framework.Ultimate V7/Learun.Application.Web/Views/LR_Content/script/lr-clientdata.js Прегледај датотеку

@@ -301,7 +301,7 @@
}
else {
var data = storage.get("userData").data || {};
var keys = op.key.split(',');
var keys = (op.key || '').split(',');
var array=new Array();
if (keys.length > 1) {
$.each(keys,


+ 1
- 1
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.Excel/Import/ExcelImportBLL.cs Прегледај датотеку

@@ -99,7 +99,7 @@ namespace Learun.Application.Excel
{
try
{
return excelImportService.GetEntity(keyValue);
return excelImportService.GetEntity(keyValue);//2
}
catch (Exception ex)
{


+ 54
- 75
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/AssetManagementSystem/Ass_AssetsInfo/Ass_AssetsInfoService.cs Прегледај датотеку

@@ -273,94 +273,39 @@ namespace Learun.Application.TwoDevelopment.AssetManagementSystem
db.Delete<Ass_AssetsChangeItemEntity>(m => m.AIId == Ass_AssetsInfoItem.AId);
db.Delete(Ass_AssetsInfoItem);
}
//新增明细
if (entity.HasDetail == true)
{
if (entity.AStock > 0)
{
for (int i = 0; i < entity.AStock; i++)
{
var Ass_AssetsInfoItem = new Ass_AssetsInfoItemEntity();
Ass_AssetsInfoItem.Create();
Ass_AssetsInfoItem.AId = entity.AId;
Ass_AssetsInfoItem.AICodeNum = i + 1;
Ass_AssetsInfoItem.AICode = entity.ACode + "_" + Ass_AssetsInfoItem.AICodeNum;
Ass_AssetsInfoItem.AIIStorageId = entity.AIIStorageId;
Ass_AssetsInfoItem.AIIStoragePosition = entity.AIIStoragePosition;
Ass_AssetsInfoItem.AIIsInStorage = true;
Ass_AssetsInfoItem.AISpecification = entity.ASpecification;
Ass_AssetsInfoItem.AIUse = entity.AUse;
db.Insert(Ass_AssetsInfoItem);
}
}
else
{
var Ass_AssetsInfoItem = new Ass_AssetsInfoItemEntity();
Ass_AssetsInfoItem.Create();
Ass_AssetsInfoItem.AId = entity.AId;
Ass_AssetsInfoItem.AICodeNum = 1;
Ass_AssetsInfoItem.AICode = entity.ACode + "_" + Ass_AssetsInfoItem.AICodeNum;
Ass_AssetsInfoItem.AIIStorageId = entity.AIIStorageId;
Ass_AssetsInfoItem.AIIStoragePosition = entity.AIIStoragePosition;
Ass_AssetsInfoItem.AIIsInStorage = false;
Ass_AssetsInfoItem.AISpecification = entity.ASpecification;
Ass_AssetsInfoItem.AIUse = entity.AUse;
db.Insert(Ass_AssetsInfoItem);
}
}
else
{
var Ass_AssetsInfoItem = new Ass_AssetsInfoItemEntity();
Ass_AssetsInfoItem.Create();
Ass_AssetsInfoItem.AId = entity.AId;
Ass_AssetsInfoItem.AICodeNum = 1;
Ass_AssetsInfoItem.AICode = entity.ACode + "_" + Ass_AssetsInfoItem.AICodeNum;
Ass_AssetsInfoItem.AIIStorageId = entity.AIIStorageId;
Ass_AssetsInfoItem.AIIStoragePosition = entity.AIIStoragePosition;
Ass_AssetsInfoItem.AIIsInStorage = entity.AStock > 0;
Ass_AssetsInfoItem.AISpecification = entity.ASpecification;
Ass_AssetsInfoItem.AIUse = entity.AUse;
db.Insert(Ass_AssetsInfoItem);
}

}
else
{
entity.Create();
db.Insert(entity);
if (entity.HasDetail == true)
}

//新增明细
if (entity.HasDetail == true)
{
if (entity.AStock > 0)
{
if (entity.AStock > 0)
{
for (int i = 0; i < entity.AStock; i++)
{
var Ass_AssetsInfoItem = new Ass_AssetsInfoItemEntity();
Ass_AssetsInfoItem.Create();
Ass_AssetsInfoItem.AId = entity.AId;
Ass_AssetsInfoItem.AIASSName = entity.AName;
Ass_AssetsInfoItem.AICodeNumJY = entity.ACode;
Ass_AssetsInfoItem.AICodeNum = i + 1;
Ass_AssetsInfoItem.AICode = entity.ACode + "_" + Ass_AssetsInfoItem.AICodeNum;
Ass_AssetsInfoItem.AIIStorageId = entity.AIIStorageId;
Ass_AssetsInfoItem.AIIStoragePosition = entity.AIIStoragePosition;
Ass_AssetsInfoItem.AIIsInStorage = true;
Ass_AssetsInfoItem.AISpecification = entity.ASpecification;
Ass_AssetsInfoItem.AIAssType = entity.AAssType;
Ass_AssetsInfoItem.AIUse = entity.AUse;
db.Insert(Ass_AssetsInfoItem);
}
}
else
for (int i = 0; i < entity.AStock; i++)
{
var Ass_AssetsInfoItem = new Ass_AssetsInfoItemEntity();
Ass_AssetsInfoItem.Create();
Ass_AssetsInfoItem.AId = entity.AId;
Ass_AssetsInfoItem.AIASSName = entity.AName;
Ass_AssetsInfoItem.AICodeNumJY = entity.ACode;
Ass_AssetsInfoItem.AICodeNum = 1;
Ass_AssetsInfoItem.AIAssValue = entity.APrice;//价值
Ass_AssetsInfoItem.AIUnits = entity.AUnit;//单位
Ass_AssetsInfoItem.AISpecificationtype = entity.AModel;//型号
Ass_AssetsInfoItem.AIASSClass = entity.ATId;//类别
Ass_AssetsInfoItem.AIManufacturer = entity.AManufacturer;//厂家
Ass_AssetsInfoItem.AIUse = entity.AUse;//用途
Ass_AssetsInfoItem.AISpecification = entity.ASpecification;//规格
Ass_AssetsInfoItem.AIAssType = entity.AAssType;//属性
Ass_AssetsInfoItem.AICodeNum = i + 1;
Ass_AssetsInfoItem.AICode = entity.ACode + "_" + Ass_AssetsInfoItem.AICodeNum;
Ass_AssetsInfoItem.AICodeNumJY = entity.ACode + "_" + Ass_AssetsInfoItem.AICodeNum;
Ass_AssetsInfoItem.AIIStorageId = entity.AIIStorageId;
Ass_AssetsInfoItem.AIIStoragePosition = entity.AIIStoragePosition;
Ass_AssetsInfoItem.AIIsInStorage = false;
Ass_AssetsInfoItem.AIIsInStorage = true;
Ass_AssetsInfoItem.AISpecification = entity.ASpecification;
Ass_AssetsInfoItem.AIUse = entity.AUse;
db.Insert(Ass_AssetsInfoItem);
@@ -371,16 +316,50 @@ namespace Learun.Application.TwoDevelopment.AssetManagementSystem
var Ass_AssetsInfoItem = new Ass_AssetsInfoItemEntity();
Ass_AssetsInfoItem.Create();
Ass_AssetsInfoItem.AId = entity.AId;
Ass_AssetsInfoItem.AIASSName = entity.AName;
Ass_AssetsInfoItem.AIAssValue = entity.APrice;
Ass_AssetsInfoItem.AIUnits = entity.AUnit;//单位
Ass_AssetsInfoItem.AISpecificationtype = entity.AModel;//型号
Ass_AssetsInfoItem.AIASSClass = entity.ATId;//类别
Ass_AssetsInfoItem.AIManufacturer = entity.AManufacturer;//厂家
Ass_AssetsInfoItem.AIUse = entity.AUse;//用途
Ass_AssetsInfoItem.AISpecification = entity.ASpecification;//规格
Ass_AssetsInfoItem.AIAssType = entity.AAssType;//属性
Ass_AssetsInfoItem.AICodeNum = 1;
Ass_AssetsInfoItem.AICode = entity.ACode + "_" + Ass_AssetsInfoItem.AICodeNum;
Ass_AssetsInfoItem.AICodeNumJY = entity.ACode + "_" + Ass_AssetsInfoItem.AICodeNum;
Ass_AssetsInfoItem.AIIStorageId = entity.AIIStorageId;
Ass_AssetsInfoItem.AIIStoragePosition = entity.AIIStoragePosition;
Ass_AssetsInfoItem.AIIsInStorage = entity.AStock > 0;
Ass_AssetsInfoItem.AIIsInStorage = false;
Ass_AssetsInfoItem.AISpecification = entity.ASpecification;
Ass_AssetsInfoItem.AIUse = entity.AUse;
db.Insert(Ass_AssetsInfoItem);
}
}
else
{
var Ass_AssetsInfoItem = new Ass_AssetsInfoItemEntity();
Ass_AssetsInfoItem.Create();
Ass_AssetsInfoItem.AId = entity.AId;
Ass_AssetsInfoItem.AIASSName = entity.AName;
Ass_AssetsInfoItem.AIAssValue = entity.APrice;
Ass_AssetsInfoItem.AIUnits = entity.AUnit;//单位
Ass_AssetsInfoItem.AISpecificationtype = entity.AModel;//型号
Ass_AssetsInfoItem.AIASSClass = entity.ATId;//类别
Ass_AssetsInfoItem.AIManufacturer = entity.AManufacturer;//厂家
Ass_AssetsInfoItem.AIUse = entity.AUse;//用途
Ass_AssetsInfoItem.AISpecification = entity.ASpecification;//规格
Ass_AssetsInfoItem.AIAssType = entity.AAssType;//属性
Ass_AssetsInfoItem.AICodeNum = 1;
Ass_AssetsInfoItem.AICode = entity.ACode + "_" + Ass_AssetsInfoItem.AICodeNum;
Ass_AssetsInfoItem.AICodeNumJY = entity.ACode + "_" + Ass_AssetsInfoItem.AICodeNum;
Ass_AssetsInfoItem.AIIStorageId = entity.AIIStorageId;
Ass_AssetsInfoItem.AIIStoragePosition = entity.AIIStoragePosition;
Ass_AssetsInfoItem.AIIsInStorage = entity.AStock > 0;
Ass_AssetsInfoItem.AISpecification = entity.ASpecification;
Ass_AssetsInfoItem.AIUse = entity.AUse;
db.Insert(Ass_AssetsInfoItem);
}
db.Commit();
}
catch (Exception ex)


+ 21
- 2
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/AssetManagementSystem/Ass_AssetsInfoApply/Ass_AssetsInfoApplyService.cs Прегледај датотеку

@@ -317,14 +317,21 @@ namespace Learun.Application.TwoDevelopment.AssetManagementSystem
insertassinfoitem.AId = assinfoitem.AId;
insertassinfoitem.AICodeNum = Ass_AssetsInfoItemMaxNum + 1 + i;
insertassinfoitem.AICode = assinfoitem.ACode + "_" + insertassinfoitem.AICodeNum.ToString();
insertassinfoitem.AICodeNumJY = assinfoitem.ACode + "_" + insertassinfoitem.AICodeNum.ToString();
insertassinfoitem.AICodeNumJY = assinfoitem.ACode + "_" + insertassinfoitem.AICodeNum.ToString();//金隅编号
insertassinfoitem.AIAssValue = assinfoitem.APrice;//价值
insertassinfoitem.AIUnits = assinfoitem.AUnit;//单位
insertassinfoitem.AISpecificationtype = assinfoitem.AModel;//型号
insertassinfoitem.AIManufacturer = assinfoitem.AManufacturer;//厂家
insertassinfoitem.AIUse = assinfoitem.AUse;//用途
insertassinfoitem.AISpecification = assinfoitem.ASpecification;//规格

insertassinfoitem.AIIStorageId = assitemapp.AAIStorageId;
insertassinfoitem.AIASSName = assitemapp.AAIName;
insertassinfoitem.AIIStoragePosition = assitemapp.AAIStoragePosition;
insertassinfoitem.AIIsInStorage = true;
insertassinfoitem.AISpecification = assitemapp.AAISpecification;
insertassinfoitem.AIAssType = assinfoapp.AAAssType;
insertassinfoitem.AIASSClass = assinfoitem.ATId;
insertassinfoitem.AIASSClass = assinfoitem.ATId;//类别
insertassinfoitem.AIUse = assitemapp.AAIUse;
db.Insert(insertassinfoitem);
//出入库明细表
@@ -417,6 +424,12 @@ namespace Learun.Application.TwoDevelopment.AssetManagementSystem
insertassinfoitem.AICodeNum = i + 1;
insertassinfoitem.AICode = insertAss_AssetsInfo.ACode + "_" + insertassinfoitem.AICodeNum.ToString();
insertassinfoitem.AICodeNumJY = insertAss_AssetsInfo.ACode + "_" + insertassinfoitem.AICodeNum.ToString();
insertassinfoitem.AIAssValue = assinfoitem.APrice;//价值
insertassinfoitem.AIUnits = assinfoitem.AUnit;//单位
insertassinfoitem.AISpecificationtype = assinfoitem.AModel;//型号
insertassinfoitem.AIManufacturer = assinfoitem.AManufacturer;//厂家
insertassinfoitem.AIUse = assinfoitem.AUse;//用途
insertassinfoitem.AISpecification = assinfoitem.ASpecification;//规格
insertassinfoitem.AIASSName = assitemapp.AAIName;
insertassinfoitem.AIIStorageId = assitemapp.AAIStorageId;
insertassinfoitem.AIAssType = assinfoapp.AAAssType;
@@ -474,6 +487,12 @@ namespace Learun.Application.TwoDevelopment.AssetManagementSystem
insertassinfoitem.AICodeNum = 1;
insertassinfoitem.AICode = insertAss_AssetsInfo.ACode + "_" + insertassinfoitem.AICodeNum.ToString();
insertassinfoitem.AICodeNumJY = insertAss_AssetsInfo.ACode + "_" + insertassinfoitem.AICodeNum.ToString();
insertassinfoitem.AIAssValue = assinfoitem.APrice;//价值
insertassinfoitem.AIUnits = assinfoitem.AUnit;//单位
insertassinfoitem.AISpecificationtype = assinfoitem.AModel;//型号
insertassinfoitem.AIManufacturer = assinfoitem.AManufacturer;//厂家
insertassinfoitem.AIUse = assinfoitem.AUse;//用途
insertassinfoitem.AISpecification = assinfoitem.ASpecification;//规格
insertassinfoitem.AIASSName = assitemapp.AAIName;
insertassinfoitem.AIIStorageId = assitemapp.AAIStorageId;
insertassinfoitem.AIAssType = assinfoapp.AAAssType;


+ 1
- 1
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/AssetManagementSystem/Ass_AssetsInfoItem/Ass_AssetsInfoItemEntity.cs Прегледај датотеку

@@ -211,7 +211,7 @@ namespace Learun.Application.TwoDevelopment.AssetManagementSystem
public string AIUse { get; set; }

/// <summary>
/// 资产类别
/// 资产属性
/// </summary>
[Column("AIASSTYPE")]
public int? AIAssType { get; set; }


+ 2
- 0
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/AssetManagementSystem/Ass_AssetsInfoItem/Ass_AssetsInfoItemService.cs Прегледај датотеку

@@ -183,6 +183,8 @@ namespace Learun.Application.TwoDevelopment.AssetManagementSystem
a.AIIStoragePosition,
a.AIIsInStorage,
a.AICodeNumJY,
a.AIUsePeople,
a.AIDepartment,
a.AIId,
a.AICode,
a.AIASSName,


+ 2
- 7
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/AssetManagementSystem/Ass_Receive/Ass_ReceiveService.cs Прегледај датотеку

@@ -217,15 +217,10 @@ namespace Learun.Application.TwoDevelopment.AssetManagementSystem
if (num > 0)
{
var assInfoEntity = db.FindEntity<Ass_AssetsInfoEntity>(a => a.AId == item.AID);
if (assInfoEntity.AStock > num)
if (assInfoEntity.AStock >= num)
{
assInfoEntity.AStock = assInfoEntity.AStock - num;
var listAssInfoItemList =
db.FindList<Ass_AssetsInfoItemEntity>(a => a.AId == item.AID).Take(2);
foreach (var assInfoItem in listAssInfoItemList)
{
db.Delete(assInfoItem);
}
db.Update(assInfoEntity);
}
}



Loading…
Откажи
Сачувај