public static void Add(ORM orm) { Console.Write("\nFirstName: "); string fn = Console.ReadLine(); Console.Write("LastName: "); string ln = Console.ReadLine(); Console.Write("Age: "); int age = Convert.ToInt32(Console.ReadLine()); Console.Write("PhoneNumber: "); string pn = Console.ReadLine(); Console.Write("Email: "); string em = Console.ReadLine(); orm.Add(new People { FirstName = fn, LastName = ln, Age = age, PhoneNumber = pn, Email = em }); }
public static void Add(ORM orm) { Console.Write("\nCountry: "); string country = Console.ReadLine(); Console.Write("City: "); string city = Console.ReadLine(); Console.Write("Oblast: "); string oblast = Console.ReadLine(); Console.Write("Region: "); string region = Console.ReadLine(); Console.Write("Street: "); string street = Console.ReadLine(); Console.WriteLine("House: "); int house = Convert.ToInt32(Console.ReadLine()); Console.WriteLine("Flat: "); int flat = Convert.ToInt32(Console.ReadLine()); orm.Add(new Addresses { Country = country, City = city, Oblast = oblast, Region = region, Street = street, House = house, Flat = flat }); }
public static void Add(ORM orm) { Console.Write("\nName: "); string name = Console.ReadLine(); orm.Add(new Types { Name = name }); }
public static void Add(ORM orm) { Console.Write("\nStatus: "); string status = Console.ReadLine(); orm.Add(new DeliveryStatus { Status = status }); }
public static void Add(ORM orm) { Console.Write("\nBrand: "); string br = Console.ReadLine(); Console.Write("Number: "); string n = Console.ReadLine(); Console.Write("Year: "); DateTime year = Convert.ToDateTime(Console.ReadLine()); orm.Add(new Cars { Brand = br, Number = n, Year = year }); }
//添加用户 public static void Add(Model.User user) { ORM.Add(user, new Model.UserMapping(), Constant.CONNSTRING); }