生产管理-生产工单排产代码调整
This commit is contained in:
@@ -31,4 +31,11 @@ public interface IDictionaryDataService
|
||||
/// <param name="key"></param>
|
||||
/// <returns></returns>
|
||||
Task<Dictionary<string, object>> GetDicByKey(string key);
|
||||
|
||||
/// <summary>
|
||||
/// 根据typeId获取字典
|
||||
/// </summary>
|
||||
/// <param name="typeId"></param>
|
||||
/// <returns></returns>
|
||||
Task<Dictionary<string, object>> GetDicByTypeId(string typeId);
|
||||
}
|
||||
@@ -1,4 +1,5 @@
|
||||
using JNPF.Common.Core.Manager;
|
||||
using JNPF.ClayObject.Extensions;
|
||||
using JNPF.Common.Core.Manager;
|
||||
using JNPF.Common.Core.Manager.Files;
|
||||
using JNPF.Common.Enums;
|
||||
using JNPF.Common.Manager;
|
||||
@@ -338,9 +339,15 @@ public class DictionaryDataService : IDictionaryDataService, IDynamicApiControll
|
||||
return await _repository.AsSugarClient().Queryable<DictionaryDataEntity>()
|
||||
.LeftJoin<DictionaryTypeEntity>((a, b) => a.DictionaryTypeId == b.Id)
|
||||
.Where((a, b) => b.EnCode == key && b.DeleteMark == null)
|
||||
.ToDictionaryAsync((it)=>it.EnCode,it=>it.FullName);
|
||||
.ToDictionaryAsync((it) => it.EnCode, it => it.FullName);
|
||||
}
|
||||
|
||||
public async Task<Dictionary<string, object>> GetDicByTypeId(string typeId) =>
|
||||
await _repository.AsQueryable().Where(x => x.DictionaryTypeId == typeId).ToDictionaryAsync(x => x.EnCode, x => x.FullName);
|
||||
|
||||
|
||||
|
||||
|
||||
#endregion
|
||||
|
||||
#region PrivateMethod
|
||||
|
||||
Reference in New Issue
Block a user