Exemple #1
0
        private WaterImportProc getWaterModel()
        {
            WaterImportProc   model    = new WaterImportProc();
            WaterDataImporter importer = WaterDataImporter.getInstance();

            model.Running = importer.ImportRunning;
            model.EndDate = importer.LastDate;

            return(model);
        }
Exemple #2
0
        public ActionResult StartWaterImport(string type)
        {
            WaterImportProc model = getWaterModel();

            model.Running = true;

            if (type.Equals("full"))
            {
                WaterDataImporter.getInstance().ResetAllWaterData();
            }
            else
            {
                WaterDataImporter.getInstance().UpdateWaterData();
            }

            return(PartialView("_WaterImportPartial", model));
        }