Exemplo n.º 1
0
 private bool KembaliValidate(object obj)
 {
     if (DestinationSource.Where(O => O.Selected).Count() > 0)
     {
         return(true);
     }
     return(false);
 }
Exemplo n.º 2
0
        public async void RefreshAll()
        {
            await Task.Delay(200);

            DestinationView.Refresh();
            OriginView.Refresh();
            TotalDestination = DestinationSource.Sum(O => O.Pcs * O.Weight);
            TOtalOrigin      = OriginSource.Sum(O => O.Pcs * O.Weight);
        }
Exemplo n.º 3
0
        private void KembaliAction(object obj)
        {
            foreach (var item in DestinationSource.Where(O => O.Selected).ToList())
            {
                var newItem = item.GetClone();
                newItem.Selected = false;
                OriginSource.Add(newItem);
                DestinationSource.Remove(item);
            }

            RefreshAll();
        }
 public Destination(
     Address target,
     byte[] fnSignature,
     UInt256 value,
     DestinationSource source = DestinationSource.Contract,
     long blockNumber         = 0)
 {
     Target      = target;
     FnSignature = fnSignature;
     Value       = value;
     Source      = source;
     BlockNumber = blockNumber;
 }
        private void SetDestinationSource()
        {
            DestinationSource.Clear();
            foreach (var item in PortCollection.Source)
            {
                if (Agent != null && Agent.CitiesCanAccess != null)
                {
                    var CityCanAccess = Agent.CitiesCanAccess.Where(O => O.CityId == item.CityID).FirstOrDefault();
                    if (CityCanAccess != null)
                    {
                        DestinationSource.Add(item);
                    }
                }
            }

            DestinationView.Refresh();
        }
Exemplo n.º 6
0
        private void PindahkanAction(object obj)
        {
            try
            {
                foreach (var item in OriginSource.Where(O => O.Selected).ToList())
                {
                    var newItem = item.GetClone();
                    newItem.Selected = false;
                    DestinationSource.Add(newItem);
                    OriginSource.Remove(item);
                }

                RefreshAll();
            }
            catch (Exception ex)
            {
                Helpers.ShowErrorMessage(ex.Message);
            }
        }