设备信息中添加排序号

main
xiaoguo 2 years ago
parent dab58fae2c
commit 96d904c527

Binary file not shown.

@ -2,6 +2,7 @@
#nullable disable
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations.Schema;
namespace PVDEMCS.Services.Models;
@ -37,6 +38,11 @@ public partial class EquipmentInfo
/// </summary>
public bool Activated { get; set; }
/// <summary>
/// 排序号
/// </summary>
public int OrdrNo { get; set; }
/// <summary>
/// 备注
/// </summary>

@ -114,6 +114,7 @@ public partial class EFContext : DbContext
entity.Property(e => e.EquipmentCode).HasComment("设备编码");
entity.Property(e => e.EquipmentName).HasComment("设备名称");
entity.Property(e => e.EquipmentType).HasComment("设备类型IonbondBalzersCemecon");
entity.Property(e => e.OrdrNo).HasComment("排序号");
entity.Property(e => e.IsDelete)
.HasDefaultValueSql("b'0'")
.HasComment("是否删除");

@ -44,6 +44,12 @@ public partial class EquipmentInfoEntity : CUDBaseEntity
[Column("activated", TypeName = "bit(1)")]
public bool Activated { get; set; }
/// <summary>
/// 排序号
/// </summary>
[Column("ordrNo")]
public int OrdrNo { get; set; }
/// <summary>
/// 备注
/// </summary>

@ -89,6 +89,7 @@ namespace PVDEMCS.Services.Repositories
EquipmentName = f.EquipmentName,
EquipmentType = f.EquipmentType,
Activated = f.Activated,
OrdrNo = f.OrdrNo,
Remark = f.Remark
});
@ -176,6 +177,7 @@ namespace PVDEMCS.Services.Repositories
update.EquipmentCode = entity.EquipmentCode;
update.EquipmentName = entity.EquipmentName;
update.Activated = entity.Activated;
update.OrdrNo = entity.OrdrNo;
update.Remark = entity.Remark;
update.Update();
context.SaveChanges();

@ -11,7 +11,7 @@
Target Server Version : 80034
File Encoding : 65001
Date: 03/11/2023 20:12:27
Date: 06/11/2023 10:40:28
*/
SET NAMES utf8mb4;
@ -75,6 +75,7 @@ CREATE TABLE `equipment_info` (
`equipment_name` varchar(32) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NOT NULL COMMENT '设备名称',
`equipment_type` varchar(32) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NOT NULL COMMENT '设备类型IonbondBalzersCemecon',
`activated` bit(1) NOT NULL DEFAULT b'1' COMMENT '设备状态,1启用0停用',
`ordrNo` int NULL DEFAULT 0 COMMENT '排序号',
`remark` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NULL DEFAULT NULL COMMENT '备注',
`create_by` varchar(32) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '创建者',
`create_at` datetime NULL DEFAULT NULL COMMENT '创建时间',

Loading…
Cancel
Save