|
- using Learun.Util;
- using System;
- using System.Data;
- using System.Collections.Generic;
-
- namespace Learun.Application.TwoDevelopment.AssetManagementSystem
- {
- /// <summary>
- /// 版 本 Learun-ADMS-Ultimate V7.0.0 力软敏捷开发框架
- /// Copyright (c) 2013-2018 上海力软信息技术有限公司
- /// 创 建:超级管理员
- /// 日 期:2019-09-11 10:35
- /// 描 述:资产报废
- /// </summary>
- public class AssScrapBLL : AssScrapIBLL
- {
- private AssScrapService assScrapService = new AssScrapService();
-
- #region 获取数据
-
- /// <summary>
- /// 获取页面显示列表数据
- /// <summary>
- /// <param name="queryJson">查询参数</param>
- /// <returns></returns>
- public IEnumerable<Ass_ScrapEntity> GetPageList(Pagination pagination, string queryJson)
- {
- try
- {
- return assScrapService.GetPageList(pagination, queryJson);
- }
- catch (Exception ex)
- {
- if (ex is ExceptionEx)
- {
- throw;
- }
- else
- {
- throw ExceptionEx.ThrowBusinessException(ex);
- }
- }
- }
-
- /// <summary>
- /// 获取Ass_Scrap表实体数据
- /// <param name="keyValue">主键</param>
- /// <summary>
- /// <returns></returns>
- public Ass_ScrapEntity GetAss_ScrapEntity(string keyValue)
- {
- try
- {
- return assScrapService.GetAss_ScrapEntity(keyValue);
- }
- catch (Exception ex)
- {
- if (ex is ExceptionEx)
- {
- throw;
- }
- else
- {
- throw ExceptionEx.ThrowBusinessException(ex);
- }
- }
- }
-
- /// <summary>
- /// 获取主表实体数据
- /// <param name="processId">流程实例ID</param>
- /// <summary>
- /// <returns></returns>
- public Ass_ScrapEntity GetEntityByProcessId(string processId)
- {
- try
- {
- return assScrapService.GetEntityByProcessId(processId);
- }
- catch (Exception ex)
- {
- if (ex is ExceptionEx)
- {
- throw;
- }
- else
- {
- throw ExceptionEx.ThrowBusinessException(ex);
- }
- }
- }
-
- #endregion
-
- #region 提交数据
-
- /// <summary>
- /// 删除实体数据
- /// <param name="keyValue">主键</param>
- /// <summary>
- /// <returns></returns>
- public void DeleteEntity(string keyValue)
- {
- try
- {
- assScrapService.DeleteEntity(keyValue);
- }
- catch (Exception ex)
- {
- if (ex is ExceptionEx)
- {
- throw;
- }
- else
- {
- throw ExceptionEx.ThrowBusinessException(ex);
- }
- }
- }
-
- /// <summary>
- /// 保存实体数据(新增、修改)
- /// <param name="keyValue">主键</param>
- /// <summary>
- /// <returns></returns>
- public void SaveEntity(string keyValue, Ass_ScrapEntity entity,List<Ass_ScrapItemEntity> list)
- {
- try
- {
- assScrapService.SaveEntity(keyValue, entity,list);
- }
- catch (Exception ex)
- {
- if (ex is ExceptionEx)
- {
- throw;
- }
- else
- {
- throw ExceptionEx.ThrowBusinessException(ex);
- }
- }
- }
-
- #endregion
-
- #region 扩展数据
-
-
- /// <summary>
- /// 提交报废申请单
- /// </summary>
- /// <param name="keyValue">报废申请表主键</param>
- /// <param name="pastatus">审核状态</param>
- /// <param name="processId">流程Id</param>
- /// <returns></returns>
- public void ModifyStatus(string keyValue, int pastatus, string processId)
- {
- try
- {
- assScrapService.ModifyStatus(keyValue, pastatus, processId);
- }
- catch (Exception ex)
- {
- if (ex is ExceptionEx)
- {
- throw;
- }
- else
- {
- throw ExceptionEx.ThrowBusinessException(ex);
- }
- }
- }
-
-
-
-
- /// <summary>
- /// 修改采购申请表的审核状态
- /// </summary>
- /// <param name="pastatus">审核状态</param>
- /// <param name="processId">流程Id</param>
- public void ModifyStatusByProcessId(int pastatus, string processId)
- {
- try
- {
- assScrapService.ModifyStatusByProcessId(pastatus, processId);
- }
- catch (Exception ex)
- {
- if (ex is ExceptionEx)
- {
- throw;
- }
- else
- {
- throw ExceptionEx.ThrowBusinessException(ex);
- }
- }
- }
-
-
-
- #endregion
- }
- }
|