Package webservice

Examples of webservice.TotalPosWebService


            ByteArrayOutputStream baosF = new ByteArrayOutputStream();
            XMLWriter xmlwF = new XMLWriter(baosF);
            xmlwF.write(data2Sent);

            TotalPosWebService ws = new TotalPosWebServiceService().getTotalPosWebServicePort();

            String ans = ws.closeDay(baosF.toString());
            if ( !ans.isEmpty() ){
                throw new Exception(ans);
            }
           
            /*SrvSap ss = new SrvSap();
View Full Code Here


        System.out.println("[" + Shared.now() + "] UpdateStockFromSAP " + Shared.lineNumber() " Operando");
        Connection c = null;
        try {
            Shared.createBackup("articulo precio codigo_de_barras costo movimiento_inventario detalles_movimientos");

            TotalPosWebService ws = new TotalPosWebServiceService().getTotalPosWebServicePort();

            c = ConnectionDrivers.cpds.getConnection();
            c.setAutoCommit(false);

            if ( mode.equals("MM") || mode.equals("MMBackground") ){
               
                String ansListMM = ws.listMMwithPrices(Shared.getConfig("storePrefix")+Shared.getConfig("storeName"), Shared.getConfig("Z"), ConnectionDrivers.getLastMM());
                //String ansListMM = ws.listMM("4900458128");
                System.out.println("[" + Shared.now() + "] UpdateStockFromSAP " + Shared.lineNumber() " ansListMM = " + ansListMM );

                String itemsNeeded = ConnectionDrivers.createNewMovement(c, ansListMM);
                ansListMM = null;
                System.out.println("[" + Shared.now() + "] UpdateStockFromSAP " + Shared.lineNumber() " itemsNeeded = " + itemsNeeded);
               
                // Update prices too
                updatePrices(c,ws);

                // flagsC
                updateFlagC(c, ws);

                // Descriptions
                updateDescriptions(c, ws);

                System.out.println("[" + Shared.now() + "] UpdateStockFromSAP " + Shared.lineNumber() " Listo!");
            }else if ( mode.equals("Prices")){
                updatePrices(c,ws);
            }else if ( mode.equals("initialStock") ){
               
                String ansListMM = ws.getInitialStockWithPrices(Shared.getConfig("storePrefix")+Shared.getConfig("storeName"), Shared.getConfig("Z"));
                System.out.println("[" + Shared.now() + "] UpdateStockFromSAP " + Shared.lineNumber() "  ansListMM = " + ansListMM );
                ConnectionDrivers.getInitialStock(c, ansListMM);

                ConnectionDrivers.disableInitialStock(c);

                System.out.println("[" + Shared.now() + "] UpdateStockFromSAP " + Shared.lineNumber() " Listo!");
            }else if ( mode.equals("profitWorkers")){
                System.out.println("[" + Shared.now() + "] UpdateStockFromSAP " + Shared.lineNumber() " Profit DB Name " + Shared.getConfig("profitDatabase"));
                String ans = ws.listEmployCode(Shared.getConfig("storeNameProfit"), Shared.getConfig("profitDatabase"));
                System.out.println("[" + Shared.now() + "] UpdateStockFromSAP " + Shared.lineNumber() " Ans = " + ans);
                ConnectionDrivers.updateEmployees(ans);
            }

            System.out.println("[" + Shared.now() + "] UpdateStockFromSAP " + Shared.lineNumber() " Haciendo el commit...");
View Full Code Here

TOP

Related Classes of webservice.TotalPosWebService

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.