Exemple #1
0
            public static void syncSingleProduct()
            {
                object date = new LastUpdDB().getUpdAB();

                if (date != null)
                {
                    ClassGroupProduct.loadFromFile();
                    ClassTVA.loadFromFile();
                    ClassProducts.loadFronFile();

                    List <ProductDB.Products> productsAB = ProductDB.Products.selAB(DateTime.Parse(date.ToString()).AddMinutes(-1), DateTime.Now.AddMinutes(1));


                    if (productsAB.Count > 0)
                    {
                        string s = "Les produits suivante a été modifié : " + Environment.NewLine;

                        foreach (var p in productsAB)
                        {
                            // ClassProducts.modifAddOnlyFile(ClassProducts.DbToVar(p));


                            try
                            {
                                s += p.Name + " (" + p.CodeBare + ") - " + "QTY : " + p.StockReal_.Count() + " - Prix : € " + Environment.NewLine;
                            }


                            catch (Exception ex)
                            {
                                string text = "KOD 013214" + ex.Message;

                                //   new ClassFunctuon().showMessageSB(text);

                                new ClassLog(text);
                            }
                        }

                        //   new ClassFunctuon().showMessageTimeList(s);
                    }
                }
            }
Exemple #2
0
        public void SyncAll()
        {
            ClassProducts.loadFronFile();

            ClassInfoClients.loadFromFile();
        }