已添加28个文件
已重命名2个文件
已修改15个文件
¶Ô±ÈÐÂÎļþ |
| | |
| | | namespace CMS.Plugin.PipeLineLems.Application.Contracts.Dtos.CallMaterialOrder; |
| | | |
| | | /// <summary> |
| | | /// 嫿å表åå»ºåæ°å¯¹è±¡ |
| | | /// </summary> |
| | | public class CallMaterialOrderCreateDto : CallMaterialOrderCreateOrUpdateDtoBase |
| | | { |
| | | /// <summary> |
| | | /// æåº |
| | | /// </summary> |
| | | public virtual int? Sort { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ¯å¦ç¦ç¨ |
| | | /// </summary> |
| | | public bool? IsDisabled { get; set; } = false; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | using CMS.Plugin.PipeLineLems.Domain.Shared.Enums; |
| | | using System; |
| | | using Volo.Abp.Application.Dtos; |
| | | |
| | | namespace CMS.Plugin.PipeLineLems.Application.Contracts.Dtos.CallMaterialOrder; |
| | | |
| | | /// <summary> |
| | | /// 嫿å表åå»ºææ´æ°åºç±» |
| | | /// </summary> |
| | | public abstract class CallMaterialOrderCreateOrUpdateDtoBase : ExtensibleEntityDto |
| | | { |
| | | /// <summary> |
| | | /// åææ è¯ |
| | | /// </summary> |
| | | public string DataIdentifier { get; set; } |
| | | |
| | | /// <summary> |
| | | /// åæåå· |
| | | /// </summary> |
| | | public string? MaterialMode { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å«æç¶æ |
| | | /// </summary> |
| | | public CallMaterialStatusEnum CallMaterialStatus { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 嫿æ°é |
| | | /// </summary> |
| | | public int Quantity { get; set; } |
| | | |
| | | /// <summary> |
| | | /// WMSè¿åç»æ |
| | | /// </summary> |
| | | public string? WmsRetResult { get; set; } |
| | | |
| | | /// <summary> |
| | | /// WMSä»»å¡å· |
| | | /// </summary> |
| | | public string? WmsTaskNo { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å建人ID |
| | | /// </summary> |
| | | public string? CreatorId { get; set; } |
| | | |
| | | /// <summary> |
| | | /// ä¿®æ¹äººID |
| | | /// </summary> |
| | | public string? LastModifierId { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å 餿¶é´ |
| | | /// </summary> |
| | | public DateTime? DeletionTime { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æä½å¤æ³¨ |
| | | /// </summary> |
| | | public string? OperationRemark { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å é¤å¤æ³¨ |
| | | /// </summary> |
| | | public string? DeleteRemark { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æåº |
| | | /// </summary> |
| | | public int Sort { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 夿³¨ |
| | | /// </summary> |
| | | public string? Remark { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ¯å¦ç¦ç¨ |
| | | /// </summary> |
| | | public bool? IsDisabled { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ©å±å段1 |
| | | /// </summary> |
| | | public string? ExtraField1 { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ©å±å段2 |
| | | /// </summary> |
| | | public string? ExtraField2 { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ©å±å段3 |
| | | /// </summary> |
| | | public string? ExtraField3 { get; set; } |
| | | |
| | | |
| | | |
| | | /// <summary> |
| | | /// Initializes a new instance of the <see cref="CallMaterialOrderCreateOrUpdateDtoBase"/> class. |
| | | /// </summary> |
| | | public CallMaterialOrderCreateOrUpdateDtoBase() : base(false) |
| | | { |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | using CMS.Plugin.PipeLineLems.Domain.Shared.Enums; |
| | | using CmsQueryExtensions; |
| | | using Volo.Abp.Application.Dtos; |
| | | using Volo.Abp.Data; |
| | | using Volo.Abp.Domain.Entities; |
| | | |
| | | |
| | | namespace CMS.Plugin.PipeLineLems.Application.Contracts.Dtos.CallMaterialOrder; |
| | | |
| | | /// <summary> |
| | | /// 嫿åè¡¨æ°æ®åæ°å¯¹è±¡ |
| | | /// </summary> |
| | | public class CallMaterialOrderDto: ExtensibleEntityDto<Guid>, IHasConcurrencyStamp |
| | | { |
| | | /// <summary> |
| | | /// åææ è¯ |
| | | /// </summary> |
| | | public string DataIdentifier { get; set; } |
| | | |
| | | /// <summary> |
| | | /// åæåå· |
| | | /// </summary> |
| | | public string? MaterialMode { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å«æç¶æ |
| | | /// </summary> |
| | | public CallMaterialStatusEnum CallMaterialStatus { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å«æç¶æ |
| | | /// </summary> |
| | | public string CallMaterialStatusDesc |
| | | { |
| | | get |
| | | { |
| | | return GetEnumDescriptionUtil.GetEnumDescription(CallMaterialStatus); |
| | | } |
| | | } |
| | | /// <summary> |
| | | /// 嫿æ°é |
| | | /// </summary> |
| | | public int Quantity { get; set; } |
| | | |
| | | /// <summary> |
| | | /// WMSè¿åç»æ |
| | | /// </summary> |
| | | public string? WmsRetResult { get; set; } |
| | | |
| | | /// <summary> |
| | | /// WMSä»»å¡å· |
| | | /// </summary> |
| | | public string? WmsTaskNo { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ©å±å±æ§ |
| | | /// </summary> |
| | | public ExtraPropertyDictionary? ExtraProperties { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å¹¶åæ³ |
| | | /// </summary> |
| | | public string? ConcurrencyStamp { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å建æ¶é´ |
| | | /// </summary> |
| | | public DateTime CreationTime { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å建人ID |
| | | /// </summary> |
| | | public string? CreatorId { get; set; } |
| | | |
| | | /// <summary> |
| | | /// ä¿®æ¹æ¶é´ |
| | | /// </summary> |
| | | public DateTime? LastModificationTime { get; set; } |
| | | |
| | | /// <summary> |
| | | /// ä¿®æ¹äººID |
| | | /// </summary> |
| | | public string? LastModifierId { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ¯å¦å é¤ |
| | | /// </summary> |
| | | public bool IsDeleted { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å é¤äººID |
| | | /// </summary> |
| | | public string? DeleterId { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å 餿¶é´ |
| | | /// </summary> |
| | | public DateTime? DeletionTime { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å建人 |
| | | /// </summary> |
| | | public string? CreatorName { get; set; } |
| | | |
| | | /// <summary> |
| | | /// ä¿®æ¹äºº |
| | | /// </summary> |
| | | public string? LastModifierName { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æä½å¤æ³¨ |
| | | /// </summary> |
| | | public string? OperationRemark { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å é¤å¤æ³¨ |
| | | /// </summary> |
| | | public string? DeleteRemark { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æåº |
| | | /// </summary> |
| | | public int Sort { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 夿³¨ |
| | | /// </summary> |
| | | public string? Remark { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ¯å¦ç¦ç¨ |
| | | /// </summary> |
| | | public bool? IsDisabled { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ©å±å段1 |
| | | /// </summary> |
| | | public string? ExtraField1 { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ©å±å段2 |
| | | /// </summary> |
| | | public string? ExtraField2 { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ©å±å段3 |
| | | /// </summary> |
| | | public string? ExtraField3 { get; set; } |
| | | |
| | | |
| | | |
| | | /// <summary> |
| | | /// Gets the export data. |
| | | /// </summary> |
| | | /// <returns></returns> |
| | | public Dictionary<string, object> GetExportData() |
| | | { |
| | | var exportData = new Dictionary<string, object>(); |
| | | foreach (var property in this.GetType().GetProperties()) |
| | | { |
| | | exportData.Add(property.Name, property.GetValue(this)); |
| | | } |
| | | |
| | | return exportData; |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | using MiniExcelLibs.Attributes; |
| | | using System.ComponentModel.DataAnnotations; |
| | | using System; |
| | | using System.ComponentModel; |
| | | using CMS.Plugin.PipeLineLems.Domain.Shared.Enums; |
| | | namespace CMS.Plugin.PipeLineLems.Application.Contracts.Dtos.CallMaterialOrder; |
| | | |
| | | /// <summary> |
| | | /// 嫿åè¡¨å¯¼åºæ¨¡å |
| | | /// </summary> |
| | | public class CallMaterialOrderExportModel |
| | | { |
| | | /// <summary> |
| | | /// åææ è¯ |
| | | /// </summary> |
| | | [ExcelColumn(Name = "åææ è¯", Width = 25)] |
| | | public string DataIdentifier { get; set; } |
| | | |
| | | /// <summary> |
| | | /// åæåå· |
| | | /// </summary> |
| | | [ExcelColumn(Name = "åæåå·", Width = 25)] |
| | | public string MaterialMode { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å«æç¶æ |
| | | /// </summary> |
| | | [ExcelColumn(Name = "å«æç¶æ", Width = 25)] |
| | | public CallMaterialStatusEnum CallMaterialStatus { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 嫿æ°é |
| | | /// </summary> |
| | | [ExcelColumn(Name = "嫿æ°é", Width = 25)] |
| | | public int Quantity { get; set; } |
| | | |
| | | /// <summary> |
| | | /// WMSè¿åç»æ |
| | | /// </summary> |
| | | [ExcelColumn(Name = "WMSè¿åç»æ", Width = 25)] |
| | | public string WmsRetResult { get; set; } |
| | | |
| | | /// <summary> |
| | | /// WMSä»»å¡å· |
| | | /// </summary> |
| | | [ExcelColumn(Name = "WMSä»»å¡å·", Width = 25)] |
| | | public string WmsTaskNo { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å建æ¶é´ |
| | | /// </summary> |
| | | [ExcelColumn(Name = "å建æ¶é´", Width = 25)] |
| | | public DateTime CreationTime { get; set; } |
| | | |
| | | /// <summary> |
| | | /// ä¿®æ¹æ¶é´ |
| | | /// </summary> |
| | | [ExcelColumn(Name = "ä¿®æ¹æ¶é´", Width = 25)] |
| | | public DateTime LastModificationTime { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å建人 |
| | | /// </summary> |
| | | [ExcelColumn(Name = "å建人", Width = 25)] |
| | | public string CreatorName { get; set; } |
| | | |
| | | /// <summary> |
| | | /// ä¿®æ¹äºº |
| | | /// </summary> |
| | | [ExcelColumn(Name = "ä¿®æ¹äºº", Width = 25)] |
| | | public string LastModifierName { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 夿³¨ |
| | | /// </summary> |
| | | [ExcelColumn(Name = "夿³¨", Width = 25)] |
| | | public string Remark { get; set; } |
| | | |
| | | |
| | | |
| | | public Dictionary<string, object> GetExportData() |
| | | { |
| | | var exportData = new Dictionary<string, object>(); |
| | | foreach (var property in this.GetType().GetProperties()) |
| | | { |
| | | exportData.Add(property.Name, property.GetValue(this)); |
| | | } |
| | | |
| | | return exportData; |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | using Volo.Abp.Domain.Entities; |
| | | namespace CMS.Plugin.PipeLineLems.Application.Contracts.Dtos.CallMaterialOrder; |
| | | |
| | | /// <summary> |
| | | /// 嫿åè¡¨æ´æ°åæ°å¯¹è±¡ |
| | | /// </summary> |
| | | public class CallMaterialOrderUpdateDto : CallMaterialOrderCreateOrUpdateDtoBase, IHasConcurrencyStamp |
| | | { |
| | | /// <summary> |
| | | /// å¹¶åæ³ |
| | | /// </summary> |
| | | public string ConcurrencyStamp { get; set; } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | |
| | | namespace CMS.Plugin.PipeLineLems.Application.Contracts.Dtos.CallMaterialOrder |
| | | { |
| | | /// <summary> |
| | | /// 嫿å表导å
¥æ¨¡å |
| | | /// </summary> |
| | | public class CallMaterialOrdersImportModel |
| | | { |
| | | private List<CallMaterialOrderImportModel> _CallMaterialOrders = new(); |
| | | |
| | | public List<CallMaterialOrderImportModel> CallMaterialOrders |
| | | { |
| | | get => _CallMaterialOrders; |
| | | set |
| | | { |
| | | _CallMaterialOrders = value; |
| | | var rowIndex = 2; |
| | | _CallMaterialOrders?.ForEach(x => x.RowIndex = rowIndex++); |
| | | } |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 嫿å表导å
¥æ¨¡å |
| | | /// </summary> |
| | | public class CallMaterialOrderImportModel : CallMaterialOrderExportModel |
| | | { |
| | | /// <summary> |
| | | /// è¡å· |
| | | /// </summary> |
| | | public int RowIndex { get; set; } |
| | | } |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | using CMS.Plugin.PipeLineLems.Domain.Shared.Enums; |
| | | using CmsQueryExtensions.Extension; |
| | | using Volo.Abp.Application.Dtos; |
| | | |
| | | namespace CMS.Plugin.PipeLineLems.Application.Contracts.Dtos.CallMaterialOrder; |
| | | |
| | | /// <summary> |
| | | /// 嫿å表æ¥è¯¢åæ° |
| | | /// </summary> |
| | | public class GetCallMaterialOrderInput : ExtensiblePagedAndSortedResultRequestDto |
| | | { |
| | | |
| | | #region å
³é®åæ¥è¯¢ |
| | | |
| | | /// <summary> |
| | | /// å
³é®åæ¨¡ç³æ¥è¯¢ï¼æ³¨ææ¯å°åï¼ï¼ |
| | | /// </summary> |
| | | public string searchVal { get; set; } |
| | | |
| | | /// <summary> |
| | | /// éç¨æ¥è¯¢é
ç½® (1:æ¨¡ç³æ¥è¯¢ , 2:ç²¾åæ¥è¯¢)ï¼æ³¨ææ¯å°åï¼ï¼ |
| | | /// </summary> |
| | | public SearchFilterModeEnum searchVal_FilterMode { get; set; } = SearchFilterModeEnum.æ¨¡ç³æ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// åæç´¢ç»ä»¶ä¼ éçéç¨æ¥è¯¢é
ç½®ç屿§åï¼æ³¨ææ¯å°åï¼ï¼ |
| | | /// </summary> |
| | | [NoAutoQuery] |
| | | public string str_searchFormInputAttrs { get; set; } |
| | | /// <summary> |
| | | /// åæç´¢ç»ä»¶ä¼ éçéç¨æ¥è¯¢é
ç½®ç屿§åï¼æ³¨ææ¯å°åï¼ï¼ |
| | | /// </summary> |
| | | public List<string> searchFormInputAttrs |
| | | { |
| | | get |
| | | { |
| | | if (!string.IsNullOrEmpty(str_searchFormInputAttrs)) |
| | | { |
| | | return str_searchFormInputAttrs.Split(',').ToList(); |
| | | } |
| | | return new List<string>(); |
| | | } |
| | | } |
| | | |
| | | #endregion |
| | | |
| | | /// <summary> |
| | | /// åææ è¯ |
| | | /// </summary> |
| | | public string DataIdentifier { get; set; } |
| | | |
| | | /// <summary> |
| | | /// åææ è¯-æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum DataIdentifier_FilterMode { get; set; }= SearchFilterModeEnum.æ¨¡ç³æ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// åæåå· |
| | | /// </summary> |
| | | public string MaterialMode { get; set; } |
| | | |
| | | /// <summary> |
| | | /// åæåå·-æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum MaterialMode_FilterMode { get; set; }= SearchFilterModeEnum.æ¨¡ç³æ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// å«æç¶æ |
| | | /// </summary> |
| | | public CallMaterialStatusEnum? CallMaterialStatus { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å«æç¶æ-æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum CallMaterialStatus_FilterMode { get; set; }= SearchFilterModeEnum.ç²¾åæ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// 嫿æ°é |
| | | /// </summary> |
| | | public int? Quantity { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 嫿æ°é-æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum Quantity_FilterMode { get; set; }= SearchFilterModeEnum.ç²¾åæ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// WMSè¿åç»æ |
| | | /// </summary> |
| | | public string WmsRetResult { get; set; } |
| | | |
| | | /// <summary> |
| | | /// WMSè¿åç»æ-æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum WmsRetResult_FilterMode { get; set; }= SearchFilterModeEnum.æ¨¡ç³æ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// WMSä»»å¡å· |
| | | /// </summary> |
| | | public string WmsTaskNo { get; set; } |
| | | |
| | | /// <summary> |
| | | /// WMSä»»å¡å·-æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum WmsTaskNo_FilterMode { get; set; }= SearchFilterModeEnum.æ¨¡ç³æ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// å建æ¶é´ |
| | | /// </summary> |
| | | //è¡¨ç¤ºæ¯ é«çº§æ¥è¯¢èå´æ¥è¯¢ç¹æ§ |
| | | [HighSearchRangeAttribute] |
| | | public List<string> CreationTime { get; set; } |
| | | |
| | | |
| | | /// <summary> |
| | | /// å建人ID |
| | | /// </summary> |
| | | public string CreatorId { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å建人ID-æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum CreatorId_FilterMode { get; set; }= SearchFilterModeEnum.æ¨¡ç³æ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// ä¿®æ¹æ¶é´ |
| | | /// </summary> |
| | | //è¡¨ç¤ºæ¯ é«çº§æ¥è¯¢èå´æ¥è¯¢ç¹æ§ |
| | | [HighSearchRangeAttribute] |
| | | public List<string> LastModificationTime { get; set; } |
| | | |
| | | |
| | | /// <summary> |
| | | /// ä¿®æ¹äººID |
| | | /// </summary> |
| | | public string LastModifierId { get; set; } |
| | | |
| | | /// <summary> |
| | | /// ä¿®æ¹äººID-æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum LastModifierId_FilterMode { get; set; }= SearchFilterModeEnum.æ¨¡ç³æ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// æ¯å¦å é¤ |
| | | /// </summary> |
| | | public bool? IsDeleted { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ¯å¦å é¤-æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum IsDeleted_FilterMode { get; set; }= SearchFilterModeEnum.ç²¾åæ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// å é¤äººID |
| | | /// </summary> |
| | | public string DeleterId { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å é¤äººID-æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum DeleterId_FilterMode { get; set; }= SearchFilterModeEnum.æ¨¡ç³æ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// å 餿¶é´ |
| | | /// </summary> |
| | | //è¡¨ç¤ºæ¯ é«çº§æ¥è¯¢èå´æ¥è¯¢ç¹æ§ |
| | | [HighSearchRangeAttribute] |
| | | public List<string> DeletionTime { get; set; } |
| | | |
| | | |
| | | /// <summary> |
| | | /// å建人 |
| | | /// </summary> |
| | | public string CreatorName { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å建人-æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum CreatorName_FilterMode { get; set; }= SearchFilterModeEnum.æ¨¡ç³æ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// ä¿®æ¹äºº |
| | | /// </summary> |
| | | public string LastModifierName { get; set; } |
| | | |
| | | /// <summary> |
| | | /// ä¿®æ¹äºº-æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum LastModifierName_FilterMode { get; set; }= SearchFilterModeEnum.æ¨¡ç³æ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// æä½å¤æ³¨ |
| | | /// </summary> |
| | | public string OperationRemark { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æä½å¤æ³¨-æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum OperationRemark_FilterMode { get; set; }= SearchFilterModeEnum.æ¨¡ç³æ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// å é¤å¤æ³¨ |
| | | /// </summary> |
| | | public string DeleteRemark { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å é¤å¤æ³¨-æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum DeleteRemark_FilterMode { get; set; }= SearchFilterModeEnum.æ¨¡ç³æ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// æåº |
| | | /// </summary> |
| | | public int? Sort { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æåº-æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum Sort_FilterMode { get; set; }= SearchFilterModeEnum.ç²¾åæ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// 夿³¨ |
| | | /// </summary> |
| | | public string Remark { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 夿³¨-æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum Remark_FilterMode { get; set; }= SearchFilterModeEnum.æ¨¡ç³æ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// æ¯å¦ç¦ç¨ |
| | | /// </summary> |
| | | public bool? IsDisabled { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ¯å¦ç¦ç¨-æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum IsDisabled_FilterMode { get; set; }= SearchFilterModeEnum.ç²¾åæ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// æ©å±å段1 |
| | | /// </summary> |
| | | public string ExtraField1 { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ©å±å段1-æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum ExtraField1_FilterMode { get; set; }= SearchFilterModeEnum.æ¨¡ç³æ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// æ©å±å段2 |
| | | /// </summary> |
| | | public string ExtraField2 { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ©å±å段2-æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum ExtraField2_FilterMode { get; set; }= SearchFilterModeEnum.æ¨¡ç³æ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// æ©å±å段3 |
| | | /// </summary> |
| | | public string ExtraField3 { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ©å±å段3-æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum ExtraField3_FilterMode { get; set; }= SearchFilterModeEnum.æ¨¡ç³æ¥è¯¢; |
| | | |
| | | |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | namespace CMS.Plugin.PipeLineLems.Application.Contracts.Dtos.CallMaterialOrderRecord; |
| | | |
| | | /// <summary> |
| | | /// å«æè®°å½è¡¨åå»ºåæ°å¯¹è±¡ |
| | | /// </summary> |
| | | public class CallMaterialOrderRecordCreateDto : CallMaterialOrderRecordCreateOrUpdateDtoBase |
| | | { |
| | | /// <summary> |
| | | /// æåº |
| | | /// </summary> |
| | | public virtual int? Sort { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ¯å¦ç¦ç¨ |
| | | /// </summary> |
| | | public bool? IsDisabled { get; set; } = false; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | using CMS.Plugin.PipeLineLems.Domain.Shared.Enums; |
| | | using System; |
| | | using Volo.Abp.Application.Dtos; |
| | | |
| | | namespace CMS.Plugin.PipeLineLems.Application.Contracts.Dtos.CallMaterialOrderRecord; |
| | | |
| | | /// <summary> |
| | | /// å«æè®°å½è¡¨åå»ºææ´æ°åºç±» |
| | | /// </summary> |
| | | public abstract class CallMaterialOrderRecordCreateOrUpdateDtoBase : ExtensibleEntityDto |
| | | { |
| | | /// <summary> |
| | | /// åææ è¯ |
| | | /// </summary> |
| | | public string DataIdentifier { get; set; } |
| | | |
| | | /// <summary> |
| | | /// åæåå· |
| | | /// </summary> |
| | | public string? MaterialMode { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å«æç¶æ |
| | | /// </summary> |
| | | public CallMaterialStatusEnum CallMaterialStatus { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 嫿æ°é |
| | | /// </summary> |
| | | public int Quantity { get; set; } |
| | | |
| | | /// <summary> |
| | | /// WMSè¿åç»æ |
| | | /// </summary> |
| | | public string? WmsRetResult { get; set; } |
| | | |
| | | /// <summary> |
| | | /// WMSä»»å¡å· |
| | | /// </summary> |
| | | public string? WmsTaskNo { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å建人ID |
| | | /// </summary> |
| | | public string? CreatorId { get; set; } |
| | | |
| | | /// <summary> |
| | | /// ä¿®æ¹äººID |
| | | /// </summary> |
| | | public string? LastModifierId { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å 餿¶é´ |
| | | /// </summary> |
| | | public DateTime? DeletionTime { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æåº |
| | | /// </summary> |
| | | public int Sort { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 夿³¨ |
| | | /// </summary> |
| | | public string? Remark { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ©å±å段1 |
| | | /// </summary> |
| | | public string? ExtraField1 { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ©å±å段2 |
| | | /// </summary> |
| | | public string? ExtraField2 { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ©å±å段3 |
| | | /// </summary> |
| | | public string? ExtraField3 { get; set; } |
| | | |
| | | |
| | | |
| | | /// <summary> |
| | | /// Initializes a new instance of the <see cref="CallMaterialOrderRecordCreateOrUpdateDtoBase"/> class. |
| | | /// </summary> |
| | | public CallMaterialOrderRecordCreateOrUpdateDtoBase() : base(false) |
| | | { |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | using CMS.Plugin.PipeLineLems.Domain.Shared.Enums; |
| | | using CmsQueryExtensions; |
| | | using Volo.Abp.Application.Dtos; |
| | | using Volo.Abp.Data; |
| | | using Volo.Abp.Domain.Entities; |
| | | |
| | | |
| | | namespace CMS.Plugin.PipeLineLems.Application.Contracts.Dtos.CallMaterialOrderRecord; |
| | | |
| | | /// <summary> |
| | | /// å«æè®°å½è¡¨æ°æ®åæ°å¯¹è±¡ |
| | | /// </summary> |
| | | public class CallMaterialOrderRecordDto: ExtensibleEntityDto<Guid>, IHasConcurrencyStamp |
| | | { |
| | | /// <summary> |
| | | /// åææ è¯ |
| | | /// </summary> |
| | | public string DataIdentifier { get; set; } |
| | | |
| | | /// <summary> |
| | | /// åæåå· |
| | | /// </summary> |
| | | public string? MaterialMode { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å«æç¶æ |
| | | /// </summary> |
| | | public CallMaterialStatusEnum CallMaterialStatus { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å«æç¶æ |
| | | /// </summary> |
| | | public string CallMaterialStatusDesc |
| | | { |
| | | get |
| | | { |
| | | return GetEnumDescriptionUtil.GetEnumDescription(CallMaterialStatus); |
| | | } |
| | | } |
| | | /// <summary> |
| | | /// 嫿æ°é |
| | | /// </summary> |
| | | public int Quantity { get; set; } |
| | | |
| | | /// <summary> |
| | | /// WMSè¿åç»æ |
| | | /// </summary> |
| | | public string? WmsRetResult { get; set; } |
| | | |
| | | /// <summary> |
| | | /// WMSä»»å¡å· |
| | | /// </summary> |
| | | public string? WmsTaskNo { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ©å±å±æ§ |
| | | /// </summary> |
| | | public ExtraPropertyDictionary? ExtraProperties { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å¹¶åæ³ |
| | | /// </summary> |
| | | public string? ConcurrencyStamp { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å建æ¶é´ |
| | | /// </summary> |
| | | public DateTime CreationTime { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å建人ID |
| | | /// </summary> |
| | | public string? CreatorId { get; set; } |
| | | |
| | | /// <summary> |
| | | /// ä¿®æ¹æ¶é´ |
| | | /// </summary> |
| | | public DateTime? LastModificationTime { get; set; } |
| | | |
| | | /// <summary> |
| | | /// ä¿®æ¹äººID |
| | | /// </summary> |
| | | public string? LastModifierId { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ¯å¦å é¤ |
| | | /// </summary> |
| | | public bool IsDeleted { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å é¤äººID |
| | | /// </summary> |
| | | public string? DeleterId { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å 餿¶é´ |
| | | /// </summary> |
| | | public DateTime? DeletionTime { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å建人 |
| | | /// </summary> |
| | | public string? CreatorName { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æåº |
| | | /// </summary> |
| | | public int Sort { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 夿³¨ |
| | | /// </summary> |
| | | public string? Remark { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ©å±å段1 |
| | | /// </summary> |
| | | public string? ExtraField1 { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ©å±å段2 |
| | | /// </summary> |
| | | public string? ExtraField2 { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ©å±å段3 |
| | | /// </summary> |
| | | public string? ExtraField3 { get; set; } |
| | | |
| | | |
| | | |
| | | /// <summary> |
| | | /// Gets the export data. |
| | | /// </summary> |
| | | /// <returns></returns> |
| | | public Dictionary<string, object> GetExportData() |
| | | { |
| | | var exportData = new Dictionary<string, object>(); |
| | | foreach (var property in this.GetType().GetProperties()) |
| | | { |
| | | exportData.Add(property.Name, property.GetValue(this)); |
| | | } |
| | | |
| | | return exportData; |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | using MiniExcelLibs.Attributes; |
| | | using System.ComponentModel.DataAnnotations; |
| | | using System; |
| | | using System.ComponentModel; |
| | | using CMS.Plugin.PipeLineLems.Domain.Shared.Enums; |
| | | namespace CMS.Plugin.PipeLineLems.Application.Contracts.Dtos.CallMaterialOrderRecord; |
| | | |
| | | /// <summary> |
| | | /// å«æè®°å½è¡¨å¯¼åºæ¨¡å |
| | | /// </summary> |
| | | public class CallMaterialOrderRecordExportModel |
| | | { |
| | | /// <summary> |
| | | /// åææ è¯ |
| | | /// </summary> |
| | | [ExcelColumn(Name = "åææ è¯", Width = 25)] |
| | | public string DataIdentifier { get; set; } |
| | | |
| | | /// <summary> |
| | | /// åæåå· |
| | | /// </summary> |
| | | [ExcelColumn(Name = "åæåå·", Width = 25)] |
| | | public string MaterialMode { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å«æç¶æ |
| | | /// </summary> |
| | | [ExcelColumn(Name = "å«æç¶æ", Width = 25)] |
| | | public CallMaterialStatusEnum CallMaterialStatus { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 嫿æ°é |
| | | /// </summary> |
| | | [ExcelColumn(Name = "嫿æ°é", Width = 25)] |
| | | public int Quantity { get; set; } |
| | | |
| | | /// <summary> |
| | | /// WMSè¿åç»æ |
| | | /// </summary> |
| | | [ExcelColumn(Name = "WMSè¿åç»æ", Width = 25)] |
| | | public string WmsRetResult { get; set; } |
| | | |
| | | /// <summary> |
| | | /// WMSä»»å¡å· |
| | | /// </summary> |
| | | [ExcelColumn(Name = "WMSä»»å¡å·", Width = 25)] |
| | | public string WmsTaskNo { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å建æ¶é´ |
| | | /// </summary> |
| | | [ExcelColumn(Name = "å建æ¶é´", Width = 25)] |
| | | public DateTime CreationTime { get; set; } |
| | | |
| | | /// <summary> |
| | | /// ä¿®æ¹æ¶é´ |
| | | /// </summary> |
| | | [ExcelColumn(Name = "ä¿®æ¹æ¶é´", Width = 25)] |
| | | public DateTime LastModificationTime { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å建人 |
| | | /// </summary> |
| | | [ExcelColumn(Name = "å建人", Width = 25)] |
| | | public string CreatorName { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 夿³¨ |
| | | /// </summary> |
| | | [ExcelColumn(Name = "夿³¨", Width = 25)] |
| | | public string Remark { get; set; } |
| | | |
| | | |
| | | |
| | | public Dictionary<string, object> GetExportData() |
| | | { |
| | | var exportData = new Dictionary<string, object>(); |
| | | foreach (var property in this.GetType().GetProperties()) |
| | | { |
| | | exportData.Add(property.Name, property.GetValue(this)); |
| | | } |
| | | |
| | | return exportData; |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | using Volo.Abp.Domain.Entities; |
| | | namespace CMS.Plugin.PipeLineLems.Application.Contracts.Dtos.CallMaterialOrderRecord; |
| | | |
| | | /// <summary> |
| | | /// å«æè®°å½è¡¨æ´æ°åæ°å¯¹è±¡ |
| | | /// </summary> |
| | | public class CallMaterialOrderRecordUpdateDto : CallMaterialOrderRecordCreateOrUpdateDtoBase, IHasConcurrencyStamp |
| | | { |
| | | /// <summary> |
| | | /// å¹¶åæ³ |
| | | /// </summary> |
| | | public string ConcurrencyStamp { get; set; } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | |
| | | namespace CMS.Plugin.PipeLineLems.Application.Contracts.Dtos.CallMaterialOrderRecord |
| | | { |
| | | /// <summary> |
| | | /// å«æè®°å½è¡¨å¯¼å
¥æ¨¡å |
| | | /// </summary> |
| | | public class CallMaterialOrderRecordsImportModel |
| | | { |
| | | private List<CallMaterialOrderRecordImportModel> _CallMaterialOrderRecords = new(); |
| | | |
| | | public List<CallMaterialOrderRecordImportModel> CallMaterialOrderRecords |
| | | { |
| | | get => _CallMaterialOrderRecords; |
| | | set |
| | | { |
| | | _CallMaterialOrderRecords = value; |
| | | var rowIndex = 2; |
| | | _CallMaterialOrderRecords?.ForEach(x => x.RowIndex = rowIndex++); |
| | | } |
| | | } |
| | | |
| | | /// <summary> |
| | | /// å«æè®°å½è¡¨å¯¼å
¥æ¨¡å |
| | | /// </summary> |
| | | public class CallMaterialOrderRecordImportModel : CallMaterialOrderRecordExportModel |
| | | { |
| | | /// <summary> |
| | | /// è¡å· |
| | | /// </summary> |
| | | public int RowIndex { get; set; } |
| | | } |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | using CMS.Plugin.PipeLineLems.Domain.Shared.Enums; |
| | | using CmsQueryExtensions.Extension; |
| | | using Volo.Abp.Application.Dtos; |
| | | |
| | | namespace CMS.Plugin.PipeLineLems.Application.Contracts.Dtos.CallMaterialOrderRecord; |
| | | |
| | | /// <summary> |
| | | /// å«æè®°å½è¡¨æ¥è¯¢åæ° |
| | | /// </summary> |
| | | public class GetCallMaterialOrderRecordInput : ExtensiblePagedAndSortedResultRequestDto |
| | | { |
| | | |
| | | #region å
³é®åæ¥è¯¢ |
| | | |
| | | /// <summary> |
| | | /// å
³é®åæ¨¡ç³æ¥è¯¢ï¼æ³¨ææ¯å°åï¼ï¼ |
| | | /// </summary> |
| | | public string searchVal { get; set; } |
| | | |
| | | /// <summary> |
| | | /// éç¨æ¥è¯¢é
ç½® (1:æ¨¡ç³æ¥è¯¢ , 2:ç²¾åæ¥è¯¢)ï¼æ³¨ææ¯å°åï¼ï¼ |
| | | /// </summary> |
| | | public SearchFilterModeEnum searchVal_FilterMode { get; set; } = SearchFilterModeEnum.æ¨¡ç³æ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// åæç´¢ç»ä»¶ä¼ éçéç¨æ¥è¯¢é
ç½®ç屿§åï¼æ³¨ææ¯å°åï¼ï¼ |
| | | /// </summary> |
| | | [NoAutoQuery] |
| | | public string str_searchFormInputAttrs { get; set; } |
| | | /// <summary> |
| | | /// åæç´¢ç»ä»¶ä¼ éçéç¨æ¥è¯¢é
ç½®ç屿§åï¼æ³¨ææ¯å°åï¼ï¼ |
| | | /// </summary> |
| | | public List<string> searchFormInputAttrs |
| | | { |
| | | get |
| | | { |
| | | if (!string.IsNullOrEmpty(str_searchFormInputAttrs)) |
| | | { |
| | | return str_searchFormInputAttrs.Split(',').ToList(); |
| | | } |
| | | return new List<string>(); |
| | | } |
| | | } |
| | | |
| | | #endregion |
| | | |
| | | /// <summary> |
| | | /// åææ è¯ |
| | | /// </summary> |
| | | public string DataIdentifier { get; set; } |
| | | |
| | | /// <summary> |
| | | /// åææ è¯-æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum DataIdentifier_FilterMode { get; set; }= SearchFilterModeEnum.æ¨¡ç³æ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// åæåå· |
| | | /// </summary> |
| | | public string MaterialMode { get; set; } |
| | | |
| | | /// <summary> |
| | | /// åæåå·-æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum MaterialMode_FilterMode { get; set; }= SearchFilterModeEnum.æ¨¡ç³æ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// å«æç¶æ |
| | | /// </summary> |
| | | public CallMaterialStatusEnum? CallMaterialStatus { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å«æç¶æ-æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum CallMaterialStatus_FilterMode { get; set; }= SearchFilterModeEnum.ç²¾åæ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// 嫿æ°é |
| | | /// </summary> |
| | | public int? Quantity { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 嫿æ°é-æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum Quantity_FilterMode { get; set; }= SearchFilterModeEnum.ç²¾åæ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// WMSè¿åç»æ |
| | | /// </summary> |
| | | public string WmsRetResult { get; set; } |
| | | |
| | | /// <summary> |
| | | /// WMSè¿åç»æ-æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum WmsRetResult_FilterMode { get; set; }= SearchFilterModeEnum.æ¨¡ç³æ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// WMSä»»å¡å· |
| | | /// </summary> |
| | | public string WmsTaskNo { get; set; } |
| | | |
| | | /// <summary> |
| | | /// WMSä»»å¡å·-æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum WmsTaskNo_FilterMode { get; set; }= SearchFilterModeEnum.æ¨¡ç³æ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// å建æ¶é´ |
| | | /// </summary> |
| | | //è¡¨ç¤ºæ¯ é«çº§æ¥è¯¢èå´æ¥è¯¢ç¹æ§ |
| | | [HighSearchRangeAttribute] |
| | | public List<string> CreationTime { get; set; } |
| | | |
| | | |
| | | /// <summary> |
| | | /// å建人ID |
| | | /// </summary> |
| | | public string CreatorId { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å建人ID-æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum CreatorId_FilterMode { get; set; }= SearchFilterModeEnum.æ¨¡ç³æ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// ä¿®æ¹æ¶é´ |
| | | /// </summary> |
| | | //è¡¨ç¤ºæ¯ é«çº§æ¥è¯¢èå´æ¥è¯¢ç¹æ§ |
| | | [HighSearchRangeAttribute] |
| | | public List<string> LastModificationTime { get; set; } |
| | | |
| | | |
| | | /// <summary> |
| | | /// ä¿®æ¹äººID |
| | | /// </summary> |
| | | public string LastModifierId { get; set; } |
| | | |
| | | /// <summary> |
| | | /// ä¿®æ¹äººID-æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum LastModifierId_FilterMode { get; set; }= SearchFilterModeEnum.æ¨¡ç³æ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// æ¯å¦å é¤ |
| | | /// </summary> |
| | | public bool? IsDeleted { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ¯å¦å é¤-æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum IsDeleted_FilterMode { get; set; }= SearchFilterModeEnum.ç²¾åæ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// å é¤äººID |
| | | /// </summary> |
| | | public string DeleterId { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å é¤äººID-æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum DeleterId_FilterMode { get; set; }= SearchFilterModeEnum.æ¨¡ç³æ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// å 餿¶é´ |
| | | /// </summary> |
| | | //è¡¨ç¤ºæ¯ é«çº§æ¥è¯¢èå´æ¥è¯¢ç¹æ§ |
| | | [HighSearchRangeAttribute] |
| | | public List<string> DeletionTime { get; set; } |
| | | |
| | | |
| | | /// <summary> |
| | | /// å建人 |
| | | /// </summary> |
| | | public string CreatorName { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å建人-æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum CreatorName_FilterMode { get; set; }= SearchFilterModeEnum.æ¨¡ç³æ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// æåº |
| | | /// </summary> |
| | | public int? Sort { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æåº-æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum Sort_FilterMode { get; set; }= SearchFilterModeEnum.ç²¾åæ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// 夿³¨ |
| | | /// </summary> |
| | | public string Remark { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 夿³¨-æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum Remark_FilterMode { get; set; }= SearchFilterModeEnum.æ¨¡ç³æ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// æ©å±å段1 |
| | | /// </summary> |
| | | public string ExtraField1 { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ©å±å段1-æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum ExtraField1_FilterMode { get; set; }= SearchFilterModeEnum.æ¨¡ç³æ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// æ©å±å段2 |
| | | /// </summary> |
| | | public string ExtraField2 { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ©å±å段2-æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum ExtraField2_FilterMode { get; set; }= SearchFilterModeEnum.æ¨¡ç³æ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// æ©å±å段3 |
| | | /// </summary> |
| | | public string ExtraField3 { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ©å±å段3-æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum ExtraField3_FilterMode { get; set; }= SearchFilterModeEnum.æ¨¡ç³æ¥è¯¢; |
| | | |
| | | |
| | | } |
| | |
| | | using CMS.Plugin.PipeLineLems.Domain.Shared.Enums; |
| | | using CmsQueryExtensions.Extension; |
| | | using Volo.Abp.Application.Dtos; |
| | | |
| | |
| | | /// ä»»å¡ç¼ç -æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum TaskCode_FilterMode { get; set; }= SearchFilterModeEnum.æ¨¡ç³æ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// 计åç¶æ |
| | | /// </summary> |
| | | public WorkPlanStatusEnum? WorkPlanStatus { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 计åç¶æ-æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum WorkPlanStatus_FilterMode { get; set; }= SearchFilterModeEnum.ç²¾åæ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// å«æç¶æ |
| | | /// </summary> |
| | | public CallMaterialStatusEnum? CallMaterialStatus { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å«æç¶æ-æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum CallMaterialStatus_FilterMode { get; set; }= SearchFilterModeEnum.ç²¾åæ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// åææ è¯ |
| | |
| | | /// æè´¨-æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum Material_FilterMode { get; set; }= SearchFilterModeEnum.æ¨¡ç³æ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// æ¯å¦ä¸»æ¯ç®¡ |
| | | /// </summary> |
| | | public bool? HasMainSignature { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ¯å¦ä¸»æ¯ç®¡-æ¥è¯¢å
³ç³»è¿ç®ç¬¦ |
| | | /// </summary> |
| | | public SearchFilterModeEnum HasMainSignature_FilterMode { get; set; }= SearchFilterModeEnum.ç²¾åæ¥è¯¢; |
| | | |
| | | /// <summary> |
| | | /// å·¥èºæµåç¼å· |
| | |
| | | public string TaskCode { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 计åç¶æ |
| | | /// </summary> |
| | | public WorkPlanStatusEnum WorkPlanStatus { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å«æç¶æ |
| | | /// </summary> |
| | | public CallMaterialStatusEnum CallMaterialStatus { get; set; } |
| | | |
| | | /// <summary> |
| | | /// åææ è¯ |
| | | /// </summary> |
| | | public string? DataIdentifier { get; set; } |
| | |
| | | /// æè´¨ |
| | | /// </summary> |
| | | public string? Material { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ¯å¦ä¸»æ¯ç®¡ |
| | | /// </summary> |
| | | public bool HasMainSignature { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å·¥èºæµåç¼å· |
| | |
| | | public string TaskCode { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 计åç¶æ |
| | | /// </summary> |
| | | public WorkPlanStatusEnum WorkPlanStatus { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 计åç¶æ |
| | | /// </summary> |
| | | public string WorkPlanStatusDesc |
| | | { |
| | | get |
| | | { |
| | | return GetEnumDescriptionUtil.GetEnumDescription(WorkPlanStatus); |
| | | } |
| | | } |
| | | /// <summary> |
| | | /// å«æç¶æ |
| | | /// </summary> |
| | | public CallMaterialStatusEnum CallMaterialStatus { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å«æç¶æ |
| | | /// </summary> |
| | | public string CallMaterialStatusDesc |
| | | { |
| | | get |
| | | { |
| | | return GetEnumDescriptionUtil.GetEnumDescription(CallMaterialStatus); |
| | | } |
| | | } |
| | | /// <summary> |
| | | /// åææ è¯ |
| | | /// </summary> |
| | | public string? DataIdentifier { get; set; } |
| | |
| | | /// æè´¨ |
| | | /// </summary> |
| | | public string? Material { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ¯å¦ä¸»æ¯ç®¡ |
| | | /// </summary> |
| | | public bool HasMainSignature { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å·¥èºæµåç¼å· |
| | |
| | | public string TaskCode { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 计åç¶æ |
| | | /// </summary> |
| | | [ExcelColumn(Name = "计åç¶æ", Width = 25)] |
| | | public WorkPlanStatusEnum WorkPlanStatus { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å«æç¶æ |
| | | /// </summary> |
| | | [ExcelColumn(Name = "å«æç¶æ", Width = 25)] |
| | | public CallMaterialStatusEnum CallMaterialStatus { get; set; } |
| | | |
| | | /// <summary> |
| | | /// åææ è¯ |
| | | /// </summary> |
| | | [ExcelColumn(Name = "åææ è¯", Width = 25)] |
| | |
| | | /// </summary> |
| | | [ExcelColumn(Name = "æè´¨", Width = 25)] |
| | | public string Material { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ¯å¦ä¸»æ¯ç®¡ |
| | | /// </summary> |
| | | [ExcelColumn(Name = "æ¯å¦ä¸»æ¯ç®¡", Width = 25)] |
| | | public bool HasMainSignature { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å·¥èºæµåç¼å· |
| | |
| | | public string DataIdentifier { get; set; } |
| | | |
| | | /// <summary> |
| | | /// ç®¡è§æ ¼ç |
| | | /// åæåå· |
| | | /// </summary> |
| | | public string MaterialMode { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 管段ç¼ç |
| | | /// </summary> |
| | | public string PipeSpecCode { get; set; } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | using CMS.Plugin.PipeLineLems.Application.Contracts.Dtos.CallMaterialOrder; |
| | | using Volo.Abp.Application.Services; |
| | | |
| | | namespace CMS.Plugin.PipeLineLems.Application.Contracts.Services; |
| | | |
| | | /// <summary> |
| | | /// 嫿å表åºç¨æå¡æ¥å£ |
| | | /// </summary> |
| | | public interface ICallMaterialOrderAppService : ICrudAppService<CallMaterialOrderDto, Guid, GetCallMaterialOrderInput, CallMaterialOrderCreateDto, CallMaterialOrderUpdateDto> |
| | | { |
| | | /// <summary> |
| | | /// å
é嫿å表 |
| | | /// </summary> |
| | | /// <param name="ids"></param> |
| | | /// <returns></returns> |
| | | Task<List<CallMaterialOrderDto>> CloneAsync(IEnumerable<Guid> ids); |
| | | |
| | | /// <summary> |
| | | /// å é¤å«æå表 |
| | | /// </summary> |
| | | /// <param name="ids"></param> |
| | | /// <returns></returns> |
| | | Task DeleteManyAsync(IEnumerable<Guid> ids); |
| | | |
| | | /// <summary> |
| | | /// è°æ´æåºå«æå表 |
| | | /// </summary> |
| | | /// <param name="id"></param> |
| | | /// <param name="sort"></param> |
| | | /// <returns></returns> |
| | | Task AdjustSortAsync(Guid id, int sort); |
| | | |
| | | /// <summary> |
| | | /// 导å
¥å«æå表 |
| | | /// </summary> |
| | | /// <param name="input"></param> |
| | | /// <returns></returns> |
| | | Task ImportAsync(CallMaterialOrdersImportModel input); |
| | | |
| | | /// <summary> |
| | | /// 导åºå«æå表 |
| | | /// </summary> |
| | | /// <param name="input"></param> |
| | | /// <returns></returns> |
| | | Task<(Dictionary<string, object> Sheets, string FileName)> ExportAsync(GetCallMaterialOrderInput input); |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | using CMS.Plugin.PipeLineLems.Application.Contracts.Dtos.CallMaterialOrderRecord; |
| | | using Volo.Abp.Application.Services; |
| | | |
| | | namespace CMS.Plugin.PipeLineLems.Application.Contracts.Services; |
| | | |
| | | /// <summary> |
| | | /// å«æè®°å½è¡¨åºç¨æå¡æ¥å£ |
| | | /// </summary> |
| | | public interface ICallMaterialOrderRecordAppService : ICrudAppService<CallMaterialOrderRecordDto, Guid, GetCallMaterialOrderRecordInput, CallMaterialOrderRecordCreateDto, CallMaterialOrderRecordUpdateDto> |
| | | { |
| | | /// <summary> |
| | | /// å
éå«æè®°å½è¡¨ |
| | | /// </summary> |
| | | /// <param name="ids"></param> |
| | | /// <returns></returns> |
| | | Task<List<CallMaterialOrderRecordDto>> CloneAsync(IEnumerable<Guid> ids); |
| | | |
| | | /// <summary> |
| | | /// å é¤å«æè®°å½è¡¨ |
| | | /// </summary> |
| | | /// <param name="ids"></param> |
| | | /// <returns></returns> |
| | | Task DeleteManyAsync(IEnumerable<Guid> ids); |
| | | |
| | | /// <summary> |
| | | /// è°æ´æåºå«æè®°å½è¡¨ |
| | | /// </summary> |
| | | /// <param name="id"></param> |
| | | /// <param name="sort"></param> |
| | | /// <returns></returns> |
| | | Task AdjustSortAsync(Guid id, int sort); |
| | | |
| | | /// <summary> |
| | | /// 导å
¥å«æè®°å½è¡¨ |
| | | /// </summary> |
| | | /// <param name="input"></param> |
| | | /// <returns></returns> |
| | | Task ImportAsync(CallMaterialOrderRecordsImportModel input); |
| | | |
| | | /// <summary> |
| | | /// 导åºå«æè®°å½è¡¨ |
| | | /// </summary> |
| | | /// <param name="input"></param> |
| | | /// <returns></returns> |
| | | Task<(Dictionary<string, object> Sheets, string FileName)> ExportAsync(GetCallMaterialOrderRecordInput input); |
| | | } |
| | |
| | | /// <param name="input"></param> |
| | | /// <returns></returns> |
| | | Task<(Dictionary<string, object> Sheets, string FileName)> ExportAsync(GetWorkPlanInput input); |
| | | |
| | | Task<MesOrderResponse> CreatebyApsAsync(List<WorkPlanInput> input); |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | using CMS.Plugin.PipeLineLems.Application.Contracts.Dtos.CallMaterialOrder; |
| | | using CMS.Plugin.PipeLineLems.Application.Contracts.Services; |
| | | using CMS.Plugin.PipeLineLems.Domain.Shared; |
| | | using CmsQueryExtensions; |
| | | using CMS.Plugin.PipeLineLems.Domain.CallMaterialOrder; |
| | | using CmsQueryExtensions.Extension; |
| | | using System.Linq.Expressions; |
| | | using Volo.Abp; |
| | | using Volo.Abp.Application.Dtos; |
| | | using Volo.Abp.Data; |
| | | using Volo.Abp.ObjectExtending; |
| | | using Volo.Abp.ObjectMapping; |
| | | |
| | | namespace CMS.Plugin.PipeLineLems.Application.Implements; |
| | | |
| | | /// <summary> |
| | | /// 嫿å表åºç¨æå¡ |
| | | /// </summary> |
| | | public class CallMaterialOrderAppService : CMSPluginAppService, ICallMaterialOrderAppService |
| | | { |
| | | private readonly ICallMaterialOrderRepository callMaterialOrderRepository; |
| | | |
| | | /// <summary> |
| | | /// Initializes a new instance of the <see cref="CallMaterialOrderAppService"/> class. |
| | | /// </summary> |
| | | /// <param name="CallMaterialOrderRepository">The task job repository.</param> |
| | | public CallMaterialOrderAppService(ICallMaterialOrderRepository _CallMaterialOrderRepository) |
| | | { |
| | | callMaterialOrderRepository = _CallMaterialOrderRepository; |
| | | } |
| | | |
| | | /// <summary> |
| | | /// è·åæå®å«æå表 |
| | | /// </summary> |
| | | /// <param name="id"></param> |
| | | /// <returns></returns> |
| | | public virtual async Task<CallMaterialOrderDto> GetAsync(Guid id) |
| | | { |
| | | return ObjectMapper.Map<CallMaterialOrder, CallMaterialOrderDto>(await callMaterialOrderRepository.GetAsync(id)); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// å页è·å嫿å表 |
| | | /// </summary> |
| | | /// <param name="input"></param> |
| | | /// <returns></returns> |
| | | public virtual async Task<PagedResultDto<CallMaterialOrderDto>> GetListAsync(GetCallMaterialOrderInput input) |
| | | { |
| | | Check.NotNull(input, nameof(input)); |
| | | |
| | | if (input.Sorting.IsNullOrWhiteSpace()) |
| | | { |
| | | input.Sorting = nameof(CallMaterialOrder.Sort); |
| | | } |
| | | |
| | | #region 卿æé æ¥è¯¢æ¡ä»¶ |
| | | |
| | | //卿æé æ¥è¯¢æ¡ä»¶ |
| | | var whereConditions = DynamicGetQueryParams(input); |
| | | |
| | | #endregion |
| | | |
| | | var count = await callMaterialOrderRepository.GetCountAsync(whereConditions); |
| | | var list = await callMaterialOrderRepository.GetListAsync(whereConditions, input.Sorting, input.MaxResultCount, input.SkipCount); |
| | | |
| | | return new PagedResultDto<CallMaterialOrderDto>(count, ObjectMapper.Map<List<CallMaterialOrder>, List<CallMaterialOrderDto>>(list)); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 卿æé æ¥è¯¢æ¡ä»¶ |
| | | /// </summary> |
| | | /// <param name="input">è¾å
¥åæ°</param> |
| | | /// <returns></returns> |
| | | private FunReturnResultModel<Expression<Func<CallMaterialOrder, bool>>> DynamicGetQueryParams(GetCallMaterialOrderInput input) |
| | | { |
| | | //卿æé æ¥è¯¢æ¡ä»¶ |
| | | var whereConditions = WhereConditionsExtensions.GetWhereConditions<CallMaterialOrder, GetCallMaterialOrderInput>(input); |
| | | if (!whereConditions.IsSuccess) |
| | | { |
| | | throw new Exception("卿æé æ¥è¯¢æ¡ä»¶å¤±è´¥:" + whereConditions.ErrMsg); |
| | | } |
| | | |
| | | //ä¹å¯å次èªå®ä¹æå»ºæ¥è¯¢æ¡ä»¶ |
| | | Expression<Func<CallMaterialOrder, bool>> extendExpression = a => a.IsDeleted == false; |
| | | // ä½¿ç¨ System.Linq.PredicateBuilder ç And |
| | | var pres = (System.Linq.Expressions.Expression<Func<CallMaterialOrder, bool>>)(whereConditions.data); |
| | | whereConditions.data = System.Linq.PredicateBuilder.And(pres, extendExpression); |
| | | |
| | | return whereConditions; |
| | | } |
| | | |
| | | /// <summary> |
| | | /// æ°å»ºå«æå表 |
| | | /// </summary> |
| | | /// <param name="input"></param> |
| | | /// <returns></returns> |
| | | /// <exception cref="UserFriendlyException"></exception> |
| | | public virtual async Task<CallMaterialOrderDto> CreateAsync(CallMaterialOrderCreateDto input) |
| | | { |
| | | await CheckCreateOrUpdateDtoAsync(input); |
| | | |
| | | var exist = await callMaterialOrderRepository.NameExistAsync(input.DataIdentifier); |
| | | if (exist) |
| | | { |
| | | throw new UserFriendlyException(L[CMSPluginDomainErrorCodes.NameAlreadyExists, input.DataIdentifier]); |
| | | } |
| | | |
| | | var maxSort = await callMaterialOrderRepository.GetMaxSortAsync(); |
| | | var sort = input.Sort ?? maxSort; |
| | | |
| | | var insertObj = ObjectMapper.Map<CallMaterialOrderCreateDto, CallMaterialOrder>(input); |
| | | insertObj.Sort = sort; |
| | | input.MapExtraPropertiesTo(insertObj, MappingPropertyDefinitionChecks.None); |
| | | |
| | | await callMaterialOrderRepository.InsertAsync(insertObj); |
| | | |
| | | //if (input.Sort.HasValue && insertObj.Sort != maxSort) |
| | | //{ |
| | | // await AdjustSortAsync(insertObj.Id, insertObj.Sort); |
| | | //} |
| | | |
| | | return ObjectMapper.Map<CallMaterialOrder, CallMaterialOrderDto>(insertObj); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// æ´æ°å«æå表 |
| | | /// </summary> |
| | | /// <param name="id"></param> |
| | | /// <param name="input"></param> |
| | | /// <returns></returns> |
| | | /// <exception cref="UserFriendlyException"></exception> |
| | | public virtual async Task<CallMaterialOrderDto> UpdateAsync(Guid id, CallMaterialOrderUpdateDto input) |
| | | { |
| | | await CheckCreateOrUpdateDtoAsync(input); |
| | | |
| | | var updateObj = await callMaterialOrderRepository.GetAsync(id); |
| | | var exist = await callMaterialOrderRepository.NameExistAsync(input.DataIdentifier, updateObj.Id); |
| | | if (exist) |
| | | { |
| | | throw new UserFriendlyException(L[CMSPluginDomainErrorCodes.NameAlreadyExists, input.DataIdentifier]); |
| | | } |
| | | |
| | | updateObj.SetConcurrencyStampIfNotNull(input.ConcurrencyStamp); |
| | | input.MapExtraPropertiesTo(updateObj, MappingPropertyDefinitionChecks.None); |
| | | |
| | | updateObj.DataIdentifier = input.DataIdentifier; |
| | | updateObj.MaterialMode = input.MaterialMode; |
| | | updateObj.CallMaterialStatus = input.CallMaterialStatus; |
| | | updateObj.Quantity = input.Quantity; |
| | | updateObj.WmsRetResult = input.WmsRetResult; |
| | | updateObj.WmsTaskNo = input.WmsTaskNo; |
| | | updateObj.Remark = input.Remark; |
| | | |
| | | |
| | | await callMaterialOrderRepository.UpdateAsync(updateObj); |
| | | |
| | | return ObjectMapper.Map<CallMaterialOrder, CallMaterialOrderDto>(updateObj); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// å
é嫿å表 |
| | | /// </summary> |
| | | /// <param name="ids"></param> |
| | | /// <returns></returns> |
| | | public async Task<List<CallMaterialOrderDto>> CloneAsync(IEnumerable<Guid> ids) |
| | | { |
| | | //var callMaterialOrders = new List<CallMaterialOrder>(); |
| | | //if (ids != null) |
| | | //{ |
| | | // var sort = await callMaterialOrderRepository.GetMaxSortAsync(); |
| | | // foreach (var id in ids) |
| | | // { |
| | | // var CallMaterialOrder = await callMaterialOrderRepository.FindAsync(id); |
| | | // if (CallMaterialOrder != null) |
| | | // { |
| | | // var name = CallMaterialOrder.Name + CallMaterialOrderConsts.CloneTag; |
| | | // var notExist = false; |
| | | // while (!notExist) |
| | | // { |
| | | // var exist = await callMaterialOrderRepository.NameExistAsync(name); |
| | | // if (exist || callMaterialOrders.Any(x => x.Name == name)) |
| | | // { |
| | | // name += CallMaterialOrderConsts.CloneTag; |
| | | // continue; |
| | | // } |
| | | |
| | | // notExist = true; |
| | | // } |
| | | |
| | | // //CallMaterialOrder = await callMaterialOrderRepository.InsertAsync(CallMaterialOrder.Clone(GuidGenerator.Create(), name, sort++)); |
| | | // callMaterialOrders.Add(CallMaterialOrder); |
| | | // } |
| | | // } |
| | | //} |
| | | |
| | | //return ObjectMapper.Map<List<CallMaterialOrder>, List<CallMaterialOrderDto>>(callMaterialOrders); |
| | | return new List<CallMaterialOrderDto>(); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// å é¤åä¸ªå«æå表 |
| | | /// </summary> |
| | | /// <param name="id"></param> |
| | | /// <returns></returns> |
| | | public virtual Task DeleteAsync(Guid id) |
| | | { |
| | | return callMaterialOrderRepository.DeleteAsync(id); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// å é¤å¤ä¸ªå«æå表 |
| | | /// </summary> |
| | | /// <param name="ids"></param> |
| | | /// <returns></returns> |
| | | public async Task DeleteManyAsync(IEnumerable<Guid> ids) |
| | | { |
| | | foreach (var id in ids) |
| | | { |
| | | await DeleteAsync(id); |
| | | } |
| | | } |
| | | |
| | | /// <summary> |
| | | /// è°æ´æåºå«æå表 |
| | | /// </summary> |
| | | /// <param name="id"></param> |
| | | /// <param name="sort"></param> |
| | | /// <returns></returns> |
| | | public virtual async Task AdjustSortAsync(Guid id, int sort) |
| | | { |
| | | var list = await callMaterialOrderRepository.GetListAsync(null, nameof(CallMaterialOrder.Sort)); |
| | | if (list != null && list.Any()) |
| | | { |
| | | var initSort = 1; |
| | | list.ForEach(x => x.AdjustSort(initSort++)); |
| | | var entity = list.FirstOrDefault(x => x.Id == id); |
| | | if (entity != null) |
| | | { |
| | | if (sort == 1) |
| | | { |
| | | list.Where(x => x.Id != id).ToList()?.ForEach(x => x.AdjustSort(x.Sort + 1)); |
| | | } |
| | | else if (entity.Sort > sort) |
| | | { |
| | | list.Where(x => x.Id != id && x.Sort >= sort).ToList()?.ForEach(x => x.AdjustSort(x.Sort + 1)); |
| | | list.Where(x => x.Id != id && x.Sort < sort).ToList()?.ForEach(x => x.AdjustSort(x.Sort - 1)); |
| | | } |
| | | else if (entity.Sort < sort) |
| | | { |
| | | list.Where(x => x.Id != id && x.Sort > sort).ToList()?.ForEach(x => x.AdjustSort(x.Sort + 1)); |
| | | list.Where(x => x.Id != id && x.Sort <= sort).ToList()?.ForEach(x => x.AdjustSort(x.Sort - 1)); |
| | | } |
| | | |
| | | entity.AdjustSort(sort); |
| | | } |
| | | } |
| | | |
| | | await callMaterialOrderRepository.UpdateManyAsync(list); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 导å
¥å«æå表 |
| | | /// </summary> |
| | | /// <param name="input"></param> |
| | | /// <returns></returns> |
| | | /// <exception cref="UserFriendlyException"></exception> |
| | | public async Task ImportAsync(CallMaterialOrdersImportModel input) |
| | | { |
| | | Check.NotNull(input, nameof(input)); |
| | | |
| | | var callMaterialOrderCreateDtos = new List<(int RowIndex, CallMaterialOrderCreateDto Item)>(); |
| | | var callMaterialOrderUpdateDtos = new List<(int RowIndex, Guid Id, CallMaterialOrderUpdateDto Item)>(); |
| | | var importItems = input.CallMaterialOrders; |
| | | |
| | | if (importItems != null && importItems.Any()) |
| | | { |
| | | #region 导å
¥æ ¡éª |
| | | |
| | | // 夿åç§°æ¯å¦éå¤ï¼å¹¶è¾åºç¬¬å è¡éå¤ |
| | | var duplicateCallMaterialOrders = importItems.GroupBy(x => x.DataIdentifier).Where(x => x.Count() > 1).ToList(); |
| | | if (duplicateCallMaterialOrders?.Any() == true) |
| | | { |
| | | var duplicateCallMaterialOrderMsgs = duplicateCallMaterialOrders.Select(x => $"第 {string.Join(",", x.Select(x => x.RowIndex))} è¡ï¼{x.Key} åç§°éå¤"); |
| | | var errorMsg = $"导å
¥å¤±è´¥ï¼é
ç½®ï¼ {string.Join(",", duplicateCallMaterialOrderMsgs)}ï¼ç»æ¢å¯¼å
¥"; |
| | | throw new UserFriendlyException(errorMsg); |
| | | } |
| | | |
| | | #endregion |
| | | |
| | | foreach (var impItem in importItems) |
| | | { |
| | | if (impItem.DataIdentifier.IsNullOrWhiteSpace()) |
| | | { |
| | | continue; |
| | | } |
| | | |
| | | if (impItem.DataIdentifier.IsNullOrWhiteSpace()) |
| | | { |
| | | var errorMsg = $"导å
¥å¤±è´¥ï¼é
ç½®ï¼ç¬¬{impItem.RowIndex}è¡ï¼CallMaterialOrderåç§°ä¸è½ä¸ºç©º"; |
| | | throw new UserFriendlyException(errorMsg); |
| | | } |
| | | |
| | | var oldCallMaterialOrder = await callMaterialOrderRepository.FindByNameAsync(impItem.DataIdentifier); |
| | | if (oldCallMaterialOrder != null) |
| | | { |
| | | var callMaterialOrderUpdateDto = new CallMaterialOrderUpdateDto |
| | | { |
| | | DataIdentifier = impItem.DataIdentifier, |
| | | MaterialMode = impItem.MaterialMode, |
| | | CallMaterialStatus = impItem.CallMaterialStatus, |
| | | Quantity = impItem.Quantity, |
| | | WmsRetResult = impItem.WmsRetResult, |
| | | WmsTaskNo = impItem.WmsTaskNo, |
| | | Remark = impItem.Remark, |
| | | |
| | | }; |
| | | |
| | | callMaterialOrderUpdateDtos.Add((impItem.RowIndex, oldCallMaterialOrder.Id, callMaterialOrderUpdateDto)); |
| | | } |
| | | else |
| | | { |
| | | var callMaterialOrderCreateDto = new CallMaterialOrderCreateDto |
| | | { |
| | | DataIdentifier = impItem.DataIdentifier, |
| | | MaterialMode = impItem.MaterialMode, |
| | | CallMaterialStatus = impItem.CallMaterialStatus, |
| | | Quantity = impItem.Quantity, |
| | | WmsRetResult = impItem.WmsRetResult, |
| | | WmsTaskNo = impItem.WmsTaskNo, |
| | | Remark = impItem.Remark, |
| | | |
| | | }; |
| | | |
| | | callMaterialOrderCreateDtos.Add((impItem.RowIndex, callMaterialOrderCreateDto)); |
| | | } |
| | | } |
| | | } |
| | | |
| | | // æ°å¢ |
| | | foreach (var callMaterialOrderDto in callMaterialOrderCreateDtos) |
| | | { |
| | | try |
| | | { |
| | | await CreateAsync(callMaterialOrderDto.Item); |
| | | } |
| | | catch (Exception e) |
| | | { |
| | | var errorMsg = $"导å
¥å¤±è´¥ï¼é
ç½®ï¼ç¬¬{callMaterialOrderDto.RowIndex}è¡ï¼{e.Message}ï¼ç»æ¢å¯¼å
¥"; |
| | | throw new UserFriendlyException(errorMsg); |
| | | } |
| | | } |
| | | |
| | | // æ´æ° |
| | | foreach (var callMaterialOrderDto in callMaterialOrderUpdateDtos) |
| | | { |
| | | try |
| | | { |
| | | await UpdateAsync(callMaterialOrderDto.Id, callMaterialOrderDto.Item); |
| | | } |
| | | catch (Exception e) |
| | | { |
| | | var errorMsg = $"导å
¥å¤±è´¥ï¼é
ç½®ï¼ç¬¬{callMaterialOrderDto.RowIndex}è¡ï¼{e.Message}ï¼ç»æ¢å¯¼å
¥"; |
| | | throw new UserFriendlyException(errorMsg); |
| | | } |
| | | } |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 导åºå«æå表 |
| | | /// </summary> |
| | | /// <param name="input"></param> |
| | | /// <returns></returns> |
| | | public async Task<(Dictionary<string, object> Sheets, string FileName)> ExportAsync(GetCallMaterialOrderInput input) |
| | | { |
| | | Check.NotNull(input, nameof(input)); |
| | | |
| | | if (input.Sorting.IsNullOrWhiteSpace()) |
| | | { |
| | | input.Sorting = nameof(CallMaterialOrder.Sort); |
| | | } |
| | | |
| | | #region 卿æé æ¥è¯¢æ¡ä»¶ |
| | | |
| | | //卿æé æ¥è¯¢æ¡ä»¶ |
| | | var whereConditions = DynamicGetQueryParams(input); |
| | | |
| | | #endregion |
| | | |
| | | |
| | | var list = await callMaterialOrderRepository.GetListAsync(whereConditions, input.Sorting, input.MaxResultCount, input.SkipCount, includeDetails: true); |
| | | var result = ObjectMapper.Map<List<CallMaterialOrder>, List<CallMaterialOrderDto>>(list); |
| | | |
| | | var sheets = new Dictionary<string, object> |
| | | { |
| | | ["é
ç½®"] = ExportHelper.ConvertListToExportData(result), |
| | | }; |
| | | |
| | | var fileName = "嫿å"; |
| | | return (sheets, fileName); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// æ ¡éªå«æå表ï¼å½æ°å»ºææ´æ°æ¶ |
| | | /// </summary> |
| | | /// <param name="input"></param> |
| | | /// <returns></returns> |
| | | protected Task CheckCreateOrUpdateDtoAsync(CallMaterialOrderCreateOrUpdateDtoBase input) |
| | | { |
| | | Check.NotNull(input, nameof(input)); |
| | | Check.NotNullOrWhiteSpace(input.DataIdentifier, "åææ è¯", 256); |
| | | Check.NotNull(input.CallMaterialStatus, "å«æç¶æ"); |
| | | Check.NotNull(input.Quantity, "嫿æ°é"); |
| | | |
| | | return Task.CompletedTask; |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | using CMS.Plugin.PipeLineLems.Application.Contracts.Dtos.CallMaterialOrderRecord; |
| | | using CMS.Plugin.PipeLineLems.Application.Contracts.Services; |
| | | using CMS.Plugin.PipeLineLems.Domain.Shared; |
| | | using CmsQueryExtensions; |
| | | using CMS.Plugin.PipeLineLems.Domain.CallMaterialOrderRecord; |
| | | using CmsQueryExtensions.Extension; |
| | | using System.Linq.Expressions; |
| | | using Volo.Abp; |
| | | using Volo.Abp.Application.Dtos; |
| | | using Volo.Abp.Data; |
| | | using Volo.Abp.ObjectExtending; |
| | | using Volo.Abp.ObjectMapping; |
| | | |
| | | namespace CMS.Plugin.PipeLineLems.Application.Implements; |
| | | |
| | | /// <summary> |
| | | /// å«æè®°å½è¡¨åºç¨æå¡ |
| | | /// </summary> |
| | | public class CallMaterialOrderRecordAppService : CMSPluginAppService, ICallMaterialOrderRecordAppService |
| | | { |
| | | private readonly ICallMaterialOrderRecordRepository callMaterialOrderRecordRepository; |
| | | |
| | | /// <summary> |
| | | /// Initializes a new instance of the <see cref="CallMaterialOrderRecordAppService"/> class. |
| | | /// </summary> |
| | | /// <param name="CallMaterialOrderRecordRepository">The task job repository.</param> |
| | | public CallMaterialOrderRecordAppService(ICallMaterialOrderRecordRepository _CallMaterialOrderRecordRepository) |
| | | { |
| | | callMaterialOrderRecordRepository = _CallMaterialOrderRecordRepository; |
| | | } |
| | | |
| | | /// <summary> |
| | | /// è·åæå®å«æè®°å½è¡¨ |
| | | /// </summary> |
| | | /// <param name="id"></param> |
| | | /// <returns></returns> |
| | | public virtual async Task<CallMaterialOrderRecordDto> GetAsync(Guid id) |
| | | { |
| | | return ObjectMapper.Map<CallMaterialOrderRecord, CallMaterialOrderRecordDto>(await callMaterialOrderRecordRepository.GetAsync(id)); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// å页è·åå«æè®°å½è¡¨ |
| | | /// </summary> |
| | | /// <param name="input"></param> |
| | | /// <returns></returns> |
| | | public virtual async Task<PagedResultDto<CallMaterialOrderRecordDto>> GetListAsync(GetCallMaterialOrderRecordInput input) |
| | | { |
| | | Check.NotNull(input, nameof(input)); |
| | | |
| | | if (input.Sorting.IsNullOrWhiteSpace()) |
| | | { |
| | | input.Sorting = nameof(CallMaterialOrderRecord.Sort); |
| | | } |
| | | |
| | | #region 卿æé æ¥è¯¢æ¡ä»¶ |
| | | |
| | | //卿æé æ¥è¯¢æ¡ä»¶ |
| | | var whereConditions = DynamicGetQueryParams(input); |
| | | |
| | | #endregion |
| | | |
| | | var count = await callMaterialOrderRecordRepository.GetCountAsync(whereConditions); |
| | | var list = await callMaterialOrderRecordRepository.GetListAsync(whereConditions, input.Sorting, input.MaxResultCount, input.SkipCount); |
| | | |
| | | return new PagedResultDto<CallMaterialOrderRecordDto>(count, ObjectMapper.Map<List<CallMaterialOrderRecord>, List<CallMaterialOrderRecordDto>>(list)); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 卿æé æ¥è¯¢æ¡ä»¶ |
| | | /// </summary> |
| | | /// <param name="input">è¾å
¥åæ°</param> |
| | | /// <returns></returns> |
| | | private FunReturnResultModel<Expression<Func<CallMaterialOrderRecord, bool>>> DynamicGetQueryParams(GetCallMaterialOrderRecordInput input) |
| | | { |
| | | //卿æé æ¥è¯¢æ¡ä»¶ |
| | | var whereConditions = WhereConditionsExtensions.GetWhereConditions<CallMaterialOrderRecord, GetCallMaterialOrderRecordInput>(input); |
| | | if (!whereConditions.IsSuccess) |
| | | { |
| | | throw new Exception("卿æé æ¥è¯¢æ¡ä»¶å¤±è´¥:" + whereConditions.ErrMsg); |
| | | } |
| | | |
| | | //ä¹å¯å次èªå®ä¹æå»ºæ¥è¯¢æ¡ä»¶ |
| | | Expression<Func<CallMaterialOrderRecord, bool>> extendExpression = a => a.IsDeleted == false; |
| | | // ä½¿ç¨ System.Linq.PredicateBuilder ç And |
| | | var pres = (System.Linq.Expressions.Expression<Func<CallMaterialOrderRecord, bool>>)(whereConditions.data); |
| | | whereConditions.data = System.Linq.PredicateBuilder.And(pres, extendExpression); |
| | | |
| | | return whereConditions; |
| | | } |
| | | |
| | | /// <summary> |
| | | /// æ°å»ºå«æè®°å½è¡¨ |
| | | /// </summary> |
| | | /// <param name="input"></param> |
| | | /// <returns></returns> |
| | | /// <exception cref="UserFriendlyException"></exception> |
| | | public virtual async Task<CallMaterialOrderRecordDto> CreateAsync(CallMaterialOrderRecordCreateDto input) |
| | | { |
| | | await CheckCreateOrUpdateDtoAsync(input); |
| | | |
| | | var exist = await callMaterialOrderRecordRepository.NameExistAsync(input.DataIdentifier); |
| | | if (exist) |
| | | { |
| | | throw new UserFriendlyException(L[CMSPluginDomainErrorCodes.NameAlreadyExists, input.DataIdentifier]); |
| | | } |
| | | |
| | | var maxSort = await callMaterialOrderRecordRepository.GetMaxSortAsync(); |
| | | var sort = input.Sort ?? maxSort; |
| | | |
| | | var insertObj = ObjectMapper.Map<CallMaterialOrderRecordCreateDto, CallMaterialOrderRecord>(input); |
| | | insertObj.Sort = sort; |
| | | input.MapExtraPropertiesTo(insertObj, MappingPropertyDefinitionChecks.None); |
| | | |
| | | await callMaterialOrderRecordRepository.InsertAsync(insertObj); |
| | | |
| | | //if (input.Sort.HasValue && insertObj.Sort != maxSort) |
| | | //{ |
| | | // await AdjustSortAsync(insertObj.Id, insertObj.Sort); |
| | | //} |
| | | |
| | | return ObjectMapper.Map<CallMaterialOrderRecord, CallMaterialOrderRecordDto>(insertObj); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// æ´æ°å«æè®°å½è¡¨ |
| | | /// </summary> |
| | | /// <param name="id"></param> |
| | | /// <param name="input"></param> |
| | | /// <returns></returns> |
| | | /// <exception cref="UserFriendlyException"></exception> |
| | | public virtual async Task<CallMaterialOrderRecordDto> UpdateAsync(Guid id, CallMaterialOrderRecordUpdateDto input) |
| | | { |
| | | await CheckCreateOrUpdateDtoAsync(input); |
| | | |
| | | var updateObj = await callMaterialOrderRecordRepository.GetAsync(id); |
| | | var exist = await callMaterialOrderRecordRepository.NameExistAsync(input.DataIdentifier, updateObj.Id); |
| | | if (exist) |
| | | { |
| | | throw new UserFriendlyException(L[CMSPluginDomainErrorCodes.NameAlreadyExists, input.DataIdentifier]); |
| | | } |
| | | |
| | | updateObj.SetConcurrencyStampIfNotNull(input.ConcurrencyStamp); |
| | | input.MapExtraPropertiesTo(updateObj, MappingPropertyDefinitionChecks.None); |
| | | |
| | | updateObj.DataIdentifier = input.DataIdentifier; |
| | | updateObj.MaterialMode = input.MaterialMode; |
| | | updateObj.CallMaterialStatus = input.CallMaterialStatus; |
| | | updateObj.Quantity = input.Quantity; |
| | | updateObj.WmsRetResult = input.WmsRetResult; |
| | | updateObj.WmsTaskNo = input.WmsTaskNo; |
| | | updateObj.Remark = input.Remark; |
| | | |
| | | |
| | | await callMaterialOrderRecordRepository.UpdateAsync(updateObj); |
| | | |
| | | return ObjectMapper.Map<CallMaterialOrderRecord, CallMaterialOrderRecordDto>(updateObj); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// å
éå«æè®°å½è¡¨ |
| | | /// </summary> |
| | | /// <param name="ids"></param> |
| | | /// <returns></returns> |
| | | public async Task<List<CallMaterialOrderRecordDto>> CloneAsync(IEnumerable<Guid> ids) |
| | | { |
| | | //var callMaterialOrderRecords = new List<CallMaterialOrderRecord>(); |
| | | //if (ids != null) |
| | | //{ |
| | | // var sort = await callMaterialOrderRecordRepository.GetMaxSortAsync(); |
| | | // foreach (var id in ids) |
| | | // { |
| | | // var CallMaterialOrderRecord = await callMaterialOrderRecordRepository.FindAsync(id); |
| | | // if (CallMaterialOrderRecord != null) |
| | | // { |
| | | // var name = CallMaterialOrderRecord.Name + CallMaterialOrderRecordConsts.CloneTag; |
| | | // var notExist = false; |
| | | // while (!notExist) |
| | | // { |
| | | // var exist = await callMaterialOrderRecordRepository.NameExistAsync(name); |
| | | // if (exist || callMaterialOrderRecords.Any(x => x.Name == name)) |
| | | // { |
| | | // name += CallMaterialOrderRecordConsts.CloneTag; |
| | | // continue; |
| | | // } |
| | | |
| | | // notExist = true; |
| | | // } |
| | | |
| | | // //CallMaterialOrderRecord = await callMaterialOrderRecordRepository.InsertAsync(CallMaterialOrderRecord.Clone(GuidGenerator.Create(), name, sort++)); |
| | | // callMaterialOrderRecords.Add(CallMaterialOrderRecord); |
| | | // } |
| | | // } |
| | | //} |
| | | |
| | | //return ObjectMapper.Map<List<CallMaterialOrderRecord>, List<CallMaterialOrderRecordDto>>(callMaterialOrderRecords); |
| | | return new List<CallMaterialOrderRecordDto>(); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// å é¤åä¸ªå«æè®°å½è¡¨ |
| | | /// </summary> |
| | | /// <param name="id"></param> |
| | | /// <returns></returns> |
| | | public virtual Task DeleteAsync(Guid id) |
| | | { |
| | | return callMaterialOrderRecordRepository.DeleteAsync(id); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// å é¤å¤ä¸ªå«æè®°å½è¡¨ |
| | | /// </summary> |
| | | /// <param name="ids"></param> |
| | | /// <returns></returns> |
| | | public async Task DeleteManyAsync(IEnumerable<Guid> ids) |
| | | { |
| | | foreach (var id in ids) |
| | | { |
| | | await DeleteAsync(id); |
| | | } |
| | | } |
| | | |
| | | /// <summary> |
| | | /// è°æ´æåºå«æè®°å½è¡¨ |
| | | /// </summary> |
| | | /// <param name="id"></param> |
| | | /// <param name="sort"></param> |
| | | /// <returns></returns> |
| | | public virtual async Task AdjustSortAsync(Guid id, int sort) |
| | | { |
| | | var list = await callMaterialOrderRecordRepository.GetListAsync(null, nameof(CallMaterialOrderRecord.Sort)); |
| | | if (list != null && list.Any()) |
| | | { |
| | | var initSort = 1; |
| | | list.ForEach(x => x.AdjustSort(initSort++)); |
| | | var entity = list.FirstOrDefault(x => x.Id == id); |
| | | if (entity != null) |
| | | { |
| | | if (sort == 1) |
| | | { |
| | | list.Where(x => x.Id != id).ToList()?.ForEach(x => x.AdjustSort(x.Sort + 1)); |
| | | } |
| | | else if (entity.Sort > sort) |
| | | { |
| | | list.Where(x => x.Id != id && x.Sort >= sort).ToList()?.ForEach(x => x.AdjustSort(x.Sort + 1)); |
| | | list.Where(x => x.Id != id && x.Sort < sort).ToList()?.ForEach(x => x.AdjustSort(x.Sort - 1)); |
| | | } |
| | | else if (entity.Sort < sort) |
| | | { |
| | | list.Where(x => x.Id != id && x.Sort > sort).ToList()?.ForEach(x => x.AdjustSort(x.Sort + 1)); |
| | | list.Where(x => x.Id != id && x.Sort <= sort).ToList()?.ForEach(x => x.AdjustSort(x.Sort - 1)); |
| | | } |
| | | |
| | | entity.AdjustSort(sort); |
| | | } |
| | | } |
| | | |
| | | await callMaterialOrderRecordRepository.UpdateManyAsync(list); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 导å
¥å«æè®°å½è¡¨ |
| | | /// </summary> |
| | | /// <param name="input"></param> |
| | | /// <returns></returns> |
| | | /// <exception cref="UserFriendlyException"></exception> |
| | | public async Task ImportAsync(CallMaterialOrderRecordsImportModel input) |
| | | { |
| | | Check.NotNull(input, nameof(input)); |
| | | |
| | | var callMaterialOrderRecordCreateDtos = new List<(int RowIndex, CallMaterialOrderRecordCreateDto Item)>(); |
| | | var callMaterialOrderRecordUpdateDtos = new List<(int RowIndex, Guid Id, CallMaterialOrderRecordUpdateDto Item)>(); |
| | | var importItems = input.CallMaterialOrderRecords; |
| | | |
| | | if (importItems != null && importItems.Any()) |
| | | { |
| | | #region 导å
¥æ ¡éª |
| | | |
| | | // 夿åç§°æ¯å¦éå¤ï¼å¹¶è¾åºç¬¬å è¡éå¤ |
| | | var duplicateCallMaterialOrderRecords = importItems.GroupBy(x => x.DataIdentifier).Where(x => x.Count() > 1).ToList(); |
| | | if (duplicateCallMaterialOrderRecords?.Any() == true) |
| | | { |
| | | var duplicateCallMaterialOrderRecordMsgs = duplicateCallMaterialOrderRecords.Select(x => $"第 {string.Join(",", x.Select(x => x.RowIndex))} è¡ï¼{x.Key} åç§°éå¤"); |
| | | var errorMsg = $"导å
¥å¤±è´¥ï¼é
ç½®ï¼ {string.Join(",", duplicateCallMaterialOrderRecordMsgs)}ï¼ç»æ¢å¯¼å
¥"; |
| | | throw new UserFriendlyException(errorMsg); |
| | | } |
| | | |
| | | #endregion |
| | | |
| | | foreach (var impItem in importItems) |
| | | { |
| | | if (impItem.DataIdentifier.IsNullOrWhiteSpace()) |
| | | { |
| | | continue; |
| | | } |
| | | |
| | | if (impItem.DataIdentifier.IsNullOrWhiteSpace()) |
| | | { |
| | | var errorMsg = $"导å
¥å¤±è´¥ï¼é
ç½®ï¼ç¬¬{impItem.RowIndex}è¡ï¼CallMaterialOrderRecordåç§°ä¸è½ä¸ºç©º"; |
| | | throw new UserFriendlyException(errorMsg); |
| | | } |
| | | |
| | | var oldCallMaterialOrderRecord = await callMaterialOrderRecordRepository.FindByNameAsync(impItem.DataIdentifier); |
| | | if (oldCallMaterialOrderRecord != null) |
| | | { |
| | | var callMaterialOrderRecordUpdateDto = new CallMaterialOrderRecordUpdateDto |
| | | { |
| | | DataIdentifier = impItem.DataIdentifier, |
| | | MaterialMode = impItem.MaterialMode, |
| | | CallMaterialStatus = impItem.CallMaterialStatus, |
| | | Quantity = impItem.Quantity, |
| | | WmsRetResult = impItem.WmsRetResult, |
| | | WmsTaskNo = impItem.WmsTaskNo, |
| | | Remark = impItem.Remark, |
| | | |
| | | }; |
| | | |
| | | callMaterialOrderRecordUpdateDtos.Add((impItem.RowIndex, oldCallMaterialOrderRecord.Id, callMaterialOrderRecordUpdateDto)); |
| | | } |
| | | else |
| | | { |
| | | var callMaterialOrderRecordCreateDto = new CallMaterialOrderRecordCreateDto |
| | | { |
| | | DataIdentifier = impItem.DataIdentifier, |
| | | MaterialMode = impItem.MaterialMode, |
| | | CallMaterialStatus = impItem.CallMaterialStatus, |
| | | Quantity = impItem.Quantity, |
| | | WmsRetResult = impItem.WmsRetResult, |
| | | WmsTaskNo = impItem.WmsTaskNo, |
| | | Remark = impItem.Remark, |
| | | |
| | | }; |
| | | |
| | | callMaterialOrderRecordCreateDtos.Add((impItem.RowIndex, callMaterialOrderRecordCreateDto)); |
| | | } |
| | | } |
| | | } |
| | | |
| | | // æ°å¢ |
| | | foreach (var callMaterialOrderRecordDto in callMaterialOrderRecordCreateDtos) |
| | | { |
| | | try |
| | | { |
| | | await CreateAsync(callMaterialOrderRecordDto.Item); |
| | | } |
| | | catch (Exception e) |
| | | { |
| | | var errorMsg = $"导å
¥å¤±è´¥ï¼é
ç½®ï¼ç¬¬{callMaterialOrderRecordDto.RowIndex}è¡ï¼{e.Message}ï¼ç»æ¢å¯¼å
¥"; |
| | | throw new UserFriendlyException(errorMsg); |
| | | } |
| | | } |
| | | |
| | | // æ´æ° |
| | | foreach (var callMaterialOrderRecordDto in callMaterialOrderRecordUpdateDtos) |
| | | { |
| | | try |
| | | { |
| | | await UpdateAsync(callMaterialOrderRecordDto.Id, callMaterialOrderRecordDto.Item); |
| | | } |
| | | catch (Exception e) |
| | | { |
| | | var errorMsg = $"导å
¥å¤±è´¥ï¼é
ç½®ï¼ç¬¬{callMaterialOrderRecordDto.RowIndex}è¡ï¼{e.Message}ï¼ç»æ¢å¯¼å
¥"; |
| | | throw new UserFriendlyException(errorMsg); |
| | | } |
| | | } |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 导åºå«æè®°å½è¡¨ |
| | | /// </summary> |
| | | /// <param name="input"></param> |
| | | /// <returns></returns> |
| | | public async Task<(Dictionary<string, object> Sheets, string FileName)> ExportAsync(GetCallMaterialOrderRecordInput input) |
| | | { |
| | | Check.NotNull(input, nameof(input)); |
| | | |
| | | if (input.Sorting.IsNullOrWhiteSpace()) |
| | | { |
| | | input.Sorting = nameof(CallMaterialOrderRecord.Sort); |
| | | } |
| | | |
| | | #region 卿æé æ¥è¯¢æ¡ä»¶ |
| | | |
| | | //卿æé æ¥è¯¢æ¡ä»¶ |
| | | var whereConditions = DynamicGetQueryParams(input); |
| | | |
| | | #endregion |
| | | |
| | | |
| | | var list = await callMaterialOrderRecordRepository.GetListAsync(whereConditions, input.Sorting, input.MaxResultCount, input.SkipCount, includeDetails: true); |
| | | var result = ObjectMapper.Map<List<CallMaterialOrderRecord>, List<CallMaterialOrderRecordDto>>(list); |
| | | |
| | | var sheets = new Dictionary<string, object> |
| | | { |
| | | ["é
ç½®"] = ExportHelper.ConvertListToExportData(result), |
| | | }; |
| | | |
| | | var fileName = "å«æè®°å½"; |
| | | return (sheets, fileName); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// æ ¡éªå«æè®°å½è¡¨ï¼å½æ°å»ºææ´æ°æ¶ |
| | | /// </summary> |
| | | /// <param name="input"></param> |
| | | /// <returns></returns> |
| | | protected Task CheckCreateOrUpdateDtoAsync(CallMaterialOrderRecordCreateOrUpdateDtoBase input) |
| | | { |
| | | Check.NotNull(input, nameof(input)); |
| | | Check.NotNullOrWhiteSpace(input.DataIdentifier, "åææ è¯", 256); |
| | | Check.NotNull(input.CallMaterialStatus, "å«æç¶æ"); |
| | | Check.NotNull(input.Quantity, "嫿æ°é"); |
| | | |
| | | return Task.CompletedTask; |
| | | } |
| | | } |
| | |
| | | using Microsoft.Extensions.DependencyInjection; |
| | | using Volo.Abp; |
| | | using Microsoft.Extensions.DependencyInjection; |
| | | using NPOI.Util; |
| | | using CMS.Plugin.PipeLineLems.Domain.CallMaterialOrder; |
| | | using CMS.Plugin.PipeLineLems.Application.Contracts.Services; |
| | | using CMS.Plugin.PipeLineLems.Application.Contracts.Dtos.CallMaterialOrder; |
| | | using Volo.Abp.Uow; |
| | | |
| | | namespace CMS.Plugin.PipeLineLems.Application.Implements; |
| | | |
| | |
| | | public class SharedService: CMSPluginAppService |
| | | { |
| | | |
| | | public async Task<MesOrderResponse> CommonCreatebyApsAsync(List<WorkPlanInput> input, IServiceProvider _serviceProvider, WorkPlanAppService workPlanAppService) |
| | | public async Task<MesOrderResponse> CommonCreatebyApsAsync(List<WorkPlanInput> input, IServiceProvider _serviceProvider, |
| | | WorkPlanAppService workPlanAppService |
| | | ) |
| | | { |
| | | if (input == null) |
| | | { |
| | |
| | | throw new UserFriendlyException("è¾å
¥åæ°Dataä¸è½ä¸ºç©º"); |
| | | } |
| | | |
| | | //æ ¡éªæ°æ® |
| | | //1ãåææ è¯ç¸åçä¸è½åå¨äºä¸¤ä¸ª 管段ç¼å·ä¸ |
| | | //var validationResult = ValidateUniqueDataIdentifierPerPipeSection(input); |
| | | //if (!validationResult.isValid) |
| | | //{ |
| | | // å¤çéªè¯å¤±è´¥çæ
åµ |
| | | // throw new UserFriendlyException($"éªè¯å¤±è´¥: {validationResult.errorMessage}"); |
| | | // è¿åé误信æ¯ç»å®¢æ·ç«¯æè¿è¡å
¶ä»å¤ç |
| | | //} |
| | | |
| | | |
| | | var callMaterialOrderAppService = _serviceProvider.GetRequiredService<ICallMaterialOrderAppService>(); |
| | | |
| | | var orderManager = _serviceProvider.GetRequiredService<IOrderManager>(); |
| | | var productProvider = _serviceProvider.GetRequiredService<IProductProvider>(); |
| | | var formulaProvider = _serviceProvider.GetRequiredService<IFormulaProvider>(); |
| | | List<OrderModel> orderModels = new List<OrderModel>(); |
| | | //æç
§ä»»å¡ç¼å·åç» |
| | | var groupTask = input.GroupBy(x => x.TaskCode); |
| | | |
| | | #region äºå¡ |
| | | |
| | | using var scope = _serviceProvider.CreateScope(); |
| | | var unitOfWorkManager = scope.ServiceProvider.GetRequiredService<IUnitOfWorkManager>(); |
| | | using var uow = unitOfWorkManager.Begin(requiresNew: true); |
| | | |
| | | try |
| | | { |
| | | #region æ°æ®å¤ç |
| | | |
| | | //æç
§ åææ è¯ åç» |
| | | var groupTask = input.GroupBy(x => x.DataIdentifier); |
| | | foreach (var gTask in groupTask) |
| | | { |
| | | var taskCode = gTask.Key; |
| | | var order = await orderManager.GetByCodeAsync(taskCode); |
| | | if (order != null) |
| | | { |
| | | throw new UserFriendlyException($"ä»»å¡ç¼å·[{taskCode}]å·²åå¨"); |
| | | } |
| | | |
| | | |
| | | |
| | | //var product = await productProvider.FindByNameAsync(orderItem.PipeSectionName); |
| | |
| | | { |
| | | throw new UserFriendlyException($"产ååç§°[åå²åæç®¡]æ å
³èé
æ¹"); |
| | | } |
| | | //åç»æ°æ® |
| | | var group = gTask.ToList().GroupBy(x => x.DataIdentifier); |
| | | //æç
§ 管段ç¼å· åç» |
| | | var group = gTask.ToList().GroupBy(x => x.PipeSpecCode); |
| | | foreach (var item in group) |
| | | { |
| | | var prodOrderNo = "Order_" + item.Key; |
| | | var order = await orderManager.GetByCodeAsync(prodOrderNo); |
| | | if (order != null) |
| | | { |
| | | throw new UserFriendlyException($"ç产工å[{prodOrderNo}]å·²åå¨"); |
| | | } |
| | | |
| | | OrderModel orderModelForCut = new OrderModel() |
| | | { |
| | | Id = Guid.NewGuid(), |
| | | Code = "Cut_" + taskCode, |
| | | Code = prodOrderNo, |
| | | Source = "APSæ¨é", |
| | | PlanStartTime = gTask.ToList().First().PlannedStartTime, |
| | | PlanFinishTime = gTask.ToList().First().PlannedEndTime, |
| | | PlanQty = (ulong)item.ToList().Count, |
| | | PlanQty = 1, |
| | | Status = OrderStatus.NotActive, |
| | | Product = new AssociationProductModel() { Id = productForCut.Id, Name = productForCut.Name, Model = productForCut.Model, ShortNumber = productForCut.ShortNumber }, |
| | | Formula = new AssociationFormulaModel() { Id = formulaForCut.Id, Code = formulaForCut.Code, Name = formulaForCut.Name } |
| | |
| | | orderModelForCut.ExtraProperties["OuterDiameter"] = gTask.ToList().First().OuterDiameter;//å¤å¾ |
| | | orderModelForCut.ExtraProperties["Material"] = gTask.ToList().First().Material;//æè´¨ |
| | | orderModelForCut.ExtraProperties["Length"] = gTask.ToList().First().Length;//é¿åº¦ |
| | | orderModelForCut.ExtraProperties["DataIdentifier"] = gTask.ToList().First().DataIdentifier;//åææ è¯ |
| | | orderModelForCut.ExtraProperties["MaterialMode"] = gTask.ToList().First().MaterialMode;//åæç±»å |
| | | orderModelForCut.ExtraProperties["PipeFittingCode"] = gTask.ToList().First().PipeFittingCode;//管段ç¼å· |
| | | |
| | | var orderForCut = await orderManager.GetByCodeAsync(orderModelForCut.Code); |
| | | if (orderForCut != null) |
| | |
| | | //orderModels.Add(orderModelResult); |
| | | } |
| | | |
| | | |
| | | //ä¿åå° scms_callmaterialorders è¡¨ä¸ |
| | | CallMaterialOrderCreateDto insertObjForOrder = new CallMaterialOrderCreateDto() |
| | | { |
| | | CallMaterialStatus = Domain.Shared.Enums.CallMaterialStatusEnum.æªæ§è¡, |
| | | DataIdentifier = gTask.Key, |
| | | MaterialMode = gTask.ToList().First().MaterialMode, |
| | | Quantity = 1 |
| | | }; |
| | | |
| | | await callMaterialOrderAppService.CreateAsync(insertObjForOrder); |
| | | } |
| | | |
| | | |
| | | //ä¿åå°è¡¨ä¸ |
| | | |
| | | |
| | | //ä¿åå° scms_workplans è¡¨ä¸ |
| | | foreach (var item in input) |
| | | { |
| | | var insertObj = ObjectMapper.Map<WorkPlanInput, WorkPlanCreateDto>(item); |
| | | //insertObj.OrgMaterialCode = "1111"; |
| | | insertObj.CallMaterialStatus = Domain.Shared.Enums.CallMaterialStatusEnum.æªæ§è¡; |
| | | insertObj.WorkPlanStatus = Domain.Shared.Enums.WorkPlanStatusEnum.æªæ§è¡; |
| | | insertObj.Sort = 1; |
| | | await workPlanAppService.CreateAsync(insertObj); |
| | | } |
| | | |
| | | #endregion |
| | | |
| | | await uow.CompleteAsync(); |
| | | } |
| | | catch (Exception) |
| | | { |
| | | |
| | | throw; |
| | | } |
| | | finally |
| | | { |
| | | await uow.RollbackAsync(); |
| | | } |
| | | |
| | | |
| | | |
| | | #endregion |
| | | |
| | | |
| | | |
| | | // åå¸äºä»¶ |
| | |
| | | return response; |
| | | } |
| | | |
| | | /// <summary> |
| | | /// éªè¯åææ è¯ç¸åçè®°å½ä¸è½åå¨äºä¸¤ä¸ªä¸åç管段ç¼å·ä¸ |
| | | /// </summary> |
| | | /// <param name="inputs">ä½ä¸è®¡åè¾å
¥åæ°å表</param> |
| | | /// <returns>éªè¯ç»æï¼å
嫿¯å¦éè¿éªè¯åé误信æ¯</returns> |
| | | public static (bool isValid, string errorMessage) ValidateUniqueDataIdentifierPerPipeSection(List<WorkPlanInput> inputs) |
| | | { |
| | | if (inputs == null || !inputs.Any()) |
| | | { |
| | | return (true, string.Empty); |
| | | } |
| | | |
| | | // 使ç¨Lookupåç»ï¼é®ä¸ºåææ è¯ï¼å¼ä¸ºå¯¹åºç管段ç¼å·éå |
| | | var dataIdentifierGroups = inputs.ToLookup(x => x.DataIdentifier, x => x.PipeSpecCode); |
| | | |
| | | foreach (var group in dataIdentifierGroups) |
| | | { |
| | | // 忽ç¥ç©ºçåææ è¯ |
| | | if (string.IsNullOrEmpty(group.Key)) |
| | | { |
| | | continue; |
| | | } |
| | | |
| | | // è·åå½ååææ è¯å¯¹åºçå¯ä¸ç®¡æ®µç¼å·éå |
| | | var uniquePipeSections = group.Distinct().ToList(); |
| | | |
| | | // 妿åå¨å¤ä¸ªä¸åç管段ç¼å·ï¼åè¿åè§å |
| | | if (uniquePipeSections.Count > 1) |
| | | { |
| | | return (false, $"åææ è¯ '{group.Key}' åå¨äºå¤ä¸ªä¸åç管段ç¼å·ä¸: {string.Join(", ", uniquePipeSections)}"); |
| | | } |
| | | } |
| | | |
| | | return (true, string.Empty); |
| | | } |
| | | } |
| | |
| | | using Volo.Abp.Data; |
| | | using Volo.Abp.ObjectExtending; |
| | | using Volo.Abp.ObjectMapping; |
| | | using CMS.Plugin.FormulaManagement.Abstractions; |
| | | using CMS.Plugin.OrderManagement.Abstractions.Enums; |
| | | using CMS.Plugin.OrderManagement.Abstractions.Models; |
| | | using CMS.Plugin.OrderManagement.Abstractions; |
| | | using CMS.Plugin.ProductManagement.Abstractions; |
| | | using Microsoft.Extensions.DependencyInjection; |
| | | |
| | | namespace CMS.Plugin.PipeLineLems.Application.Implements; |
| | | |
| | |
| | | public class WorkPlanAppService : CMSPluginAppService, IWorkPlanAppService |
| | | { |
| | | private readonly IWorkPlanRepository workPlanRepository; |
| | | private readonly IServiceProvider _serviceProvider; |
| | | private readonly SharedService _sharedService; |
| | | |
| | | private readonly IServiceProvider _serviceProvider; |
| | | /// <summary> |
| | | /// Initializes a new instance of the <see cref="WorkPlanAppService"/> class. |
| | | /// </summary> |
| | | /// <param name="WorkPlanRepository">The task job repository.</param> |
| | | public WorkPlanAppService(IWorkPlanRepository _WorkPlanRepository, IServiceProvider serviceProvider, SharedService sharedService) |
| | | public WorkPlanAppService(IWorkPlanRepository _WorkPlanRepository, SharedService sharedService, IServiceProvider serviceProvider) |
| | | { |
| | | workPlanRepository = _WorkPlanRepository; |
| | | _serviceProvider = serviceProvider; |
| | | _sharedService = sharedService; |
| | | _serviceProvider = serviceProvider; |
| | | } |
| | | |
| | | /// <summary> |
| | |
| | | input.MapExtraPropertiesTo(updateObj, MappingPropertyDefinitionChecks.None); |
| | | |
| | | updateObj.TaskCode = input.TaskCode; |
| | | updateObj.WorkPlanStatus = input.WorkPlanStatus; |
| | | updateObj.CallMaterialStatus = input.CallMaterialStatus; |
| | | updateObj.DataIdentifier = input.DataIdentifier; |
| | | updateObj.MaterialMode = input.MaterialMode; |
| | | updateObj.Length = input.Length; |
| | |
| | | updateObj.OuterDiameter = input.OuterDiameter; |
| | | updateObj.Thickness = input.Thickness; |
| | | updateObj.Material = input.Material; |
| | | |
| | | updateObj.ProcessRouteNumber = input.ProcessRouteNumber; |
| | | updateObj.PlannedStartTime = input.PlannedStartTime; |
| | | updateObj.PlannedEndTime = input.PlannedEndTime; |
| | |
| | | /// <exception cref="UserFriendlyException"></exception> |
| | | public async Task ImportAsync(WorkPlansImportModel input) |
| | | { |
| | | |
| | | //è½¬æ¢æ°æ® |
| | | var result = ObjectMapper.Map<List<WorkPlansImportModel.WorkPlanImportModel>, List<WorkPlanInput>>(input.WorkPlans); |
| | | |
| | | //await CreatebyApsAsync(result); |
| | | await _sharedService.CommonCreatebyApsAsync(result, _serviceProvider, this); |
| | | } |
| | | |
| | | |
| | | public async Task<MesOrderResponse> CreatebyApsAsync(List<WorkPlanInput> input) |
| | | { |
| | | var response=await _sharedService.CommonCreatebyApsAsync(input, _serviceProvider, this); |
| | | |
| | | return response; |
| | | } |
| | | |
| | | ///// <summary> |
| | | ///// 导å
¥ä½ä¸è®¡å表 |
| | | ///// </summary> |
| | | ///// <param name="input"></param> |
| | | ///// <returns></returns> |
| | | ///// <exception cref="UserFriendlyException"></exception> |
| | | //public async Task ImportAsync(WorkPlansImportModel input) |
| | | //{ |
| | | // Check.NotNull(input, nameof(input)); |
| | | |
| | | // var workPlanCreateDtos = new List<(int RowIndex, WorkPlanCreateDto Item)>(); |
| | |
| | | // var workPlanUpdateDto = new WorkPlanUpdateDto |
| | | // { |
| | | // TaskCode = impItem.TaskCode, |
| | | //WorkPlanStatus = impItem.WorkPlanStatus, |
| | | //CallMaterialStatus = impItem.CallMaterialStatus, |
| | | // DataIdentifier = impItem.DataIdentifier, |
| | | // MaterialMode = impItem.MaterialMode, |
| | | // Length = impItem.Length, |
| | |
| | | // OuterDiameter = impItem.OuterDiameter, |
| | | // Thickness = impItem.Thickness, |
| | | // Material = impItem.Material, |
| | | // HasMainSignature = impItem.HasMainSignature, |
| | | // ProcessRouteNumber = impItem.ProcessRouteNumber, |
| | | // PlannedStartTime = impItem.PlannedStartTime, |
| | | // PlannedEndTime = impItem.PlannedEndTime, |
| | |
| | | // var workPlanCreateDto = new WorkPlanCreateDto |
| | | // { |
| | | // TaskCode = impItem.TaskCode, |
| | | //WorkPlanStatus = impItem.WorkPlanStatus, |
| | | //CallMaterialStatus = impItem.CallMaterialStatus, |
| | | // DataIdentifier = impItem.DataIdentifier, |
| | | // MaterialMode = impItem.MaterialMode, |
| | | // Length = impItem.Length, |
| | |
| | | // OuterDiameter = impItem.OuterDiameter, |
| | | // Thickness = impItem.Thickness, |
| | | // Material = impItem.Material, |
| | | // HasMainSignature = impItem.HasMainSignature, |
| | | // ProcessRouteNumber = impItem.ProcessRouteNumber, |
| | | // PlannedStartTime = impItem.PlannedStartTime, |
| | | // PlannedEndTime = impItem.PlannedEndTime, |
| | |
| | | // throw new UserFriendlyException(errorMsg); |
| | | // } |
| | | // } |
| | | //} |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 导åºä½ä¸è®¡å表 |
| | |
| | | { |
| | | Check.NotNull(input, nameof(input)); |
| | | Check.NotNullOrWhiteSpace(input.TaskCode, "ä»»å¡ç¼ç ", 256); |
| | | Check.NotNull(input.WorkPlanStatus, "计åç¶æ"); |
| | | Check.NotNull(input.CallMaterialStatus, "å«æç¶æ"); |
| | | Check.NotNull(input.Length, "é¿åº¦(mm)"); |
| | | Check.NotNull(input.MarkingPosition, "æç ä½ç½®"); |
| | | Check.NotNull(input.CuttingPosition, "åå²ä½ç½®"); |
| | |
| | | Check.NotNull(input.PipeWallThickness, "å¥ç®¡ç´å¾(mm)"); |
| | | Check.NotNull(input.OuterDiameter, "å¤å¾(mm)"); |
| | | Check.NotNull(input.Thickness, "å£å(mm)"); |
| | | Check.NotNull(input.HasMainSignature, "æ¯å¦ä¸»æ¯ç®¡"); |
| | | |
| | | return Task.CompletedTask; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | using AutoMapper; |
| | | using CMS.Plugin.PipeLineLems.Application.Contracts.Dtos.CallMaterialOrder; |
| | | using CMS.Plugin.PipeLineLems.Domain.CallMaterialOrder; |
| | | using Volo.Abp.ObjectExtending; |
| | | |
| | | namespace CMS.Plugin.PipeLineLems.Application.MapperProfiles; |
| | | |
| | | /// <summary> |
| | | /// 嫿å表AutoMapperé
ç½® |
| | | /// </summary> |
| | | /// <seealso cref="AutoMapper.Profile" /> |
| | | public class CallMaterialOrderAutoMapperProfile : Profile |
| | | { |
| | | /// <summary> |
| | | /// Initializes a new instance of the <see cref="CallMaterialOrderAutoMapperProfile"/> class. |
| | | /// </summary> |
| | | public CallMaterialOrderAutoMapperProfile() |
| | | { |
| | | /* You can configure your AutoMapper mapping configuration here. |
| | | * Alternatively, you can split your mapping configurations |
| | | * into multiple profile classes for a better organization. */ |
| | | CreateMap<CallMaterialOrder, CallMaterialOrderDto>(MemberList.None).MapExtraProperties(MappingPropertyDefinitionChecks.None); |
| | | CreateMap<CallMaterialOrderCreateDto, CallMaterialOrder>(MemberList.None).MapExtraProperties(MappingPropertyDefinitionChecks.None); |
| | | CreateMap<GetCallMaterialOrderInput, CallMaterialOrder>(MemberList.None).MapExtraProperties(MappingPropertyDefinitionChecks.None); |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | using AutoMapper; |
| | | using CMS.Plugin.PipeLineLems.Application.Contracts.Dtos.CallMaterialOrderRecord; |
| | | using CMS.Plugin.PipeLineLems.Domain.CallMaterialOrderRecord; |
| | | using Volo.Abp.ObjectExtending; |
| | | |
| | | namespace CMS.Plugin.PipeLineLems.Application.MapperProfiles; |
| | | |
| | | /// <summary> |
| | | /// å«æè®°å½è¡¨AutoMapperé
ç½® |
| | | /// </summary> |
| | | /// <seealso cref="AutoMapper.Profile" /> |
| | | public class CallMaterialOrderRecordAutoMapperProfile : Profile |
| | | { |
| | | /// <summary> |
| | | /// Initializes a new instance of the <see cref="CallMaterialOrderRecordAutoMapperProfile"/> class. |
| | | /// </summary> |
| | | public CallMaterialOrderRecordAutoMapperProfile() |
| | | { |
| | | /* You can configure your AutoMapper mapping configuration here. |
| | | * Alternatively, you can split your mapping configurations |
| | | * into multiple profile classes for a better organization. */ |
| | | CreateMap<CallMaterialOrderRecord, CallMaterialOrderRecordDto>(MemberList.None).MapExtraProperties(MappingPropertyDefinitionChecks.None); |
| | | CreateMap<CallMaterialOrderRecordCreateDto, CallMaterialOrderRecord>(MemberList.None).MapExtraProperties(MappingPropertyDefinitionChecks.None); |
| | | CreateMap<GetCallMaterialOrderRecordInput, CallMaterialOrderRecord>(MemberList.None).MapExtraProperties(MappingPropertyDefinitionChecks.None); |
| | | } |
| | | } |
| | |
| | | CreateMap<WorkPlan, WorkPlanDto>(MemberList.None).MapExtraProperties(MappingPropertyDefinitionChecks.None); |
| | | CreateMap<WorkPlanCreateDto, WorkPlan>(MemberList.None).MapExtraProperties(MappingPropertyDefinitionChecks.None); |
| | | CreateMap<GetWorkPlanInput, WorkPlan>(MemberList.None).MapExtraProperties(MappingPropertyDefinitionChecks.None); |
| | | //CreateMap<WorkPlansImportModel.WorkPlanImportModel, WorkPlan>(MemberList.None); |
| | | //CreateMap<WorkPlansImportModel.WorkPlanImportModel, WorkPlanInput>(MemberList.None); |
| | | //CreateMap<WorkPlanInput, WorkPlanCreateDto>(MemberList.None); |
| | | } |
| | | } |
| | |
| | | /// <summary> |
| | | /// å«æç¶æ |
| | | /// </summary> |
| | | public enum CallMaterialStatusEnum : byte |
| | | public enum CallMaterialStatusEnum |
| | | { |
| | | /// <summary> |
| | | /// æªæ§è¡ |
| | | /// </summary> |
| | | [Description("æªæ§è¡")] |
| | | æªæ§è¡ = 0, |
| | | æªæ§è¡ = 1, |
| | | |
| | | /// <summary> |
| | | /// å«æä¸ |
| | | /// </summary> |
| | | [Description("嫿ä¸")] |
| | | å«æä¸ = 1, |
| | | å«æä¸ = 2, |
| | | |
| | | |
| | | /// <summary> |
| | |
| | | /// <summary> |
| | | /// PipeLineLemsç¶æ |
| | | /// </summary> |
| | | public enum PipeLineLemsStatus : byte |
| | | public enum PipeLineLemsStatus |
| | | { |
| | | /// <summary> |
| | | /// æªæ§è¡ |
| | | /// </summary> |
| | | [Description("æªæ§è¡")] |
| | | Initial = 0, |
| | | Initial = 1, |
| | | |
| | | /// <summary> |
| | | /// æ§è¡ä¸ |
| | | /// </summary> |
| | | [Description("æ§è¡ä¸")] |
| | | Excuting = 1, |
| | | Excuting = 2, |
| | | |
| | | /// <summary> |
| | | /// 已宿 |
| | |
| | | /// <summary> |
| | | /// ä½ä¸è®¡åç¶æ |
| | | /// </summary> |
| | | public enum WorkPlanStatusEnum : byte |
| | | public enum WorkPlanStatusEnum |
| | | { |
| | | /// <summary> |
| | | /// æªæ§è¡ |
| | | /// </summary> |
| | | [Description("æªæ§è¡")] |
| | | æªæ§è¡ = 0, |
| | | æªæ§è¡ = 1, |
| | | |
| | | /// <summary> |
| | | /// æ§è¡ä¸ |
| | | /// </summary> |
| | | [Description("æ§è¡ä¸")] |
| | | æ§è¡ä¸ = 1, |
| | | æ§è¡ä¸ = 2, |
| | | |
| | | /// <summary> |
| | | /// æåä¸ |
| | | /// </summary> |
| | | [Description("æåä¸")] |
| | | æåä¸ = 2, |
| | | æåä¸ = 3, |
| | | |
| | | /// <summary> |
| | | /// 已宿 |
¶Ô±ÈÐÂÎļþ |
| | |
| | | using CmsQueryExtensions.Extension; |
| | | using System.Linq.Expressions; |
| | | using Volo.Abp.Domain.Repositories; |
| | | |
| | | namespace CMS.Plugin.PipeLineLems.Domain.CallMaterialOrder; |
| | | |
| | | /// <summary> |
| | | /// 嫿å表ä»å¨ |
| | | /// </summary> |
| | | public interface ICallMaterialOrderRepository : IBasicRepository<CallMaterialOrder, Guid> |
| | | { |
| | | /// <summary> |
| | | /// æç
§åç§°æ¥æ¾å«æå表 |
| | | /// </summary> |
| | | /// <param name="name"></param> |
| | | /// <param name="cancellationToken"></param> |
| | | /// <returns></returns> |
| | | Task<CallMaterialOrder> FindByNameAsync(string name, CancellationToken cancellationToken = default); |
| | | |
| | | /// <summary> |
| | | /// éªè¯åç§°æ¯å¦åå¨å«æå表 |
| | | /// </summary> |
| | | /// <param name="name"></param> |
| | | /// <param name="id"></param> |
| | | /// <returns></returns> |
| | | Task<bool> NameExistAsync(string name, Guid? id = null); |
| | | |
| | | /// <summary> |
| | | /// è·åæå¤§æåºå«æå表 |
| | | /// </summary> |
| | | /// <returns></returns> |
| | | Task<int> GetMaxSortAsync(); |
| | | |
| | | /// <summary> |
| | | /// è·åå页åè¡¨å«æå表 |
| | | /// </summary> |
| | | /// <param name="whereConditions"></param> |
| | | /// <param name="sorting"></param> |
| | | /// <param name="maxResultCount"></param> |
| | | /// <param name="skipCount"></param> |
| | | /// <param name="includeDetails"></param> |
| | | /// <param name="cancellationToken"></param> |
| | | /// <returns></returns> |
| | | Task<List<CallMaterialOrder>> GetListAsync(FunReturnResultModel<Expression<Func<CallMaterialOrder, bool>>> whereConditions, string sorting = null, int maxResultCount = int.MaxValue, int skipCount = 0, bool includeDetails = false, CancellationToken cancellationToken = default); |
| | | |
| | | /// <summary> |
| | | /// è·åæ»æ°å«æå表 |
| | | /// </summary> |
| | | /// <param name="whereConditions"></param> |
| | | /// <param name="cancellationToken"></param> |
| | | /// <returns></returns> |
| | | Task<long> GetCountAsync(FunReturnResultModel<Expression<Func<CallMaterialOrder, bool>>> whereConditions, CancellationToken cancellationToken = default); |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | using CmsQueryExtensions.Extension; |
| | | using System.Linq.Expressions; |
| | | using Volo.Abp.Domain.Repositories; |
| | | |
| | | namespace CMS.Plugin.PipeLineLems.Domain.CallMaterialOrderRecord; |
| | | |
| | | /// <summary> |
| | | /// å«æè®°å½è¡¨ä»å¨ |
| | | /// </summary> |
| | | public interface ICallMaterialOrderRecordRepository : IBasicRepository<CallMaterialOrderRecord, Guid> |
| | | { |
| | | /// <summary> |
| | | /// æç
§åç§°æ¥æ¾å«æè®°å½è¡¨ |
| | | /// </summary> |
| | | /// <param name="name"></param> |
| | | /// <param name="cancellationToken"></param> |
| | | /// <returns></returns> |
| | | Task<CallMaterialOrderRecord> FindByNameAsync(string name, CancellationToken cancellationToken = default); |
| | | |
| | | /// <summary> |
| | | /// éªè¯åç§°æ¯å¦åå¨å«æè®°å½è¡¨ |
| | | /// </summary> |
| | | /// <param name="name"></param> |
| | | /// <param name="id"></param> |
| | | /// <returns></returns> |
| | | Task<bool> NameExistAsync(string name, Guid? id = null); |
| | | |
| | | /// <summary> |
| | | /// è·åæå¤§æåºå«æè®°å½è¡¨ |
| | | /// </summary> |
| | | /// <returns></returns> |
| | | Task<int> GetMaxSortAsync(); |
| | | |
| | | /// <summary> |
| | | /// è·åå页åè¡¨å«æè®°å½è¡¨ |
| | | /// </summary> |
| | | /// <param name="whereConditions"></param> |
| | | /// <param name="sorting"></param> |
| | | /// <param name="maxResultCount"></param> |
| | | /// <param name="skipCount"></param> |
| | | /// <param name="includeDetails"></param> |
| | | /// <param name="cancellationToken"></param> |
| | | /// <returns></returns> |
| | | Task<List<CallMaterialOrderRecord>> GetListAsync(FunReturnResultModel<Expression<Func<CallMaterialOrderRecord, bool>>> whereConditions, string sorting = null, int maxResultCount = int.MaxValue, int skipCount = 0, bool includeDetails = false, CancellationToken cancellationToken = default); |
| | | |
| | | /// <summary> |
| | | /// è·åæ»æ°å«æè®°å½è¡¨ |
| | | /// </summary> |
| | | /// <param name="whereConditions"></param> |
| | | /// <param name="cancellationToken"></param> |
| | | /// <returns></returns> |
| | | Task<long> GetCountAsync(FunReturnResultModel<Expression<Func<CallMaterialOrderRecord, bool>>> whereConditions, CancellationToken cancellationToken = default); |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | using CMS.Plugin.PipeLineLems.Domain.CallMaterialOrderRecord; |
| | | using CMS.Plugin.PipeLineLems.EntityFrameworkCore.Extensions; |
| | | using CmsQueryExtensions.Extension; |
| | | using Microsoft.EntityFrameworkCore; |
| | | using System.Linq.Dynamic.Core; |
| | | using System.Linq.Expressions; |
| | | using Volo.Abp.Domain.Repositories.EntityFrameworkCore; |
| | | using Volo.Abp.EntityFrameworkCore; |
| | | |
| | | |
| | | namespace CMS.Plugin.PipeLineLems.EntityFrameworkCore.Repositories; |
| | | |
| | | /// <summary> |
| | | /// å«æè®°å½è¡¨ä»å¨å®ç° |
| | | /// </summary> |
| | | public class EfCoreCallMaterialOrderRecordRepository : EfCoreRepository<ICMSPluginDbContext, CallMaterialOrderRecord, Guid>, ICallMaterialOrderRecordRepository |
| | | { |
| | | /// <summary> |
| | | /// Initializes a new instance of the <see cref="EfCoreCallMaterialOrderRecordRepository"/> class. |
| | | /// </summary> |
| | | /// <param name="dbContextProvider">The database context provider.</param> |
| | | public EfCoreCallMaterialOrderRecordRepository(IDbContextProvider<ICMSPluginDbContext> dbContextProvider) |
| | | : base(dbContextProvider) |
| | | { |
| | | } |
| | | |
| | | /// <summary> |
| | | /// æç
§åç§°æ¥æ¾å«æè®°å½è¡¨ |
| | | /// </summary> |
| | | /// <param name="name"></param> |
| | | /// <param name="cancellationToken"></param> |
| | | /// <returns></returns> |
| | | public virtual async Task<CallMaterialOrderRecord> FindByNameAsync(string name, CancellationToken cancellationToken = default) |
| | | { |
| | | return await (await GetDbSetAsync()) |
| | | .IncludeDetails() |
| | | .Where(x => !x.IsDeleted) |
| | | .OrderByDescending(x=>x.CreationTime) |
| | | .FirstOrDefaultAsync(t => t.DataIdentifier == name, GetCancellationToken(cancellationToken)); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// éªè¯åç§°æ¯å¦åå¨å«æè®°å½è¡¨ |
| | | /// </summary> |
| | | /// <param name="name">æ ¡éªå¼</param> |
| | | /// <param name="id"></param> |
| | | /// <returns></returns> |
| | | public async Task<bool> NameExistAsync(string name, Guid? id = null) |
| | | { |
| | | return await (await GetDbSetAsync()).WhereIf(id.HasValue, p => p.Id != id).Where(x => !x.IsDeleted).AnyAsync(x => x.DataIdentifier == name); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// è·åæå¤§æåºå«æè®°å½è¡¨ |
| | | /// </summary> |
| | | /// <returns></returns> |
| | | public async Task<int> GetMaxSortAsync() |
| | | { |
| | | var hasAny = await (await GetQueryableAsync()) |
| | | .Where(x => !x.IsDeleted).AnyAsync(); |
| | | if (!hasAny) |
| | | { |
| | | return 1; |
| | | } |
| | | |
| | | var sort = await (await GetQueryableAsync()) |
| | | .Where(x => !x.IsDeleted).MaxAsync(x => x.Sort); |
| | | return sort + 1; |
| | | } |
| | | |
| | | /// <summary> |
| | | /// è·åå页åè¡¨å«æè®°å½è¡¨ |
| | | /// </summary> |
| | | /// <param name="whereConditions"></param> |
| | | /// <param name="sorting"></param> |
| | | /// <param name="maxResultCount"></param> |
| | | /// <param name="skipCount"></param> |
| | | /// <param name="includeDetails"></param> |
| | | /// <param name="cancellationToken"></param> |
| | | /// <returns></returns> |
| | | public async Task<List<CallMaterialOrderRecord>> GetListAsync(FunReturnResultModel<Expression<Func<CallMaterialOrderRecord, bool>>> whereConditions, string sorting = null, int maxResultCount = int.MaxValue, int skipCount = 0, bool includeDetails = false, CancellationToken cancellationToken = default) |
| | | { |
| | | return await (await GetDbSetAsync()) |
| | | .IncludeDetails(includeDetails) |
| | | .WhereIf(whereConditions != null, whereConditions.data) |
| | | .Where(x => !x.IsDeleted) |
| | | .OrderByDescending(x=>x.CreationTime) |
| | | .PageBy(skipCount, maxResultCount) |
| | | .ToListAsync(GetCancellationToken(cancellationToken)); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// è·åæ»æ°å«æè®°å½è¡¨ |
| | | /// </summary> |
| | | /// <param name="whereConditions"></param> |
| | | /// <param name="cancellationToken"></param> |
| | | /// <returns></returns> |
| | | public async Task<long> GetCountAsync(FunReturnResultModel<Expression<Func<CallMaterialOrderRecord, bool>>> whereConditions, CancellationToken cancellationToken = default) |
| | | { |
| | | return await (await GetQueryableAsync()) |
| | | .WhereIf(whereConditions != null, whereConditions.data) |
| | | .Where(x => !x.IsDeleted) |
| | | .CountAsync(cancellationToken: GetCancellationToken(cancellationToken)); |
| | | } |
| | | |
| | | |
| | | /// <inheritdoc /> |
| | | public override async Task<IQueryable<CallMaterialOrderRecord>> WithDetailsAsync() |
| | | { |
| | | return (await GetQueryableAsync()) |
| | | .Where(x => !x.IsDeleted).IncludeDetails(); |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | using CMS.Plugin.PipeLineLems.Domain.CallMaterialOrder; |
| | | using CMS.Plugin.PipeLineLems.EntityFrameworkCore.Extensions; |
| | | using CmsQueryExtensions.Extension; |
| | | using Microsoft.EntityFrameworkCore; |
| | | using System.Linq.Dynamic.Core; |
| | | using System.Linq.Expressions; |
| | | using Volo.Abp.Domain.Repositories.EntityFrameworkCore; |
| | | using Volo.Abp.EntityFrameworkCore; |
| | | |
| | | |
| | | namespace CMS.Plugin.PipeLineLems.EntityFrameworkCore.Repositories; |
| | | |
| | | /// <summary> |
| | | /// 嫿å表ä»å¨å®ç° |
| | | /// </summary> |
| | | public class EfCoreCallMaterialOrderRepository : EfCoreRepository<ICMSPluginDbContext, CallMaterialOrder, Guid>, ICallMaterialOrderRepository |
| | | { |
| | | /// <summary> |
| | | /// Initializes a new instance of the <see cref="EfCoreCallMaterialOrderRepository"/> class. |
| | | /// </summary> |
| | | /// <param name="dbContextProvider">The database context provider.</param> |
| | | public EfCoreCallMaterialOrderRepository(IDbContextProvider<ICMSPluginDbContext> dbContextProvider) |
| | | : base(dbContextProvider) |
| | | { |
| | | } |
| | | |
| | | /// <summary> |
| | | /// æç
§åç§°æ¥æ¾å«æå表 |
| | | /// </summary> |
| | | /// <param name="name"></param> |
| | | /// <param name="cancellationToken"></param> |
| | | /// <returns></returns> |
| | | public virtual async Task<CallMaterialOrder> FindByNameAsync(string name, CancellationToken cancellationToken = default) |
| | | { |
| | | return await (await GetDbSetAsync()) |
| | | .IncludeDetails() |
| | | .Where(x => !x.IsDeleted) |
| | | .OrderByDescending(x=>x.CreationTime) |
| | | .FirstOrDefaultAsync(t => t.DataIdentifier == name, GetCancellationToken(cancellationToken)); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// éªè¯åç§°æ¯å¦åå¨å«æå表 |
| | | /// </summary> |
| | | /// <param name="name">æ ¡éªå¼</param> |
| | | /// <param name="id"></param> |
| | | /// <returns></returns> |
| | | public async Task<bool> NameExistAsync(string name, Guid? id = null) |
| | | { |
| | | return await (await GetDbSetAsync()).WhereIf(id.HasValue, p => p.Id != id).Where(x => !x.IsDeleted).AnyAsync(x => x.DataIdentifier == name); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// è·åæå¤§æåºå«æå表 |
| | | /// </summary> |
| | | /// <returns></returns> |
| | | public async Task<int> GetMaxSortAsync() |
| | | { |
| | | var hasAny = await (await GetQueryableAsync()) |
| | | .Where(x => !x.IsDeleted).AnyAsync(); |
| | | if (!hasAny) |
| | | { |
| | | return 1; |
| | | } |
| | | |
| | | var sort = await (await GetQueryableAsync()) |
| | | .Where(x => !x.IsDeleted).MaxAsync(x => x.Sort); |
| | | return sort + 1; |
| | | } |
| | | |
| | | /// <summary> |
| | | /// è·åå页åè¡¨å«æå表 |
| | | /// </summary> |
| | | /// <param name="whereConditions"></param> |
| | | /// <param name="sorting"></param> |
| | | /// <param name="maxResultCount"></param> |
| | | /// <param name="skipCount"></param> |
| | | /// <param name="includeDetails"></param> |
| | | /// <param name="cancellationToken"></param> |
| | | /// <returns></returns> |
| | | public async Task<List<CallMaterialOrder>> GetListAsync(FunReturnResultModel<Expression<Func<CallMaterialOrder, bool>>> whereConditions, string sorting = null, int maxResultCount = int.MaxValue, int skipCount = 0, bool includeDetails = false, CancellationToken cancellationToken = default) |
| | | { |
| | | return await (await GetDbSetAsync()) |
| | | .IncludeDetails(includeDetails) |
| | | .WhereIf(whereConditions != null, whereConditions.data) |
| | | .Where(x => !x.IsDeleted) |
| | | .OrderByDescending(x=>x.CreationTime) |
| | | .PageBy(skipCount, maxResultCount) |
| | | .ToListAsync(GetCancellationToken(cancellationToken)); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// è·åæ»æ°å«æå表 |
| | | /// </summary> |
| | | /// <param name="whereConditions"></param> |
| | | /// <param name="cancellationToken"></param> |
| | | /// <returns></returns> |
| | | public async Task<long> GetCountAsync(FunReturnResultModel<Expression<Func<CallMaterialOrder, bool>>> whereConditions, CancellationToken cancellationToken = default) |
| | | { |
| | | return await (await GetQueryableAsync()) |
| | | .WhereIf(whereConditions != null, whereConditions.data) |
| | | .Where(x => !x.IsDeleted) |
| | | .CountAsync(cancellationToken: GetCancellationToken(cancellationToken)); |
| | | } |
| | | |
| | | |
| | | /// <inheritdoc /> |
| | | public override async Task<IQueryable<CallMaterialOrder>> WithDetailsAsync() |
| | | { |
| | | return (await GetQueryableAsync()) |
| | | .Where(x => !x.IsDeleted).IncludeDetails(); |
| | | } |
| | | } |
ÎļþÃû´Ó PipeLineLems/server/src/CMS.Plugin.PipeLineLems.MySQL/Migrations/20250511025035_Update1.Designer.cs ÐÞ¸Ä |
| | |
| | | namespace CMS.Plugin.PipeLineLems.MySQL.Migrations |
| | | { |
| | | [DbContext(typeof(CMSPluginDbContext))] |
| | | [Migration("20250511025035_Update1")] |
| | | [Migration("20250511041027_Update1")] |
| | | partial class Update1 |
| | | { |
| | | protected override void BuildTargetModel(ModelBuilder modelBuilder) |
| | |
| | | .ValueGeneratedOnAdd() |
| | | .HasColumnType("char(36)"); |
| | | |
| | | b.Property<byte>("CallMaterialStatus") |
| | | .HasColumnType("tinyint unsigned") |
| | | b.Property<int>("CallMaterialStatus") |
| | | .HasColumnType("int") |
| | | .HasComment("å«æç¶æ"); |
| | | |
| | | b.Property<string>("ConcurrencyStamp") |
| | |
| | | .ValueGeneratedOnAdd() |
| | | .HasColumnType("char(36)"); |
| | | |
| | | b.Property<byte>("CallMaterialStatus") |
| | | .HasColumnType("tinyint unsigned") |
| | | b.Property<int>("CallMaterialStatus") |
| | | .HasColumnType("int") |
| | | .HasComment("å«æç¶æ"); |
| | | |
| | | b.Property<string>("ConcurrencyStamp") |
| | |
| | | .ValueGeneratedOnAdd() |
| | | .HasColumnType("char(36)"); |
| | | |
| | | b.Property<byte>("CallMaterialStatus") |
| | | .HasColumnType("tinyint unsigned") |
| | | b.Property<int>("CallMaterialStatus") |
| | | .HasColumnType("int") |
| | | .HasComment("å«æç¶æ"); |
| | | |
| | | b.Property<string>("ConcurrencyStamp") |
| | |
| | | .HasColumnType("varchar(256)") |
| | | .HasComment("æ³å
°å
¬ç§°åå"); |
| | | |
| | | b.Property<byte>("WorkPlanStatus") |
| | | .HasColumnType("tinyint unsigned") |
| | | b.Property<int>("WorkPlanStatus") |
| | | .HasColumnType("int") |
| | | .HasComment("计åç¶æ"); |
| | | |
| | | b.Property<string>("WorkpieceName") |
ÎļþÃû´Ó PipeLineLems/server/src/CMS.Plugin.PipeLineLems.MySQL/Migrations/20250511025035_Update1.cs ÐÞ¸Ä |
| | |
| | | .Annotation("MySql:CharSet", "utf8mb4"), |
| | | MaterialMode = table.Column<string>(type: "varchar(256)", maxLength: 256, nullable: true, comment: "åæåå·") |
| | | .Annotation("MySql:CharSet", "utf8mb4"), |
| | | CallMaterialStatus = table.Column<byte>(type: "tinyint unsigned", nullable: false, comment: "å«æç¶æ"), |
| | | CallMaterialStatus = table.Column<int>(type: "int", nullable: false, comment: "å«æç¶æ"), |
| | | Quantity = table.Column<int>(type: "int", nullable: false, comment: "嫿æ°é"), |
| | | WmsRetResult = table.Column<string>(type: "longtext", nullable: true, comment: "WMSè¿åç»æ") |
| | | .Annotation("MySql:CharSet", "utf8mb4"), |
| | |
| | | .Annotation("MySql:CharSet", "utf8mb4"), |
| | | MaterialMode = table.Column<string>(type: "varchar(256)", maxLength: 256, nullable: true, comment: "åæåå·") |
| | | .Annotation("MySql:CharSet", "utf8mb4"), |
| | | CallMaterialStatus = table.Column<byte>(type: "tinyint unsigned", nullable: false, comment: "å«æç¶æ"), |
| | | CallMaterialStatus = table.Column<int>(type: "int", nullable: false, comment: "å«æç¶æ"), |
| | | Quantity = table.Column<int>(type: "int", nullable: false, comment: "嫿æ°é"), |
| | | WmsRetResult = table.Column<string>(type: "longtext", nullable: true, comment: "WMSè¿åç»æ") |
| | | .Annotation("MySql:CharSet", "utf8mb4"), |
| | |
| | | Id = table.Column<Guid>(type: "char(36)", nullable: false, collation: "ascii_general_ci"), |
| | | TaskCode = table.Column<string>(type: "varchar(256)", maxLength: 256, nullable: false, comment: "ä»»å¡ç¼ç ") |
| | | .Annotation("MySql:CharSet", "utf8mb4"), |
| | | WorkPlanStatus = table.Column<byte>(type: "tinyint unsigned", nullable: false, comment: "计åç¶æ"), |
| | | CallMaterialStatus = table.Column<byte>(type: "tinyint unsigned", nullable: false, comment: "å«æç¶æ"), |
| | | WorkPlanStatus = table.Column<int>(type: "int", nullable: false, comment: "计åç¶æ"), |
| | | CallMaterialStatus = table.Column<int>(type: "int", nullable: false, comment: "å«æç¶æ"), |
| | | DataIdentifier = table.Column<string>(type: "varchar(256)", maxLength: 256, nullable: true, comment: "åææ è¯") |
| | | .Annotation("MySql:CharSet", "utf8mb4"), |
| | | MaterialMode = table.Column<string>(type: "varchar(256)", maxLength: 256, nullable: true, comment: "åæåå·") |
| | |
| | | .ValueGeneratedOnAdd() |
| | | .HasColumnType("char(36)"); |
| | | |
| | | b.Property<byte>("CallMaterialStatus") |
| | | .HasColumnType("tinyint unsigned") |
| | | b.Property<int>("CallMaterialStatus") |
| | | .HasColumnType("int") |
| | | .HasComment("å«æç¶æ"); |
| | | |
| | | b.Property<string>("ConcurrencyStamp") |
| | |
| | | .ValueGeneratedOnAdd() |
| | | .HasColumnType("char(36)"); |
| | | |
| | | b.Property<byte>("CallMaterialStatus") |
| | | .HasColumnType("tinyint unsigned") |
| | | b.Property<int>("CallMaterialStatus") |
| | | .HasColumnType("int") |
| | | .HasComment("å«æç¶æ"); |
| | | |
| | | b.Property<string>("ConcurrencyStamp") |
| | |
| | | .ValueGeneratedOnAdd() |
| | | .HasColumnType("char(36)"); |
| | | |
| | | b.Property<byte>("CallMaterialStatus") |
| | | .HasColumnType("tinyint unsigned") |
| | | b.Property<int>("CallMaterialStatus") |
| | | .HasColumnType("int") |
| | | .HasComment("å«æç¶æ"); |
| | | |
| | | b.Property<string>("ConcurrencyStamp") |
| | |
| | | .HasColumnType("varchar(256)") |
| | | .HasComment("æ³å
°å
¬ç§°åå"); |
| | | |
| | | b.Property<byte>("WorkPlanStatus") |
| | | .HasColumnType("tinyint unsigned") |
| | | b.Property<int>("WorkPlanStatus") |
| | | .HasColumnType("int") |
| | | .HasComment("计åç¶æ"); |
| | | |
| | | b.Property<string>("WorkpieceName") |
¶Ô±ÈÐÂÎļþ |
| | |
| | | using Ao.Lang; |
| | | using CMS.Extensions.Abp.AspNetCore.Mvc.Filters; |
| | | using CMS.Plugin.PipeLineLems.Application.Contracts.Dtos.CallMaterialOrder; |
| | | using CMS.Plugin.PipeLineLems.Application.Contracts.Services; |
| | | using Microsoft.AspNetCore.Authorization; |
| | | using Microsoft.AspNetCore.Http; |
| | | using Microsoft.AspNetCore.Mvc; |
| | | using MiniExcelLibs; |
| | | using System.Reflection; |
| | | using Volo.Abp; |
| | | using Volo.Abp.Application.Dtos; |
| | | |
| | | namespace CMS.Plugin.PipeLineLems.Controller |
| | | { |
| | | /// <summary> |
| | | /// 嫿å表æå¡ |
| | | /// </summary> |
| | | [ApiController] |
| | | [TypeFilter(typeof(CMSLanguageFilter))] |
| | | [TypeFilter(typeof(CMSUowActionFilter))] |
| | | [TypeFilter(typeof(CMSAuditActionFilter))] |
| | | [TypeFilter(typeof(CMSExceptionFilter))] |
| | | [Route("api/v{version:apiVersion}/PipeLineLems/[controller]")] |
| | | public class CallMaterialOrderController : ControllerBase |
| | | { |
| | | private readonly ICallMaterialOrderAppService _callMaterialOrderAppService; |
| | | |
| | | /// <summary> |
| | | /// Initializes a new instance of the <see cref="CallMaterialOrderController"/> class. |
| | | /// </summary> |
| | | /// <param name="callMaterialOrderAppService">The callMaterialOrder application service.</param> |
| | | public CallMaterialOrderController(ICallMaterialOrderAppService callMaterialOrderAppService) |
| | | { |
| | | _callMaterialOrderAppService = callMaterialOrderAppService; |
| | | } |
| | | |
| | | /// <summary> |
| | | /// è·å嫿å表 |
| | | /// </summary> |
| | | /// <param name="id">æ è¯ç¬¦.</param> |
| | | /// <returns></returns> |
| | | [HttpGet] |
| | | [Route("{id}")] |
| | | public virtual Task<CallMaterialOrderDto> GetAsync(Guid id) |
| | | { |
| | | return _callMaterialOrderAppService.GetAsync(id); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// å页è·å嫿å表çå表. |
| | | /// </summary> |
| | | /// <param name="input">è¾å
¥.</param> |
| | | /// <returns></returns> |
| | | [HttpGet] |
| | | [Route("Page")] |
| | | public virtual Task<PagedResultDto<CallMaterialOrderDto>> GetListAsync([FromQuery] GetCallMaterialOrderInput input) |
| | | { |
| | | return _callMaterialOrderAppService.GetListAsync(input); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// åå»ºå«æå表 |
| | | /// </summary> |
| | | /// <param name="input">è¾å
¥.</param> |
| | | /// <returns></returns> |
| | | //[Authorize] |
| | | [HttpPost] |
| | | public virtual Task<CallMaterialOrderDto> CreateAsync(CallMaterialOrderCreateDto input) |
| | | { |
| | | return _callMaterialOrderAppService.CreateAsync(input); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// æ´æ°å«æå表 |
| | | /// </summary> |
| | | /// <param name="id">æ è¯ç¬¦.</param> |
| | | /// <param name="input">è¾å
¥.</param> |
| | | /// <returns></returns> |
| | | //[Authorize] |
| | | [HttpPut] |
| | | [Route("{id}")] |
| | | public virtual Task<CallMaterialOrderDto> UpdateAsync(Guid id, CallMaterialOrderUpdateDto input) |
| | | { |
| | | return _callMaterialOrderAppService.UpdateAsync(id, input); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// å
é嫿å表 |
| | | /// </summary> |
| | | /// <param name="ids">Idéå.</param> |
| | | /// <returns></returns> |
| | | //[Authorize] |
| | | [HttpPost] |
| | | [Route("Clone")] |
| | | public virtual Task<List<CallMaterialOrderDto>> CloneAsync([FromBody] IEnumerable<Guid> ids) |
| | | { |
| | | return _callMaterialOrderAppService.CloneAsync(ids); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// å é¤å«æå表 |
| | | /// </summary> |
| | | /// <param name="id">æ è¯ç¬¦.</param> |
| | | /// <returns></returns> |
| | | //[Authorize] |
| | | [HttpDelete] |
| | | [Route("{id}")] |
| | | public virtual Task DeleteAsync(Guid id) |
| | | { |
| | | return _callMaterialOrderAppService.DeleteAsync(id); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// æ¹éå é¤å«æå表 |
| | | /// </summary> |
| | | /// <param name="ids">The ids.</param> |
| | | /// <returns></returns> |
| | | //[Authorize] |
| | | [HttpDelete] |
| | | public virtual Task DeleteAsync([FromBody] IEnumerable<Guid> ids) |
| | | { |
| | | return _callMaterialOrderAppService.DeleteManyAsync(ids); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// è°æ´æåºå«æå表 |
| | | /// </summary> |
| | | /// <param name="id">æ è¯ç¬¦.</param> |
| | | /// <returns></returns> |
| | | [HttpPut] |
| | | [Route("{id}/AdjustSort/{sort}")] |
| | | public virtual Task AdjustSortAsync(Guid id, int sort) |
| | | { |
| | | return _callMaterialOrderAppService.AdjustSortAsync(id, sort); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 导å
¥å«æå表 |
| | | /// </summary> |
| | | /// <returns></returns> |
| | | [Authorize] |
| | | [HttpPost] |
| | | [Route("Import")] |
| | | public virtual async Task<IActionResult> ImportAsync(IFormFile file) |
| | | { |
| | | using var stream = new MemoryStream(); |
| | | await file.CopyToAsync(stream); |
| | | stream.Seek(0L, SeekOrigin.Begin); |
| | | |
| | | var sheetNames = stream.GetSheetNames(); |
| | | var callMaterialOrderRows = sheetNames.Contains("é
ç½®") ? MiniExcel.Query<CallMaterialOrdersImportModel.CallMaterialOrderImportModel>(stream, sheetName: "é
ç½®").ToList() : new(); |
| | | |
| | | if (!callMaterialOrderRows.Any()) |
| | | { |
| | | throw new UserFriendlyException("è¯·æ£æ¥å¯¼å
¥çè¡¨æ ¼"); |
| | | } |
| | | |
| | | await _callMaterialOrderAppService.ImportAsync(new CallMaterialOrdersImportModel |
| | | { |
| | | CallMaterialOrders = callMaterialOrderRows, |
| | | }); |
| | | |
| | | return Ok(); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 导åºå«æå表 |
| | | /// </summary> |
| | | /// <returns></returns> |
| | | [HttpGet] |
| | | [Route("Export")] |
| | | public virtual async Task<IActionResult> ExportAsync([FromQuery] GetCallMaterialOrderInput input) |
| | | { |
| | | input.MaxResultCount = int.MaxValue; |
| | | var exportData = await _callMaterialOrderAppService.ExportAsync(input); |
| | | var templatePath = Path.Combine(AppDomain.CurrentDomain.BaseDirectory, $"Resources/Templates/CallMaterialOrderå¯¼åºæ¨¡æ¿.xlsx"); |
| | | if (!System.IO.File.Exists(templatePath)) |
| | | { |
| | | templatePath = Path.Combine(Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location) ?? string.Empty, $"Resources/Templates/CallMaterialOrderå¯¼åºæ¨¡æ¿.xlsx"); |
| | | } |
| | | |
| | | var memoryStream = new MemoryStream(); |
| | | await memoryStream.SaveAsByTemplateAsync(templatePath, exportData.Sheets); |
| | | memoryStream.Seek(0L, SeekOrigin.Begin); |
| | | return new FileStreamResult(memoryStream, "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet") { FileDownloadName = $"{exportData.FileName}_{DateTime.Now:yyyyMMddhhmmss}.xlsx" }; |
| | | } |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | using Ao.Lang; |
| | | using CMS.Extensions.Abp.AspNetCore.Mvc.Filters; |
| | | using CMS.Plugin.PipeLineLems.Application.Contracts.Dtos.CallMaterialOrderRecord; |
| | | using CMS.Plugin.PipeLineLems.Application.Contracts.Services; |
| | | using Microsoft.AspNetCore.Authorization; |
| | | using Microsoft.AspNetCore.Http; |
| | | using Microsoft.AspNetCore.Mvc; |
| | | using MiniExcelLibs; |
| | | using System.Reflection; |
| | | using Volo.Abp; |
| | | using Volo.Abp.Application.Dtos; |
| | | |
| | | namespace CMS.Plugin.PipeLineLems.Controller |
| | | { |
| | | /// <summary> |
| | | /// å«æè®°å½è¡¨æå¡ |
| | | /// </summary> |
| | | [ApiController] |
| | | [TypeFilter(typeof(CMSLanguageFilter))] |
| | | [TypeFilter(typeof(CMSUowActionFilter))] |
| | | [TypeFilter(typeof(CMSAuditActionFilter))] |
| | | [TypeFilter(typeof(CMSExceptionFilter))] |
| | | [Route("api/v{version:apiVersion}/PipeLineLems/[controller]")] |
| | | public class CallMaterialOrderRecordController : ControllerBase |
| | | { |
| | | private readonly ICallMaterialOrderRecordAppService _callMaterialOrderRecordAppService; |
| | | |
| | | /// <summary> |
| | | /// Initializes a new instance of the <see cref="CallMaterialOrderRecordController"/> class. |
| | | /// </summary> |
| | | /// <param name="callMaterialOrderRecordAppService">The callMaterialOrderRecord application service.</param> |
| | | public CallMaterialOrderRecordController(ICallMaterialOrderRecordAppService callMaterialOrderRecordAppService) |
| | | { |
| | | _callMaterialOrderRecordAppService = callMaterialOrderRecordAppService; |
| | | } |
| | | |
| | | /// <summary> |
| | | /// è·åå«æè®°å½è¡¨ |
| | | /// </summary> |
| | | /// <param name="id">æ è¯ç¬¦.</param> |
| | | /// <returns></returns> |
| | | [HttpGet] |
| | | [Route("{id}")] |
| | | public virtual Task<CallMaterialOrderRecordDto> GetAsync(Guid id) |
| | | { |
| | | return _callMaterialOrderRecordAppService.GetAsync(id); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// å页è·åå«æè®°å½è¡¨çå表. |
| | | /// </summary> |
| | | /// <param name="input">è¾å
¥.</param> |
| | | /// <returns></returns> |
| | | [HttpGet] |
| | | [Route("Page")] |
| | | public virtual Task<PagedResultDto<CallMaterialOrderRecordDto>> GetListAsync([FromQuery] GetCallMaterialOrderRecordInput input) |
| | | { |
| | | return _callMaterialOrderRecordAppService.GetListAsync(input); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// åå»ºå«æè®°å½è¡¨ |
| | | /// </summary> |
| | | /// <param name="input">è¾å
¥.</param> |
| | | /// <returns></returns> |
| | | //[Authorize] |
| | | [HttpPost] |
| | | public virtual Task<CallMaterialOrderRecordDto> CreateAsync(CallMaterialOrderRecordCreateDto input) |
| | | { |
| | | return _callMaterialOrderRecordAppService.CreateAsync(input); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// æ´æ°å«æè®°å½è¡¨ |
| | | /// </summary> |
| | | /// <param name="id">æ è¯ç¬¦.</param> |
| | | /// <param name="input">è¾å
¥.</param> |
| | | /// <returns></returns> |
| | | //[Authorize] |
| | | [HttpPut] |
| | | [Route("{id}")] |
| | | public virtual Task<CallMaterialOrderRecordDto> UpdateAsync(Guid id, CallMaterialOrderRecordUpdateDto input) |
| | | { |
| | | return _callMaterialOrderRecordAppService.UpdateAsync(id, input); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// å
éå«æè®°å½è¡¨ |
| | | /// </summary> |
| | | /// <param name="ids">Idéå.</param> |
| | | /// <returns></returns> |
| | | //[Authorize] |
| | | [HttpPost] |
| | | [Route("Clone")] |
| | | public virtual Task<List<CallMaterialOrderRecordDto>> CloneAsync([FromBody] IEnumerable<Guid> ids) |
| | | { |
| | | return _callMaterialOrderRecordAppService.CloneAsync(ids); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// å é¤å«æè®°å½è¡¨ |
| | | /// </summary> |
| | | /// <param name="id">æ è¯ç¬¦.</param> |
| | | /// <returns></returns> |
| | | //[Authorize] |
| | | [HttpDelete] |
| | | [Route("{id}")] |
| | | public virtual Task DeleteAsync(Guid id) |
| | | { |
| | | return _callMaterialOrderRecordAppService.DeleteAsync(id); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// æ¹éå é¤å«æè®°å½è¡¨ |
| | | /// </summary> |
| | | /// <param name="ids">The ids.</param> |
| | | /// <returns></returns> |
| | | //[Authorize] |
| | | [HttpDelete] |
| | | public virtual Task DeleteAsync([FromBody] IEnumerable<Guid> ids) |
| | | { |
| | | return _callMaterialOrderRecordAppService.DeleteManyAsync(ids); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// è°æ´æåºå«æè®°å½è¡¨ |
| | | /// </summary> |
| | | /// <param name="id">æ è¯ç¬¦.</param> |
| | | /// <returns></returns> |
| | | [HttpPut] |
| | | [Route("{id}/AdjustSort/{sort}")] |
| | | public virtual Task AdjustSortAsync(Guid id, int sort) |
| | | { |
| | | return _callMaterialOrderRecordAppService.AdjustSortAsync(id, sort); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 导å
¥å«æè®°å½è¡¨ |
| | | /// </summary> |
| | | /// <returns></returns> |
| | | [Authorize] |
| | | [HttpPost] |
| | | [Route("Import")] |
| | | public virtual async Task<IActionResult> ImportAsync(IFormFile file) |
| | | { |
| | | using var stream = new MemoryStream(); |
| | | await file.CopyToAsync(stream); |
| | | stream.Seek(0L, SeekOrigin.Begin); |
| | | |
| | | var sheetNames = stream.GetSheetNames(); |
| | | var callMaterialOrderRecordRows = sheetNames.Contains("é
ç½®") ? MiniExcel.Query<CallMaterialOrderRecordsImportModel.CallMaterialOrderRecordImportModel>(stream, sheetName: "é
ç½®").ToList() : new(); |
| | | |
| | | if (!callMaterialOrderRecordRows.Any()) |
| | | { |
| | | throw new UserFriendlyException("è¯·æ£æ¥å¯¼å
¥çè¡¨æ ¼"); |
| | | } |
| | | |
| | | await _callMaterialOrderRecordAppService.ImportAsync(new CallMaterialOrderRecordsImportModel |
| | | { |
| | | CallMaterialOrderRecords = callMaterialOrderRecordRows, |
| | | }); |
| | | |
| | | return Ok(); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 导åºå«æè®°å½è¡¨ |
| | | /// </summary> |
| | | /// <returns></returns> |
| | | [HttpGet] |
| | | [Route("Export")] |
| | | public virtual async Task<IActionResult> ExportAsync([FromQuery] GetCallMaterialOrderRecordInput input) |
| | | { |
| | | input.MaxResultCount = int.MaxValue; |
| | | var exportData = await _callMaterialOrderRecordAppService.ExportAsync(input); |
| | | var templatePath = Path.Combine(AppDomain.CurrentDomain.BaseDirectory, $"Resources/Templates/CallMaterialOrderRecordå¯¼åºæ¨¡æ¿.xlsx"); |
| | | if (!System.IO.File.Exists(templatePath)) |
| | | { |
| | | templatePath = Path.Combine(Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location) ?? string.Empty, $"Resources/Templates/CallMaterialOrderRecordå¯¼åºæ¨¡æ¿.xlsx"); |
| | | } |
| | | |
| | | var memoryStream = new MemoryStream(); |
| | | await memoryStream.SaveAsByTemplateAsync(templatePath, exportData.Sheets); |
| | | memoryStream.Seek(0L, SeekOrigin.Begin); |
| | | return new FileStreamResult(memoryStream, "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet") { FileDownloadName = $"{exportData.FileName}_{DateTime.Now:yyyyMMddhhmmss}.xlsx" }; |
| | | } |
| | | } |
| | | } |
| | |
| | | using Ao.Lang; |
| | | using AutoMapper.Internal.Mappers; |
| | | using CMS.Extensions.Abp.AspNetCore.Mvc.Filters; |
| | | using CMS.Plugin.PipeLineLems.Application.Contracts.Dtos.WorkPlan; |
| | | using CMS.Plugin.PipeLineLems.Application.Contracts.Services; |
| | | using CMS.Plugin.PipeLineLems.Application.Implements; |
| | | using CMS.Plugin.PipeLineLems.Domain.WorkPlan; |
| | | using Microsoft.AspNetCore.Authorization; |
| | | using Microsoft.AspNetCore.Http; |
| | | using Microsoft.AspNetCore.Mvc; |
| | |
| | | public class WorkPlanController : ControllerBase |
| | | { |
| | | private readonly IWorkPlanAppService _workPlanAppService; |
| | | |
| | | |
| | | /// <summary> |
| | | /// è·åç产计å. |
| | | /// </summary> |
| | | /// <param name="input">æ è¯ç¬¦.</param> |
| | | /// <returns></returns> |
| | | [HttpPost] |
| | | [Route("GetWorkPlanByAps")] |
| | | public virtual async Task<MesOrderResponse> CreateWorkPlanByApsAsync([FromBody] List<WorkPlanInput> input) |
| | | { |
| | | return await _workPlanAppService.CreatebyApsAsync(input); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// Initializes a new instance of the <see cref="WorkPlanController"/> class. |
| | |
| | | { |
| | | throw new UserFriendlyException("è¯·æ£æ¥å¯¼å
¥çè¡¨æ ¼"); |
| | | } |
| | | |
| | | |
| | | await _workPlanAppService.ImportAsync(new WorkPlansImportModel |
| | | { |