Exemplo n.º 1
0
        async Task Find_DayCountAsync()
        {
            try
            {
                inc++;
                IFirebaseClient client = new FireSharp.FirebaseClient(config);
                SL = SL + inc.ToString("00");
                FirebaseResponse response = await client.GetAsync("Sales/SalesOrder/" + SL);

                SO rep = response.ResultAs <SO>();
                if (rep?.SalesOrderID == null)
                {
                    stat   = 1;
                    saleID = SL;
                    return;
                }
                else
                {
                    // Replaces No. with the OLD Format
                    SL = SL.Replace(inc.ToString("00"), "");
                    Find_DayCountAsync();
                }
            }
            catch (Exception)
            {
            }
        }
Exemplo n.º 2
0
        //public async void gethuyenAsync()
        //{
        //    //activityIndicator1.IsRunning = true;
        //    //lblLoadingText.IsVisible = true;

        //    IFirebaseClient clientKT = new FireSharp.FirebaseClient(config);
        //    FirebaseResponse tk1 = await clientKT.GetAsync("TinhThanh/" + 1);
        //    Tinh _tinh1 = tk1.ResultAs<Tinh>();
        //    Source = new List<Quan>()
        //        {
        //            new Quan(_tinh1.MaTinh, _tinh1.TenTinh)
        //        };
        //}
        public async void getgiadinh()
        {
            ObservableCollection <khacthuegiadinh> manggiadinh = new ObservableCollection <khacthuegiadinh>();
            IFirebaseClient  client = new FireSharp.FirebaseClient(config);
            int              i      = 0;
            bool             dem    = true;
            FirebaseResponse tk     = await client.GetAsync("khachthue/" + 33956565 + "/KHACHTHUEGIADINH/" + 1 + "/");

            //if (tk.Body == "null")
            //{
            //    dem = false;
            //}
            khacthuegiadinh GD = tk.ResultAs <khacthuegiadinh>();

            Khachthuegiadinh = new ObservableCollection <khacthuegiadinh>()
            {
                new khacthuegiadinh(
                    GD.HOTEN,
                    GD.NGAYSINH,
                    GD.GIOITINH,
                    GD.QUANHE,
                    GD.NGHENGHIEP,
                    GD.DIACHICHOOHIENNAY)
            };
        }
Exemplo n.º 3
0
        public async void gethuyenAsync()
        {
            //activityIndicator1.IsRunning = true;
            //lblLoadingText.IsVisible = true;

            IFirebaseClient  clientKT = new FireSharp.FirebaseClient(config);
            FirebaseResponse tk1      = await clientKT.GetAsync("TinhThanh/" + 1);

            Tinh _tinh1 = tk1.ResultAs <Tinh>();

            Source = new List <Quan>()
            {
                new Quan(_tinh1.MaTinh, _tinh1.TenTinh)
            };
        }