DESKTOP-G961P6V\Zhh 2 years ago
parent
commit
3837359ee4
  1. 6
      src/Shentun.Peis.Application.Contracts/RegisterCheckPictures/UploadRegisterCheckPictureManyDto.cs
  2. 3
      src/Shentun.Peis.Application/RegisterCheckPictures/RegisterCheckPictureAppService.cs
  3. 7
      src/Shentun.Peis.Domain/RegisterCheckPictures/RegisterCheckPicture.cs
  4. 3
      src/Shentun.Peis.EntityFrameworkCore/DbMapping/RegisterCheckPictures/RegisterCheckPictureDbMapping.cs
  5. 14294
      src/Shentun.Peis.EntityFrameworkCore/Migrations/20240516100718_init20240515002.Designer.cs
  6. 28
      src/Shentun.Peis.EntityFrameworkCore/Migrations/20240516100718_init20240515002.cs
  7. 8
      src/Shentun.Peis.EntityFrameworkCore/Migrations/PeisDbContextModelSnapshot.cs

6
src/Shentun.Peis.Application.Contracts/RegisterCheckPictures/UploadRegisterCheckPictureManyDto.cs

@ -3,6 +3,7 @@ using System;
using System.Collections.Generic; using System.Collections.Generic;
using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations;
using System.Text; using System.Text;
using System.Xml;
namespace Shentun.Peis.RegisterCheckPictures namespace Shentun.Peis.RegisterCheckPictures
{ {
@ -27,6 +28,11 @@ namespace Shentun.Peis.RegisterCheckPictures
public List<UploadRegisterCheckPictureManyPictureBaseStrsDto> PictureBaseStrs { get; set; } = new List<UploadRegisterCheckPictureManyPictureBaseStrsDto>() { }; public List<UploadRegisterCheckPictureManyPictureBaseStrsDto> PictureBaseStrs { get; set; } = new List<UploadRegisterCheckPictureManyPictureBaseStrsDto>() { };
/// <summary>
/// 图片文件类型 0-仪器图片,1-报告文件
/// </summary>
public char PictureFileType { get; set; } = '0';
///// <summary> ///// <summary>
///// 图片base64 ///// 图片base64
///// </summary> ///// </summary>

3
src/Shentun.Peis.Application/RegisterCheckPictures/RegisterCheckPictureAppService.cs

@ -194,7 +194,8 @@ namespace Shentun.Peis.RegisterCheckPictures
DisplayOrder = input.PictureBaseStrs.IndexOf(item) + 1, DisplayOrder = input.PictureBaseStrs.IndexOf(item) + 1,
IsPrint = 'Y', IsPrint = 'Y',
PictureFilename = PictureUrl, PictureFilename = PictureUrl,
RegisterCheckId = input.RegisterCheckId
RegisterCheckId = input.RegisterCheckId,
PictureFileType = input.PictureFileType
}; };
await _registerCheckPictureRepository.InsertAsync(ent); await _registerCheckPictureRepository.InsertAsync(ent);

7
src/Shentun.Peis.Domain/RegisterCheckPictures/RegisterCheckPicture.cs

@ -33,6 +33,13 @@ namespace Shentun.Peis.Models
[Column("is_print")] [Column("is_print")]
[MaxLength(1)] [MaxLength(1)]
public char IsPrint { get; set; } public char IsPrint { get; set; }
/// <summary>
/// 图片文件类型 0-仪器图片,1-报告文件,默认是0
/// </summary>
[Column("picture_file_type")]
[MaxLength(1)]
public char PictureFileType { get; set; }
/// <summary> /// <summary>
/// 显示顺序 /// 显示顺序
/// </summary> /// </summary>

3
src/Shentun.Peis.EntityFrameworkCore/DbMapping/RegisterCheckPictures/RegisterCheckPictureDbMapping.cs

@ -32,6 +32,9 @@ namespace Shentun.Peis.DbMapping
entity.Property(e => e.RegisterCheckId).HasComment("登记流水号").IsRequired(); entity.Property(e => e.RegisterCheckId).HasComment("登记流水号").IsRequired();
entity.Property(e => e.PictureFileType).HasComment("图片文件类型").HasDefaultValueSql("'0'");
entity.HasOne(d => d.RegisterCheck) entity.HasOne(d => d.RegisterCheck)
.WithMany(p => p.RegisterCheckPictures) .WithMany(p => p.RegisterCheckPictures)
.HasForeignKey(d => d.RegisterCheckId) .HasForeignKey(d => d.RegisterCheckId)

14294
src/Shentun.Peis.EntityFrameworkCore/Migrations/20240516100718_init20240515002.Designer.cs
File diff suppressed because it is too large
View File

28
src/Shentun.Peis.EntityFrameworkCore/Migrations/20240516100718_init20240515002.cs

@ -0,0 +1,28 @@
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable
namespace Shentun.Peis.Migrations
{
public partial class init20240515002 : Migration
{
protected override void Up(MigrationBuilder migrationBuilder)
{
migrationBuilder.AddColumn<char>(
name: "picture_file_type",
table: "register_check_picture",
type: "character(1)",
maxLength: 1,
nullable: false,
defaultValueSql: "'0'",
comment: "图片文件类型");
}
protected override void Down(MigrationBuilder migrationBuilder)
{
migrationBuilder.DropColumn(
name: "picture_file_type",
table: "register_check_picture");
}
}
}

8
src/Shentun.Peis.EntityFrameworkCore/Migrations/PeisDbContextModelSnapshot.cs

@ -8118,6 +8118,14 @@ namespace Shentun.Peis.Migrations
.HasColumnType("uuid") .HasColumnType("uuid")
.HasColumnName("last_modifier_id"); .HasColumnName("last_modifier_id");
b.Property<char>("PictureFileType")
.ValueGeneratedOnAdd()
.HasMaxLength(1)
.HasColumnType("character(1)")
.HasColumnName("picture_file_type")
.HasDefaultValueSql("'0'")
.HasComment("图片文件类型");
b.Property<string>("PictureFilename") b.Property<string>("PictureFilename")
.IsRequired() .IsRequired()
.HasMaxLength(200) .HasMaxLength(200)

Loading…
Cancel
Save