Merge branch 'development' of https://git.dlhis.com/liguoyang/jinko.yikatong into development
This commit is contained in:
@@ -18,21 +18,21 @@ public class SqlSugarPack : BaseAppPack
|
||||
public override void Configure(IApplicationBuilder app, IWebHostEnvironment env)
|
||||
{
|
||||
#if DEBUG
|
||||
using var scope = app.ApplicationServices.CreateScope();
|
||||
var db = scope.ServiceProvider.GetService<ISqlSugarClient>();
|
||||
var tables = App.ActiveTyps.Where(x => x.IsDefined(typeof(SugarTable), false))
|
||||
.Where(x => !x.IsDefined(typeof(SkipScanAttribute), false))
|
||||
.ToArray();
|
||||
//using var scope = app.ApplicationServices.CreateScope();
|
||||
//var db = scope.ServiceProvider.GetService<ISqlSugarClient>();
|
||||
//var tables = App.ActiveTyps.Where(x => x.IsDefined(typeof(SugarTable), false))
|
||||
// .Where(x => !x.IsDefined(typeof(SkipScanAttribute), false))
|
||||
// .ToArray();
|
||||
|
||||
db.DbMaintenance.CreateDatabase();
|
||||
db.CodeFirst.InitTables(tables);
|
||||
//db.DbMaintenance.CreateDatabase();
|
||||
//db.CodeFirst.InitTables(tables);
|
||||
|
||||
using var scopeFace = app.ApplicationServices.CreateScope();
|
||||
var dbFace = scopeFace.ServiceProvider.GetService<ISqlSugarClient>();
|
||||
var faceConnectionString = Configuration.GetSection("SqlSugarOptions:FaceConnectionString").Value;
|
||||
dbFace.CurrentConnectionConfig.ConnectionString = faceConnectionString;
|
||||
dbFace.DbMaintenance.CreateDatabase();
|
||||
dbFace.CodeFirst.InitTables<GainfoFaceEntity>();
|
||||
//using var scopeFace = app.ApplicationServices.CreateScope();
|
||||
//var dbFace = scopeFace.ServiceProvider.GetService<ISqlSugarClient>();
|
||||
//var faceConnectionString = Configuration.GetSection("SqlSugarOptions:FaceConnectionString").Value;
|
||||
//dbFace.CurrentConnectionConfig.ConnectionString = faceConnectionString;
|
||||
//dbFace.DbMaintenance.CreateDatabase();
|
||||
//dbFace.CodeFirst.InitTables<GainfoFaceEntity>();
|
||||
|
||||
#endif
|
||||
}
|
||||
|
||||
@@ -60,12 +60,6 @@ public class CanteenUserEntity : SugarBaseEntity, IVersion, ITenantId
|
||||
[SugarColumn(ColumnDescription = "余额(餐补)")]
|
||||
public decimal BalanceOfSubsidies { get; set; }
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 成本中心
|
||||
/// </summary>
|
||||
public string CostId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 版本号
|
||||
/// </summary>
|
||||
|
||||
@@ -143,6 +143,11 @@ public class GainfoEntity : SugarBaseEntity
|
||||
[SugarColumn(ColumnDescription = "人事范围")]
|
||||
public string Werks { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 成本中心
|
||||
/// </summary>
|
||||
public string CostId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 在职状态
|
||||
/// </summary>
|
||||
|
||||
@@ -76,7 +76,7 @@ public class BalanceRecordEntity : SugarBaseEntity, ITenantId
|
||||
/// <summary>
|
||||
/// 所属成本日期
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnDescription = "所属成本日期")]
|
||||
[SugarColumn(ColumnDataType = "date", ColumnDescription = "所属成本日期")]
|
||||
public DateTime CostDate { get; set; }
|
||||
|
||||
/// <summary>
|
||||
@@ -121,5 +121,11 @@ public class BalanceRecordEntity : SugarBaseEntity, ITenantId
|
||||
[SugarColumn(ColumnDataType = "varchar(50)", SqlParameterDbType = typeof(EnumToStringConvert), ColumnDescription = "数据状态")]
|
||||
public BalanceRecordStatusEnumType Status { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 消费时间
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnDescription = "消费时间")]
|
||||
public DateTime CostDateTime { get; set; }
|
||||
|
||||
public string TenantId { get; set; }
|
||||
}
|
||||
Reference in New Issue
Block a user