Пример #1
0
 public override void UpdateUi(ScreenActivationContext sac)
 {
     Items.Clear();
        Items.AddRange(sac.Jq.All("suggestions",
        cqq => new SuggestionViewModel()
        {
            Name = cqq.GetText("suggest"),
            Link = cqq.GetLink("suggest")
        }));
 }
Пример #2
0
 public override void UpdateUi(ScreenActivationContext sac)
 {
     Search = sac.Jq.GetForm("dzebna");
     Items.Clear();
     Items.AddRange(sac.Jq.All("produktebi",
         cqq => new ProductItemViewModel()
             {
                 Name = cqq.GetText("dasakheleba"),
                 Eans = cqq.GetText("eans"),
                 Photo = cqq.GetText("img"),
                 Open = cqq.GetLink("self")
             }));
 }
Пример #3
0
        protected override bool DoCanHandle(ScreenActivationContext sac)
        {
            return sac.Jq.IsTitle("gadakhdisForma") || sac.Jq.IsTitle("cheki");

        }
Пример #4
0
 public override void UpdateUi(ScreenActivationContext sac)
 {
     var jq = sac.Jq;
     jq.IsTitle("cheki", Print);
     jq.IsTitle("gakidva", UpdateSaleViewModel);
     jq.IsTitle("gadakhdisForma", ShowPaymentForm);
 }
Пример #5
0
 protected virtual bool DoCanHandle(ScreenActivationContext sac)
 {
     return false;
 }
Пример #6
0
 public virtual void UpdateUi(ScreenActivationContext sac)
 {
 }
Пример #7
0
 public bool CanHandle(ScreenActivationContext sac)
 {
     var attribute = this.GetType().GetAttributes<TitleAttribute>(false).First();
     var result = sac.Jq.IsTitle(attribute.Name);
     return result || DoCanHandle(sac);
 }
Пример #8
0
        public override void UpdateUi(ScreenActivationContext sac)
        {
            var cqq = sac.Jq;
            Id = cqq.GetText("ref");
            Barcode = cqq.GetText("ref");
            Name = cqq.GetText("dasakheleba");
            ExcelFileName = "";
            Price = cqq.GetForm("fasisShecvla");
            Eans = "";
            Photos.Clear();
            Photos.Add(cqq.GetText("img"));

            NotifyOfPropertyChange(() => ActivePhoto);
            References.Clear();
            References.AddRange(cqq.All("eans",
                cqq1 => cqq1.All("refs", q => new ReferenceViewModel()
                {
                    Barcode = q.GetText("ref"),
                    Open = q.GetLink("self"),
                })).SelectMany(x => x));
        }