Example #1
0
        // ============= KANBAN ==================//
        private void get_db_insert_kanban_local()
        {
            WebReference.WebService_kanban mytagdata = new WebReference.WebService_kanban();
            DataTable dt = mytagdata.get_m_kanban();

            rows_db = dt.Rows.Count;
            if (dt.Rows.Count > 0)
            {
                for (int i = 0; i < dt.Rows.Count; i++)
                {
                    srct_code_kanban             = (string)dt.Rows[i]["SRCT_Code"];
                    customer_Code_kanban         = (string)dt.Rows[i]["Customer_Code"];
                    attension_point_kanban       = (string)dt.Rows[i]["Attension_point"];
                    part_Number_kanban           = (string)dt.Rows[i]["Part_Number"];
                    part_Name_kanban             = (string)dt.Rows[i]["Part_Name"];
                    model_kanban                 = (string)dt.Rows[i]["Model"];
                    package_kanban               = (int)dt.Rows[i]["Package"];
                    customer_kanban              = (string)dt.Rows[i]["Customer"];
                    line_kanban                  = (string)dt.Rows[i]["Line"];
                    store_Address_kanban         = (string)dt.Rows[i]["Store_Address"];
                    part_Ilustration_kanban      = (string)dt.Rows[i]["Part_Ilustration"];
                    part_Ilustration_Path_kanban = (string)dt.Rows[i]["Part_Ilustration_Path"];
                    dock_Code_kanban             = (string)dt.Rows[i]["Dock_Code"];
                    location_kanban              = (string)dt.Rows[i]["Location"];
                    kb_running_kanban            = (int)dt.Rows[i]["KB_running"];
                    insert_data_kanban_to_local();
                }
                MessageBox.Show("Kanban Update Sucessfuly");
            }
        }
Example #2
0
        private void checklogin()//update_data_to_db();
        {
            qrcode = user.Text;
            //password_s = pass.Text;
            WebReference.WebService_kanban mytagdata = new WebReference.WebService_kanban();
            DataTable dt    = mytagdata.login(this.qrcode);
            string    qr_db = (string)dt.Rows[0]["QRCode"];
            string    name  = (string)dt.Rows[0]["Username"];
            FrmHome   f1    = new FrmHome(qrcode); //ตั้งชื่อเพื่อเรียกใช้ฟอร์ม1 พร้อมส่งข้อความ (data)

            //MessageBox.Show(qrcode);
            if (dt.Rows.Count > 0)
            {
                if (qrcode == qr_db)
                {
                    MessageBox.Show("เข้าสู่ระบบสำเร็จ ยินดีต้อนรับ : '" + name + "' ");
                    user.Text = name;
                    this.Hide();
                    f1.ShowDialog();
                    this.Show();
                }
                else
                {
                    MessageBox.Show("ไม่สามรถเข้าระบบได้");
                }
                //MessageBox.Show(get_username);
            }
        }
Example #3
0
        }// end method check_dupicate(Parameter)

        // ========== Count Rows From DB ==========//
        private void count_rows_db_m_kanban()
        {
            WebReference.WebService_kanban mytagdata = new WebReference.WebService_kanban();
            DataTable dt = mytagdata.get_m_kanban();

            rows_db = dt.Rows.Count;
            // MessageBox.Show("rows DB :" + rows_db.ToString());
        }
Example #4
0
        // ============ END ===========//

        // ============ Service t_part_tag =============//
        private void get_srct_kanban_db()
        {
            WebReference.WebService_kanban mytagdata = new WebReference.WebService_kanban();
            DataTable dt = mytagdata.get_srct_kanban(this.digit_customercode, this.location_pi, this.digit_dockcode);

            if (dt.Rows.Count > 0)
            {
                part_srct_kanban = (string)dt.Rows[0]["SRCT_Code"];
                //MessageBox.Show("part_srct_kanban: " +part_srct_kanban);
            }
        }//end method
Example #5
0
 private void update_db_from_local()//update_data_to_db();
 {
     WebReference.WebService_kanban mytagdata = new WebReference.WebService_kanban();
     mytagdata.insert_data_to_db_from_local(this.part_local, this.srct_local, this.dock_local, this.pack_local, this.error_local, this.chk_local, this.user_local, this.date_local, this.ekb_local, this.kanban_local);
     // rows_db = dt.Rows.Count;
 }