Ejemplo n.º 1
0
 public void remove_operation(int indeks, MyOrderData order)
 {
     new AlertDialog.Builder(this)
     .SetPositiveButton("Tak", (sender, args) =>
     {
         try
         {
             string token = order.details.client[indeks].UserToken;
             order.details.client.RemoveAt(indeks);
             ClientShortJSON jsonObj = new ClientShortJSON()
             {
                 users = order.details.client.ToArray()
             };
             MySQLHelper.removeUser
             (
                 JsonConvert.SerializeObject(jsonObj),
                 token, order.details.client.Count,
                 order.ReservationID.ToString(),
                 order.CenaBiletu,
                 connection
             );
         }
         catch (Exception e)
         {
         }
     })
     .SetNegativeButton("Nie", (sender, args) =>
     {
     })
     .SetMessage("Czy napewno chcesz usun¹æ osobê ? \n[" + order.details.client[indeks].ToStringWithoutToken() + "]")
     .SetTitle("PotwierdŸ operacje")
     .Show();
 }
Ejemplo n.º 2
0
        protected override void OnCreate(Bundle savedInstanceState)
        {
            base.OnCreate(savedInstanceState);
            SetContentView(Resource.Layout.EditOrder);
            init_title();
            connection = Helper.MySQLHelper.getConnection("Server=mysql8.mydevil.net;Port=3306;Database=m1245_paragon;User=m1245_paragon;Password=KsiVnj8HQz32VxT8eNPd");
            MyOrderData order = GlobalMemory.order[GlobalMemory.actual_edited];

            set_title(order.details.client.Count, order.CenaBiletu, order.KosztRezerwacji);
            listView = FindViewById <ExpandableListView>(Resource.Id.listviewClientOfReservation);
            listView.SetAdapter(new ExpandableDataAdapterForClient(this, order, this));
        }
 public ExpandableDataAdapterForClient(Activity newContext, MyOrderData newList, EditOrder a)
 {
     _obj      = a;
     _DataList = newList;
     _context  = newContext;
 }