Added Add/Edit function to MemberListWindow

This commit is contained in:
2023-02-21 20:37:49 +01:00
parent c90e986b52
commit a060728a48
11 changed files with 334 additions and 283 deletions

20
WGneu/Models/Branch.cs Normal file
View File

@ -0,0 +1,20 @@
using Microsoft.EntityFrameworkCore;
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations.Schema;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace WGneu.Models
{
[Table("branch"), PrimaryKey("ZwstId")]
public class Branch
{
[Column("zwstid")]
public string ZwstId { get; set; }
[Column("name")]
public string Name { get; set; }
}
}

View File

@ -21,7 +21,7 @@ namespace WGneu.Models
public string FamilyName { get; set; }
[Column("zwstid")]
public string Zweigstelle { get; set; }
public string ZwstId { get; set; }
[Column("country")]
public string CountryCode { get; set; }
@ -43,5 +43,8 @@ namespace WGneu.Models
[ForeignKey("DefaultKgNr")]
public virtual AT_Kg DefaultKg { get; set; }
[ForeignKey("ZwstId")]
public virtual Branch Branch { get; set; }
}
}

23
WGneu/Models/WbKg.cs Normal file
View File

@ -0,0 +1,23 @@
using Microsoft.EntityFrameworkCore;
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations.Schema;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace WGneu.Models
{
[Table("wb_kg"), PrimaryKey("KgNr")]
public class WbKg
{
[Column("kgnr")]
public int KgNr { get; set; }
[Column("glnr")]
public int? GlNr { get; set; }
[ForeignKey("KgNr")]
public virtual AT_Kg Kg { get; set; }
}
}