修改参与人员导表
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/push Build is passing
Details
parent
86c871bc9f
commit
8111b60d4f
|
@ -80,7 +80,24 @@ namespace IRaCIS.Core.Application.Service.Common
|
||||||
t => t.UserRole.OrganizationName.Contains(param.OrganizationName))
|
t => t.UserRole.OrganizationName.Contains(param.OrganizationName))
|
||||||
.WhereIf(!string.IsNullOrWhiteSpace(param.UserRealName),
|
.WhereIf(!string.IsNullOrWhiteSpace(param.UserRealName),
|
||||||
t => (t.UserRole.FullName).Contains(param.UserRealName))
|
t => (t.UserRole.FullName).Contains(param.UserRealName))
|
||||||
.ProjectTo<TrialMaintenanceDTO>(_mapper.ConfigurationProvider).ToListAsync();
|
.Select(t=>new TrialMaintenanceDTO()
|
||||||
|
{
|
||||||
|
UserRealName=t.UserRole.IdentityUser.FullName,
|
||||||
|
UserName=t.UserRole.IdentityUser.UserName,
|
||||||
|
UserType=t.UserRole.UserTypeRole.UserTypeShortName,
|
||||||
|
Phone=t.UserRole.IdentityUser.Phone,
|
||||||
|
EMail=t.UserRole.IdentityUser.EMail,
|
||||||
|
OrganizationName= t.UserRole.IdentityUser.OrganizationName,
|
||||||
|
|
||||||
|
IsDeleted=t.TrialUser.IsDeleted,
|
||||||
|
JoinTime=t.TrialUser.JoinTime,
|
||||||
|
RemoveTime=t.TrialUser.RemoveTime,
|
||||||
|
|
||||||
|
//角色授权禁用时间
|
||||||
|
CreateTime=t.CreateTime,
|
||||||
|
DeletedTime=t.DeletedTime,
|
||||||
|
}).OrderBy(t=>t.UserRealName)
|
||||||
|
.ToListAsync();
|
||||||
|
|
||||||
exportInfo.List = ExportExcelConverterDate.ConvertToClientTimeInObject(list, _userInfo.TimeZoneId);
|
exportInfo.List = ExportExcelConverterDate.ConvertToClientTimeInObject(list, _userInfo.TimeZoneId);
|
||||||
exportInfo.CurrentTime = ExportExcelConverterDate.DateTimeInternationalToString(DateTime.Now, _userInfo.TimeZoneId);
|
exportInfo.CurrentTime = ExportExcelConverterDate.DateTimeInternationalToString(DateTime.Now, _userInfo.TimeZoneId);
|
||||||
|
|
|
@ -96,38 +96,22 @@ namespace IRaCIS.Application.Contracts
|
||||||
|
|
||||||
public class TrialMaintenanceDTO : UserTrialCommand
|
public class TrialMaintenanceDTO : UserTrialCommand
|
||||||
{
|
{
|
||||||
//[JsonIgnore]
|
|
||||||
//public int No { get; set; }
|
|
||||||
//For MiniExcel ExcelFormat
|
|
||||||
public string State => IsDeleted ? "退出" : "加入";
|
|
||||||
|
|
||||||
|
|
||||||
//[ValueMapping(text: "退出", true)]
|
|
||||||
//[ValueMapping(text: "加入", false)]
|
|
||||||
|
|
||||||
[DictionaryTranslateAttribute("IsUserExitTrial")]
|
[DictionaryTranslateAttribute("IsUserExitTrial")]
|
||||||
public bool IsDeleted { get; set; }
|
public bool IsDeleted { get; set; }
|
||||||
|
|
||||||
//[ExporterHeader(Format = "yyyy-mm-DD hh:mm:ss")]
|
|
||||||
[ExcelFormat("yyyy-MM-dd hh:mm:ss")]
|
|
||||||
public DateTime? DeletedTime { get; set; }
|
public DateTime? DeletedTime { get; set; }
|
||||||
|
|
||||||
|
|
||||||
//[ExporterHeader(Format = "yyyy-mm-DD")]
|
|
||||||
[ExcelFormat("yyyy-MM-dd")]
|
|
||||||
public DateTime? RemoveTime { get; set; }
|
public DateTime? RemoveTime { get; set; }
|
||||||
|
|
||||||
public string RemoveTimeStr => RemoveTime?.ToString("yyyy-MM-dd") ?? string.Empty;
|
public string RemoveTimeStr => RemoveTime?.ToString("yyyy-MM-dd") ?? string.Empty;
|
||||||
|
|
||||||
|
|
||||||
//[ExporterHeader(Format = "yyyy-mm-DD")]
|
|
||||||
[ExcelFormat("yyyy-MM-dd")]
|
|
||||||
public DateTime? JoinTime { get; set; }
|
public DateTime? JoinTime { get; set; }
|
||||||
|
|
||||||
public string JoinTimeStr => JoinTime?.ToString("yyyy-MM-dd") ?? string.Empty;
|
public string JoinTimeStr => JoinTime?.ToString("yyyy-MM-dd") ?? string.Empty;
|
||||||
|
|
||||||
//[ExporterHeader(Format = "yyyy-mm-DD hh:mm:ss")]
|
|
||||||
[ExcelFormat("yyyy-MM-dd HH:mm:ss")]
|
|
||||||
public DateTime CreateTime { get; set; }
|
public DateTime CreateTime { get; set; }
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -7,6 +7,7 @@ using IRaCIS.Core.Domain.Models;
|
||||||
using IRaCIS.Core.Domain.Share;
|
using IRaCIS.Core.Domain.Share;
|
||||||
using MassTransit.Serialization;
|
using MassTransit.Serialization;
|
||||||
using Microsoft.AspNetCore.Mvc;
|
using Microsoft.AspNetCore.Mvc;
|
||||||
|
using Microsoft.EntityFrameworkCore.Storage.Json;
|
||||||
using System;
|
using System;
|
||||||
|
|
||||||
namespace IRaCIS.Core.Application.Service
|
namespace IRaCIS.Core.Application.Service
|
||||||
|
@ -114,7 +115,10 @@ namespace IRaCIS.Core.Application.Service
|
||||||
[HttpPut]
|
[HttpPut]
|
||||||
public async Task<IResponseOutput> UpdateTrialUserRole(UpdateTrialUserRoleCommand updateCommand)
|
public async Task<IResponseOutput> UpdateTrialUserRole(UpdateTrialUserRoleCommand updateCommand)
|
||||||
{
|
{
|
||||||
await _trialUseRoleRepository.UpdatePartialFromQueryAsync(t => updateCommand.IdList.Contains(t.Id), u => new TrialUserRole() { IsDeleted = updateCommand.IsDeleted }, true, true);
|
|
||||||
|
DateTime? deleteTime = updateCommand.IsDeleted ? DateTime.Now : null;
|
||||||
|
|
||||||
|
await _trialUseRoleRepository.UpdatePartialFromQueryAsync(t => updateCommand.IdList.Contains(t.Id), u => new TrialUserRole() { IsDeleted = updateCommand.IsDeleted, DeletedTime = deleteTime }, true, true);
|
||||||
|
|
||||||
return ResponseOutput.Ok();
|
return ResponseOutput.Ok();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue