예제 #1
0
        private void UstawMiesiacFiltr(int NrMiesiac)
        {
            DateTime dt  = new DateTime(DateTime.Today.Year, NrMiesiac, 1);
            DateTime dt2 = new DateTime(DateTime.Today.Year, NrMiesiac, DateTime.DaysInMonth(DateTime.Today.Year, NrMiesiac));
            List <IHP_WAZENIE_USLUGA> _listaWwazen = context.IHP_WAZENIE_USLUGA.Where(x => x.DATACZAS >= dt && x.DATACZAS <= dt2).ToList();

            Uslugi.Clear();
            foreach (IHP_WAZENIE_USLUGA item in _listaWwazen)
            {
                IHP_WAZENIE_USLUGA_EX itemex = new IHP_WAZENIE_USLUGA_EX(context, item);
                Uslugi.Add(itemex);
            }
        }
예제 #2
0
        private void UstawRok()
        {
            DateTime dt  = new DateTime(DateTime.Today.Year, 1, 1);
            DateTime dt2 = new DateTime(DateTime.Today.Year, 12, 31);
            List <IHP_WAZENIE_USLUGA> _listaWwazen = context.IHP_WAZENIE_USLUGA.Where(x => x.DATACZAS >= dt && x.DATACZAS <= dt2).ToList();

            Uslugi.Clear();
            foreach (IHP_WAZENIE_USLUGA item in _listaWwazen)
            {
                IHP_WAZENIE_USLUGA_EX itemex = new IHP_WAZENIE_USLUGA_EX(context, item);
                Uslugi.Add(itemex);
            }
        }
예제 #3
0
        private void UstawTydzien()
        {
            DayOfWeek fdow     = CultureInfo.CurrentCulture.DateTimeFormat.FirstDayOfWeek;
            int       offset   = fdow - DateTime.Today.DayOfWeek - 1;
            DateTime  fdowDate = DateTime.Today.AddDays(offset);
            DateTime  ldowDate = fdowDate.AddDays(7);
            List <IHP_WAZENIE_USLUGA> _listaWwazen = context.IHP_WAZENIE_USLUGA.Where(x => x.DATACZAS >= fdowDate && x.DATACZAS <= ldowDate).ToList();

            Uslugi.Clear();
            foreach (IHP_WAZENIE_USLUGA item in _listaWwazen)
            {
                IHP_WAZENIE_USLUGA_EX itemex = new IHP_WAZENIE_USLUGA_EX(context, item);
                Uslugi.Add(itemex);
            }
        }
예제 #4
0
        public void LoadCollection()
        {
            List <IHP_WAZENIE_USLUGA> _uslugilst;

            _uslugilst = context.IHP_WAZENIE_USLUGA.ToList();

            Uslugi.Clear();

            //Wazenia.Clear();
            foreach (IHP_WAZENIE_USLUGA item in _uslugilst)
            {
                IHP_WAZENIE_USLUGA_EX it = new IHP_WAZENIE_USLUGA_EX(context, item);
                Uslugi.Add(it);
            }
        }
예제 #5
0
        private void UstawDzien()
        {
            BgColor = "Red";
            DateTime currentDateTime = DateTime.Now;

            DateOd = currentDateTime.Date;
            DateDo = currentDateTime.Date.AddDays(1).AddTicks(-1);
            List <IHP_WAZENIE_USLUGA> _listaWwazen = context.IHP_WAZENIE_USLUGA.Where(x => x.DATACZAS >= DateOd && x.DATACZAS <= DateDo).ToList();

            Uslugi.Clear();
            foreach (IHP_WAZENIE_USLUGA item in _listaWwazen)
            {
                IHP_WAZENIE_USLUGA_EX itemex = new IHP_WAZENIE_USLUGA_EX(context, item);
                Uslugi.Add(itemex);
            }
        }
예제 #6
0
        private void Clear()
        {
            if (_samochod != null)
            {
                Samochod  = null;
                _samochod = null;
            }

            if (_kontrah != null)
            {
                _kontrah = null;
                Kontrah  = null;
            }

            if (_kontraharch != null)
            {
                _kontraharch = null;
                KontrahArch  = null;
            }

            if (_kierowca != null)
            {
                _kierowca = null;
                Kierowca  = null;
            }

            if (_rodzajdok != null)
            {
                _rodzajdok = null;
            }
            if (_wazenie != null)
            {
                Wazenie  = null;
                _wazenie = null;
            }
            KierowcaNazwa   = string.Empty;
            KontrahentNazwa = string.Empty;
            NrRejNazwa      = string.Empty;
            Uwagi           = string.Empty;
            _ispopraw       = false;
            LoadCollection();
        }