|
|
|
@ -1,5 +1,6 @@ |
|
|
|
|
using Microsoft.AspNetCore.Mvc; |
|
|
|
|
using Microsoft.Extensions.Logging; |
|
|
|
|
using Mysqlx.Expr; |
|
|
|
|
using System.Text.RegularExpressions; |
|
|
|
|
|
|
|
|
|
namespace Tiobon.Core.Services; |
|
|
|
@ -8,10 +9,12 @@ public partial class CommonServices : BaseServices<RootEntityTkey<int>>, ICommon |
|
|
|
|
{ |
|
|
|
|
IHttpContextAccessor _httpContextAccessor; |
|
|
|
|
ILogger<PayServices> _logger; |
|
|
|
|
public CommonServices(ILogger<PayServices> logger, IHttpContextAccessor httpContextAccessor) |
|
|
|
|
public ICaching _caching; |
|
|
|
|
public CommonServices(ILogger<PayServices> logger, IHttpContextAccessor httpContextAccessor, ICaching caching = null) |
|
|
|
|
{ |
|
|
|
|
_logger = logger; |
|
|
|
|
_httpContextAccessor = httpContextAccessor; |
|
|
|
|
_caching = caching; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
#region 获取菜单 |
|
|
|
@ -1929,7 +1932,7 @@ public partial class CommonServices : BaseServices<RootEntityTkey<int>>, ICommon |
|
|
|
|
if (toolbar != null) toolbar.fnKey = "TBD4YN"; |
|
|
|
|
|
|
|
|
|
result.DT_Procedure.ExportExcel = "/api/Ghrh_HumanRequest/ExportCompleteExcel"; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var name2 = await QueryLangValue("F_ResumeMaintenance_0226", "编制内"); |
|
|
|
|
var name3 = await QueryLangValue("F_ResumeMaintenance_0227", "编制外"); |
|
|
|
|
result.JM_TableColumnT1.TableColumn?.ForEach(x => |
|
|
|
@ -1947,12 +1950,14 @@ public partial class CommonServices : BaseServices<RootEntityTkey<int>>, ICommon |
|
|
|
|
} |
|
|
|
|
}); |
|
|
|
|
result.JM_TableColumnT1.TableColumn = result.JM_TableColumnT1.TableColumn.OrderBy(x => x.SortNo).ToList(); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
break; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
#endregion |
|
|
|
|
|
|
|
|
|
result.DT_PageMutiMsg = await _caching.GetAsync<List<DT_PageMutiMsg>>(param.menuName + "_DT_PageMutiMsg"); |
|
|
|
|
|
|
|
|
|
#region 多语返回处理 |
|
|
|
|
if (param.menuName == "F_ResumeMaintenance_All" || |
|
|
|
|
param.menuName == "F_ResumeMaintenance_Process" || |
|
|
|
@ -1986,7 +1991,11 @@ public partial class CommonServices : BaseServices<RootEntityTkey<int>>, ICommon |
|
|
|
|
} |
|
|
|
|
#endregion |
|
|
|
|
|
|
|
|
|
result.DT_PageMutiMsg = Db.Ado.SqlQuery<DT_PageMutiMsg>(sqlLang); |
|
|
|
|
if (result.DT_PageMutiMsg is null) |
|
|
|
|
{ |
|
|
|
|
result.DT_PageMutiMsg = Db.Ado.SqlQuery<DT_PageMutiMsg>(sqlLang); |
|
|
|
|
await _caching.SetAsync(param.menuName + "_DT_PageMutiMsg", result.DT_PageMutiMsg, TimeSpan.FromMinutes(5)); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
return new ServiceResult<ModuleReturn>() { Success = true, Message = "查询成功", Data = result, }; |
|
|
|
|
} |
|
|
|
|