Exemplo n.º 1
0
        public ListEmployeeViewModel(Employe employe)
        {
            IService service = new Service.Service();

            idEmploye              = employe.IdEmploye;
            nomEmploye             = employe.NomEmploye;;
            prenomEmploye          = employe.PrenomEmploye;;
            dateDeNaissanceEmploye = employe.DateDeNaissanceEmploye;
            ancienneteEmploye      = employe.AncienneteEmploye;
            biographieEmploye      = employe.BiographieEmploye;
        }
 static void Main()
 {
     var service = new Service();
     if (Environment.UserInteractive)
     {
         service.InteractiveStart();
         Console.WriteLine("service running.  Press enter to exit");
         Console.ReadLine();
         service.InteractiveStop();
         return;
     }
     ServiceBase.Run(service);
 }
Exemplo n.º 3
0
        static void Main()
        {
            var                     connectionString       = "Data Source = LUNA\\SQLEXPRESS; Initial Catalog = Library; Integrated Security = True";
            IBookRepository         bookRepository         = new BookRepository(new BookContext(connectionString));
            ILibrarianRepository    librarianRepository    = new LibrarianRepository(new LibrarianContext(connectionString));
            ISubscriberRepository   subscriberRepository   = new SubscriberRepository(new SubscriberContext(connectionString));
            IBorrowedBookRepository borrowedBookRepository = new BorrowedBookRepository(new BorrowedBookContext(connectionString));
            IReservedBookRepository reservedBookRepository = new ReservedBookRepository(new ReservedBookContext(connectionString));
            IReturnedBookRepository returnedBookRepository = new ReturnedBookRepository(new ReturnedBookContext(connectionString));
            IService                service = new Service.Service(bookRepository, librarianRepository, subscriberRepository, borrowedBookRepository, reservedBookRepository, returnedBookRepository);


            Application.SetHighDpiMode(HighDpiMode.SystemAware);
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);
            Application.Run(new LogInForm(service));
        }
        public static void Main(string[] args)
        {
            var service = new Service();
#if !__MonoCS__
			if (Environment.UserInteractive)
#else
			if (AppDomain.CurrentDomain.FriendlyName != "service")
#endif
			{
                service.OnStart(args);
                Console.WriteLine("Press any key to stop program");
                Console.Read();
                service.OnStop();
            }
            else
                Run(service);
        }
Exemplo n.º 5
0
    protected void endallorder_Click(object sender, EventArgs e)
    {
        Service.Service aa = new Service.Service();

        if (aa.CheckCredit(cusid.Text, creditnum.Text, creditdate.Text))
        {
            int sumor = int.Parse(O1.ReturnData("SELECT Sum(TblsubOrdersHelp.total) AS Sumמתוךtotal FROM TblsubOrdersHelp;").Tables[0].Rows[0][0].ToString());


            if (aa.CheckBal(cusid.Text, creditnum.Text, creditdate.Text, sumor))
            {
                EndOrder();
                aa.Updtbalance(cusid.Text, creditnum.Text, creditdate.Text, sumor);
            }
            else
            {
                err2.Text = "יתרת הכרטיס נמוכה מסכום ההזמנה ב: " + aa.Howmuchlower(cusid.Text, creditnum.Text, creditdate.Text, sumor) + " ₪";
            }
        }
        else
        {
            err2.Text = "פרטי כרטיס אשרי שגויים";
        }
    }
Exemplo n.º 6
0
 public ProductListPresenter(IProductListView ProductListView,
     Service.ProductService ProductService)
 {
     _productService = ProductService;
     _productListView = ProductListView;
 }
Exemplo n.º 7
0
 public void Init()
 {
     _random = new Random();
     _service = new Service();
     _model = new Model() { Symbol = "MSFT", Name = "Microsoft Corpora", LastTradePrice = 37.575, LastTradeDate = DateTime.Now.AddDays(-1), OpenPrice = 37.65, DayLowPrice = 37.51, DayHighPrice = 37.78 };
 }