コード例 #1
0
        public ProductionOrderDetail(int OrderId)
        {
            InitializeComponent();
            RestService RestService = new Fidabel.RestService();

            dataGridorderdetail.ItemsSource = RestService.GetOrderDetailList("http://" + CurrentSession.url + "/api/production_order_detail/" + OrderId);
        }
コード例 #2
0
        public ProductionOrder(int Lineid)
        {
            InitializeComponent();
            RestService RestService = new Fidabel.RestService();

            dataGridorder.ItemsSource = RestService.GetOrder("http://" + CurrentSession.url + "/api/production_order/" + Lineid);
        }
コード例 #3
0
        public MainPage()
        {
            InitializeComponent();
            RestService RestService = new Fidabel.RestService();

            dataGridline.ItemsSource = RestService.GetLine("http://" + CurrentSession.url + "/api/production_line");
        }
コード例 #4
0
        private void Button_Clicked_1(object sender, EventArgs e)
        {
            RestService RestService = new Fidabel.RestService();
            string      Msg         = RestService.GetLogin("http://" + CurrentSession.url + "/api/login/" + txtuser.Text + "/" + txtpassword.Text);

            if (Msg.ToLower() == "[true]")
            {
                Navigation.PushModalAsync(new MainPage());
            }
        }
コード例 #5
0
        public ProductionOrderEdit(int id_order_detail)
        {
            InitializeComponent();
            RestService RestService = new Fidabel.RestService();

            production_order_detailList = RestService.GetOrderDetail("http://" + CurrentSession.url + "/api/production_order_detail/show/" + id_order_detail);
            if (production_order_detailList != null)
            {
                lblname.Text     = production_order_detailList.name;
                txtquantity.Text = production_order_detailList.quantity.ToString();
            }
        }
コード例 #6
0
        private void Button_Clicked_1(object sender, EventArgs e)
        {
            if (production_order_detailList != null)
            {
                production_order_detailList.quantity = Convert.ToDecimal(txtquantity.Text);
                RestService RestService = new Fidabel.RestService();
                var         production_order_detail_Json = JsonConvert.SerializeObject(production_order_detailList);

                int flag = RestService.PostData(production_order_detail_Json, "http://" + CurrentSession.url + "/api/production_order_detail/edit");
                if (flag == 0)
                {
                    Navigation.PushModalAsync(new ProductionOrderDetail(CurrentSession.production_order));
                }
                else
                {
                    lblerror.Text = "Something is Wrong";
                }
            }
        }