Browse Source

更新版本

master
学 赵 1 year ago
parent
commit
7cbcd34060
  1. 2
      code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/BBAC_CAN_SA_SERVICE.cs
  2. 2
      code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/HBPO_CAN_SA_SERVICE.cs
  3. 20
      code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/INVOICE_SERVICE.cs
  4. 4
      code/src/Modules/SettleAccount/src/SettleAccount.Domain/Entities/BQ/BBAC_SE_EDI.cs
  5. 26
      code/src/Modules/SettleAccount/src/SettleAccount.Domain/Entities/BQ/Managers/INV_MNG.cs
  6. 5813
      code/src/Modules/SettleAccount/src/SettleAccount.EntityFrameworkCore/Migrations/20230829062103_202308290001.Designer.cs
  7. 186
      code/src/Modules/SettleAccount/src/SettleAccount.EntityFrameworkCore/Migrations/20230829062103_202308290001.cs
  8. 26
      code/src/Modules/SettleAccount/src/SettleAccount.EntityFrameworkCore/Migrations/SettleAccountDbContextModelSnapshot.cs

2
code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/BBAC_CAN_SA_SERVICE.cs

@ -98,7 +98,7 @@ namespace Win.Sfs.SettleAccount.Entities.BQ
var entitys = await _bbacMng.GetDetalListAsync(invbillNum);//可结算
var groupNumList = entitys.Select(p => p.GroupNum).Distinct().ToList();
//var groupNumList = entitys.Select(p => new { p.GroupNum).Distinct().ToList();
var notQuery = _notRepository.Where(p => groupNumList.Contains(p.InvGroupNum)).ToList();//不能结算
var notQuery = _notRepository.Where(p => groupNumList.Contains(p.GroupNum)).ToList();//不能结算
var priceList = _priceRepository.ToList();//价格单
var errorList = await CheckInvoiceGenerationRules(entitys, priceList,main.BusinessType);//校验生成规则
if (errorList.Count() > 0)

2
code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/HBPO_CAN_SA_SERVICE.cs

@ -88,7 +88,7 @@ namespace Win.Sfs.SettleAccount.Entities.BQ
{
var entitys = await _hbpoMng.GetDetalListAsync(invbillnum);
var groupNumList = entitys.Select(p => p.GroupNum).Distinct().ToList();
var notQuery = _notRepository.Where(p => groupNumList.Contains(p.InvGroupNum)).ToList();
var notQuery = _notRepository.Where(p => groupNumList.Contains(p.GroupNum)).ToList();
var priceList = _priceRepository.ToList();//价格单
var errorList = await CheckInvoiceGenerationRules(entitys, priceList, main.BusinessType);//校验生成规则

20
code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/INVOICE_SERVICE.cs

@ -115,6 +115,16 @@ namespace Win.Sfs.SettleAccount.Entities.BQ
await _invMng.SetForwardState(p_invs, SettleBillState.);
return new JsonResult(new { Code = "200", Message = "审核成功" });
}
[HttpPost]
public virtual async Task<IActionResult> UpdateInvoice(string invbill,string remark)
{
var sucess= await _invMng.UpdateInvoiceAsync(invbill,remark);
if (sucess)
{
return new JsonResult(new { Code = 200, Message = "更新成功" });
}
return new JsonResult(new { Code = 400, Message = "更新失败" });
}
/// <summary>
/// 主表查询
@ -138,13 +148,8 @@ namespace Win.Sfs.SettleAccount.Entities.BQ
[HttpPost]
public virtual async Task<INVOICE_GRP_DETAIL_DTO> DetailQueryAsync(INVOICE_GRP_REQ_DTO input)
{
INVOICE_GRP_DETAIL_DTO entity = new INVOICE_GRP_DETAIL_DTO();
var invs = await _repository.GetListByFilterAsync(input.Filters, input.Sorting, int.MaxValue, input.SkipCount);
var m = await _mRepository.GetListByFilterAsync(input.Filters, input.Sorting, int.MaxValue, input.SkipCount);
var mdtos = ObjectMapper.Map<List<INVOICE_MAP_GROUP>, List<INVOICE_MAP_GROUP_DTO>>(m);
var w = await _wRepository.GetListByFilterAsync(input.Filters, input.Sorting, int.MaxValue, input.SkipCount);
@ -278,9 +283,6 @@ namespace Win.Sfs.SettleAccount.Entities.BQ
var classDisplayName = typeof(INVOICE_GRP_DTO).GetCustomAttribute<DisplayAttribute>()?.Name ?? typeof(INVOICE_GRP_DTO).Name;
string _fileName = $"{classDisplayName}_{Guid.NewGuid().ToString()}.xlsx";
foreach (var itm in entities)
{
var invlist = detail.Where(p => p.InvbillNum == itm.InvbillNum).ToList();
@ -290,7 +292,7 @@ namespace Win.Sfs.SettleAccount.Entities.BQ
_excel.Append(invlist, "发票号" + itm.InvbillNum).SeparateBySheet();
_excel.Append(mgroup, "发票结算分组对应" + itm.InvbillNum).SeparateBySheet();
_excel.Append(adjp, "发票调整数据" + itm.InvbillNum).SeparateBySheet();
_excel.Append(nolist, "结算分组零件");
_excel.Append(nolist, "结算分组零件" + itm.InvbillNum);
}

4
code/src/Modules/SettleAccount/src/SettleAccount.Domain/Entities/BQ/BBAC_SE_EDI.cs

@ -10,7 +10,7 @@ public class BBAC_SE_EDI:FullAuditedAggregateRoot<Guid>
public string KeyCode { get; set; } = null!;
[Display(Name = "期间")]
public string Version { get; set; }
public int Version { get; set; }
[Display(Name = "零件号")]
public string LU { get; set; } = null!;
@ -60,7 +60,7 @@ public class BBAC_SE_EDI:FullAuditedAggregateRoot<Guid>
public BBAC_SE_EDI()
{ }
public BBAC_SE_EDI(Guid guid, string keyCode, string version, string lU, string pN, string seqNumber, string assemblyCode, string injectionCode, decimal qty, DateTime beginDate
public BBAC_SE_EDI(Guid guid, string keyCode, int version, string lU, string pN, string seqNumber, string assemblyCode, string injectionCode, decimal qty, DateTime beginDate
,string site, string extend1, string extend2, string extend3, string extend4)
{

26
code/src/Modules/SettleAccount/src/SettleAccount.Domain/Entities/BQ/Managers/INV_MNG.cs

@ -93,6 +93,32 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Managers
// return false;
//}
public async Task<bool> UpdateInvoiceAsync(string p_invbillnum, string remark)
{
try
{
var ls = _repository.Where(p => p.InvbillNum == p_invbillnum).ToList();
foreach (var itm in ls)
{
itm.FileName = remark;
}
await _repository.UpdateManyAsync(ls);
return true;
}
catch
{
return false;
}
return false;
}
private async Task<bool> SetSettleState(INVOICE_GRP p_entiy, SettleBillState p_State, bool IsForward = true)
{

5813
code/src/Modules/SettleAccount/src/SettleAccount.EntityFrameworkCore/Migrations/20230829062103_202308290001.Designer.cs

File diff suppressed because it is too large

186
code/src/Modules/SettleAccount/src/SettleAccount.EntityFrameworkCore/Migrations/20230829062103_202308290001.cs

@ -0,0 +1,186 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
namespace Win.Sfs.SettleAccount.Migrations
{
public partial class _202308290001 : Migration
{
protected override void Up(MigrationBuilder migrationBuilder)
{
migrationBuilder.AlterColumn<int>(
name: "Version",
table: "Set_BBAC_SE_EDI",
type: "int",
nullable: false,
defaultValue: 0,
oldClrType: typeof(string),
oldType: "nvarchar(max)",
oldNullable: true);
migrationBuilder.UpdateData(
table: "Set_JobItem",
keyColumn: "Id",
keyValue: new Guid("185c5968-e02b-267e-db2f-225fccfc9716"),
column: "ConcurrencyStamp",
value: "c3e3165a405d46aab69c31f2f82d756f");
migrationBuilder.UpdateData(
table: "Set_JobItem",
keyColumn: "Id",
keyValue: new Guid("1bb02f67-ed05-6cc1-1507-502e8f6c7a31"),
column: "ConcurrencyStamp",
value: "ba68c04aac4f4416b989d7b55bdc4b7e");
migrationBuilder.UpdateData(
table: "Set_JobItem",
keyColumn: "Id",
keyValue: new Guid("49b1da12-418c-544d-fe8b-be7e5b572452"),
column: "ConcurrencyStamp",
value: "683c8c8939e14a1395088c6e0bd05bf4");
migrationBuilder.UpdateData(
table: "Set_JobItem",
keyColumn: "Id",
keyValue: new Guid("6f68fc8f-b058-c3f4-e07d-722c61f3f7fa"),
column: "ConcurrencyStamp",
value: "609e5d6d97514b848dd51be85dfb9f1f");
migrationBuilder.UpdateData(
table: "Set_JobItem",
keyColumn: "Id",
keyValue: new Guid("7a0dc087-a859-5863-eb6e-56f588bd779e"),
column: "ConcurrencyStamp",
value: "eb380e1324a74068abc87a93d0f7f014");
migrationBuilder.UpdateData(
table: "Set_JobItem",
keyColumn: "Id",
keyValue: new Guid("8f7dc23d-e2e9-3691-cfe9-545bb958e3f2"),
column: "ConcurrencyStamp",
value: "068e141b55ea41f3afa25065d6578ccd");
migrationBuilder.UpdateData(
table: "Set_JobItem",
keyColumn: "Id",
keyValue: new Guid("b9b9c79f-4894-474b-4f67-b1ec121c41e5"),
column: "ConcurrencyStamp",
value: "2da3b07d5f914c86bc0a43f924ed1749");
migrationBuilder.UpdateData(
table: "Set_JobItem",
keyColumn: "Id",
keyValue: new Guid("c09c23ea-815f-1b43-4476-2365a8d9a60b"),
column: "ConcurrencyStamp",
value: "0a1e55d5a565455898b8be3e9ae310c2");
migrationBuilder.UpdateData(
table: "Set_JobItem",
keyColumn: "Id",
keyValue: new Guid("c1f71240-1b81-0107-8b23-ddc9811a3efe"),
column: "ConcurrencyStamp",
value: "7c5e7b3a484149e7aafa2b5fa797cf2e");
migrationBuilder.UpdateData(
table: "Set_JobItem",
keyColumn: "Id",
keyValue: new Guid("ef3d8e8a-a88e-ca1f-e615-714c6bc48824"),
column: "ConcurrencyStamp",
value: "0bd67219a5564fb586a9f3be1e6126c9");
migrationBuilder.UpdateData(
table: "Set_JobItem",
keyColumn: "Id",
keyValue: new Guid("f306b380-47e5-5c01-b902-67ca4113a8f4"),
column: "ConcurrencyStamp",
value: "7c954b11c9584a2198947011c6bf2cd4");
}
protected override void Down(MigrationBuilder migrationBuilder)
{
migrationBuilder.AlterColumn<string>(
name: "Version",
table: "Set_BBAC_SE_EDI",
type: "nvarchar(max)",
nullable: true,
oldClrType: typeof(int),
oldType: "int");
migrationBuilder.UpdateData(
table: "Set_JobItem",
keyColumn: "Id",
keyValue: new Guid("185c5968-e02b-267e-db2f-225fccfc9716"),
column: "ConcurrencyStamp",
value: "7171dfa8ed7a468697f49f779675204b");
migrationBuilder.UpdateData(
table: "Set_JobItem",
keyColumn: "Id",
keyValue: new Guid("1bb02f67-ed05-6cc1-1507-502e8f6c7a31"),
column: "ConcurrencyStamp",
value: "550dcdec5fb44b65a235deaef4be5be5");
migrationBuilder.UpdateData(
table: "Set_JobItem",
keyColumn: "Id",
keyValue: new Guid("49b1da12-418c-544d-fe8b-be7e5b572452"),
column: "ConcurrencyStamp",
value: "c2ec841c8d8848afa92f5a8b503c28c0");
migrationBuilder.UpdateData(
table: "Set_JobItem",
keyColumn: "Id",
keyValue: new Guid("6f68fc8f-b058-c3f4-e07d-722c61f3f7fa"),
column: "ConcurrencyStamp",
value: "8c21427a3b514dca9dc26f393a3109cf");
migrationBuilder.UpdateData(
table: "Set_JobItem",
keyColumn: "Id",
keyValue: new Guid("7a0dc087-a859-5863-eb6e-56f588bd779e"),
column: "ConcurrencyStamp",
value: "1211352da8754a31a50d0a30ec3c8481");
migrationBuilder.UpdateData(
table: "Set_JobItem",
keyColumn: "Id",
keyValue: new Guid("8f7dc23d-e2e9-3691-cfe9-545bb958e3f2"),
column: "ConcurrencyStamp",
value: "37d450957fb54e37be9a792d3a98f558");
migrationBuilder.UpdateData(
table: "Set_JobItem",
keyColumn: "Id",
keyValue: new Guid("b9b9c79f-4894-474b-4f67-b1ec121c41e5"),
column: "ConcurrencyStamp",
value: "e4e1563e8ab544c59f8055555cc05a8c");
migrationBuilder.UpdateData(
table: "Set_JobItem",
keyColumn: "Id",
keyValue: new Guid("c09c23ea-815f-1b43-4476-2365a8d9a60b"),
column: "ConcurrencyStamp",
value: "39199c157f4d4e319ed0cbfd863fc937");
migrationBuilder.UpdateData(
table: "Set_JobItem",
keyColumn: "Id",
keyValue: new Guid("c1f71240-1b81-0107-8b23-ddc9811a3efe"),
column: "ConcurrencyStamp",
value: "610e0efedca34af8bf1ddd9f869ff9fd");
migrationBuilder.UpdateData(
table: "Set_JobItem",
keyColumn: "Id",
keyValue: new Guid("ef3d8e8a-a88e-ca1f-e615-714c6bc48824"),
column: "ConcurrencyStamp",
value: "9c5c15ca0ef84bd69f3e35687321e68e");
migrationBuilder.UpdateData(
table: "Set_JobItem",
keyColumn: "Id",
keyValue: new Guid("f306b380-47e5-5c01-b902-67ca4113a8f4"),
column: "ConcurrencyStamp",
value: "cc5d77c9310846688906b64a5800d17c");
}
}
}

26
code/src/Modules/SettleAccount/src/SettleAccount.EntityFrameworkCore/Migrations/SettleAccountDbContextModelSnapshot.cs

@ -950,8 +950,8 @@ namespace Win.Sfs.SettleAccount.Migrations
b.Property<string>("Site")
.HasColumnType("nvarchar(max)");
b.Property<string>("Version")
.HasColumnType("nvarchar(max)");
b.Property<int>("Version")
.HasColumnType("int");
b.HasKey("Id");
@ -4449,7 +4449,7 @@ namespace Win.Sfs.SettleAccount.Migrations
new
{
Id = new Guid("ef3d8e8a-a88e-ca1f-e615-714c6bc48824"),
ConcurrencyStamp = "9c5c15ca0ef84bd69f3e35687321e68e",
ConcurrencyStamp = "0bd67219a5564fb586a9f3be1e6126c9",
Cron = "0 0 8 26 *",
IsDisabled = false,
IsRunning = false,
@ -4459,7 +4459,7 @@ namespace Win.Sfs.SettleAccount.Migrations
new
{
Id = new Guid("185c5968-e02b-267e-db2f-225fccfc9716"),
ConcurrencyStamp = "7171dfa8ed7a468697f49f779675204b",
ConcurrencyStamp = "c3e3165a405d46aab69c31f2f82d756f",
Cron = "0 0/1 * * * ?",
IsDisabled = false,
IsRunning = false,
@ -4469,7 +4469,7 @@ namespace Win.Sfs.SettleAccount.Migrations
new
{
Id = new Guid("1bb02f67-ed05-6cc1-1507-502e8f6c7a31"),
ConcurrencyStamp = "550dcdec5fb44b65a235deaef4be5be5",
ConcurrencyStamp = "ba68c04aac4f4416b989d7b55bdc4b7e",
Cron = "0 0/1 * * * ?",
IsDisabled = false,
IsRunning = false,
@ -4479,7 +4479,7 @@ namespace Win.Sfs.SettleAccount.Migrations
new
{
Id = new Guid("b9b9c79f-4894-474b-4f67-b1ec121c41e5"),
ConcurrencyStamp = "e4e1563e8ab544c59f8055555cc05a8c",
ConcurrencyStamp = "2da3b07d5f914c86bc0a43f924ed1749",
Cron = "0 0/30 * * * ? ",
IsDisabled = false,
IsRunning = false,
@ -4489,7 +4489,7 @@ namespace Win.Sfs.SettleAccount.Migrations
new
{
Id = new Guid("49b1da12-418c-544d-fe8b-be7e5b572452"),
ConcurrencyStamp = "c2ec841c8d8848afa92f5a8b503c28c0",
ConcurrencyStamp = "683c8c8939e14a1395088c6e0bd05bf4",
Cron = "0 0/30 * * * ? ",
IsDisabled = false,
IsRunning = false,
@ -4499,7 +4499,7 @@ namespace Win.Sfs.SettleAccount.Migrations
new
{
Id = new Guid("7a0dc087-a859-5863-eb6e-56f588bd779e"),
ConcurrencyStamp = "1211352da8754a31a50d0a30ec3c8481",
ConcurrencyStamp = "eb380e1324a74068abc87a93d0f7f014",
Cron = "0 0/30 * * * ? ",
IsDisabled = false,
IsRunning = false,
@ -4509,7 +4509,7 @@ namespace Win.Sfs.SettleAccount.Migrations
new
{
Id = new Guid("6f68fc8f-b058-c3f4-e07d-722c61f3f7fa"),
ConcurrencyStamp = "8c21427a3b514dca9dc26f393a3109cf",
ConcurrencyStamp = "609e5d6d97514b848dd51be85dfb9f1f",
Cron = "0 0/30 * * * ? ",
IsDisabled = false,
IsRunning = false,
@ -4519,7 +4519,7 @@ namespace Win.Sfs.SettleAccount.Migrations
new
{
Id = new Guid("f306b380-47e5-5c01-b902-67ca4113a8f4"),
ConcurrencyStamp = "cc5d77c9310846688906b64a5800d17c",
ConcurrencyStamp = "7c954b11c9584a2198947011c6bf2cd4",
Cron = "0 0/30 * * * ? ",
IsDisabled = false,
IsRunning = false,
@ -4529,7 +4529,7 @@ namespace Win.Sfs.SettleAccount.Migrations
new
{
Id = new Guid("8f7dc23d-e2e9-3691-cfe9-545bb958e3f2"),
ConcurrencyStamp = "37d450957fb54e37be9a792d3a98f558",
ConcurrencyStamp = "068e141b55ea41f3afa25065d6578ccd",
Cron = "0 0/30 * * * ? ",
IsDisabled = false,
IsRunning = false,
@ -4539,7 +4539,7 @@ namespace Win.Sfs.SettleAccount.Migrations
new
{
Id = new Guid("c1f71240-1b81-0107-8b23-ddc9811a3efe"),
ConcurrencyStamp = "610e0efedca34af8bf1ddd9f869ff9fd",
ConcurrencyStamp = "7c5e7b3a484149e7aafa2b5fa797cf2e",
Cron = "0 0/30 * * * ? ",
IsDisabled = false,
IsRunning = false,
@ -4549,7 +4549,7 @@ namespace Win.Sfs.SettleAccount.Migrations
new
{
Id = new Guid("c09c23ea-815f-1b43-4476-2365a8d9a60b"),
ConcurrencyStamp = "39199c157f4d4e319ed0cbfd863fc937",
ConcurrencyStamp = "0a1e55d5a565455898b8be3e9ae310c2",
Cron = "0 0/30 * * * ? ",
IsDisabled = false,
IsRunning = false,

Loading…
Cancel
Save