Commit Graph

24 Commits

Author SHA1 Message Date
amercader 4c81c7c3a7 [#1726][model] Harvest source reference compatibility
The 'source' property of harvest objects now comes from the actual
foreign key. For compatibility with old harvesters, an before insert
event listener has beeen added to check if the source id has been set,
and set it automatically from the job if not.
Note that this requires SQLAlchemy 0.7 (ie CKAN 1.5.1)
2012-02-01 12:52:52 +00:00
amercader 004210935a [model] Avoid unicode warning 2012-02-01 11:10:44 +00:00
amercader b64d97118c [#1726][model] Add scripts for populating source_id and current fields 2012-02-01 11:08:41 +00:00
amercader d1783f5415 [model] Changes in harvest model
Added three changes to the harvest model:

 * 'title' column in harvest_source table
 * 'current' column in harvest_job table
 * foreign key from harvest_object to harvest_source

Tables are checked on startup to see if they need to be updated.
TODO: populate current and harvest_source_id fields
2012-01-30 18:38:35 +00:00
amercader f086e908bc [model] Clearer table initialization 2012-01-30 17:09:28 +00:00
David Read dd00e98d9d [model]: More careful about creating tables, since paster db upgrade loads the envrionment and therefore runs setup() before it does the migrations, and therefore in this instance we do not want to create the db tables. 2011-08-10 16:25:57 +01:00
Friedrich Lindenberg 0d9d1f8096 reduce number of queries for harvest index to a less insane number. still heavy. 2011-06-13 17:36:35 +02:00
David Raznick 264b606c48 take tables out of global scope at import time 2011-05-31 18:02:07 +01:00
Adrià Mercader bbe459527f [forms] Major refactoring of the harvest forms. Forms no longer use the DGU form
API, and are handled similarly to the new ones on CKAN core (logic, schema,
validators...). The UI is also more consistent with the CKAN one.
2011-05-13 14:17:58 +01:00
Adrià Mercader 26cdc1089d Change date definitions in Harvest Objects. reference_date -> metadata_modified_date, created -> gathered 2011-05-11 17:07:05 +01:00
Adrià Mercader 329ca2dd29 Add a reference date to the Harvest Objects. This must be set during the harvest
process.
2011-05-10 11:05:44 +01:00
Adrià Mercader e3a83ea14d Source URL not unique 2011-04-15 18:28:38 +01:00
David Raznick 9018beeedb use create_all instead of create 2011-04-15 12:19:24 +01:00
Adrià Mercader e2faa14b8d [refactoring] Save gathering starting and finishing time 2011-04-11 16:29:47 +01:00
Adrià Mercader 2588352bc5 [refactoring] Simplify model relations 2011-04-08 16:48:29 +01:00
Adrià Mercader 90ae9d27db [refactoring] Tweaks in the model and a setup function to create the tables 2011-04-07 16:57:36 +01:00
Adrià Mercader 4023bb7222 [refactoring] Use the common functions in the web interface.
Not yet implemented in create and edit harvest source as they use the DGU forms API.
Also TODO, think of what report info is needed in the listing and details page.
2011-04-05 13:39:23 +01:00
Adrià Mercader dca4ff328f [refactoring] Add missing column in error table 2011-04-05 12:53:36 +01:00
Adrià Mercader a4d93e4ad3 [refactoring] Add a reference to objects from jobs 2011-04-05 12:36:27 +01:00
Adrià Mercader ce86cfde1b [refactoring] Clean up the model definitions 2011-04-05 11:51:59 +01:00
Adrià Mercader d3f06b7b4f [refactoring] Changes in model 2011-03-30 16:55:42 +01:00
Adrià Mercader 0396838e36 [refactoring] First version of the new model 2011-03-30 14:42:59 +01:00
Adrià Mercader 57631a8931 Use the projection from harvested documents. Add a configure option to define the database projection 2011-03-18 17:42:43 +00:00
Adrià Mercader c2bfdd16fc #1030 Move harvesting model to ckanext-harvest 2011-03-14 15:19:58 +00:00