课题组增加状态
parent
df6b89b3be
commit
d48ffc5051
|
|
@ -49,6 +49,8 @@ public class HospitalGroupQuery : PageInput
|
|||
public string? ContactPhone { get; set; }
|
||||
|
||||
public string? Name { get; set; }
|
||||
|
||||
public bool? IsEnable { get; set; }
|
||||
}
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -47,6 +47,7 @@ public class HospitalGroupService(IRepository<HospitalGroup> _hospitalGroupRepos
|
|||
.WhereIf(!string.IsNullOrWhiteSpace(inQuery.Affiliation), t => t.Affiliation.Contains(inQuery.Affiliation))
|
||||
.WhereIf(!string.IsNullOrWhiteSpace(inQuery.ContactPhone), t => t.ContactPhone.Contains(inQuery.ContactPhone))
|
||||
.WhereIf(!string.IsNullOrWhiteSpace(inQuery.ContactName), t => t.ContactName.Contains(inQuery.ContactName))
|
||||
.WhereIf(!inQuery.IsEnable != null, t => t.IsEnable == inQuery.IsEnable)
|
||||
.ProjectTo<HospitalGroupView>(_mapper.ConfigurationProvider);
|
||||
|
||||
var pageList = await hospitalGroupQueryable.SortToListAsync(inQuery);
|
||||
|
|
@ -69,6 +70,7 @@ public class HospitalGroupService(IRepository<HospitalGroup> _hospitalGroupRepos
|
|||
.WhereIf(!string.IsNullOrWhiteSpace(inQuery.Affiliation), t => t.Affiliation.Contains(inQuery.Affiliation))
|
||||
.WhereIf(!string.IsNullOrWhiteSpace(inQuery.ContactPhone), t => t.ContactPhone.Contains(inQuery.ContactPhone))
|
||||
.WhereIf(!string.IsNullOrWhiteSpace(inQuery.ContactName), t => t.ContactName.Contains(inQuery.ContactName))
|
||||
.WhereIf(!inQuery.IsEnable != null, t => t.IsEnable == inQuery.IsEnable)
|
||||
.ProjectTo<HospitalGroupView>(_mapper.ConfigurationProvider);
|
||||
|
||||
var pageList = await hospitalGroupQueryable.ToPagedListAsync(inQuery);
|
||||
|
|
|
|||
|
|
@ -31,7 +31,7 @@ namespace IRaCIS.Core.Domain.Models
|
|||
public string ContactPhone { get; set; }
|
||||
|
||||
|
||||
|
||||
public bool IsEnable { get; set; }
|
||||
|
||||
}
|
||||
|
||||
|
|
|
|||
18828
IRaCIS.Core.Infra.EFCore/Migrations/20250820061139_hospitalisEnable.Designer.cs
generated
Normal file
18828
IRaCIS.Core.Infra.EFCore/Migrations/20250820061139_hospitalisEnable.Designer.cs
generated
Normal file
File diff suppressed because it is too large
Load Diff
|
|
@ -0,0 +1,29 @@
|
|||
using Microsoft.EntityFrameworkCore.Migrations;
|
||||
|
||||
#nullable disable
|
||||
|
||||
namespace IRaCIS.Core.Infra.EFCore.Migrations
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public partial class hospitalisEnable : Migration
|
||||
{
|
||||
/// <inheritdoc />
|
||||
protected override void Up(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.AddColumn<bool>(
|
||||
name: "IsEnable",
|
||||
table: "HospitalGroup",
|
||||
type: "bit",
|
||||
nullable: false,
|
||||
defaultValue: false);
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
protected override void Down(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.DropColumn(
|
||||
name: "IsEnable",
|
||||
table: "HospitalGroup");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -2807,6 +2807,9 @@ namespace IRaCIS.Core.Infra.EFCore.Migrations
|
|||
b.Property<Guid>("CreateUserId")
|
||||
.HasColumnType("uniqueidentifier");
|
||||
|
||||
b.Property<bool>("IsEnable")
|
||||
.HasColumnType("bit");
|
||||
|
||||
b.Property<string>("Name")
|
||||
.IsRequired()
|
||||
.HasMaxLength(400)
|
||||
|
|
@ -17623,7 +17626,7 @@ namespace IRaCIS.Core.Infra.EFCore.Migrations
|
|||
.IsRequired();
|
||||
|
||||
b.HasOne("IRaCIS.Core.Domain.Models.Trial", "Trial")
|
||||
.WithMany()
|
||||
.WithMany("TrialIdentityUserList")
|
||||
.HasForeignKey("TrialId")
|
||||
.OnDelete(DeleteBehavior.Cascade)
|
||||
.IsRequired();
|
||||
|
|
@ -18707,6 +18710,8 @@ namespace IRaCIS.Core.Infra.EFCore.Migrations
|
|||
|
||||
b.Navigation("TrialDicList");
|
||||
|
||||
b.Navigation("TrialIdentityUserList");
|
||||
|
||||
b.Navigation("TrialReadingCriterionList");
|
||||
|
||||
b.Navigation("TrialSiteList");
|
||||
|
|
|
|||
Loading…
Reference in New Issue