protected override async Task OnAdding(TenantDto input, Tenant entity) { await base.OnAdding(input, entity); entity.Super_Id = Tenant_Id; entity.Tenant_Id = IdGenerate.NetId(); }
private void loadID() { ChiTietSuDung lastDV = db.ChiTietSuDungs.OrderByDescending(x => x.MaCTSD).FirstOrDefault(); string lastID = lastDV != null ? lastDV.MaCTSD : ""; string nextID = IdGenerate.genId(lastID, "CTSD"); txtMaCTSD.Text = nextID; }
private void loadID() { DichVu lastDV = db.DichVus.OrderByDescending(x => x.MaDV).FirstOrDefault(); string lastID = lastDV != null ? lastDV.MaDV : ""; string nextID = IdGenerate.genId(lastID, "DV"); txtMaSP.Text = nextID; }
private void loadID() { HoaDon lastDV = db.HoaDons.OrderByDescending(x => x.MaHD).FirstOrDefault(); string lastID = lastDV != null ? lastDV.MaHD : ""; string nextID = IdGenerate.genId(lastID, "HD"); txtMaHD.Text = nextID; }
private void loadID() { ThietBi lastDV = db.ThietBis.OrderByDescending(x => x.ID_PC).FirstOrDefault(); string lastID = lastDV != null ? lastDV.ID_PC : ""; string nextID = IdGenerate.genId(lastID, "PC"); txtMaPC.Text = nextID; }