2009-12-11 Nina Hueffmeyer * Greater/Modules/analysis.py: Added tool for displaying cumulative frequency distribution. * Greater/Modules/session.py: Edited display of results layer, coloured lines a little thinner now. 2009-03-09 Nina Hueffmeyer * Greater/Modules/discharges.py, sessiondischarge.py: Delete the entry 'DISCH_CLASS_ID' from the parameter list, since it is no longer used for the simulation. * Greater/UI/session.py: The color coding of the discharge layer has been based on the disch_class_id. All WWTPs are displayed in simple red now. 2009-03-01 Nina Hueffmeyer * Greater/Modules/discharges.py, sessiondischarge.py: Added the field 'roof_indust' to both objects. 2009-02-10 Nina Hueffmeyer * Greater/Modules/discharge.py, sessiondischarge.py and catchment.py: The complexity modes 2 and 3 were edited, which required new WWTP attributes both for the discharge objects as well as the session discharge objects. 2009-01-26 Nina Hueffmeyer * Greater/Modules/discharge.py and sessiondischarge.py: The parameter treated has been renamed to f_mix for clarity. 2009-01-16 Nina Hueffmeyer * Greater/Modules/discharge.py and sessiondischarge.py: Added parameter 'paved_surface' in parameter lists to enable overwriting the value in the sess_disch data. 2009-01-16 Nina Hueffmeyer * marketdata: The substance parameter surface_potential can be replaced for a single WWTP in the market data parameter set. 2004-09-09 the development of the Great-er Lake and WWTP-Mode2 Models starts. This is done by Carola Koldehoff. For the Institute of Environmental Systems Research. 2007-03-28 Frank Koormann * Greater/Modules/analysis.py: Merged changes from HEAD: (calculate_river_csim_x): Bugfix #5524: Create explicit TransientDB() (sediment_extension_results): Use actual sediment exposure module nomenclature including units (show_picture_tool): Improve picture filename handling robustness. (conc_profile_tool): ylabel is layer title, use Layer.Shapestore.Table, which contains also derived concentrations, for ProfileTable. 2006-10-06 Frank Koormann * Greater/Modules/plot.py (Profile): Cleanup of profile plotting backported from HEAD 2006-04-12 Nina Hüffmeyer Zinc project: Added emission pathways for roof and street runoff. * Greater/Modules/catchment.py: r_wwtp has new index in list disch_Pa because of new attributes 'roof' and 'street' * Greater/Modules/discharge.py: added the two discharge attributes 'roof' and 'street' to discharge object * Greater/Modules/marketdata.py: added the two consumption rates 'roof_runoff' and 'street_runoff' belonging to 'roof' and 'street' in discharge object * Greater/Modules/sessiondischarge.py: added the two discharge attributes 'roof' and 'street' to sessiondischarge object * Greater/UI/session.py: differentiate between mixed and separated sewage system and direct emittors when displaying discharge layer 2006-02-10 Frank Koormann GREAT-ER 2.0.5 USF branch tagged * GreaterModel/version.py: Version number updated. 2005-11-02 Frank Koormann * Greater/Modules/session.py (greater_exit): New, calls MainWindow.Exit. Needed to specify a correct helptext for the "exit" menu item. Bugfix for #3633. 2005-08-04 Frank Koormann * Greater/Modules/catchment.py (edit_dischargedata_tool): Update to new SciParam API. 2004-12-16 Frank Koormann Updated version information and new default API. * Greater/version.py: Updated to '2.0.3 USF' * Greater/UI/application.py (main): Default API is _dagreater_pg * Greater/UI/mainwindow.py (GreaterMainWindow.About): Added '(c) 2004' (GreaterMainWindow.update_title): Title is 'GREAT-ER USF' 2004-10-28 Carola Koldehoff * Greater/Modules/catchment.py (edit_dischargedata_tool):explanation of the discharges process steps. * Greater/Dialoges/editdischargedata.py (test_editdischargedata_dialog): new test because of explanation of wwtp process steps. 2004-10-13 Carola Koldehoff * Greater/Modules/model.py (Model.select_modelchain): Because of an error occouring when using Revision 1.89 the code line 446-457 is switched out. 2004-09-27 Jan-Oliver Wagner A bug fix regarding default values and a generalization from Substance, Environment, Model into ParamterBlock for better code maintenance. * Greater/Modules/parameterblock.py (ParameterBlock.da_get_xxx_det): New. Method to be overridden by the deriving class. (da_get_det): No need to override since da_get_xxx_det is used now. Thus, the implementation is moved here and could be eliminated in all derived classes. At the same time a bug in this function fixes the problem that the default values had not been parsed correctly. * Greater/Modules/substance.py (Substance.da_get_xxx_det): New. Defines the function to get parameter details. (Substance.da_get_det): Removed. This is generalized into class ParameterBlock. * Greater/Modules/model.py (Model.da_get_xxx_det): New. Defines the function to get parameter details. (Model.da_get_det): Removed. This is generalized into class ParameterBlock. * Greater/Modules/environment.py (Environment.da_get_xxx_det): New. Defines the function to get parameter details. (Environment.da_get_det): Removed. This is generalized into class ParameterBlock. 2004-09-27 Frank Koormann Full implementation of GREAT-ER Sediment Extension result analysis. * Greater/Dialogs/csimclassesriver.py (csimclassesriver_dialog.__init__): The basic dialog title is fixed. Only the base layer name can be specified. Changed the meaning of parameter title to base accordingly. (csimclassesriver_dialog.csim_x_percentile): The stored base layer name is used for labelling percentiles etc. (_TestApp): Updated test. * Greater/Dialogs/selectcsimx.py (SelectCsimXDialog.__init__): Added base layer name as additional parameter (used in dialog title). (SelectCsimXDialog.selectcsimx_dialog): Hand through base layer name. (_TestApp): Updated test. * Greater/Modules/analysis.py (titlemap): Mapping between GreaterLayerType and title components. (calculate_river_csim_x): Derive title components from LayerType. (csim_classes_river): Derive title components from LayerType and include this also in newly created layers. Layer attribtes are derived from the current base layer, not from the stretch results table. The layer is stored under "CSIMCLASSESRIVER_%basename", i.e. one csim_classes layer per base layer is used. (combine_csim_flow): Derive title components from LayerType and include this also in newly created layers. Layer attribtes are derived from the current base layer, not from the stretch results table. The layer is stored under "COMBINEDCSIMFLOW_%basename", i.e. one csim_flow layer per base layer is used. (SelectTool.MouseUp): Use the currently selected layer for analysis tools instead of the RiverNetworkResultsLayer. (mass_flux_tool): Derive title components and field name from LayerType. (conc_profile_tool): Derive field for profile plotting from current classification. (Updated sensitivities): calculate_river_csim_x, csim_classes_river, combine_csim_flow: Active if selected layer is a base layer (total, dissolved, sorbed or Sediment) mass_flux: Active if selected layer is a base layer but not the Sediment one. concentration_profile: Active if the selected layer is a stretch result layer but not displaying Sediment results. * Greater/Modules/catchment.py (RiverNetworkSedimentExtensionLayers): New, return list of layers with the sediment extension results. (RiverNetworkBaseLayers): New, return list of base layers. (RiverNetworkSedimentLayers): Redefined, return Sediment layers. Note that this is a subset of the sediment extension results! Return empty list instead of None if no Sediment layers exist. (RiverNetworkNonSedimentLayers): Removed. (RiverNetworkResultsLayersProfile): Return list of layers with usable concentration profile results. This are all stretch result layers. * Greater/Modules/model.py (start_simulation): Handle results from map.RiverNetworkSedimentLayers() correctly. * Greater/UI/context.py (context_nonsediment_stretch_results_layer): Removed. (context_stretch_results_baselayer): New. Return true, if the current layer is a stretch results base layer. (context_stretch_results_layer_massflux): New. Return true, if current layer has stretch results for mass flux. (context_stretch_results_layer): Removed. (context_stretch_results_layer_profile): New. Return true, if current layer has stretch results for conc profile. (context_can_start_simulation): Fixed typo in doc-String. 2004-09-21 Frank Koormann Sample implementation of GREAT-ER Sediment Extension result analysis. * doc/greater-testplan.tex: Added section for analysis menu item activity status. * Greater/Modules/catchment.py (CatchmentMap.RiverNetworkNonSedimentLayers): New, return list of layers with the river results without the sediment layer. * Greater/UI/context.py (context_csim_total_layer): New, return true, if the current layer is the basic Csim total layer. (context_nonsediment_stretch_results_layer): New, return true if the current layer is a nonsediment stretch results layer. (context_stretch_results_layer): New, return true, if the current layer is a stretch results layer. * Greater/Modules/analysis.py (sediment_extension_results): Smarter size of dialog. Derive new ShapeStore from join of RiverNetworkLayer and results.StretchTable (compute_river_csim_x): New optional parameter basename, used to handle columns for percentile calculation more flexible. (calculate_river_csim_x): Flexible dreive basename from LayerType, create layer from result class base layer (instead of join of RiverNetworkLayer and results.StretchTable. 2004-09-17 Frank Koormann * doc/greater-manual.tex: Added documentation of basic GREAT-ER Sediment Extension functionality. * doc/screenshots/editmodelparameters-dlg-river.eps: Updated * doc/screenshots/editmodel-dlg-sediment.eps: New * doc/screenshots/editmodel-sediment-warning.eps: New * doc/screenshots/sedimentresults-dlg.eps: New 2004-09-17 Frank Koormann * doc/greater-testplan.tex: Added new test suite for GREAT-ER Sediment Extension. Model selection logics and basic layer display tested so far. 2004-09-17 Frank Koormann * Greater/Modules/catchment.py (CatchmentMap.__init__): Remove debug output * Greater/Modules/model.py (select_modelchain): More robust implementation of Sediment Layer Check 2004-09-09 Frank Koormann Activation of GREAT-ER Sediment Extension * Greater/Dialogs/selectmodel.py (selectmodel_dialog): Initialize ParameterNotebookDialog with two columns. * Greater/Modules/model.py (select_modelchain): Added check for GREAT-ER Sediment Extension related model chain settings: Raise a warning if the Sediment Extension is active but River mode is 1. The extension will not be executed in this case. (start_simulation): Remove old Sediment Layers after successful cimpletion of new simulation run. * Greater/Modules/analysis.py (sediment_extension_results): New, add sediment extension result layers to the map from a multi choice list presented to the user. * Greater/Modules/catchment.py (CatchmentMap.RiverNetworkLayerOfType): New, return all layers of a given type. This method is equal with the RiverNetworkCSIMXLayer but better in naming. Potentially it will replace the latter later. (RiverNetworkSedimentLayers): New, return all layers matching the "CSIM.*DISS|CSIM.*SORB|CSIM.*SED" regexp (i.e. the Sediment layers). * Greater/UI/context.py (context_sediment_extension_results_exist): New, return true if a simulation session is open and has stretch results and the rivernetwork results layer contains results from the sediment extension. 2004-09-08 Jan-Oliver Wagner * Greater/Modules/analysis.py (pec_catchment): commented out Vinv/P_Vinv computation and added hint that this is not really used but should remain in the code. Also fixed a typo. 2004-09-06 Frank Koormann * Greater/UI/session.py (GreaterSession.update_map): Draw lakes (stretch type 6..11) with light blue thick lines. 2004-01-05 Frank Koormann * doc/great-er_gnu-linux_how-to.txt: New, how to install GREAT-ER under GNU/Linux 2003-12-08 Frank Koormann * Greater/Modules/session.py (authenticate): Call SimulationServerConnection() with explicite db_api_module. This fixes failure to start model system via Authenticate. 2003-11-05 Frank Koormann Hand db_api_module settings through to local model system: * Greater/Modules/model.py (SimulationServerConnection.__init__): db_api_module=None as new parameter, store as attribute (SimulationServerConnection.reconnect): Initialize SchedulerProcess an WorkerProcess with db_api_module (select_simulation_server): Initialize SimulationServerConnection with db_api_module. * Greater/UI/application.py (GreaterApplication.set_db_api_module, GreaterApplication.get_db_api_module): New, provide acces on applcation attribute db_api_module. (main): Store db_api_module and initialize SimulationServerConnection accordingly. 2003-11-04 Frank Koormann * Greater/Dialogs/OpenSession.py (OpenSessionDialog.__init()__): Make sure OpenSessionDialog.sessionlist is declared before method returns. This fixes #2206. 2003-10-10 Jan-Oliver Wagner * Greater/Modules/analysis.py (combine_csim_flow): added another check to avoid problems for very specific situations. 2003-10-07 Frank Koormann * Greater/UI/mainwindow.py (GreaterMainWindow.About): Check if SimulationServerConnection is available. 2003-10-01 Frank Koormann * doc/Manual.sty, doc/greater-manual.tex: Renamed GREAT-ER II to GREAT-ER desktop 2003-09-30 Frank Koormann Version information update * Greater/version.py: Update to 'GREAT-ER desktop version 2.0.0' * Greater/Modules/model.py (SimulationServerConnection.reconnect): Store the model system version information under self.version * Greater/UI/mainwindow.py (GreaterMainWindow.About): Extended version informations: Thuban and GREAT-ER model system added, reformatting GREAT-ER API version. * Greater/Dialogs/about.py (AboutDialog.dialog_layout): Set version info textfield to 300 pixel width * Resources/Bitmaps/banner.png: Updated version following new naming policies 2003-09-29 Jan-Oliver Wagner * Greater/Modules/analysis.py (show_picture_tool): Extended error message to explain possible reasons why a picture can not be shown. 2003-09-25 Frank Koormann * Greater/Modules/parameter.py (CreateParameter): In description.remark replace '\\n' with '\n' to make use of sciparam multiline details. 2003-09-24 Jan-Oliver Wagner * doc/greater-testplan.tex: Added test for Thuban manual. * Greater/Modules/plot.py (Profile): Added adaption of y-axis for ranges starting at a very large value with very small values. 2003-09-24 Frank Koormann * Greater/Modules/model.py (start_simulation): Play a system sound (exclamation) under MSW when the simulation is finished. Can only be switched off by commenting the code. 2003-09-24 Bernhard Herzog * Greater/UI/application.py (error_message) (GreaterApplication.ShowExceptionDialog): Factor some of the error message generation code into a separate function error_message so that it can be tested. Also fix some bugs in the code now in error_message. * test/test_application.py: New. Tests for code in Greater/UI/application.py. At the moment only for error_message() 2003-09-24 Jan-Oliver Wagner A few bug-fixes. * Greater/Modules/plot.py (Profile): introduced minimum step of 1 if x- or y-axis' range fall below a certain value. * Greater/Modules/help.py: Added registered command for thuban manual. Changed name of command for greater manual. (user_manual): Added parameter doc_name to generalize regarding the loaded pdf-file. (greater_user_manual, thuban_user_manual): New. Call user_manual with the corresponding filename. (init_menu): Added menu entry for thuban manual. * Greater/Modules/catchment.py (xmldata_pics): Changed default fill color. 2003-07-29 Frank Koormann * doc/screenshots/traceback.eps: New, traceback dialog. 2003-07-28 Frank Koormann * doc/greater-manual.tex: Added source package URLs. Added section on bug reporting 2003-07-28 Frank Koormann * Greater/Modules/analysis.py (add_background): Identify background layers by OBJ_SUB_TYPE instead of NAME. Added MONITORING layers (with grey fill color). 2003-07-25 Frank Koormann * doc/screenshots/tutorial-tableview.eps: Updated screenshot (new tableview in Greater) 2003-07-24 Frank Koormann * doc/Manual.sty: Style file for manual settings. * doc/screenshots/editdischargedata-dlg.eps, doc/screenshots/editdischargedata-tutorial-dlg.eps, doc/screenshots/editemission-tutorial-dlg.eps, doc/screenshots/editemissiondata-dlg.eps, doc/screenshots/substance-dlg-partitioning.eps, doc/screenshots/substance-dlg-riskassessment.eps: Updates (new order of entries). 2003-07-24 Jan-Oliver Wagner Discharge and Market data dialog did not consider sort order as defined in the database. This is fixed now. * Greater/Modules/discharge.py (Discharge.__init__): added self._descriptions. (Discharge.Parameters): Sort the parameters. (Discharge._create_parameters): Fill self._descriptions. * Greater/Modules/sessiondischarge.py (SessionDischarge.__init__): added self._descriptions. (SessionDischarge.Parameters): Sort the parameters. (SessionDischarge._create_parameters): Fill self._descriptions. * Greater/Modules/marketdata.py (MarketData.__init__): added self._descriptions. Fill self._descriptions. (MarketData.Parameters): Sort the parameters. 2003-07-23 Frank Koormann * doc/greater-manual.tex, doc/greater-tutorial.tex: Proof-read and gaspell-checked. * doc/gnufdl.tex: Update to new file naming concept. * doc/screenshots/mainwindow-elements.sk: Sketch based version of explanatory screen shot (vector fonts scale better). * doc/screenshots/mainwindow-elements.eps: Now based on sketch version. * doc/screenshots/substance-dlg-riskassessment.eps: Considers new units (mg/L instead of kg/m^3). 2003-07-23 Jan-Oliver Wagner * Greater/Modules/analysis.py (risk_analysis): Added a factor for unit conversion of pnec. This resolves https://intevation.de/rt/webrt?serial_num=1984 2003-07-22 Frank Koormann * doc/greater-tutorial.tex: New GREAT-ER II Tutorial (as part of GREAT-ER II User Manual) * doc/greater-manual.tex: Use packages lastpage, color, Manual Extended installation description, inclusion of tutorial, reworked User Manual. * doc/session-workflow.sk: New, diagramm to illustrate session workflow. * doc/Makefile: Added greater-tutorial.tex as dependecy for greater-manual.dvi * doc/gnufdl.tex: Added \CVS dummy tag to ensure corret file display. * doc/screenshots/editenvironmentparameters-dlg-environment.eps, doc/screenshots/editmodelparameters-dlg-general.eps, doc/screenshots/missingparameters-dlg.eps, doc/screenshots/peccatchment-dlg.eps, doc/screenshots/pecinitial-dlg.eps, doc/screenshots/startsimulation-dlg.eps, doc/screenshots/substance-dlg-degradation.eps, doc/screenshots/substance-dlg-emissiondata.eps, doc/screenshots/substance-dlg-identification.eps, doc/screenshots/substance-dlg-partitioning.eps, doc/screenshots/substance-dlg-physicochemical.eps, doc/screenshots/substance-dlg-riverremoval.eps, doc/screenshots/substance-dlg-wwtpremoval.eps: Updated screenshots * doc/screenshots/add-background-dlg.eps, doc/screenshots/combine-csim-flow.eps, doc/screenshots/discharge-results.eps, doc/screenshots/distribution-dlg.eps, doc/screenshots/editdischargedata-tutorial-dlg.eps, doc/screenshots/editemission-tutorial-dlg.eps, doc/screenshots/editmodelparameters-dlg-river2.eps, doc/screenshots/identify-dlg.eps, doc/screenshots/initial_screen.eps, doc/screenshots/mainwindow-elements.eps, doc/screenshots/menu-analysis.eps, doc/screenshots/menu-catchment.eps, doc/screenshots/menu-environment.eps, doc/screenshots/menu-file.eps, doc/screenshots/menu-simulation.eps, doc/screenshots/menu-substance.eps, doc/screenshots/newsession-dlg.eps, doc/screenshots/required-parameters-river2.eps, doc/screenshots/startsimulation-tutorial.eps, doc/screenshots/substance-dlg-riskassessment.eps, doc/screenshots/tutorial-calder-with-bg.eps, doc/screenshots/tutorial-concentrationprofile.eps, doc/screenshots/tutorial-fullcalder.eps, doc/screenshots/tutorial-join-dlg.eps, doc/screenshots/tutorial-massflux.eps, doc/screenshots/tutorial-monitoring-data.eps, doc/screenshots/tutorial-results.eps, doc/screenshots/tutorial-riskanalysis.eps, doc/screenshots/tutorial-save-as.eps, doc/screenshots/tutorial-showtable.eps, doc/screenshots/tutorial-tableview.eps, doc/screenshots/tutorial_session.eps: New screenshots. 2003-07-21 Bernhard Herzog * README: Add some basic installation instructions * Greater/Modules/catchment.py (CatchmentMap.AddLayer): Add objects to self.temp_file_objects for all layers with ShapefileStores whose files are in the temp dir, not just fro GreaterLayers 2003-07-18 Thomas Koester * doc/greater-manual.tex: Use twoside printing with binding correction of 19mm. Added fancy headers/footers for even pages. 2003-07-17 Thomas Koester * doc/greater-manual.tex, doc/gui_styleguide.tex: Use the term "GREAT-ER II". 2003-07-17 Bernhard Herzog * Greater/Modules/catchment.py (CatchmentMap.__init__): New instance variable temp_file_objects to hold all objects that represent open files in the temp dir (CatchmentMap.remove_temp_dir): Close all objects in self.temp_file_objects before trying to remove them. This should fix the problem on windows that open files can't be deleted. (CatchmentMap.AddLayer): Extend the inherited method to add objects to temp_file_objects if the added layer is one of the special layers. * Greater/UI/session.py (GreaterSession.RemoveMap): New. extend inherited method to remove all tables that depend on the map using remove_dependent_tables (GreaterSession.remove_dependent_tables): New. Pretend to remove all tables depending on a given set of shapestores. (GreaterSession.RemoveTable): New. Extend the inherited method to remove the tables that depend on the removed table. 2003-07-01 Jan-Oliver Wagner * Greater/Modules/analysis.py (add_background): Now correctly sets the default line color for roads and railroads. This fixes https://intevation.de/rt/webrt?serial_num=1988 (pec_initial, pec_catchment): Apply ".3g" to format the result values. This fixes https://intevation.de/rt/webrt?serial_num=1982 2003-07-01 Jan-Oliver Wagner * Greater/Modules/analysis.py (risk_analysis): Consider the river-factor correctly. Reduced number of classes to 2. Improved the range setting. This resolves https://intevation.de/rt/webrt?serial_num=1983 2003-06-25 Jan-Oliver Wagner * Greater/Modules/catchment.py (Catchment._construct_table): Added test for no records. (Catchment._load_discharges, Catchment._load_stretches): Added test whether a table was constructed (or just None was returned). 2003-06-25 Jan-Oliver Wagner * Greater/Modules/help.py (user_manual): apply os.startfile() instead of wxExecute for MSW. 2003-06-25 Jan-Oliver Wagner * Greater/Modules/session.py (edit_session): Set recuresively all privileges in case they have changed. 2003-06-25 Jan-Oliver Wagner * Greater/Modules/model.py (start_simulation): Added handling of status 'stopping'. 2003-06-16 Jan-Oliver Wagner * Greater/Modules/analysis.py (pec_catchment): Fixed text on PEC catchment. 2003-06-13 Frank Koormann * Greater/Modules/help.py (pdfViewer.OnTerminate): Added error number. (user_manual): More stable path generation for manual. * Greater/version.py: longversion updated to Milestone 3. * Greater/UI/mainwindow.py (Mainwindow.About): Naming update * Greater/Modules/model.py (missing_parameters): Typo fixed. 2003-06-12 Jan-Oliver Wagner * Greater/Modules/analysis.py (add_background): Set the title of the layer according to the title in the database. 2003-06-11 Frank Koormann * doc/greater-testplan.tex: Version update to 2.0 MS3 release 2003-06-06 Jan-Oliver Wagner Take care that the log-file is initialized with a new thuban start. * Greater/Modules/model.py: Removed any code regarding deprecated function stop_simulation. (SchedulerProcess.start): Use flag 'w' to reinitialize the log-file instead of 'a' to append. (WorkerProcess.start): Initialize the log-file. 2003-06-05 Frank Koormann * Greater/Modules/session.py (authenticate): Disable mainwindow during model system startup. * Greater/UI/application.py (main): Disable mainwindow during model system startup (auto-login) 2003-06-04 Bernhard Herzog * Greater/UI/application.py (GreaterApplication.ShowExceptionDialog): delete the last exception info that python keeps in sys.last_* because especially last_traceback keeps indirect references to all objects bound to local variables and this might prevent some object from being collected early enough. 2003-06-03 Jan-Oliver Wagner Fixed bugs https://intevation.de/rt/webrt?serial_num=1913 https://intevation.de/rt/webrt?serial_num=1916 https://intevation.de/rt/webrt?serial_num=1917 and updated testplan. * Greater/Modules/analysis.py (combine_csim_flow): fixed a bug. (conc_profile_tool): Fixed a bug. * Greater/UI/session.py (GreaterSession.update_results_layer): Made sure, we have presently a CatchmentMap before trying to update the results layer. * doc/greater-testplan.tex: Fixed some test items according to the new GREAT-ER version. Added some info in the header. 2003-06-03 Thomas Koester * Greater/Modules/analysis.py (csim_classes_river): Values in Class 0 will be assigned to default group. * Greater/Dialogs/csimclassesriver.py, Greater/Dialogs/selectcsimx.py, Greater/Modules/analysis.py, Greater/UI/session.py: Always use 'Csim', not 'csim' or 'CSim'. 2003-06-03 Jan-Oliver Wagner Fix for bug https://intevation.de/rt/webrt?serial_num=1888 * Greater/Modules/results.py (Results): Fixed a wrapped field. (Results.__init__): Fixed bug. * Greater/Modules/analysis.py: Changed sensitivity methods. * Greater/Modules/session.py (new_session, open_session): Set simulation to None after deleting it. * Greater/UI/context.py (context_stretch_results_exist, context_discharge_results_exist): New. (context_results_exist_and_layer_visible): Renamed to context_stretch_results_exist_and_layer_visible including the corresponding definition. 2003-06-02 Frank Koormann * Greater/Modules/substance.py (edit_substance): Wrap actions after confirmed edits in BusyCursor. * Greater/Modules/model.py (select_modelchain): Wrap actions after confirmed selection in BusyCursor. 2003-06-01 Jan-Oliver Wagner Now all results values are already adapted to the sensible unit when loaded into the tables. * Greater/Modules/results.py (Results.TreeInfo): Use method calls instead of accesing the variables directly. (Results._create_table_from_csv_binobj): new additional optional parameter unit_factor is used to multiply all values of the read tables. (Results._load_results): Apply the unit_factor. * Greater/Modules/analysis.py: Removed any occurance of using the STP- or River-Factor. * Greater/UI/session.py (GreaterSession.update_results_layer): Removed use of River-Factor. 2003-05-30 Jan-Oliver Wagner * Greater/Modules/datatable.py (AppendColumn, UpdateColumn): Fix a very stupid bug (never assume dict.values() to be in a certain order. * Greater/Modules/analysis.py (calculate_river_csim_x, csim_classes_river, combine_csim_flow, discharge_influent_csim, discharge_effluent_csim, risk_analysis): Removed unnecessary conversion to AutoTransientTable. (conc_profile_tool): Added try-finally for busy-cursor. 2003-05-30 Jan-Oliver Wagner * Greater/Modules/results.py (Results.SetStretchTable, Results.SetDischargeTable): Reset dictionary. * Greater/Modules/analysis.py (calculate_river_csim_x, risk_analysis): Enabled AddShapeStore() for the newly created layers. (csim_classes_river, combine_csim_flow, discharge_influent_csim, discharge_effluent_csim): Put BusyCursor into a try-finally. Enabled AddShapeStore() for the newly created layers. 2003-05-30 Jan-Oliver Wagner * Greater/Modules/analysis.py, Greater/UI/session.py : Replaced ClassGenerator by direct call of its functions (according to the corresponding change in Thuban). 2003-05-29 Jan-Oliver Wagner * Greater/Modules/session.py (SimulationSession.RequiredParametersSync): Test for an existing connection to the simulation server first. 2003-05-29 Jan-Oliver Wagner * Greater/Modules/session.py (new_session, open_session): return None if something went wrong. (save_session): Return None if there is no SimulationSession anymore. * Greater/Modules/catchment.py (Catchment.__del__): Bug-fix: Set session to unmodified. 2003-05-28 Jan-Oliver Wagner Fixes for https://intevation.de/rt/webrt?serial_num=1906 and https://intevation.de/rt/webrt?serial_num=1905 * Greater/Modules/results.py (Results.__del__): Unset the session's modified flag. * Greater/Modules/session.py (open_session, save_session, save_session_as, close_session): Place the UnsetModified() command at the right position and update required parameters where apropriate. * Greater/UI/session.py (GreaterSession.WasModified): Use True/False instead of 1/0. 2003-05-28 Jan-Oliver Wagner * Greater/UI/session.py (GreaterSession.UnreferencedTables): New. Takes care that special GREAT-ER tables are not added to this list so that the user can not remove them. 2003-05-28 Jan-Oliver Wagner Further improved performance. * Greater/UI/session.py (GreaterSession.update_map): Removed handling of Csim Mean (except removal of layer if no results are there). (GreaterSession.update_results_layer): New. Does the handling update_map did before. * Greater/Modules/model.py (start_simulation): call update_results_layer() after successful simulation. * Greater/Modules/session.py (open_session, save_session_as): call update_results_layer(). 2003-05-28 Jan-Oliver Wagner Improved performance by moving away various operations from the update-method for the map. Also, most results layers are now removable. * Greater/UI/session.py (GreaterSession.update_map): Removed handling of Risk and CSimX layers. Now the layers are just removed if no corresponding results exist anymore. * Greater/Modules/analysis.py (calculate_river_csim_x, risk_analysis): Added creation of the layer. Apply try-finally fpr busy-cursor. (csim_classes_river): Apply try-finally fpr busy-cursor. * Greater/Modules/catchment.py (Catchment._load_discharges, Catchment._load_stretch_attributes): Set a title for the table. (Catchment.CanRemoveLayer): Make only the base layers unremovable. * Greater/Modules/session.py (SimulationSession.RemoveAllResults): Removed superfluous command. (SimulationSession._get_results): Use SetResult() instead of doing the same by hand. 2003-05-28 Jan-Oliver Wagner * Greater/Modules/model.py (start_simulation): Remove also the discharge influent/effluent layer when a simulation is successfully finished. * Greater/UI/session.py (GreaterSession.update_map): remove all the results layers if there are no results 2003-05-28 Jan-Oliver Wagner * Greater/Modules/analysis.py (add_background): sort the selection list for the dialog. 2003-05-28 Frank Koormann * Greater/UI/application.py (main()): Wrap db-auto-login with try/except for better stability. Issue a app.Session().changed() 2003-05-28 Jan-Oliver Wagner * doc/greater-testplan.tex: Updated according to the new version. Mainly the Analysis-section has been extended. 2003-05-27 Frank Koormann * Greater/UI/session.py (GreaterSession.update_map): Wrapped entire functionality into try/finally to catch the various exit points to call wxEndBusyCursor() 2003-05-27 Jan-Oliver Wagner * Greater/UI/session.py (GreaterSession.update_map): Added missing wxEndBusyCursor. 2003-05-27 Frank Koormann Error messages numbering (8000-8499 for the Client, 8500 - 8999 for the Client - Model connections). API errors are counted from 9000. * Greater/Modules/model.py: Numbered GreaterModelError * Greater/Modules/session.py: Numbered GreaterClientError and GreaterModelError * Greater/UI/application.py (GreaterApplication.ShowExceptionDialog): Display error number with the message 2003-05-27 Jan-Oliver Wagner * Greater/UI/application.py (main): Deactivate Raster-Image-Handling if not in alpha-mode. 2003-05-27 Jan-Oliver Wagner * Greater/Modules/help.py (pdfViewer, user_manual): Added MSW-specific stuff. 2003-05-27 Jan-Oliver Wagner Introduce help module. * Greater/Modules/help.py: New. GREAT-ER Help Object. * Greater/UI/application.py (main): Don't create a help menu on your own, but incorporate rather the GREAT-ER help module. 2003-05-27 Frank Koormann * Greater/UI/application.py (GreaterApplication.ShowExceptionDialog): Loop over wxIsBusy() until BusyCount == 0. 2003-05-27 Jan-Oliver Wagner * Greater/UI/session.py (GreaterSession.update_map): Apply wxBusyCursor. 2003-05-27 Jan-Oliver Wagner * Greater/Modules/session.py (init_menu): removed toggle_session_tree. * Greater/UI/application.py (main): renamed variable alpha_module to alpha_mode. Added insertion of toggle_session_tree to file-menu for the alpha-mode. 2003-05-26 Jan-Oliver Wagner * Greater/Dialogs/about.py, Greater/Dialogs/authenticate.py, Greater/Dialogs/csimclassesriver.py, Greater/Dialogs/editdischargedata.py, Greater/Dialogs/editenvironment.py, Greater/Dialogs/editmarketdata.py, Greater/Dialogs/editsession.py, Greater/Dialogs/editsubstance.py, Greater/Dialogs/errordialogs.py, Greater/Dialogs/openparablock.py, Greater/Dialogs/opensession.py, Greater/Dialogs/profile.py, Greater/Dialogs/saveparablockas.py, Greater/Dialogs/savesessionas.py, Greater/Dialogs/selectcatchment.py, Greater/Dialogs/selectcsimx.py, Greater/Dialogs/selectmodel.py, Greater/Dialogs/selectsimserver.py, Greater/Dialogs/showpicture.py, Greater/Dialogs/widgets.py, Greater/Modules/alpha.py: Replace the true/false of wxWindows by True/False of Python 2.2.1. 2003-05-26 Jan-Oliver Wagner Improved sensitivity of the tool commands. * Greater/UI/context.py (discharge_layer_visible, context_results_exist_and_layer_visible, context_pics_exist_and_layer_visible, context_substance_and_catchment_open_and_discharge_layer_visible): New. * Greater/Modules/analysis.py: Changed sensitivity of the three tool commands to be active only if the corresponding layer is visible. * Greater/Modules/catchment.py: Changed sensitivity of the two tool commands to be active only if the corresponding layer is visible. 2003-05-26 Jan-Oliver Wagner * Greater/Modules/analysis.py (csim_classes_river, combine_csim_flow, discharge_influent_csim, discharge_effluent_csim): Replaced deprecated SimpleStore by use of DerivedShapeStore. 2003-05-26 Frank Koormann * Greater/Modules/model.py (start_simulation): Removed Debug-Output 2003-05-23 Jan-Oliver Wagner Improved management of the GREAT-ER tables. * Greater/Modules/datatable.py (AppendColumn, UpdateColumn): Don't require table to be a MemoryTable and use ReadRowAsDict instead of direct access. * Greater/Modules/results.py (Results.__init__): initialize _greater_session and _profile_tables. (Results.__del__): New. On delete, remove the results tables from the session. (Results.AddProfileTable): New. Add a profile table to be stored by the results. (Results.SetDischargeTable, Results.SetStretchTable): Now manage table to be in the Session. * Greater/Modules/catchment.py (Catchment.__init__): initialize _greater_session, _session_discharge_table and _market_discharge_table. Update the market and session discharge table. (Catchment.__del__): New. On delete, remove the market and session discharge tables from the session. (Catchment.UpdateSessionDischargeTable, Catchment.UpdateMarketDischargeTable): New. Rebuild the corresponding table. (edit_marketdata_tool, edit_marketdata): Update the corresponding tables. * Greater/Modules/model.py (start_simulation): Set the parent for a new result. * Greater/Modules/analysis.py (conc_profile_tool): Construct a table and add it to the session. * Greater/Modules/session.py (SimulationSession.__init__): Additional parameter parent connects to Greater Session. (new_session, make_new_session, open_session, save_session, save_session_as): Set parent. * Greater/Dialogs/profile.py (ProfileDialog): Removed all functionality of "Save Table". * Greater/UI/session.py (GreaterSession.update_map): Replace deprecated SimpleStore by DerivedShapeStore. Apply AddShapeStore to add tables to session. * Greater/UI/serialize.py: Added __version__. 2003-05-23 Thomas Koester * Greater/UI/mainwindow.py (GreaterMainWindow.About): About dialog now has a parent. Fixes bug #1889. 2003-05-23 Frank Koormann * Greater/UI/application.py (main): Instantiate the application object with 0 to suppress an extra window for stdout/stderr messages under Win32. * Greater/Modules/session.py (SimulationSession.RequiredParametersSync): Call sys.exc_info() in a safer way. * Greater/Modules/model.py (missing_parameters, start_simulation()): Call sys.exc_info() in a safer way. 2003-05-21 Jan-Oliver Wagner Added table representation for session discharges and market data. * Greater/Modules/sessiondischarge.py (SessionDischarge.TableFields, SessionDischarge.TableValues): New. Return data as relevant for a table representation. * Greater/Modules/marketdata.py (MarketData.TableFields, MarketData.TableValues): New. Return data as relevant for a table representation. * Greater/Modules/discharge.py (Discharge.SessDisch): New. Return the Session Discharge. * Greater/Modules/catchment.py (Catchment.SessionDischargeTable): New. Return a table object for the user-specific changes on discharges. (Catchment.MarketDischargeTable): New. Return a table object for the user-specific market changes on discharges. * Greater/Modules/alpha.py (show_session_discharge_table, show_market_discharge_table): New. 2003-05-21 Jan-Oliver Wagner Improved About-Dialog. * Greater/Dialogs/about.py: New. A About Dialog. * Greater/UI/mainwindow.py (GreaterMainWindow.About): Call the new about-dialog. 2003-05-21 Jan-Oliver Wagner Fixes a privileges bug and some improved robustness. * Greater/UI/session.py (GreaterSession.update_map): Don't try to show results if there is no corresponding results table. * Greater/Modules/results.py (Results._create_table_from_csv_binobj, Results.SetDischargeTable, Results.SetStretchTable): Check for bad tables. * /Greater/Modules/session.py: removed some unneeded imports. (save_session_as): Set the Privileges of the binary RESULTS objects. 2003-05-21 Frank Koormann * Greater/Modules/session.py (make_new_session): Explicitely set the privileges specified by the user to overwrite API defaults for da_create_temp_sess(-1,'Y') 2003-05-20 Frank Koormann SimServerConnection: A scheduler without a worker is not valid. * Greater/Dialogs/selectsimserver.py (SelectSimulationServerDialog.OnTestServer): return status['num_workers'] 2003-05-20 Frank Koormann Error System Update: Client handles 3 types of errors seperatly: GreaterAPIError, GreaterClientError and GreaterModelError. * Greater/UI/application.py (GreaterApplication.ShowExceptionDialog): Extended to handle the three specific error types. In any other case display default traceback with URL of the GREAT-ER bug tracker. * Greater/UI/session.py (GreaterSession): New attribute db_error_messages (GreaterSession.SetDBConnection): If DB connection is established, load API error messages from database into db_error_message dictionary. (GreaterSession.ErrorMessages): New, return db_error_message. * Greater/Dialogs/opensession.py (OpenSessionDialog.dialog_layout): Raise RuntimeError('GreaterClientError:..') if substance can't be read for session. * Greater/Modules/model.py (SchedulerProcess.start, SchedulerProcess.wait_for_message): Raise RuntimeError('GreaterModelError:..') if startup fails. (WorkerProcess.start): Raise RuntimeError('GreaterModelError:..') if startup fails. (SimulationServerConnection.UseServer): New, return True/False (SimulationServerConnection.ServerURL): New, return ServerURL (missing_parameters, start_simulation: Raise RuntimeError('GreaterModelError:..'). * Greater/Modules/session.py (SimulationSession._get_substance, SimulationSession._get_model, SimulationSession._get_environment, SimulationSession._get_results): Raise RuntimeError('GreaterClientError:..'). (SimulationSession.RequiredParametersSync): Raise RuntimeError('GreaterModelError:..') 2003-05-19 Frank Koormann * Greater/Dialogs/selectsimserver.py (SelectSimulationServerDialog.OnTestServer): Return Pythons 'True' and 'False' values instead the one wxPython 'true'/'false' pair, which are depracted and led to the reported bug #1865 under Win32 with newer versions of wxPython. 2003-05-19 Jan-Oliver Wagner * Greater/UI/mainwindow.py (GreaterMainWindow.__init__): Changed sizes for the status bar fields. (GreaterMainWindow.update_status_bar): Added 'needs simulation' flag 2003-05-19 Frank Koormann * Greater/UI/application.py (GreaterApplication.ShowExceptionDialog): Check for Busy-Mode before trying to end wxBusyCursor. Otherwise an exception occurs under Win32. 2003-05-19 Jan-Oliver Wagner * Greater/Modules/analysis.py (pec_catchment): Improved perfomance drastically by using dictionaries instead of linear search. 2003-05-14 Jan-Oliver Wagner * Greater/Modules/catchment.py (edit_marketdata_tool, edit_dischargedata_tool): replaced deprecated function read_record by ReadRowAsDict. * Greater/Modules/analysis.py (combine_csim_flow): Fixed a bug and replaced deprecated function read_record by ReadRowAsDict. (mass_flux_tool): replaced deprecated function read_record by ReadRowAsDict. (conc_profile_tool): Improved performance drastically by using dictionaries to replace linear search. 2003-05-14 Jan-Oliver Wagner Added implementation for the remaining analysis functions. Various fixes. * Greater/Modules/results.py (Results): Added wrapped fields STPFactor and STPUnit. * Greater/Modules/analysis.py (csim_classes_river): Use busy-cursor and fix a bug: now percentiles are copied. Also: Completed implementation. (combine_csim_flow): Replaced dummy by implementation. (pec_catchment): Use busy-cursor. Fixed a bug: now also a catchment without any concentrations above 0 is handled correctly. (discharge_influent_csim): Replaced dummy by implementation. (discharge_effluent_csim): Replaced dummy by implementation. (risk_analysis): Use busy-cursor. (SelectTool): Use the results layer instead of the normal rivernet layer. (conc_profile_tool): improved labels for x,y axis. * Greater/Modules/catchment.py (CatchmentMap.DischargeInfluentLayer, .DischargeEffluentLayer, .CSimClassesRiverLayer, .CombinedCSimFlowLayer): New. * Greater/UI/application.py (GreaterApplication.ShowExceptionDialog): reset the mouse cursor. * Greater/UI/session.py (GreaterSession.update_map): Replace Unique Values by all values for some classficiations. Take care for classifications where no classes are created. 2003-05-13 Frank Koormann * Resources/Bitmaps/banner.png: GREAT-ER II, more prominent project URL. 2003-05-12 Jan-Oliver Wagner Completed implementation of PEC X. Various improvements for the analysis stuff. * Greater/Modules/analysis.py (calculate_river_csim_x): Completed Implementation. (compute_river_csim_x): renamed CSIMX to CSIMINTERN_X. * Greater/Modules/model.py (start_simulation): Remove results layer when simulation is succesfully finished. * Greater/Modules/catchment.py (CatchmentMap.RiverNetworkCSIMXLayer): New. * Greater/UI/application.py (GreaterApplication.CreateMainWindow): Increased default window size to 650x400. (main): Added Table menu to be visible in GREAT-ER. * GREAT-ER/Greater/UI/session.py (GreaterSession.update_map): Changed to Quantiles for CSIMINTERN_MEAN and added displaying CSIMINTERN_X. 2003-05-09 Frank Koormann * Greater/Dialogs/selectsimserver.py (SelectSimulationServerDialog.OnTestServer): Implements request 1720. Server test message print no/one/ workers. 2003-05-09 Jan-Oliver Wagner Completed implementation of Risk Analysis. * Greater/UI/session.py (GreaterSession.update_map): Added handling for risk layer. * Greater/Modules/catchment.py (CatchmentMap.RiverNetworkRiskLayer): New. * Greater/Modules/analysis.py (risk_analysis): Completed implementation. 2003-05-09 Frank Koormann * Greater/UI/application.py (main): Added /[@] as a second option for auto login (requested http://intevation.de/rt/webrt?serial_num=1748). Start the model system if one of the three auto login methods was successful. 2003-05-09 Jan-Oliver Wagner Implemented the computation part for some analysis functions. Furthermore, now the river results are displayed in a special layer. * Greater/UI/session.py (GreaterSession.update_map): Added handling to display/update the results layer for rivernetwork simulations. * Greater/Modules/results.py (Results._load_results): moved away the creation of the dictionaries now using methods to set the Tables and Dicts. (Results.SetDischargeTable, Results.SetStretchTable): New. Cover the code removed from _load_results. * Greater/Modules/analysis.py (compute_river_csim_x): New. (calculate_river_csim_x): First part implemented: Calculation of the csimx and appending it to the results. They are yet not displayed. (csim_classes_river): First part implemented. If a percentile is specified, it is now computed first. The actual classification is not performed so far. (risk_analysis): First part implemented. The risk is computed and inserted into the results. Nothing is displayed so far. * Greater/Modules/datatable.py (AppendColumn, UpdateColumn): New. (DataTable): Removed. Functionality provided by Thuban's MemoryTable. * Greater/Modules/parameterblock.py (ParameterBlock.GetValue): New. * Greater/Modules/catchment.py (Catchment._load_discharges): Fixed a bug. (CatchmentMap.RiverNetworkResultsLayer): New. 2003-05-07 Jan-Oliver Wagner Adaption to the new concept of results stored as BLOBs. Also, they are now made available to analysis function etc. as tables. Furthermore: A new show picture dialog and a bug fix. * Greater/Modules/alpha.py (show_discharge_table, show_stretch_table, show_discharge_results_table, how_stretch_results_table): Retrieve the tables directly rather than creating it on its own. * Greater/Modules/catchment.py (Catchment._construct_table): Added equation for stdev of uniform distributions. (Catchment._load_discharges): Change self._discharge_records into a local variable. (Catchment.DischargeRecords): Removed. (Catchment._load_stretch_attributes): Change self._stretch_records into a local variable. (Catchment.StretchRecords): Removed. * Greater/Modules/results.py (Results.__init__): update initialisation to use the new variables and methods. (Results.StretchRecords): Removed. (Results._create_table_from_csv_binobj): New. (Results._load_results): New. (Results.DischargeTable, Results.StretchTable, Results.DischargeDict): New. (Results._get_stretch_results, Results._get_discharge_results): Removed. * Greater/Modules/analysis.py (pec_initial, pec_catchment, mass_flux_tool, conc_profile_tool): Now uses the new table style of the results. * Greater/Dialogs/showpicture.py: Complete rework to have a more comfortable dialog that also now allows to store the picture as file. * Greater/UI/application.py (GreaterApplication.in_exception_dialog): New. (GreaterApplication.ShowExceptionDialog): Prevents automatic recursion. 2003-05-06 Frank Koormann * Greater/Modules/session.py: New temporary session management (distinguish web and desktop client sessions). Call of da_create_temp_sess() updated accordingly. In addition some code could be cleaned. (make_new_session): Temp session can be build from scratch now. (save_session): da_make_temp_sess_permanent now can differentiate between temp sess from scratch and temp sess from source session. 2003-05-05 Jan-Oliver Wagner Now the tables joined to discharges/rivernet have correct valuetypes (float, int) for columns. * Greater/Modules/catchment.py (Catchment._construct_table): New. Construct a table, ie. find out and set types and add columns for distributed parameters for a GREAT-ER record list. (Catchment._load_discharges): create _discharge_table via _construct_table (Catchment._load_stretch_attributes): create _stretch_table via _construct_table 2003-05-02 Jan-Oliver Wagner * Greater/Modules/analysis.py (add_background): Don't load all the bin-objects for the list. Collections of binary objects are now identified via identical name. This is import eg. for shapefile (shp,shx,dbf). 2003-05-02 Jan-Oliver Wagner Implement GREAT-ER Background-Layer support; a bugfix and small steps towards better layer attribute support. * Greater/Modules/analysis.py: Extend menu with "Add Background". (add_background): New. Offer all suitable background data in a dialog and then open the corresponding layers. * Greater/Modules/catchment.py (Catchment._load_discharges): create a DataTable of the discharge attributes. (Catchment.DischargeTable): New. Return table object for discharge records. (Catchment._load_stretch_attributes): create a DataTable of the stretch attributes. (Catchment.StretchTable): New. Return table object for stretches. (CatchmentMap.RiverNetworkLayer, CatchmentMap.DischargeLayer, CatchmentMap.PicturesLayer): Don't analyse non-GREATER layers. * Greater/UI/session.py (GreaterSession.update_map): Consider empty maps. Fix https://intevation.de/rt/webrt?serial_num=1839. Use the DataTable as now offered by Catchment. * Greater/UI/mainwindow.py (GreaterMainWindow.OnIdle): analysis menu now visible when there is at least a catchment (because of Add Background). 2003-04-30 Jan-Oliver Wagner Initially join attributes to some layers. * Greater/Modules/catchment.py (GreaterLayer.SetGreaterLayerType): New. (GreaterLayer.GreaterLayerType): Don't try to get the type from the filename anymore - use the new internally stored type instead. (catchment_map_from_catchment): pass on new parameter session. * Greater/UI/serialize.py (GreaterSessionHandler.__init__): added parameter session which is store under self.theSession in order to avoid loosing the current GREAT-ER session (in fact only the map is to be replaced). (GreaterSessionHandler.start_session): New. (GreaterSessionHandler.start_map): Set the GREAT-ER layer type. (parse_session): Added parameter session t be passed on. Greater/UI/session.py (GreaterSession.update_map): Now the attribute table for dicharges and stretches are joined to the corresponding layers. 2003-04-30 Frank Koormann * Resources/Bitmaps/show_pic.xpm: New, icon for picture tool. * Greater/Modules/analysis.py: Activated show_pic icon for picture tool. 2003-04-29 Jan-Oliver Wagner Implemented the Pictures-Handling. * Greater/Dialogs/showpicture.py: New. A Dialog to display a picture. * Greater/Modules/catchment.py (CatchmentMap.PicturesLayer): New. (xmldata): Split up to insert Picture layer on demand. (catchment_map_from_catchment): Added handling for PICS. * Greater/Modules/analysis.py: Added Menu entry 'Show Picture'. (SelectTool.__init__): Added optional parameter layer_name to select the right layer depending on the active tools' intention. (SelectTool.MouseUp): Get the right layer using layer_name. (start_select_tool): hand over layer_name (show_picture_tool, show_picture, show_pic_iconfile): New. * Greater/UI/context.py (context_pics_exist): New. * Greater/UI/mainwindow.py (GreaterMainWindow.OnIdle): Changed criteria for Analysis menu to appear also when there is a pictures layer. * Greater/UI/application.py (main): Show legend by default at statup. 2003-04-29 Jan-Oliver Wagner * Greater/Dialogs/selectsimserver.py (SelectSimulationServerDialog.dialog_layout): increased width of ServerURL text widget. This resolves https://intevation.de/rt/webrt?serial_num=1719 * Greater/Modules/analysis.py: Added Menu entry for "Risk Analysis", removed "Phase 3" hint from menu help texts. (risk_analysis): new 2003-04-28 Jan-Oliver Wagner * Greater/Modules/analysis.py (pec_catchment): added implementation for the PEC catchment weighted by flow increment. Also, the shapes of the corresponding river stretches that belong to this computation are selected on the map. 2003-04-25 Jan-Oliver Wagner * doc/greater-manual.tex (New Substance, Open Substance, Select Catchment): Added hint that user-defined discharges are removed as well. Fixes http://intevation.de/rt/webrt?serial_num=1710 * Greater/Dialogs/openparablock.py (OpenParameterBlockDialog.__init__): Now does not display those entries that actually don't make sense. Fixes: http://intevation.de/rt/webrt?serial_num=1712 2003-04-24 Jan-Oliver Wagner * Greater/Modules/session.py (delete_session): Removed FIXME note since the bug is not reproducable anymore. Added code for catching exceptions when a session can not be deleted due to some database inconsistencies. This is related (though not directly) to http://intevation.de/rt/webrt?serial_num=1743 * Greater/Dialogs/opensession.py (OpenSessionDialog.__init__): Now sessions where the substance or catchment is not readable are always removed from the list (Open and Delete). Also, now sessions where substance can not be deleted, are removed from the list (Delete only). This all fixes http://intevation.de/rt/webrt?serial_num=1743 2003-04-24 Frank Koormann * Greater/UI/serialize.py: Updates to changes in the Thuban.Model.load (1.20) and Thuban.Model.save (1.15) modules: (GreaterSaver): now inherits from SessionSaver (GreaterLoader): now inherits from SessionLoader (parse_session): Dropped InputSource wrapping and other stuff now implemented by SessionLoader. 2003-04-11 Jan-Oliver Wagner * Greater/UI/application.py (GreaterApplication.ShowExceptionDialog): added hint on bugtracker URL and made the dialog a scrolled one to allow copy&paste of the traceback. This fixes https://intevation.de/rt/webrt?serial_num=1781 * Greater/Modules/paratree.py (ParaTree.get_group): New. * Greater/Modules/model.py (missing_parameters): restructured composition of message string in order to sort list of parameters by block AND by group. This fixes https://intevation.de/rt/webrt?serial_num=1745 2003-04-10 Bernhard Herzog * test/support.py: Clean up which and how directories are added to sys.path so that we can run the test suite with the same environment settings as the GUI client. (add_greater_dir_to_path, add_simulwrapper_dirs_to_path) (add_greater_db_dirs_to_path): removed. (greater_support_dirs): New. Return a list of directories to add to sys.path (add_dirs_to_path): New. Add directories to sys.path. (initgreater): Update to use the new functions. * Greater/Modules/alpha.py (show_discharge_table) (show_stretch_table, show_discharge_results_table) (show_stretch_results_table): TableFrame doesn't need the interactor argument anymore. 2003-04-09 Jan-Oliver Wagner * Greater/Modules/analysis.py (pec_initial): Added info on number of discharges to the output dialog. This fixes bug #1746, https://intevation.de/rt/webrt?serial_num=1746 2003-04-08 Jan-Oliver Wagner * Greater/Modules/session.py (init_menu): renamed keyword for session_tree since due to a change in Thuban. * Greater/UI/application.py (main): now the thuban menus map and layer are added to the GREAT-ER menu as their are. 2003-04-04 Jan-Oliver Wagner * test/test_support.py (TestCanWrite.test_canwrite): Fixed test according to bug #1742. * Greater/Modules/support.py (can_write): fixed part of bug #1742, https://intevation.de/rt/webrt?serial_num=1742 * Greater/Dialogs/opensession.py (OpenSessionDialog.__init__): reduce the session list through copying, not through removing. This fixes the rest of bug #1742 * Greater/Modules/model.py (missing_parameters): Added wait-cursor which fixes bug #1750, https://intevation.de/rt/webrt?serial_num=1750 2003-04-04 Jan-Oliver Wagner * Greater/Modules/analysis.py (conc_profile_tool): Now also selects all shapes downstream on the map. 2003-04-03 Frank Koormann * Greater/UI/mainwindow.py: (GreaterMainWindow.__init__()): Changed with of second status bar field. (GreaterMainWindow.update_status_bar()): Added database name (if available) to the connection information. These changes implement feature request #1752 http://intevation.de/rt/webrt?serial_num=1752 (GreaterMainWindow.view_position_changed()): New, override the original method with a simplier formatting. This was requested by the Phase 1 test group and documented under items 2.1.5 / 2.1.6 in the test summary. 2003-03-18 Jan-Oliver Wagner * Greater/UI/application.py (GreaterApplication.CreateMainWindow): Instead of self.interactor, just apply None for convenience. See Thuban ChangeLog 2003-03-14 for more. * Greater/UI/mainwindow.py: Replaced SESSION_CHANGED by SESSION_REPLACED. See Thuban ChangeLog 2003-03-10 for more. 2003-03-07 Bernhard Herzog * Greater/version.py (longversion): Update for the final milestone 2 release 2003-03-07 Frank Koormann * doc/greater-manual.tex: Versioning fix and gui section from sciparam (sciparam-manual-gui.tex) included 2003-03-07 Frank Koormann * doc/greater-manual.tex: Added section on Mass Flux, typo fixes and formatting. Changed document date and version. * doc/screenshots/editdischargedata-dlg.eps: Updated (longest detail string in dialog) * doc/screenshots/editemissiondata-dlg.eps: Updated (longest detail string in dialog) 2003-03-06 Thomas Koester * doc/gnufdl.tex: Exclude sections from table of contents. 2003-03-06 Frank Koormann * doc/Makefile: Extended rule to generate pdf with raster images. 2003-03-06 Frank Koormann * Greater/Modules/model.py (WorkerProcess): Fixed doc strings for class methods (still mentioned server instead of worker). 2003-03-06 Thomas Koester * doc/greater-manual.tex, doc/gnufdl.tex: Updated to GNU FDL 1.2; moved \label{theverylastpage} into main document. 2003-03-05 Thomas Koester * doc/greater-manual.tex: Updated names of some screenshots, added subsection for Mass Flux and other small fixes. * doc/screenshots/calculaterivercsim-dlg.eps, doc/screenshots/concentrationprofile-dlg.eps, doc/screenshots/csimclasses-dlg.eps, doc/screenshots/missingparameters-dlg.eps, doc/screenshots/peccatchment-dlg.eps, doc/screenshots/pecinitial-dlg.eps, doc/screenshots/selectsimulationserver-dlg.eps, doc/screenshots/simulationserverfailure-dlg.eps, doc/screenshots/simulationserversuccess-dlg.eps, doc/screenshots/startsimulation-dlg.eps: Updated * doc/screenshots/selectmodel-dlg-as.eps: updated and renamed to editmodelparameters-dlg-as.eps * doc/screenshots/selectmodel-dlg-general.eps: updated and renamed to editmodelparameters-dlg-general.eps * doc/screenshots/selectmodel-dlg-river.eps: updated and renamed to editmodelparameters-dlg-river.eps * doc/screenshots/selectmodel-dlg-sewer.eps: updated and renamed to editmodelparameters-dlg-sewer.eps * doc/screenshots/selectmodel-dlg-tf.eps: updated and renamed to editmodelparameters-dlg-tf.eps * doc/screenshots/massflux-dlg.eps: Added. 2003-03-05 Bernhard Herzog * Greater/Modules/model.py (start_simulation): Put the entire loop that polls the scheduler for the status and updates the progress dialog into a try..finally to make sure that the dialog is closed when an error occurs (e.g. the scheduler is shut down). Otherwise the great-er GUI client will be blocked forever. 2003-03-05 Thomas Koester * doc/greater-manual.tex: Updated names of some screenshots, order of substance dialog pages and other small fixes. * doc/screenshots/authenticate-dlg.eps, doc/screenshots/editdischargedata-dlg.eps, doc/screenshots/editsession-dlg.eps, doc/screenshots/mainwindow.eps, doc/screenshots/openenvironment-dlg.eps, doc/screenshots/opensession-dlg.eps, doc/screenshots/opensubstance-dlg.eps, doc/screenshots/saveenvironmentas-dlg.eps, doc/screenshots/savesubstanceas-dlg.eps, doc/screenshots/selectcatchment-dlg.eps, doc/screenshots/substance-dlg-degradation.eps, doc/screenshots/substance-dlg-partitioning.eps, doc/screenshots/substance-dlg-physicochemical.eps, doc/screenshots/substance-dlg-identification.eps: Updated. * doc/screenshots/editmarketdata-dlg.eps: updated and renamed to editemissiondata-dlg.eps * doc/screenshots/substance-dlg-sewagetreatmentremoval.eps: updated and renamed to substance-dlg-wwtpremoval.eps * doc/screenshots/substance-dlg-marketinformation.eps: updated and renamed to substance-dlg-emissiondata.eps * doc/screenshots/substance-dlg-instreamremoval.eps: updated and renamed to substance-dlg-riverremoval.eps * doc/screenshots/editmodelparameters-dlg-as.eps: updated and renamed to editenvironmentparameters-dlg-as.eps * doc/screenshots/editmodelparameters-dlg-environment.eps: updated and renamed to editenvironmentparameters-dlg-environment.eps * doc/screenshots/editmodelparameters-dlg-primary.eps: updated and renamed to editenvironmentparameters-dlg-primary.eps * doc/screenshots/editmodelparameters-dlg-river.eps: updated and renamed to editenvironmentparameters-dlg-river.eps * doc/screenshots/editmodelparameters-dlg-secondary.eps: updated and renamed to editenvironmentparameters-dlg-secondary.eps * doc/screenshots/editmodelparameters-dlg-sewer.eps: updated and renamed to editenvironmentparameters-dlg-sewer.eps * doc/screenshots/editmodelparameters-dlg-wwtp.eps: updated and renamed to editenvironmentparameters-dlg-wwtp.eps 2003-03-05 Frank Koormann * doc/screenshots/peccatchment-dlg.eps: new * doc/screenshots/calculaterivercsim-dlg.eps: new * doc/screenshots/csimclasses-dlg.eps: new * doc/screenshots/concentrationprofile-dlg.eps: new * doc/screenshots/simulationserversuccess-dlg.eps: new * doc/screenshots/simulationserverfailure-dlg.eps: new * doc/greater-manual.tex (Analysis): Various updates to the subsections. (Simulation): Extended explanations for Simulation Server Test. 2003-03-04 Frank Koormann * Greater/Modules/model.py (start_simulation): Add Session basics (Name, Substance, Catchment) to the simulation progress window. 2003-03-04 Thomas Koester * Greater/UI/mainwindow.py (GreaterMainWindow.About): Use wxPython.wx.__version__ to display version of wxPython. * Greater/Modules/environment.py (new_environment): Repaired call to wxMessageDialog. * Greater/Dialogs/openparablock.py (openparameterblock_dialog, OpenParameterBlockDialog.__init__): Added parameter 'hide_none', which disables the '' substance/environment/etc. if true. * Greater/Modules/environment.py (delete_environment), Greater/Modules/substance.py (delete_substance): Added 'hide_none=1' * Greater/Dialogs/openparablock.py (OpenParameterBlockDialog.__init__): Disabled code which tried to remove non-deletable entries; see bug #1712. (OpenParameterBlockDialog.__init__, OpenParameterBlockDialog.dialog_layout): Show entry even if there are no other entries. 2003-03-03 Thomas Koester * doc/greater-testplan.tex (Parameter Dialogs): Updated for current SciParam 0.9.2pre2. 2003-02-26 Frank Koormann * Greater/Dialogs/selectsimserver.py (SelectSimulationServerDialog.OnTestServer): Added wxBeginBusyCursor/wxEndBusyCursor frame around scheduler test. 2003-02-24 Thomas Koester * Greater/Dialogs/widgets.py (ParameterCommentDialog.add_content): Create comment box after other content to fix focus order; bug #1692. 2003-02-18 Bernhard Herzog * Greater/Modules/session.py (save_session): Add wxBeginBusyCursor call because of the wxEndBusyCursor in the finally block 2003-02-18 Thomas Koester * Greater/Dialogs/csimclassesriver.py (percentile_ctrl.__init__): Use None instead of wxSize() as default parameter; fixes bug #1644. 2003-02-18 Bernhard Herzog * GREAT-ER.py: The simulwrapper is not needed anymore. Add directories with greater specific code and some selected 3rd party Python extensions to the path * Greater/Modules/model.py: Remove the obsolete import of simulwrapper modules * Greater/UI/mainwindow.py (GreaterMainWindow.__init__): Make the filename of the icon file independend of the current working directory 2003-02-17 Thomas Koester * Greater/Dialogs/editenvironment.py (editenvironment_dialog), Greater/Dialogs/selectmodel.py (selectmodel_dialog): Plural of 'parameter' is 'parameters'. * doc/greater-testplan.tex: A bunch of small fixes. 2003-02-17 Bernhard Herzog * Greater/Modules/plot.py (search_path): Make sure reportlab finds our version of times-roman even on windows. 2003-02-17 Thomas Koester * doc/greater-testplan.tex: Changed GREAT-ER CVS version to 2003-02-17; Simulation menu is always enabled now; small changes. * Greater/Dialogs/authenticate.py, Greater/Dialogs/savesessionas.py, Greater/Dialogs/saveparablockas.py, Greater/Dialogs/openparablock.py, Greater/Dialogs/selectcatchment.py, Greater/Dialogs/selectsimserver.py, Greater/Dialogs/opensession.py: from widgets import SPACE, SMALLSPACE 2003-02-17 Thomas Koester * Greater/Dialogs/selectsimserver.py (SelectSimulationServerDialog.OnTestServer): Rewritten and fixed. (SelectSimulationServerDialog.OnOK): Let OnTestServer handle dialogs. * Greater/UI/mainwindow.py: import context_results_exist; removed import context_db_open (GreaterMainWindow.__init__): Initialize variable self.prev_results_exist for OnIdle. (GreaterMainWindow.OnIdle): Enable or disable Analysis menu depending on whether results are available; fixes bug #1638. 2003-02-17 Frank Koorman * Greater/Modules/session.py: Bugfix for #1658: (session.SetSubstance): Added parameter delete_sessdisch abd call for RemoveAllSessDisch() (session._get_substance): Updated call of SetSubstance (handle delete_sessdisch equal to delete_market) 2003-02-17 Thomas Koester * Greater/Modules/model.py: removed sensitivity for select_simulation_server menu. * Greater/UI/mainwindow.py (GreaterMainWindow.__init__): Removed initialization for self.prev_db_open. (GreaterMainWindow.OnIdle): Simulation menu is always enabled now. Added workaround for wxPython 2.3.3, where GetLabelTop returns the accelerator char, too. 2003-02-17 Frank Koorman * doc/greater-testplan.tex (Session Management): Updated Menu item visibility for open session without substance and catchment. More precise on tools: This is focusing on the navigation tools. 2003-02-17 Thomas Koester * Greater/UI/mainwindow.py (GreaterMainWindow.__init__): Initialize variables self.prev_session_open and self.prev_db_open for OnIdle. (GreaterMainWindow.OnIdle): Enable or disable menus only if needed, this fixes bug #1651; Updated doc string. 2003-02-15 Jan-Oliver Wagner * Greater/Modules/environment.py (Environment.new_det): New. (Environment.da_get_det): use new_det. 2003-02-14 Thomas Koester * doc/greater-testplan.tex: Fixed various inconsistencies. * doc/greater-testplan.tex: Changed GREAT-ER CVS version to 2003-02-14; Removed \newpage. * Greater/Modules/session.py (edit_session): Set substance to None if the user selects , always set it if the user selects something else; fixes bugs #1639 and #1653. 2003-02-14 Frank Koormann * Greater/Dialogs/editenvironment.py (editenvironment_dialog): Create Dialog with two columns. * Greater/Modules/parameterblock.py (ParameterBlock._create_parameter): Added keyword 'NOFRAME' as special label for subgroups (to set the label to None as expected by SciParam. 2003-02-14 Jan-Oliver Wagner * Greater/Modules/session.py (edit_session): fixed a bug regarding setting the substance. 2003-02-14 Jan-Oliver Wagner * Greater/Modules/session.py (save_session_as): Check on existence before setting privileges. 2003-02-14 Jan-Oliver Wagner * Greater/Modules/model.py: added sensitivity for select_simulation_server * Greater/UI/mainwindow.py (GreaterMainWindow.__init__): removed initialization of self.session_menus_active. (GreaterMainWindow.OnIdle): added explicit check for Menu Simulation and removed use of self.session_menus_active. 2003-02-14 Jan-Oliver Wagner * doc/greater-testplan.tex (Environment Management): Fixed some tests. 2003-02-13 Thomas Koester * doc/greater-testplan.tex (Catchment/Discharge Management): Force having a substance. * doc/greater-testplan.tex (Catchment/Discharge Management): Use \test instead of \item. * doc/greater-testplan.tex (Simulation/Prerequisites): Select a substance instead of 'no substance'. * doc/greater-testplan.tex (Simulation): Revert previous change, but tell the user to create a new substance. * doc/greater-testplan.tex (Environment Management): Replace Boron and LAS with Summer and Winter. * Greater/Modules/analysis.py (calculate_river_csim_x, csim_classes_river): Swapped dialogs; Always destroy dialogs. 2003-02-13 Jan-Oliver Wagner * Greater/Dialogs/editsession.py (EditSessionDialog.__init__): fixed a string. * Greater/Dialogs/selectsimserver.py (SelectSimulationServerDialog.OnTestServer): put connection-to-server into a try: and return result. (SelectSimulationServerDialog.OnOK): call OnTestServer and don't finish dialog until it is sure a server can be connected. (select_simulation_server_dialog): additional parameters serverurl and useserver are now passed on to the dialog. * Greater/Modules/model.py (select_simulation_server): pass on current serverurl and useserver to the dialog. 2003-02-13 Thomas Koester * doc/greater-testplan.tex (Session Management): Added a test to check for bug #1639. * doc/greater-testplan.tex (Session Management): Use "New Session" instead of "Open Session" because there may be no saved session. * doc/greater-testplan.tex (Substance Management): Added a test for a warning dialog when trying to open a new substance while another one is already present. * Greater/Modules/environment.py (open_environment): Fixed crash documented in bug #1642. 2003-02-13 Bernhard Herzog * Greater/Modules/session.py (authenticate): Display a message in the status bar that the module system is bein started 2003-02-13 Thomas Koester * doc/greater-testplan.tex (Session Management, Parameter Dialogs): Some small fixes and additional tests. * Greater/Dialogs/editsession.py (EditSessionDialog.check_values): Strip leading/trailing whitespace from session name when determining if it may be used; use string methods instead of string module. * Greater/Dialogs/widgets.py (wxFindPrefixListBox.FindPrefix): Use string methods instead of string module, which wasn't imported. 2003-02-12 Thomas Koester * Greater/Dialogs/csimclassesriver.py (csimx_validator): Extended and renamed to percentile_validator. (percentile_validator): Renamed to percentile_row_validator; Now derived from the new percentile_validator class. (percentile_ctrl): New class. (percentile_row): Now derived from percentile_ctrl. (percentile_row.SetValue): Enable next row if current value is empty, but current control is enabled. (classes_spinner.__init__): Really use 'min' value. (csimclassesriver_dialog.__init__): Center on parent window. (csimclassesriver_dialog.classes_grid): Class 1 must be given. (csimclassesriver_dialog.csim_x_percentile): Use new percentile_ctrl. * Greater/Dialogs/csimclassesriver.py (percentile_validator.ErrorDialog): Give correct range hints. * doc/greater-testplan.tex: Updated section 'Parameter Dialogs' for current CVS and database status. 2003-02-12 Bernhard Herzog * Greater/Dialogs/selectsimserver.py (SelectSimulationServerDialog.OnTestServer): Use the corrent RPC method name and the correct key for in the result dict. * Greater/Modules/model.py (select_simulation_server): Use SimulationServerConnection to get the current connection not SetSimulationServerConnection 2003-02-12 Frank Koormann * doc/greater-testplan.tex (Substance Management): Added 'Save As' item to test cases. 2003-02-11 Thomas Koester * Greater/Dialogs/csimclassesriver.py (classes_spinner): New class. (percentile_row.SetValue): Save current last percentile control. (percentile_row.Enable): The last percentile control is always enabled with a value of 100. (csimclassesriver_dialog.classes_grid): Add classes_spinner. (csimclassesriver_dialog.__init__): Center button box. (csimclassesriver_dialog.add_content): Add csim_x_percentile. (csimclassesriver_dialog.csim_x_percentile): New method. (csimx_validator): New class. (csimclassesriver_dialog.csim_x_percentile): Added radio buttons and text control. (csimclassesriver_dialog.OnRadioButton): New method. 2003-02-11 Jan-Oliver Wagner * doc/greater-testplan.tex: updated according to improvements for milestone 2. * Greater/Modules/session.py (SimulationSession.__init__): initialize variable RiverCSimClasses. * Greater/Modules/analysis.py (calculate_river_csim_x): call the dialog. (csim_classes_river): call the dialog. 2003-02-11 Thomas Koester * Greater/Dialogs/csimclassesriver.py (csimclassesriver_dialog): Updated class doc string. (percentile_row.__init__): Use SetMaxLength method if available. (percentile_row.SetValue): Update current row status, too, by calling SetValue on the previous row. 2003-02-11 Bernhard Herzog * Greater/UI/splashscreen.py: New module implementing the GREAT-ER splash screen * Greater/UI/application.py (GreaterApplication.ResourceDir): New method to return the resource directory (GreaterApplication.splash_screen): Override inherited method to display a splash screen 2003-02-11 Thomas Koester * Greater/Dialogs/csimclassesriver.py: New file. * Greater/Dialogs/csimclassesriver.py (percentile_validator.OnChar): Take text selections into account when calculating new number. (percentile_row.__init__): Connect events to methods OnSetFocus, OnKillFocus and OnLeftDown. (percentile_row.OnKillFocus, percentile_row.OnSetFocus, percentile_row.OnLeftDown): New methods. 2003-02-11 Jan-Oliver Wagner * Greater/Modules/analysis.py: fix toolbar. (mass_flux_tool): use wxScrolledMessageDialog instead of wxMessageDialog. (mass_flux_iconfile): New. 2003-02-11 Bernhard Herzog * Greater/Modules/analysis.py (init_menu): Explicitly insert the analysis menu after the simulation menu * Greater/UI/application.py (main): Change the order in which the modules are imported so that analysis is last. 2003-02-11 Frank Koormann * Resources/Bitmaps/banner.png: New, image for the splash screen. 2003-02-10 Frank Koormann * Resources/Bitmaps/mass_flux.xpm: New, icon for mass flux analysis tool. 2003-02-10 Frank Koormann * Greater/Modules/model.py (start_simulation): More flexible implementation of progress finalization. 2003-02-10 Jan-Oliver Wagner * Greater/Modules/analysis.py: Added massflux tool and menu entry (mass_flux_tool, mass_flux): New. 2003-02-10 Jan-Oliver Wagner * GREAT-ER/Greater/Modules/analysis.py (conc_profile_tool): now checks whether the concentration profile is a flatline and if so no plotting is performed. 2003-02-10 Jan-Oliver Wagner * Greater/Modules/analysis.py (conc_profile_tool): fixed bug #1588 2003-02-10 Jan-Oliver Wagner * Greater/Modules/model.py (start_simulation): Apply message dialogs for the cases when the simulation ends with an error or was stopped. 2003-02-10 Jan-Oliver Wagner * Greater/Dialogs/editsession.py: import styleguide definitions * Greater/Dialogs/selectcsimx.py: New. (Csim X dialog) * Greater/Modules/analysis.py: fixed various string to inform on what comes in Phase 3. (calculate_river_csim_x): call the corresponding dialog. 2003-02-07 Jan-Oliver Wagner * Greater/Modules/paratree.py (ParaTree.get_field): return None if the requested record is not found. * Greater/Modules/parameterblock.py (ParameterBlock._full_initialization): safety check whether a parameter has a corresponding parameter definition. 2003-02-07 Jan-Oliver Wagner * Greater/Modules/model.py (start_simulation): status may never reach the defined maximum. Explicitely give feedback on completion of a single task. * Greater/Modules/analysis.py: changed a string 2003-02-07 Thomas Koester * Greater/Dialogs/editenvironment.py, Greater/Dialogs/editsubstance.py, Greater/Dialogs/selectmodel.py, Greater/Dialogs/widgets.py: ParameterDialog and ParameterNotebookDialog are now imported from SciParam.UI instead of SciParam. 2003-02-07 Jan-Oliver Wagner * Greater/Modules/parameterblock.py (ParameterBlock._create_parameters): for newly created detail records, use dfault value to set the value! * Greater/Modules/parameter.py (CreateParameter): fixed some strings * Greater/Modules/model.py (Model.new_det): New. (Model.da_get_det): use new_det. 2003-02-07 Jan-Oliver Wagner * Greater/Modules/plot.py (Profile): increased size of drawing. * Greater/Modules/analysis.py (conc_profile_tool): Apply River Factor and add the most downstream point. 2003-02-07 Frank Koormann * Greater/Modules/results.py (Results): Added river_factor to wrapped fields. * Greater/Modules/analysis.py (pec_initial, pec_catchment): Apply river factor on results. 2003-02-07 Jan-Oliver Wagner * Greater/Modules/session.py (save_session_as): bug fix (#1583) 2003-02-07 Jan-Oliver Wagner * Resources/Fonts/: New. * Resources/Fonts/n021003l.pfb: New. (font for reportlab) * Greater/Dialogs/profile.py: New. (profile visualization dialog) * Greater/Modules/plot.py: New. (plot functions using reportlab) * Greater/Modules/session.py (edit_session): small bugfix. * Greater/Modules/analysis.py (pec_initial): apply wxScrolledMessageDialog instead of wxMessageDialog. (pec_catchment): replaced dummy by implementation. (conc_profile_tool): finalized implementation. 2003-02-04 Thomas Koester * Greater/Modules/parameter.py (Parameter.Sync): Updated to handle new-style DistParam objects. 2003-02-04 Jan-Oliver Wagner * Greater/Modules/catchment.py (CatchmentMap.RiverNetworkLayer): New. * Greater/Modules/analysis.py: added tool registration. (SelectTool, start_select_tool, conc_profile_tool): New. (concentration_profile): now starts the corresponding tool. 2003-01-31 Frank Koormann * Resources/Bitmaps/concentration_profile.xpm: New tool button image. 2003-02-04 Jan-Oliver Wagner * Greater/Modules/marketdata.py (MarketData): Added wrapped field Privileges. * Greater/Modules/sessiondischarge.py (SessionDischarge): Added wrapped field Privileges. * Greater/Modules/discharge.py (Discharge.SetPrivileges): New. * Greater/Modules/session.py (SimulationSession.SetCatchment): set privileges for all discharges to the ones of the session. (SimulationSession.SetSubstance): Don't remove session discharges. (save_session_as): set privileges for all discharges to the ones of the session. 2003-02-04 Jan-Oliver Wagner * Greater/Modules/support.py: New. * test/test_support.py: New. * /Greater/Dialogs/opensession.py (OpenSessionDialog.__init__, run_opensession_dialog): additional optional parameter to specify the caller user in order to only display the entries the user can overwrite. * /Greater/Dialogs/openparablock.py (OpenParameterBlockDialog.__init__, openparameterblock_dialog): additional optional parameter to specify the caller user in order to only display the entries the user can overwrite. * /Greater/Modules/environment.py (delete_environment): call dialog with the current user name (to not display undeletable entries). * /Greater/Modules/substance.py (delete_substance): call dialog with the current user name (to not display undeletable entries). * /Greater/Modules/session.py (delete_session): call dialog with the current user name (to not display undeletable entries). * Greater/UI/mainwindow.py (GreaterMainWindow.About): Added correct term for the License of GREAT-ER. 2003-01-31 Frank Koormann * doc/greater-testplan.tex: Check title/tool/status bar Keyboard navigation Result management while changing substance/catchment data Change "Market" with "Emission" 2003-01-31 Jan-Oliver Wagner * doc/missing.eps: New. Use it a placeholder for not yet made screenshots. * doc/[missing.eps, missingparameters-dlg.eps, openenvironment-dlg.eps, pecinitial-dlg.eps, saveenvironmentas-dlg.eps, savesubstanceas-dlg.eps, selectsimulationserver-dlg.eps, startsimulation-dlg.eps]: New. (all copies if missing.eps so far). * doc/greater-manual.tex: Major update for milestone 2. Further work need. 2003-01-31 Frank Koormann * Greater/Modules/model.py (SimulationServerConnection.reconnect): Wrapp the startup/connecting with a busy cursor. 2003-01-30 Jan-Oliver Wagner * Greater/Modules/substance.py (new_substance, open_substance): altered message strings * Greater/Modules/environment.py (new_environment, open_environment): altered message strings * Greater/Dialogs/openparablock.py (OpenParameterBlockDialog.__init__): sort entries by name. * Greater/Dialogs/opensession.py (OpenSessionDialog.__init__): sort entries by name. * Greater/Dialogs/selectcatchment.py (SelectCatchmentDialog.__init__): sort entries by name. * Greater/Dialogs/editsession.py (EditSessionDialog.__init__): sort entries by name. 2003-01-30 Frank Koormann * Resources/greater2.xpm: New, GREAT-ER icon, XPM version * Resources/greater2.ico: New, GREAT-ER icon, Windows Iconfile version * Greater/UI/mainwindow.py (GreaterMainWindow.__init__): Set GREAT-ER icon for mainwindow. 2003-01-30 Bernhard Herzog * Greater/Modules/model.py (SchedulerProcess.__init__) (SchedulerProcess.start, SchedulerProcess.wait_for_message) (SchedulerProcess.stop, SchedulerProcess.stop) (WorkerProcess.__init__, WorkerProcess.start, WorkerProcess.stop): Use wxProcess and wxExecute instead of the functions in Python's os module. This works better in the windows GUI client. (SimulationServerConnection.reconnect): Use the wait_for_worker method to wait until the worker has connected to the scheduler. Simply sleeping is too unreliable esp. on Windows. 2003-01-30 Jan-Oliver Wagner * Greater/Modules/substance.py (new_substance): handle a cancelled new_substance dialog. (edit_substance): return whether dialog was cancelled. * Greater/Modules/environment.py (new_environment): handle a cancelled new_environment dialog. (edit_environment): return whether dialog was cancelled. 2003-01-30 Jan-Oliver Wagner * Greater/Dialogs/widgets.py (PrivilegesBox.OnCheckBox): no clicking a checkbox will activate/deactivate dependent checkboxes automatically instead of disallowing to check. 2003-01-30 Jan-Oliver Wagner * Greater/UI/mainwindow.py (GreaterMainWindow.SaveSession): just save the session, don't reopen it. * Greater/Modules/session.py (save_session, save_session_as): Added parameter to specifiy whether the just saved session is reloaded immediately. 2003-01-30 Jan-Oliver Wagner * Greater/Dialogs/editsubstance.py (editsubstance_dialog): removed ugly hack for 'notunknown' setting. * Greater/Modules/substance.py (Substance.SyncName, Substance.NameNotUnknown): New. (edit_substance, save_substance_as): Use the new methods. 2003-01-29 Jan-Oliver Wagner * Greater/Modules/parameter.py (Parameter.Sync): don't try to sync if parameter is None. (Fixes bug #1553). 2003-01-29 Jan-Oliver Wagner * Greater/Modules/session.py (save_session): extended message sting. (save_session_as): bugfix: now setting privileges correctly. 2003-01-29 Jan-Oliver Wagner * Greater/Modules/phrasetabcache.py: New. * Greater/Modules/parameter.py: Use phrasetabcache. 2003-01-29 Jan-Oliver Wagner * Greater/Modules/session.py (SimulationSession._get_substance, SimulationSession._get_model, SimulationSession._get_environment): Explicitely do not delete Results, SessDisch or Market. (SimulationSession.SetSubstance, SimulationSession.SetEnvironemnt, SimulationSession.SetModel): Additional and changed parameters no allow to specify which dependent parts should not be removed. * Greater/Modules/environment.py (save_environment_as): adapted call parameter. * Greater/Modules/substance.py (save_substance_as): adapted call parameter. 2003-01-29 Jan-Oliver Wagner * Greater/UI/mainwindow.py (GreaterMainWindow.SaveSession): call save_session_as if save_session fails. * Greater/Modules/session.py (new_session): don't proceed if session can not be saved. (open_session): don't proceed if session can not be saved. (save_session): handle possibility that session can not be saved. (close_session): don't proceed if session can not be saved. 2003-01-29 Frank Koormann * Greater/Modules/model.py (SchedulerProcess.start): removed cmdline test-port parameter (WorkerProcess.start): removed cmdline test-port parameter. (start_simulation): Changed progess display to three sequential runs. 2003-01-29 Jan-Oliver Wagner * Greater/Modules/session.py (authenticate): put da_cleanup_temp_sess into a try:. * Greater/Modules/results.py (Results._get_stretch_results): removed superflous debug print. * /Greater/Modules/model.py: disabled menu item Stop Simulation. (SchedulerProcess, WorkerProcess): updated from GREAT-ERModel/test/support.py. (SimulationServerConnection.reconnect): added use of port scan feature. (start_simulation): Added a progress dialog with Cancel-option. * Greater/Dialogs/authenticate.py: removed superflous import. * Greater/UI/mainwindow.py (GreaterMainWindow.OnClose): put da_cleanup_temp_sess into a try:. * test/test_parameterblock.py (TestParameterBlock.setUp): modified data to create a more realistic situation. 2003-01-27 Thomas Koester * Greater/UI/mainwindow.py (GreaterMainWindow.About): Updated copyright notice. 2003-01-27 Thomas Koester * Greater/Dialogs/editenvironment.py (test_editenvironment_dialog), Greater/Dialogs/editsubstance.py (test_editsubstance_dialog), Greater/Dialogs/selectmodel.py (test_selectmodel_dialog): List of notebook pages now contains 2-tuple (name, parameterlist) instead of lists [name, parameterlist]. SciParam always expected 2-tuples, but didn't throw an error before. * Greater/Modules/parameterblock.py (ParameterBlock._create_parameters): Append 2-tuple instead of list. 2003-01-24 Jan-Oliver Wagner * Greater/Modules/results.py (Results): added wrapped fields ID, RiverUnit, PECinitial and PECcatchment. (Results.StretchRecords, Results.StretchDict): new. (Results._get_stretch_results): now additionally builds a dictionary. * Greater/Modules/alpha.py (show_stretch_results_table): adapted to changes in Results. * Greater/Modules/analysis.py (pec_initial): Now implemented. * Greater/Modules/discharge.py (Discharge): added wrapped fields ID and StretchID. * Greater/Modules/model.py (start_simulation): removed temporary debug output and fixed a bug. 2003-01-24 Jan-Oliver Wagner * GREAT-ER/Greater/Modules/model.py (missing_parameters): Added da_db_commit. (start_simulation): exchanged call of wrapped old simulator by (a yet very simple) call of Simulation Scheduler. 2003-01-24 Jan-Oliver Wagner * Greater/Modules/session.py (authenticate): bugfix: don't start a Simulation Scheduler if there already is one. (SimulationSession.SetSubstance SetModel, SetEnvironment): bugfix: make sure the object is fully initialized. (edit_session): bugfix: set substance correctly. 2003-01-24 Jan-Oliver Wagner * Greater/Modules/model.py (WorkerProcess.__init__): use another test_port (this fixes a bug). 2003-01-24 Jan-Oliver Wagner * Greater/Modules/session.py (open_session): fixed a bug. 2003-01-24 Jan-Oliver Wagner * test/test_parameter.py (TestFormatOfValues.setUp): some code and hints for future changes. * test/test_parameterblock.py: New. * Greater/Modules/parameter.py (Parameter.UnsetRequired): only unset if parameter is not None. (CreateParameter): handle var_type STARTSUBGROUP and ENDSUBGROUP. * Greater/Modules/parameterblock.py (ParameterBlock.new_det): New. (ParameterBlock._create_parameters): creation of SciParams not based on the found detail records any more. Instead the paratree information is used and if no corresponding detail is found, an empty entry is created. Furthermore, the var_type STARTSUBGROUP and ENDSUBGROUP is used to construct subgroups as required by the SciParam Dialogs. * Greater/Modules/substance.py (Substance.new_det): New. (Substance.da_get_det): Use new_det. 2003-01-23 Thomas Koester * Greater/Dialogs/editsubstance.py (test_editsubstance_dialog): Don't use COLUMN_BREAK, because it will be broken in SciParam. 2003-01-22 Jan-Oliver Wagner * test/test_substance.py (mock_simserver, mock_dbconnection): new. (mock_context): use the above mock classes. * Greater/UI/mainwindow.py (GreaterMainWindow.OnClose): added shutdown of a locally running simulation Scheduler. * /Greater/UI/session.py (GreaterSession.__init__): initialize self.simserver_connection. (GreaterSession.SimulationServerConnection): new (GreaterSession.SetSimulationServerConnection): new (GreaterSession.TreeInfo): added the simserver_connection. * Greater/Dialogs/authenticate.py (AuthenticateDialog.EvtListBoxDClick): removed this obsolete method. * Greater/Dialogs/selectsimserver.py: new * Greater/Modules/parameter.py (Parameter.SetRequired, Parameter.UnsetRequired): new (CreateParameter): fixed bug in error message dialog. * Greater/Modules/parameterblock.py (ParameterBlock.SetRequired, ParameterBlock.UnsetRequiredForAll): new * Greater/Modules/environment.py (new_environment): sync to db, commit and sync required parameters before launching the dialog with the new data. (open_environment): sync to db, commit and sync required parameters after setting the new environment. (save_environment_as): sync required parameters after reloading the environment. * Greater/Modules/substance.py: two new menu items, one for setting the simulation server and one for getting an overview on the currently missing parameters. (new_substance): sync to db, commit and sync required parameters before launching the dialog with the new data. (open_substance): sync to db, commit and sync required parameters after setting the new substance. (save_substance_as): sync required parameters after reloading the substance. * Greater/Modules/session.py (authenticate): establish a connection to a SimulationServer immediately after establishing the database connection (this will launch a Simulation Scheduler and Worker locally). (SimulationSession.RequiredParametersSync): new (new_session): sync DB and required parameters after creating the new session. (open_session): sync DB and required parameters after opening a session. (edit_session): removed obsolete code, sync DB and required parameters after editing a session. (save_session_as): sync required parameters after reloading the session. * Greater/Modules/model.py (SchedulerProcess, WorkerProcess): new (SimulationServerConnection): new (select_modelchain): sync db and missing parameters after the model parameters have been edited. (missing_parameters): new (start_simulation): call missing_parameters to test whether simulation can be performed. (select_simulation_server): new 2003-01-22 Frank Koormann * doc/greater-manual.tex: Altered "Market" to "Emission" Added hint that in case of "unknown" local values the general values are applied for a simulation. 2003-01-16 Jan-Oliver Wagner * Greater/Dialogs/authenticate.py: now uses mockdb instead of stub_interface. (AuthenticateDialog.OnOK): removed code for cleanup of temporary session. * Greater/Modules/session.py (authenticate): no cleans up temporary sessions. 2003-01-16 Jan-Oliver Wagner * test/test_simulationsession.py: new. * Greater/UI/mainwindow.py (GreaterMainWindow.update_title): fixed typo (resolving bug #1521). * Greater/Modules/session.py (make_new_session): substance set to None if None (resolving bug #1520). 2003-01-16 Jan-Oliver Wagner * test/test_substance.py (TestSubstanceMainFunctions.test_delete): new * Greater/Modules/substance.py (delete_substance): added test and message dialog for unauthorized delete. * Greater/Modules/environment.py (delete_environment): added test and message dialog for unauthorized delete. 2003-01-16 Jan-Oliver Wagner * Greater/Dialogs/editsession.py: added da_db_connect execution for test. * Greater/Dialogs/openparablock.py: added da_db_connect execution for test. (OpenParameterBlockDialog.__init__): added check for no objects in db. (openparameterblock_dialog): added check for dialog failure due to no objects found in db. * Greater/Dialogs/opensession.py: added da_db_connect execution for test. (_test): adapted according to make_new_session. * Greater/Dialogs/savesessionas.py: added da_db_connect execution for test. * Greater/Dialogs/selectcatchment.py: adapted test from _stub_interface to mock_db. 2003-01-15 Jan-Oliver Wagner * test/test_substance.py: new. * Greater/Modules/substance.py (save_substance_as): generalized so its action could even be executed without raising a dialog. Also fixed a bug (now a copy of the substance is forced). * Greater/Modules/environment.py (save_environment_as): generalized so its action could even be executed without raising a dialog. Also fixed a bug (now a copy of the environment is forced). 2003-01-14 Jan-Oliver Wagner * Greater/Dialogs/editenvironment.py: new. Former editmodelparameter.py. * Greater/Dialogs/editmodelparameter.py: deleted. * Greater/Dialogs/saveparablockas.py: new. generalized version of savesubstanceas. * Greater/Dialogs/savesubstanceas.py: deleted. replaced by saveparabockas. * Greater/UI/context.py (context_environment_open): new. * Greater/UI/application.py (main): added menu 'environment'. * Greater/Modules/substance.py (Substance.__init__): Further parameters user_id and privs (used for creating a new record if None given). Before it was necessary to already have an adequate record. (Substance.DBSync): now explicitely sets the subst_id for each parameter before stored to the db. (Substance.sciparam_parameters): removed (moved to ParameterBlock). (Substance.da_get_det): Now creates new details if None found. (new_substance): Removed all the parameter creation. Now instantiating a Substance is basically all that needs to be done. (open_substance, delete_substance): dummy record is not created here any more (it is created instantiating Substance with no record given). * Greater/Modules/environment.py: new. Analog to substance.py. Parts moved from model.py. * Greater/Modules/model.py: generalized the Model class to be analog to Environment. Moved any Environment-related stuff to environment.py. * Greater/Modules/catchment.py (Catchment): Added ID() wrapping the catchment records' ID. * Greater/Modules/parameterblock.py (ParameterBlock._full_initialization): Use the wxBusyCursor since some operation may take some time. * Greater/Modules/session.py (SimulationSession): Added wrapped fields ID, Privileges and UserID. (SimulationSession.SetSubstance, .SetModel, .SetEnvironement): Now sets UserID and Privileges to the ones of the session. Now it deletes the previous substance from the database unless this default is changed through the new optional parameter 'delete'. (SimulationSession.Substance, .Model, .Environement, .Results): Now creates attribute and sets it to None if the corresponding attribute did not exists be then. (new_session): added a da_db_commit for this operation. 2003-01-13 Thomas Koester * Greater/Modules/parameter.py: Get distribution names from SciParam. * Greater/Modules/parameter.py: Replaced deprecated string.atoi() calls with int(). Removed trailing spaces. * ChangeLog: Cleanup of tabs and spaces. 2003-01-09 Jan-Oliver Wagner * Greater/Modules/session.py (SimulationSession.SetSubstance, SimulationSession.SetModel, SimulationSession.SetEnvironment): replace direct access by ID(). (new_session, make_new_session): Now setting the privileges (was missing). * Greater/Modules/substance.py: replaced use of opensubstance_dialog by more generalized openparameterblock_dialog. Changes in various methods accordingly done. (Substance.da_get): new * Greater/Dialogs/openparablock.py: new. Generalized version of former opensubstance.py. * Greater/Dialogs/opensubstance.py: removed. replaced by openparablock.py. 2003-01-09 Jan-Oliver Wagner * Greater/Modules/model.py (Model): renamed wrapped field ModelID to ID. (Model.__init__): Call __init__ of ParameterBlock without det records. (Model._new_detail_records): moved code into Model.da_get_det. (Model.TreeInfo): rephrased code (eg. use wrapped functions). (Model.DBSync): rephrased code (eg. use wrapped functions). (Model.da_get_det): new (Environement): renamed wrapped field ModelID to ID. (Environement.__init__): Call __init__ of ParameterBlock without det records. (Environement._new_detail_records): moved code into Environement.da_get_det. (Environement.TreeInfo): rephrased code (eg. use wrapped functions). (Environement.DBSync): rephrased code (eg. use wrapped functions). (Environement.da_get_det): new (select_modelchain, edit_environmentparameter): use function to access sciparams. (init_menu): moved menu item for model parameters from model to simulation; renamed model to environment. * Greater/Modules/parameterblock.py (ParameterBlock): added wrapped fields. (ParameterBlock.__init__): removed parameter detail_records. init now does not create parameters, but just sets flag that it is not yet fully initialized. (ParameterBlock.TreeInfo, ParameterBlock.Sync): will fully initialize the record if not yet done. (ParameterBlock.ParamGroups, ParameterBlock.SciParams): new. wrap corresponding variables. (ParameterBlock.da_get_det): new. must be overloaded. (ParameterBlock._full_initialization): new. (ParameterBlock._create_parameters): prefixed private varibals with a _. * Greater/Modules/results.py (Results): added wrapped field ID and use it (and Comment) in various methods. * Greater/Modules/session.py (SimulationSession.DBSync): added use of ID. Substance and Results ID is now also updated. * Greater/Modules/substance.py: removed some now unnecessary imports. Replaced various component access with access via methods. Replaced da_insert* methods by .Insert() (Substance): moved some wrapped fields to ParameterBlock. (Substance.__init__): Call __init__ of ParameterBlock without det records. Moved det records copying to ParameterBlock. (Substance.da_get_det): new. 2003-01-05 Jan-Oliver Wagner * Greater/Modules/substance.py (Substance): Added wrapped_fields. (Substance.TreeInfo): Using wrapper function instead of direct access. (open_substance): Dialog execution funtion has a new name and a further parameter (the title). (save_substance_as): new (delete_substance): new Added these two funtions to the menu. * Greater/Dialogs/opensubstance.py (OpenSubstanceDialog.__init__): New parameter title. (run_opensubstance_dialog): renamed to opensubstance_dialog and additional parameter title. Return value changed: now only returns the recored, not a list with this one record as before. * Greater/Dialogs/savesubstanceas.py: new 2003-01-02 Jan-Oliver Wagner * Greater/Modules/substance.py (Substance.TreeInfo): fixed a datatype bug 2003-01-02 Jan-Oliver Wagner * Greater/Modules/substance.py (Substance.TreeInfo): Added is_templ to tree. * Greater/Modules/editsession.py: removed unused path extension for unit test. * Greater/Modules/savesessionas.py: removed unused path extension for unit test. * Greater/Modules/opensession.py: removed unused path extension for unit test. * Greater/Modules/opensubstance.py: added mock db contents for unit test. (OpenSubstanceDialog.dialog_layout): added elements for user, group and privileges. (OpenSubstanceDialog.EvtListBox): added handling for new elements. 2002-12-20 Frank Koormann * test/mock_db.py: Removed. Actually the mock_db is moved to the Module GREAT-ER-DB: test/mock_db.py * test/support.py (add_greater_db_dirs_to_path): New method * Greater/Dialogs/editsession.py (run_session_dialog): Set privs=1 in definition. Otherwise test fails. Adaptions to new location of Mock_DB. * Greater/Dialogs/savesessionas.py, Greater/Dialogs/opensession.py: Adaptions to new location of Mock_DB. 2002-12-20 Frank Koormann * test/mock_db.py: (da_db_connect), (da_get_mod) (da_insert_mod_det), (da_get_mod_det): New 2002-12-20 Jan-Oliver Wagner * Greater/Dialogs/editsession.py: Added test users and groups (EditSessionDialog.__init__): Added parameter 'privs'. (EditSessionDialog.dialog_layout): Added Privieleges box. (EditSessionDialog.OnOK): Added privs as return parameter. * Greater/Dialogs/savesessionas.py: Added test users and groups (SaveSessionAsDialog.__init__): Added parameter 'privs'. (SaveSessionAsDialog.dialog_layout): Added Privieleges box. (SaveSessionAsDialog.OnOK): Added privs as return parameter. * Greater/Dialogs/widgets.py (PrivilegesBox.__init__): Added event hook. (PrivilegesBox.GetValue(), PrivilegesBox.OnCheckBox): new * Greater/UI/mainwindow.py (GreaterMainWindow.__init__): increased size of second field of status bar by 100. (Greater_MainWindow.update_status_bar): Added grouname next to username. * Greater/Modules/session.py: Added handling of privs for all relevant dialogs. (DBConnection.__init__): added retrieval and setting of self.groupname based on the user name. (DBConnection.TreeInfo): Added groupname. * test/mock_db.py (MockDB.da_insert_catch, MockDB.da_insert_subst): new 2002-12-18 Jan-Oliver Wagner * test/mock_db.py (MockDB.__init__): added user_tab and group_tab. (MockDB.da_get_user, MockDB.da_insert_user, MockDB.da_get_group, MockDB.da_insert_group): new * Greater/Dialogs/widgets.py (PrivilegesBox): new * Greater/Dialogs/opensession.py: Added test users and groups (OpenSessionDialog.dialog_layout): Added User, Group and privileges info. 2002-12-17 Jan-Oliver Wagner * test/moc_db.py: removed (renamed to mock_db.py) * test/mock_db.py: new (former moc_db.py, also renamed any moc to mock) * test/test_parameter.py: renamed any moc to mock * Greater/Dialogs/opensession.py: replaced stub_interface by mock_db. (OpenSessionDialog.__init__): fixed bug: now return when no session is found without trying to buld the dialog layout. (OpenSessionDialog.dialog_layout): fixed bugs: now tests whether no substances or no catchments are found and use "None" for such cases. (_test): make a test sessions using GREAT-ER function make_new_session. 2002-12-16 Thomas Koester * Greater/Modules/parameter.py (CreateParameter): Set maxlength=255 for StringParam objects. 2002-12-13 Thomas Koester * Greater/Dialogs/widgets.py: New variable comment_length. * Greater/Dialogs/editmodelparameter.py (editmodelparameter_dialog), Greater/Dialogs/editsubstance.py (editsubstance_dialog), Greater/Dialogs/selectmodel.py (selectmodel_dialog): Use comment_length option of ParameterDialog. * Greater/Dialogs/widgets.py (LengthValidator): Cleaned up. (EditCommentBox.__init__): Use comment_length. 2002-12-11 Jan-Oliver Wagner * test/test_parameter.py (TestFormatOfValues): new 2002-12-11 Jan-Oliver Wagner * test/moc_db.py: new * test/test_parameter.py: introduced use of moc_db * test/test_record_wrapper.py: now imports GreaterDB instead of Greater.DB. 2002-12-11 Jan-Oliver Wagner * dbapiwrapper: removed * Greater/DB: removed * setup.py: removed * setyup.cfg: removed. 2002-12-10 Jan-Oliver Wagner * Greater/Modules/session.py (SimulationSession.UpdateMarketID, SimulationSession.UpdateSessDischID): Added call of da_db_commit() * Greater/Modules/model.py (start_simulation): removed call of da_db_commit() 2002-12-10 Jan-Oliver Wagner * Greater/Modules/marketdata.py (MarketData._param_ids): new (MarketData.__init__, MarketData.TreeInfo, MarketData.Sync): dictionary _parameters and replaces parameters and parameter_dict. * Greater/Modules/sessiondischarge.py (SessionDischarge._param_ids): new (SessionDischarge.__init__, SessionDischarge.TreeInfo, SessionDischarge.Sync, SessionDischarge._create_parameters): dictionary _parameters and replaces parameters and parameter_dict. * Greater/Modules/discharge.py (Discharge._param_ids): new (Discharge.*): replace market by _market, market now is treated analog to sessiondischarge, ie. records are only created when referenced. (Discharge._new_market): new 2002-12-10 Thomas Koester * Greater/Dialogs/editsubstance.py (editsubstance_dialog): Set notunknown flag of substance name. Should be done in the database. 2002-12-09 Frank Koormann * Greater/Dialogs/editsession.py (EditSessionDialog.check_values): Check session name against 'unknown', wich isn't a valid name. 2002-12-09 Jan-Oliver Wagner * Greater/Modules/discharge.py (Discharge.RemoveMarket, Discharge.RemoveSessDisch): new * Greater/Modules/session.py (Session.RemoveAllMarket): Added removal of corresponding objects from current application. (RemoveAllSessDisch): Added removal of corresponding objects from current application. (Session.SetSubstance): Now also removes all SessDisch. Does not any more reload the discharges (what was this good for?). 2002-12-09 Bernhard Herzog * Greater/Modules/catchment.py (Command edit_dischargedata) (Command edit_marketdata): Use Thuban's new ToolCommand class 2002-12-06 Bernhard Herzog * Greater/Modules/recordwrapper.py (RecordWrapper.Session): Add a parameter to make the method return None instead of raising an error when the session can't be reached. * Greater/Modules/parameter.py (Parameter.Sync): Don't require the parameter to be bound to a session. Update the doc-string. * Greater/Modules/substance.py (sciparam_parameters): New parameter record_class so that the parameter objects can be instantiated with the correct record type (new_substance): Use the correct record classes for the parameters and the substance. 2002-12-06 Frank Koormann * Greater/Modules/session.py (RemoveAllMarket, RemoveAllSessDisch): Fixed Bug: Added catch_id as a parameter and modified according calls. 2002-12-05 Jan-Oliver Wagner * Greater/Modules/catchment.py (select_catchment): Fixed bug: Catchment is given simulation as parent now. 2002-12-05 Frank Koormann * Greater/UI/mainwindow.py (OnClose): Refixed handling of modified sessions on exit: Now all three options work. 2002-12-05 Jan-Oliver Wagner * Greater/Modules/session.py (make_new_session, edit_session): Fixed bug: Catchment is given simulation as parent now. 2002-12-05 Frank Koormann * Greater/UI/mainwindow.py (About): Reordered items in dialog. * simulwrapper/simul/io_dbapi.py (Environment): Special handling for parameter 'COMBINED_SEWER_FLOW': Default is 1.0. 2002-12-04 Thomas Koester * doc/greater-manual.tex: New section: Keyboard Shortcuts. 2002-12-04 Jan-Oliver Wagner * Greater/Modules/alpha.py (show_discharge_table): Replaced function name to get discharge records. (show_stretch_table): Replaced function name to get stretch records. * Greater/Modules/marketdata.py: new. Extracted from Greater/Modules/discharge.py. * Greater/Modules/sessiondischarge.py: new. GREAT-ER Session Discharge object. * Greater/Modules/catchment.py (Catchmnet.__init__): renamed initialization methods, added initialization of _discharges. (Catchment.TreeInfo): Replaced use of variable by method call. (Catchment.DBSync): Replaced use of variable by method call. (Catchment._get_discharges): renamed to _load_discharges. (Catchment._load_discharges): new (Catchment.Discharges): new (Catchment.DischargeRecords): new (Catchment._get_stretch_attributes): renamed to _load_stretch_attributes. (Catchment.StretchRecords): new (edit_marketdata_tool): Replaced use of variable by method call. (edit_discharge_data_tool): Replaced use of variable by method call, added call of UpdateSessDischID. * Greater/Modules/session.py (SimulationSession): Added SessDischID as wrapped field. (SimulationSession.SetCatchment): Moved cleanup code to separate methods. (SimulationSession.RemoveAllMarket): new. (SimulationSession.RemoveAllSessDisch): new. (SimulationSession.RemoveAllResults): new. (SimulationSession.UpdateSessDischID): new. (SimulationSession.SetSubstance): replaced cleanup code by method call. (open_session): Added a da_db_commit(). * Greater/Modules/discharge.py: adjusted imports. (Discharge.__init__): Added initialization of _sessdisch. (Discharge.TreeInfo): Instead of direct returning the value, the list is now build step by step. SessionDischarges are added. (Discharge.Parameters): Now returns parameters of SessionDischarge if exists. (Discharge.Sync): Now syncs also SessionDischarges. Don't copy modified values to Discharge data any more (instead make a SessionDischarge). (Discharge.DBSync): Added _sessdisch. (Discharge._init_sessdisch): new (Discharge._new_sessdisch): new (MarketData): moved to maketdata.py 2002-12-04 Frank Koormann * Greater/UI/mainwindow.py (GreaterMainWindow.OnClose): Bug #1403 fixed: Check return code of MainWindow.OnClose() to decide further actions. 2002-12-03 Thomas Koester * Greater/UI/mainwindow.py (GreaterMainWindow.About): Added version information for wxPython and Python. 2002-11-29 Frank Koormann * ./Greater/Modules/session.py (SimulationSession.DBSync, open_session, save_session, save_session_as): Added and repositioned da_db_commit() statements. (make_new_session): Added sess_disch_id to record contents. 2002-11-29 Frank Koormann * ./simulwrapper/simul/io_dbapi.py (rewriteResults): Use new da_insert_bulk_res_stretch to write simulation results to DB. 2002-11-29 Frank Koormann * ./Greater/version.py: New, GREAT-ER Client version information * ./Greater/UI/mainwindow.py (About): Added dynamic version information for GREAT-ER Client and DB API. 2002-11-28 Frank Koormann * ./Greater/UI/application.py, ./Greater/Modules/model.py, ./simulwrapper/simul/greater_simul.py, ./simulwrapper/simul/io_dbapi.py, ./Greater/UI/mainwindow.py, ./Greater/Dialogs/authenticate.py, ./Greater/Dialogs/editsession.py, ./Greater/Dialogs/opensession.py, ./Greater/Dialogs/opensubstance.py, ./Greater/Dialogs/savesessionas.py, ./Greater/Dialogs/selectcatchment.py, ./Greater/Modules/catchment.py, ./Greater/Modules/discharge.py, ./Greater/Modules/parameter.py, ./Greater/Modules/paratree.py, ./Greater/Modules/recordwrapper.py, ./Greater/Modules/results.py, ./Greater/Modules/session.py, ./Greater/Modules/substance.py, ./test/test_parameter.py: Change to modular version of API Wrapper: Update all references to old wrapper (Greater.DB) as part of Module GREAT-ER to GreaterDB. Change occurences of "_api_interface" to "_dagreater", the new name of the interface. 2002-11-28 Jan-Oliver Wagner * Greater/Modules/parameter.py (Parameter.Sync): Fixed a bug (along with float values, int values are formatted the same) 2002-11-28 Bernhard Herzog * test/test_record_wrapper.py: New test for the RecordWrapper. * Greater/Modules/recordwrapper.py (RecordWrapper.Session): Determine whether a parent is the session by looking at its is_Session attribute. This gets rid of the ugly import session in the method and removes the circular depency between session.py and recordwrapper.py * Greater/Modules/session.py (Session.is_Session): New class attribute to mark the class as the session. 2002-11-28 Jan-Oliver Wagner * Greater/Modules/parameter.py (Parameter.Sync): Fixed a bug (only float values are converted using float formatting) 2002-11-28 Jan-Oliver Wagner * Greater/Modules/discharge.py (Discharge.Sync, MarketData.Sync): Fixed a bug (Parameter instance was assumed to be a float). 2002-11-28 Frank Koormann * simulwrapper/simul/io_dbapi.py: Check for unknown values against empty string instead of the string "unknown". 2002-11-21 Jan-Oliver Wagner * Greater/Modules/parameter.py (Parameter.Sync): fixed numeric to string conversion and fixed distrib type identification. * Greater/Modules/discharge.py (Discharge.Sync): fixed numeric to string conversion. (MarketData.Sync): fixed numeric to string conversion. * test/test_parameter.py (TestFormatNumericValues.test_format_single_value): replaced finally by except. (TestFormatNumericValues.test_format_distributed_value): replaced finally by except and added test on distibution. * dbapiwrapper/apispec.py: replaced 'UNKNOWN' by new definition "%" for the C stub. 2002-11-21 Jan-Oliver Wagner * Greater/Modules/recordwrapper.py (RecordWrapper.Session): Moved import of session into this function to avoid problems from two modules importing each other (recordwrapper and session). * test/: new * test/support.py, test/runtests.py, test/test_parameter.py: new 2002-11-20 Jan-Oliver Wagner * Greater/Modules/parameter.py (CreateParameter): removed special treatment of '' for choices. 2002-11-20 Jan-Oliver Wagner * Greater/Modules/parameter.py (Parameter.TreeInfo): replaced "----properties---" separator by a sub-tree "Description". Added Subtree of Var-Type with choice list for parameters of Var-Type Pn. (Parameter.Sync): Now always set value to '' instead of 'unknown' if the parameter value is None. This is to comply with Data Model Specification 3.0, section 1.3. (CreateParameters): Don't test for 'unknown' in remarks of phrases any more. value == '' is a sufficient indicator. * Greater/Modules/discharge.py (MarketData.__init__): initialize with '' instread of 'unknown'. (MarketData.HaseUsefulData): test for '' instead of 'unknown'. * Greater/Modules/model.py (Model.__init__): replaced string "Unknown" by "Unnamed" for initializing name. (Environment.__init__): replaced string "Unknown" by "Unnamed" for initializing name. * dbapiwrapper/apispec.py: replaced 'unknown' by '' for all values. 2002-11-18 Bernhard Herzog * dbapiwrapper/genapiwrapper.py (DBFreeFunction.__init__): Call the correct base class' constructor 2002-11-08 Bernhard Herzog * dbapiwrapper/genapiwrapper.py (ListStruct.__init__) (ListStruct.set_da_free_function, ListStruct.free_function_name) (DBFreeFunction.__init__): Associate the free functions with the struct like the insert and update functions. (DBGetFunction.c_method_impl): Use the new way to determine the name of the appropriate free function * dbapiwrapper/apispec.py: Fix spelling of da_free_subst_result 2002-11-07 Bernhard Herzog * dbapiwrapper/apispec.py: Fix spelling of sess_disch_id * dbapiwrapper/genapiwrapper.py (DBInsertFunction._add_to_struct): Split the code that tells the struct about the insert function into a separate method so it can be overridden by derived classes. (DBBulkInsertFunction._add_to_struct): Override to not do anything (DBBulkInsertFunction.py_wrapper): Handle the parameter list better. 2002-11-07 Bernhard Herzog * dbapiwrapper/parse_function_proto.py (parse_prototype): Allow optional "ret_code" between return type and function name * dbapiwrapper/apispec.py: Update for API version 3.0 * dbapiwrapper/genapiwrapper.py (Struct.c_return) (Pointer.c_return): Added. (ListStruct.from_dict_impl): Fix doc string. (ListStruct.from_dict_list_name, ListStruct.from_dict_list_impl): New methods to convert lists of dicts to linked lists of structs (GreaterAPIModule.add_struct_from_dict_list): Added for the new from_dict_list functionality. (WrappedFunction.c_method_impl): Add doc-string (WrappedFunction.c_stub): Base the return value on the return type. (DBGetFunction.c_stub): Handle the case where there are only two parameters, the struct and the error code. (DBInsertFunction.__init__, DBInsertFunction.c_stub): Make the updated_field parameter optional. (DBBulkInsertFunction): New class for the bulk insert functions 2002-11-06 Frank Koormann * Greater/Modules/model.py: Fixed typo in menu items: The plural of parameter is parameters. 2002-11-06 Bernhard Herzog * Greater/Modules/session.py (SimulationSession.wrapped_fields): Add accessors for catch_id and subst_id (edit_session): Check whether the catchment/substance returned from the dialog are the same as the ones in the current session and only set them if they've actually changed. 2002-11-06 Frank Koormann * Greater/Modules/catchment.py, Greater/Dialogs/editmarketdata.py, Greater/Dialogs/editsubstance.py: Changed occurrences of "Market" in the GUI to "Emission". 2002-11-06 Bernhard Herzog * Greater/Modules/session.py (edit_session): Fix the way Catchment is instantiated. 2002-11-05 Bernhard Herzog * Greater/Modules/catchment.py (Command edit_dischargedata) (Command edit_marketdata): Be sensitive only when both a substance and a catchment are selected. * Greater/UI/context.py (context_substance_and_catchment_open): Added. * Greater/Modules/results.py (Results.ParameterChanged): Remove a debug print. 2002-11-05 Bernhard Herzog * Greater/Modules/results.py (Results.ParameterChanged): Change the implementation to deal with results where the comment field already contained changed parameters when it was read from the database. (Results.__init__): No need for changed_parameters anymore. 2002-11-04 Bernhard Herzog If there are simulation results record which input parameters of the simulation have changed since the simulation was run. * Greater/Modules/results.py (Results.__init__): Accept the parent parameter and pass it on to RecordWrapper. New instance variable changed_parameters (Results.ParameterChanged): New. Record that a parameter has changed. (Results._get_discharge_results): New. Needed because the comment field now records which parameters have changed. * Greater/Modules/session.py (SimulationSession.ParameterChanged): New. Convenience method so that the parameter objects don't have to deal with the result object themselves. (SimulationSession.DBSync): Also sync the result object as it may now contain modified informatio in its comment field. * Greater/Modules/parameter.py (Parameter.Sync): Call the session's ParameterChanged method if the value has changed. * Greater/Modules/discharge.py (Discharge.Sync, MarketData.Sync): Call the session's ParameterChanged method if a parameter actually changes. * Greater/DB/interface.py (Record.__setattr__): Call the parent's RecordModified method whenever the contents change not just when the _modified flag changes 2002-11-04 Bernhard Herzog Reform the way change notifications are passed between the classes that copmpose the SimulationSession. Instead of using the connector -- which is mostly only useful for loose coupling like between model and view -- RecordWrapper instances now tell the parent directly that they've changed. As a result most Destroy methods can be removed and parents don't have to subscribe to their children's messages anymore. Neither do they need to forwars such messages. * Greater/Modules/recordwrapper.py (RecordWrapper): No longer derived from Modifiable (RecordWrapper.__init__): No need to call base class constructor. (RecordWrapper.changed): Simply call the parent's ChildChanged method. (RecordWrapper.ChildChanged): Default implementation of ChildChanged that simply calls self.changed() which in turn notifies the parent. * Greater/Modules/session.py (SimulationSession.Destroy): Removed. (SimulationSession.__init__): Call UnsetModified because a newly instantiated session has not been modified yet by definition. (SimulationSession.rebind): Remove the (Un)subscribe calls. (SimulationSession.forward): Removed. (SimulationSession.changed): Override the Modifiable method to at least issue a CHANGED message (SimulationSession.SetSubstance): No need to call Destroy methods * Greater/Modules/catchment.py (Catchment.Destroy) (Catchment.forward): Removed. No longer needed in the new scheme. (Catchment._get_discharges): No need to call the Destroy methods (edit_marketdata_tool, edit_dischargedata_tool): Don't make explicit calls to changed. Change notifications should happen automatically now. * Greater/Modules/substance.py (edit_substance): Don't make explicit calls to changed. Change notifications should happen automatically now. * Greater/Modules/model.py (select_modelchain) (edit_environmentparameter): Don't make explicit calls to changed. Change notifications should happen automatically now. * Greater/UI/session.py (GreaterSession.Destroy): Removed. The inherited version is OK. (GreaterSession.WasModified): Override the inherited method to also consult the simulation session 2002-11-04 Bernhard Herzog * Greater/Modules/recordwrapper.py (RecordWrapper.__init__): Set the record's parent to self. (RecordWrapper.db_update): Implement the RecordModified method needed by the record. * Greater/DB/interface.py (Record.SetParent): New method to set the new isntance variable _parent. (Record.__setattr__): Call the parent's RecordModified method if the modification flag changes. * Greater/Modules/parameter.py (Parameter.__init__): Accept the parent parameter and pass it on to RecordWrapper * Greater/Modules/parametergroup.py (ParameterGroup.__init__): Accept the parent parameter and pass it on to RecordWrapper (ParameterGroup.AddParameter): New method to add a parameter to the group * Greater/Modules/parameterblock.py (ParameterBlock.__init__): Accept the parent parameter and pass it on to RecordWrapper (ParameterBlock._create_parameters): Instantiate the parameter groups with the block as parant and use the new AddParameter method to add parameters to groups * Greater/Modules/discharge.py (Discharge.Sync): Sync the model only if it's actually defined. 2002-11-01 Bernhard Herzog * Greater/Modules/catchment.py (CatchmentMap.Catchment): New method to return the catchment the map displays. * Greater/UI/session.py (GreaterSession.update_map): Rework the logic to only create a new map if the catchment actually changes. 2002-11-01 Bernhard Herzog * Greater/Modules/parameterblock.py (ParameterBlock.SetParameters): Removed because it's no longer used. * GREAT-ER.py, Greater/Modules/model.py: sys.path manipulation should not be done by a normal module so move the code that adds the simulwrapper directory to the path to GREAT-ER.py * Greater/Modules/model.py (start_simulation): use the public method to get the session id. * Greater/Modules/session.py (SimulationSession.DBSync): Use the new methods to access the ids of model and environment. (make_new_session): The logic for creating new model/environment objects is now in the Model/Environment classes. * Greater/Modules/model.py (Model.__init__): Handle instantiation of new Models here. (Model._new_detail_records): New. Helper method for instantiation of new model records. (Model.DBSync): Simplify with the new RecordWrapper methods (Model.wrapped_fields): Add method to access mod_id (Environment.__init__): Handle instantiation of new Environments here. (Environment._new_detail_records): New. Helper method for instantiation of new model records. (Environment.DBSync): Simplify with the new RecordWrapper methods (Environment.wrapped_fields): Add method to access env_id 2002-10-31 Bernhard Herzog * Greater/Modules/session.py (SimulationSession.DBSync): Use the new recordwrapper methods for the db-api calls. (make_new_session): Use the correct record classes. (new_session): Update the doc-string. 2002-10-31 Bernhard Herzog Substantial refactoring. * dbapiwrapper/genapiwrapper.py (ListStruct.__init__): Two new instance variables da_insert_function, da_update_function that contain None or the function which performs the insert/update for this record. (ListStruct.set_da_insert_function) (ListStruct.set_da_update_function): New methods to set the inert/update functions. (ListStruct.py_class_name, ListStruct.py_class_definition): New methods to return a python class definition. (DBGetFunction.py_wrapper): Instantiate the class corresponding to the struct type and use a list-comprehension to also pass the new parameter to the constructor. (DBInsertFunction.__init__): Set self as the insert function on ListStructs (DBInsertFunction.py_params): New method to return the names of the python parameters. (DBInsertFunction.py_wrapper): Use the Fields method to get the fields dictionary. (DBUpdateFunction.__init__): Override the inherited method to set the update function on ListStructs (DBUpdateFunction.py_wrapper): Use the Fields method to get the fields dictionary. (format_py_module): Import Record instead of defining it. Create the classes for the ListStructs (DBInsertFunction.c_stub): Remove unused variable. * Greater/DB/interface.py (Record): New class to be used in pyinterface instead of the pyinterface.Record. The new class can keep track of whether the values of the records were changed and provides a better interface to access the fields. (set_api_interface): Add doc-string. * Greater/Modules/recordwrapper.py (RecordWrapper.__init__): New optional parameter parent. (RecordWrapper.SetParent): New method to set the parent. (RecordWrapper.Session, RecordWrapper.SessionID): New methods to return the session/sess_id. These methods use the parent to track down the session object the wrapper belongs to. (RecordWrapper.to_db, RecordWrapper.db_insert) (RecordWrapper.db_update): Convenience methods to update or insert the record in the database. to_db uses the record's IsNew and WasModified methods to be smart about this. * Greater/Modules/discharge.py (Discharge.__init__): No need to pass the sess_id and market_id anymore now that we have the parent argument. (Discharge.TreeInfo): Make sure the market data is initialized. (MarketData): New class for the market data. (Discharge._create_parameters, Discharge._init_market): Split the market data initialization into _init_market which in turn delegates a lot to MarketData. (Discharge.Market): New method to return the market. (Discharge.Parameters): New method to return the discharge parameters (Discharge.Sync): Delegate syncing of the market data to the market object (Discharge.DBSync): Most of the logic is now in the MarketData class and RecordWrapper (Discharge.MarketComment, Discharge.SetMarketComment): Removed. Access these via Market() now. (Discharge.HasMarketInformation): Essentially moved to MarketData.HasUsefulData * Greater/Modules/catchment.py (Catchment.__init__): No need to pass the sess_id and market_id anymore now that we have the parent argument. (Catchment.DBSync): Don't assign the sess_id and market_id to the discharges as they can get that informatin themselves throught the parents. (Catchment._get_discharges): Adjust to new constructor signature of Discharge (select_catchment): Instantiate the Catchment without the session information at first. It will be automatically set by SetCatchment. (edit_marketdata_tool): Use new way to access the discharge's market. (edit_dischargedata_tool): Use new way to get the parameter objects * Greater/Modules/session.py (SimulationSession.wrapped_fields): Provide accessor for market_id (SimulationSession.rebind): Extend to set the parent of RecordWrapper instances (make_new_session, SimulationSession._get_catchment): Adjust to new constructor signature of Catchment. (SimulationSession.SessionID): Override inherited method. * Greater/Modules/substance.py: Remove unused imports. (Substance.DBSync): Simplify by using the new record wrapper methods. * Greater/Modules/datatable.py (DataTable.__init__) (DataTable.read_record): Use the record's Fields method to get the fields dict. 2002-10-28 Bernhard Herzog * Greater/Modules/recordwrapper.py (RecordWrapper.__init__): Add an assertion to check whether the record is not None. * Greater/Modules/parameterblock.py (ParameterBlock.TreeInfo) (ParameterBlock._create_parameters): Remove special case for record being None. (ParameterBlock.TreeInfo): Radical simplification. * Greater/Modules/session.py (SimulationSession._get_environment): A non-existing environment object is indicated by None not an Environment instance with a None record. * Greater/Modules/model.py (Model.__init__): Remove special case for record being None. Update doc-string. (Model.TreeInfo, Model.DBSync): Remove special case for record being None. (Environment.__init__): Remove special case for record being None. Update doc-string. (Environment.TreeInfo, Environment.DBSync): Remove special case for record being None. * Greater/Modules/catchment.py (Catchment.TreeInfo) (Catchment._get_discharges, Catchment._get_stretch_attributes): Remove special case for record being None. * Greater/Modules/substance.py (Substance.__init__): Remove special case for record being None. Update the doc-string. (Substance.TreeInfo): Remove special case for record being None. Add doc-string. (Substance.DBSync): Remove special case for record being None. 2002-10-25 Bernhard Herzog A SimulationSession's environment or model paramters may be None now to indicate that they are not set yet. Before the environment or model's record was set to None in this case. * Greater/Modules/session.py (SimulationSession.Destroy) (SimulationSession._get_model, SimulationSession.SetModel) (SimulationSession._get_environment) (SimulationSession.SetEnvironment, SimulationSession.TreeInfo): Handle the new way of representing empty model or environment parameters. (SimulationSession.TreeInfo): Append strings to items for the children which are None. * Greater/Modules/model.py (select_modelchain) (edit_environmentparameter): Access the model object through the Model method. Add doc-string. 2002-10-25 Bernhard Herzog A SimulationSession's result may be None now to indicate that no result is associated with the session. Before the result's record was set to None in this case. * Greater/Modules/session.py (SimulationSession.Destroy) (SimulationSession.SetCatchment, SimulationSession._get_results) (SimulationSession.SetResults, SimulationSession.TreeInfo) (make_new_session): Handle the new way of representing no results. (SimulationSession.Results): Add doc-string * Greater/UI/context.py (context_results_exist): Handle the new way of representing no results. 2002-10-25 Bernhard Herzog A SimulationSession's substance may be None now to indicate that no substance is associated with the session. Before the substance's record was set to None in this case. * Greater/Modules/session.py (SimulationSession.Destroy) (SimulationSession.TreeInfo, SimulationSession.DBSync): Deal with the new substance being None. (SimulationSession.SubstanceRecord): New method to return the actual database record of the substance. (SimulationSession._get_substance, make_new_session): If the session has not substance set it to None. (SimulationSession.SetSubstance): Allow new value to be None. (SimulationSession.Substance): Add doc-string (edit_session): Use the new SubstanceRecord method. Handle no substance according to the new scheme. (save_session_as): Use the new SubstanceRecord method. * Greater/Modules/substance.py (new_substance, open_substance): Deal with the new scheme of representing no substance. (edit_substance): Add doc-string. * Greater/UI/mainwindow.py (GreaterMainWindow.update_title): Deal with the new scheme of representing no substance. * Greater/UI/context.py (context_substance_open): Deal with the new scheme of representing no substance. 2002-10-25 Bernhard Herzog A SimulationSession's catchment may be None now to indicate that no catchment is associated with the session. Before the catchment's record was set to None in this case. * Greater/Modules/session.py (SimulationSession.rebind): Allow the new value to be None. (SimulationSession._get_catchment): Set the catchment to None if the session has no catchment instead of using a catchment with None as record. (SimulationSession.Destroy): self.catchment may be None now. (SimulationSession.SetCatchment): Allow the new catchment to be None. (SimulationSession.SetSubstance, SimulationSession.DBSync, SimulationSession.TreeInfo): Deal with self.catchment being None. (SimulationSession.CatchmentRecord): New method to return the datbase record of the catchment. (make_new_session): Deal with None catchment (edit_session, save_session_as): Use the new CatchmentRecord method. Deal with None catchments. * Greater/Modules/catchment.py (select_catchment): If the user deselects the catchment set the catchment itself to None. Use the new CatchmentRecord method. * Greater/UI/session.py (GreaterSession.update_map): Deal with the simulation session's catchment being None. * Greater/UI/mainwindow.py (GreaterMainWindow.update_title): Deal with the simulation session's catchment being None. * Greater/UI/context.py (context_catchment_open): Deal with the simulation session's catchment being None. 2002-10-24 Bernhard Herzog * Greater/Modules/parameterblock.py, Greater/Modules/parameter.py, Greater/Modules/substance.py: Remove unused imports 2002-10-24 Frank Koormann * Greater/Modules/substance.py (open_substance): Raise a warning if open substance is going to overwrite an existing substance data set. 2002-10-24 Bernhard Herzog * Greater/Modules/paratree.py: New module with a cache for the parameter definitions. * Greater/Modules/substance.py (sciparam_parameters): Use the paratree module instead of da_get_para_tree. * Greater/Modules/parameterblock.py (ParameterBlock._create_parameters): Use the paratree module instead of da_get_para_tree. * Greater/Modules/parameter.py (CreateParameter): Use the paratree module instead of da_get_para_tree. Fix some formatting done with tabs. * Greater/Modules/session.py (disconnect): Clear the cache maintained by the paratree module after disconnecting. 2002-10-22 Bernhard Herzog * Greater/Modules/parameterblock.py (ParameterBlock._create_parameters): Don't instantiate Parameter for the same record over and over again. 2002-10-21 Bernhard Herzog Fix some complaints from pychecker: * dbapiwrapper/genapiwrapper.py (BaseType.__ne__) (BaseType.__neq__): Rename the method to __ne__ and call __eq__ correctly (SimpleType.parse_tuple_char): Raise NotImplementedError for types that are not implemented yet because they're are currently not needed. (ListStruct.to_dict_list_impl): Remove unreachable code (DBGetFunction.c_method_impl, DBInsertFunction.c_method_impl) (DBInsertFunction.c_stub, DBUpdateFunction.c_method_impl) (DBFreeFunction.c_stub): Removed unused local variables (main): Fix incorrectly spelled local variable 2002-10-21 Bernhard Herzog Optionally include debug code in the API wrapper: * dbapiwrapper/genapiwrapper.py (WrappedFunction.py_wrapper) (SpecialFunction.py_wrapper, DBGetFunction.py_wrapper) (DBInsertFunction.py_wrapper, DBUpdateFunction.py_wrapper) (DBDeleteFunction.py_wrapper): New parameter insert_debug_output to generate code that prints debug information (format_py_module): New parameter insert_debug_output. Pass through to the py_wrapper methods (generate_wrapper): New parameter insert_debug_output. Pass through to format_py_module * setup.py (GenerateWrapper.run): New command line parameter wrapper-with-debug-output and corresponding instance variable wrapper_with_debug_output to choose whether hte python wrapper code should contain debug code (GenerateWrapper.user_options): Pass wrapper_with_debug_output to the insert_debug_output parameter of generate_wrapper (greater_build.initialize_options, greater_build.user_options): Add wrapper-with-debug-output here too so that it's passed through to the GenerateWrapper command 2002-10-16 Frank Koormann * simulwrapper/simul/io_dbf.py, simulwrapper/simul/io_dbf.py (rewriteResults): Performance update based on an analysis by bh: search for stretches with discharges based on a dictionary instead of scanning a list. 2002-10-10 Frank Koormann * Greater/Modules/model.py: Fixed bug introduced by last renaming update. 2002-10-08 Frank Koormann * Greater/Modules/model.py: Consider function name changes in simulwrapper * simulwrapper/simul/greater_simul.py: greater_simul.py no longer provides a main function (The former dbf mode): (greaterSimul_dbf(configFile)): New (greaterSimul_dbapi(parameter)): The former greaterSimul(parameter) * simulwrapper/simul/io_dbapi.py: (Discharge): Added handling of market data (input): Consider changes to Discharge function header. (rewriteResults): Fixed mix up in river simulation results oprder (Substance): Fixed handling of (potentially) distributed parameters. The current simulator can't handle these correct. 2002-09-23 Frank Koormann * simulwrapper/simul/greater_simul.py (simul): Modifications of simcmd to make it compatible to WIN98. (use "start /w" in combination with os.system()) * simulwrapper/simul/io_dbapi.py (rewriteResults): Explicitly close result files after read. 2002-09-18 Frank Koormann * doc/greater-manual.tex: Added short remarks on chapters Installation and Tutorial. Removed Menu Items currently not displayed by the client. 2002-09-18 Frank Koormann * doc/greater-manual.tex: Added section on main window and minor fixes according to functionality of milestone 1 release of GREAT-ER client. * doc/screenshots/*.eps: Windows version of all screenshots. 2002-09-16 Frank Koormann * simulwrapper/simul/greater_simul.py (simul): Added some output to give the user a better impression of the wrapper status. * simulwrapper/simul/io_dbapi.py (Environment): Updated field_id for "Combined Sewer Flow" paramater. * Greater/UI/mainwindow.py (About): Updated "About" text to great-er_milestone_1 CVS tag. 2002-09-14 Frank Koormann * Greater/Dialogs/editsubstance.py (editsubstance_dialog): Open ParameterNotebookDialog with two columns. * Greater/Modules/session.py: Updated help texts. (open_session): Call context.session.issue(CHANGED,context.session) explicitly to update status bar. * Greater/Modules/analysis.py: General update of help texts and dialogs to point out implementation in phase 2. * Greater/Modules/catchment.py: Updated help texts. * Greater/Modules/substance.py: Updated help texts. 2002-09-13 Bernhard Herzog * Greater/Dialogs/widgets.py (EditCommentBox.__init__): The correct length limit is 2000 characters. (LengthValidator.Validate): Put the actual max. length into the message 2002-09-13 Thomas Koester * Greater/Dialogs/editsubstance.py (test_editsubstance_dialog): Tests for new SciParam feature COLUMN_BREAK. 2002-09-13 Bernhard Herzog * Greater/Modules/model.py (Command stop_simulation): Disable it permanently. * Greater/Modules/substance.py (open_substance): Show a busy cursor during the database operations. * Greater/UI/mainwindow.py (GreaterMainWindow.__init__): Make the leftmost field the largest one and remove the SetStatusBarPane call as it doesn't work with wxWindows 2.3.2 (GreaterMainWindow.set_position_text): Put the text into the leftmost field (GreaterMainWindow.update_title): Change the order of the items to "GREAT-ER" - - - (GreaterMainWindow.update_status_bar): Put the information into the rightmost fields of the status bar. 2002-09-13 Bernhard Herzog * Greater/UI/mainwindow.py (GreaterMainWindow.__init__): Tweak the status bar so that we have three fields and the help messages are displayed in the rightmost one. (GreaterMainWindow.set_position_text): Override the inherited method to put the text into the rightmost status bar field. (GreaterMainWindow.__init__): Subscribe to some application messages so that we can subscribe to session messages. (GreaterMainWindow.app_session_changed): New. Subscribe to some session events and update the title and status bar. (GreaterMainWindow.session_changed): New. Update the title and status bar. (GreaterMainWindow.update_title): New. Update the title bar. (GreaterMainWindow.update_status_bar): New. Update the status bar. 2002-09-13 Bernhard Herzog * Greater/UI/mainwindow.py (GreaterMainWindow.__init__) (GreaterMainWindow.OnIdle): Disable some menus iff no session is open 2002-09-12 Frank Koormann * simulwrapper/simul/io_dbapi.py: (Discharge, Emission): In combination handle market_tab records to write the emission table and the required fields in the discharge input table. If a consumption is unknown for a given market_tab record this is interpreted as using the default consumption (same as in GREAT-Er 1). * simulwrapper/simul/io_core.py (Discharges): Handle information as generated by io_dbapi.Discharge(). 2002-09-12 Bernhard Herzog * Greater/Dialogs/savesessionas.py (run_savesessionas_dialog): Center the dialog on the parent. * Greater/Dialogs/editmodelparameter.py (editmodelparameter_dialog): Center the dialog on the parent. * Greater/Dialogs/authenticate.py (run_authenticate_dialog): Center the dialog on the parent. * Greater/Dialogs/editdischargedata.py (editdischargedata_dialog): Center the dialog on the parent. * Greater/Dialogs/editmarketdata.py (editmarketdata_dialog): Center the dialog on the parent. * Greater/Dialogs/editsession.py (run_editsession_dialog): Center the dialog on the parent. * Greater/Dialogs/editsubstance.py (editsubstance_dialog): Center the dialog on the parent. * Greater/Dialogs/opensession.py (run_opensession_dialog): Center the dialog on the parent. * Greater/Dialogs/opensubstance.py (run_opensubstance_dialog): Center the dialog on the parent. * Greater/Dialogs/selectcatchment.py (run_selectcatchment_dialog): Center the dialog on the parent. * Greater/Dialogs/selectmodel.py (selectmodel_dialog): Center the dialog on the parent. * Greater/Dialogs/editmodelparameter.py (editmodelparameter_dialog): Put a length validator on all comment fields. * Greater/Dialogs/selectmodel.py (selectmodel_dialog): Put a length validator on all comment fields. * Greater/Dialogs/editsubstance.py (editsubstance_dialog): Put a length validator on all comment fields. * Greater/Dialogs/savesessionas.py (SaveSessionAsDialog.OnOK): Validate the comment field and remove the unnessary cancel branch. 2002-09-12 Frank Koormann * Greater/Modules/discharge.py: Several changes to fix handling of market data: (Discharge.HasMarketInformation): New: Return 1 if any of the four data fields of a market record (consumption, flux_nondom, flux_runoff or remark) is different from None (or its equivalent). (Discharge.DBSync): Introduced a new flag (has_market_data) to decide if the contents of a record have to be inserted or updated. Complete redesign of the function. (Discharge._create_parameter): Fundamental redesign of market data handling. name and status of the market record must be not null, privileges set to 6 for the moment. * Greater/Modules/session.py: Several changes to fix the handling of market data and results in the client and the database: (SimulationSession.SetCatchment): Explicitly delete records from MARKET_TAB and RES_TAB when Catchment is changed. (SimulationSession.SetSubstance): Explicitly delete records from MARKET_TAB and RES_TAB when Substance is changed. In addition, destroy all discharges and rebuild them to eliminate market data fragments. (SimulationSession.UpdateMarketID): New: When inserting the first market data record for a session, the method calls discharge.DBSync() to let the database generate a new market_id. This ID is then set for the current session by reading it from the corresponding database record. (SimulationSession.TreeInfo): Added all contents of the session record in plain to get a better overview. * Greater/Modules/catchment.py (edit_marketdata_tool): Call SimulationSession.UpdateMarketID if tool dialog was closed with OK. 2002-09-12 Bernhard Herzog * Greater/Dialogs/widgets.py (LengthValidator): New. A validator to restrict a (multiline) text control's length. (EditCommentBox.__init__): Use a LengthValidator. (CommentBox): Add doc-string * Greater/Dialogs/editsession.py (EditSessionDialog.check_values): Validate the comment field. * Greater/UI/application.py (GreaterApplication.ShowExceptionDialog): Add a doc-string. Don't use the mainwindow because it might not exist anymore. * dbapiwrapper/genapiwrapper.py: Several changes to make sure all changes the db_api may have made to the struct are propagated back to the python wrappers. (DBInsertFunction.c_method_impl): Return the whole struct as a dictionary (DBInsertFunction.py_wrapper): Update the whole __dict__. (DBUpdateFunction.c_method_impl): Return the whole struct as a dictionary (DBUpdateFunction.py_wrapper): Update the whole __dict__. 2002-09-12 Frank Koormann * Greater/Modules/session.py (make_new_session): Call DBSync() after all session related components are setup. (delete_session): Explicitly delete temporary session. * Greater/UI/mainwindow.py (OnClose): If the context still shows a temporary session, delete it. * simulwrapper/simul/io_dbapi.py (rewriteResults): Activate already implemented da_delete_res when inserting new results. * Greater/Dialogs/authenticate.py (AuthenticateDialog): Explicitely call da_db_commit() after da_cleanup_temp_sess() to make changes visible to others. 2002-09-11 Frank Koormann * simulwrapper/simul/io_dbapi.py (rewriteResults): Order of CSIMEND and CSIMINTERNAL ar read from the simul-output was mixed. 2002-09-11 Bernhard Herzog * Greater/UI/application.py (GreaterApplication.ShowExceptionDialog): New method usable as an excepthook which displays a message box with the traceback (main): Use ShowExceptionDialog as the except hook while GREAT-ER is running. * Greater/Modules/catchment.py (edit_marketdata_tool) (edit_dischargedata_tool): Handle the comment field. * Greater/Modules/discharge.py (Discharge.MarketComment) (Discharge.SetMarketComment): New. Accessor methods for the market data's comment field. 2002-09-11 Thomas Koester * Greater/Dialogs/editmarketdata.py (editmarketdata_dialog), Greater/Dialogs/editdischargedata.py (editdischargedata_dialog): Use show_comment=false for ParameterDialog. * Greater/Dialogs/editmarketdata.py (editmarketdata_dialog), Greater/Dialogs/editdischargedata.py (editdischargedata_dialog), Greater/Modules/catchment.py (edit_marketdata_tool, edit_dischargedata_tool): edit*__dialog now use global comment. They return comment (if OK button was pressed) or None. * Greater/Dialogs/widgets.py: New class ParameterCommentDialog derived from ParameterDialog without parameter comments, but with one global comment. * Greater/Dialogs/editmarketdata.py (editmarketdata_dialog), Greater/Dialogs/editdischargedata.py (editdischargedata_dialog): Use ParameterCommentDialog. 2002-09-11 Bernhard Herzog * Greater/Modules/catchment.py (Catchment.Destroy): Extend the inherited method to Properly destroy the discharges. (Catchment.forward): New. Forward CHANGED events (Catchment._get_discharges): Subscribe to the discharges' CHANGED events. (_blue, _red, _green): Removed as they haven't been used for anything lately. * Greater/Dialogs/savesessionas.py (SaveSessionAsDialog.dialog_layout): Set the initial focus on the name text control * Greater/Dialogs/editsession.py (EditSessionDialog.dialog_layout): Set the initial focus on the name text control * Greater/Modules/model.py (init_menu): Unserline the 'i' instead of the 'S' in the 'Simulation' menu because 'S' is also used for 'Substance' 2002-09-10 Frank Koormann * simulwrapper/simul/io_dbapi.py (Substance): Reformatting distributed parameter fields. Suppress distribution info for K_INSTREAM. Convert unknown or missing parameters to "-1". * simulwrapper/simul/io_core.py (Discharge): Use field FLOW_DOM instead of DWF for flow. (Substance): Fixed handling of K_MAX. 2002-09-11 Bernhard Herzog * Greater/Modules/substance.py (new_substance): Show a busy cursor during database operations. * Greater/UI/context.py (context_can_start_simulation): New function to determine when a simulation may be started. * Greater/Modules/model.py (start_simulation): Return immediately if no simulation can be started in the current state of the context. (Command start_simulation): Only be sensitive if a simulation can be started. Fixes RT1285. 2002-09-11 Thomas Koester * Greater/Dialogs/opensubstance.py, selectcatchment.py: Fixed imports for local test. * Greater/Dialogs/opensubstance.py, Greater/Dialogs/savesessionas.py, Greater/Dialogs/selectcatchment.py: Make dialog conform to GUI styleguide. * Greater/Dialogs/opensession.py, Greater/Dialogs/opensubstance.py, Greater/Dialogs/selectcatchment.py: Use wxNewId() instead of fixed value. * Greater/Dialogs/widgets.py: New class OkCancelBox. * Greater/Dialogs/authenticate.py, Greater/Dialogs/editsession.py, Greater/Dialogs/opensession.py, Greater/Dialogs/opensubstance.py, Greater/Dialogs/savesessionas.py, Greater/Dialogs/selectcatchment.py: Use OkCancelBox. * Greater/Dialogs/editsession.py, Greater/Dialogs/opensession.py, Greater/Dialogs/opensubstance.py, Greater/Dialogs/savesessionas.py, Greater/Dialogs/selectcatchment.py: Use wxDEFAULT_DIALOG_STYLE as dialog style. * Greater/Dialogs/editdischargedata.py, Greater/Dialogs/selectmodel.py Greater/Dialogs/editmarketdata.py, Greater/Dialogs/editsubstance.py, Greater/Dialogs/editmodelparameter.py: Removed obsolete columns=1. 2002-09-11 Bernhard Herzog * Greater/Dialogs/widgets.py (EditCommentBox.GetValue): Remove the text parameter 2002-09-10 Frank Koormann * Greater/Modules/session.py (save_session_as): fixed bug #1254, store comment with new session. 2002-09-10 Bernhard Herzog * Greater/Modules/substance.py (new_substance): Implement it. (sciparam_parameters): Helper for new_substance 2002-09-10 Thomas Koester * doc/gui_styleguide.tex: Increase values for SPACE to 10 and SMALLSPACE to 4. * Greater/Dialogs/authenticate.py, Greater/Dialogs/editsession.py, Greater/Dialogs/opensession.py, Greater/Dialogs/savesessionas.py: Fixed imports for local test. * Greater/Dialogs/authenticate.py, Greater/Dialogs/editsession.py, Greater/Dialogs/errordialogs.py, Greater/Dialogs/opensession.py, Greater/Dialogs/widgets.py: Make dialog conform to GUI styleguide. * Greater/Dialogs/editsubstance.py, Greater/Dialogs/errordialogs.py: Fixed/Added standalone test. * Greater/Dialogs/widgets.py: Added EditCommentBox. * Greater/Dialogs/editsession.py, Greater/Dialogs/savesessionas.py: Use EditCommentBox from widgets.py. 2002-09-09 Bernhard Herzog * Greater/UI/application.py (main): Add the help menu. (main): Make the _api_interface the default DB interface * dbapiwrapper/genapiwrapper.py (Array.py_to_c): Take the terminating NUL into account when comparing the length of the python string to the length of the char array. 2002-09-09 Frank Koormann * Greater/Modules/session.py (close_session, new_session, open_session): Replaced da_cleanup_temp_sess() with explicit da_delete_sess( current session ). In conjunction with the following this is the fix of http://intevation.de/rt/webrt?serial_num=1269&display=History * Greater/UI/authenticate.py (AuthenticateDialog): Call da_cleanup_temp_sess() after successful connect to database. Store user name in upper case. 2002-09-09 Bernhard Herzog * Greater/Dialogs/editsession.py (EditSessionDialog.dialog_layout): Limit the length of the name to the length in the corresponding field of the db-api struct. (EditSessionDialog.check_values): New method to check the session name. (EditSessionDialog.OnOK): Call check_values. 2002-09-09 Thomas Koester * Greater/Dialogs/editdischargedata.py, Greater/Dialogs/editmarketdata.py, Greater/Dialogs/editmodelparameter.py, Greater/Dialogs/editsubstance.py, Greater/Dialogs/selectmodel.py: removed calls to SetDimensions(). * Greater/UI/mainwindow.py (GreaterMainWindow.About): added version information for GREAT-ER UI, SciParam and DB-API. 2002-09-09 Frank Koormann * Greater/Modules/session.py (edit_session): Added BusyCursor 2002-09-09 Frank Koormann * Greater/Modules/session.py (new_session, open_session, close_session): Updated changes management: Save changes to current session on request. 2002-09-09 Frank Koormann * Greater/Dialogs/editmodelparameter.py (editmodelparameter_dialog): Adapted window title to menu entry. * Greater/Dialogs/selectmodel.py (selectmodel_dialog): Adapted window title to menu entry. 2002-09-09 Frank Koormann * Greater/Modules/parameter.py (CreateParameter): As a workaround choice parameters are created as lists if they are not of type 42 (yes/no choices). 2002-09-09 Bernhard Herzog * Greater/UI/session.py (GreaterSession.rebind): Call the old value's Destroy method. 2002-09-06 Bernhard Herzog * Greater/UI/application.py (main): Remove the standard Thuban commands from the menu * Greater/Dialogs/editsession.py (EditSessionDialog.dialog_layout): Use wxChoice instead of wxComboBox. This fixes bug #1251 and is the right widget anyway because the user shouldn't be able to edit the name of the substance or catchment. * Greater/UI/session.py (GreaterSession.Destroy): New. Extend the inherited method to destroy the simulation_session too. * Greater/Modules/session.py (SimulationSession.Destroy): New. Extend the inherited method to destroy the other PUblisher instances owned by the SimulationSession instance. 2002-09-05 Bernhard Herzog * Greater/Dialogs/authenticate.py (AuthenticateDialog.dialog_layout): Give the database edit widget the initial focus * Greater/Dialogs/editsession.py (EditSessionDialog.__init__): Add the session's current substance as a choice too if it isn't a template anymore. 2002-09-05 Frank Koormann * Greater/Modules/catchment.py (edit_marketdata_tool, edit_dischargedata_tool): Corresponding record in DISCH_TAB to the selected shape of the discharge layer is looked up via the shapes "discharge" attribute. (Fix for Bug #1267) 2002-09-05 Frank Koormann * Resources/Bitmaps/edit_market.xpm: New icon * Resources/Bitmaps/edit_discharge.xpm: New icon * Greater/Modules/catchment.py: Adapted toolbar generation to new icons. 2002-09-05 Bernhard Herzog * Greater/Modules/catchment.py (select_catchment): Display busy cursor during DB operations. * Greater/Dialogs/authenticate.py (AuthenticateDialog.OnOK): Display busy cursor during DB operations. * Greater/Modules/model.py (start_simulation): Display busy cursor during DB operations and simulation. Add doc string * Greater/Modules/session.py (new_session, make_new_session): Split the actual creation of the new session into a separate function to make it easier to display a busy cursor. (edit_session, save_session_as, close_session, delete_session): Add/update doc-string. (disconnect, open_session, save_session, save_session_as) (close_session): Display busy cursor during DB operations 2002-09-05 Frank Koormann * Greater/Modules/session.py (open_session): If the current session is modified, ask the user to proceed before displaying the open dialog. 2002-09-04 Frank Koormann * Greater/Modules/session.py (new_session): Workaround to create a valid temp session (from an immediately deleted permanent one). 2002-09-04 Bernhard Herzog * Greater/Modules/discharge.py (Discharge.Sync): Convert the parameter values to the string representation. * Greater/Modules/model.py (Model.DBSync, Environment.DBSync): Insert the records if they're not in the database yet. 2002-09-04 Frank Koormann * Greater/Modules/session.py (save_session, save_session_as): On save change user ID to the current user. 2002-09-04 Bernhard Herzog * Greater/Modules/discharge.py (Discharge.DBSync): Yet another fix to corectly recognize an empty marketrecord. * Greater/UI/mainwindow.py (GreaterMainWindow.OnClose): Only clean up temp sessions if connected. 2002-09-04 Frank Koormann * Greater/Modules/discharge.py (Discharge.DBSync): Fixed recently introduced bug on if constructs * Greater/Modules/session.py (authenticate): * Greater/UI/application.py (main): Call session.UnsetModified() after session.SetDBConnection() since connecting to a database is performed before any session is open. 2002-09-04 Frank Koormann * simulwrapper/simul/greater_simul.py (simul): Delete cfg-file after simulation. * Greater/Modules/discharge.py (Discharge.DBSync): Insert market record only when changes were made. * Greater/Modules/model.py (Model.DBSync, Environment.DBSync): Check if structures really exist before update. * Greater/Modules/session.py (new_session): Replace fixed user_id by id for current user. Fixed is_temp_sess flag (was 'N' instead of 'Y') (save_session): If we have a new session (i.e. temp_sess_src_id = -1), make it a permanent session simply by changing is_temp_sess instead of calling da_make_temp_sess_permanent. (save_session_as): Fixed bug: unknown sess was used instead of sim.record. 2002-09-02 Bernhard Herzog * Greater/UI/mainwindow.py (GreaterMainWindow.About): Greater/UI/application.py (run_about_dialog): Move the implementation of the about command to the mainwindow. Overriding a method is simpler than redefining a command now that we have a GREAT-ER specific main window. * Greater/UI/mainwindow.py (GreaterMainWindow.OnClose): Override the inherited method to make sure that on a normal exit the temporary sessions are deleted from the database 2002-08-30 Bernhard Herzog * Greater/Modules/catchment.py (CatchmentMap.CanRemoveLayer): Override to disallow deletion of the special layers 2002-08-30 Jan-Oliver Wagner * dbapiwrapper/apispec.py: just added the forgotten update of which version of the API this refers to (it is 2.4). * Greater/Modules/session.py (SimulationSession.__get_results): fixed a bug (no. of params for da_get_res was wrong). (new_session): Now call da_cleanup_temp_sess before creating a new one. (open_session): Now call da_cleanup_temp_sess before opening a new one. (close_session): Now call da_cleanup_temp_sess. 2002-08-29 Jan-Oliver Wagner * Greater/Modules/parameterblock.py (ParameterBlock.SetParameters): new. An alternative to __init__ to set the parameters. * Greater/Modules/catchment.py (Catchment.DBSync): now always set the sess_id and market_id for each discharge before sync'ing it. (select_catchment): Fixed a bug. * Greater/Modules/model.py (Model.__init__, Environment.__init__): Now if mod_id/env_id is -1 an empty list of mod/env-details is used (and can be later set with the new ParameterBlock method SetParameters). (Model.DBSync, Environment.DBSync): Always set the mod_id (env_id) of the single detail-records since they can be -1 e.g. for new sessions. * Greater/Modules/session.py: Comprehensive rework! The basic change is towards a data manegement where session data are mainly kept in dynamic structure in the GREAT-ER GUI Client and only written to the database when it is really necessary to do so (save session, save session as and delete session and of course Start Simulation) 2002-08-29 Jan-Oliver Wagner * Greater/Modules/discharge.py (Discharge.__init__): two additional parameter sess_id and market_id which are required to work with market data. (Discharge.DBSync): Now calls da_insert_market if the corresponding record has ID = -1 (hence not yet in the database). (Discharge._creater_parameters): Fixed call of da_get_market and generalized code. * Greater/Modules/catchment.py (Catchment.__init__): two additional parameter sess_id and market_id which are required to work with market data. * Greater/Modules/session.py: removed dummy setting of cre_date and mod_date as this is fixed now with dagreater 2.5. Adapted to new init-Functions of Catchment. 2002-08-29 Jan-Oliver Wagner * doc/gui_styleguide.tex: Applied real emphasize instead of $$. 2002-08-28 Frank Koormann * simulwrapper/simul/io_dbapi.py: Default Consumption handling fixed. 2002-08-28 Frank Koormann * doc/greater-testplan.tex, doc/gui_styleguide.tex: Added \usepackages{times} for smarter pdf output. 2002-08-28 Jan-Oliver Wagner * doc/greater-testplan.tex: added prerequisit for Sim. 2002-08-28 Jan-Oliver Wagner * Greater/Modules/parameter.py (Parameter.TreeInfo): print data of record, not of SciParam. 2002-08-28 Frank Koormann * simulwrapper/simul/io_dbapi.py: Bugs in "unknown" handling fixed 2002-08-28 Frank Koormann * simulwrapper/simul/io_dbapi.py: Handling of "unknown" values fixed. 2002-08-28 Thomas Koester * doc/greater-testplan.tex: removed unnecessary directive. Changed 'Dialog' to lowercase. Added a 'press Cancel' directive. 2002-08-28 Jan-Oliver Wagner * Greater/UI/application.py (main): Removed default appearance of session tree. 2002-08-28 Frank Koormann * Greater/Dialogs/editdischargedata.py (editdischargedata_dialog): Added name as third parameter to display discharge name in title bar. * Greater/Dialogs/editmarketdata.py (editmarketdata_dialog): Added name as third parameter to display discharge name in title bar. * Greater/Modules/catchment.py (editdischargedata_tool, editmarketdata_tool): Call according dialog with discharge name. 2002-08-28 Jan-Oliver Wagner * Greater/Modules/substance.py (Substance.DBSync): Fixed bug 1252 (now test for record == None) 2002-08-28 Thomas Koester * doc/greater-testplan.tex: changed geometry, splitted two tests, corrected logical errors. * doc/greater-testplan.tex: reverted geometry to old width. 2002-08-28 Frank Koormann * Greater/Modules/model.py (start_simulation): Added DBSync. * Greater/Modules/session.py (SimulationSession.SetCatchment): When changing the catchment update SimulationSession.Results after deletion of results. 2002-08-28 Jan-Oliver Wagner * Greater/Modules/session.py (new_session): Fixed a bug (create only real parameters, not group-separators). * Greater/Modules/substance.py: Removed menu item Delete. * doc/greater-manual.tex: Removed menu item Delete. 2002-08-28 Thomas Koester * doc/greater-testplan.tex: fixed typos, inserted \pagebreak. 2002-08-28 Bernhard Herzog * Greater/Modules/catchment.py (EditTool.__init__, EditTool.MouseUp): fetch the discharge layer in MouseUp instead of specifying it as an instance variable. The layer may have been destroyed because the catchment was changed. layer may have changed (start_edit_tool, edit_marketdata, edit_dischargedata): No need to pass the layer around anymore. 2002-08-28 Jan-Oliver Wagner * doc/greater-testplan.tex: Added 'Session Management', 'Substance Management' and 'Simulation' section. Some typos fixed. 2002-08-28 Thomas Koester * doc/greater-testplan.tex: Added 'Parameter Dialogs' section. Fixed small typos and layout. * doc/greater-testplan.tex: Used \verb command for . * doc/greater-testplan.tex: Added 'Catchment/Discharge Management' section. * doc/greater-testplan.tex (Parameter Dialogs): added one test. * doc/greater-testplan.tex: Added 'Model' section. 2002-08-28 Jan-Oliver Wagner * doc/greater-testplan.tex: Rework. new enumeration, now with sections, and other face lifting. 2002-08-28 Thomas Koester * doc/greater-testplan.tex: Added usage and failure report guide. 2002-08-28 Frank Koormann * Greater/Modules/model.py (start_simulation): Start simulation and upload results on success. * simulwrapper/simul/greater_simul.py: Changed import path. * Greater/Dialogs/authenticate.py (AuthenticateDialog.OnOK): Added password to the returned values. * Greater/Modules/results.py: import da_get_res_stretch, da_get_res_disch. * Greater/Modules/session.py (DBConnection.__init__): Added password. * Greater/UI/application.py (main): Added password to DBConnection. 2002-08-28 Jan-Oliver Wagner * Greater/Modules/substance.py (Substance.__init__): now if the substance record is a template, a copy is created in the database and used for the instance of Substance. Of course all substance details are copied as well. * Greater/Modules/session.py (new_session): Fixed bug for results. (SimulationSession.SetXXX, XXX=Substance, Model, Environment, Results): fixed to handle None. 2002-08-28 Frank Koormann * Greater/Modules/session.py (SimulationSession.SetCatchment): Fixed handling of result deletion. Currently only reset the session.res_id to -1 (SimulationSession.CopySession): Updated insert of session to API v2.5 * simulwrapper/simul/greater_simul.py (greaterSimul): Updated da_get_sess to API v2.5, fixed handling of MCshots represented in exponential notation. * simulwrapper/simul/io_dbapi.py (rewriteResults): Fixed handling of result deletion. Currently only reset the session.res_id to -1. Updates to API v2.5 (Substance): Fixed handling of "unknown" values * simulwrapper/simul/io_core.py (RiverClass): Fixed SS_VAL bug 2002-08-27 Jan-Oliver Wagner * Greater/Modules/catchment.py (Catchment.DBSync): new. update all discharge data to database * Greater/Modules/discharge.py (Discharge.DBSync): new. this method does not update the database yet - read the comments. * Greater/Modules/parameter.py (Parameter.Sync): fixed bug. * Greater/Modules/parameter.py (Substance.DBSync): new. update substance and all substance details to database. * Greater/Modules/session.py (SimulationSession.Sync): new. update record from component data. (SimulationSession.DBSync): new. update session and all its components to database. (save_session): call Sync and DBSync; sync-code moved to Sync(). * Greater/Modules/model.py (Model.DBSync, Environment.DBSync): new. update details to database. 2002-08-27 Jan-Oliver Wagner * Greater/Modules/catchment.py: Sync SciParam and DB record after dialogs returned with OK. * Greater/Modules/substance.py (Substance.Sync): new. copy back inputs from SciParams to the records * Greater/Modules/discharge.py (Discharge.TreeInfo): Also print the contents of the marketrecord. (Discharge.Sync): new. copy back inputs from SciParams to the records. (Discharge._create_parameters): build self.disch_parameter_dict and self.market_parameter_dict to support Sync(). * Greater/Modules/parameterblock.py (ParameterBlock.Sync): new. copy back inputs from SciParams to the records. * Greater/Modules/parametergroup.py (ParameterGroup.Sync): new. copy back inputs from SciParams to the records. * Greater/Modules/parameter.py (Parameter.Sync): new. copy back inputs from SciParams to the records. (distrib_ids): new (CreateParameter): use distrib_ids. * Greater/Modules/model.py: call Sync() after Dialogs are finished with OK. 2002-08-27 Bernhard Herzog * setup.py (GenerateWrapper.run): Also check oracle_interface_lib when deciding whether to create _api_interface.c 2002-08-27 Thomas Koester * doc/greater-testplan.tex: Use \CVSRevision command. * doc/Makefile, doc/greater-testplan.tex: Added test plan. * doc/Makefile: Removed references to old documents. Changed DOCUMENTS to greater-manual and gui_styleguide. 2002-08-26 Bernhard Herzog * Greater/UI/mainwindow.py: New module with a GREAT-ER specific mainwindow class * Greater/UI/application.py (GreaterApplication.CreateMainWindow): Use th new mainwindow class 2002-08-26 Frank Koormann * doc/greater-manual.tex: Added "\usepackage{times}" for readable pdf-documents. 2002-08-26 Frank Koormann * doc/greater-manual.tex: Fixed some typos. * doc/Makefile: new. 2002-08-26 Jan-Oliver Wagner * Greater/UI/application.py (main): Added option --alpha which will enable the alpha module. * Greater/Modules/alpha.py: new. module for alpha-test code. * Greater/Modules/catchment.py: Now loads stretch and discharge records explicitely (to easily show them in tables). * Greater/Modules/results.py (Results._get_stretch_results, Results._get_stretch_results): new. Load corresponding records from the database. * Greater/Modules/datatable.py: Now records is assumed to contain database records directly instead of assuming each record contains a component 'record'. * Greater/Modules/session.py (SimulationSession.Results): new 2002-08-26 Bernhard Herzog * Greater/Modules/datatable.py: New module for a table class holding greater DB records. 2002-08-26 Jan-Oliver Wagner * Greater/Modules/results.py: new 2002-08-26 Jan-Oliver Wagner * Greater/Modules/session.py (SimulationSession.SetCatchment): Fixed bug to handle as catchment. Avoid -1 for da_get_catch as already improved for the other da_get functions. 2002-08-24 Jan-Oliver Wagner * Greater/Modules/analysis.py: menus now have sensitivitiy to context_results_exist. * Greater/Modules/model.py: Added ID of model and environment to the TreeInfo. * Greater/Modules/session.py: Added handling of Results. Bug fix for selecting no substance. Improvement for da_get_-functions where id of -1 occurs as indicator for no record: Avoid to call da_get_ with -1 as this will retrieve all records. Removed ID output from TreeInfo (it is no in the corresponding sub-classes). * Greater/Modules/substance.py: Added ID of substance to the TreeInfo. * Greater/UI/context.py: Added context_results_exist. * Greater/Dialogs/opensubstance.py: Fixed bug on pre-selection. 2002-08-23 Bernhard Herzog * Greater/UI/application.py: Replace Thuban's about box with a GREAT-ER one (run_about_dialog): Implement the about box. 2002-08-23 Jan-Oliver Wagner * doc/screenshots/mcshots-dlg.eps: removed * doc/screenshots/backgroundconcentration-dlg.eps: removed * doc/greater-manual.tex: removed menues for bg-conc and mc-shots 2002-08-23 Jan-Oliver Wagner * dbapiwrapper/apispec.py: various fixes in stub data * Greater/Modules/discharge.py: renamed parameter key CONSUMPTION to SITE_CONSUMPTION 2002-08-23 Frank Koormann * Greater/Dialogs/selectcatchment.py (_TestApp.OnInit): Print the returned catch_id instead of the instance. * Greater/Modules/session.py (SimulationSession.SetCatchment): On change delete market and result data, update record and sync database. (SimulationSession.SetSubstance), (SimulationSession.SetModel), (SimulationSession.SetEnvironment): update record and sync database. (SimulationSession.CopySession): Fixed bug in market data copying: market_id was not set to new ID. (SimulationSession.TreeInfo): Added catch_id, subst_id, mod_id and end_id to the tree. (save_session_as): replaced da_insert_sess with da_update_sess: The second insert with same references caused the problems under delete_session. 2002-08-23 Bernhard Herzog * dbapiwrapper/genapiwrapper.py (DBInsertFunction.py_wrapper): Handle insert functions with more parameters than the struct DA_S_err 2002-08-23 Frank Koormann * Greater/Modules/session.py: Adapted call of da_create_temp_sess() to new wrapper implemenation. (delete_session): Bug fixed: changed "none" to "None" 2002-08-22 Frank Koormann * Greater/Dialogs/opensession.py: Added title paramater to open the dialog with variable title. (OpenSessionDialog.dialog_layout): Fixed API call to get substance list, corrected hanling of "None" values for substance and catchment. * Greater/Dialogs/savesessionas.py: Fixed handling of "None" values for catchment and substance. * Greater/Modules/catchment.py (Catchment.TreeInfo): catch_id added to the list. * Greater/Modules/session.py: Session handling added. (SimulationSession.CopySession): New method to return a full copy of the current session. Create new entries in the SESS_TAB and all related tables (substance, environment, model, market, result). (SimulationSession.TreeInfo): sess_id added to the list. (new_session): Rewritten to create new session with name, remark, catchment and substance depending on user inputs and environment and model structures filled with default values. (open_session): Added handling of temporary sessions and title feature. (save_session): Added handling of temporary sessions and "None" values. (delete_session): New feature. 2002-08-22 Bernhard Herzog * dbapiwrapper/genapiwrapper.py (SpecialFunction.__init__): New parameter output_params for lParameters of the C function that are really output functions and should not be parameters of the python wrapper function. * dbapiwrapper/apispec.py (da_create_temp_sess): Add output_params parameter to ignore sess_id_tmp in the python wrapper. 2002-08-22 Jan-Oliver Wagner * Greater/Modules/parameter.py (Parameter.TreeInfo): fixed output so that now the value, dist-type and required are shown based on the SciParam and not the record. * Greater/Modules/substance.py (Substance.__init__): bugfix to allow None as record. * Greater/Modules/model.py (Model.__init__, Environment.__init__): bugfix to allow None as record. * dbapiwrapper/apispec.py: various fixes in stub-data of para_tree_def_tab 2002-08-22 Bernhard Herzog * Greater/UI/application.py (main): Also pass the toolbar to the init_menu functions. * Greater/Modules/substance.py (init_menu), Greater/Modules/session.py (init_menu), Greater/Modules/model.py (init_menu), Greater/Modules/analysis.py (init_menu): Add the toolbar parameter * Greater/Modules/catchment.py (init_menu): Add the toolbar parameter adnd add the edit_marketdata and edit_dischargedata commands to the toolbar as well. (Commands edit_marketdata, edit_dischargedata): Turn them into tools by adding an icon and a "checked" callback * Greater/Modules/session.py (save_session_as): Remove the XML debug code. 2002-08-22 Jan-Oliver Wagner * Greater/Modules/parametergroup.py: new (Class ParameterGroup) * Greater/Modules/parameterblock.py: new (Class ParameterBlock) * Greater/Modules/parameter.py (is_param_greater): new (Parameter.TreeInfo): Removed Group and Block-ID * Greater/Modules/model.py: Model and Environment now derived from class ParameterBlock. * Greater/Modules/substance.py: Substance now derived from class ParameterBlock. * dbapiwrapper/apispec.py: Group GENERAL of MOD added. 2002-08-22 Bernhard Herzog * Greater/Modules/catchment.py (GreaterLayer): New class for the greater specific layers for a catchment's shapefiles. (CatchmentMap): The shapefiles are now retrieved from the db outside of the catchment map and the catchment map may be constructed from a (sort of) thuban session file. This means that: (CatchmentMap.__init__): New parameters for the shapefile names and the temporary directory (CatchmentMap.make_temp_dir, CatchmentMap.SetCatchment) (CatchmentMap.build_layers): Removed. (catchment_map_from_catchment): New function to create a CatchmentMap from the database information * Greater/UI/session.py (GreaterSession.update_map): Always create a new Catchment map if there is a catchment and don't update in place. (GreaterSession.Serialize): New method to return an XML representation of the session * Greater/UI/serialize.py: New module to create and parse the greater/thuban session XML representation. * Greater/UI/application.py (main): Remove some debug prints and add newlines to the messages written to stderr. * dbapiwrapper/genapiwrapper.py (SpecialFunction): New class for wrappers that are code completely by hand. * dbapiwrapper/apispec.py: Implement da_create_temp_sess, da_make_temp_sess_permanent and da_cleanup_temp_sess 2002-08-21 Jan-Oliver Wagner * Greater/Modules/discharge.py, Greater/Modules/parameter.py, Greater/Modules/substance.py: replaced "UNKNOWN" by "%" as required by the new dagreater 2.4 * Greater/Modules/session.py: replaced "Y" by "%" as required by the new dagreater 2.4 2002-08-21 Jan-Oliver Wagner * Greater/Dialogs/opensession.py: adaption to new dagreater 2.4: da_get_sess and da_get_subst * Greater/Modules/model.py: adaption to new dagreater 2.4: da_get_para_tree * Greater/Modules/parameter.py: adaption to new dagreater 2.4: da_get_para_tree * Greater/Modules/substance.py: adaption to new dagreater 2.4: da_get_para_tree 2002-08-21 Frank Koormann * Greater/UI/application.py main(): DB connection infos were mixed up for the session tree when connecting via db-auto-login. 2002-08-21 Jan-Oliver Wagner * Greater/Dialogs/mcshots.py: removed (now part of model parameters) * Greater/Dialogs/backgroundconcentration.py: removed (now part of model parameters) * dbapiwrapper/apispec.py: added several group headers for stub da_get_para_tree now can deliver group headers. Phrase Yes/no now offers 'Y'/'N' instead of '1'/'0'. * Greater/Modules/substance.py: Groups are now automatically build from the database. * Greater/Modules/model.py: Groups are now automatically build from the database. Removed menu item and asociated functions for mc-shots and background-concentration. Renamed the remaining two menu items of Model. 2002-08-21 Bernhard Herzog * dbapiwrapper/parse_function_proto.py (parse_prototype): lowercase the parameter names. (format_function): Remove the superfluous open paren from the default function case. * dbapiwrapper/apispec.py: Update for API Specification 2.4 * Greater/UI/application.py (main): Add db-auto-login commandline option (requires env. var GREATER_DB_PARAMS to be set to USERNAME:PASSWORD:DBNAME). 2002-08-21 Frank Koormann * Greater/UI/session.py (GreaterSession.update_map): Work around Greater.Modules.catchment.CatchmentMap.SetCatchment() since current_map can also be an instance of Thuban.Model.map.Map 2002-08-21 Frank Koormann * Greater/Dialogs/savesessionas.py: New * Greater/Dialogs/editsession.py: Added variable window title. * Greater/Modules/model.py: Added handling of None for Model and Environment * Greater/Modules/session.py: Added save session features (new_session): Call run_editsession_dialog() and create new session. Currently not functional due to DB API limits. (SimulationSession._get_catchment), (SimulationSession._get_substance), (SimulationSession._get_model), (SimulationSession._get_environment): Handling of empty DB query results (SimulationSession.SetModel),(SimulationSession.SetEnvironemnt): added (edit_session): Dialog Title added (save_session): Execute da_db_commit (save_session_as): Call run_savesessionas_dialog() and insert new session record into database, execute da_db_commit * Greater/UI/session.py (GreaterSession.update_map): Handling of catchment.record == None added. 2002-08-20 Jan-Oliver Wagner * doc/greater-manual.tex: updated menu File description according to recent changes * Greater/Modules/catchment.py: Introduced default colors for the default layers. * Greater/Modules/session.py: fixed a bug in open_session 2002-08-20 Jan-Oliver Wagner * Greater/UI/context.py: added context_substance_open and context_catchment_open * Greater/Dialogs/authenticate.py: Now dialog returns a tupel (database and username). Fixed dialog-test. * Greater/Dialogs/selectcatchment.py: Now allows to handle as an option for the selection. Fixed dialog-test. * Greater/Dialogs/opensubstance.py: Now allows to handle as an option for the selection. Fixed dialog-test. * Greater/Dialogs/editsession.py: Now allows to handle as an option for the selections of substance and catchment. Fixed dialog-test. * Greater/Modules/catchment.py: Menu items now sensitive to whether there is no current catchment. Added handling for the opportunity to have no catchment selected. * Greater/Modules/substance.py: Menu item Edit Substance now sensitive to whether there is no current substance. Added handling for the opportunity to have no substance selected. * Greater/Modules/session.py: Added call of da_db_disconnect. Added info about connected database in TreeInfo. Fixed edit_session: now full extent is shown automatically to show the newly selected catchment. 2002-08-19 Jan-Oliver Wagner * Greater/UI/context.py: removed context_session_unmodified (not required anymore). * Greater/Modules/session.py: Implemented disconnect. Reworked close_session (now launches a confirmation dialog). 2002-08-19 Jan-Oliver Wagner * dbapiwrapper/apispec.py: Various changes in the stub data * Greater/UI/context.py: Added context_session_modified and context_session_unmodified * Greater/UI/session.py(GreaterSession.SetSimulationSession): Now handles None as parameter that indidicates to remove the session. * Greater/Modules/session.py: Added further menu sensitivity to context states. Implemented close_session. * Greater/Modules/parameter.py: Fixed a small bug in calling da_get_phrase_grp(). 2002-08-19 Frank Koormann * simulwrapper/simul/greater_simul.py (greaterSimul): Fixed access to mod_tab-values. * simulwrapper/simul/io_core.py (Substance): Handling of K_MAX and distributed values fixed. * simulwrapper/simul/io_dbapi.py (Substance): Processing of distributed parameters fixed. (rewriteResults): Session handling fixed. * simulwrapper/simul/io_dbf.py (River): Cast river length to string. * Greater/Dialogs/opensession.py: Dialog title changed. 2002-08-17 Frank Koormann * simulwrapper/simul/io_dbapi.py: new * simulwrapper/simul/io_core.py, simulwrapper/simul/greater_simul.py: Adaptions to the specific requirements for the DB API 2002-08-15 Jan-Oliver Wagner * dbapiwrapper/apispec.py: Various changes in the stub data to harmoinize with TDs Oracle contents. * Greater/Modules/model.py: Split up class Model into Model and Environment. * Greater/Modules/session.py: New menu items disconnect and close session. New component environment of session. * Greater/UI/context.py: new context context_db_closed * Greater/Dialogs/editsession.py: fixed upcase/lowercase bug * Greater/Dialogs/opensubstance.py: fixed upcase/lowercase bug * Greater/Dialogs/opensession.py: import statement shifted to the top 2002-08-15 Bernhard Herzog * Greater/Modules/catchment.py (CatchmentMap.__del__) (CatchmentMap.Destroy): Call remove_temp_dir after calling the inherited method. On windows we have to be sure that all files are closed before we try to remove them as open files can't be closed. * dbapiwrapper/genapiwrapper.py (ListStruct.from_dict_impl): Revert the changes to return value of the generated from_dict function. (DBInsertFunction.c_method_impl, DBUpdateFunction.c_method_impl): Create an exception object when the argument isn't a dictionary. 2002-08-14 Jan-Oliver Wagner * Greater/Dialogs/errordialogs.py: new * Greater/Dialogs/opensession.py: intermediate fix for calling da_get_subst * Greater/Modules/parameter.py (CreateParameter): Added error handling * Greater/Modules/session.py: intermediate fix for calling da_get_subst * Greater/Modules/discharge.py: replaced DUMMY by UNKNOWN for all calls of CreateParameter * dbapiwrapper/apispec.py: Added functions da_db_commit, da_db_rollback; Added substance parameter K_SED for stub; Adapted some field_id's to be compatible with TechniData; Temporarily deactived params of da_delete_market 2002-08-14 Frank Koormann * simulwrapper/simul/io_dbf.py: fixed indention error in function Discharge 2002-08-14 Bernhard Herzog * setup.py (GenerateWrapper.initialize_options) (greater_build.initialize_options) (GenerateWrapper.finalize_options): New option oracle-interface-lib to build the API wrapper linked to a DLL (GenerateWrapper.add_oracle_interface) (GenerateWrapper.oracle_extension_from_file) (GenerateWrapper.oracle_extension_from_lib): Split add_oracle_interface into two new methods one for building with a single extra C-file and one for building with a DLL. * Greater/UI/application.py (main): Fix bug in option processing. * dbapiwrapper/genapiwrapper.py (format_py_module) (generate_wrapper): Make the generated python module more flexible with regard to which cmodule to use so that it can be used with both the stub and the real DB API interface. (WrappedFunction.py_wrapper): Generate a real python function so that it's dispatched to the c-module at runtime. * setup.py (GenerateWrapper.run): Only generate the python wrapper module once as Greater/DB/pyinterface.py. * Greater/DB/interface.py: The python module of the API implementation is now called pyinterface (set_api_interface): New function to select an implementation of the DB interface. * Greater/UI/application.py (main): New command line argument to specify the DB API module to use. 2002-08-13 Bernhard Herzog * setup.py (GenerateWrapper.user_options) (GenerateWrapper.initialize_options) (GenerateWrapper.finalize_options): Add oracle-interface-file option to specify the C-api implementation to use. (GenerateWrapper.add_oracle_interface): Method to create the real API wrapper module definition (GenerateWrapper.run): Only generate the real wrapper if the oracle-interface-file options was given. (greater_build): Our own build command to pass the oracle-interface-file through. 2002-08-13 Jan-Oliver Wagner * Greater/Dialogs/opensession.py: added some debug code 2002-08-13 Jan-Oliver Wagner * Greater/Dialogs/authenticate.py: Added third text entry field: Database. Added SPACE for Styleguide compliance. 2002-08-13 Bernhard Herzog * setup.py (GenerateWrapper.run): Generate the files for both the stub implementation and the actual API wrapper. * dbapiwrapper/apispec.py (da_db_connect, da_get_sess): err_type is a simple char now (DA_S_group_priv): Fix spelling of group_priv_id (DA_S_res): river_factor now char[41] (DA_S_group_priv): Add a _priv suffix to create, read, write and delete * dbapiwrapper/genapiwrapper.py (Struct.c_definition): Optionally generate a typedef for the struct as well. (Struct.typedef_name): New method to provide a suitable typedef name (format_c_header): Generate the typedefs for the structs as well. (WrappedFunction.c_method_impl, DBGetFunction.c_method_impl) (DBInsertFunction.c_method_impl, DBUpdateFunction.c_method_impl) (DBDeleteFunction.c_method_impl): Use DA_T_errinfo instead of DA_S_errinfo (WrappedFunction.c_method_impl, DBGetFunction.c_method_impl) (DBGetFunction.c_stub, DBInsertFunction.c_method_impl) (DBUpdateFunction.c_method_impl, DBDeleteFunction.c_method_impl): err_type is a simple char now (read_specification): Only read specification once. (format_api_module): New parameter for additional header files. (generate_wrapper): New parameters to specify whether the c header should actually be written and for additional headers. (DBGetFunction.c_stub): Call the correct function when escaping strings and convert string values to string explicitly because some start as Python numbers 2002-08-13 Bernhard Herzog * Greater/DB/interface.py: New module to select one of the DB api implementations. Use this module to access the interface, not one of the actual implementations. * Greater/Dialogs/opensession.py (OpenSessionDialog.__init__) (OpenSessionDialog.dialog_layout, OpenSessionDialog.EvtListBox), Greater/Modules/substance.py, Greater/Modules/session.py, Greater/Modules/parameter.py, Greater/Modules/model.py, Greater/Modules/discharge.py, Greater/Modules/catchment.py, Greater/Dialogs/selectcatchment.py, Greater/Dialogs/opensubstance.py, Greater/Dialogs/editsession.py (EditSessionDialog.dialog_layout), Greater/Dialogs/authenticate.py: Use the new AB-API interface module 2002-08-13 Jan-Oliver Wagner * Greater/Dialogs/authenticate.py: db_connect: renamed to da_db_connect * Greater/Modules/parameter.py: da_get_phrase replaced by da_get_phrase_grp * Greater/Modules/session.py: removed output of is_templ * dbapiwrapper/genapiwrapper.py: renamed err_code to success and swithed logics accordingly. * dbapiwrapper/apispec.py: renamed db_connect to da_db_connect; fixed forgotten upcase variables STRETCH_ID, SESS_ID to lower case; deactivated da_get_phrase with comment 2002-08-13 Jan-Oliver Wagner * dbapiwrapper/apispec.py: exchange 1 and 0 in all returns; (da_get_group_priv): rename modul to module (da_get_message): disable this function with comment * dbapiwrapper/genapiwrapper.py: exchanged 1 and 0 in all returns 2002-08-12 Bernhard Herzog * dbapiwrapper/genapiwrapper.py (VoidType): Implement a void type (Pointer.parse_tuple_char): New. We have char* function parameters now (DBGetFunction.c_method_impl): The free functions now return void, so don't check their return values. (DBUpdateFunction.struct_parameter_type): There's no errinfo parameter anymore. (DBFreeFunction.c_stub): Don't return a value in the generated code. 2002-08-12 Jan-Oliver Wagner * dbapiwrapper/apispec.py: updated for API 2.3 2002-08-12 Jan-Oliver Wagner * dbapiwrapper/apispec.py: cleaned up stub data for discharges * Greater/Modules/analysis.py: all menus now only active when a session is open; all menus will launch an information dialog 'no implemented' * Greater/Modules/substance.py: new and delete substance now show dialog 'not implemented'. * Greater/Modules/session.py: 'not implemented' dialogs for not implemented menu items; added save as and delete * Greater/Modules/model.py: all menus now only active when a session is open; 'not implemented' dialogs for not implemented menu items * Greater/Modules/catchment.py: renamed a menu item titel * Greater/Modules/discharge.py: removed a discharge parameter; added TODO * doc/greater-manual.tex: renamed a menu item 2002-08-12 Jan-Oliver Wagner * GREAT-ER/dbapiwrapper/apispec.py: renamed market parameter * Greater/Modules/discharge.py: renamed market parameter 2002-08-12 Jan-Oliver Wagner * dbapiwrapper/apispec.py: added market parameters and a missing phrase * Greater/Dialogs/editmarketdata.py: replaced run_editmarketdata_dialog by test_editmarketdata_dialog * Greater/Dialogs/editsession.py: fixed bug (lower case record elements) * Greater/Dialogs/selectcatchment.py: fixed bug (lower case record elements) * Greater/Modules/parameter.py: new function CreateParameter() allows to create scientific parameters even without a detail-Parameter (e.g. as required for discharge site data) * Greater/Modules/discharge.py: now retrieves discharge and market parameter details from database * Greater/Modules/catchment.py: turned edit market data dialog into a tool 2002-08-09 Jan-Oliver Wagner * dbapiwrapper/apispec.py: added model selection parameters to stub * Greater/Modules/model.py: now builds selection dialog with parameter from DB 2002-08-09 Jan-Oliver Wagner * dbapiwrapper/apispec.py: fixed/improved phrases * Greater/Modules/parameter.py(_create_parameter): Now retrieves phrases from database 2002-08-09 Jan-Oliver Wagner * dbapiwrapper/apispec.py: added various model parameters for the stub * Greater/Modules/model.py: model parameters now retrieved from the database 2002-08-09 Jan-Oliver Wagner * Greater/Dialogs/selectmodel.py: replaced run_selectmodel_dialog by test_selectmodel_dialog; import from SciParam now explicit * Greater/Dialogs/editmodelparameter.py: replaced run_editmodelparameter_dialog by test_editmodelparameter_dialog; import from SciParam now explicit * Greater/Modules/model.py: (temporarily) added explicitly parameters for parameter and selection dialogs. All dialog now set 'model.changed(CHANGED)' accordingly. * Greater/Modules/substance.py: removed import of SciParam 2002-08-08 Bernhard Herzog * dbapiwrapper/genapiwrapper.py (format_c_files): Ignore all files that contain "CVS". Open files in binary mode. Make the size of the arrays explicit so that it won't contain an additionall NUL byte. Split long files into several string literals to work around limitations in MSVC * Greater/Modules/catchment.py (CatchmentMap.build_layers): Write the temporary files in binary mode. 2002-08-08 Jan-Oliver Wagner * dbapiwrapper/apispec.py: numerous substance data added to stub; activated phrases * Greater/Modules/parameter.py: added handling of DISTRIB parameters; raw handling of ChoiceParams; group_id now shown in tree; removed some debug-prints; added error-handling for unknown var-types * Greater/Modules/substance.py: now gets all its parameters from the database 2002-08-08 Frank Koormann * simulwrapper/lib/dbfpy/binnum.py, simulwrapper/lib/dbfpy/dbfload.py, simulwrapper/lib/dbfpy/dbfnew.py, simulwrapper/lib/dbfpy/dbf.py, simulwrapper/lib/dbfpy/__init__.py, simulwrapper/lib/dbfpy/strutil.py, simulwrapper/lib/dbfpy/CHANGES, simulwrapper/lib/dbfpy/README: dbfpy Module (http://www.fiby.at/dbfpy/index.html) added. * simulwrapper/simul/greater_simul.py, simulwrapper/simul/io_core.py, simulwrapper/simul/io_dbf.py: GREAT-ER 1.0 simulator wrapper added. * simulwrapper/simul/simul, simulwrapper/simul/simul.exe: GREAT-ER 1.0 simulator binaries added. 2002-08-08 Thomas Koester * doc/gui_styleguide.tex: added * doc/gui_styleguide.tex: Yes, No, Cancel is a valid combination of buttons, too. 2002-08-07 Jan-Oliver Wagner * dbapiwrapper/apispec.py, dbapiwrapper/genapiwrapper.py: updated according to API Spec 2.2 v2 * Greater/Modules/substance.py, Greater/Modules/catchment.py, Greater/Modules/parameter.py, Greater/Modules/recordwrapper.py, Greater/Modules/session.py, Greater/Modules/discharge.py, Greater/Modules/model.py, Greater/Dialogs/opensession.py: made compliant with API Spec 2.2 v2 (record elements now lower case) 2002-08-05 Bernhard Herzog * dbapiwrapper/genapiwrapper.py (format_c_files): Make the strings static but non-const (non-const to avoid lots of compiler warnings). * Greater/Modules/parameter.py (Parameter.TreeInfo): Take the tree info items from the parameter object so that it reflects the values the user entered. * Greater/Modules/substance.py (edit_substance): Use the public method to get the substance 2002-08-01 Jan-Oliver Wagner * dbapiwrapper/apispec.py: added parameter MC_SHOTS, added specific C stub for da_get_mod_det. Greater/Dialogs/mcshots.py (run_mc_shots_dialog): replaced by test_mc_shots_dialog * Greater/Modules/parameter.py: added handling of VAR_TYPE INT. Now also considers default values. * Greater/Modules/model.py: added handling of MC-Shots 2002-07-31 Jan-Oliver Wagner * dbapiwrapper/apispec.py: more stub data and c_body * Dialogs/backgroundconcentration.py: replaced run_background_concentration_dialog by test_background_concentration_dialog * Greater/Modules/session.py: added class element model * Greater/Modules/model.py: added class Model * Greater/Modules/parameter.py: now retrievs parameter description from DB; extended tree info 2002-07-30 Bernhard Herzog * Greater/UI/application.py (main): Parse command line options. Only one option so far: --stub-auto-login to ease testing. * Greater/Modules/catchment.py (CatchmentMap.clear_layers) (CatchmentMap.build_layers): Removed clear_layers. It's now implemented in the base class under the name ClearLayers. * Greater/UI/application.py (GreaterApplication.OnExit, main): OnExit is now handled in Thuban. 2002-07-30 Jan-Oliver Wagner * dbapiwrapper/apispec.py: added some DA_S_subst_det stubs, explicit c_body for da_get_subst_det * Greater/Modules/parameter.py: new * Greater/Modules/substance.py: added handling of parameters (work not finished) * Greater/Modules/catchment.py: discharges in tree now at last; edit_dischargedata_dialog: renamed to edit_dischargedata_tool * Greater/Dialogs/editdischargedata.py: run_editdischargedata_dialog removed. some clean-ups * Greater/Dialogs/editsubstance.py: run_editsubstance_dialog removed. some clean-ups 2002-07-30 Jan-Oliver Wagner * dbapiwrapper/apispec.py: explicit c_body for da_get_disch * Greater/Modules/discharge.py: new * Greater/Modules/catchment.py: added handling of discharges * Greater/Dialogs/editdischargedata.py (run_editdischargedata_dialog): now receives discharge object to use for the dialog * Greater/Dialogs/editdischargedata.py (test_editdischargedata_dialog): former run_editdischargedata_dialog, but now always outputs debug info 2002-07-29 Bernhard Herzog * Greater/Modules/session.py (open_authenticate, session): Remove debug prints. * Greater/Modules/catchment.py (CatchmentMap.clear_layers): Don't loop over a list while modifying it. * Greater/UI/application.py (main): Switch positions of Substance and Catchment menus * Greater/Modules/model.py (init_menu): Swich positions of Model and Simulation menus * Greater/UI/application.py (GreaterApplication.OnExit, main): New cleanup method that has to be called in main. * Greater/Modules/recordwrapper.py (RecordWrapper.__init__): Call the base class' constructor as well. * Greater/Modules/catchment.py: Rework the tempfile handling. Now we create one temporary directory in which all our files will be placed. (CatchmentMap.__init__): New instance variable temp_dir. (CatchmentMap.remove_temp_dir): New method to remove the temporary directory and all the files in it. (CatchmentMap.Destroy, CatchmentMap.__del__): Make sure the temp dir is removed. (CatchmentMap.make_temp_dir): Create the temporary directory. (CatchmentMap.build_layers): Create the temporary files in the temoprary directory. Bind the layer with the discharges to an instance variable so that we can easily refer to it. (CatchmentMap.DischargeLayer): New method to return the layer containing the discharges. (EditTool): New tool to select a shape and start a dialog. (start_edit_tool): Helper function to start the edit tool (edit_dischargedata): This command now starts the edit tool which later runs the dialog. (edit_dischargedata_dialog): Helper function for edit_dischargedata to run the dialog 2002-07-29 Jan-Oliver Wagner * dbapiwrapper/genapiwrapper.py, dbapiwrapper/apispec.py: update according to new API 2.2 * Greater/Modules/catchment.py: replaced calls of da_get_bin_obj_file by new version of da_get_bin_obj (as required by new API 2.2) 2002-07-29 Jan-Oliver Wagner * dbapiwrapper/apispec.py: added stub-data for discharges * dbapiwrapper/apispec.py: added Ems as second demo catchment * dbapiwrapper/stub_files/ems/*: new 2002-07-26 Bernhard Herzog * dbapiwrapper/genapiwrapper.py (format_c_files): Fix glob pattern to not match the CVS subdirectories * Greater/Modules/substance.py: Make the menu items available only when a session is open 2002-07-26 Jan-Oliver Wagner * Greater/Modules/session.py (SimulationSession.TreeInfo): more verbose * Greater/Modules/catchment.py (Catchment.TreeInfo): more verbose * Greater/Modules/catchment.py (CatchmentMap.build_layers): now gets all layer files from the db api. * setup.py (GenerateWrapper.run): added handling of cfiles * dbapiwrapper/stub_files/*: new * dbapiwrapper/genapiwrapper.py: new arg cfiles * dbapiwrapper/genapiwrapper.py (make_escapes, escape, format_c_files): new * dbapiwrapper/genapiwrapper.py (DBGetFunction:c_stub): explicit treatment of FILE * dbapiwrapper/genapiwrapper.py (Pointer:py_from_c): explicit treatment of FILE * dbapiwrapper/apispec.py (DA_S_catch): replaced Aire by Hase. * dbapiwrapper/apispec.py (DA_S_bin_obj, DA_S_bin_obj_file): Added 4 shapefile layers for Hase (12 files in total). * dbapiwrapper/apispec.py (da_get_bin_obj, da_get_bin_obj_file): explicit c_body's. 2002-07-25 Bernhard Herzog * Greater/Dialogs/opensession.py (CommentBox): Removed. Use the one in widgets now. * Greater/Dialogs/widgets.py (CommentBox): New implementation of CommentBox * Greater/Dialogs/selectcatchment.py, Greater/Dialogs/opensubstance.py, Greater/Dialogs/opensession.py: Use the new CommentBox from widget * Greater/Dialogs/opensubstance.py (OpenSubstanceDialog.dialog_layout): Add the comment box. (OpenSubstanceDialog.EvtListBox): New method to update the comment box. * Greater/Dialogs/selectcatchment.py (SelectCatchmentDialog.dialog_layout): Add the comment box. (SelectCatchmentDialog.EvtListBox): New method to update the comment box. * Greater/Modules/catchment.py (CatchmentMap): Fix spelling of CatchmentMap. Update the places where it's used. * Greater/UI/session.py (GreaterSession.rebind): Also subscribe child_changed to the CHANGED channel. (GreaterSession.child_changed): New method to call update_map whenever the simulation session has changed (GreaterSession.update_map): New. Create or update the map. * Greater/Modules/catchment.py: Some code rearrangements. (CatchmentMap): New class for the map associated with a catchment. * Greater/UI/session.py (context_session_open, context_db_open), * Greater/UI/context.py (context_session_open, context_db_open): Move these functions to a separate module to avoid circular imports. Update the modules importing these functions. 2002-07-25 Jan-Oliver Wagner * Greater/Modules/model.py: now calling select model dlg * Greater/Dialogs/selectmodel.py: new * doc/greater-manual.tex: finished menu model * doc/screenshots/editmodelparameters-dlg-as.eps: new * doc/screenshots/editmodelparameters-dlg-environment.eps: new * doc/screenshots/editmodelparameters-dlg-primary.eps: new * doc/screenshots/editmodelparameters-dlg-river.eps: new * doc/screenshots/editmodelparameters-dlg-secondary.eps: new * doc/screenshots/editmodelparameters-dlg-sewer.eps: new * doc/screenshots/editmodelparameters-dlg-wwtp.eps: new * doc/screenshots/selectmodel-dlg-as.eps: new * doc/screenshots/selectmodel-dlg-sewer.eps: new * doc/screenshots/selectmodel-dlg-river.eps: new * doc/screenshots/selectmodel-dlg-tf.eps: new 2002-07-24 Jan-Oliver Wagner * Greater/Dialogs/editmodelparameter.py: completed refinement of parameters 2002-07-24 Bernhard Herzog * Greater/UI/application.py (GreaterApplication.CreateMainWindow): Set the inital window size to something more useful for Greater. 2002-07-23 Bernhard Herzog * Greater/Dialogs/opensubstance.py (OpenSubstanceDialog.dialog_layout): Remove some debug prints * Greater/UI/application.py (main): Put the GREAT-ER commands into the menu * Greater/__init__.py (main): All that's left to do here is to call UI.application.main * Greater/Modules/analysis.py (init_menu): * Greater/Modules/catchment.py (init_menu): * Greater/Modules/model.py (init_menu ): * Greater/Modules/substance.py (init_menu): Put the menu initialization into separate functions to get more control over when and in which order the menus are added. * Greater/Modules/session.py (replace_file_menu, init_menu): Rename replace_file_menu to init_menu 2002-07-23 Jan-Oliver Wagner * doc/screenshots/backgroundconcentration-dlg.eps: new * doc/screenshots/mcshots-dlg.eps: new * doc/greater-manual.tex: further menu documentation (model&simulation) * Greater/Dialogs/editmodelparameter.py: refined some parameters * Greater/Dialogs/backgroundconcentration.py: fixed typo * Greater/Dialogs/editmarketdata.py: refined parameter entries * Greater/Dialogs/editdischargedata.py: refined parameter entries * doc/screenshots/editmarketdata-dlg.eps: new * doc/screenshots/editdischargedata-dlg: new * doc/greater-manual.tex: completed menu catchment * Greater/Dialogs/editsubstance.py: refined all parameter entries * doc/screenshots/substance-dlg-degradation.eps: new * doc/screenshots/substance-dlg-identification.eps: new * doc/screenshots/substance-dlg-instreamremoval.eps: new * doc/screenshots/substance-dlg-marketinformation.eps: new * doc/screenshots/substance-dlg-partitioning.eps: new * doc/screenshots/substance-dlg-physicochemical.eps: new * doc/screenshots/substance-dlg-sewagetreatmentremoval.eps: new * doc/greater-manual.tex: further work on substance menu, started catchment menu 2002-07-23 Bernhard Herzog * Greater/UI/application.py (GreaterApplication.CreateMainWindow): Override this method to change the title and omit the initial statusbar message * Greater/UI/session.py (context_session_open, context_db_open): New functions for use as sensitivity callbacks * Greater/Modules/session.py (SimulationSession.rebind): Call changed. (db_connection_open, can_edit_session): Removed. Use context_session_open and context_db_open instead * Greater/Dialogs/selectcatchment.py (run_selectcatchment_dialog, SelectCatchmentDialog.__init__): New parameter for the initial catchment. (SelectCatchmentDialog.dialog_layout): select the intial value. (SelectCatchmentDialog.EvtListBoxDClick): Simply call OnOK (SelectCatchmentDialog.OnOK): We only need to handle the OK part. * Greater/Dialogs/opensubstance.py (OpenSubstanceDialog.__init__, run_opensubstance_dialog): New parameter for the initial value. (OpenSubstanceDialog.dialog_layout): Select the initial substance. (OpenSubstanceDialog.EvtListBoxDClick): Simply call OnOK (OpenSubstanceDialog.OnOK): We only need to handle the OK part. * Greater/Modules/catchment.py: Add sensitivity callbacks to the commands (select_catchment): We can now just call the session's SetCatchment method * Greater/Modules/substance.py (open_substance): We can now just call the session's SetSubstance method 2002-07-22 Jan-Oliver Wagner * Greater/Dialogs/editsubstance.py: params of some pages more precisely defined * doc/greater-manual.tex: first texts for menu substance. 2002-07-22 Bernhard Herzog * Greater/Modules/recordwrapper.py: New module with a base class for the classes that extend the records returned by the DB API * Greater/Modules/catchment.py (Catchment): Completely different now. Derived from RecordWrapper * Greater/Modules/substance.py (Substance): Completely different now. Derived from RecordWrapper * Greater/Modules/session.py (SimulationSession): Substantial extensions. SimulationSession is now derived from RecordWrapper and allows modifying various parts of a session such as substance, catchment etc. (can_edit_session, edit_session): Implement new command greater_edit_session (replace_file_menu): Add the greater_edit_session command * Greater/Dialogs/editsession.py (EditCommentBox.GetValue): New method to return the current content of the box (EditSessionDialog.__init__): New arguments for the start values to use in the editor. Correct the title (EditSessionDialog.dialog_layout): Fill the controls with the correct initial values (EditSessionDialog.OnOK): Build a meaningful result value (run_editsession_dialog): Accept the initial values and pass them on to hte dialog * Greater/UI/session.py (GreaterSession.rebind): New method to make it easier to manage subscriptions to child object's channels (GreaterSession.SetSimulationSession): rebind channels (GreaterSession.SimulationSession): New accessor method 2002-07-22 Jan-Oliver Wagner * Greater/Modules/substance.py: rearranged menu * doc/screenshots/sessioninfotree-win.eps: new * doc/greater-manual.tex: completed Menu Session 2002-07-19 Bernhard Herzog * Greater/UI/session.py (GreaterSession.TreeInfo): New. Extend the tree items with the db-connection and the simulation session (GreaterSession.SetSimulationSession) (GreaterSession.SetDBConnection): Call self.changed * Greater/Modules/session.py (DBConnection.TreeInfo): New. (SimulationSession): New class wrapping the DA_S_sess record. * Greater/Dialogs/opensession.py (OpenSessionDialog.EvtListBoxDClick) (OpenSessionDialog.OnOK): Use the entire struct as the result of the dialog and not just the ID 2002-07-19 Jan-Oliver Wagner * Greater/Dialogs/editsession.py: new * doc/greater-manual.tex: further text on session menu * doc/screenshots/editsession-dlg.eps: new 2002-07-19 Bernhard Herzog * Greater/UI/application.py (GreaterApplication.create_session): Fix a typo that caused a SyntaxError * Greater/UI/session.py: New module with a GREAT-ER specific Thuban session * Greater/UI/application.py (GreaterApplication.create_session): New method to create a greater session in stead of the standard thuban session * Greater/Modules/session.py (DBConnection): New class representing an open GREAT-ER DB connection (db_connection_open): New function usable as the sensitivity callback in command objects. Use it in the command instances for greater_new_session, greater_open_session and greater_save_session * doc/greater-manual.tex (subsection{Open Session}): Fix typo 2002-07-19 Jan-Oliver Wagner * dbapiwrapper/apispec.py: added sample stub_data for ListStructs * dbapiwrapper/genapiwrapper.py (DBGetFunction): now generates entries from stub_data and handles requests for certain elements * Greater/Dialogs/opensession.py: now handles session browsing and returns session id * doc/greater-manual.tex: added section for menu item Open Session * doc/screenshots/opensession-dlg.eps: new 2002-07-18 Bernhard Herzog * Greater/UI: New package for the more generic UI code * Greater/UI/application.py: New. Application class for GREAT-ER * Greater/__init__.py: Add some CVS keywords. (main): Use the Greater application now. * Greater/Modules/session.py (open_session): Execute the dialog 2002-07-18 Jan-Oliver Wagner * Greater/Dialogs/authenticate.py: wrong userid now raises error message * dbapiwrapper/apispec.py: updated according to API spec 2.1 * dbapiwrapper/genapiwrapper.py (DBFreeFunction): removed second basetype as required for API spec 2.1 * Greater/Dialogs/opensession.py: new 2002-07-18 Bernhard Herzog * Greater/Modules/substance.py (open_substance, edit_substance), Greater/Modules/session.py (authenticate), Greater/Modules/model.py (edit_modelparameter, background_concentration, mc_shots), Greater/Modules/catchment.py (select_catchment, edit_marketdata, edit_dischargedata): Handle the new context implementation of Thuban 2002-07-18 Thomas Koester * Greater/Dialogs/backgroundconcentration.py, Greater/Dialogs/editdischargedata.py, Greater/Dialogs/editmarketdata.py, Greater/Dialogs/editmodelparameter.py, Greater/Dialogs/editsubstance.py, Greater/Dialogs/mcshots.py: from SciParam import * 2002-07-17 Jan-Oliver Wagner * doc: New directory with a raw manual skeleton. * dbapiwrapper/genapiwrapper.py (Function and WrappedFunction): added alternative insertion of a specified C body * dbapiwrapper/apispec.py: added a stub behaviour for db_connect * Greater/Dialogs/authenticate.py (AuthenticateDialog): added use of db api stub 2002-07-17 Thomas Koester * Greater/Dialogs/editsubstance.py, Greater/Dialogs/editdischargedata.py, Greater/Dialogs/editmarketdata.py, Greater/Dialogs/editmodelparameter.py: seperated parameter list from dialog function; changed parameter list to use new classes. 2002-07-17 Bernhard Herzog * Greater/Modules/session.py (replace_file_menu): Add commands show_session_tree and exit (authenticate): Run the authenticate dialog * Greater/Modules/session.py: Add some CVS keywords 2002-07-16 Bernhard Herzog * Greater/__init__.py: Don't use * in import statement (main): New. Main function for GREAT-ER. * GREAT-ER.py: All GREAT-ER initialization is now in Greater/__init__.py * Greater/Modules/session.py: New module for the commands in the File/Session menu * dbapiwrapper/genapiwrapper.py (WrappedFunction.py_wrapper): New method so that all functions are available in the python module as well. 2002-07-16 Thomas Koester * Greater/Dialogs/mcshots.py: use IntParam and seperated parameter list from dialog function 2002-07-16 Jan-Oliver Wagner * Greater/Dialogs/selectcatchment.py: now uses DB.stub_interface * Greater/Dialogs/opensubstance.py: now uses DB.stub_interface * Greater/DB/api_stub.py: removed * Greater/Dialogs/widgets.py: removed import of api_stub * Greater/Dialogs/authenticate.py: new 2002-07-15 Thomas Koester * Greater/Dialogs/editmarketdata.py, Greater/Dialogs/editdischargedata.py: import SciParam.control instead of SciParam.notebook. * Greater/Dialogs/mcshots.py: use IntParameter class. 2002-07-15 Bernhard Herzog * dbapiwrapper/README, dbapiwrapper/apispec.py, dbapiwrapper/genapiwrapper.py, dbapiwrapper/parse_struct_spec.py, dbapiwrapper/parse_function_proto.py: New files to generate the DB API wrapper. * setup.py, setup.cfg: Distutils setup. So far it can only build the db api wrapper. 2002-07-15 Jan-Oliver Wagner * Greater/Dialogs/mcshots.py: new * Greater/Dialogs/backgroundconcentration.py: new * Greater/Modules/model.py: added call of dialogs mcshots and backgroundconcentration * Greater/__init__.py, Greater/Modules/catchment.py, Greater/Modules/substance.py, greater.py: Moved contents of greater.py to Greater.__init__.py and removed greater.py 2002-07-11 Jan-Oliver Wagner * Greater/Dialogs/editdischargedata.py: improved default definition for parameters 2002-07-11 Thomas Koester * Greater/Dialogs/selectcatchment.py (run_selectcatchment_dialog): call dialog.Destroy() to end _test application * Greater/Dialogs/widgets.py (wxFindPrefixListBox): ripped from selectcatchment.py to be used by other dialogs * Greater/Dialogs/selectcatchment.py, Greater/Dialogs/opensubstance.py: use wxFindPrefixListBox from widgets.py * Greater/Dialogs/opensubstance.py: prepared for running dialog on its own for tests * Greater/Dialogs/editdischargedata.py: added input fields * Greater/Dialogs/editmarketdata.py: added as copy of editdischargedata.py * Greater/Dialogs/editmodelparameter.py: added as copy of editsubstance.py * Greater/Modules/catchment.py: activated editmarketdata * Greater/Modules/model.py: activated editmodelparameter * Greater/Dialogs/editmodelparameter.py: two pages of input fields * Greater/Dialogs/editdischargedata.py, editmarketdata.py, editmodelparameter.py, editsubstance.py: show debug output only when started as script 2002-07-11 Jan-Oliver Wagner * Greater/Dialogs/selectcatchment.py: prepared for running dialog on its own for tests 2002-07-11 Jan-Oliver Wagner * Greater/Dialogs/selectcatchment.py: prepared for running dialog on its own for tests 2002-07-10 Jan-Oliver Wagner * ChangeLog: started