Пример #1
0
 private void Reps_Charges(object sender, System.EventArgs e)
 {
     OSAS.OSAS oOSAS = new OSAS.OSAS();
     //oOSAS.copy_rep_charges("S07");
     oOSAS.migrate_reps("S07", true);
     //oOSAS.migrate_reps("F07",true);
 }
Пример #2
0
        static void  process_sql()
        {
            OSAS.OSAS oOSAS = new OSAS.OSAS();
            oOSAS.migrate_taxes_by_product("F07");

            oOSAS.migrate_prizes("F07");
            oOSAS.migrate_brochures("F07");
            oOSAS.update_products("F07");

            oOSAS.migrate_prizes("S07");
            oOSAS.migrate_brochures("S07");
            oOSAS.update_products("S07");

            //oOSAS.update_customers("T07");
            oOSAS.update_customers("S07");
            oOSAS.update_customers("F07");
            //oOSAS.update_customers("F06");

            //oOSAS.migrate_reps("F06",true);
            oOSAS.migrate_reps("S07", true);
            oOSAS.migrate_reps("F07", true);

            oOSAS.update_OSAS_orders("*");

            return;
        }
Пример #3
0
        private void writeaccess(object sender, System.EventArgs e)
        {
            OSAS.OSAS oTest = new OSAS.OSAS();

            //oTest.test_header_order();
            //oTest.test_detail_order();
            //oTest.create_keyed_file();
            oTest.migrate_taxes_by_product("S05");
            return;

            //OSAS.OSAS  oOSAS = new OSAS.OSAS();

            OSAS.OSAS_Orders oOrders = new OSAS.OSAS_Orders("", "T01");

            oOrders.open_OSAS_orders();

            // Writing Order Headers.
            oOrders.Header.Teacher      = "TEACHER 003";
            oOrders.Header.Student      = "STUDENT 001";
            oOrders.Header.Type         = "000";
            oOrders.Header.Prize        = "0123456789";
            oOrders.Header.No_Items     = "20";
            oOrders.Header.Retail       = "10.58";
            oOrders.Header.Collected    = "10.58";
            oOrders.Header.Tax          = "2.35";
            oOrders.Header.Printed      = "0";
            oOrders.Header.Disc_Printed = "0";
            oOrders.Header.Box          = "5";
            oOrders.Header.Date         = "2454291";
            oOrders.Header.Phone        = "6619461674";

            oOrders.write_header_order();

            // Writing Order Detail...
            oOrders.Detail.Teacher     = oOrders.Header.Teacher;
            oOrders.Detail.Student     = oOrders.Header.Student;
            oOrders.Detail.Seq         = "001";
            oOrders.Detail.Item        = "002";
            oOrders.Detail.No_Items    = "10";
            oOrders.Detail.Tax         = "0.00";
            oOrders.Detail.No_Invoiced = "0";

            oOrders.write_detail_order();

            oOrders.Detail.Teacher     = oOrders.Header.Teacher;
            oOrders.Detail.Student     = oOrders.Header.Student;
            oOrders.Detail.Seq         = "002";
            oOrders.Detail.Item        = "ABC";
            oOrders.Detail.No_Items    = "15";
            oOrders.Detail.Tax         = "0.00";
            oOrders.Detail.No_Invoiced = "0";

            oOrders.write_detail_order();

            if (!oOrders.RemoveRecord("000"))
            {
                MessageBox.Show("BAD");
            }



            // Go through order rows.

            oOrders.goStart();
            int err = 0;

            do
            {
                if (oOrders.isEOF())
                {
                    break;
                }

                if (oOrders.isHeader())
                {
                    oOrders.read_header_order();
                    //oOrders.write_header_order();
                    //MessageBox.Show(oOrders.read_record());
                    MessageBox.Show(oOrders.Header.Teacher + oOrders.Header.Student);

                    while (oOrders.same_order())
                    {
                        oOrders.read_detail_order();
                        //MessageBox.Show(oOrders.read_record());
                        MessageBox.Show(oOrders.Detail.CompanyID + oOrders.Detail.CustomerID + oOrders.Detail.Teacher + oOrders.Detail.Item);
                    }
                }
                else
                {
                    oOrders.read_detail_order();
                }
            }while (err != 2);



            oOrders.close_orders();
        }
Пример #4
0
 private void Order_Process(object sender, System.EventArgs e)
 {
     OSAS.OSAS oOSAS = new OSAS.OSAS();
     oOSAS.update_OSAS_orders("*");
 }