enju_biblio 0.1.0.pre42 → 0.1.0.pre43

Sign up to get free protection for your applications and to get access to all the features.
Files changed (319) hide show
  1. checksums.yaml +4 -4
  2. data/app/controllers/creates_controller.rb +11 -11
  3. data/app/controllers/items_controller.rb +3 -3
  4. data/app/controllers/manifestations_controller.rb +14 -14
  5. data/app/controllers/owns_controller.rb +10 -10
  6. data/app/controllers/patron_import_files_controller.rb +34 -34
  7. data/app/controllers/patron_import_results_controller.rb +5 -5
  8. data/app/controllers/patron_relationship_types_controller.rb +3 -3
  9. data/app/controllers/patron_relationships_controller.rb +7 -7
  10. data/app/controllers/patron_types_controller.rb +3 -3
  11. data/app/controllers/patrons_controller.rb +61 -61
  12. data/app/controllers/picture_files_controller.rb +4 -4
  13. data/app/controllers/produces_controller.rb +11 -11
  14. data/app/controllers/realizes_controller.rb +11 -11
  15. data/app/helpers/{patrons_helper.rb → agents_helper.rb} +5 -5
  16. data/app/models/{patron.rb → agent.rb} +36 -36
  17. data/app/models/{patron_import_file.rb → agent_import_file.rb} +77 -77
  18. data/app/models/agent_import_result.rb +26 -0
  19. data/app/models/{patron_relationship.rb → agent_relationship.rb} +7 -7
  20. data/app/models/{patron_relationship_type.rb → agent_relationship_type.rb} +4 -4
  21. data/app/models/{patron_sweeper.rb → agent_sweeper.rb} +6 -6
  22. data/app/models/{patron_type.rb → agent_type.rb} +4 -4
  23. data/app/models/country.rb +1 -1
  24. data/app/models/create.rb +7 -7
  25. data/app/models/donate.rb +5 -5
  26. data/app/models/enju_biblio/ability.rb +24 -24
  27. data/app/models/item.rb +5 -5
  28. data/app/models/item_sweeper.rb +2 -2
  29. data/app/models/manifestation.rb +24 -20
  30. data/app/models/own.rb +7 -7
  31. data/app/models/page_sweeper.rb +4 -4
  32. data/app/models/picture_file.rb +1 -1
  33. data/app/models/produce.rb +7 -7
  34. data/app/models/realize.rb +7 -7
  35. data/app/models/resource_import_file.rb +19 -19
  36. data/app/views/{patron_import_files → agent_import_files}/edit.html.erb +6 -6
  37. data/app/views/agent_import_files/index.html.erb +40 -0
  38. data/app/views/{patron_import_files → agent_import_files}/new.html.erb +3 -3
  39. data/app/views/agent_import_files/show.html.erb +69 -0
  40. data/app/views/agent_import_results/index.csv.erb +3 -0
  41. data/app/views/agent_import_results/index.html.erb +52 -0
  42. data/app/views/agent_import_results/show.html.erb +38 -0
  43. data/app/views/{patron_relationship_types → agent_relationship_types}/_form.html.erb +1 -1
  44. data/app/views/{patron_relationship_types → agent_relationship_types}/edit.html.erb +3 -3
  45. data/app/views/agent_relationship_types/index.html.erb +43 -0
  46. data/app/views/{patron_relationship_types → agent_relationship_types}/new.html.erb +2 -2
  47. data/app/views/agent_relationship_types/show.html.erb +29 -0
  48. data/app/views/{patron_relationships → agent_relationships}/_form.html.erb +7 -7
  49. data/app/views/{patron_relationships → agent_relationships}/edit.html.erb +3 -3
  50. data/app/views/agent_relationships/index.html.erb +34 -0
  51. data/app/views/{patron_relationships → agent_relationships}/new.html.erb +2 -2
  52. data/app/views/agent_relationships/show.html.erb +24 -0
  53. data/app/views/{patron_types → agent_types}/_form.html.erb +1 -1
  54. data/app/views/{patron_types → agent_types}/edit.html.erb +3 -3
  55. data/app/views/agent_types/index.html.erb +43 -0
  56. data/app/views/{patron_types → agent_types}/new.html.erb +2 -2
  57. data/app/views/agent_types/show.html.erb +29 -0
  58. data/app/views/{patrons → agents}/_expression_list.html.erb +3 -3
  59. data/app/views/{patrons → agents}/_form.html.erb +9 -9
  60. data/app/views/{patrons → agents}/_form_family_name_first.html.erb +0 -0
  61. data/app/views/{patrons → agents}/_form_family_name_last.html.erb +0 -0
  62. data/app/views/{patrons → agents}/_history_list.html.erb +2 -2
  63. data/app/views/{patrons → agents}/_index.html.erb +9 -9
  64. data/app/views/{patrons → agents}/_index_expression.html.erb +15 -15
  65. data/app/views/{patrons → agents}/_index_manifestation.html.erb +16 -16
  66. data/app/views/agents/_index_patron.html.erb +71 -0
  67. data/app/views/agents/_index_patron_merge_list.html.erb +53 -0
  68. data/app/views/{patrons → agents}/_index_work.html.erb +17 -17
  69. data/app/views/{patrons → agents}/_manifestation_list.html.erb +3 -3
  70. data/app/views/agents/_patron.html.erb +13 -0
  71. data/app/views/agents/_patron_list.html.erb +18 -0
  72. data/app/views/{patrons → agents}/_work_list.html.erb +1 -1
  73. data/app/views/agents/edit.html.erb +16 -0
  74. data/app/views/agents/index.atom.builder +10 -0
  75. data/app/views/{patrons → agents}/index.html.erb +4 -4
  76. data/app/views/{patrons → agents}/index.mobile.erb +5 -5
  77. data/app/views/{patrons → agents}/index.rss.builder +11 -11
  78. data/app/views/{patrons → agents}/new.html.erb +2 -2
  79. data/app/views/agents/show.html.erb +152 -0
  80. data/app/views/{patrons → agents}/show.js.erb +0 -0
  81. data/app/views/agents/show.mobile.erb +69 -0
  82. data/app/views/creates/_form.html.erb +5 -5
  83. data/app/views/creates/_index.html.erb +2 -2
  84. data/app/views/creates/_index_patron.html.erb +6 -6
  85. data/app/views/creates/_index_work.html.erb +2 -2
  86. data/app/views/creates/index.html.erb +2 -2
  87. data/app/views/creates/new.html.erb +3 -3
  88. data/app/views/creates/show.html.erb +4 -4
  89. data/app/views/donates/edit.html.erb +2 -2
  90. data/app/views/donates/index.html.erb +2 -2
  91. data/app/views/donates/new.html.erb +2 -2
  92. data/app/views/donates/show.html.erb +2 -2
  93. data/app/views/items/index.html.erb +1 -1
  94. data/app/views/languages/index.html.erb +1 -1
  95. data/app/views/layouts/patrons.html.erb +2 -2
  96. data/app/views/manifestations/_index_form_contributor.html.erb +1 -1
  97. data/app/views/manifestations/_index_form_creator.html.erb +1 -1
  98. data/app/views/manifestations/_index_form_publisher.html.erb +1 -1
  99. data/app/views/manifestations/_manifestation_list.html.erb +6 -6
  100. data/app/views/manifestations/_show.mods.builder +4 -4
  101. data/app/views/manifestations/_show.rdf.builder +4 -4
  102. data/app/views/manifestations/_show_creators.html.erb +4 -4
  103. data/app/views/manifestations/_show_creators.mobile.erb +4 -4
  104. data/app/views/manifestations/_title.html.erb +3 -3
  105. data/app/views/manifestations/_title.mobile.erb +3 -3
  106. data/app/views/manifestations/edit.html.erb +2 -2
  107. data/app/views/manifestations/index.atom.builder +2 -2
  108. data/app/views/manifestations/index.html.erb +3 -3
  109. data/app/views/manifestations/index.opds.builder +2 -2
  110. data/app/views/manifestations/index.sru.builder +6 -6
  111. data/app/views/manifestations/new.html.erb +2 -2
  112. data/app/views/notifier/manifestation_info.en.text.erb +1 -1
  113. data/app/views/notifier/manifestation_info.ja.text.erb +1 -1
  114. data/app/views/owns/_form.html.erb +1 -1
  115. data/app/views/owns/index.html.erb +2 -2
  116. data/app/views/owns/show.html.erb +4 -4
  117. data/app/views/picture_files/_index.html.erb +1 -1
  118. data/app/views/picture_files/_index_patron.html.erb +2 -2
  119. data/app/views/picture_files/index.html.erb +2 -2
  120. data/app/views/picture_files/show.html.erb +2 -2
  121. data/app/views/produces/_form.html.erb +5 -5
  122. data/app/views/produces/_index.html.erb +2 -2
  123. data/app/views/produces/_index_manifestation.html.erb +3 -3
  124. data/app/views/produces/_index_patron.html.erb +3 -3
  125. data/app/views/produces/index.html.erb +2 -2
  126. data/app/views/produces/new.html.erb +3 -3
  127. data/app/views/produces/show.html.erb +4 -4
  128. data/app/views/realizes/_form.html.erb +5 -5
  129. data/app/views/realizes/_index.html.erb +2 -2
  130. data/app/views/realizes/_index_expression.html.erb +3 -3
  131. data/app/views/realizes/_index_patron.html.erb +3 -3
  132. data/app/views/realizes/index.html.erb +2 -2
  133. data/app/views/realizes/new.html.erb +3 -3
  134. data/app/views/realizes/show.html.erb +4 -4
  135. data/app/views/resource_import_results/show.html.erb +1 -1
  136. data/config/routes.rb +16 -16
  137. data/db/migrate/{001_create_patrons.rb → 001_create_agents.rb} +8 -8
  138. data/db/migrate/012_create_owns.rb +2 -2
  139. data/db/migrate/015_create_creates.rb +2 -2
  140. data/db/migrate/047_create_produces.rb +2 -2
  141. data/db/migrate/125_create_donates.rb +2 -2
  142. data/db/migrate/20080830154109_create_realizes.rb +2 -2
  143. data/db/migrate/{20080905191442_create_patron_types.rb → 20080905191442_create_agent_types.rb} +2 -2
  144. data/db/migrate/20081028083142_create_agent_import_files.rb +22 -0
  145. data/db/migrate/{20090812151902_create_patron_relationship_types.rb → 20090812151902_create_agent_relationship_types.rb} +2 -2
  146. data/db/migrate/20091012101112_add_dcndl_schema.rb +2 -2
  147. data/db/migrate/20100606073747_create_agent_relationships.rb +13 -0
  148. data/db/migrate/20100814091104_add_position_to_agent_relationship.rb +11 -0
  149. data/db/migrate/20100925074559_create_agent_import_results.rb +12 -0
  150. data/db/migrate/20110301121550_add_birth_date_and_death_date_to_agent.rb +11 -0
  151. data/db/migrate/20120413161403_add_fingerprint_to_agent_import_file.rb +5 -0
  152. data/db/migrate/20120413170720_add_error_message_to_agent_import_file.rb +5 -0
  153. data/db/migrate/20120511072422_add_agent_identifier_to_agent.rb +6 -0
  154. data/db/migrate/20120602141129_add_edit_mode_to_agent_import_file.rb +5 -0
  155. data/lib/enju_biblio/biblio_helper.rb +8 -8
  156. data/lib/enju_biblio/version.rb +1 -1
  157. data/lib/enju_biblio.rb +3 -3
  158. data/lib/generators/enju_biblio/setup/templates/db/fixtures/patron_relationship_types.yml +3 -3
  159. data/lib/generators/enju_biblio/setup/templates/db/fixtures/patron_types.yml +2 -2
  160. data/lib/generators/enju_biblio/setup/templates/db/fixtures/patrons.yml +4 -4
  161. data/spec/controllers/agent_import_files_controller_spec.rb +321 -0
  162. data/spec/controllers/{patron_import_results_controller_spec.rb → agent_import_results_controller_spec.rb} +17 -17
  163. data/spec/controllers/agent_relationship_types_controller_spec.rb +445 -0
  164. data/spec/controllers/agent_relationships_controller_spec.rb +446 -0
  165. data/spec/controllers/agent_types_controller_spec.rb +447 -0
  166. data/spec/controllers/agents_controller_spec.rb +644 -0
  167. data/spec/controllers/countries_controller_spec.rb +1 -1
  168. data/spec/controllers/items_controller_spec.rb +4 -4
  169. data/spec/controllers/manifestation_relationship_types_controller_spec.rb +1 -1
  170. data/spec/controllers/manifestations_controller_spec.rb +4 -4
  171. data/spec/controllers/owns_controller_spec.rb +2 -2
  172. data/spec/controllers/resource_import_files_controller_spec.rb +1 -1
  173. data/spec/dummy/app/helpers/application_helper.rb +5 -222
  174. data/spec/dummy/app/models/ability.rb +31 -31
  175. data/spec/dummy/app/models/{local_patron.rb → local_agent.rb} +1 -1
  176. data/spec/dummy/app/models/user.rb +3 -3
  177. data/spec/dummy/config/application.rb +0 -1
  178. data/spec/dummy/config/environments/test.rb +1 -0
  179. data/spec/dummy/db/development.sqlite3 +0 -0
  180. data/spec/dummy/db/migrate/035_create_reserves.rb +1 -1
  181. data/spec/dummy/db/migrate/20090519203307_create_participates.rb +2 -2
  182. data/spec/dummy/db/schema.rb +132 -132
  183. data/spec/dummy/db/test.sqlite3 +0 -0
  184. data/spec/dummy/private/system/agent_import_files/agent_imports/000/000/004/original/agent_delete_file.tsv +8 -0
  185. data/spec/dummy/private/system/agent_import_files/agent_imports/000/000/004/original/agent_import_file_sample1.tsv +5 -0
  186. data/spec/dummy/private/system/agent_import_files/agent_imports/000/000/004/original/agent_import_file_sample2.tsv +8 -0
  187. data/spec/dummy/private/system/agent_import_files/agent_imports/000/000/004/original/agent_import_file_sample3.tsv +5 -0
  188. data/spec/dummy/private/system/agent_import_files/agent_imports/000/000/004/original/agent_update_file.tsv +3 -0
  189. data/spec/dummy/solr/data/test/index/segments.gen +0 -0
  190. data/spec/dummy/solr/data/test/index/segments_q76 +0 -0
  191. data/spec/factories/{patron.rb → agent.rb} +3 -3
  192. data/spec/factories/create.rb +1 -1
  193. data/spec/factories/donate.rb +1 -1
  194. data/spec/factories/own.rb +1 -1
  195. data/spec/factories/patron_relationship.rb +3 -3
  196. data/spec/factories/patron_relationship_type.rb +2 -2
  197. data/spec/factories/patron_type.rb +2 -2
  198. data/spec/factories/produce.rb +1 -1
  199. data/spec/factories/realize.rb +1 -1
  200. data/spec/fixtures/{patron_import_files.yml → agent_import_files.yml} +18 -18
  201. data/spec/fixtures/{patron_import_results.yml → agent_import_results.yml} +7 -7
  202. data/spec/fixtures/{patron_relationship_types.yml → agent_relationship_types.yml} +4 -4
  203. data/spec/fixtures/{patron_relationships.yml → agent_relationships.yml} +4 -4
  204. data/spec/fixtures/{patron_types.yml → agent_types.yml} +4 -4
  205. data/spec/fixtures/{patrons.yml → agents.yml} +47 -47
  206. data/spec/fixtures/creates.yml +8 -8
  207. data/spec/fixtures/donates.yml +4 -4
  208. data/spec/fixtures/owns.yml +3 -3
  209. data/spec/fixtures/picture_files.yml +1 -1
  210. data/spec/fixtures/produces.yml +20 -20
  211. data/spec/fixtures/realizes.yml +11 -11
  212. data/spec/fixtures/reserves.yml +1 -1
  213. data/spec/models/agent_import_file_spec.rb +96 -0
  214. data/spec/models/{patron_import_result_spec.rb → agent_import_result_spec.rb} +4 -4
  215. data/spec/models/{patron_relationship_spec.rb → agent_relationship_spec.rb} +3 -3
  216. data/spec/models/{patron_relationship_type_spec.rb → agent_relationship_type_spec.rb} +2 -2
  217. data/spec/models/{patron_spec.rb → agent_spec.rb} +16 -16
  218. data/spec/models/{patron_type_spec.rb → agent_type_spec.rb} +2 -2
  219. data/spec/models/create_spec.rb +1 -1
  220. data/spec/models/donate_spec.rb +1 -1
  221. data/spec/models/manifestation_spec.rb +1 -1
  222. data/spec/models/own_spec.rb +1 -1
  223. data/spec/models/produce_spec.rb +1 -1
  224. data/spec/models/realize_spec.rb +1 -1
  225. data/spec/models/resource_import_file_spec.rb +8 -8
  226. data/spec/requests/agents_spec.rb +9 -0
  227. data/spec/routing/agent_relationship_types_routing_spec.rb +35 -0
  228. data/spec/routing/agent_relationships_routing_spec.rb +35 -0
  229. data/spec/routing/agents_routing_spec.rb +35 -0
  230. data/spec/views/creates/edit.html.erb_spec.rb +1 -1
  231. data/spec/views/creates/index.html.erb_spec.rb +2 -2
  232. data/spec/views/creates/new.html.erb_spec.rb +1 -1
  233. data/spec/views/creates/show.html.erb_spec.rb +1 -1
  234. data/spec/views/owns/edit.html.erb_spec.rb +1 -1
  235. data/spec/views/owns/index.html.erb_spec.rb +2 -2
  236. data/spec/views/owns/new.html.erb_spec.rb +1 -1
  237. data/spec/views/owns/show.html.erb_spec.rb +1 -1
  238. data/spec/views/produces/edit.html.erb_spec.rb +2 -2
  239. data/spec/views/produces/index.html.erb_spec.rb +2 -2
  240. data/spec/views/produces/new.html.erb_spec.rb +2 -2
  241. data/spec/views/produces/show.html.erb_spec.rb +1 -1
  242. data/spec/views/realizes/edit.html.erb_spec.rb +2 -2
  243. data/spec/views/realizes/index.html.erb_spec.rb +2 -2
  244. data/spec/views/realizes/new.html.erb_spec.rb +2 -2
  245. data/spec/views/realizes/show.html.erb_spec.rb +1 -1
  246. metadata +131 -187
  247. data/app/models/patron_import_result.rb +0 -26
  248. data/app/views/patron_import_files/index.html.erb +0 -40
  249. data/app/views/patron_import_files/show.html.erb +0 -69
  250. data/app/views/patron_import_results/index.csv.erb +0 -3
  251. data/app/views/patron_import_results/index.html.erb +0 -52
  252. data/app/views/patron_import_results/show.html.erb +0 -38
  253. data/app/views/patron_relationship_types/index.html.erb +0 -43
  254. data/app/views/patron_relationship_types/show.html.erb +0 -29
  255. data/app/views/patron_relationships/index.html.erb +0 -34
  256. data/app/views/patron_relationships/show.html.erb +0 -24
  257. data/app/views/patron_types/index.html.erb +0 -43
  258. data/app/views/patron_types/show.html.erb +0 -29
  259. data/app/views/patrons/_index_patron.html.erb +0 -71
  260. data/app/views/patrons/_index_patron_merge_list.html.erb +0 -53
  261. data/app/views/patrons/_patron.html.erb +0 -13
  262. data/app/views/patrons/_patron_list.html.erb +0 -18
  263. data/app/views/patrons/edit.html.erb +0 -16
  264. data/app/views/patrons/index.atom.builder +0 -10
  265. data/app/views/patrons/show.html.erb +0 -152
  266. data/app/views/patrons/show.mobile.erb +0 -69
  267. data/db/migrate/20081028083142_create_patron_import_files.rb +0 -22
  268. data/db/migrate/20100606073747_create_patron_relationships.rb +0 -13
  269. data/db/migrate/20100814091104_add_position_to_patron_relationship.rb +0 -11
  270. data/db/migrate/20100925074559_create_patron_import_results.rb +0 -12
  271. data/db/migrate/20110301121550_add_birth_date_and_death_date_to_patron.rb +0 -11
  272. data/db/migrate/20120413161403_add_fingerprint_to_patron_import_file.rb +0 -5
  273. data/db/migrate/20120413170720_add_error_message_to_patron_import_file.rb +0 -5
  274. data/db/migrate/20120511072422_add_patron_identifier_to_patron.rb +0 -6
  275. data/db/migrate/20120602141129_add_edit_mode_to_patron_import_file.rb +0 -5
  276. data/spec/controllers/patron_import_files_controller_spec.rb +0 -321
  277. data/spec/controllers/patron_relationship_types_controller_spec.rb +0 -445
  278. data/spec/controllers/patron_relationships_controller_spec.rb +0 -446
  279. data/spec/controllers/patron_types_controller_spec.rb +0 -447
  280. data/spec/controllers/patrons_controller_spec.rb +0 -644
  281. data/spec/dummy/app/mailers/notifier.rb +0 -40
  282. data/spec/dummy/lib/plugins/ext/event-calendar.rb +0 -38
  283. data/spec/dummy/lib/plugins/ext/sunspot/abstract_search.rb +0 -12
  284. data/spec/dummy/lib/plugins/ext/sunspot/dismax.rb +0 -41
  285. data/spec/dummy/lib/plugins/ext/sunspot/start_record.rb +0 -55
  286. data/spec/dummy/lib/plugins/ext/sunspot.rb +0 -3
  287. data/spec/dummy/lib/plugins/ext.rb +0 -1
  288. data/spec/dummy/lib/plugins.rb +0 -2
  289. data/spec/dummy/solr/data/test/index/_goc.fdt +0 -0
  290. data/spec/dummy/solr/data/test/index/_goc.fdx +0 -0
  291. data/spec/dummy/solr/data/test/index/_goc.fnm +0 -7
  292. data/spec/dummy/solr/data/test/index/_goc.frq +0 -0
  293. data/spec/dummy/solr/data/test/index/_goc.nrm +0 -1
  294. data/spec/dummy/solr/data/test/index/_goc.prx +0 -0
  295. data/spec/dummy/solr/data/test/index/_goc.tii +0 -0
  296. data/spec/dummy/solr/data/test/index/_goc.tis +0 -0
  297. data/spec/dummy/solr/data/test/index/_god.fdt +0 -0
  298. data/spec/dummy/solr/data/test/index/_god.fdx +0 -0
  299. data/spec/dummy/solr/data/test/index/_god.fnm +0 -7
  300. data/spec/dummy/solr/data/test/index/_god.frq +0 -0
  301. data/spec/dummy/solr/data/test/index/_god.nrm +0 -1
  302. data/spec/dummy/solr/data/test/index/_god.prx +0 -0
  303. data/spec/dummy/solr/data/test/index/_god.tii +0 -0
  304. data/spec/dummy/solr/data/test/index/_god.tis +0 -0
  305. data/spec/dummy/solr/data/test/index/_goe.fdt +0 -0
  306. data/spec/dummy/solr/data/test/index/_goe.fdx +0 -0
  307. data/spec/dummy/solr/data/test/index/_goe.fnm +0 -8
  308. data/spec/dummy/solr/data/test/index/_goe.frq +0 -0
  309. data/spec/dummy/solr/data/test/index/_goe.nrm +0 -1
  310. data/spec/dummy/solr/data/test/index/_goe.prx +0 -0
  311. data/spec/dummy/solr/data/test/index/_goe.tii +0 -0
  312. data/spec/dummy/solr/data/test/index/_goe.tis +0 -0
  313. data/spec/dummy/solr/data/test/index/segments_otc +0 -0
  314. data/spec/dummy/tmp/cache/4AD/470/country_all +0 -0
  315. data/spec/models/patron_import_file_spec.rb +0 -96
  316. data/spec/requests/patrons_spec.rb +0 -9
  317. data/spec/routing/patron_relationship_types_routing_spec.rb +0 -35
  318. data/spec/routing/patron_relationships_routing_spec.rb +0 -35
  319. data/spec/routing/patrons_routing_spec.rb +0 -35
@@ -2,12 +2,12 @@
2
2
  <%= f.error_messages -%>
3
3
 
4
4
  <div class="field">
5
- <%= f.label t('activerecord.models.patron') -%><br />
6
- <%- if @produce.patron -%>
7
- <%= link_to @produce.patron.full_name, @produce.patron -%>
8
- <%= f.hidden_field :patron_id -%>
5
+ <%= f.label t('activerecord.models.agent') -%><br />
6
+ <%- if @produce.agent -%>
7
+ <%= link_to @produce.agent.full_name, @produce.agent -%>
8
+ <%= f.hidden_field :agent_id -%>
9
9
  <%- else -%>
10
- <%= f.text_field :patron_id -%>
10
+ <%= f.text_field :agent_id -%>
11
11
  <%- end -%>
12
12
  </div>
13
13
 
@@ -4,14 +4,14 @@
4
4
 
5
5
  <table class="table table-striped index">
6
6
  <tr>
7
- <th><%= t('activerecord.models.patron') -%></th>
7
+ <th><%= t('activerecord.models.agent') -%></th>
8
8
  <th><%= t('activerecord.models.manifestation') -%></th>
9
9
  <th></th>
10
10
  </tr>
11
11
 
12
12
  <%- @produces.each do |produce| -%>
13
13
  <tr class="line<%= cycle("0", "1") -%>">
14
- <td><%= link_to produce.patron.full_name, produce.patron -%></td>
14
+ <td><%= link_to produce.agent.full_name, produce.agent -%></td>
15
15
  <td><%= link_to produce.manifestation_original_title, produce.manifestation -%></td>
16
16
  <td>
17
17
  <%- if can? :delete, produce -%>
@@ -8,7 +8,7 @@
8
8
  <table class="table table-striped index">
9
9
  <tr>
10
10
  <th id="position"></th>
11
- <th><%= t('activerecord.models.patron') -%></th>
11
+ <th><%= t('activerecord.models.agent') -%></th>
12
12
  <th><%= t('page.created_at') -%></th>
13
13
  <th><%= t('page.updated_at') -%></th>
14
14
  </tr>
@@ -21,7 +21,7 @@
21
21
  <%= produce.last? ? image_tag('icons/stop.png', :size => '16x16') : link_to(image_tag('icons/arrow_down.png', :size => '16x16', :alt => t('page.desc')), manifestation_produce_path(produce.manifestation, produce, :move => 'lower'), :method => :put) -%>
22
22
  <%- end -%>
23
23
  </td>
24
- <td><%= link_to produce.patron.try(:full_name), produce.patron -%></td>
24
+ <td><%= link_to produce.agent.try(:full_name), produce.agent -%></td>
25
25
  <td><%= l(produce.created_at) -%></td>
26
26
  <td><%= l(produce.updated_at) -%></td>
27
27
  </tr>
@@ -35,7 +35,7 @@
35
35
 
36
36
  <div id="submenu" class="ui-corner-all">
37
37
  <ul>
38
- <li><%= link_to t('page.listing', :model => t('activerecord.models.patron')), manifestation_patrons_path(manifestation) -%></li>
38
+ <li><%= link_to t('page.listing', :model => t('activerecord.models.agent')), manifestation_agents_path(manifestation) -%></li>
39
39
  <%- if can? :create, Produce -%>
40
40
  <li><%= link_to t('page.new', :model => t('activerecord.models.produce')), new_manifestation_produce_path(manifestation) -%></li>
41
41
  <%- end -%>
@@ -2,7 +2,7 @@
2
2
  <h1 class="title"><%= t('page.listing', :model => t('activerecord.models.produce')) -%></h1>
3
3
  <div id="content_list">
4
4
  <h2 class="resource_title">
5
- <%= link_to patron.full_name, patron -%>
5
+ <%= link_to agent.full_name, agent -%>
6
6
  </h2>
7
7
  <table class="table table-striped index">
8
8
  <tr>
@@ -19,7 +19,7 @@
19
19
  <td><%= l(produce.updated_at) -%></td>
20
20
  <td>
21
21
  <%- if can? :delete, produce -%>
22
- <%= link_to t('page.destroy'), patron_produce_path(patron, produce), :data => {:confirm => t('page.are_you_sure')}, :method => :delete -%>
22
+ <%= link_to t('page.destroy'), agent_produce_path(agent, produce), :data => {:confirm => t('page.are_you_sure')}, :method => :delete -%>
23
23
  <%- end -%>
24
24
  </td>
25
25
  </tr>
@@ -34,7 +34,7 @@
34
34
  <div id="submenu" class="ui-corner-all">
35
35
  <ul>
36
36
  <%- if can? :create, Produce -%>
37
- <li><%= link_to t('page.new', :model => t('activerecord.models.produce')), new_patron_produce_path(patron) -%></li>
37
+ <li><%= link_to t('page.new', :model => t('activerecord.models.produce')), new_agent_produce_path(agent) -%></li>
38
38
  <%- end -%>
39
39
  </ul>
40
40
  </div>
@@ -1,5 +1,5 @@
1
- <%- if @patron -%>
2
- <%= render 'index_patron', :patron => @patron -%>
1
+ <%- if @agent -%>
2
+ <%= render 'index_agent', :agent => @agent -%>
3
3
  <%- elsif @manifestation -%>
4
4
  <%= render 'index_manifestation', :manifestation => @manifestation -%>
5
5
  <%- else -%>
@@ -7,11 +7,11 @@
7
7
 
8
8
  <div id="submenu" class="ui-corner-all">
9
9
  <ul>
10
- <%- if @produce.patron -%>
11
- <li><%= link_to t('page.listing', :model => t('activerecord.models.patron')), publisher_manifestations_path(@produce.patron) -%></li>
10
+ <%- if @produce.agent -%>
11
+ <li><%= link_to t('page.listing', :model => t('activerecord.models.agent')), publisher_manifestations_path(@produce.agent) -%></li>
12
12
  <%- end -%>
13
13
  <%- if @produce.manifestation -%>
14
- <li><%= link_to t('page.listing', :model => t('activerecord.models.manifestation')), manifestation_patrons_path(@produce.manifestation) -%></li>
14
+ <li><%= link_to t('page.listing', :model => t('activerecord.models.manifestation')), manifestation_agents_path(@produce.manifestation) -%></li>
15
15
  <%- end -%>
16
16
  </ul>
17
17
  </div>
@@ -4,8 +4,8 @@
4
4
  <p id="notice"><%= notice %></p>
5
5
 
6
6
  <p>
7
- <strong><%= t('activerecord.models.patron') -%>:</strong>
8
- <%=link_to @produce.patron.full_name, @produce.patron -%>
7
+ <strong><%= t('activerecord.models.agent') -%>:</strong>
8
+ <%=link_to @produce.agent.full_name, @produce.agent -%>
9
9
  </p>
10
10
 
11
11
  <p>
@@ -18,7 +18,7 @@
18
18
 
19
19
  <div id="submenu" class="ui-corner-all">
20
20
  <ul>
21
- <li><%= link_to t('page.back_to', :model => t('activerecord.models.patron')), manifestation_patrons_path(@produce.manifestation) -%></li>
22
- <li><%= link_to t('page.back_to', :model => t('activerecord.models.manifestation')), publisher_manifestations_path(@produce.patron) -%></li>
21
+ <li><%= link_to t('page.back_to', :model => t('activerecord.models.agent')), manifestation_agents_path(@produce.manifestation) -%></li>
22
+ <li><%= link_to t('page.back_to', :model => t('activerecord.models.manifestation')), publisher_manifestations_path(@produce.agent) -%></li>
23
23
  </ul>
24
24
  </div>
@@ -2,12 +2,12 @@
2
2
  <%= f.error_messages -%>
3
3
 
4
4
  <div class="field">
5
- <%= f.label t('activerecord.models.patron') -%><br />
6
- <%- if @realize.patron -%>
7
- <%= link_to @realize.patron.full_name, @realize.patron -%>
8
- <%= f.hidden_field :patron_id -%>
5
+ <%= f.label t('activerecord.models.agent') -%><br />
6
+ <%- if @realize.agent -%>
7
+ <%= link_to @realize.agent.full_name, @realize.agent -%>
8
+ <%= f.hidden_field :agent_id -%>
9
9
  <%- else -%>
10
- <%= f.text_field :patron_id -%>
10
+ <%= f.text_field :agent_id -%>
11
11
  <%- end -%>
12
12
  </div>
13
13
 
@@ -4,14 +4,14 @@
4
4
 
5
5
  <table class="table table-striped index">
6
6
  <tr>
7
- <th><%= t('activerecord.models.patron') -%></th>
7
+ <th><%= t('activerecord.models.agent') -%></th>
8
8
  <th><%= t('activerecord.models.manifestation') -%></th>
9
9
  <th></th>
10
10
  </tr>
11
11
 
12
12
  <%- @realizes.each do |realize| -%>
13
13
  <tr class="line<%= cycle("0", "1") -%>">
14
- <td><%= link_to realize.patron.full_name, realize.patron -%></td>
14
+ <td><%= link_to realize.agent.full_name, realize.agent -%></td>
15
15
  <td><%= link_to realize.expression.original_title, realize.expression -%></td>
16
16
  <td>
17
17
  <%- if can? :delete, realize -%>
@@ -8,7 +8,7 @@
8
8
  <table class="table table-striped index">
9
9
  <tr>
10
10
  <th id="position"></th>
11
- <th><%= t('activerecord.models.patron') -%></th>
11
+ <th><%= t('activerecord.models.agent') -%></th>
12
12
  <th><%= t('page.created_at') -%></th>
13
13
  <th><%= t('page.updated_at') -%></th>
14
14
  </tr>
@@ -21,7 +21,7 @@
21
21
  <%= realize.last? ? image_tag('icons/stop.png', :size => '16x16') : link_to(image_tag('icons/arrow_down.png', :size => '16x16', :alt => t('page.desc')), expression_realize_path(realize.expression, realize, :move => 'lower'), :method => :put) -%>
22
22
  <%- end -%>
23
23
  </td>
24
- <td><%= link_to realize.patron.try(:full_name), realize.patron -%></td>
24
+ <td><%= link_to realize.agent.try(:full_name), realize.agent -%></td>
25
25
  <td><%= l(realize.created_at) -%></td>
26
26
  <td><%= l(realize.updated_at) -%></td>
27
27
  </tr>
@@ -35,7 +35,7 @@
35
35
 
36
36
  <div id="submenu" class="ui-corner-all">
37
37
  <ul>
38
- <li><%= link_to t('page.listing', :model => t('activerecord.models.patron')), expression_patrons_path(expression) -%></li>
38
+ <li><%= link_to t('page.listing', :model => t('activerecord.models.agent')), expression_agents_path(expression) -%></li>
39
39
  <%- if can? :create, Realize -%>
40
40
  <li><%= link_to t('page.new', :model => t('activerecord.models.realize')), new_expression_realize_path(expression) -%></li>
41
41
  <%- end -%>
@@ -2,7 +2,7 @@
2
2
  <h1 class="title"><%= t('page.listing', :model => t('activerecord.models.realize')) -%></h1>
3
3
  <div id="content_list">
4
4
  <h2 class="resource_title">
5
- <%= link_to patron.full_name, patron -%>
5
+ <%= link_to agent.full_name, agent -%>
6
6
  </h2>
7
7
  <table class="table table-striped index">
8
8
  <tr>
@@ -19,7 +19,7 @@
19
19
  <td><%= l(realize.updated_at) -%></td>
20
20
  <td>
21
21
  <%- if can? :delete, realize -%>
22
- <%= link_to t('page.destroy'), patron_realize_path(patron, realize), :data => {:confirm => t('page.are_you_sure')}, :method => :delete -%>
22
+ <%= link_to t('page.destroy'), agent_realize_path(agent, realize), :data => {:confirm => t('page.are_you_sure')}, :method => :delete -%>
23
23
  <%- end -%>
24
24
  </td>
25
25
  </tr>
@@ -34,7 +34,7 @@
34
34
  <div id="submenu" class="ui-corner-all">
35
35
  <ul>
36
36
  <%- if can? :create, Realize -%>
37
- <li><%= link_to t('page.new', :model => t('activerecord.models.realize')), new_patron_realize_path(patron) -%></li>
37
+ <li><%= link_to t('page.new', :model => t('activerecord.models.realize')), new_agent_realize_path(agent) -%></li>
38
38
  <%- end -%>
39
39
  </ul>
40
40
  </div>
@@ -1,5 +1,5 @@
1
- <%- if @patron -%>
2
- <%= render 'index_patron', :patron => @patron -%>
1
+ <%- if @agent -%>
2
+ <%= render 'index_agent', :agent => @agent -%>
3
3
  <%- elsif @expression -%>
4
4
  <%= render 'index_expression', :expression => @expression -%>
5
5
  <%- else -%>
@@ -7,11 +7,11 @@
7
7
 
8
8
  <div id="submenu" class="ui-corner-all">
9
9
  <ul>
10
- <%- if @realize.patron -%>
11
- <li><%= link_to t('page.listing', :model => t('activerecord.models.manifestation')), contributor_manifestations_path(@realize.patron) -%></li>
10
+ <%- if @realize.agent -%>
11
+ <li><%= link_to t('page.listing', :model => t('activerecord.models.manifestation')), contributor_manifestations_path(@realize.agent) -%></li>
12
12
  <%- end -%>
13
13
  <%- if @realize.expression -%>
14
- <li><%= link_to t('page.listing', :model => t('activerecord.models.patron')), expression_patrons_path(@realize.expression) -%></li>
14
+ <li><%= link_to t('page.listing', :model => t('activerecord.models.agent')), expression_agents_path(@realize.expression) -%></li>
15
15
  <%- end -%>
16
16
  </ul>
17
17
  </div>
@@ -4,8 +4,8 @@
4
4
  <p id="notice"><%= notice %></p>
5
5
 
6
6
  <p>
7
- <strong><%= t('activerecord.models.patron') -%>:</strong>
8
- <%= link_to @realize.patron.full_name, @realize.patron -%>
7
+ <strong><%= t('activerecord.models.agent') -%>:</strong>
8
+ <%= link_to @realize.agent.full_name, @realize.agent -%>
9
9
  </p>
10
10
 
11
11
  <p>
@@ -18,7 +18,7 @@
18
18
 
19
19
  <div id="submenu" class="ui-corner-all">
20
20
  <ul>
21
- <li><%= link_to t('page.back_to', :model => t('activerecord.models.patron')), expression_patrons_path(@realize.expression) -%></li>
22
- <li><%= link_to t('page.back_to', :model => t('activerecord.models.manifestation')), contributor_manifestations_path(@realize.patron) -%></li>
21
+ <li><%= link_to t('page.back_to', :model => t('activerecord.models.agent')), expression_agents_path(@realize.expression) -%></li>
22
+ <li><%= link_to t('page.back_to', :model => t('activerecord.models.manifestation')), contributor_manifestations_path(@realize.agent) -%></li>
23
23
  </ul>
24
24
  </div>
@@ -19,7 +19,7 @@
19
19
  </p>
20
20
 
21
21
  <p>
22
- <b><%= t('activerecord.attributes.patron_import_result.body') %></b>
22
+ <b><%= t('activerecord.attributes.agent_import_result.body') %></b>
23
23
  <%= @resource_import_result.body %>
24
24
  </p>
25
25
 
data/config/routes.rb CHANGED
@@ -2,7 +2,7 @@ Rails.application.routes.draw do
2
2
  resources :identifier_types
3
3
 
4
4
  resources :manifestations do
5
- resources :patrons
5
+ resources :agents
6
6
  resources :produces
7
7
  resources :exemplifies
8
8
  resources :series_statements
@@ -13,44 +13,44 @@ Rails.application.routes.draw do
13
13
  end
14
14
 
15
15
  resources :items do
16
- resources :patrons
16
+ resources :agents
17
17
  resources :owns
18
18
  resource :exemplify
19
19
  resources :manifestations, :only => [:index]
20
20
  end
21
21
 
22
- resources :patrons do
22
+ resources :agents do
23
23
  resources :works, :controller => 'manifestations'
24
24
  resources :expressions, :controller => 'manifestations'
25
25
  resources :manifestations
26
26
  resources :items
27
27
  resources :picture_files
28
- resources :patrons
29
- resources :patron_relationships
28
+ resources :agents
29
+ resources :agent_relationships
30
30
  resources :creates
31
31
  resources :realizes
32
32
  resources :produces
33
33
  end
34
34
 
35
35
  resources :works, :controller => 'manifestations', :except => [:index, :new, :create] do
36
- resources :patrons
36
+ resources :agents
37
37
  resources :creates
38
38
  end
39
39
 
40
40
  resources :expressions, :controller => 'manifestations', :except => [:index, :new, :create] do
41
- resources :patrons
41
+ resources :agents
42
42
  resources :realizes
43
43
  end
44
44
 
45
- resources :creators, :controller => 'patrons', :except => [:index, :new, :create] do
45
+ resources :creators, :controller => 'agents', :except => [:index, :new, :create] do
46
46
  resources :manifestations
47
47
  end
48
48
 
49
- resources :contributors, :controller => 'patrons', :except => [:index, :new, :create] do
49
+ resources :contributors, :controller => 'agents', :except => [:index, :new, :create] do
50
50
  resources :manifestations
51
51
  end
52
52
 
53
- resources :publishers, :controller => 'patrons', :except => [:index, :new, :create] do
53
+ resources :publishers, :controller => 'agents', :except => [:index, :new, :create] do
54
54
  resources :manifestations
55
55
  end
56
56
 
@@ -76,10 +76,10 @@ Rails.application.routes.draw do
76
76
  resources :carrier_types
77
77
  resources :content_types
78
78
  resources :extents
79
- resources :patron_types
79
+ resources :agent_types
80
80
 
81
- resources :patron_relationship_types
82
- resources :patron_relationships
81
+ resources :agent_relationship_types
82
+ resources :agent_relationships
83
83
  resources :manifestation_relationship_types
84
84
  resources :manifestation_relationships
85
85
 
@@ -87,10 +87,10 @@ Rails.application.routes.draw do
87
87
  resources :resource_import_results
88
88
  end
89
89
  resources :resource_import_results
90
- resources :patron_import_files do
91
- resources :patron_import_results
90
+ resources :agent_import_files do
91
+ resources :agent_import_results
92
92
  end
93
- resources :patron_import_results
93
+ resources :agent_import_results
94
94
 
95
95
  resources :import_requests
96
96
 
@@ -1,6 +1,6 @@
1
- class CreatePatrons < ActiveRecord::Migration
1
+ class CreateAgents < ActiveRecord::Migration
2
2
  def change
3
- create_table :patrons do |t|
3
+ create_table :agents do |t|
4
4
  t.integer :user_id
5
5
  t.string :last_name
6
6
  t.string :middle_name
@@ -35,7 +35,7 @@ class CreatePatrons < ActiveRecord::Migration
35
35
  t.datetime :date_of_death
36
36
  t.integer :language_id, :default => 1, :null => false
37
37
  t.integer :country_id, :default => 1, :null => false
38
- t.integer :patron_type_id, :default => 1, :null => false
38
+ t.integer :agent_type_id, :default => 1, :null => false
39
39
  t.integer :lock_version, :default => 0, :null => false
40
40
  t.text :note
41
41
  t.integer :required_role_id, :default => 1, :null => false
@@ -44,10 +44,10 @@ class CreatePatrons < ActiveRecord::Migration
44
44
  t.text :email
45
45
  t.text :url
46
46
  end
47
- add_index :patrons, :user_id, :unique => true
48
- add_index :patrons, :language_id
49
- add_index :patrons, :country_id
50
- add_index :patrons, :required_role_id
51
- add_index :patrons, :full_name
47
+ add_index :agents, :user_id, :unique => true
48
+ add_index :agents, :language_id
49
+ add_index :agents, :country_id
50
+ add_index :agents, :required_role_id
51
+ add_index :agents, :full_name
52
52
  end
53
53
  end
@@ -1,12 +1,12 @@
1
1
  class CreateOwns < ActiveRecord::Migration
2
2
  def change
3
3
  create_table :owns do |t|
4
- t.references :patron, :null => false
4
+ t.references :agent, :null => false
5
5
  t.references :item, :null => false
6
6
  t.integer :position
7
7
  t.timestamps
8
8
  end
9
- add_index :owns, :patron_id
9
+ add_index :owns, :agent_id
10
10
  add_index :owns, :item_id
11
11
  end
12
12
  end
@@ -1,12 +1,12 @@
1
1
  class CreateCreates < ActiveRecord::Migration
2
2
  def change
3
3
  create_table :creates do |t|
4
- t.references :patron, :null => false
4
+ t.references :agent, :null => false
5
5
  t.references :work, :null => false
6
6
  t.integer :position
7
7
  t.timestamps
8
8
  end
9
- add_index :creates, :patron_id
9
+ add_index :creates, :agent_id
10
10
  add_index :creates, :work_id
11
11
  end
12
12
  end
@@ -1,12 +1,12 @@
1
1
  class CreateProduces < ActiveRecord::Migration
2
2
  def change
3
3
  create_table :produces do |t|
4
- t.references :patron, :null => false
4
+ t.references :agent, :null => false
5
5
  t.references :manifestation, :null => false
6
6
  t.integer :position
7
7
  t.timestamps
8
8
  end
9
- add_index :produces, :patron_id
9
+ add_index :produces, :agent_id
10
10
  add_index :produces, :manifestation_id
11
11
  end
12
12
  end
@@ -1,12 +1,12 @@
1
1
  class CreateDonates < ActiveRecord::Migration
2
2
  def change
3
3
  create_table :donates do |t|
4
- t.integer :patron_id, :null => false
4
+ t.integer :agent_id, :null => false
5
5
  t.integer :item_id, :null => false
6
6
 
7
7
  t.timestamps
8
8
  end
9
- add_index :donates, :patron_id
9
+ add_index :donates, :agent_id
10
10
  add_index :donates, :item_id
11
11
  end
12
12
  end
@@ -1,13 +1,13 @@
1
1
  class CreateRealizes < ActiveRecord::Migration
2
2
  def change
3
3
  create_table :realizes do |t|
4
- t.references :patron, :null => false
4
+ t.references :agent, :null => false
5
5
  t.references :expression, :null => false
6
6
  t.integer :position
7
7
 
8
8
  t.timestamps
9
9
  end
10
- add_index :realizes, :patron_id
10
+ add_index :realizes, :agent_id
11
11
  add_index :realizes, :expression_id
12
12
  end
13
13
  end
@@ -1,6 +1,6 @@
1
- class CreatePatronTypes < ActiveRecord::Migration
1
+ class CreateAgentTypes < ActiveRecord::Migration
2
2
  def change
3
- create_table :patron_types do |t|
3
+ create_table :agent_types do |t|
4
4
  t.string :name, :null => false
5
5
  t.text :display_name
6
6
  t.text :note
@@ -0,0 +1,22 @@
1
+ class CreateAgentImportFiles < ActiveRecord::Migration
2
+ def change
3
+ create_table :agent_import_files do |t|
4
+ t.integer :parent_id
5
+ t.string :content_type
6
+ t.integer :size
7
+ t.integer :user_id
8
+ t.text :note
9
+ t.datetime :executed_at
10
+ t.string :state
11
+ t.string :agent_import_file_name
12
+ t.string :agent_import_content_type
13
+ t.integer :agent_import_file_size
14
+ t.datetime :agent_import_updated_at
15
+
16
+ t.timestamps
17
+ end
18
+ add_index :agent_import_files, :parent_id
19
+ add_index :agent_import_files, :user_id
20
+ add_index :agent_import_files, :state
21
+ end
22
+ end
@@ -1,6 +1,6 @@
1
- class CreatePatronRelationshipTypes < ActiveRecord::Migration
1
+ class CreateAgentRelationshipTypes < ActiveRecord::Migration
2
2
  def change
3
- create_table :patron_relationship_types do |t|
3
+ create_table :agent_relationship_types do |t|
4
4
  t.string :name, :null => false
5
5
  t.text :display_name
6
6
  t.text :note
@@ -1,7 +1,7 @@
1
1
  class AddDcndlSchema < ActiveRecord::Migration
2
2
  def self.up
3
3
  add_column :manifestations, :title_alternative_transcription, :text
4
- add_column :patrons, :full_name_alternative_transcription, :text
4
+ add_column :agents, :full_name_alternative_transcription, :text
5
5
  add_column :manifestations, :description, :text
6
6
  add_column :manifestations, :abstract, :text
7
7
  add_column :manifestations, :available_at, :timestamp
@@ -14,7 +14,7 @@ class AddDcndlSchema < ActiveRecord::Migration
14
14
 
15
15
  def self.down
16
16
  remove_column :manifestations, :title_alternative_transcription
17
- remove_column :patrons, :full_name_alternative_transcription
17
+ remove_column :agents, :full_name_alternative_transcription
18
18
  remove_column :manifestations, :description
19
19
  remove_column :manifestations, :abstract
20
20
  remove_column :manifestations, :available_at
@@ -0,0 +1,13 @@
1
+ class CreateAgentRelationships < ActiveRecord::Migration
2
+ def change
3
+ create_table :agent_relationships do |t|
4
+ t.integer :parent_id
5
+ t.integer :child_id
6
+ t.integer :agent_relationship_type_id
7
+
8
+ t.timestamps
9
+ end
10
+ add_index :agent_relationships, :parent_id
11
+ add_index :agent_relationships, :child_id
12
+ end
13
+ end
@@ -0,0 +1,11 @@
1
+ class AddPositionToAgentRelationship < ActiveRecord::Migration
2
+ def self.up
3
+ add_column :manifestation_relationships, :position, :integer
4
+ add_column :agent_relationships, :position, :integer
5
+ end
6
+
7
+ def self.down
8
+ remove_column :agent_relationships, :position
9
+ remove_column :manifestation_relationships, :position
10
+ end
11
+ end
@@ -0,0 +1,12 @@
1
+ class CreateAgentImportResults < ActiveRecord::Migration
2
+ def change
3
+ create_table :agent_import_results do |t|
4
+ t.integer :agent_import_file_id
5
+ t.integer :agent_id
6
+ t.integer :user_id
7
+ t.text :body
8
+
9
+ t.timestamps
10
+ end
11
+ end
12
+ end
@@ -0,0 +1,11 @@
1
+ class AddBirthDateAndDeathDateToAgent < ActiveRecord::Migration
2
+ def self.up
3
+ add_column :agents, :birth_date, :string
4
+ add_column :agents, :death_date, :string
5
+ end
6
+
7
+ def self.down
8
+ remove_column :agents, :death_date
9
+ remove_column :agents, :birth_date
10
+ end
11
+ end
@@ -0,0 +1,5 @@
1
+ class AddFingerprintToAgentImportFile < ActiveRecord::Migration
2
+ def change
3
+ add_column :agent_import_files, :agent_import_fingerprint, :string
4
+ end
5
+ end
@@ -0,0 +1,5 @@
1
+ class AddErrorMessageToAgentImportFile < ActiveRecord::Migration
2
+ def change
3
+ add_column :agent_import_files, :error_message, :text
4
+ end
5
+ end
@@ -0,0 +1,6 @@
1
+ class AddAgentIdentifierToAgent < ActiveRecord::Migration
2
+ def change
3
+ add_column :agents, :agent_identifier, :string
4
+ add_index :agents, :agent_identifier
5
+ end
6
+ end
@@ -0,0 +1,5 @@
1
+ class AddEditModeToAgentImportFile < ActiveRecord::Migration
2
+ def change
3
+ add_column :agent_import_files, :edit_mode, :string
4
+ end
5
+ end