public AccountVM(User user) { SQL sql = new SQL(); sql.Connect(); this.Scripts = sql.ReturnAllSCriptsByUser(user); foreach(Script item in this.Scripts) { item.InstOfDb.Name = sql.ReturnNameOfInstance(item.InstOfDb.ID); } sql.Close(); }
public AccountVM(User user) { SQL sql = new SQL(); sql.Connect(); this.Scripts = sql.ReturnAllSCriptsByUser(user); foreach(Script item in this.Scripts) { item.InstOfDb.Name = sql.ReturnNameOfInstance(item.InstOfDb.ID); } sql.Close(); }