Compare commits
10 Commits
23ac9dbd97
...
c67424492a
| Author | SHA1 | Date |
|---|---|---|
|
|
c67424492a | |
|
|
f49825066a | |
|
|
8eac8de403 | |
|
|
e913a8a0d6 | |
|
|
9218e69daa | |
|
|
fe390527ce | |
|
|
4cf479f43c | |
|
|
521e6248f1 | |
|
|
b0f99b8058 | |
|
|
32d79ea23b |
|
|
@ -413,11 +413,19 @@ dotPenOriginalImg:
|
||||||
await DbBiz.BeginTranAsync();
|
await DbBiz.BeginTranAsync();
|
||||||
|
|
||||||
// 删除
|
// 删除
|
||||||
await DbBiz.Deleteable<MkExamResult>().Where(w => w.ExamSubjectId == eto.ExamSubjectId && w.StudentNo == penSerial).ExecuteCommandAsync();
|
var delObjectiveIds = await DbBiz.Queryable<MkExamResult>()
|
||||||
|
.Where(w => w.ExamSubjectId == eto.ExamSubjectId && w.StudentNo == penSerial)
|
||||||
|
.Select(s => s.Id).ToListAsync();
|
||||||
|
await DbBiz.Deleteable<MkExamResult>().Where(w => delObjectiveIds.Contains(w.Id)).ExecuteCommandAsync();
|
||||||
|
|
||||||
|
var delSubjectiveIds = await DbBiz.Queryable<SubjectiveMarkingResult>()
|
||||||
|
.Where(w => w.ExamSubjectId == eto.ExamSubjectId && w.StudentExamNum == penSerial && w.IsDeleted == false)
|
||||||
|
.Select(s => s.Id).ToListAsync();
|
||||||
await DbBiz.Updateable<SubjectiveMarkingResult>()
|
await DbBiz.Updateable<SubjectiveMarkingResult>()
|
||||||
.SetColumns(s => new SubjectiveMarkingResult { IsDeleted = true, UpdateDate = Clock.Now })
|
.SetColumns(s => new SubjectiveMarkingResult { IsDeleted = true, UpdateDate = Clock.Now })
|
||||||
.Where(w => w.ExamSubjectId == eto.ExamSubjectId && w.StudentExamNum == penSerial && w.IsDeleted == false)
|
.Where(w => delSubjectiveIds.Contains(w.Id))
|
||||||
.ExecuteCommandAsync();
|
.ExecuteCommandAsync();
|
||||||
|
|
||||||
// 新增
|
// 新增
|
||||||
await DbBiz.Insertable(kgtDtls).ExecuteCommandAsync();
|
await DbBiz.Insertable(kgtDtls).ExecuteCommandAsync();
|
||||||
await DbBiz.Insertable(zgtDtls).ExecuteCommandAsync();
|
await DbBiz.Insertable(zgtDtls).ExecuteCommandAsync();
|
||||||
|
|
|
||||||
|
|
@ -63,7 +63,7 @@ public class DolphinExamPictureCutHttpApiHostModule : AbpModule
|
||||||
},
|
},
|
||||||
db =>
|
db =>
|
||||||
{
|
{
|
||||||
db.QueryFilter.AddTableFilter<ISoftDelete>(s => s.IsDeleted == false);
|
//db.QueryFilter.AddTableFilter<ISoftDelete>(s => s.IsDeleted == false);
|
||||||
|
|
||||||
var config = new SqlSugarConfig();
|
var config = new SqlSugarConfig();
|
||||||
db.Aop.DataExecuting = config.DataExecuting(context.Services);
|
db.Aop.DataExecuting = config.DataExecuting(context.Services);
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue