enju_leaf 1.1.0.rc12 → 1.1.0.rc13

Sign up to get free protection for your applications and to get access to all the features.
Files changed (367) hide show
  1. checksums.yaml +4 -4
  2. data/app/assets/stylesheets/enju.css +0 -1
  3. data/app/controllers/my_accounts_controller.rb +26 -18
  4. data/app/controllers/page_controller.rb +6 -6
  5. data/app/controllers/profiles_controller.rb +155 -0
  6. data/app/controllers/roles_controller.rb +5 -5
  7. data/app/controllers/user_export_files_controller.rb +100 -0
  8. data/app/controllers/user_groups_controller.rb +11 -11
  9. data/app/controllers/user_import_files_controller.rb +22 -11
  10. data/app/controllers/user_import_results_controller.rb +1 -1
  11. data/app/mailers/notifier.rb +7 -7
  12. data/app/models/enju_leaf/ability.rb +14 -13
  13. data/app/models/profile.rb +63 -16
  14. data/app/models/role.rb +2 -2
  15. data/app/models/user_export_file.rb +52 -0
  16. data/app/models/user_export_file_state_machine.rb +15 -0
  17. data/app/models/user_export_file_transition.rb +20 -0
  18. data/app/models/user_group.rb +3 -3
  19. data/app/models/user_has_role.rb +2 -2
  20. data/app/models/user_import_file.rb +139 -53
  21. data/app/views/kaminari/_first_page.html.erb +1 -1
  22. data/app/views/kaminari/_last_page.html.erb +1 -1
  23. data/app/views/kaminari/_next_page.html.erb +1 -1
  24. data/app/views/kaminari/_page.html.erb +1 -1
  25. data/app/views/kaminari/_prev_page.html.erb +1 -1
  26. data/app/views/kaminari/enju_leaf_mobile/_next_page.html.erb +1 -1
  27. data/app/views/kaminari/enju_leaf_mobile/_page.html.erb +1 -1
  28. data/app/views/kaminari/enju_leaf_mobile/_prev_page.html.erb +1 -1
  29. data/app/views/layouts/application.html.erb +4 -4
  30. data/app/views/my_accounts/_edit_credential.html.erb +67 -59
  31. data/app/views/my_accounts/edit.html.erb +6 -46
  32. data/app/views/my_accounts/show.html.erb +8 -8
  33. data/app/views/page/_add.html.erb +2 -2
  34. data/app/views/page/_footer.html.erb +3 -2
  35. data/app/views/page/_footer.mobile.erb +1 -1
  36. data/app/views/page/_header.html.erb +4 -4
  37. data/app/views/page/_include.html.erb +1 -1
  38. data/app/views/page/_index.html.erb +8 -8
  39. data/app/views/page/_index.mobile.erb +4 -4
  40. data/app/views/page/_menu.html.erb +9 -6
  41. data/app/views/page/_msie_acceralator.html.erb +1 -1
  42. data/app/views/page/_position.html.erb +2 -2
  43. data/app/views/page/_search_form.html.erb +2 -2
  44. data/app/views/page/_search_form.mobile.erb +2 -2
  45. data/app/views/page/_select_locale.html.erb +2 -2
  46. data/app/views/page/about.en.html.erb +2 -2
  47. data/app/views/page/about.ja.html.erb +2 -2
  48. data/app/views/page/advanced_search.html.erb +8 -8
  49. data/app/views/page/configuration.html.erb +5 -3
  50. data/app/views/page/export.html.erb +7 -17
  51. data/app/views/page/import.html.erb +1 -4
  52. data/app/views/page/index.html.erb +2 -2
  53. data/app/views/page/msie_acceralator.builder +1 -1
  54. data/app/views/page/opensearch.builder +2 -2
  55. data/app/views/profiles/_edit_credential.html.erb +78 -0
  56. data/app/views/profiles/_edit_profile.html.erb +42 -0
  57. data/app/views/{users → profiles}/_form.html.erb +0 -0
  58. data/app/views/{users → profiles}/_show.html.erb +0 -0
  59. data/app/views/profiles/edit.html.erb +36 -0
  60. data/app/views/profiles/index.html.erb +61 -0
  61. data/app/views/{users → profiles}/new.html.erb +34 -36
  62. data/app/views/{users → profiles}/show.html.erb +24 -22
  63. data/app/views/{users → profiles}/show.mobile.erb +0 -0
  64. data/app/views/roles/_form.html.erb +1 -1
  65. data/app/views/roles/edit.html.erb +1 -1
  66. data/app/views/roles/index.html.erb +2 -2
  67. data/app/views/roles/new.html.erb +1 -1
  68. data/app/views/roles/show.html.erb +1 -1
  69. data/app/views/user_export_files/_form.html.erb +22 -0
  70. data/app/views/user_export_files/edit.html.erb +6 -0
  71. data/app/views/user_export_files/index.html.erb +44 -0
  72. data/app/views/user_export_files/new.html.erb +16 -0
  73. data/app/views/user_export_files/show.html.erb +31 -0
  74. data/app/views/user_groups/_form.html.erb +5 -5
  75. data/app/views/user_groups/edit.html.erb +1 -1
  76. data/app/views/user_groups/index.html.erb +14 -8
  77. data/app/views/user_groups/new.html.erb +1 -1
  78. data/app/views/user_groups/show.html.erb +3 -3
  79. data/app/views/user_import_files/index.html.erb +11 -10
  80. data/app/views/user_import_files/new.html.erb +15 -3
  81. data/app/views/user_import_files/show.html.erb +13 -3
  82. data/app/views/user_import_results/index.html.erb +7 -7
  83. data/app/views/user_import_results/{index.tsv.erb → index.txt.erb} +1 -1
  84. data/app/views/user_import_results/show.html.erb +2 -2
  85. data/app/workers/user_export_file_queue.rb +7 -0
  86. data/config/initializers/mime_types.rb +1 -1
  87. data/config/locales/devise.en.yml +19 -18
  88. data/config/locales/devise.ja.yml +45 -42
  89. data/config/locales/en.yml +214 -0
  90. data/config/locales/ja.yml +10 -6
  91. data/config/locales/translation_en.yml +34 -5
  92. data/config/locales/translation_ja.yml +35 -6
  93. data/config/routes.rb +4 -7
  94. data/db/migrate/20130221154434_add_additional_attributes_to_user.rb +0 -9
  95. data/db/migrate/20140122054321_create_profiles.rb +1 -1
  96. data/db/migrate/20140709113413_create_user_export_files.rb +11 -0
  97. data/db/migrate/20140709113905_create_user_export_file_transitions.rb +14 -0
  98. data/db/migrate/20140720170714_add_default_library_id_to_user_import_file.rb +5 -0
  99. data/db/migrate/20140720170735_add_default_user_group_id_to_user_import_file.rb +5 -0
  100. data/db/migrate/20140811031145_add_expired_at_to_profile.rb +5 -0
  101. data/lib/enju_leaf/calculate_stat.rb +9 -0
  102. data/lib/enju_leaf/controller.rb +1 -1
  103. data/lib/enju_leaf/export_file.rb +26 -0
  104. data/lib/enju_leaf/import_file.rb +25 -0
  105. data/lib/enju_leaf/master_model.rb +15 -6
  106. data/lib/enju_leaf/url_validator.rb +4 -2
  107. data/lib/enju_leaf/user.rb +74 -68
  108. data/lib/enju_leaf/version.rb +1 -1
  109. data/lib/enju_leaf.rb +23 -24
  110. data/lib/generators/enju_leaf/quick_install/quick_install_generator.rb +2 -1
  111. data/lib/generators/enju_leaf/setup/setup_generator.rb +6 -0
  112. data/lib/generators/enju_leaf/setup/templates/db/fixtures/user_groups.yml +1 -1
  113. data/lib/generators/enju_leaf/setup/templates/db/seeds.rb +5 -4
  114. data/lib/tasks/enju_leaf_tasks.rake +18 -9
  115. data/lib/tasks/profile.rb +15 -0
  116. data/spec/controllers/my_accounts_controller_spec.rb +61 -43
  117. data/spec/controllers/page_controller_spec.rb +20 -20
  118. data/spec/controllers/profiles_controller_spec.rb +530 -0
  119. data/spec/controllers/roles_controller_spec.rb +19 -19
  120. data/spec/controllers/user_export_files_controller_spec.rb +297 -0
  121. data/spec/controllers/user_groups_controller_spec.rb +48 -48
  122. data/spec/controllers/user_import_files_controller_spec.rb +45 -41
  123. data/spec/controllers/user_import_results_controller_spec.rb +9 -9
  124. data/spec/dummy/app/models/user.rb +3 -0
  125. data/spec/dummy/config/application.rb +3 -1
  126. data/spec/dummy/config/environments/test.rb +2 -0
  127. data/spec/dummy/db/development.sqlite3 +0 -0
  128. data/spec/dummy/db/migrate/{001_create_patrons.rb → 001_create_agents.rb} +1 -2
  129. data/spec/dummy/db/migrate/005_create_manifestations.rb +5 -17
  130. data/spec/dummy/db/migrate/006_create_items.rb +2 -3
  131. data/spec/dummy/db/migrate/032_create_checkins.rb +17 -0
  132. data/spec/dummy/db/migrate/033_create_checkouts.rb +25 -0
  133. data/spec/dummy/db/migrate/035_create_reserves.rb +27 -0
  134. data/spec/dummy/db/migrate/055_create_bookmarks.rb +22 -0
  135. data/spec/dummy/db/migrate/059_create_libraries.rb +5 -1
  136. data/spec/dummy/db/migrate/069_create_shelves.rb +5 -1
  137. data/spec/dummy/db/migrate/080_create_library_groups.rb +0 -2
  138. data/spec/dummy/db/migrate/113_create_events.rb +23 -0
  139. data/spec/dummy/db/migrate/114_create_event_categories.rb +16 -0
  140. data/spec/dummy/db/migrate/121_create_checked_items.rb +17 -0
  141. data/spec/dummy/db/migrate/127_create_use_restrictions.rb +16 -0
  142. data/spec/dummy/db/migrate/129_create_item_has_use_restrictions.rb +16 -0
  143. data/spec/dummy/db/migrate/130_create_request_status_types.rb +5 -1
  144. data/spec/dummy/db/migrate/131_create_request_types.rb +5 -1
  145. data/spec/dummy/db/migrate/132_create_circulation_statuses.rb +16 -0
  146. data/spec/dummy/db/migrate/149_create_message_templates.rb +18 -0
  147. data/spec/dummy/db/migrate/154_create_messages.rb +23 -0
  148. data/spec/dummy/db/migrate/20080819181903_create_message_requests.rb +18 -0
  149. data/spec/dummy/db/migrate/{20080905191442_create_patron_types.rb → 20080905191442_create_agent_types.rb} +1 -1
  150. data/spec/dummy/db/migrate/{20081028083142_create_patron_import_files.rb → 20081028083142_create_agent_import_files.rb} +2 -4
  151. data/spec/dummy/db/migrate/20081028083208_create_resource_import_files.rb +1 -3
  152. data/spec/dummy/db/migrate/20081030023412_create_checkout_types.rb +17 -0
  153. data/spec/dummy/db/migrate/20081030023518_create_user_group_has_checkout_types.rb +25 -0
  154. data/spec/dummy/db/migrate/20081030023615_create_carrier_type_has_checkout_types.rb +18 -0
  155. data/spec/dummy/db/migrate/20081212075554_create_checkout_stat_has_manifestations.rb +17 -0
  156. data/spec/dummy/db/migrate/20081212080038_create_manifestation_checkout_stats.rb +16 -0
  157. data/spec/dummy/db/migrate/20081212151614_create_bookmark_stats.rb +16 -0
  158. data/spec/dummy/db/migrate/20081212151820_create_bookmark_stat_has_manifestations.rb +13 -0
  159. data/spec/dummy/db/migrate/20081215094302_create_user_checkout_stats.rb +16 -0
  160. data/spec/dummy/db/migrate/20081215094955_create_checkout_stat_has_users.rb +17 -0
  161. data/spec/dummy/db/migrate/20081216190517_create_reserve_stat_has_manifestations.rb +17 -0
  162. data/spec/dummy/db/migrate/20081216190724_create_manifestation_reserve_stats.rb +16 -0
  163. data/spec/dummy/db/migrate/20081220023628_create_user_reserve_stats.rb +16 -0
  164. data/spec/dummy/db/migrate/20081220034117_create_reserve_stat_has_users.rb +17 -0
  165. data/spec/dummy/db/migrate/20090321130448_add_completed_at_to_user_checkout_stat.rb +27 -0
  166. data/spec/dummy/db/migrate/{20090812151902_create_patron_relationship_types.rb → 20090812151902_create_agent_relationship_types.rb} +1 -1
  167. data/spec/dummy/db/migrate/20090831220301_create_lending_policies.rb +21 -0
  168. data/spec/dummy/db/migrate/20100129142347_create_import_requests.rb +0 -1
  169. data/spec/dummy/db/migrate/20100222124420_add_allow_bookmark_external_url_to_library_group.rb +9 -0
  170. data/spec/dummy/db/migrate/20100525171356_acts_as_taggable_on_migration.rb +30 -0
  171. data/spec/dummy/db/migrate/{20100606073747_create_patron_relationships.rb → 20100606073747_create_agent_relationships.rb} +1 -1
  172. data/spec/dummy/db/migrate/{20100814091104_add_position_to_patron_relationship.rb → 20100814091104_add_position_to_agent_relationship.rb} +1 -1
  173. data/spec/dummy/db/migrate/{20100925074559_create_patron_import_results.rb → 20100925074559_create_agent_import_results.rb} +1 -1
  174. data/spec/dummy/db/migrate/{20110301121550_add_birth_date_and_death_date_to_patron.rb → 20110301121550_add_birth_date_and_death_date_to_agent.rb} +1 -1
  175. data/spec/dummy/db/migrate/20110301134521_add_expire_date_to_reserve.rb +9 -0
  176. data/spec/dummy/db/migrate/20110328130826_add_current_checkout_count_to_user_group_has_checkout_type.rb +9 -0
  177. data/spec/dummy/db/migrate/20110618091240_add_periodical_to_series_statement.rb +1 -1
  178. data/spec/dummy/db/migrate/20110621093332_remove_expire_date_from_reserve.rb +9 -0
  179. data/spec/dummy/db/migrate/20110913115320_add_lft_and_rgt_to_message.rb +11 -0
  180. data/spec/dummy/db/migrate/20111020063828_remove_dsbl_from_library_group.rb +11 -0
  181. data/spec/dummy/db/migrate/20111217234412_add_save_checkout_history_to_user.rb +5 -0
  182. data/spec/dummy/db/migrate/20111218002349_add_checkout_icalendar_token_to_user.rb +6 -0
  183. data/spec/dummy/db/migrate/20111231145823_add_share_bookmarks_to_user.rb +5 -0
  184. data/spec/dummy/db/migrate/20120125050502_add_depth_to_message.rb +6 -0
  185. data/spec/dummy/db/migrate/{20120413161403_add_fingerprint_to_patron_import_file.rb → 20120413161403_add_fingerprint_to_agent_import_file.rb} +1 -1
  186. data/spec/dummy/db/migrate/{20120413170720_add_error_message_to_patron_import_file.rb → 20120413170720_add_error_message_to_agent_import_file.rb} +1 -1
  187. data/spec/dummy/db/migrate/20120418121539_add_save_search_history_to_user.rb +5 -0
  188. data/spec/dummy/db/migrate/20120424103932_add_librarian_id_to_checked_item.rb +5 -0
  189. data/spec/dummy/db/migrate/{20120511072422_add_patron_identifier_to_patron.rb → 20120511072422_add_agent_identifier_to_agent.rb} +1 -1
  190. data/spec/dummy/db/migrate/{20120602141129_add_edit_mode_to_patron_import_file.rb → 20120602141129_add_edit_mode_to_agent_import_file.rb} +1 -1
  191. data/spec/dummy/db/migrate/20130303104849_add_state_index_to_reserve.rb +5 -0
  192. data/spec/dummy/db/migrate/20130303124821_add_retained_at_to_reserve.rb +5 -0
  193. data/spec/dummy/db/migrate/20130304015019_add_postponed_at_to_reserve.rb +5 -0
  194. data/spec/dummy/db/migrate/20130416054135_add_circulation_status_id_to_item.rb +8 -0
  195. data/spec/dummy/db/migrate/20130421155019_add_creator_string_to_series_statement.rb +7 -0
  196. data/spec/dummy/db/migrate/20130421164124_add_series_master_to_series_statement.rb +5 -0
  197. data/spec/dummy/db/migrate/20130509185724_add_statement_of_responsibility_to_manifestation.rb +5 -0
  198. data/spec/dummy/db/migrate/20130519065638_add_lock_version_to_reserve.rb +5 -0
  199. data/spec/dummy/db/migrate/20130519065837_add_lock_version_to_checkin.rb +5 -0
  200. data/spec/dummy/db/migrate/20140518050147_create_reserve_transitions.rb +14 -0
  201. data/spec/dummy/db/migrate/20140518111006_create_message_transitions.rb +14 -0
  202. data/spec/dummy/db/migrate/20140518135713_create_message_request_transitions.rb +14 -0
  203. data/spec/dummy/db/migrate/20140519170214_create_resource_import_file_transitions.rb +14 -0
  204. data/spec/dummy/db/migrate/20140519171220_create_import_request_transitions.rb +14 -0
  205. data/spec/dummy/db/migrate/20140524020735_create_agent_import_file_transitions.rb +14 -0
  206. data/spec/dummy/db/migrate/20140524135607_create_bookmark_stat_transitions.rb +14 -0
  207. data/spec/dummy/db/migrate/20140524142813_add_taggings_count_to_tag.rb +5 -0
  208. data/spec/dummy/db/migrate/20140528045518_create_user_checkout_stat_transitions.rb +14 -0
  209. data/spec/dummy/db/migrate/20140528045539_create_user_reserve_stat_transitions.rb +14 -0
  210. data/spec/dummy/db/migrate/20140528045600_create_manifestation_checkout_stat_transitions.rb +14 -0
  211. data/spec/dummy/db/migrate/20140528045617_create_manifestation_reserve_stat_transitions.rb +14 -0
  212. data/spec/dummy/db/migrate/20140529014410_create_item_transitions.rb +14 -0
  213. data/spec/dummy/db/migrate/20140614065404_create_resource_export_files.rb +11 -0
  214. data/spec/dummy/db/migrate/20140614141500_create_resource_export_file_transitions.rb +14 -0
  215. data/spec/dummy/db/migrate/20140628073524_add_user_encoding_to_agent_import_file.rb +5 -0
  216. data/spec/dummy/db/migrate/20140628073535_add_user_encoding_to_resource_import_file.rb +5 -0
  217. data/spec/dummy/db/migrate/20140810061942_add_user_id_to_stat.rb +12 -0
  218. data/spec/dummy/db/migrate/20140810091231_add_checkout_icalendar_token_to_profile.rb +6 -0
  219. data/spec/dummy/db/migrate/20140810091417_add_save_checkout_history_to_profile.rb +5 -0
  220. data/spec/dummy/db/migrate/20140811132912_add_save_search_history_to_profile.rb +5 -0
  221. data/spec/dummy/db/migrate/20140812093836_add_share_bookmarks_to_profile.rb +5 -0
  222. data/spec/dummy/db/schema.rb +632 -57
  223. data/spec/dummy/db/test.sqlite3 +0 -0
  224. data/spec/dummy/private/system/user_import_files/user_imports/980/190/963/original/user_delete_file.tsv +4 -0
  225. data/spec/dummy/private/system/user_import_files/user_imports/980/190/963/original/user_import_file_sample.tsv +7 -7
  226. data/spec/dummy/public/system/user_export_files/user_exports/000/000/003/original/user_export_file_20140815-3963-1s1td26.txt +8 -0
  227. data/spec/dummy/public/system/user_export_files/user_exports/000/000/003/original/user_export_file_20140815-69229-i0rcty.txt +8 -0
  228. data/spec/dummy/public/system/user_export_files/user_exports/000/000/003/original/user_export_file_20140816-21120-1w731r8.txt +8 -0
  229. data/spec/dummy/public/system/user_export_files/user_exports/000/000/004/original/user_export_file_20140711-28652-1dj3e98.txt +148 -0
  230. data/spec/dummy/public/system/user_export_files/user_exports/000/000/004/original/user_export_file_20140711-29117-13jb6ol.txt +148 -0
  231. data/spec/dummy/public/system/user_export_files/user_exports/000/000/004/original/user_export_file_20140721-65743-1tnagd4.txt +8 -0
  232. data/spec/dummy/public/system/user_export_files/user_exports/000/000/004/original/user_export_file_20140815-3963-1kk8o87.txt +8 -0
  233. data/spec/dummy/public/system/user_export_files/user_exports/000/000/004/original/user_export_file_20140815-69229-188nwub.txt +8 -0
  234. data/spec/dummy/public/system/user_export_files/user_exports/000/000/004/original/user_export_file_20140816-21120-twzfb6.txt +8 -0
  235. data/spec/dummy/solr/default/data/index/_4h.fdt +0 -0
  236. data/spec/dummy/solr/default/data/index/{_3h.fdx → _4h.fdx} +0 -0
  237. data/spec/dummy/solr/default/data/index/{_3h.fnm → _4h.fnm} +0 -0
  238. data/spec/dummy/solr/default/data/index/{_3h.nvd → _4h.nvd} +0 -0
  239. data/spec/dummy/solr/default/data/index/{_3h.nvm → _4h.nvm} +0 -0
  240. data/spec/dummy/solr/default/data/index/{_3h.si → _4h.si} +0 -0
  241. data/spec/dummy/solr/default/data/index/_4h_Lucene41_0.doc +0 -0
  242. data/spec/dummy/solr/default/data/index/_4h_Lucene41_0.pos +0 -0
  243. data/spec/dummy/solr/default/data/index/_4h_Lucene41_0.tim +0 -0
  244. data/spec/dummy/solr/default/data/index/_4h_Lucene41_0.tip +0 -0
  245. data/spec/dummy/solr/default/data/index/segments.gen +0 -0
  246. data/spec/dummy/solr/default/data/index/segments_97 +0 -0
  247. data/spec/dummy/solr/default/data/tlog/tlog.0000000000000000320 +0 -0
  248. data/spec/dummy/solr/default/data/tlog/tlog.0000000000000000321 +0 -0
  249. data/spec/dummy/solr/default/data/tlog/tlog.0000000000000000322 +0 -0
  250. data/spec/dummy/solr/default/data/tlog/tlog.0000000000000000323 +0 -0
  251. data/spec/dummy/solr/default/data/tlog/tlog.0000000000000000324 +0 -0
  252. data/spec/dummy/solr/default/data/tlog/tlog.0000000000000000325 +0 -0
  253. data/spec/dummy/solr/default/data/tlog/tlog.0000000000000000326 +0 -0
  254. data/spec/dummy/solr/default/data/tlog/tlog.0000000000000000327 +0 -0
  255. data/spec/dummy/solr/default/data/tlog/tlog.0000000000000000328 +0 -0
  256. data/spec/dummy/solr/default/data/tlog/tlog.0000000000000000329 +0 -0
  257. data/spec/dummy/tmp/cache/4F7/F90/default_role +0 -0
  258. data/spec/dummy/tmp/cache/ACB/B20/manifestation_search_total +0 -0
  259. data/spec/dummy/tmp/cache/assets/test/sprockets/13fe41fee1fe35b49d145bcc06610705 +0 -0
  260. data/spec/dummy/tmp/cache/assets/test/sprockets/154f7b83f2da0e86effbe25f32135177 +0 -0
  261. data/spec/dummy/tmp/cache/assets/test/sprockets/1b984bdbd3204a51a82d0e01a1569e2d +0 -0
  262. data/spec/dummy/tmp/cache/assets/test/sprockets/2f5173deea6c795b8fdde723bb4b63af +0 -0
  263. data/spec/dummy/tmp/cache/assets/test/sprockets/3054c50144654f9c7e57bb0639a276e9 +0 -0
  264. data/spec/dummy/tmp/cache/assets/test/sprockets/357970feca3ac29060c1e3861e2c0953 +0 -0
  265. data/spec/dummy/tmp/cache/assets/test/sprockets/3bd7a263237ba366f64d938fe5303757 +0 -0
  266. data/spec/dummy/tmp/cache/assets/test/sprockets/62899096da1a3e67660f3b88068be8c9 +0 -0
  267. data/spec/dummy/tmp/cache/assets/test/sprockets/65b2e4f67eab21b30217e29075f433b2 +0 -0
  268. data/spec/dummy/tmp/cache/assets/test/sprockets/87d24a3f43f175d4d17babe9203c79a7 +0 -0
  269. data/spec/dummy/tmp/cache/assets/test/sprockets/cffd775d018f68ce5dba1ee0d951a994 +0 -0
  270. data/spec/dummy/tmp/cache/assets/test/sprockets/d38d8658b30de1d068603968227680d4 +0 -0
  271. data/spec/dummy/tmp/cache/assets/test/sprockets/d771ace226fc8215a3572e0aa35bb0d6 +0 -0
  272. data/spec/dummy/tmp/cache/assets/test/sprockets/f7cbd26ba1d28d48de824f0e94586655 +0 -0
  273. data/spec/dummy/tmp/cache/stdout +246 -279
  274. data/spec/dummy/tmp/pids/redis-test.pid +1 -1
  275. data/spec/factories/profile.rb +9 -0
  276. data/spec/factories/user.rb +0 -13
  277. data/spec/fixtures/agent_import_files.yml +0 -3
  278. data/spec/fixtures/agents.yml +54 -54
  279. data/spec/fixtures/baskets.yml +4 -4
  280. data/spec/fixtures/carrier_type_has_checkout_types.yml +30 -0
  281. data/spec/fixtures/checked_items.yml +34 -0
  282. data/spec/fixtures/checkins.yml +54 -0
  283. data/spec/fixtures/checkout_stat_has_manifestations.yml +23 -0
  284. data/spec/fixtures/checkout_stat_has_users.yml +23 -0
  285. data/spec/fixtures/checkout_types.yml +33 -0
  286. data/spec/fixtures/checkouts.yml +162 -0
  287. data/spec/fixtures/circulation_statuses.yml +119 -0
  288. data/spec/fixtures/event_categories.yml +55 -0
  289. data/spec/fixtures/events.yml +142 -0
  290. data/spec/fixtures/exemplifies.yml +12 -0
  291. data/spec/fixtures/import_requests.yml +0 -2
  292. data/spec/fixtures/item_has_use_restrictions.yml +60 -0
  293. data/spec/fixtures/items.yml +101 -11
  294. data/spec/fixtures/lending_policies.yml +98 -0
  295. data/spec/fixtures/libraries.yml +26 -25
  296. data/spec/fixtures/library_groups.yml +6 -8
  297. data/spec/fixtures/manifestation_checkout_stats.yml +30 -0
  298. data/spec/fixtures/manifestation_reserve_stats.yml +30 -0
  299. data/spec/fixtures/manifestations.yml +69 -207
  300. data/spec/fixtures/message_requests.yml +27 -0
  301. data/spec/fixtures/message_templates.yml +105 -0
  302. data/spec/fixtures/profiles.yml +98 -0
  303. data/spec/fixtures/request_status_types.yml +63 -0
  304. data/spec/fixtures/request_types.yml +55 -0
  305. data/spec/fixtures/reserve_stat_has_manifestations.yml +23 -0
  306. data/spec/fixtures/reserve_stat_has_users.yml +23 -0
  307. data/spec/fixtures/reserve_transitions.yml +88 -0
  308. data/spec/fixtures/reserves.yml +162 -0
  309. data/spec/fixtures/resource_import_files.yml +0 -3
  310. data/spec/fixtures/roles.yml +0 -4
  311. data/spec/fixtures/shelves.yml +2 -3
  312. data/spec/fixtures/use_restrictions.yml +92 -0
  313. data/spec/fixtures/user_checkout_stats.yml +30 -0
  314. data/spec/fixtures/user_export_files.yml +26 -0
  315. data/spec/fixtures/user_group_has_checkout_types.yml +110 -0
  316. data/spec/fixtures/user_import_files.yml +2 -0
  317. data/spec/fixtures/user_reserve_stats.yml +30 -0
  318. data/spec/fixtures/users.yml +1 -101
  319. data/spec/models/profile_spec.rb +66 -0
  320. data/spec/models/user_export_file_spec.rb +31 -0
  321. data/spec/models/user_import_file_spec.rb +42 -20
  322. data/spec/models/user_spec.rb +1 -18
  323. data/spec/requests/{users_spec.rb → profiles_spec.rb} +3 -3
  324. data/spec/routing/accounts_spec.rb +1 -1
  325. data/spec/routing/profiles_routing_spec.rb +35 -0
  326. data/spec/support/resque.rb +1 -0
  327. data/spec/views/{users → profiles}/edit.html.erb_spec.rb +5 -7
  328. data/spec/views/{users → profiles}/index.html.erb_spec.rb +3 -3
  329. data/spec/views/{users → profiles}/new.html.erb_spec.rb +5 -5
  330. data/spec/views/profiles/show.html.erb_spec.rb +20 -0
  331. data/vendor/assets/javascripts/jquery.colorbox.js +4 -3
  332. data/vendor/assets/stylesheets/colorbox.css +1 -1
  333. metadata +416 -132
  334. data/app/controllers/users_controller.rb +0 -195
  335. data/app/models/user_sweeper.rb +0 -18
  336. data/app/views/users/_edit_credential.html.erb +0 -79
  337. data/app/views/users/edit.html.erb +0 -76
  338. data/app/views/users/index.html.erb +0 -56
  339. data/lib/enju_leaf/expire_editable_fragment.rb +0 -30
  340. data/lib/enju_leaf/expire_fragment_cache.rb +0 -17
  341. data/spec/controllers/users_controller_spec.rb +0 -539
  342. data/spec/dummy/db/migrate/20110916053430_rename_manifestation_number_list_to_number_string.rb +0 -13
  343. data/spec/dummy/db/migrate/20120415060308_rename_resource_import_file_imported_at_to_executed_at.rb +0 -9
  344. data/spec/dummy/db/migrate/20120415060323_rename_patron_import_file_imported_at_to_executed_at.rb +0 -9
  345. data/spec/dummy/db/migrate/20121119153944_add_manifestation_id_to_item.rb +0 -5
  346. data/spec/dummy/solr/default/data/index/_3h.fdt +0 -0
  347. data/spec/dummy/solr/default/data/index/_3h_Lucene41_0.doc +0 -0
  348. data/spec/dummy/solr/default/data/index/_3h_Lucene41_0.pos +0 -0
  349. data/spec/dummy/solr/default/data/index/_3h_Lucene41_0.tim +0 -0
  350. data/spec/dummy/solr/default/data/index/_3h_Lucene41_0.tip +0 -0
  351. data/spec/dummy/solr/default/data/index/segments_71 +0 -0
  352. data/spec/dummy/solr/default/data/tlog/tlog.0000000000000000242 +0 -0
  353. data/spec/dummy/solr/default/data/tlog/tlog.0000000000000000243 +0 -0
  354. data/spec/dummy/solr/default/data/tlog/tlog.0000000000000000244 +0 -0
  355. data/spec/dummy/solr/default/data/tlog/tlog.0000000000000000245 +0 -0
  356. data/spec/dummy/solr/default/data/tlog/tlog.0000000000000000246 +0 -0
  357. data/spec/dummy/solr/default/data/tlog/tlog.0000000000000000247 +0 -0
  358. data/spec/dummy/solr/default/data/tlog/tlog.0000000000000000248 +0 -0
  359. data/spec/dummy/solr/default/data/tlog/tlog.0000000000000000249 +0 -0
  360. data/spec/dummy/solr/default/data/tlog/tlog.0000000000000000250 +0 -0
  361. data/spec/dummy/solr/default/data/tlog/tlog.0000000000000000251 +0 -0
  362. data/spec/dummy/tmp/cache/assets/test/sprockets/3f8d795856d1fdf902b0be679120571a +0 -0
  363. data/spec/dummy/tmp/cache/assets/test/sprockets/5998e66e374537d52eed3fe1ca5f2bfc +0 -0
  364. data/spec/dummy/tmp/cache/assets/test/sprockets/5ea4a1824e1d67da6c4fb9aeef9f49f4 +0 -0
  365. data/spec/dummy/tmp/cache/assets/test/sprockets/87f0cb69a0df1355e33cce3949919d5a +0 -0
  366. data/spec/routing/users_routing_spec.rb +0 -35
  367. data/spec/views/users/show.html.erb_spec.rb +0 -15
@@ -0,0 +1,55 @@
1
+ ---
2
+ event_category_00002:
3
+ name: closed
4
+ display_name: 休館日
5
+ updated_at: 2008-01-01 16:24:32.561469 +09:00
6
+ id: 2
7
+ note: ""
8
+ created_at: 2008-01-01 16:17:34.642433 +09:00
9
+ position: 2
10
+ event_category_00003:
11
+ name: おはなし会
12
+ display_name: おはなし会
13
+ updated_at: 2008-01-01 16:24:45.267241 +09:00
14
+ id: 3
15
+ note: ""
16
+ created_at: 2008-01-01 16:17:45.415487 +09:00
17
+ position: 3
18
+ event_category_00004:
19
+ name: 上映会
20
+ display_name: 上映会
21
+ updated_at: 2008-01-01 16:24:55.261682 +09:00
22
+ id: 4
23
+ note: ""
24
+ created_at: 2008-01-01 16:18:08.868680 +09:00
25
+ position: 4
26
+ event_category_00005:
27
+ name: 講演会
28
+ display_name: 講演会
29
+ updated_at: 2008-01-01 16:25:04.251141 +09:00
30
+ id: 5
31
+ note: ""
32
+ created_at: 2008-01-01 16:25:04.251141 +09:00
33
+ position: 5
34
+ event_category_00001:
35
+ name: unknown
36
+ display_name: (not specified)
37
+ updated_at: 2008-01-01 16:24:17.869192 +09:00
38
+ id: 1
39
+ note: ""
40
+ created_at: 2008-01-01 16:17:12.549565 +09:00
41
+ position: 1
42
+
43
+ # == Schema Information
44
+ #
45
+ # Table name: event_categories
46
+ #
47
+ # id :integer not null, primary key
48
+ # name :string(255) not null
49
+ # display_name :text
50
+ # note :text
51
+ # position :integer
52
+ # created_at :datetime
53
+ # updated_at :datetime
54
+ #
55
+
@@ -0,0 +1,142 @@
1
+ ---
2
+ event_00001:
3
+ updated_at: 2008-01-13 02:54:43.764011 +09:00
4
+ event_category_id: 1
5
+ end_at: 2008-01-14 02:54:00 +09:00
6
+ name: !binary |
7
+ 5LuV5LqL5aeL44KB
8
+
9
+ display_name: !binary |
10
+ 5LuV5LqL5aeL44KB
11
+
12
+ deleted_at:
13
+ start_at: 2008-01-13 02:54:00 +09:00
14
+ id: 1
15
+ note: !binary |
16
+ 44Gq44KT44Go44GL44GL44KT44Go44GL
17
+
18
+ library_id: 2
19
+ created_at: 2008-01-01 16:20:54.372729 +09:00
20
+ event_00002:
21
+ updated_at: 2008-01-13 02:54:21.134175 +09:00
22
+ event_category_id: 2
23
+ end_at: 2008-01-14 02:54:00 +09:00
24
+ name: !binary |
25
+ 44OG44K544OI
26
+
27
+ display_name: !binary |
28
+ 44OG44K544OI
29
+
30
+ deleted_at:
31
+ start_at: 2008-01-13 02:54:00 +09:00
32
+ id: 2
33
+ note: !binary |
34
+ 44OG44K544OI55So44Gu44Kk44OZ44Oz44OI44Gn44GZ44CC
35
+
36
+ library_id: 2
37
+ created_at: 2008-01-01 20:54:25.803201 +09:00
38
+ event_00003:
39
+ updated_at: 2008-02-05 20:00:35.319131 +09:00
40
+ event_category_id: 1
41
+ end_at: 2008-02-05 00:00:00 +09:00
42
+ name: !binary |
43
+ 44Of44O844OG44Kj44Oz44Kw
44
+
45
+ display_name: !binary |
46
+ 44Of44O844OG44Kj44Oz44Kw
47
+
48
+ deleted_at:
49
+ start_at: 2008-01-13 00:00:00 +09:00
50
+ id: 3
51
+ note: ""
52
+ library_id: 2
53
+ created_at: 2008-01-13 02:51:10.642395 +09:00
54
+ event_00004:
55
+ updated_at: 2008-02-05 15:43:42.617670 +09:00
56
+ event_category_id: 4
57
+ end_at: 2008-02-06 00:00:00 +09:00
58
+ name: !binary |
59
+ 44OG44K544OI
60
+
61
+ display_name: !binary |
62
+ 44OG44K544OI
63
+
64
+ deleted_at:
65
+ start_at: 2008-02-05 00:00:00 +09:00
66
+ id: 4
67
+ note: !binary |
68
+ 44Gq44KT44Go44GL44GL44KT44Go44GL
69
+
70
+ library_id: 3
71
+ created_at: 2008-02-05 15:43:42.617670 +09:00
72
+ event_00005:
73
+ updated_at: 2008-02-05 20:41:50.533164 +09:00
74
+ event_category_id: 1
75
+ end_at: 2008-02-08 00:00:00 +09:00
76
+ name: test
77
+ display_name: test
78
+ deleted_at:
79
+ start_at: 2008-02-05 00:00:00 +09:00
80
+ id: 5
81
+ note: ""
82
+ library_id: 2
83
+ created_at: 2008-02-05 20:41:50.533164 +09:00
84
+ event_00006:
85
+ updated_at: 2008-02-05 23:52:06.315285 +09:00
86
+ event_category_id: 2
87
+ end_at: 2008-02-08 00:00:00 +09:00
88
+ name: !binary |
89
+ 44Gq44KT44Go44GL44GL44KT44Go44GL
90
+
91
+ display_name: !binary |
92
+ 44Gq44KT44Go44GL44GL44KT44Go44GL
93
+
94
+ deleted_at:
95
+ start_at: 2008-02-05 00:00:00 +09:00
96
+ id: 6
97
+ note: ""
98
+ library_id: 2
99
+ created_at: 2008-02-05 20:50:26.651371 +09:00
100
+ event_00007:
101
+ updated_at: 2008-02-05 21:00:53.926050 +09:00
102
+ event_category_id: 1
103
+ end_at: 2008-02-08 00:00:00 +09:00
104
+ name: test
105
+ display_name: test
106
+ deleted_at:
107
+ start_at: 2008-02-05 00:00:00 +09:00
108
+ id: 7
109
+ note: test
110
+ library_id: 2
111
+ created_at: 2008-02-05 21:00:53.926050 +09:00
112
+ event_00008:
113
+ updated_at: 2008-02-05 21:00:53.926050 +09:00
114
+ event_category_id: 1
115
+ end_at: 2008-02-05 15:00:00 +09:00
116
+ name: test
117
+ display_name: test
118
+ deleted_at:
119
+ start_at: 2008-02-05 15:00:00 +09:00
120
+ id: 8
121
+ note: test
122
+ library_id: 2
123
+ created_at: 2008-02-05 21:00:53.926050 +09:00
124
+
125
+ # == Schema Information
126
+ #
127
+ # Table name: events
128
+ #
129
+ # id :integer not null, primary key
130
+ # library_id :integer default(1), not null
131
+ # event_category_id :integer default(1), not null
132
+ # name :string(255)
133
+ # note :text
134
+ # start_at :datetime
135
+ # end_at :datetime
136
+ # all_day :boolean default(FALSE), not null
137
+ # deleted_at :datetime
138
+ # created_at :datetime
139
+ # updated_at :datetime
140
+ # display_name :text
141
+ #
142
+
@@ -139,6 +139,18 @@ exemplify_00023:
139
139
  manifestation_id: 11
140
140
  id: 23
141
141
  created_at: 2008-01-11 02:44:37.135721 +09:00
142
+ exemplify_00024:
143
+ updated_at: 2008-01-11 02:44:37.135721 +09:00
144
+ item_id: 24
145
+ manifestation_id: 3
146
+ id: 24
147
+ created_at: 2008-01-11 02:44:37.135721 +09:00
148
+ exemplify_00025:
149
+ updated_at: 2008-01-11 02:44:37.135721 +09:00
150
+ item_id: 25
151
+ manifestation_id: 8
152
+ id: 25
153
+ created_at: 2008-01-11 02:44:37.135721 +09:00
142
154
 
143
155
 
144
156
  # == Schema Information
@@ -2,13 +2,11 @@
2
2
 
3
3
  one:
4
4
  isbn: '978-4774142043'
5
- state: pending
6
5
  manifestation_id: 1
7
6
  user_id: 1
8
7
 
9
8
  two:
10
9
  isbn: '978-4774141640'
11
- state: pending
12
10
  manifestation_id: 2
13
11
  user_id: 1
14
12
 
@@ -0,0 +1,60 @@
1
+ ---
2
+ item_has_use_restriction_00001:
3
+ item_id: 1
4
+ updated_at: 2008-02-13 12:29:36.013448 +09:00
5
+ id: 1
6
+ use_restriction_id: 10
7
+ created_at: 2008-02-13 12:29:36.013448 +09:00
8
+ item_has_use_restriction_00002:
9
+ item_id: 2
10
+ updated_at: 2008-02-13 17:58:37.527556 +09:00
11
+ id: 2
12
+ use_restriction_id: 2
13
+ created_at: 2008-02-13 17:58:37.527556 +09:00
14
+ item_has_use_restriction_00003:
15
+ item_id: 3
16
+ updated_at: 2008-02-13 17:58:49.490086 +09:00
17
+ id: 3
18
+ use_restriction_id: 3
19
+ created_at: 2008-02-13 17:58:49.490086 +09:00
20
+ item_has_use_restriction_00004:
21
+ item_id: 17
22
+ updated_at: 2008-02-13 12:29:36.013448 +09:00
23
+ id: 4
24
+ use_restriction_id: 4
25
+ created_at: 2008-02-13 12:29:36.013448 +09:00
26
+ item_has_use_restriction_00005:
27
+ item_id: 21
28
+ updated_at: 2008-02-13 12:29:36.013448 +09:00
29
+ id: 5
30
+ use_restriction_id: 4
31
+ created_at: 2008-02-13 12:29:36.013448 +09:00
32
+ item_has_use_restriction_00006:
33
+ item_id: 11
34
+ updated_at: 2008-02-13 12:29:36.013448 +09:00
35
+ id: 6
36
+ use_restriction_id: 4
37
+ created_at: 2008-02-13 12:29:36.013448 +09:00
38
+ item_has_use_restriction_00007:
39
+ item_id: 6
40
+ updated_at: 2008-02-13 12:29:36.013448 +09:00
41
+ id: 7
42
+ use_restriction_id: 4
43
+ created_at: 2008-02-13 12:29:36.013448 +09:00
44
+ item_has_use_restriction_00008:
45
+ item_id: 24
46
+ updated_at: 2008-02-13 12:29:36.013448 +09:00
47
+ id: 8
48
+ use_restriction_id: 4
49
+ created_at: 2008-02-13 12:29:36.013448 +09:00
50
+
51
+ # == Schema Information
52
+ #
53
+ # Table name: item_has_use_restrictions
54
+ #
55
+ # id :integer not null, primary key
56
+ # item_id :integer not null
57
+ # use_restriction_id :integer not null
58
+ # created_at :datetime
59
+ # updated_at :datetime
60
+ #
@@ -2,212 +2,302 @@
2
2
  item_00001:
3
3
  updated_at: 2007-08-24 23:46:00.484813 +09:00
4
4
  item_identifier: '00001'
5
+ circulation_status_id: 2
6
+ checkout_type_id: 1
5
7
  shelf_id: 1
6
8
  call_number:
9
+ manifestation_id: 1
7
10
  id: 1
8
11
  include_supplements: false
9
12
  created_at: 2007-08-24 23:46:00.484813 +09:00
10
13
  item_00002:
11
14
  updated_at: 2007-08-24 23:46:01.641413 +09:00
12
15
  item_identifier: '00002'
16
+ circulation_status_id: 2
17
+ checkout_type_id: 1
13
18
  shelf_id: 1
14
19
  call_number:
20
+ manifestation_id: 2
15
21
  id: 2
16
22
  include_supplements: false
17
23
  created_at: 2007-08-24 23:46:01.641413 +09:00
18
24
  item_00003:
19
25
  updated_at: 2007-08-24 23:46:02.502569 +09:00
20
26
  item_identifier: '00003'
27
+ circulation_status_id: 2
28
+ checkout_type_id: 2
21
29
  shelf_id: 1
22
30
  call_number:
31
+ manifestation_id: 3
23
32
  id: 3
24
33
  include_supplements: false
25
34
  created_at: 2007-08-24 23:46:02.502569 +09:00
26
35
  item_00004:
27
36
  updated_at: 2007-08-24 23:46:03.520781 +09:00
28
37
  item_identifier: '00004'
38
+ circulation_status_id: 2
39
+ checkout_type_id: 1
29
40
  shelf_id: 1
30
41
  call_number:
42
+ manifestation_id: 1
31
43
  id: 4
32
44
  include_supplements: true
33
45
  created_at: 2007-08-24 23:46:03.520781 +09:00
34
46
  item_00005:
35
47
  updated_at: 2007-08-24 23:46:04.538073 +09:00
36
48
  item_identifier: '00005'
49
+ circulation_status_id: 2
50
+ checkout_type_id: 2
37
51
  shelf_id: 1
38
52
  call_number:
53
+ manifestation_id: 2
39
54
  id: 5
40
55
  include_supplements: false
41
56
  created_at: 2007-08-24 23:46:04.538073 +09:00
42
57
  item_00006:
43
58
  updated_at: 2007-08-24 23:46:05.555353 +09:00
44
59
  item_identifier: '00006'
60
+ circulation_status_id: 2
61
+ checkout_type_id: 2
45
62
  shelf_id: 1
46
63
  call_number:
64
+ manifestation_id: 3
47
65
  id: 6
48
66
  include_supplements: true
49
67
  created_at: 2007-08-24 23:46:05.555353 +09:00
50
68
  item_00007:
51
69
  updated_at: 2007-08-24 23:46:06.572631 +09:00
52
70
  item_identifier: '00007'
71
+ circulation_status_id: 2
72
+ checkout_type_id: 1
53
73
  shelf_id: 1
54
74
  call_number:
75
+ manifestation_id: 1
55
76
  id: 7
56
77
  include_supplements: false
57
78
  created_at: 2007-08-24 23:46:06.572631 +09:00
58
79
  item_00008:
59
80
  updated_at: 2007-08-24 23:46:07.589909 +09:00
60
81
  item_identifier: '00008'
82
+ circulation_status_id: 2
83
+ checkout_type_id: 2
61
84
  shelf_id: 1
62
85
  call_number:
86
+ manifestation_id: 2
63
87
  id: 8
64
88
  include_supplements: true
65
89
  created_at: 2007-08-24 23:46:07.589909 +09:00
66
90
  item_00009:
67
91
  updated_at: 2007-08-24 23:46:08.607081 +09:00
68
92
  item_identifier: '00009'
93
+ circulation_status_id: 2
94
+ checkout_type_id: 1
69
95
  shelf_id: 4
70
96
  call_number:
97
+ manifestation_id: 3
71
98
  id: 9
72
99
  include_supplements: false
73
100
  created_at: 2007-08-24 23:46:08.607081 +09:00
74
101
  item_00010:
75
102
  updated_at: 2007-08-24 23:46:09.624281 +09:00
76
103
  item_identifier: '00010'
104
+ circulation_status_id: 2
105
+ checkout_type_id: 2
77
106
  shelf_id: 1
78
107
  call_number:
108
+ manifestation_id: 1
79
109
  id: 10
80
110
  include_supplements: false
81
111
  created_at: 2007-08-24 23:46:09.624281 +09:00
82
112
  item_00011:
83
113
  updated_at: 2007-08-24 23:46:10.484813 +09:00
84
114
  item_identifier: '00011'
115
+ circulation_status_id: 2
116
+ checkout_type_id: 1
85
117
  shelf_id: 1
86
118
  call_number:
119
+ manifestation_id: 1
87
120
  id: 11
88
121
  include_supplements: false
89
122
  created_at: 2007-08-24 23:46:10.484813 +09:00
90
123
  item_00012:
91
124
  updated_at: 2007-08-24 23:46:11.484813 +09:00
92
125
  item_identifier: '00012'
126
+ circulation_status_id: 3
127
+ checkout_type_id: 2
93
128
  shelf_id: 1
94
129
  call_number:
130
+ manifestation_id: 2
95
131
  id: 12
96
132
  include_supplements: false
97
133
  created_at: 2007-08-24 23:46:11.484813 +09:00
98
134
  item_00013:
99
135
  updated_at: 2007-08-24 23:46:12.484813 +09:00
100
136
  item_identifier: '00013'
137
+ circulation_status_id: 10
138
+ checkout_type_id: 1
101
139
  shelf_id: 1
102
140
  call_number:
141
+ manifestation_id: 2
103
142
  id: 13
104
143
  include_supplements: false
105
144
  created_at: 2007-08-24 23:46:12.484813 +09:00
106
145
  item_00014:
107
146
  updated_at: 2007-08-24 23:46:13.484813 +09:00
108
147
  item_identifier: '00014'
148
+ circulation_status_id: 10
149
+ checkout_type_id: 2
109
150
  shelf_id: 1
110
151
  call_number:
152
+ manifestation_id: 2
111
153
  id: 14
112
154
  include_supplements: false
113
155
  created_at: 2007-08-24 23:46:13.484813 +09:00
114
156
  item_00015:
115
157
  updated_at: 2007-08-24 23:46:14.484813 +09:00
116
158
  item_identifier: '00015'
159
+ circulation_status_id: 10
160
+ checkout_type_id: 3
117
161
  shelf_id: 1
118
162
  call_number:
163
+ manifestation_id: 2
119
164
  id: 15
120
165
  include_supplements: false
121
166
  created_at: 2007-08-24 23:46:14.484813 +09:00
122
167
  item_00016:
123
168
  updated_at: 2007-08-24 23:46:15.484813 +09:00
124
169
  item_identifier: '00016'
170
+ circulation_status_id: 10
171
+ checkout_type_id: 2
125
172
  shelf_id: 1
126
173
  call_number:
174
+ manifestation_id: 3
127
175
  id: 16
128
176
  include_supplements: true
129
177
  created_at: 2007-08-24 23:46:15.484813 +09:00
130
178
  item_00017:
131
179
  updated_at: 2007-08-24 23:46:16.484813 +09:00
132
180
  item_identifier: '00017'
181
+ circulation_status_id: 10
182
+ checkout_type_id: 3
133
183
  shelf_id: 1
134
184
  call_number:
185
+ manifestation_id: 3
135
186
  id: 17
136
187
  include_supplements: false
137
188
  created_at: 2007-08-24 23:46:16.484813 +09:00
138
189
  item_00018:
139
190
  updated_at: 2007-08-24 23:46:17.484813 +09:00
140
191
  item_identifier: '00018'
192
+ circulation_status_id: 10
193
+ checkout_type_id: 3
141
194
  shelf_id: 1
142
195
  call_number:
196
+ manifestation_id: 1
143
197
  id: 18
144
198
  include_supplements: false
145
199
  created_at: 2007-08-24 23:46:17.484813 +09:00
146
200
  item_00019:
147
201
  updated_at: 2007-08-24 23:46:18.484813 +09:00
148
202
  item_identifier: '00019'
203
+ circulation_status_id: 2
204
+ checkout_type_id: 3
149
205
  shelf_id: 1
150
206
  call_number:
207
+ manifestation_id: 1
151
208
  id: 19
152
209
  include_supplements: false
153
210
  created_at: 2007-08-24 23:46:18.484813 +09:00
154
211
  item_00020:
155
212
  updated_at: 2007-08-24 23:46:19.484813 +09:00
156
213
  item_identifier: '00020'
214
+ circulation_status_id: 13
215
+ checkout_type_id: 3
157
216
  shelf_id: 1
158
217
  call_number:
218
+ manifestation_id: 1
159
219
  id: 20
160
220
  include_supplements: false
161
221
  created_at: 2007-08-24 23:46:19.484813 +09:00
162
222
  item_00021:
163
223
  updated_at: 2007-08-24 23:46:20.484813 +09:00
164
224
  item_identifier: '00021'
225
+ circulation_status_id: 2
226
+ checkout_type_id: 3
165
227
  shelf_id: 1
166
228
  call_number:
229
+ manifestation_id: 11
167
230
  id: 21
168
231
  include_supplements: false
169
232
  created_at: 2007-08-24 23:46:20.484813 +09:00
170
233
  item_00022:
171
234
  updated_at: 2007-08-24 23:46:20.484813 +09:00
172
235
  item_identifier: '00022'
236
+ circulation_status_id: 2
237
+ checkout_type_id: 3
173
238
  shelf_id: 1
174
239
  call_number:
240
+ manifestation_id: 11
175
241
  id: 22
176
242
  include_supplements: false
177
243
  created_at: 2007-08-24 23:46:20.484813 +09:00
178
244
  item_00023:
179
245
  updated_at: 2007-08-24 23:46:20.484813 +09:00
180
246
  item_identifier: '00023'
247
+ circulation_status_id: 15
248
+ checkout_type_id: 3
181
249
  shelf_id: 2
182
250
  call_number:
251
+ manifestation_id: 11
183
252
  id: 23
184
253
  include_supplements: false
185
254
  created_at: 2007-08-24 23:46:20.484813 +09:00
186
-
255
+ item_00024:
256
+ updated_at: 2007-08-24 23:46:20.484813 +09:00
257
+ item_identifier: '00024'
258
+ circulation_status_id: 8
259
+ checkout_type_id: 3
260
+ shelf_id: 2
261
+ call_number:
262
+ manifestation_id: 3
263
+ id: 24
264
+ include_supplements: false
265
+ created_at: 2007-08-24 23:46:20.484813 +09:00
266
+ item_00025:
267
+ updated_at: 2007-08-24 23:46:20.484813 +09:00
268
+ item_identifier: '00025'
269
+ circulation_status_id: 8
270
+ checkout_type_id: 3
271
+ shelf_id: 2
272
+ call_number:
273
+ manifestation_id: 8
274
+ id: 25
275
+ include_supplements: false
276
+ created_at: 2007-08-24 23:46:20.484813 +09:00
187
277
 
188
278
  # == Schema Information
189
279
  #
190
280
  # Table name: items
191
281
  #
192
- # id :integer not null, primary key
282
+ # id :integer not null, primary key
193
283
  # call_number :string(255)
194
284
  # item_identifier :string(255)
195
- # created_at :datetime not null
196
- # updated_at :datetime not null
285
+ # created_at :datetime not null
286
+ # updated_at :datetime not null
197
287
  # deleted_at :datetime
198
- # shelf_id :integer default(1), not null
199
- # include_supplements :boolean default(FALSE), not null
200
- # owns_count :integer default(0), not null
288
+ # shelf_id :integer default(1), not null
289
+ # include_supplements :boolean default(FALSE), not null
201
290
  # note :text
202
291
  # url :string(255)
203
292
  # price :integer
204
- # lock_version :integer default(0), not null
205
- # required_role_id :integer default(1), not null
293
+ # lock_version :integer default(0), not null
294
+ # required_role_id :integer default(1), not null
206
295
  # state :string(255)
207
- # required_score :integer default(0), not null
296
+ # required_score :integer default(0), not null
208
297
  # acquired_at :datetime
209
298
  # bookstore_id :integer
210
- # missing_since :datetime
211
299
  # budget_type_id :integer
300
+ # circulation_status_id :integer default(5), not null
301
+ # checkout_type_id :integer default(1), not null
212
302
  #
213
303
 
@@ -0,0 +1,98 @@
1
+ # Read about fixtures at http://ar.rubyonrails.org/classes/Fixtures.html
2
+
3
+ lending_policy_00001:
4
+ item_id: 1
5
+ user_group_id: 1
6
+ loan_period: 1
7
+ fixed_due_date:
8
+ renewal: 1
9
+ fine: 10
10
+ note: MyText
11
+ position: 1
12
+ lending_policy_00002:
13
+ item_id: 1
14
+ user_group_id: 2
15
+ loan_period: 1
16
+ fixed_due_date:
17
+ renewal: 1
18
+ fine: 10
19
+ note: MyText
20
+ position: 2
21
+ lending_policy_00003:
22
+ item_id: 10
23
+ user_group_id: 2
24
+ loan_period: 1
25
+ fixed_due_date:
26
+ renewal: 1
27
+ fine: 10
28
+ note: MyText
29
+ position: 1
30
+ lending_policy_00004:
31
+ item_id: 6
32
+ user_group_id: 1
33
+ loan_period: 1
34
+ fixed_due_date:
35
+ renewal: 1
36
+ fine: 10
37
+ note: MyText
38
+ position: 1
39
+ lending_policy_00005:
40
+ item_id: 6
41
+ user_group_id: 2
42
+ loan_period: 1
43
+ fixed_due_date:
44
+ renewal: 1
45
+ fine: 10
46
+ note: MyText
47
+ position: 1
48
+ lending_policy_00006:
49
+ item_id: 11
50
+ user_group_id: 1
51
+ loan_period: 1
52
+ fixed_due_date:
53
+ renewal: 1
54
+ fine: 10
55
+ note: MyText
56
+ position: 1
57
+ note: MyText
58
+ position: 1
59
+ lending_policy_00007:
60
+ item_id: 21
61
+ user_group_id: 1
62
+ loan_period: 1
63
+ fixed_due_date:
64
+ renewal: 1
65
+ fine: 10
66
+ note: MyText
67
+ position: 1
68
+ lending_policy_00008:
69
+ item_id: 11
70
+ user_group_id: 2
71
+ loan_period: 1
72
+ fixed_due_date:
73
+ renewal: 1
74
+ fine: 10
75
+ lending_policy_00009:
76
+ item_id: 24
77
+ user_group_id: 2
78
+ loan_period: 1
79
+ fixed_due_date:
80
+ renewal: 1
81
+ fine: 10
82
+
83
+ # == Schema Information
84
+ #
85
+ # Table name: lending_policies
86
+ #
87
+ # id :integer not null, primary key
88
+ # item_id :integer not null
89
+ # user_group_id :integer not null
90
+ # loan_period :integer default(0), not null
91
+ # fixed_due_date :datetime
92
+ # renewal :integer default(0), not null
93
+ # fine :integer default(0), not null
94
+ # note :text
95
+ # position :integer
96
+ # created_at :datetime
97
+ # updated_at :datetime
98
+ #