public static void NhapNghiepVu(ArrayList arrayList) { //int mahdn,string tenhdn,string tennvgiao,string mahd,string tenxechothue,int soluong,int maxechothue,int tongtien,double giachothue int mahdn = arrayList.Count + 1000; Console.WriteLine("Nhập tên HDN"); string tenhdn = Nhap.NhapString(); Console.WriteLine("Nhập tên nhân viên giao"); string tennvgiao = Nhap.NhapString(); Console.WriteLine("Nhập mã HD"); string mahd = Nhap.NhapString(); Console.WriteLine("Nhập tên xe cho thuê"); string tenxechothue = Nhap.NhapString(); Console.WriteLine("Nhập số lượng"); int soluong = Nhap.NhapInt(); Console.WriteLine("Nhập mã xe cho thuê"); int maxechothue = Nhap.NhapInt(); Console.WriteLine("Nhập giá cho thuê"); double giachothue = Nhap.NhapDouble(); double tongtien = Convert.ToDouble(soluong) * giachothue; arrayList.Add(new NghiepVu(mahdn, tenhdn, tennvgiao, mahd, tenxechothue, soluong, maxechothue, Convert.ToInt32(tongtien), giachothue)); }
public static void Sua(ArrayList arrayList) { TinhLuong ob = Find(arrayList); Console.WriteLine("Nhập tên nhân viên"); ob.Matl= arrayList.Count + 1000; Console.WriteLine("Nhập mã nhân viên"); ob.Manv = Nhap.NhapInt(); Console.WriteLine("Nhập số ngày làm việc "); ob.Songaylv = Nhap.NhapFloat(); Console.WriteLine("Nhập thưởng"); ob.Thuong = Nhap.NhapDouble(); Console.WriteLine("Nhập lương cơ bản"); ob.Luongcoban = Nhap.NhapDouble(); }
public static void NhapTinhLuong(ArrayList arrayList) { //int matl, int manv, float songaylv, double thuong, double luongcoban int matl = arrayList.Count + 1000; Console.WriteLine("Nhập mã nhân viên"); int manv = Nhap.NhapInt(); Console.WriteLine("Nhập số ngày làm việc "); float songaylv = Nhap.NhapFloat(); Console.WriteLine("Nhập thưởng"); double thuong = Nhap.NhapDouble(); Console.WriteLine("Nhập lương cơ bản"); double lcb = Nhap.NhapDouble(); arrayList.Add(new TinhLuong(matl,manv,songaylv,thuong,lcb)); }
public static void Sua(ArrayList arrayList) { GiaBan ob = Find(arrayList); Console.WriteLine("Nhập mã xe"); ob.Maxe = Nhap.NhapInt(); Console.WriteLine("Nhập giá cho thuê"); ob.Giachothue = Nhap.NhapDouble(); Console.WriteLine("Nhập đơn vị tính"); ob.Donvitinh = Nhap.NhapString(); Console.WriteLine("Nhập ngày áp dụng"); ob.Ngayad = Nhap.NhapString(); Console.WriteLine("Nhập ngày thôi áp dụng"); ob.Ngaythoad = Nhap.NhapString(); }
public static void Sua(ArrayList arrayList) { NghiepVu ob = Find(arrayList); Console.WriteLine("Nhập tên HDN"); ob.Tenhdn = Nhap.NhapString(); Console.WriteLine("Nhập tên nhân viên giao"); ob.Tennvgiao = Nhap.NhapString(); Console.WriteLine("Nhập mã HD"); ob.Mahd = Nhap.NhapString(); Console.WriteLine("Nhập tên xe cho thuê"); ob.Tenxechothue = Nhap.NhapString(); Console.WriteLine("Nhập số lượng"); ob.Soluong = Nhap.NhapInt(); Console.WriteLine("Nhập mã xe cho thuê"); ob.Maxechothue = Nhap.NhapInt(); Console.WriteLine("Nhập giá cho thuê"); ob.Giachothue = Nhap.NhapDouble(); ob.Tongtien = Convert.ToInt32(Convert.ToDouble(ob.Soluong) * ob.Giachothue); }
public static void NhapGiaBan(ArrayList arrayList) { //int magiachothue,int maxe,double giachothue,string donvitinh,string ngayad,string ngaythoiad int magiachothue = arrayList.Count + 1000; Console.WriteLine("Nhập mã xe"); int maxe = Nhap.NhapInt(); Console.WriteLine("Nhập giá cho thuê"); double giachothue = Nhap.NhapDouble(); Console.WriteLine("Nhập đơn vị tính"); string donvitinh = Nhap.NhapString(); Console.WriteLine("Nhập ngày áp dụng"); string ngayad = Nhap.NhapString(); Console.WriteLine("Nhập ngày thôi áp dụng"); string ngaythoiad = Nhap.NhapString(); arrayList.Add(new GiaBan(magiachothue, maxe, giachothue, donvitinh, ngayad, ngaythoiad)); }