upstream-rails_admin 1.0.2
Sign up to get free protection for your applications and to get access to all the features.
- data/Gemfile +74 -0
- data/LICENSE.md +20 -0
- data/README.md +162 -0
- data/Rakefile +19 -0
- data/app/assets/images/rails_admin/aristo/images/bg_fallback.png +0 -0
- data/app/assets/images/rails_admin/aristo/images/icon_sprite.png +0 -0
- data/app/assets/images/rails_admin/aristo/images/progress_bar.gif +0 -0
- data/app/assets/images/rails_admin/aristo/images/slider_handles.png +0 -0
- data/app/assets/images/rails_admin/aristo/images/ui-icons_222222_256x240.png +0 -0
- data/app/assets/images/rails_admin/aristo/images/ui-icons_454545_256x240.png +0 -0
- data/app/assets/images/rails_admin/bullet_black.png +0 -0
- data/app/assets/images/rails_admin/bullet_white.png +0 -0
- data/app/assets/images/rails_admin/calendar.png +0 -0
- data/app/assets/images/rails_admin/clock.png +0 -0
- data/app/assets/images/rails_admin/colorpicker/colorpicker_background.png +0 -0
- data/app/assets/images/rails_admin/colorpicker/colorpicker_hex.png +0 -0
- data/app/assets/images/rails_admin/colorpicker/colorpicker_hsb_b.png +0 -0
- data/app/assets/images/rails_admin/colorpicker/colorpicker_hsb_h.png +0 -0
- data/app/assets/images/rails_admin/colorpicker/colorpicker_hsb_s.png +0 -0
- data/app/assets/images/rails_admin/colorpicker/colorpicker_indic.gif +0 -0
- data/app/assets/images/rails_admin/colorpicker/colorpicker_overlay.png +0 -0
- data/app/assets/images/rails_admin/colorpicker/colorpicker_rgb_b.png +0 -0
- data/app/assets/images/rails_admin/colorpicker/colorpicker_rgb_g.png +0 -0
- data/app/assets/images/rails_admin/colorpicker/colorpicker_rgb_r.png +0 -0
- data/app/assets/images/rails_admin/colorpicker/colorpicker_select.gif +0 -0
- data/app/assets/images/rails_admin/colorpicker/colorpicker_submit.png +0 -0
- data/app/assets/images/rails_admin/colorpicker/custom_background.png +0 -0
- data/app/assets/images/rails_admin/colorpicker/custom_hex.png +0 -0
- data/app/assets/images/rails_admin/colorpicker/custom_hsb_b.png +0 -0
- data/app/assets/images/rails_admin/colorpicker/custom_hsb_h.png +0 -0
- data/app/assets/images/rails_admin/colorpicker/custom_hsb_s.png +0 -0
- data/app/assets/images/rails_admin/colorpicker/custom_indic.gif +0 -0
- data/app/assets/images/rails_admin/colorpicker/custom_rgb_b.png +0 -0
- data/app/assets/images/rails_admin/colorpicker/custom_rgb_g.png +0 -0
- data/app/assets/images/rails_admin/colorpicker/custom_rgb_r.png +0 -0
- data/app/assets/images/rails_admin/colorpicker/custom_submit.png +0 -0
- data/app/assets/images/rails_admin/colorpicker/select.png +0 -0
- data/app/assets/images/rails_admin/colorpicker/select2.png +0 -0
- data/app/assets/images/rails_admin/colorpicker/slider.png +0 -0
- data/app/assets/images/rails_admin/logo.png +0 -0
- data/app/assets/images/rails_admin/magnifier.png +0 -0
- data/app/assets/images/rails_admin/multiselect/icon_sprite.png +0 -0
- data/app/assets/images/rails_admin/multiselect/ui-icon-circle-triangle-n-dark.png +0 -0
- data/app/assets/images/rails_admin/multiselect/ui-icon-circle-triangle-n-light.png +0 -0
- data/app/assets/images/rails_admin/multiselect/ui-icon-circle-triangle-s-dark.png +0 -0
- data/app/assets/images/rails_admin/multiselect/ui-icon-circle-triangle-s-light.png +0 -0
- data/app/assets/javascripts/rails_admin/custom/ui.js +12 -0
- data/app/assets/javascripts/rails_admin/jquery.colorpicker.js +484 -0
- data/app/assets/javascripts/rails_admin/jquery.pjax.js +543 -0
- data/app/assets/javascripts/rails_admin/jquery.ui.timepicker.js +1371 -0
- data/app/assets/javascripts/rails_admin/ra.datetimepicker.js +67 -0
- data/app/assets/javascripts/rails_admin/ra.filter-box.js +129 -0
- data/app/assets/javascripts/rails_admin/ra.filtering-multiselect.js +280 -0
- data/app/assets/javascripts/rails_admin/ra.filtering-select.js +181 -0
- data/app/assets/javascripts/rails_admin/ra.nested-form-hooks.coffee +41 -0
- data/app/assets/javascripts/rails_admin/ra.remote-form.js +152 -0
- data/app/assets/javascripts/rails_admin/ra.widgets.coffee +135 -0
- data/app/assets/javascripts/rails_admin/rails_admin.js.erb +27 -0
- data/app/assets/javascripts/rails_admin/themes/cerulean/ui.js +0 -0
- data/app/assets/javascripts/rails_admin/themes/default/ui.js +12 -0
- data/app/assets/javascripts/rails_admin/ui.js.coffee +65 -0
- data/app/assets/stylesheets/rails_admin/aristo/images/bg_fallback.png +0 -0
- data/app/assets/stylesheets/rails_admin/aristo/images/icon_sprite.png +0 -0
- data/app/assets/stylesheets/rails_admin/aristo/images/progress_bar.gif +0 -0
- data/app/assets/stylesheets/rails_admin/aristo/images/slider_handles.png +0 -0
- data/app/assets/stylesheets/rails_admin/aristo/images/ui-icons_222222_256x240.png +0 -0
- data/app/assets/stylesheets/rails_admin/aristo/images/ui-icons_454545_256x240.png +0 -0
- data/app/assets/stylesheets/rails_admin/aristo/jquery-ui-1.8.7.custom.css.scss +733 -0
- data/app/assets/stylesheets/rails_admin/base/README +2 -0
- data/app/assets/stylesheets/rails_admin/base/mixins.css.scss +1 -0
- data/app/assets/stylesheets/rails_admin/base/theming.css.scss +270 -0
- data/app/assets/stylesheets/rails_admin/base/variables.css.scss +1 -0
- data/app/assets/stylesheets/rails_admin/custom/mixins.css.scss +12 -0
- data/app/assets/stylesheets/rails_admin/custom/theming.css.scss +13 -0
- data/app/assets/stylesheets/rails_admin/custom/variables.css.scss +15 -0
- data/app/assets/stylesheets/rails_admin/imports.css.scss.erb +78 -0
- data/app/assets/stylesheets/rails_admin/jquery.colorpicker.css.scss +180 -0
- data/app/assets/stylesheets/rails_admin/jquery.ui.timepicker.css.scss +69 -0
- data/app/assets/stylesheets/rails_admin/ra.calendar-additions.css.scss +25 -0
- data/app/assets/stylesheets/rails_admin/ra.filtering-multiselect.css.scss +85 -0
- data/app/assets/stylesheets/rails_admin/rails_admin.css +4 -0
- data/app/assets/stylesheets/rails_admin/themes/cerulean/mixins.css.scss +0 -0
- data/app/assets/stylesheets/rails_admin/themes/cerulean/theming.css.scss +97 -0
- data/app/assets/stylesheets/rails_admin/themes/cerulean/variables.css.scss +168 -0
- data/app/assets/stylesheets/rails_admin/themes/default/mixins.css.scss +8 -0
- data/app/assets/stylesheets/rails_admin/themes/default/theming.css.scss +11 -0
- data/app/assets/stylesheets/rails_admin/themes/default/variables.css.scss +12 -0
- data/app/controllers/rails_admin/application_controller.rb +82 -0
- data/app/controllers/rails_admin/main_controller.rb +155 -0
- data/app/helpers/rails_admin/application_helper.rb +125 -0
- data/app/helpers/rails_admin/form_builder.rb +113 -0
- data/app/helpers/rails_admin/main_helper.rb +36 -0
- data/app/views/kaminari/twitter-bootstrap/_gap.html.haml +2 -0
- data/app/views/kaminari/twitter-bootstrap/_next_page.html.haml +4 -0
- data/app/views/kaminari/twitter-bootstrap/_page.html.haml +4 -0
- data/app/views/kaminari/twitter-bootstrap/_paginator.html.haml +10 -0
- data/app/views/kaminari/twitter-bootstrap/_prev_page.html.haml +4 -0
- data/app/views/layouts/rails_admin/_secondary_navigation.html.haml +12 -0
- data/app/views/layouts/rails_admin/application.html.haml +26 -0
- data/app/views/layouts/rails_admin/pjax.html.haml +20 -0
- data/app/views/rails_admin/main/_dashboard_history.html.haml +10 -0
- data/app/views/rails_admin/main/_delete_notice.html.haml +18 -0
- data/app/views/rails_admin/main/_form_colorpicker.html.haml +1 -0
- data/app/views/rails_admin/main/_form_datetime.html.haml +1 -0
- data/app/views/rails_admin/main/_form_enumeration.html.haml +1 -0
- data/app/views/rails_admin/main/_form_field.html.haml +1 -0
- data/app/views/rails_admin/main/_form_file_upload.html.haml +13 -0
- data/app/views/rails_admin/main/_form_filtering_multiselect.html.haml +47 -0
- data/app/views/rails_admin/main/_form_filtering_select.html.haml +37 -0
- data/app/views/rails_admin/main/_form_nested_many.html.haml +14 -0
- data/app/views/rails_admin/main/_form_nested_one.html.haml +10 -0
- data/app/views/rails_admin/main/_form_polymorphic_association.html.haml +10 -0
- data/app/views/rails_admin/main/_form_text.html.haml +15 -0
- data/app/views/rails_admin/main/_submit_buttons.html.haml +15 -0
- data/app/views/rails_admin/main/bulk_delete.html.haml +11 -0
- data/app/views/rails_admin/main/dashboard.html.haml +31 -0
- data/app/views/rails_admin/main/delete.html.haml +18 -0
- data/app/views/rails_admin/main/edit.html.haml +2 -0
- data/app/views/rails_admin/main/export.html.haml +75 -0
- data/app/views/rails_admin/main/history.html.haml +42 -0
- data/app/views/rails_admin/main/index.html.haml +140 -0
- data/app/views/rails_admin/main/new.html.haml +2 -0
- data/app/views/rails_admin/main/show.html.haml +14 -0
- data/config/initializers/active_record_extensions.rb +19 -0
- data/config/initializers/devise_patch.rb +9 -0
- data/config/initializers/haml.rb +2 -0
- data/config/initializers/mongoid_extensions.rb +5 -0
- data/config/locales/fr.yml +24 -0
- data/config/locales/rails_admin.en.yml +130 -0
- data/config/routes.rb +12 -0
- data/lib/generators/rails_admin/install_generator.rb +84 -0
- data/lib/generators/rails_admin/templates/drop.rb +18 -0
- data/lib/generators/rails_admin/templates/initializer.erb +101 -0
- data/lib/generators/rails_admin/templates/migration.rb +18 -0
- data/lib/generators/rails_admin/uninstall_generator.rb +22 -0
- data/lib/generators/rails_admin/utils.rb +30 -0
- data/lib/rails_admin.rb +34 -0
- data/lib/rails_admin/abstract_model.rb +108 -0
- data/lib/rails_admin/adapters/active_record.rb +255 -0
- data/lib/rails_admin/adapters/active_record/abstract_object.rb +32 -0
- data/lib/rails_admin/adapters/mongoid.rb +390 -0
- data/lib/rails_admin/adapters/mongoid/abstract_object.rb +48 -0
- data/lib/rails_admin/adapters/mongoid/extension.rb +48 -0
- data/lib/rails_admin/config.rb +323 -0
- data/lib/rails_admin/config/actions.rb +121 -0
- data/lib/rails_admin/config/actions/base.rb +117 -0
- data/lib/rails_admin/config/actions/bulk_delete.rb +55 -0
- data/lib/rails_admin/config/actions/dashboard.rb +46 -0
- data/lib/rails_admin/config/actions/delete.rb +53 -0
- data/lib/rails_admin/config/actions/edit.rb +60 -0
- data/lib/rails_admin/config/actions/export.rb +40 -0
- data/lib/rails_admin/config/actions/history_index.rb +38 -0
- data/lib/rails_admin/config/actions/history_show.rb +38 -0
- data/lib/rails_admin/config/actions/index.rb +85 -0
- data/lib/rails_admin/config/actions/new.rb +64 -0
- data/lib/rails_admin/config/actions/show.rb +32 -0
- data/lib/rails_admin/config/actions/show_in_app.rb +28 -0
- data/lib/rails_admin/config/configurable.rb +92 -0
- data/lib/rails_admin/config/fields.rb +88 -0
- data/lib/rails_admin/config/fields/association.rb +108 -0
- data/lib/rails_admin/config/fields/base.rb +298 -0
- data/lib/rails_admin/config/fields/factories/association.rb +32 -0
- data/lib/rails_admin/config/fields/factories/carrierwave.rb +31 -0
- data/lib/rails_admin/config/fields/factories/devise.rb +27 -0
- data/lib/rails_admin/config/fields/factories/dragonfly.rb +27 -0
- data/lib/rails_admin/config/fields/factories/enum.rb +11 -0
- data/lib/rails_admin/config/fields/factories/paperclip.rb +26 -0
- data/lib/rails_admin/config/fields/factories/password.rb +17 -0
- data/lib/rails_admin/config/fields/factories/serialized.rb +17 -0
- data/lib/rails_admin/config/fields/group.rb +78 -0
- data/lib/rails_admin/config/fields/types.rb +27 -0
- data/lib/rails_admin/config/fields/types/all.rb +25 -0
- data/lib/rails_admin/config/fields/types/belongs_to_association.rb +41 -0
- data/lib/rails_admin/config/fields/types/boolean.rb +31 -0
- data/lib/rails_admin/config/fields/types/bson_object_id.rb +42 -0
- data/lib/rails_admin/config/fields/types/carrierwave.rb +31 -0
- data/lib/rails_admin/config/fields/types/color.rb +37 -0
- data/lib/rails_admin/config/fields/types/date.rb +24 -0
- data/lib/rails_admin/config/fields/types/datetime.rb +163 -0
- data/lib/rails_admin/config/fields/types/decimal.rb +14 -0
- data/lib/rails_admin/config/fields/types/dragonfly.rb +41 -0
- data/lib/rails_admin/config/fields/types/enum.rb +35 -0
- data/lib/rails_admin/config/fields/types/file_upload.rb +61 -0
- data/lib/rails_admin/config/fields/types/float.rb +14 -0
- data/lib/rails_admin/config/fields/types/has_and_belongs_to_many_association.rb +14 -0
- data/lib/rails_admin/config/fields/types/has_many_association.rb +32 -0
- data/lib/rails_admin/config/fields/types/has_one_association.rb +39 -0
- data/lib/rails_admin/config/fields/types/hidden.rb +21 -0
- data/lib/rails_admin/config/fields/types/integer.rb +22 -0
- data/lib/rails_admin/config/fields/types/paperclip.rb +28 -0
- data/lib/rails_admin/config/fields/types/password.rb +39 -0
- data/lib/rails_admin/config/fields/types/polymorphic_association.rb +76 -0
- data/lib/rails_admin/config/fields/types/serialized.rb +22 -0
- data/lib/rails_admin/config/fields/types/string.rb +41 -0
- data/lib/rails_admin/config/fields/types/text.rb +36 -0
- data/lib/rails_admin/config/fields/types/time.rb +36 -0
- data/lib/rails_admin/config/fields/types/timestamp.rb +18 -0
- data/lib/rails_admin/config/groupable.rb +18 -0
- data/lib/rails_admin/config/has_fields.rb +135 -0
- data/lib/rails_admin/config/has_groups.rb +23 -0
- data/lib/rails_admin/config/hideable.rb +28 -0
- data/lib/rails_admin/config/model.rb +88 -0
- data/lib/rails_admin/config/proxyable.rb +12 -0
- data/lib/rails_admin/config/proxyable/proxy.rb +43 -0
- data/lib/rails_admin/config/sections.rb +39 -0
- data/lib/rails_admin/config/sections/base.rb +29 -0
- data/lib/rails_admin/config/sections/create.rb +11 -0
- data/lib/rails_admin/config/sections/edit.rb +11 -0
- data/lib/rails_admin/config/sections/export.rb +11 -0
- data/lib/rails_admin/config/sections/list.rb +27 -0
- data/lib/rails_admin/config/sections/modal.rb +10 -0
- data/lib/rails_admin/config/sections/nested.rb +10 -0
- data/lib/rails_admin/config/sections/show.rb +10 -0
- data/lib/rails_admin/config/sections/update.rb +10 -0
- data/lib/rails_admin/engine.rb +22 -0
- data/lib/rails_admin/extension.rb +29 -0
- data/lib/rails_admin/extensions/cancan.rb +5 -0
- data/lib/rails_admin/extensions/cancan/authorization_adapter.rb +59 -0
- data/lib/rails_admin/extensions/history.rb +5 -0
- data/lib/rails_admin/extensions/history/auditing_adapter.rb +37 -0
- data/lib/rails_admin/extensions/history/history.rb +70 -0
- data/lib/rails_admin/extensions/paper_trail.rb +5 -0
- data/lib/rails_admin/extensions/paper_trail/auditing_adapter.rb +92 -0
- data/lib/rails_admin/i18n_support.rb +43 -0
- data/lib/rails_admin/support/core_extensions.rb +44 -0
- data/lib/rails_admin/support/csv_converter.rb +109 -0
- data/lib/rails_admin/version.rb +3 -0
- data/lib/tasks/prepare_ci_env.rake +27 -0
- data/lib/tasks/rails_admin.rake +18 -0
- data/spec/ci.sh +2 -0
- data/spec/controllers/application_controller_spec.rb +30 -0
- data/spec/controllers/main_controller_spec.rb +179 -0
- data/spec/dummy_app/Gemfile +71 -0
- data/spec/dummy_app/Gemfile.lock +205 -0
- data/spec/dummy_app/Rakefile +7 -0
- data/spec/dummy_app/app/active_record/abstract.rb +5 -0
- data/spec/dummy_app/app/active_record/ball.rb +9 -0
- data/spec/dummy_app/app/active_record/carrierwave_uploader.rb +53 -0
- data/spec/dummy_app/app/active_record/category.rb +5 -0
- data/spec/dummy_app/app/active_record/cms.rb +5 -0
- data/spec/dummy_app/app/active_record/cms/basic_page.rb +9 -0
- data/spec/dummy_app/app/active_record/cms/unscoped_page.rb +3 -0
- data/spec/dummy_app/app/active_record/comment.rb +5 -0
- data/spec/dummy_app/app/active_record/division.rb +15 -0
- data/spec/dummy_app/app/active_record/draft.rb +13 -0
- data/spec/dummy_app/app/active_record/fan.rb +7 -0
- data/spec/dummy_app/app/active_record/field_test.rb +20 -0
- data/spec/dummy_app/app/active_record/hardball.rb +2 -0
- data/spec/dummy_app/app/active_record/league.rb +12 -0
- data/spec/dummy_app/app/active_record/nested_field_test.rb +7 -0
- data/spec/dummy_app/app/active_record/player.rb +23 -0
- data/spec/dummy_app/app/active_record/team.rb +27 -0
- data/spec/dummy_app/app/active_record/user.rb +21 -0
- data/spec/dummy_app/app/assets/images/rails.png +0 -0
- data/spec/dummy_app/app/assets/javascripts/application.js +15 -0
- data/spec/dummy_app/app/assets/stylesheets/application.css +13 -0
- data/spec/dummy_app/app/controllers/application_controller.rb +3 -0
- data/spec/dummy_app/app/controllers/players_controller.rb +5 -0
- data/spec/dummy_app/app/locales/models.en.yml +20 -0
- data/spec/dummy_app/app/mongoid/ball.rb +14 -0
- data/spec/dummy_app/app/mongoid/carrierwave_uploader.rb +53 -0
- data/spec/dummy_app/app/mongoid/category.rb +7 -0
- data/spec/dummy_app/app/mongoid/cms.rb +5 -0
- data/spec/dummy_app/app/mongoid/cms/basic_page.rb +12 -0
- data/spec/dummy_app/app/mongoid/cms/unscoped_page.rb +5 -0
- data/spec/dummy_app/app/mongoid/comment.rb +9 -0
- data/spec/dummy_app/app/mongoid/division.rb +14 -0
- data/spec/dummy_app/app/mongoid/draft.rb +22 -0
- data/spec/dummy_app/app/mongoid/embed.rb +6 -0
- data/spec/dummy_app/app/mongoid/fan.rb +12 -0
- data/spec/dummy_app/app/mongoid/field_test.rb +56 -0
- data/spec/dummy_app/app/mongoid/hardball.rb +2 -0
- data/spec/dummy_app/app/mongoid/league.rb +16 -0
- data/spec/dummy_app/app/mongoid/nested_field_test.rb +12 -0
- data/spec/dummy_app/app/mongoid/player.rb +37 -0
- data/spec/dummy_app/app/mongoid/team.rb +47 -0
- data/spec/dummy_app/app/mongoid/user.rb +61 -0
- data/spec/dummy_app/app/views/layouts/application.html.erb +14 -0
- data/spec/dummy_app/app/views/players/show.html.haml +1 -0
- data/spec/dummy_app/config.ru +4 -0
- data/spec/dummy_app/config/application.rb +69 -0
- data/spec/dummy_app/config/boot.rb +9 -0
- data/spec/dummy_app/config/database.yml +25 -0
- data/spec/dummy_app/config/environment.rb +5 -0
- data/spec/dummy_app/config/environments/development.rb +37 -0
- data/spec/dummy_app/config/environments/production.rb +67 -0
- data/spec/dummy_app/config/environments/test.rb +37 -0
- data/spec/dummy_app/config/initializers/backtrace_silencers.rb +7 -0
- data/spec/dummy_app/config/initializers/devise.rb +223 -0
- data/spec/dummy_app/config/initializers/dragonfly.rb +14 -0
- data/spec/dummy_app/config/initializers/inflections.rb +15 -0
- data/spec/dummy_app/config/initializers/mime_types.rb +5 -0
- data/spec/dummy_app/config/initializers/rails_admin.rb +8 -0
- data/spec/dummy_app/config/initializers/secret_token.rb +7 -0
- data/spec/dummy_app/config/initializers/session_patch.rb +16 -0
- data/spec/dummy_app/config/initializers/session_store.rb +8 -0
- data/spec/dummy_app/config/initializers/wrap_parameters.rb +14 -0
- data/spec/dummy_app/config/mongoid.yml +11 -0
- data/spec/dummy_app/config/routes.rb +10 -0
- data/spec/dummy_app/db/development.sqlite3 +0 -0
- data/spec/dummy_app/db/migrate/00000000000001_create_divisions_migration.rb +13 -0
- data/spec/dummy_app/db/migrate/00000000000002_create_drafts_migration.rb +19 -0
- data/spec/dummy_app/db/migrate/00000000000003_create_leagues_migration.rb +12 -0
- data/spec/dummy_app/db/migrate/00000000000004_create_players_migration.rb +20 -0
- data/spec/dummy_app/db/migrate/00000000000005_create_teams_migration.rb +22 -0
- data/spec/dummy_app/db/migrate/00000000000006_devise_create_users.rb +49 -0
- data/spec/dummy_app/db/migrate/00000000000007_create_histories_table.rb +16 -0
- data/spec/dummy_app/db/migrate/00000000000008_create_fans_migration.rb +12 -0
- data/spec/dummy_app/db/migrate/00000000000009_create_fans_teams_migration.rb +11 -0
- data/spec/dummy_app/db/migrate/00000000000010_add_revenue_to_team_migration.rb +9 -0
- data/spec/dummy_app/db/migrate/00000000000011_add_suspended_to_player_migration.rb +9 -0
- data/spec/dummy_app/db/migrate/00000000000012_add_avatar_columns_to_user.rb +16 -0
- data/spec/dummy_app/db/migrate/00000000000013_add_roles_to_user.rb +9 -0
- data/spec/dummy_app/db/migrate/00000000000014_add_color_to_team_migration.rb +9 -0
- data/spec/dummy_app/db/migrate/20101223222233_create_rel_tests.rb +15 -0
- data/spec/dummy_app/db/migrate/20110103205808_create_comments.rb +15 -0
- data/spec/dummy_app/db/migrate/20110123042530_rename_histories_to_rails_admin_histories.rb +9 -0
- data/spec/dummy_app/db/migrate/20110224184303_create_field_tests.rb +22 -0
- data/spec/dummy_app/db/migrate/20110328193014_create_cms_basic_pages.rb +14 -0
- data/spec/dummy_app/db/migrate/20110329183136_remove_league_id_from_teams.rb +9 -0
- data/spec/dummy_app/db/migrate/20110607152842_add_format_to_field_test.rb +9 -0
- data/spec/dummy_app/db/migrate/20110714095433_create_balls.rb +12 -0
- data/spec/dummy_app/db/migrate/20110831090841_add_protected_field_and_restricted_field_to_field_tests.rb +6 -0
- data/spec/dummy_app/db/migrate/20110901131551_change_division_primary_key.rb +19 -0
- data/spec/dummy_app/db/migrate/20110901142530_rename_league_id_foreign_key_on_divisions.rb +5 -0
- data/spec/dummy_app/db/migrate/20110901150912_set_primary_key_not_null_for_divisions.rb +21 -0
- data/spec/dummy_app/db/migrate/20110901154834_change_length_for_rails_admin_histories.rb +9 -0
- data/spec/dummy_app/db/migrate/20111103174459_create_unscoped_pages.rb +9 -0
- data/spec/dummy_app/db/migrate/20111108143642_add_dragonfly_and_carrierwave_to_field_tests.rb +7 -0
- data/spec/dummy_app/db/migrate/20111115041025_add_type_to_balls.rb +5 -0
- data/spec/dummy_app/db/migrate/20111123092549_create_nested_field_tests.rb +10 -0
- data/spec/dummy_app/db/migrate/20111130075338_add_dragonfly_asset_name_to_field_tests.rb +5 -0
- data/spec/dummy_app/db/migrate/20111215083258_create_foo_bars.rb +8 -0
- data/spec/dummy_app/db/migrate/20120117151733_add_custom_field_to_teams.rb +5 -0
- data/spec/dummy_app/db/migrate/20120118122004_add_categories.rb +7 -0
- data/spec/dummy_app/db/migrate/20120319041705_drop_rel_tests.rb +15 -0
- data/spec/dummy_app/db/schema.rb +188 -0
- data/spec/dummy_app/db/seeds.rb +29 -0
- data/spec/dummy_app/db/test.sqlite3 +0 -0
- data/spec/dummy_app/doc/README_FOR_APP +2 -0
- data/spec/dummy_app/log/development.log +865 -0
- data/spec/dummy_app/log/test.log +36651 -0
- data/spec/dummy_app/public/404.html +26 -0
- data/spec/dummy_app/public/422.html +26 -0
- data/spec/dummy_app/public/500.html +25 -0
- data/spec/dummy_app/public/favicon.ico +0 -0
- data/spec/dummy_app/public/robots.txt +5 -0
- data/spec/dummy_app/public/system/dragonfly/development/2011/11/24/10_36_27_888_Pensive_Parakeet.jpg +0 -0
- data/spec/dummy_app/public/system/dragonfly/development/2011/11/24/10_36_27_888_Pensive_Parakeet.jpg.meta +1 -0
- data/spec/dummy_app/public/system/dragonfly/development/2011/11/30/08_54_39_906_Costa_Rican_Frog.jpg +0 -0
- data/spec/dummy_app/public/system/dragonfly/development/2011/11/30/08_54_39_906_Costa_Rican_Frog.jpg.meta +1 -0
- data/spec/dummy_app/public/system/paperclip_assets/1/original/Boston City Flow.jpg +0 -0
- data/spec/dummy_app/public/system/paperclip_assets/1/thumb/Boston City Flow.jpg +0 -0
- data/spec/dummy_app/public/system/paperclip_assets/3/original/Costa Rican Frog.jpg +0 -0
- data/spec/dummy_app/public/system/paperclip_assets/3/thumb/Costa Rican Frog.jpg +0 -0
- data/spec/dummy_app/public/system/paperclip_assets/6/original/liste-electorale.pdf +0 -0
- data/spec/dummy_app/public/system/paperclip_assets/6/thumb/liste-electorale.pdf +148 -0
- data/spec/dummy_app/public/uploads/field_test/carrierwave_asset/3/Boston_City_Flow.jpg +0 -0
- data/spec/dummy_app/public/uploads/field_test/carrierwave_asset/3/thumb_Boston_City_Flow.jpg +0 -0
- data/spec/dummy_app/public/uploads/field_test/carrierwave_asset/4/Costa_Rican_Frog.jpg +0 -0
- data/spec/dummy_app/public/uploads/field_test/carrierwave_asset/4/thumb_Costa_Rican_Frog.jpg +0 -0
- data/spec/dummy_app/public/uploads/field_test/carrierwave_asset/6/Pensive_Parakeet.jpg +0 -0
- data/spec/dummy_app/public/uploads/field_test/carrierwave_asset/6/thumb_Pensive_Parakeet.jpg +0 -0
- data/spec/dummy_app/script/rails +6 -0
- data/spec/dummy_app/tmp/cache/assets/BE5/B00/sprockets%2F47892969925432da563a88e366309859 +1833 -0
- data/spec/dummy_app/tmp/cache/assets/C1C/C90/sprockets%2F4c1f0504074864b8b21792c77391e206 +0 -0
- data/spec/dummy_app/tmp/cache/assets/C29/F50/sprockets%2F6d087f33314fd5091b1270969287268b +0 -0
- data/spec/dummy_app/tmp/cache/assets/C2C/130/sprockets%2F2d09a75917207f5a55929639226b4b48 +26 -0
- data/spec/dummy_app/tmp/cache/assets/C49/FD0/sprockets%2F07901b5391110eea9648d5c25d481327 +0 -0
- data/spec/dummy_app/tmp/cache/assets/C63/BF0/sprockets%2F600472e1a4718315162a7cb0f285a02b +547 -0
- data/spec/dummy_app/tmp/cache/assets/C66/0B0/sprockets%2F2560ef2871b489690ff209e164d86665 +635 -0
- data/spec/dummy_app/tmp/cache/assets/C68/560/sprockets%2F5996692771c33962a9a2c72790ddd754 +0 -0
- data/spec/dummy_app/tmp/cache/assets/C83/F90/sprockets%2Fa580b424c36c26dd59f660078d541755 +0 -0
- data/spec/dummy_app/tmp/cache/assets/C86/C30/sprockets%2F23ca33803f8248991f3fa8d2104e9961 +0 -0
- data/spec/dummy_app/tmp/cache/assets/C88/790/sprockets%2F538d9562b05167d03d26b0e5e9f78830 +5 -0
- data/spec/dummy_app/tmp/cache/assets/C89/3B0/sprockets%2F503f729e1bc985e17b730122c7176f97 +0 -0
- data/spec/dummy_app/tmp/cache/assets/C95/A00/sprockets%2F458c72992a558902c05a9d6d99339af2 +4 -0
- data/spec/dummy_app/tmp/cache/assets/C97/4C0/sprockets%2F97a81a953151b41a100165fb83dfa023 +133 -0
- data/spec/dummy_app/tmp/cache/assets/C9A/C90/sprockets%2F400271d29a3bb9124a286ba761c3f254 +0 -0
- data/spec/dummy_app/tmp/cache/assets/C9D/BA0/sprockets%2F1bfd091b2034980851caa077c0892c40 +490 -0
- data/spec/dummy_app/tmp/cache/assets/CA2/FA0/sprockets%2F0c3f1c8708606aa0440c866138d1e9a2 +0 -0
- data/spec/dummy_app/tmp/cache/assets/CA7/480/sprockets%2F23a375f496616605e4144a21fb4dc83a +4 -0
- data/spec/dummy_app/tmp/cache/assets/CB1/8A0/sprockets%2F25c2eb1d72087ed5e863f217109b6069 +0 -0
- data/spec/dummy_app/tmp/cache/assets/CB3/B50/sprockets%2F03a7c1f7144eb79946ceb8e151772127 +0 -0
- data/spec/dummy_app/tmp/cache/assets/CC4/220/sprockets%2F8d947b008798f16134b7d576fa456ce4 +285 -0
- data/spec/dummy_app/tmp/cache/assets/CC7/F70/sprockets%2F1a1af5b2c6473f104b2f0b252a729338 +0 -0
- data/spec/dummy_app/tmp/cache/assets/CD1/C70/sprockets%2F75b65e7751a3f030d43c1cf6827cc100 +133 -0
- data/spec/dummy_app/tmp/cache/assets/CD8/370/sprockets%2F357970feca3ac29060c1e3861e2c0953 +0 -0
- data/spec/dummy_app/tmp/cache/assets/CD8/430/sprockets%2Fc89f860631079a34d3c0d662aac0d256 +635 -0
- data/spec/dummy_app/tmp/cache/assets/CD8/AF0/sprockets%2Ffa2b25b3f4c05f51086482175c970ca7 +0 -0
- data/spec/dummy_app/tmp/cache/assets/CD9/590/sprockets%2F6882cdc2e05726d5172e2b9b334ec007 +0 -0
- data/spec/dummy_app/tmp/cache/assets/CD9/E00/sprockets%2F233f366461a5722d7dfb7a0ecd064087 +0 -0
- data/spec/dummy_app/tmp/cache/assets/CDA/880/sprockets%2Fa1e3e4ae81b451c8b4b798061148a358 +275 -0
- data/spec/dummy_app/tmp/cache/assets/CE2/490/sprockets%2Fab26cd4524240da60a93659780f9ae78 +0 -0
- data/spec/dummy_app/tmp/cache/assets/CEC/270/sprockets%2Fb531a7fa499c7953ab753fa911a61799 +328 -0
- data/spec/dummy_app/tmp/cache/assets/CFD/D70/sprockets%2F79acf34495d5196bd47278685b4ee68b +237 -0
- data/spec/dummy_app/tmp/cache/assets/CFE/060/sprockets%2Fd97e1e070419bcfe35c7000d1a70427b +303 -0
- data/spec/dummy_app/tmp/cache/assets/D02/8B0/sprockets%2F0c493e35ea651c55155b2a383bf2d34d +0 -0
- data/spec/dummy_app/tmp/cache/assets/D04/A20/sprockets%2Fa264585296de2351212f1063ebcccd9b +1092 -0
- data/spec/dummy_app/tmp/cache/assets/D0F/EA0/sprockets%2F4a754f04f5d1c8995a01927bbd074fa4 +0 -0
- data/spec/dummy_app/tmp/cache/assets/D11/470/sprockets%2F67d64aa5490686515e07cdb8ae05b4c6 +9 -0
- data/spec/dummy_app/tmp/cache/assets/D12/F60/sprockets%2F6ac89a4a48bf0e3bb6364925661da565 +0 -0
- data/spec/dummy_app/tmp/cache/assets/D15/3D0/sprockets%2F7ef98ea43116410c4c50ffff444428c8 +1376 -0
- data/spec/dummy_app/tmp/cache/assets/D17/9B0/sprockets%2F3154059ed98209719dc1a7c493cb0fff +381 -0
- data/spec/dummy_app/tmp/cache/assets/D20/9E0/sprockets%2F9e5560466ce41eac747392c97eef4c51 +0 -0
- data/spec/dummy_app/tmp/cache/assets/D24/B30/sprockets%2F69d62273002dffc74f5368f55dfb97f3 +0 -0
- data/spec/dummy_app/tmp/cache/assets/D2D/840/sprockets%2F6f3b681ef8ba260acc705e3b262425a0 +0 -0
- data/spec/dummy_app/tmp/cache/assets/D2F/7C0/sprockets%2F99f6619fe89012fb9908a47ebb9b92a8 +7 -0
- data/spec/dummy_app/tmp/cache/assets/D2F/D60/sprockets%2Fa0cb0b3d7d775c4707c42a58fb0d2615 +9409 -0
- data/spec/dummy_app/tmp/cache/assets/D32/A10/sprockets%2F13fe41fee1fe35b49d145bcc06610705 +0 -0
- data/spec/dummy_app/tmp/cache/assets/D3A/260/sprockets%2F35a5b51d1927651a39e3edca8c483dd1 +0 -0
- data/spec/dummy_app/tmp/cache/assets/D3B/F80/sprockets%2F304efb1d2d219915606f3fd96b3bf5c2 +9409 -0
- data/spec/dummy_app/tmp/cache/assets/D3C/7C0/sprockets%2F6a50cb4a5d265838f510fc8e6178bae1 +0 -0
- data/spec/dummy_app/tmp/cache/assets/D3D/0A0/sprockets%2Fa92066280edcd6b188dc38e35361dd3b +0 -0
- data/spec/dummy_app/tmp/cache/assets/D40/9B0/sprockets%2F704cfd791b468a6fba4fb820ec128941 +237 -0
- data/spec/dummy_app/tmp/cache/assets/D40/E10/sprockets%2F97d56619e64ca8c9c514a3aa2a4b339c +0 -0
- data/spec/dummy_app/tmp/cache/assets/D42/1F0/sprockets%2Fcaf59e1c6d22bae908a06e476b752791 +0 -0
- data/spec/dummy_app/tmp/cache/assets/D43/E30/sprockets%2Fece324b9d4dc935a92333fd0149bf773 +0 -0
- data/spec/dummy_app/tmp/cache/assets/D47/520/sprockets%2Ff142cf9478904f9e3ebb31ecc8c50913 +0 -0
- data/spec/dummy_app/tmp/cache/assets/D4B/390/sprockets%2Feb90dbdd2a6275f48086881f7b74ee32 +0 -0
- data/spec/dummy_app/tmp/cache/assets/D4B/6D0/sprockets%2F760ec9c344d334cfe919a55cf7f6a165 +0 -0
- data/spec/dummy_app/tmp/cache/assets/D4E/1B0/sprockets%2Ff7cbd26ba1d28d48de824f0e94586655 +0 -0
- data/spec/dummy_app/tmp/cache/assets/D53/5C0/sprockets%2Fa93098db097c86d1e33dc86dece09991 +1092 -0
- data/spec/dummy_app/tmp/cache/assets/D56/F00/sprockets%2F48f6039e6745b557cbe83957abc8df2d +303 -0
- data/spec/dummy_app/tmp/cache/assets/D58/940/sprockets%2F0c3d05522ea3be49ba23372222fdcde7 +328 -0
- data/spec/dummy_app/tmp/cache/assets/D58/950/sprockets%2F6ade11e1b9d3ac4736b05aaf039c0804 +0 -0
- data/spec/dummy_app/tmp/cache/assets/D5A/EA0/sprockets%2Fd771ace226fc8215a3572e0aa35bb0d6 +0 -0
- data/spec/dummy_app/tmp/cache/assets/D5C/D10/sprockets%2F3fddf4c16115fad562082a5d4f1bd520 +0 -0
- data/spec/dummy_app/tmp/cache/assets/D5D/950/sprockets%2F9ed4c3b788618998fefb569a0a58da80 +0 -0
- data/spec/dummy_app/tmp/cache/assets/D5F/F30/sprockets%2Fc93672decbf5fb650336d1a67001fba0 +547 -0
- data/spec/dummy_app/tmp/cache/assets/D62/4A0/sprockets%2F47b7cb361e1f2e2ce081ea52fe32f640 +0 -0
- data/spec/dummy_app/tmp/cache/assets/D65/140/sprockets%2F5cc4a9317d68e31bb0c5b8d3f517a0e4 +0 -0
- data/spec/dummy_app/tmp/cache/assets/D6C/170/sprockets%2Fdc1a668e0c34eb1206fc67cf526249cf +0 -0
- data/spec/dummy_app/tmp/cache/assets/D71/9B0/sprockets%2Fc98bb1ca9b745d615b0f2f0d963c44d8 +5 -0
- data/spec/dummy_app/tmp/cache/assets/D74/020/sprockets%2Fd99999af4693dfa5998fdaf5b68276e6 +0 -0
- data/spec/dummy_app/tmp/cache/assets/D74/050/sprockets%2Fab9217b6ce5c3c8969791adc819b2a2b +0 -0
- data/spec/dummy_app/tmp/cache/assets/D7A/410/sprockets%2Fd1decdae4824f395df114687f262e78a +381 -0
- data/spec/dummy_app/tmp/cache/assets/D7C/630/sprockets%2Fff49f6b45a167453dabfa743e588dd16 +0 -0
- data/spec/dummy_app/tmp/cache/assets/D85/CC0/sprockets%2F09f7b34bbc050700a3bcbf6c6c5c1b45 +0 -0
- data/spec/dummy_app/tmp/cache/assets/D8F/DD0/sprockets%2F7bd51d74d575ec0bfad624acc81a6040 +0 -0
- data/spec/dummy_app/tmp/cache/assets/D93/C20/sprockets%2F2f48ab1ea8216fd918beb173c2a4f04d +0 -0
- data/spec/dummy_app/tmp/cache/assets/D9B/920/sprockets%2F4a02c68d7d2e9a072b8cdd5f715ab7c4 +26 -0
- data/spec/dummy_app/tmp/cache/assets/D9D/720/sprockets%2Fc7c311fcebe12a3cf86631a4a47f849f +490 -0
- data/spec/dummy_app/tmp/cache/assets/D9F/F20/sprockets%2F32f6c0bcea62f9ab09385db3217ee7e8 +0 -0
- data/spec/dummy_app/tmp/cache/assets/DA0/8A0/sprockets%2F9aff0ec8777da07337a51280eacd3f4e +768 -0
- data/spec/dummy_app/tmp/cache/assets/DA2/DB0/sprockets%2Fa6cfbef08a491ac3397e006bed885b38 +275 -0
- data/spec/dummy_app/tmp/cache/assets/DA4/010/sprockets%2F9663c5eebc07fdb49dd221cf84804c6b +0 -0
- data/spec/dummy_app/tmp/cache/assets/DA5/FE0/sprockets%2Fc5d487522471a6ab39cac1bf8e7e9b9b +0 -0
- data/spec/dummy_app/tmp/cache/assets/DA6/0A0/sprockets%2Fae11a6ff426fe2d094a5cde67159f94d +0 -0
- data/spec/dummy_app/tmp/cache/assets/DA9/170/sprockets%2F88a844719bb0fc081d9cfafc0e76ca96 +0 -0
- data/spec/dummy_app/tmp/cache/assets/DC2/720/sprockets%2F6a32e6f352ddd183d19dcac10cfc456b +0 -0
- data/spec/dummy_app/tmp/cache/assets/DCA/070/sprockets%2F8ec1ae13cf7ba342507cbb8f877a6dd1 +768 -0
- data/spec/dummy_app/tmp/cache/assets/DCB/120/sprockets%2Fc29be206ce74d90a4ad1f9a3d9d20f7d +0 -0
- data/spec/dummy_app/tmp/cache/assets/DD6/9B0/sprockets%2Fb92fb5cec0493bfdbe8248cd5673f71b +0 -0
- data/spec/dummy_app/tmp/cache/assets/DD7/5C0/sprockets%2Fe0912ed75a6ed23afdf293deed66871c +1376 -0
- data/spec/dummy_app/tmp/cache/assets/DD8/110/sprockets%2F8dfc7ac2667a017ee469f4cd443cfa8c +0 -0
- data/spec/dummy_app/tmp/cache/assets/DDC/400/sprockets%2Fcffd775d018f68ce5dba1ee0d951a994 +21 -0
- data/spec/dummy_app/tmp/cache/assets/E04/890/sprockets%2F2f5173deea6c795b8fdde723bb4b63af +21 -0
- data/spec/dummy_app/tmp/cache/assets/E05/140/sprockets%2F41bf6f07f45b76cd2eef60ed2ffbb908 +0 -0
- data/spec/dummy_app/tmp/cache/assets/E09/FE0/sprockets%2Fc5df928b0e066c9e19ee3f2be8f6dbd0 +0 -0
- data/spec/dummy_app/tmp/cache/assets/E30/BF0/sprockets%2Fd35aca629e1763dd5a9deeb6caa78b6c +285 -0
- data/spec/dummy_app/tmp/cache/assets/E42/8C0/sprockets%2Faff1c93e2a43b887cbdebf8f9df9087b +0 -0
- data/spec/dummy_app/tmp/cache/assets/E61/F10/sprockets%2Fe616dbbacda8602fc9c589aefaf4c34f +1833 -0
- data/spec/dummy_app/tmp/cache/assets/E87/8F0/sprockets%2Ff90a7f08fcd06d0faf133fed3edbfa6a +0 -0
- data/spec/dummy_app/tmp/cache/sass/0591c977016a0bb372763f6f1cfb8002d44de3b2/mixins.css.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/0591c977016a0bb372763f6f1cfb8002d44de3b2/theming.css.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/0591c977016a0bb372763f6f1cfb8002d44de3b2/variables.css.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/10238403c134661921596d094764445b02e815fe/mixins.css.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/10238403c134661921596d094764445b02e815fe/theming.css.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/10238403c134661921596d094764445b02e815fe/variables.css.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/59e0a00e930df996e5ae01d3215f486bd084d24f/imports.css.scss.erbc +0 -0
- data/spec/dummy_app/tmp/cache/sass/59e0a00e930df996e5ae01d3215f486bd084d24f/jquery.colorpicker.css.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/59e0a00e930df996e5ae01d3215f486bd084d24f/jquery.ui.timepicker.css.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/59e0a00e930df996e5ae01d3215f486bd084d24f/ra.calendar-additions.css.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/59e0a00e930df996e5ae01d3215f486bd084d24f/ra.filtering-multiselect.css.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/e49dad041ec24255ebe09b15ccd7ea91f1ab56bd/_accordion.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/e49dad041ec24255ebe09b15ccd7ea91f1ab56bd/_alerts.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/e49dad041ec24255ebe09b15ccd7ea91f1ab56bd/_breadcrumbs.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/e49dad041ec24255ebe09b15ccd7ea91f1ab56bd/_button-groups.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/e49dad041ec24255ebe09b15ccd7ea91f1ab56bd/_buttons.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/e49dad041ec24255ebe09b15ccd7ea91f1ab56bd/_carousel.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/e49dad041ec24255ebe09b15ccd7ea91f1ab56bd/_close.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/e49dad041ec24255ebe09b15ccd7ea91f1ab56bd/_code.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/e49dad041ec24255ebe09b15ccd7ea91f1ab56bd/_component-animations.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/e49dad041ec24255ebe09b15ccd7ea91f1ab56bd/_dropdowns.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/e49dad041ec24255ebe09b15ccd7ea91f1ab56bd/_forms.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/e49dad041ec24255ebe09b15ccd7ea91f1ab56bd/_grid.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/e49dad041ec24255ebe09b15ccd7ea91f1ab56bd/_hero-unit.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/e49dad041ec24255ebe09b15ccd7ea91f1ab56bd/_labels.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/e49dad041ec24255ebe09b15ccd7ea91f1ab56bd/_layouts.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/e49dad041ec24255ebe09b15ccd7ea91f1ab56bd/_mixins.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/e49dad041ec24255ebe09b15ccd7ea91f1ab56bd/_modals.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/e49dad041ec24255ebe09b15ccd7ea91f1ab56bd/_navbar.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/e49dad041ec24255ebe09b15ccd7ea91f1ab56bd/_navs.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/e49dad041ec24255ebe09b15ccd7ea91f1ab56bd/_pager.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/e49dad041ec24255ebe09b15ccd7ea91f1ab56bd/_pagination.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/e49dad041ec24255ebe09b15ccd7ea91f1ab56bd/_popovers.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/e49dad041ec24255ebe09b15ccd7ea91f1ab56bd/_progress-bars.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/e49dad041ec24255ebe09b15ccd7ea91f1ab56bd/_reset.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/e49dad041ec24255ebe09b15ccd7ea91f1ab56bd/_scaffolding.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/e49dad041ec24255ebe09b15ccd7ea91f1ab56bd/_sprites.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/e49dad041ec24255ebe09b15ccd7ea91f1ab56bd/_tables.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/e49dad041ec24255ebe09b15ccd7ea91f1ab56bd/_thumbnails.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/e49dad041ec24255ebe09b15ccd7ea91f1ab56bd/_tooltip.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/e49dad041ec24255ebe09b15ccd7ea91f1ab56bd/_type.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/e49dad041ec24255ebe09b15ccd7ea91f1ab56bd/_utilities.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/e49dad041ec24255ebe09b15ccd7ea91f1ab56bd/_variables.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/e49dad041ec24255ebe09b15ccd7ea91f1ab56bd/_wells.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/ea17b334a44bfc0f3681b2e3e4202c941da9ee82/jquery-ui-1.8.7.custom.css.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/fb68f840f6ad0344d3dcaecafd4b6ac4e35ca8fe/mixins.css.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/fb68f840f6ad0344d3dcaecafd4b6ac4e35ca8fe/theming.css.scssc +0 -0
- data/spec/dummy_app/tmp/cache/sass/fb68f840f6ad0344d3dcaecafd4b6ac4e35ca8fe/variables.css.scssc +0 -0
- data/spec/dummy_app/tmp/dragonfly/cache/body/67/c49ea211b51fee9c0ccde26af73f27446aa071 +1 -0
- data/spec/dummy_app/tmp/dragonfly/cache/body/da/39a3ee5e6b4b0d3255bfef95601890afd80709 +0 -0
- data/spec/dummy_app/tmp/dragonfly/cache/body/e7/536a0250f5395f318c24bee30dbbb0a2a28714 +24 -0
- data/spec/dummy_app/tmp/dragonfly/cache/body/f0/76846cb5891d588ad63ea7f6451e26b4f48c3d +19 -0
- data/spec/dummy_app/tmp/dragonfly/cache/meta/26/1464d915347774c08b1ddf6d305783e3acfadb +0 -0
- data/spec/dummy_app/tmp/dragonfly/cache/meta/7f/29e62b90d2b255e74d7e1a8ee8ed509c3f0406 +0 -0
- data/spec/dummy_app/tmp/dragonfly/cache/meta/c1/0f5c4fe64b3d3cffe2793ad7a8e51aeb4f3eec +0 -0
- data/spec/dummy_app/tmp/dragonfly/cache/meta/fe/97fd48b64023fee9cc7d8a12f0f1e9097058da +0 -0
- data/spec/factories.rb +71 -0
- data/spec/helpers/application_helper_spec.rb +277 -0
- data/spec/integration/authorization/cancan_spec.rb +358 -0
- data/spec/integration/basic/bulk_action/rails_admin_basic_bulk_action_spec.rb +25 -0
- data/spec/integration/basic/bulk_destroy/rails_admin_basic_bulk_destroy_spec.rb +42 -0
- data/spec/integration/basic/create/rails_admin_basic_create_spec.rb +141 -0
- data/spec/integration/basic/create/rails_admin_namespaced_model_create_spec.rb +23 -0
- data/spec/integration/basic/delete/rails_admin_basic_delete_spec.rb +27 -0
- data/spec/integration/basic/destroy/rails_admin_basic_destroy_spec.rb +56 -0
- data/spec/integration/basic/edit/rails_admin_basic_edit_spec.rb +109 -0
- data/spec/integration/basic/export/rails_admin_basic_export_spec.rb +106 -0
- data/spec/integration/basic/list/rails_admin_basic_list_spec.rb +400 -0
- data/spec/integration/basic/new/rails_admin_basic_new_spec.rb +74 -0
- data/spec/integration/basic/new/rails_admin_namespaced_model_new_spec.rb +31 -0
- data/spec/integration/basic/show/rails_admin_basic_show_spec.rb +91 -0
- data/spec/integration/basic/update/rails_admin_basic_update_spec.rb +223 -0
- data/spec/integration/config/edit/rails_admin_config_edit_spec.rb +1043 -0
- data/spec/integration/config/list/rails_admin_config_list_spec.rb +521 -0
- data/spec/integration/config/show/rails_admin_config_show_spec.rb +312 -0
- data/spec/integration/history/rails_admin_history_spec.rb +65 -0
- data/spec/integration/rails_admin_spec.rb +113 -0
- data/spec/integration/relation_spec.rb +35 -0
- data/spec/orm/active_record.rb +42 -0
- data/spec/orm/mongoid.rb +19 -0
- data/spec/spec_helper.rb +79 -0
- data/spec/unit/abstract_model_spec.rb +45 -0
- data/spec/unit/adapters/active_record/abstract_object_spec.rb +132 -0
- data/spec/unit/adapters/active_record_spec.rb +373 -0
- data/spec/unit/adapters/mongoid/abstract_object_spec.rb +31 -0
- data/spec/unit/adapters/mongoid_spec.rb +686 -0
- data/spec/unit/config/actions_spec.rb +181 -0
- data/spec/unit/config/fields/base_spec.rb +339 -0
- data/spec/unit/config/model_spec.rb +75 -0
- data/spec/unit/config/sections_spec.rb +123 -0
- data/spec/unit/config_spec.rb +278 -0
- metadata +1317 -0
Binary file
|
@@ -0,0 +1,21 @@
|
|
1
|
+
o: ActiveSupport::Cache::Entry :@expires_in0:@compressedF:@value"8�{"required_assets_digest"%1a2dc79471515227aafd54563970d306"content_type"application/javascript"
|
2
|
+
class"BundledAsset"
|
3
|
+
mtime"2012-04-28T20:21:50-05:00"
|
4
|
+
* jQuery JavaScript Library v1.7.2
|
5
|
+
* http://jquery.com/
|
6
|
+
*
|
7
|
+
* Copyright 2011, John Resig
|
8
|
+
* Dual licensed under the MIT or GPL Version 2 licenses.
|
9
|
+
* http://jquery.org/license
|
10
|
+
*
|
11
|
+
* Includes Sizzle.js
|
12
|
+
* http://sizzlejs.com/
|
13
|
+
* Copyright 2011, The Dojo Foundation
|
14
|
+
* Released under the MIT, BSD, and GPL Licenses.
|
15
|
+
*
|
16
|
+
* Date: Wed Mar 21 12:46:34 2012 -0700
|
17
|
+
*/
|
18
|
+
(function(a,b){function h(a){var b=g[a]={},c,d;a=a.split(/\s+/);for(c=0,d=a.length;c<d;c++)b[a[c]]=!0;return b}function l(a,c,d){if(d===b&&a.nodeType===1){var e="data-"+c.replace(k,"-$1").toLowerCase();d=a.getAttribute(e);if(typeof d=="string"){try{d=d==="true"?!0:d==="false"?!1:d==="null"?null:f.isNumeric(d)?+d:j.test(d)?f.parseJSON(d):d}catch(g){}f.data(a,c,d)}else d=b}return d}function m(a){for(var b in a){if(b==="data"&&f.isEmptyObject(a[b]))continue;if(b!=="toJSON")return!1}return!0}function n(a,b,c){var d=b+"defer",e=b+"queue",g=b+"mark",h=f._data(a,d);h&&(c==="queue"||!f._data(a,e))&&(c==="mark"||!f._data(a,g))&&setTimeout(function(){!f._data(a,e)&&!f._data(a,g)&&(f.removeData(a,d,!0),h.fire())},0)}function J(){return!1}function K(){return!0}function S(a){return!a||!a.parentNode||a.parentNode.nodeType===11}function T(a,b,c){b=b||0;if(f.isFunction(b))return f.grep(a,function(a,d){var e=!!b.call(a,d,a);return e===c});if(b.nodeType)return f.grep(a,function(a,d){return a===b===c});if(typeof b=="string"){var d=f.grep(a,function(a){return a.nodeType===1});if(O.test(b))return f.filter(b,d,!c);b=f.filter(b,d)}return f.grep(a,function(a,d){return f.inArray(a,b)>=0===c})}function U(a){var b=V.split("|"),c=a.createDocumentFragment();if(c.createElement)while(b.length)c.createElement(b.pop());return c}function ib(a,b){return f.nodeName(a,"table")?a.getElementsByTagName("tbody")[0]||a.appendChild(a.ownerDocument.createElement("tbody")):a}function jb(a,b){if(b.nodeType!==1||!f.hasData(a))return;var c,d,e,g=f._data(a),h=f._data(b,g),i=g.events;if(i){delete h.handle,h.events={};for(c in i)for(d=0,e=i[c].length;d<e;d++)f.event.add(b,c,i[c][d])}h.data&&(h.data=f.extend({},h.data))}function kb(a,b){var c;if(b.nodeType!==1)return;b.clearAttributes&&b.clearAttributes(),b.mergeAttributes&&b.mergeAttributes(a),c=b.nodeName.toLowerCase(),c==="object"?b.outerHTML=a.outerHTML:c!=="input"||a.type!=="checkbox"&&a.type!=="radio"?c==="option"?b.selected=a.defaultSelected:c==="input"||c==="textarea"?b.defaultValue=a.defaultValue:c==="script"&&b.text!==a.text&&(b.text=a.text):(a.checked&&(b.defaultChecked=b.checked=a.checked),b.value!==a.value&&(b.value=a.value)),b.removeAttribute(f.expando),b.removeAttribute("_submit_attached"),b.removeAttribute("_change_attached")}function lb(a){return typeof a.getElementsByTagName!="undefined"?a.getElementsByTagName("*"):typeof a.querySelectorAll!="undefined"?a.querySelectorAll("*"):[]}function mb(a){if(a.type==="checkbox"||a.type==="radio")a.defaultChecked=a.checked}function nb(a){var b=(a.nodeName||"").toLowerCase();b==="input"?mb(a):b!=="script"&&typeof a.getElementsByTagName!="undefined"&&f.grep(a.getElementsByTagName("input"),mb)}function ob(a){var b=c.createElement("div");return hb.appendChild(b),b.innerHTML=a.outerHTML,b.firstChild}function Bb(a,b,c){var d=b==="width"?a.offsetWidth:a.offsetHeight,e=b==="width"?1:0,g=4;if(d>0){if(c!=="border")for(;e<g;e+=2)c||(d-=parseFloat(f.css(a,"padding"+xb[e]))||0),c==="margin"?d+=parseFloat(f.css(a,c+xb[e]))||0:d-=parseFloat(f.css(a,"border"+xb[e]+"Width"))||0;return d+"px"}d=yb(a,b);if(d<0||d==null)d=a.style[b];if(tb.test(d))return d;d=parseFloat(d)||0;if(c)for(;e<g;e+=2)d+=parseFloat(f.css(a,"padding"+xb[e]))||0,c!=="padding"&&(d+=parseFloat(f.css(a,"border"+xb[e]+"Width"))||0),c==="margin"&&(d+=parseFloat(f.css(a,c+xb[e]))||0);return d+"px"}function Yb(a){return function(b,c){typeof b!="string"&&(c=b,b="*");if(f.isFunction(c)){var d=b.toLowerCase().split(Ob),e=0,g=d.length,h,i,j;for(;e<g;e++)h=d[e],j=/^\+/.test(h),j&&(h=h.substr(1)||"*"),i=a[h]=a[h]||[],i[j?"unshift":"push"](c)}}}function Zb(a,c,d,e,f,g){f=f||c.dataTypes[0],g=g||{},g[f]=!0;var h=a[f],i=0,j=h?h.length:0,k=a===Sb,l;for(;i<j&&(k||!l);i++)l=h[i](c,d,e),typeof l=="string"&&(!k||g[l]?l=b:(c.dataTypes.unshift(l),l=Zb(a,c,d,e,l,g)));return(k||!l)&&!g["*"]&&(l=Zb(a,c,d,e,"*",g)),l}function $b(a,c){var d,e,g=f.ajaxSettings.flatOptions||{};for(d in c)c[d]!==b&&((g[d]?a:e||(e={}))[d]=c[d]);e&&f.extend(!0,a,e)}function _b(a,b,c,d){if(f.isArray(b))f.each(b,function(b,e){c||Db.test(a)?d(a,e):_b(a+"["+(typeof e=="object"?b:"")+"]",e,c,d)});else if(!c&&f.type(b)==="object")for(var e in b)_b(a+"["+e+"]",b[e],c,d);else d(a,b)}function ac(a,c,d){var e=a.contents,f=a.dataTypes,g=a.responseFields,h,i,j,k;for(i in g)i in d&&(c[g[i]]=d[i]);while(f[0]==="*")f.shift(),h===b&&(h=a.mimeType||c.getResponseHeader("content-type"));if(h)for(i in e)if(e[i]&&e[i].test(h)){f.unshift(i);break}if(f[0]in d)j=f[0];else{for(i in d){if(!f[0]||a.converters[i+" "+f[0]]){j=i;break}k||(k=i)}j=j||k}if(j)return j!==f[0]&&f.unshift(j),d[j]}function bc(a,c){a.dataFilter&&(c=a.dataFilter(c,a.dataType));var d=a.dataTypes,e={},g,h,i=d.length,j,k=d[0],l,m,n,o,p;for(g=1;g<i;g++){if(g===1)for(h in a.converters)typeof h=="string"&&(e[h.toLowerCase()]=a.converters[h]);l=k,k=d[g];if(k==="*")k=l;else if(l!=="*"&&l!==k){m=l+" "+k,n=e[m]||e["* "+k];if(!n){p=b;for(o in e){j=o.split(" ");if(j[0]===l||j[0]==="*"){p=e[j[1]+" "+k];if(p){o=e[o],o===!0?n=p:p===!0&&(n=o);break}}}}!n&&!p&&f.error("No conversion from "+m.replace(" "," to ")),n!==!0&&(c=n?n(c):p(o(c)))}}return c}function hc(){try{return new a.XMLHttpRequest}catch(b){}}function ic(){try{return new a.ActiveXObject("Microsoft.XMLHTTP")}catch(b){}}function rc(){return setTimeout(sc,0),qc=f.now()}function sc(){qc=b}function tc(a,b){var c={};return f.each(pc.concat.apply([],pc.slice(0,b)),function(){c[this]=a}),c}function uc(a){if(!jc[a]){var b=c.body,d=f("<"+a+">").appendTo(b),e=d.css("display");d.remove();if(e==="none"||e===""){kc||(kc=c.createElement("iframe"),kc.frameBorder=kc.width=kc.height=0),b.appendChild(kc);if(!lc||!kc.createElement)lc=(kc.contentWindow||kc.contentDocument).document,lc.write((f.support.boxModel?"<!doctype html>":"")+"<html><body>"),lc.close();d=lc.createElement(a),lc.body.appendChild(d),e=f.css(d,"display"),b.removeChild(kc)}jc[a]=e}return jc[a]}function yc(a){return f.isWindow(a)?a:a.nodeType===9?a.defaultView||a.parentWindow:!1}var c=a.document,d=a.navigator,e=a.location,f=function(){function J(){if(e.isReady)return;try{c.documentElement.doScroll("left")}catch(a){setTimeout(J,1);return}e.ready()}var e=function(a,b){return new e.fn.init(a,b,h)},f=a.jQuery,g=a.$,h,i=/^(?:[^#<]*(<[\w\W]+>)[^>]*$|#([\w\-]*)$)/,j=/\S/,k=/^\s+/,l=/\s+$/,m=/^<(\w+)\s*\/?>(?:<\/\1>)?$/,n=/^[\],:{}\s]*$/,o=/\\(?:["\\\/bfnrt]|u[0-9a-fA-F]{4})/g,p=/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,q=/(?:^|:|,)(?:\s*\[)+/g,r=/(webkit)[ \/]([\w.]+)/,s=/(opera)(?:.*version)?[ \/]([\w.]+)/,t=/(msie) ([\w.]+)/,u=/(mozilla)(?:.*? rv:([\w.]+))?/,v=/-([a-z]|[0-9])/ig,w=/^-ms-/,x=function(a,b){return(b+"").toUpperCase()},y=d.userAgent,z,A,B,C=Object.prototype.toString,D=Object.prototype.hasOwnProperty,E=Array.prototype.push,F=Array.prototype.slice,G=String.prototype.trim,H=Array.prototype.indexOf,I={};return e.fn=e.prototype={constructor:e,init:function(a,d,f){var g,h,j,k;if(!a)return this;if(a.nodeType)return this.context=this[0]=a,this.length=1,this;if(a==="body"&&!d&&c.body)return this.context=c,this[0]=c.body,this.selector=a,this.length=1,this;if(typeof a=="string"){a.charAt(0)==="<"&&a.charAt(a.length-1)===">"&&a.length>=3?g=[null,a,null]:g=i.exec(a);if(g&&(g[1]||!d)){if(g[1])return d=d instanceof e?d[0]:d,k=d?d.ownerDocument||d:c,j=m.exec(a),j?e.isPlainObject(d)?(a=[c.createElement(j[1])],e.fn.attr.call(a,d,!0)):a=[k.createElement(j[1])]:(j=e.buildFragment([g[1]],[k]),a=(j.cacheable?e.clone(j.fragment):j.fragment).childNodes),e.merge(this,a);h=c.getElementById(g[2]);if(h&&h.parentNode){if(h.id!==g[2])return f.find(a);this.length=1,this[0]=h}return this.context=c,this.selector=a,this}return!d||d.jquery?(d||f).find(a):this.constructor(d).find(a)}return e.isFunction(a)?f.ready(a):(a.selector!==b&&(this.selector=a.selector,this.context=a.context),e.makeArray(a,this))},selector:"",jquery:"1.7.2",length:0,size:function(){return this.length},toArray:function(){return F.call(this,0)},get:function(a){return a==null?this.toArray():a<0?this[this.length+a]:this[a]},pushStack:function(a,b,c){var d=this.constructor();return e.isArray(a)?E.apply(d,a):e.merge(d,a),d.prevObject=this,d.context=this.context,b==="find"?d.selector=this.selector+(this.selector?" ":"")+c:b&&(d.selector=this.selector+"."+b+"("+c+")"),d},each:function(a,b){return e.each(this,a,b)},ready:function(a){return e.bindReady(),A.add(a),this},eq:function(a){return a=+a,a===-1?this.slice(a):this.slice(a,a+1)},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},slice:function(){return this.pushStack(F.apply(this,arguments),"slice",F.call(arguments).join(","))},map:function(a){return this.pushStack(e.map(this,function(b,c){return a.call(b,c,b)}))},end:function(){return this.prevObject||this.constructor(null)},push:E,sort:[].sort,splice:[].splice},e.fn.init.prototype=e.fn,e.extend=e.fn.extend=function(){var a,c,d,f,g,h,i=arguments[0]||{},j=1,k=arguments.length,l=!1;typeof i=="boolean"&&(l=i,i=arguments[1]||{},j=2),typeof i!="object"&&!e.isFunction(i)&&(i={}),k===j&&(i=this,--j);for(;j<k;j++)if((a=arguments[j])!=null)for(c in a){d=i[c],f=a[c];if(i===f)continue;l&&f&&(e.isPlainObject(f)||(g=e.isArray(f)))?(g?(g=!1,h=d&&e.isArray(d)?d:[]):h=d&&e.isPlainObject(d)?d:{},i[c]=e.extend(l,h,f)):f!==b&&(i[c]=f)}return i},e.extend({noConflict:function(b){return a.$===e&&(a.$=g),b&&a.jQuery===e&&(a.jQuery=f),e},isReady:!1,readyWait:1,holdReady:function(a){a?e.readyWait++:e.ready(!0)},ready:function(a){if(a===!0&&!--e.readyWait||a!==!0&&!e.isReady){if(!c.body)return setTimeout(e.ready,1);e.isReady=!0;if(a!==!0&&--e.readyWait>0)return;A.fireWith(c,[e]),e.fn.trigger&&e(c).trigger("ready").off("ready")}},bindReady:function(){if(A)return;A=e.Callbacks("once memory");if(c.readyState==="complete")return setTimeout(e.ready,1);if(c.addEventListener)c.addEventListener("DOMContentLoaded",B,!1),a.addEventListener("load",e.ready,!1);else if(c.attachEvent){c.attachEvent("onreadystatechange",B),a.attachEvent("onload",e.ready);var b=!1;try{b=a.frameElement==null}catch(d){}c.documentElement.doScroll&&b&&J()}},isFunction:function(a){return e.type(a)==="function"},isArray:Array.isArray||function(a){return e.type(a)==="array"},isWindow:function(a){return a!=null&&a==a.window},isNumeric:function(a){return!isNaN(parseFloat(a))&&isFinite(a)},type:function(a){return a==null?String(a):I[C.call(a)]||"object"},isPlainObject:function(a){if(!a||e.type(a)!=="object"||a.nodeType||e.isWindow(a))return!1;try{if(a.constructor&&!D.call(a,"constructor")&&!D.call(a.constructor.prototype,"isPrototypeOf"))return!1}catch(c){return!1}var d;for(d in a);return d===b||D.call(a,d)},isEmptyObject:function(a){for(var b in a)return!1;return!0},error:function(a){throw new Error(a)},parseJSON:function(b){if(typeof b!="string"||!b)return null;b=e.trim(b);if(a.JSON&&a.JSON.parse)return a.JSON.parse(b);if(n.test(b.replace(o,"@").replace(p,"]").replace(q,"")))return(new Function("return "+b))();e.error("Invalid JSON: "+b)},parseXML:function(c){if(typeof c!="string"||!c)return null;var d,f;try{a.DOMParser?(f=new DOMParser,d=f.parseFromString(c,"text/xml")):(d=new ActiveXObject("Microsoft.XMLDOM"),d.async="false",d.loadXML(c))}catch(g){d=b}return(!d||!d.documentElement||d.getElementsByTagName("parsererror").length)&&e.error("Invalid XML: "+c),d},noop:function(){},globalEval:function(b){b&&j.test(b)&&(a.execScript||function(b){a.eval.call(a,b)})(b)},camelCase:function(a){return a.replace(w,"ms-").replace(v,x)},nodeName:function(a,b){return a.nodeName&&a.nodeName.toUpperCase()===b.toUpperCase()},each:function(a,c,d){var f,g=0,h=a.length,i=h===b||e.isFunction(a);if(d){if(i){for(f in a)if(c.apply(a[f],d)===!1)break}else for(;g<h;)if(c.apply(a[g++],d)===!1)break}else if(i){for(f in a)if(c.call(a[f],f,a[f])===!1)break}else for(;g<h;)if(c.call(a[g],g,a[g++])===!1)break;return a},trim:G?function(a){return a==null?"":G.call(a)}:function(a){return a==null?"":a.toString().replace(k,"").replace(l,"")},makeArray:function(a,b){var c=b||[];if(a!=null){var d=e.type(a);a.length==null||d==="string"||d==="function"||d==="regexp"||e.isWindow(a)?E.call(c,a):e.merge(c,a)}return c},inArray:function(a,b,c){var d;if(b){if(H)return H.call(b,a,c);d=b.length,c=c?c<0?Math.max(0,d+c):c:0;for(;c<d;c++)if(c in b&&b[c]===a)return c}return-1},merge:function(a,c){var d=a.length,e=0;if(typeof c.length=="number")for(var f=c.length;e<f;e++)a[d++]=c[e];else while(c[e]!==b)a[d++]=c[e++];return a.length=d,a},grep:function(a,b,c){var d=[],e;c=!!c;for(var f=0,g=a.length;f<g;f++)e=!!b(a[f],f),c!==e&&d.push(a[f]);return d},map:function(a,c,d){var f,g,h=[],i=0,j=a.length,k=a instanceof e||j!==b&&typeof j=="number"&&(j>0&&a[0]&&a[j-1]||j===0||e.isArray(a));if(k)for(;i<j;i++)f=c(a[i],i,d),f!=null&&(h[h.length]=f);else for(g in a)f=c(a[g],g,d),f!=null&&(h[h.length]=f);return h.concat.apply([],h)},guid:1,proxy:function(a,c){if(typeof c=="string"){var d=a[c];c=a,a=d}if(!e.isFunction(a))return b;var f=F.call(arguments,2),g=function(){return a.apply(c,f.concat(F.call(arguments)))};return g.guid=a.guid=a.guid||g.guid||e.guid++,g},access:function(a,c,d,f,g,h,i){var j,k=d==null,l=0,m=a.length;if(d&&typeof d=="object"){for(l in d)e.access(a,c,l,d[l],1,h,f);g=1}else if(f!==b){j=i===b&&e.isFunction(f),k&&(j?(j=c,c=function(a,b,c){return j.call(e(a),c)}):(c.call(a,f),c=null));if(c)for(;l<m;l++)c(a[l],d,j?f.call(a[l],l,c(a[l],d)):f,i);g=1}return g?a:k?c.call(a):m?c(a[0],d):h},now:function(){return(new Date).getTime()},uaMatch:function(a){a=a.toLowerCase();var b=r.exec(a)||s.exec(a)||t.exec(a)||a.indexOf("compatible")<0&&u.exec(a)||[];return{browser:b[1]||"",version:b[2]||"0"}},sub:function(){function a(b,c){return new a.fn.init(b,c)}e.extend(!0,a,this),a.superclass=this,a.fn=a.prototype=this(),a.fn.constructor=a,a.sub=this.sub,a.fn.init=function(d,f){return f&&f instanceof e&&!(f instanceof a)&&(f=a(f)),e.fn.init.call(this,d,f,b)},a.fn.init.prototype=a.fn;var b=a(c);return a},browser:{}}),e.each("Boolean Number String Function Array Date RegExp Object".split(" "),function(a,b){I["[object "+b+"]"]=b.toLowerCase()}),z=e.uaMatch(y),z.browser&&(e.browser[z.browser]=!0,e.browser.version=z.version),e.browser.webkit&&(e.browser.safari=!0),j.test(" ")&&(k=/^[\s\xA0]+/,l=/[\s\xA0]+$/),h=e(c),c.addEventListener?B=function(){c.removeEventListener("DOMContentLoaded",B,!1),e.ready()}:c.attachEvent&&(B=function(){c.readyState==="complete"&&(c.detachEvent("onreadystatechange",B),e.ready())}),e}(),g={};f.Callbacks=function(a){a=a?g[a]||h(a):{};var c=[],d=[],e,i,j,k,l,m,n=function(b){var d,e,g,h,i;for(d=0,e=b.length;d<e;d++)g=b[d],h=f.type(g),h==="array"?n(g):h==="function"&&(!a.unique||!p.has(g))&&c.push(g)},o=function(b,f){f=f||[],e=!a.memory||[b,f],i=!0,j=!0,m=k||0,k=0,l=c.length;for(;c&&m<l;m++)if(c[m].apply(b,f)===!1&&a.stopOnFalse){e=!0;break}j=!1,c&&(a.once?e===!0?p.disable():c=[]:d&&d.length&&(e=d.shift(),p.fireWith(e[0],e[1])))},p={add:function(){if(c){var a=c.length;n(arguments),j?l=c.length:e&&e!==!0&&(k=a,o(e[0],e[1]))}return this},remove:function(){if(c){var b=arguments,d=0,e=b.length;for(;d<e;d++)for(var f=0;f<c.length;f++)if(b[d]===c[f]){j&&f<=l&&(l--,f<=m&&m--),c.splice(f--,1);if(a.unique)break}}return this},has:function(a){if(c){var b=0,d=c.length;for(;b<d;b++)if(a===c[b])return!0}return!1},empty:function(){return c=[],this},disable:function(){return c=d=e=b,this},disabled:function(){return!c},lock:function(){return d=b,(!e||e===!0)&&p.disable(),this},locked:function(){return!d},fireWith:function(b,c){return d&&(j?a.once||d.push([b,c]):(!a.once||!e)&&o(b,c)),this},fire:function(){return p.fireWith(this,arguments),this},fired:function(){return!!i}};return p};var i=[].slice;f.extend({Deferred:function(a){var b=f.Callbacks("once memory"),c=f.Callbacks("once memory"),d=f.Callbacks("memory"),e="pending",g={resolve:b,reject:c,notify:d},h={done:b.add,fail:c.add,progress:d.add,state:function(){return e},isResolved:b.fired,isRejected:c.fired,then:function(a,b,c){return i.done(a).fail(b).progress(c),this},always:function(){return i.done.apply(i,arguments).fail.apply(i,arguments),this},pipe:function(a,b,c){return f.Deferred(function(d){f.each({done:[a,"resolve"],fail:[b,"reject"],progress:[c,"notify"]},function(a,b){var c=b[0],e=b[1],g;f.isFunction(c)?i[a](function(){g=c.apply(this,arguments),g&&f.isFunction(g.promise)?g.promise().then(d.resolve,d.reject,d.notify):d[e+"With"](this===i?d:this,[g])}):i[a](d[e])})}).promise()},promise:function(a){if(a==null)a=h;else for(var b in h)a[b]=h[b];return a}},i=h.promise({}),j;for(j in g)i[j]=g[j].fire,i[j+"With"]=g[j].fireWith;return i.done(function(){e="resolved"},c.disable,d.lock).fail(function(){e="rejected"},b.disable,d.lock),a&&a.call(i,i),i},when:function(a){function l(a){return function(c){b[a]=arguments.length>1?i.call(arguments,0):c,--g||j.resolveWith(j,b)}}function m(a){return function(b){e[a]=arguments.length>1?i.call(arguments,0):b,j.notifyWith(k,e)}}var b=i.call(arguments,0),c=0,d=b.length,e=new Array(d),g=d,h=d,j=d<=1&&a&&f.isFunction(a.promise)?a:f.Deferred(),k=j.promise();if(d>1){for(;c<d;c++)b[c]&&b[c].promise&&f.isFunction(b[c].promise)?b[c].promise().then(l(c),j.reject,m(c)):--g;g||j.resolveWith(j,b)}else j!==a&&j.resolveWith(j,d?[a]:[]);return k}}),f.support=function(){var b,d,e,g,h,i,j,k,l,m,n,o,p=c.createElement("div"),q=c.documentElement;p.setAttribute("className","t"),p.innerHTML=" <link/><table></table><a href='/a' style='top:1px;float:left;opacity:.55;'>a</a><input type='checkbox'/>",d=p.getElementsByTagName("*"),e=p.getElementsByTagName("a")[0];if(!d||!d.length||!e)return{};g=c.createElement("select"),h=g.appendChild(c.createElement("option")),i=p.getElementsByTagName("input")[0],b={leadingWhitespace:p.firstChild.nodeType===3,tbody:!p.getElementsByTagName("tbody").length,htmlSerialize:!!p.getElementsByTagName("link").length,style:/top/.test(e.getAttribute("style")),hrefNormalized:e.getAttribute("href")==="/a",opacity:/^0.55/.test(e.style.opacity),cssFloat:!!e.style.cssFloat,checkOn:i.value==="on",optSelected:h.selected,getSetAttribute:p.className!=="t",enctype:!!c.createElement("form").enctype,html5Clone:c.createElement("nav").cloneNode(!0).outerHTML!=="<:nav></:nav>",submitBubbles:!0,changeBubbles:!0,focusinBubbles:!1,deleteExpando:!0,noCloneEvent:!0,inlineBlockNeedsLayout:!1,shrinkWrapBlocks:!1,reliableMarginRight:!0,pixelMargin:!0},f.boxModel=b.boxModel=c.compatMode==="CSS1Compat",i.checked=!0,b.noCloneChecked=i.cloneNode(!0).checked,g.disabled=!0,b.optDisabled=!h.disabled;try{delete p.test}catch(r){b.deleteExpando=!1}!p.addEventListener&&p.attachEvent&&p.fireEvent&&(p.attachEvent("onclick",function(){b.noCloneEvent=!1}),p.cloneNode(!0).fireEvent("onclick")),i=c.createElement("input"),i.value="t",i.setAttribute("type","radio"),b.radioValue=i.value==="t",i.setAttribute("checked","checked"),i.setAttribute("name","t"),p.appendChild(i),j=c.createDocumentFragment(),j.appendChild(p.lastChild),b.checkClone=j.cloneNode(!0).cloneNode(!0).lastChild.checked,b.appendChecked=i.checked,j.removeChild(i),j.appendChild(p);if(p.attachEvent)for(n in{submit:1,change:1,focusin:1})m="on"+n,o=m in p,o||(p.setAttribute(m,"return;"),o=typeof p[m]=="function"),b[n+"Bubbles"]=o;return j.removeChild(p),j=g=h=p=i=null,f(function(){var d,e,g,h,i,j,l,m,n,q,r,s,t,u=c.getElementsByTagName("body")[0];if(!u)return;m=1,t="padding:0;margin:0;border:",r="position:absolute;top:0;left:0;width:1px;height:1px;",s=t+"0;visibility:hidden;",n="style='"+r+t+"5px solid #000;",q="<div "+n+"display:block;'><div style='"+t+"0;display:block;overflow:hidden;'></div></div>"+"<table "+n+"' cellpadding='0' cellspacing='0'>"+"<tr><td></td></tr></table>",d=c.createElement("div"),d.style.cssText=s+"width:0;height:0;position:static;top:0;margin-top:"+m+"px",u.insertBefore(d,u.firstChild),p=c.createElement("div"),d.appendChild(p),p.innerHTML="<table><tr><td style='"+t+"0;display:none'></td><td>t</td></tr></table>",k=p.getElementsByTagName("td"),o=k[0].offsetHeight===0,k[0].style.display="",k[1].style.display="none",b.reliableHiddenOffsets=o&&k[0].offsetHeight===0,a.getComputedStyle&&(p.innerHTML="",l=c.createElement("div"),l.style.width="0",l.style.marginRight="0",p.style.width="2px",p.appendChild(l),b.reliableMarginRight=(parseInt((a.getComputedStyle(l,null)||{marginRight:0}).marginRight,10)||0)===0),typeof p.style.zoom!="undefined"&&(p.innerHTML="",p.style.width=p.style.padding="1px",p.style.border=0,p.style.overflow="hidden",p.style.display="inline",p.style.zoom=1,b.inlineBlockNeedsLayout=p.offsetWidth===3,p.style.display="block",p.style.overflow="visible",p.innerHTML="<div style='width:5px;'></div>",b.shrinkWrapBlocks=p.offsetWidth!==3),p.style.cssText=r+s,p.innerHTML=q,e=p.firstChild,g=e.firstChild,i=e.nextSibling.firstChild.firstChild,j={doesNotAddBorder:g.offsetTop!==5,doesAddBorderForTableAndCells:i.offsetTop===5},g.style.position="fixed",g.style.top="20px",j.fixedPosition=g.offsetTop===20||g.offsetTop===15,g.style.position=g.style.top="",e.style.overflow="hidden",e.style.position="relative",j.subtractsBorderForOverflowNotVisible=g.offsetTop===-5,j.doesNotIncludeMarginInBodyOffset=u.offsetTop!==m,a.getComputedStyle&&(p.style.marginTop="1%",b.pixelMargin=(a.getComputedStyle(p,null)||{marginTop:0}).marginTop!=="1%"),typeof d.style.zoom!="undefined"&&(d.style.zoom=1),u.removeChild(d),l=p=d=null,f.extend(b,j)}),b}();var j=/^(?:\{.*\}|\[.*\])$/,k=/([A-Z])/g;f.extend({cache:{},uuid:0,expando:"jQuery"+(f.fn.jquery+Math.random()).replace(/\D/g,""),noData:{embed:!0,object:"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000",applet:!0},hasData:function(a){return a=a.nodeType?f.cache[a[f.expando]]:a[f.expando],!!a&&!m(a)},data:function(a,c,d,e){if(!f.acceptData(a))return;var g,h,i,j=f.expando,k=typeof c=="string",l=a.nodeType,m=l?f.cache:a,n=l?a[j]:a[j]&&j,o=c==="events";if((!n||!m[n]||!o&&!e&&!m[n].data)&&k&&d===b)return;n||(l?a[j]=n=++f.uuid:n=j),m[n]||(m[n]={},l||(m[n].toJSON=f.noop));if(typeof c=="object"||typeof c=="function")e?m[n]=f.extend(m[n],c):m[n].data=f.extend(m[n].data,c);return g=h=m[n],e||(h.data||(h.data={}),h=h.data),d!==b&&(h[f.camelCase(c)]=d),o&&!h[c]?g.events:(k?(i=h[c],i==null&&(i=h[f.camelCase(c)])):i=h,i)},removeData:function(a,b,c){if(!f.acceptData(a))return;var d,e,g,h=f.expando,i=a.nodeType,j=i?f.cache:a,k=i?a[h]:h;if(!j[k])return;if(b){d=c?j[k]:j[k].data;if(d){f.isArray(b)||(b in d?b=[b]:(b=f.camelCase(b),b in d?b=[b]:b=b.split(" ")));for(e=0,g=b.length;e<g;e++)delete d[b[e]];if(!(c?m:f.isEmptyObject)(d))return}}if(!c){delete j[k].data;if(!m(j[k]))return}f.support.deleteExpando||!j.setInterval?delete j[k]:j[k]=null,i&&(f.support.deleteExpando?delete a[h]:a.removeAttribute?a.removeAttribute(h):a[h]=null)},_data:function(a,b,c){return f.data(a,b,c,!0)},acceptData:function(a){if(a.nodeName){var b=f.noData[a.nodeName.toLowerCase()];if(b)return b!==!0&&a.getAttribute("classid")===b}return!0}}),f.fn.extend({data:function(a,c){var d,e,g,h,i,j=this[0],k=0,m=null;if(a===b){if(this.length){m=f.data(j);if(j.nodeType===1&&!f._data(j,"parsedAttrs")){g=j.attributes;for(i=g.length;k<i;k++)h=g[k].name,h.indexOf("data-")===0&&(h=f.camelCase(h.substring(5)),l(j,h,m[h]));f._data(j,"parsedAttrs",!0)}}return m}return typeof a=="object"?this.each(function(){f.data(this,a)}):(d=a.split(".",2),d[1]=d[1]?"."+d[1]:"",e=d[1]+"!",f.access(this,function(c){if(c===b)return m=this.triggerHandler("getData"+e,[d[0]]),m===b&&j&&(m=f.data(j,a),m=l(j,a,m)),m===b&&d[1]?this.data(d[0]):m;d[1]=c,this.each(function(){var b=f(this);b.triggerHandler("setData"+e,d),f.data(this,a,c),b.triggerHandler("changeData"+e,d)})},null,c,arguments.length>1,null,!1))},removeData:function(a){return this.each(function(){f.removeData(this,a)})}}),f.extend({_mark:function(a,b){a&&(b=(b||"fx")+"mark",f._data(a,b,(f._data(a,b)||0)+1))},_unmark:function(a,b,c){a!==!0&&(c=b,b=a,a=!1);if(b){c=c||"fx";var d=c+"mark",e=a?0:(f._data(b,d)||1)-1;e?f._data(b,d,e):(f.removeData(b,d,!0),n(b,c,"mark"))}},queue:function(a,b,c){var d;if(a)return b=(b||"fx")+"queue",d=f._data(a,b),c&&(!d||f.isArray(c)?d=f._data(a,b,f.makeArray(c)):d.push(c)),d||[]},dequeue:function(a,b){b=b||"fx";var c=f.queue(a,b),d=c.shift(),e={};d==="inprogress"&&(d=c.shift()),d&&(b==="fx"&&c.unshift("inprogress"),f._data(a,b+".run",e),d.call(a,function(){f.dequeue(a,b)},e)),c.length||(f.removeData(a,b+"queue "+b+".run",!0),n(a,b,"queue"))}}),f.fn.extend({queue:function(a,c){var d=2;return typeof a!="string"&&(c=a,a="fx",d--),arguments.length<d?f.queue(this[0],a):c===b?this:this.each(function(){var b=f.queue(this,a,c);a==="fx"&&b[0]!=="inprogress"&&f.dequeue(this,a)})},dequeue:function(a){return this.each(function(){f.dequeue(this,a)})},delay:function(a,b){return a=f.fx?f.fx.speeds[a]||a:a,b=b||"fx",this.queue(b,function(b,c){var d=setTimeout(b,a);c.stop=function(){clearTimeout(d)}})},clearQueue:function(a){return this.queue(a||"fx",[])},promise:function(a,c){function m(){--h||d.resolveWith(e,[e])}typeof a!="string"&&(c=a,a=b),a=a||"fx";var d=f.Deferred(),e=this,g=e.length,h=1,i=a+"defer",j=a+"queue",k=a+"mark",l;while(g--)if(l=f.data(e[g],i,b,!0)||(f.data(e[g],j,b,!0)||f.data(e[g],k,b,!0))&&f.data(e[g],i,f.Callbacks("once memory"),!0))h++,l.add(m);return m(),d.promise(c)}});var o=/[\n\t\r]/g,p=/\s+/,q=/\r/g,r=/^(?:button|input)$/i,s=/^(?:button|input|object|select|textarea)$/i,t=/^a(?:rea)?$/i,u=/^(?:autofocus|autoplay|async|checked|controls|defer|disabled|hidden|loop|multiple|open|readonly|required|scoped|selected)$/i,v=f.support.getSetAttribute,w,x,y;f.fn.extend({attr:function(a,b){return f.access(this,f.attr,a,b,arguments.length>1)},removeAttr:function(a){return this.each(function(){f.removeAttr(this,a)})},prop:function(a,b){return f.access(this,f.prop,a,b,arguments.length>1)},removeProp:function(a){return a=f.propFix[a]||a,this.each(function(){try{this[a]=b,delete this[a]}catch(c){}})},addClass:function(a){var b,c,d,e,g,h,i;if(f.isFunction(a))return this.each(function(b){f(this).addClass(a.call(this,b,this.className))});if(a&&typeof a=="string"){b=a.split(p);for(c=0,d=this.length;c<d;c++){e=this[c];if(e.nodeType===1)if(!e.className&&b.length===1)e.className=a;else{g=" "+e.className+" ";for(h=0,i=b.length;h<i;h++)~g.indexOf(" "+b[h]+" ")||(g+=b[h]+" ");e.className=f.trim(g)}}}return this},removeClass:function(a){var c,d,e,g,h,i,j;if(f.isFunction(a))return this.each(function(b){f(this).removeClass(a.call(this,b,this.className))});if(a&&typeof a=="string"||a===b){c=(a||"").split(p);for(d=0,e=this.length;d<e;d++){g=this[d];if(g.nodeType===1&&g.className)if(a){h=(" "+g.className+" ").replace(o," ");for(i=0,j=c.length;i<j;i++)h=h.replace(" "+c[i]+" "," ");g.className=f.trim(h)}else g.className=""}}return this},toggleClass:function(a,b){var c=typeof a,d=typeof b=="boolean";return f.isFunction(a)?this.each(function(c){f(this).toggleClass(a.call(this,c,this.className,b),b)}):this.each(function(){if(c==="string"){var e,g=0,h=f(this),i=b,j=a.split(p);while(e=j[g++])i=d?i:!h.hasClass(e),h[i?"addClass":"removeClass"](e)}else if(c==="undefined"||c==="boolean")this.className&&f._data(this,"__className__",this.className),this.className=this.className||a===!1?"":f._data(this,"__className__")||""})},hasClass:function(a){var b=" "+a+" ",c=0,d=this.length;for(;c<d;c++)if(this[c].nodeType===1&&(" "+this[c].className+" ").replace(o," ").indexOf(b)>-1)return!0;return!1},val:function(a){var c,d,e,g=this[0];if(!arguments.length){if(g)return c=f.valHooks[g.type]||f.valHooks[g.nodeName.toLowerCase()],c&&"get"in c&&(d=c.get(g,"value"))!==b?d:(d=g.value,typeof d=="string"?d.replace(q,""):d==null?"":d);return}return e=f.isFunction(a),this.each(function(d){var g=f(this),h;if(this.nodeType!==1)return;e?h=a.call(this,d,g.val()):h=a,h==null?h="":typeof h=="number"?h+="":f.isArray(h)&&(h=f.map(h,function(a){return a==null?"":a+""})),c=f.valHooks[this.type]||f.valHooks[this.nodeName.toLowerCase()];if(!c||!("set"in c)||c.set(this,h,"value")===b)this.value=h})}}),f.extend({valHooks:{option:{get:function(a){var b=a.attributes.value;return!b||b.specified?a.value:a.text}},select:{get:function(a){var b,c,d,e,g=a.selectedIndex,h=[],i=a.options,j=a.type==="select-one";if(g<0)return null;c=j?g:0,d=j?g+1:i.length;for(;c<d;c++){e=i[c];if(e.selected&&(f.support.optDisabled?!e.disabled:e.getAttribute("disabled")===null)&&(!e.parentNode.disabled||!f.nodeName(e.parentNode,"optgroup"))){b=f(e).val();if(j)return b;h.push(b)}}return j&&!h.length&&i.length?f(i[g]).val():h},set:function(a,b){var c=f.makeArray(b);return f(a).find("option").each(function(){this.selected=f.inArray(f(this).val(),c)>=0}),c.length||(a.selectedIndex=-1),c}}},attrFn:{val:!0,css:!0,html:!0,text:!0,data:!0,width:!0,height:!0,offset:!0},attr:function(a,c,d,e){var g,h,i,j=a.nodeType;if(!a||j===3||j===8||j===2)return;if(e&&c in f.attrFn)return f(a)[c](d);if(typeof a.getAttribute=="undefined")return f.prop(a,c,d);i=j!==1||!f.isXMLDoc(a),i&&(c=c.toLowerCase(),h=f.attrHooks[c]||(u.test(c)?x:w));if(d!==b){if(d===null){f.removeAttr(a,c);return}return h&&"set"in h&&i&&(g=h.set(a,d,c))!==b?g:(a.setAttribute(c,""+d),d)}return h&&"get"in h&&i&&(g=h.get(a,c))!==null?g:(g=a.getAttribute(c),g===null?b:g)},removeAttr:function(a,b){var c,d,e,g,h,i=0;if(b&&a.nodeType===1){d=b.toLowerCase().split(p),g=d.length;for(;i<g;i++)e=d[i],e&&(c=f.propFix[e]||e,h=u.test(e),h||f.attr(a,e,""),a.removeAttribute(v?e:c),h&&c in a&&(a[c]=!1))}},attrHooks:{type:{set:function(a,b){if(r.test(a.nodeName)&&a.parentNode)f.error("type property can't be changed");else if(!f.support.radioValue&&b==="radio"&&f.nodeName(a,"input")){var c=a.value;return a.setAttribute("type",b),c&&(a.value=c),b}}},value:{get:function(a,b){return w&&f.nodeName(a,"button")?w.get(a,b):b in a?a.value:null},set:function(a,b,c){if(w&&f.nodeName(a,"button"))return w.set(a,b,c);a.value=b}}},propFix:{tabindex:"tabIndex",readonly:"readOnly","for":"htmlFor","class":"className",maxlength:"maxLength",cellspacing:"cellSpacing",cellpadding:"cellPadding",rowspan:"rowSpan",colspan:"colSpan",usemap:"useMap",frameborder:"frameBorder",contenteditable:"contentEditable"},prop:function(a,c,d){var e,g,h,i=a.nodeType;if(!a||i===3||i===8||i===2)return;return h=i!==1||!f.isXMLDoc(a),h&&(c=f.propFix[c]||c,g=f.propHooks[c]),d!==b?g&&"set"in g&&(e=g.set(a,d,c))!==b?e:a[c]=d:g&&"get"in g&&(e=g.get(a,c))!==null?e:a[c]},propHooks:{tabIndex:{get:function(a){var c=a.getAttributeNode("tabindex");return c&&c.specified?parseInt(c.value,10):s.test(a.nodeName)||t.test(a.nodeName)&&a.href?0:b}}}}),f.attrHooks.tabindex=f.propHooks.tabIndex,x={get:function(a,c){var d,e=f.prop(a,c);return e===!0||typeof e!="boolean"&&(d=a.getAttributeNode(c))&&d.nodeValue!==!1?c.toLowerCase():b},set:function(a,b,c){var d;return b===!1?f.removeAttr(a,c):(d=f.propFix[c]||c,d in a&&(a[d]=!0),a.setAttribute(c,c.toLowerCase())),c}},v||(y={name:!0,id:!0,coords:!0},w=f.valHooks.button={get:function(a,c){var d;return d=a.getAttributeNode(c),d&&(y[c]?d.nodeValue!=="":d.specified)?d.nodeValue:b},set:function(a,b,d){var e=a.getAttributeNode(d);return e||(e=c.createAttribute(d),a.setAttributeNode(e)),e.nodeValue=b+""}},f.attrHooks.tabindex.set=w.set,f.each(["width","height"],function(a,b){f.attrHooks[b]=f.extend(f.attrHooks[b],{set:function(a,c){if(c==="")return a.setAttribute(b,"auto"),c}})}),f.attrHooks.contenteditable={get:w.get,set:function(a,b,c){b===""&&(b="false"),w.set(a,b,c)}}),f.support.hrefNormalized||f.each(["href","src","width","height"],function(a,c){f.attrHooks[c]=f.extend(f.attrHooks[c],{get:function(a){var d=a.getAttribute(c,2);return d===null?b:d}})}),f.support.style||(f.attrHooks.style={get:function(a){return a.style.cssText.toLowerCase()||b},set:function(a,b){return a.style.cssText=""+b}}),f.support.optSelected||(f.propHooks.selected=f.extend(f.propHooks.selected,{get:function(a){var b=a.parentNode;return b&&(b.selectedIndex,b.parentNode&&b.parentNode.selectedIndex),null}})),f.support.enctype||(f.propFix.enctype="encoding"),f.support.checkOn||f.each(["radio","checkbox"],function(){f.valHooks[this]={get:function(a){return a.getAttribute("value")===null?"on":a.value}}}),f.each(["radio","checkbox"],function(){f.valHooks[this]=f.extend(f.valHooks[this],{set:function(a,b){if(f.isArray(b))return a.checked=f.inArray(f(a).val(),b)>=0}})});var z=/^(?:textarea|input|select)$/i,A=/^([^\.]*)?(?:\.(.+))?$/,B=/(?:^|\s)hover(\.\S+)?\b/,C=/^key/,D=/^(?:mouse|contextmenu)|click/,E=/^(?:focusinfocus|focusoutblur)$/,F=/^(\w*)(?:#([\w\-]+))?(?:\.([\w\-]+))?$/,G=function(a){var b=F.exec(a);return b&&(
|
19
|
+
b[1]=(b[1]||"").toLowerCase(),b[3]=b[3]&&new RegExp("(?:^|\\s)"+b[3]+"(?:\\s|$)")),b},H=function(a,b){var c=a.attributes||{};return(!b[1]||a.nodeName.toLowerCase()===b[1])&&(!b[2]||(c.id||{}).value===b[2])&&(!b[3]||b[3].test((c["class"]||{}).value))},I=function(a){return f.event.special.hover?a:a.replace(B,"mouseenter$1 mouseleave$1")};f.event={add:function(a,c,d,e,g){var h,i,j,k,l,m,n,o,p,q,r,s;if(a.nodeType===3||a.nodeType===8||!c||!d||!(h=f._data(a)))return;d.handler&&(p=d,d=p.handler,g=p.selector),d.guid||(d.guid=f.guid++),j=h.events,j||(h.events=j={}),i=h.handle,i||(h.handle=i=function(a){return typeof f=="undefined"||!!a&&f.event.triggered===a.type?b:f.event.dispatch.apply(i.elem,arguments)},i.elem=a),c=f.trim(I(c)).split(" ");for(k=0;k<c.length;k++){l=A.exec(c[k])||[],m=l[1],n=(l[2]||"").split(".").sort(),s=f.event.special[m]||{},m=(g?s.delegateType:s.bindType)||m,s=f.event.special[m]||{},o=f.extend({type:m,origType:l[1],data:e,handler:d,guid:d.guid,selector:g,quick:g&&G(g),namespace:n.join(".")},p),r=j[m];if(!r){r=j[m]=[],r.delegateCount=0;if(!s.setup||s.setup.call(a,e,n,i)===!1)a.addEventListener?a.addEventListener(m,i,!1):a.attachEvent&&a.attachEvent("on"+m,i)}s.add&&(s.add.call(a,o),o.handler.guid||(o.handler.guid=d.guid)),g?r.splice(r.delegateCount++,0,o):r.push(o),f.event.global[m]=!0}a=null},global:{},remove:function(a,b,c,d,e){var g=f.hasData(a)&&f._data(a),h,i,j,k,l,m,n,o,p,q,r,s;if(!g||!(o=g.events))return;b=f.trim(I(b||"")).split(" ");for(h=0;h<b.length;h++){i=A.exec(b[h])||[],j=k=i[1],l=i[2];if(!j){for(j in o)f.event.remove(a,j+b[h],c,d,!0);continue}p=f.event.special[j]||{},j=(d?p.delegateType:p.bindType)||j,r=o[j]||[],m=r.length,l=l?new RegExp("(^|\\.)"+l.split(".").sort().join("\\.(?:.*\\.)?")+"(\\.|$)"):null;for(n=0;n<r.length;n++)s=r[n],(e||k===s.origType)&&(!c||c.guid===s.guid)&&(!l||l.test(s.namespace))&&(!d||d===s.selector||d==="**"&&s.selector)&&(r.splice(n--,1),s.selector&&r.delegateCount--,p.remove&&p.remove.call(a,s));r.length===0&&m!==r.length&&((!p.teardown||p.teardown.call(a,l)===!1)&&f.removeEvent(a,j,g.handle),delete o[j])}f.isEmptyObject(o)&&(q=g.handle,q&&(q.elem=null),f.removeData(a,["events","handle"],!0))},customEvent:{getData:!0,setData:!0,changeData:!0},trigger:function(c,d,e,g){if(!e||e.nodeType!==3&&e.nodeType!==8){var h=c.type||c,i=[],j,k,l,m,n,o,p,q,r,s;if(E.test(h+f.event.triggered))return;h.indexOf("!")>=0&&(h=h.slice(0,-1),k=!0),h.indexOf(".")>=0&&(i=h.split("."),h=i.shift(),i.sort());if((!e||f.event.customEvent[h])&&!f.event.global[h])return;c=typeof c=="object"?c[f.expando]?c:new f.Event(h,c):new f.Event(h),c.type=h,c.isTrigger=!0,c.exclusive=k,c.namespace=i.join("."),c.namespace_re=c.namespace?new RegExp("(^|\\.)"+i.join("\\.(?:.*\\.)?")+"(\\.|$)"):null,o=h.indexOf(":")<0?"on"+h:"";if(!e){j=f.cache;for(l in j)j[l].events&&j[l].events[h]&&f.event.trigger(c,d,j[l].handle.elem,!0);return}c.result=b,c.target||(c.target=e),d=d!=null?f.makeArray(d):[],d.unshift(c),p=f.event.special[h]||{};if(p.trigger&&p.trigger.apply(e,d)===!1)return;r=[[e,p.bindType||h]];if(!g&&!p.noBubble&&!f.isWindow(e)){s=p.delegateType||h,m=E.test(s+h)?e:e.parentNode,n=null;for(;m;m=m.parentNode)r.push([m,s]),n=m;n&&n===e.ownerDocument&&r.push([n.defaultView||n.parentWindow||a,s])}for(l=0;l<r.length&&!c.isPropagationStopped();l++)m=r[l][0],c.type=r[l][1],q=(f._data(m,"events")||{})[c.type]&&f._data(m,"handle"),q&&q.apply(m,d),q=o&&m[o],q&&f.acceptData(m)&&q.apply(m,d)===!1&&c.preventDefault();return c.type=h,!g&&!c.isDefaultPrevented()&&(!p._default||p._default.apply(e.ownerDocument,d)===!1)&&(h!=="click"||!f.nodeName(e,"a"))&&f.acceptData(e)&&o&&e[h]&&(h!=="focus"&&h!=="blur"||c.target.offsetWidth!==0)&&!f.isWindow(e)&&(n=e[o],n&&(e[o]=null),f.event.triggered=h,e[h](),f.event.triggered=b,n&&(e[o]=n)),c.result}return},dispatch:function(c){c=f.event.fix(c||a.event);var d=(f._data(this,"events")||{})[c.type]||[],e=d.delegateCount,g=[].slice.call(arguments,0),h=!c.exclusive&&!c.namespace,i=f.event.special[c.type]||{},j=[],k,l,m,n,o,p,q,r,s,t,u;g[0]=c,c.delegateTarget=this;if(i.preDispatch&&i.preDispatch.call(this,c)===!1)return;if(e&&(!c.button||c.type!=="click")){n=f(this),n.context=this.ownerDocument||this;for(m=c.target;m!=this;m=m.parentNode||this)if(m.disabled!==!0){p={},r=[],n[0]=m;for(k=0;k<e;k++)s=d[k],t=s.selector,p[t]===b&&(p[t]=s.quick?H(m,s.quick):n.is(t)),p[t]&&r.push(s);r.length&&j.push({elem:m,matches:r})}}d.length>e&&j.push({elem:this,matches:d.slice(e)});for(k=0;k<j.length&&!c.isPropagationStopped();k++){q=j[k],c.currentTarget=q.elem;for(l=0;l<q.matches.length&&!c.isImmediatePropagationStopped();l++){s=q.matches[l];if(h||!c.namespace&&!s.namespace||c.namespace_re&&c.namespace_re.test(s.namespace))c.data=s.data,c.handleObj=s,o=((f.event.special[s.origType]||{}).handle||s.handler).apply(q.elem,g),o!==b&&(c.result=o,o===!1&&(c.preventDefault(),c.stopPropagation()))}}return i.postDispatch&&i.postDispatch.call(this,c),c.result},props:"attrChange attrName relatedNode srcElement altKey bubbles cancelable ctrlKey currentTarget eventPhase metaKey relatedTarget shiftKey target timeStamp view which".split(" "),fixHooks:{},keyHooks:{props:"char charCode key keyCode".split(" "),filter:function(a,b){return a.which==null&&(a.which=b.charCode!=null?b.charCode:b.keyCode),a}},mouseHooks:{props:"button buttons clientX clientY fromElement offsetX offsetY pageX pageY screenX screenY toElement".split(" "),filter:function(a,d){var e,f,g,h=d.button,i=d.fromElement;return a.pageX==null&&d.clientX!=null&&(e=a.target.ownerDocument||c,f=e.documentElement,g=e.body,a.pageX=d.clientX+(f&&f.scrollLeft||g&&g.scrollLeft||0)-(f&&f.clientLeft||g&&g.clientLeft||0),a.pageY=d.clientY+(f&&f.scrollTop||g&&g.scrollTop||0)-(f&&f.clientTop||g&&g.clientTop||0)),!a.relatedTarget&&i&&(a.relatedTarget=i===a.target?d.toElement:i),!a.which&&h!==b&&(a.which=h&1?1:h&2?3:h&4?2:0),a}},fix:function(a){if(a[f.expando])return a;var d,e,g=a,h=f.event.fixHooks[a.type]||{},i=h.props?this.props.concat(h.props):this.props;a=f.Event(g);for(d=i.length;d;)e=i[--d],a[e]=g[e];return a.target||(a.target=g.srcElement||c),a.target.nodeType===3&&(a.target=a.target.parentNode),a.metaKey===b&&(a.metaKey=a.ctrlKey),h.filter?h.filter(a,g):a},special:{ready:{setup:f.bindReady},load:{noBubble:!0},focus:{delegateType:"focusin"},blur:{delegateType:"focusout"},beforeunload:{setup:function(a,b,c){f.isWindow(this)&&(this.onbeforeunload=c)},teardown:function(a,b){this.onbeforeunload===b&&(this.onbeforeunload=null)}}},simulate:function(a,b,c,d){var e=f.extend(new f.Event,c,{type:a,isSimulated:!0,originalEvent:{}});d?f.event.trigger(e,null,b):f.event.dispatch.call(b,e),e.isDefaultPrevented()&&c.preventDefault()}},f.event.handle=f.event.dispatch,f.removeEvent=c.removeEventListener?function(a,b,c){a.removeEventListener&&a.removeEventListener(b,c,!1)}:function(a,b,c){a.detachEvent&&a.detachEvent("on"+b,c)},f.Event=function(a,b){if(!(this instanceof f.Event))return new f.Event(a,b);a&&a.type?(this.originalEvent=a,this.type=a.type,this.isDefaultPrevented=a.defaultPrevented||a.returnValue===!1||a.getPreventDefault&&a.getPreventDefault()?K:J):this.type=a,b&&f.extend(this,b),this.timeStamp=a&&a.timeStamp||f.now(),this[f.expando]=!0},f.Event.prototype={preventDefault:function(){this.isDefaultPrevented=K;var a=this.originalEvent;if(!a)return;a.preventDefault?a.preventDefault():a.returnValue=!1},stopPropagation:function(){this.isPropagationStopped=K;var a=this.originalEvent;if(!a)return;a.stopPropagation&&a.stopPropagation(),a.cancelBubble=!0},stopImmediatePropagation:function(){this.isImmediatePropagationStopped=K,this.stopPropagation()},isDefaultPrevented:J,isPropagationStopped:J,isImmediatePropagationStopped:J},f.each({mouseenter:"mouseover",mouseleave:"mouseout"},function(a,b){f.event.special[a]={delegateType:b,bindType:b,handle:function(a){var c=this,d=a.relatedTarget,e=a.handleObj,g=e.selector,h;if(!d||d!==c&&!f.contains(c,d))a.type=e.origType,h=e.handler.apply(this,arguments),a.type=b;return h}}}),f.support.submitBubbles||(f.event.special.submit={setup:function(){if(f.nodeName(this,"form"))return!1;f.event.add(this,"click._submit keypress._submit",function(a){var c=a.target,d=f.nodeName(c,"input")||f.nodeName(c,"button")?c.form:b;d&&!d._submit_attached&&(f.event.add(d,"submit._submit",function(a){a._submit_bubble=!0}),d._submit_attached=!0)})},postDispatch:function(a){a._submit_bubble&&(delete a._submit_bubble,this.parentNode&&!a.isTrigger&&f.event.simulate("submit",this.parentNode,a,!0))},teardown:function(){if(f.nodeName(this,"form"))return!1;f.event.remove(this,"._submit")}}),f.support.changeBubbles||(f.event.special.change={setup:function(){if(z.test(this.nodeName)){if(this.type==="checkbox"||this.type==="radio")f.event.add(this,"propertychange._change",function(a){a.originalEvent.propertyName==="checked"&&(this._just_changed=!0)}),f.event.add(this,"click._change",function(a){this._just_changed&&!a.isTrigger&&(this._just_changed=!1,f.event.simulate("change",this,a,!0))});return!1}f.event.add(this,"beforeactivate._change",function(a){var b=a.target;z.test(b.nodeName)&&!b._change_attached&&(f.event.add(b,"change._change",function(a){this.parentNode&&!a.isSimulated&&!a.isTrigger&&f.event.simulate("change",this.parentNode,a,!0)}),b._change_attached=!0)})},handle:function(a){var b=a.target;if(this!==b||a.isSimulated||a.isTrigger||b.type!=="radio"&&b.type!=="checkbox")return a.handleObj.handler.apply(this,arguments)},teardown:function(){return f.event.remove(this,"._change"),z.test(this.nodeName)}}),f.support.focusinBubbles||f.each({focus:"focusin",blur:"focusout"},function(a,b){var d=0,e=function(a){f.event.simulate(b,a.target,f.event.fix(a),!0)};f.event.special[b]={setup:function(){d++===0&&c.addEventListener(a,e,!0)},teardown:function(){--d===0&&c.removeEventListener(a,e,!0)}}}),f.fn.extend({on:function(a,c,d,e,g){var h,i;if(typeof a=="object"){typeof c!="string"&&(d=d||c,c=b);for(i in a)this.on(i,c,d,a[i],g);return this}d==null&&e==null?(e=c,d=c=b):e==null&&(typeof c=="string"?(e=d,d=b):(e=d,d=c,c=b));if(e===!1)e=J;else if(!e)return this;return g===1&&(h=e,e=function(a){return f().off(a),h.apply(this,arguments)},e.guid=h.guid||(h.guid=f.guid++)),this.each(function(){f.event.add(this,a,e,d,c)})},one:function(a,b,c,d){return this.on(a,b,c,d,1)},off:function(a,c,d){if(a&&a.preventDefault&&a.handleObj){var e=a.handleObj;return f(a.delegateTarget).off(e.namespace?e.origType+"."+e.namespace:e.origType,e.selector,e.handler),this}if(typeof a=="object"){for(var g in a)this.off(g,c,a[g]);return this}if(c===!1||typeof c=="function")d=c,c=b;return d===!1&&(d=J),this.each(function(){f.event.remove(this,a,d,c)})},bind:function(a,b,c){return this.on(a,null,b,c)},unbind:function(a,b){return this.off(a,null,b)},live:function(a,b,c){return f(this.context).on(a,this.selector,b,c),this},die:function(a,b){return f(this.context).off(a,this.selector||"**",b),this},delegate:function(a,b,c,d){return this.on(b,a,c,d)},undelegate:function(a,b,c){return arguments.length==1?this.off(a,"**"):this.off(b,a,c)},trigger:function(a,b){return this.each(function(){f.event.trigger(a,b,this)})},triggerHandler:function(a,b){if(this[0])return f.event.trigger(a,b,this[0],!0)},toggle:function(a){var b=arguments,c=a.guid||f.guid++,d=0,e=function(c){var e=(f._data(this,"lastToggle"+a.guid)||0)%d;return f._data(this,"lastToggle"+a.guid,e+1),c.preventDefault(),b[e].apply(this,arguments)||!1};e.guid=c;while(d<b.length)b[d++].guid=c;return this.click(e)},hover:function(a,b){return this.mouseenter(a).mouseleave(b||a)}}),f.each("blur focus focusin focusout load resize scroll unload click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup error contextmenu".split(" "),function(a,b){f.fn[b]=function(a,c){return c==null&&(c=a,a=null),arguments.length>0?this.on(b,null,a,c):this.trigger(b)},f.attrFn&&(f.attrFn[b]=!0),C.test(b)&&(f.event.fixHooks[b]=f.event.keyHooks),D.test(b)&&(f.event.fixHooks[b]=f.event.mouseHooks)}),function(){function w(a,b,c,e,f,g){for(var h=0,i=e.length;h<i;h++){var j=e[h];if(j){var k=!1;j=j[a];while(j){if(j[d]===c){k=e[j.sizset];break}j.nodeType===1&&!g&&(j[d]=c,j.sizset=h);if(j.nodeName.toLowerCase()===b){k=j;break}j=j[a]}e[h]=k}}}function x(a,b,c,e,f,g){for(var h=0,i=e.length;h<i;h++){var j=e[h];if(j){var k=!1;j=j[a];while(j){if(j[d]===c){k=e[j.sizset];break}if(j.nodeType===1){g||(j[d]=c,j.sizset=h);if(typeof b!="string"){if(j===b){k=!0;break}}else if(m.filter(b,[j]).length>0){k=j;break}}j=j[a]}e[h]=k}}}var a=/((?:\((?:\([^()]+\)|[^()]+)+\)|\[(?:\[[^\[\]]*\]|['"][^'"]*['"]|[^\[\]'"]+)+\]|\\.|[^ >+~,(\[\\]+)+|[>+~])(\s*,\s*)?((?:.|\r|\n)*)/g,d="sizcache"+(Math.random()+"").replace(".",""),e=0,g=Object.prototype.toString,h=!1,i=!0,j=/\\/g,k=/\r\n/g,l=/\W/;[0,0].sort(function(){return i=!1,0});var m=function(b,d,e,f){e=e||[],d=d||c;var h=d;if(d.nodeType!==1&&d.nodeType!==9)return[];if(!b||typeof b!="string")return e;var i,j,k,l,n,q,r,t,u=!0,v=m.isXML(d),w=[],x=b;do{a.exec(""),i=a.exec(x);if(i){x=i[3],w.push(i[1]);if(i[2]){l=i[3];break}}}while(i);if(w.length>1&&p.exec(b))if(w.length===2&&o.relative[w[0]])j=y(w[0]+w[1],d,f);else{j=o.relative[w[0]]?[d]:m(w.shift(),d);while(w.length)b=w.shift(),o.relative[b]&&(b+=w.shift()),j=y(b,j,f)}else{!f&&w.length>1&&d.nodeType===9&&!v&&o.match.ID.test(w[0])&&!o.match.ID.test(w[w.length-1])&&(n=m.find(w.shift(),d,v),d=n.expr?m.filter(n.expr,n.set)[0]:n.set[0]);if(d){n=f?{expr:w.pop(),set:s(f)}:m.find(w.pop(),w.length!==1||w[0]!=="~"&&w[0]!=="+"||!d.parentNode?d:d.parentNode,v),j=n.expr?m.filter(n.expr,n.set):n.set,w.length>0?k=s(j):u=!1;while(w.length)q=w.pop(),r=q,o.relative[q]?r=w.pop():q="",r==null&&(r=d),o.relative[q](k,r,v)}else k=w=[]}k||(k=j),k||m.error(q||b);if(g.call(k)==="[object Array]")if(!u)e.push.apply(e,k);else if(d&&d.nodeType===1)for(t=0;k[t]!=null;t++)k[t]&&(k[t]===!0||k[t].nodeType===1&&m.contains(d,k[t]))&&e.push(j[t]);else for(t=0;k[t]!=null;t++)k[t]&&k[t].nodeType===1&&e.push(j[t]);else s(k,e);return l&&(m(l,h,e,f),m.uniqueSort(e)),e};m.uniqueSort=function(a){if(u){h=i,a.sort(u);if(h)for(var b=1;b<a.length;b++)a[b]===a[b-1]&&a.splice(b--,1)}return a},m.matches=function(a,b){return m(a,null,null,b)},m.matchesSelector=function(a,b){return m(b,null,null,[a]).length>0},m.find=function(a,b,c){var d,e,f,g,h,i;if(!a)return[];for(e=0,f=o.order.length;e<f;e++){h=o.order[e];if(g=o.leftMatch[h].exec(a)){i=g[1],g.splice(1,1);if(i.substr(i.length-1)!=="\\"){g[1]=(g[1]||"").replace(j,""),d=o.find[h](g,b,c);if(d!=null){a=a.replace(o.match[h],"");break}}}}return d||(d=typeof b.getElementsByTagName!="undefined"?b.getElementsByTagName("*"):[]),{set:d,expr:a}},m.filter=function(a,c,d,e){var f,g,h,i,j,k,l,n,p,q=a,r=[],s=c,t=c&&c[0]&&m.isXML(c[0]);while(a&&c.length){for(h in o.filter)if((f=o.leftMatch[h].exec(a))!=null&&f[2]){k=o.filter[h],l=f[1],g=!1,f.splice(1,1);if(l.substr(l.length-1)==="\\")continue;s===r&&(r=[]);if(o.preFilter[h]){f=o.preFilter[h](f,s,d,r,e,t);if(!f)g=i=!0;else if(f===!0)continue}if(f)for(n=0;(j=s[n])!=null;n++)j&&(i=k(j,f,n,s),p=e^i,d&&i!=null?p?g=!0:s[n]=!1:p&&(r.push(j),g=!0));if(i!==b){d||(s=r),a=a.replace(o.match[h],"");if(!g)return[];break}}if(a===q){if(g!=null)break;m.error(a)}q=a}return s},m.error=function(a){throw new Error("Syntax error, unrecognized expression: "+a)};var n=m.getText=function(a){var b,c,d=a.nodeType,e="";if(d){if(d===1||d===9||d===11){if(typeof a.textContent=="string")return a.textContent;if(typeof a.innerText=="string")return a.innerText.replace(k,"");for(a=a.firstChild;a;a=a.nextSibling)e+=n(a)}else if(d===3||d===4)return a.nodeValue}else for(b=0;c=a[b];b++)c.nodeType!==8&&(e+=n(c));return e},o=m.selectors={order:["ID","NAME","TAG"],match:{ID:/#((?:[\w\u00c0-\uFFFF\-]|\\.)+)/,CLASS:/\.((?:[\w\u00c0-\uFFFF\-]|\\.)+)/,NAME:/\[name=['"]*((?:[\w\u00c0-\uFFFF\-]|\\.)+)['"]*\]/,ATTR:/\[\s*((?:[\w\u00c0-\uFFFF\-]|\\.)+)\s*(?:(\S?=)\s*(?:(['"])(.*?)\3|(#?(?:[\w\u00c0-\uFFFF\-]|\\.)*)|)|)\s*\]/,TAG:/^((?:[\w\u00c0-\uFFFF\*\-]|\\.)+)/,CHILD:/:(only|nth|last|first)-child(?:\(\s*(even|odd|(?:[+\-]?\d+|(?:[+\-]?\d*)?n\s*(?:[+\-]\s*\d+)?))\s*\))?/,POS:/:(nth|eq|gt|lt|first|last|even|odd)(?:\((\d*)\))?(?=[^\-]|$)/,PSEUDO:/:((?:[\w\u00c0-\uFFFF\-]|\\.)+)(?:\((['"]?)((?:\([^\)]+\)|[^\(\)]*)+)\2\))?/},leftMatch:{},attrMap:{"class":"className","for":"htmlFor"},attrHandle:{href:function(a){return a.getAttribute("href")},type:function(a){return a.getAttribute("type")}},relative:{"+":function(a,b){var c=typeof b=="string",d=c&&!l.test(b),e=c&&!d;d&&(b=b.toLowerCase());for(var f=0,g=a.length,h;f<g;f++)if(h=a[f]){while((h=h.previousSibling)&&h.nodeType!==1);a[f]=e||h&&h.nodeName.toLowerCase()===b?h||!1:h===b}e&&m.filter(b,a,!0)},">":function(a,b){var c,d=typeof b=="string",e=0,f=a.length;if(d&&!l.test(b)){b=b.toLowerCase();for(;e<f;e++){c=a[e];if(c){var g=c.parentNode;a[e]=g.nodeName.toLowerCase()===b?g:!1}}}else{for(;e<f;e++)c=a[e],c&&(a[e]=d?c.parentNode:c.parentNode===b);d&&m.filter(b,a,!0)}},"":function(a,b,c){var d,f=e++,g=x;typeof b=="string"&&!l.test(b)&&(b=b.toLowerCase(),d=b,g=w),g("parentNode",b,f,a,d,c)},"~":function(a,b,c){var d,f=e++,g=x;typeof b=="string"&&!l.test(b)&&(b=b.toLowerCase(),d=b,g=w),g("previousSibling",b,f,a,d,c)}},find:{ID:function(a,b,c){if(typeof b.getElementById!="undefined"&&!c){var d=b.getElementById(a[1]);return d&&d.parentNode?[d]:[]}},NAME:function(a,b){if(typeof b.getElementsByName!="undefined"){var c=[],d=b.getElementsByName(a[1]);for(var e=0,f=d.length;e<f;e++)d[e].getAttribute("name")===a[1]&&c.push(d[e]);return c.length===0?null:c}},TAG:function(a,b){if(typeof b.getElementsByTagName!="undefined")return b.getElementsByTagName(a[1])}},preFilter:{CLASS:function(a,b,c,d,e,f){a=" "+a[1].replace(j,"")+" ";if(f)return a;for(var g=0,h;(h=b[g])!=null;g++)h&&(e^(h.className&&(" "+h.className+" ").replace(/[\t\n\r]/g," ").indexOf(a)>=0)?c||d.push(h):c&&(b[g]=!1));return!1},ID:function(a){return a[1].replace(j,"")},TAG:function(a,b){return a[1].replace(j,"").toLowerCase()},CHILD:function(a){if(a[1]==="nth"){a[2]||m.error(a[0]),a[2]=a[2].replace(/^\+|\s*/g,"");var b=/(-?)(\d*)(?:n([+\-]?\d*))?/.exec(a[2]==="even"&&"2n"||a[2]==="odd"&&"2n+1"||!/\D/.test(a[2])&&"0n+"+a[2]||a[2]);a[2]=b[1]+(b[2]||1)-0,a[3]=b[3]-0}else a[2]&&m.error(a[0]);return a[0]=e++,a},ATTR:function(a,b,c,d,e,f){var g=a[1]=a[1].replace(j,"");return!f&&o.attrMap[g]&&(a[1]=o.attrMap[g]),a[4]=(a[4]||a[5]||"").replace(j,""),a[2]==="~="&&(a[4]=" "+a[4]+" "),a},PSEUDO:function(b,c,d,e,f){if(b[1]==="not"){if(!((a.exec(b[3])||"").length>1||/^\w/.test(b[3]))){var g=m.filter(b[3],c,d,!0^f);return d||e.push.apply(e,g),!1}b[3]=m(b[3],null,null,c)}else if(o.match.POS.test(b[0])||o.match.CHILD.test(b[0]))return!0;return b},POS:function(a){return a.unshift(!0),a}},filters:{enabled:function(a){return a.disabled===!1&&a.type!=="hidden"},disabled:function(a){return a.disabled===!0},checked:function(a){return a.checked===!0},selected:function(a){return a.parentNode&&a.parentNode.selectedIndex,a.selected===!0},parent:function(a){return!!a.firstChild},empty:function(a){return!a.firstChild},has:function(a,b,c){return!!m(c[3],a).length},header:function(a){return/h\d/i.test(a.nodeName)},text:function(a){var b=a.getAttribute("type"),c=a.type;return a.nodeName.toLowerCase()==="input"&&"text"===c&&(b===c||b===null)},radio:function(a){return a.nodeName.toLowerCase()==="input"&&"radio"===a.type},checkbox:function(a){return a.nodeName.toLowerCase()==="input"&&"checkbox"===a.type},file:function(a){return a.nodeName.toLowerCase()==="input"&&"file"===a.type},password:function(a){return a.nodeName.toLowerCase()==="input"&&"password"===a.type},submit:function(a){var b=a.nodeName.toLowerCase();return(b==="input"||b==="button")&&"submit"===a.type},image:function(a){return a.nodeName.toLowerCase()==="input"&&"image"===a.type},reset:function(a){var b=a.nodeName.toLowerCase();return(b==="input"||b==="button")&&"reset"===a.type},button:function(a){var b=a.nodeName.toLowerCase();return b==="input"&&"button"===a.type||b==="button"},input:function(a){return/input|select|textarea|button/i.test(a.nodeName)},focus:function(a){return a===a.ownerDocument.activeElement}},setFilters:{first:function(a,b){return b===0},last:function(a,b,c,d){return b===d.length-1},even:function(a,b){return b%2===0},odd:function(a,b){return b%2===1},lt:function(a,b,c){return b<c[3]-0},gt:function(a,b,c){return b>c[3]-0},nth:function(a,b,c){return c[3]-0===b},eq:function(a,b,c){return c[3]-0===b}},filter:{PSEUDO:function(a,b,c,d){var e=b[1],f=o.filters[e];if(f)return f(a,c,b,d);if(e==="contains")return(a.textContent||a.innerText||n([a])||"").indexOf(b[3])>=0;if(e==="not"){var g=b[3];for(var h=0,i=g.length;h<i;h++)if(g[h]===a)return!1;return!0}m.error(e)},CHILD:function(a,b){var c,e,f,g,h,i,j,k=b[1],l=a;switch(k){case"only":case"first":while(l=l.previousSibling)if(l.nodeType===1)return!1;if(k==="first")return!0;l=a;case"last":while(l=l.nextSibling)if(l.nodeType===1)return!1;return!0;case"nth":c=b[2],e=b[3];if(c===1&&e===0)return!0;f=b[0],g=a.parentNode;if(g&&(g[d]!==f||!a.nodeIndex)){i=0;for(l=g.firstChild;l;l=l.nextSibling)l.nodeType===1&&(l.nodeIndex=++i);g[d]=f}return j=a.nodeIndex-e,c===0?j===0:j%c===0&&j/c>=0}},ID:function(a,b){return a.nodeType===1&&a.getAttribute("id")===b},TAG:function(a,b){return b==="*"&&a.nodeType===1||!!a.nodeName&&a.nodeName.toLowerCase()===b},CLASS:function(a,b){return(" "+(a.className||a.getAttribute("class"))+" ").indexOf(b)>-1},ATTR:function(a,b){var c=b[1],d=m.attr?m.attr(a,c):o.attrHandle[c]?o.attrHandle[c](a):a[c]!=null?a[c]:a.getAttribute(c),e=d+"",f=b[2],g=b[4];return d==null?f==="!=":!f&&m.attr?d!=null:f==="="?e===g:f==="*="?e.indexOf(g)>=0:f==="~="?(" "+e+" ").indexOf(g)>=0:g?f==="!="?e!==g:f==="^="?e.indexOf(g)===0:f==="$="?e.substr(e.length-g.length)===g:f==="|="?e===g||e.substr(0,g.length+1)===g+"-":!1:e&&d!==!1},POS:function(a,b,c,d){var e=b[2],f=o.setFilters[e];if(f)return f(a,c,b,d)}}},p=o.match.POS,q=function(a,b){return"\\"+(b-0+1)};for(var r in o.match)o.match[r]=new RegExp(o.match[r].source+/(?![^\[]*\])(?![^\(]*\))/.source),o.leftMatch[r]=new RegExp(/(^(?:.|\r|\n)*?)/.source+o.match[r].source.replace(/\\(\d+)/g,q));o.match.globalPOS=p;var s=function(a,b){return a=Array.prototype.slice.call(a,0),b?(b.push.apply(b,a),b):a};try{Array.prototype.slice.call(c.documentElement.childNodes,0)[0].nodeType}catch(t){s=function(a,b){var c=0,d=b||[];if(g.call(a)==="[object Array]")Array.prototype.push.apply(d,a);else if(typeof a.length=="number")for(var e=a.length;c<e;c++)d.push(a[c]);else for(;a[c];c++)d.push(a[c]);return d}}var u,v;c.documentElement.compareDocumentPosition?u=function(a,b){return a===b?(h=!0,0):!a.compareDocumentPosition||!b.compareDocumentPosition?a.compareDocumentPosition?-1:1:a.compareDocumentPosition(b)&4?-1:1}:(u=function(a,b){if(a===b)return h=!0,0;if(a.sourceIndex&&b.sourceIndex)return a.sourceIndex-b.sourceIndex;var c,d,e=[],f=[],g=a.parentNode,i=b.parentNode,j=g;if(g===i)return v(a,b);if(!g)return-1;if(!i)return 1;while(j)e.unshift(j),j=j.parentNode;j=i;while(j)f.unshift(j),j=j.parentNode;c=e.length,d=f.length;for(var k=0;k<c&&k<d;k++)if(e[k]!==f[k])return v(e[k],f[k]);return k===c?v(a,f[k],-1):v(e[k],b,1)},v=function(a,b,c){if(a===b)return c;var d=a.nextSibling;while(d){if(d===b)return-1;d=d.nextSibling}return 1}),function(){var a=c.createElement("div"),d="script"+(new Date).getTime(),e=c.documentElement;a.innerHTML="<a name='"+d+"'/>",e.insertBefore(a,e.firstChild),c.getElementById(d)&&(o.find.ID=function(a,c,d){if(typeof c.getElementById!="undefined"&&!d){var e=c.getElementById(a[1]);return e?e.id===a[1]||typeof e.getAttributeNode!="undefined"&&e.getAttributeNode("id").nodeValue===a[1]?[e]:b:[]}},o.filter.ID=function(a,b){var c=typeof a.getAttributeNode!="undefined"&&a.getAttributeNode("id");return a.nodeType===1&&c&&c.nodeValue===b}),e.removeChild(a),e=a=null}(),function(){var a=c.createElement("div");a.appendChild(c.createComment("")),a.getElementsByTagName("*").length>0&&(o.find.TAG=function(a,b){var c=b.getElementsByTagName(a[1]);if(a[1]==="*"){var d=[];for(var e=0;c[e];e++)c[e].nodeType===1&&d.push(c[e]);c=d}return c}),a.innerHTML="<a href='#'></a>",a.firstChild&&typeof a.firstChild.getAttribute!="undefined"&&a.firstChild.getAttribute("href")!=="#"&&(o.attrHandle.href=function(a){return a.getAttribute("href",2)}),a=null}(),c.querySelectorAll&&function(){var a=m,b=c.createElement("div"),d="__sizzle__";b.innerHTML="<p class='TEST'></p>";if(b.querySelectorAll&&b.querySelectorAll(".TEST").length===0)return;m=function(b,e,f,g){e=e||c;if(!g&&!m.isXML(e)){var h=/^(\w+$)|^\.([\w\-]+$)|^#([\w\-]+$)/.exec(b);if(h&&(e.nodeType===1||e.nodeType===9)){if(h[1])return s(e.getElementsByTagName(b),f);if(h[2]&&o.find.CLASS&&e.getElementsByClassName)return s(e.getElementsByClassName(h[2]),f)}if(e.nodeType===9){if(b==="body"&&e.body)return s([e.body],f);if(h&&h[3]){var i=e.getElementById(h[3]);if(!i||!i.parentNode)return s([],f);if(i.id===h[3])return s([i],f)}try{return s(e.querySelectorAll(b),f)}catch(j){}}else if(e.nodeType===1&&e.nodeName.toLowerCase()!=="object"){var k=e,l=e.getAttribute("id"),n=l||d,p=e.parentNode,q=/^\s*[+~]/.test(b);l?n=n.replace(/'/g,"\\$&"):e.setAttribute("id",n),q&&p&&(e=e.parentNode);try{if(!q||p)return s(e.querySelectorAll("[id='"+n+"'] "+b),f)}catch(r){}finally{l||k.removeAttribute("id")}}}return a(b,e,f,g)};for(var e in a)m[e]=a[e];b=null}(),function(){var a=c.documentElement,b=a.matchesSelector||a.mozMatchesSelector||a.webkitMatchesSelector||a.msMatchesSelector;if(b){var d=!b.call(c.createElement("div"),"div"),e=!1;try{b.call(c.documentElement,"[test!='']:sizzle")}catch(f){e=!0}m.matchesSelector=function(a,c){c=c.replace(/\=\s*([^'"\]]*)\s*\]/g,"='$1']");if(!m.isXML(a))try{if(e||!o.match.PSEUDO.test(c)&&!/!=/.test(c)){var f=b.call(a,c);if(f||!d||a.document&&a.document.nodeType!==11)return f}}catch(g){}return m(c,null,null,[a]).length>0}}}(),function(){var a=c.createElement("div");a.innerHTML="<div class='test e'></div><div class='test'></div>";if(!a.getElementsByClassName||a.getElementsByClassName("e").length===0)return;a.lastChild.className="e";if(a.getElementsByClassName("e").length===1)return;o.order.splice(1,0,"CLASS"),o.find.CLASS=function(a,b,c){if(typeof b.getElementsByClassName!="undefined"&&!c)return b.getElementsByClassName(a[1])},a=null}(),c.documentElement.contains?m.contains=function(a,b){return a!==b&&(a.contains?a.contains(b):!0)}:c.documentElement.compareDocumentPosition?m.contains=function(a,b){return!!(a.compareDocumentPosition(b)&16)}:m.contains=function(){return!1},m.isXML=function(a){var b=(a?a.ownerDocument||a:0).documentElement;return b?b.nodeName!=="HTML":!1};var y=function(a,b,c){var d,e=[],f="",g=b.nodeType?[b]:b;while(d=o.match.PSEUDO.exec(a))f+=d[0],a=a.replace(o.match.PSEUDO,"");a=o.relative[a]?a+"*":a;for(var h=0,i=g.length;h<i;h++)m(a,g[h],e,c);return m.filter(f,e)};m.attr=f.attr,m.selectors.attrMap={},f.find=m,f.expr=m.selectors,f.expr[":"]=f.expr.filters,f.unique=m.uniqueSort,f.text=m.getText,f.isXMLDoc=m.isXML,f.contains=m.contains}();var L=/Until$/,M=/^(?:parents|prevUntil|prevAll)/,N=/,/,O=/^.[^:#\[\.,]*$/,P=Array.prototype.slice,Q=f.expr.match.globalPOS,R={children:!0,contents:!0,next:!0,prev:!0};f.fn.extend({find:function(a){var b=this,c,d;if(typeof a!="string")return f(a).filter(function(){for(c=0,d=b.length;c<d;c++)if(f.contains(b[c],this))return!0});var e=this.pushStack("","find",a),g,h,i;for(c=0,d=this.length;c<d;c++){g=e.length,f.find(a,this[c],e);if(c>0)for(h=g;h<e.length;h++)for(i=0;i<g;i++)if(e[i]===e[h]){e.splice(h--,1);break}}return e},has:function(a){var b=f(a);return this.filter(function(){for(var a=0,c=b.length;a<c;a++)if(f.contains(this,b[a]))return!0})},not:function(a){return this.pushStack(T(this,a,!1),"not",a)},filter:function(a){return this.pushStack(T(this,a,!0),"filter",a)},is:function(a){return!!a&&(typeof a=="string"?Q.test(a)?f(a,this.context).index(this[0])>=0:f.filter(a,this).length>0:this.filter(a).length>0)},closest:function(a,b){var c=[],d,e,g=this[0];if(f.isArray(a)){var h=1;while(g&&g.ownerDocument&&g!==b){for(d=0;d<a.length;d++)f(g).is(a[d])&&c.push({selector:a[d],elem:g,level:h});g=g.parentNode,h++}return c}var i=Q.test(a)||typeof a!="string"?f(a,b||this.context):0;for(d=0,e=this.length;d<e;d++){g=this[d];while(g){if(i?i.index(g)>-1:f.find.matchesSelector(g,a)){c.push(g);break}g=g.parentNode;if(!g||!g.ownerDocument||g===b||g.nodeType===11)break}}return c=c.length>1?f.unique(c):c,this.pushStack(c,"closest",a)},index:function(a){return a?typeof a=="string"?f.inArray(this[0],f(a)):f.inArray(a.jquery?a[0]:a,this):this[0]&&this[0].parentNode?this.prevAll().length:-1},add:function(a,b){var c=typeof a=="string"?f(a,b):f.makeArray(a&&a.nodeType?[a]:a),d=f.merge(this.get(),c);return this.pushStack(S(c[0])||S(d[0])?d:f.unique(d))},andSelf:function(){return this.add(this.prevObject)}}),f.each({parent:function(a){var b=a.parentNode;return b&&b.nodeType!==11?b:null},parents:function(a){return f.dir(a,"parentNode")},parentsUntil:function(a,b,c){return f.dir(a,"parentNode",c)},next:function(a){return f.nth(a,2,"nextSibling")},prev:function(a){return f.nth(a,2,"previousSibling")},nextAll:function(a){return f.dir(a,"nextSibling")},prevAll:function(a){return f.dir(a,"previousSibling")},nextUntil:function(a,b,c){return f.dir(a,"nextSibling",c)},prevUntil:function(a,b,c){return f.dir(a,"previousSibling",c)},siblings:function(a){return f.sibling((a.parentNode||{}).firstChild,a)},children:function(a){return f.sibling(a.firstChild)},contents:function(a){return f.nodeName(a,"iframe")?a.contentDocument||a.contentWindow.document:f.makeArray(a.childNodes)}},function(a,b){f.fn[a]=function(c,d){var e=f.map(this,b,c);return L.test(a)||(d=c),d&&typeof d=="string"&&(e=f.filter(d,e)),e=this.length>1&&!R[a]?f.unique(e):e,(this.length>1||N.test(d))&&M.test(a)&&(e=e.reverse()),this.pushStack(e,a,P.call(arguments).join(","))}}),f.extend({filter:function(a,b,c){return c&&(a=":not("+a+")"),b.length===1?f.find.matchesSelector(b[0],a)?[b[0]]:[]:f.find.matches(a,b)},dir:function(a,c,d){var e=[],g=a[c];while(g&&g.nodeType!==9&&(d===b||g.nodeType!==1||!f(g).is(d)))g.nodeType===1&&e.push(g),g=g[c];return e},nth:function(a,b,c,d){b=b||1;var e=0;for(;a;a=a[c])if(a.nodeType===1&&++e===b)break;return a},sibling:function(a,b){var c=[];for(;a;a=a.nextSibling)a.nodeType===1&&a!==b&&c.push(a);return c}});var V="abbr|article|aside|audio|bdi|canvas|data|datalist|details|figcaption|figure|footer|header|hgroup|mark|meter|nav|output|progress|section|summary|time|video",W=/ jQuery\d+="(?:\d+|null)"/g,X=/^\s+/,Y=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/ig,Z=/<([\w:]+)/,$=/<tbody/i,_=/<|&#?\w+;/,ab=/<(?:script|style)/i,bb=/<(?:script|object|embed|option|style)/i,cb=new RegExp("<(?:"+V+")[\\s/>]","i"),db=/checked\s*(?:[^=]|=\s*.checked.)/i,eb=/\/(java|ecma)script/i,fb=/^\s*<!(?:\[CDATA\[|\-\-)/,gb={option:[1,"<select multiple='multiple'>","</select>"],legend:[1,"<fieldset>","</fieldset>"],thead:[1,"<table>","</table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],col:[2,"<table><tbody></tbody><colgroup>","</colgroup></table>"],area:[1,"<map>","</map>"],_default:[0,"",""]},hb=U(c);gb.optgroup=gb.option,gb.tbody=gb.tfoot=gb.colgroup=gb.caption=gb.thead,gb.th=gb.td,f.support.htmlSerialize||(gb._default=[1,"div<div>","</div>"]),f.fn.extend({text:function(a){return f.access(this,function(a){return a===b?f.text(this):this.empty().append((this[0]&&this[0].ownerDocument||c).createTextNode(a))},null,a,arguments.length)},wrapAll:function(a){if(f.isFunction(a))return this.each(function(b){f(this).wrapAll(a.call(this,b))});if(this[0]){var b=f(a,this[0].ownerDocument).eq(0).clone(!0);this[0].parentNode&&b.insertBefore(this[0]),b.map(function(){var a=this;while(a.firstChild&&a.firstChild.nodeType===1)a=a.firstChild;return a}).append(this)}return this},wrapInner:function(a){return f.isFunction(a)?this.each(function(b){f(this).wrapInner(a.call(this,b))}):this.each(function(){var b=f(this),c=b.contents();c.length?c.wrapAll(a):b.append(a)})},wrap:function(a){var b=f.isFunction(a);return this.each(function(c){f(this).wrapAll(b?a.call(this,c):a)})},unwrap:function(){return this.parent().each(function(){f.nodeName(this,"body")||f(this).replaceWith(this.childNodes)}).end()},append:function(){return this.domManip(arguments,!0,function(a){this.nodeType===1&&this.appendChild(a)})},prepend:function(){return this.domManip(arguments,!0,function(a){this.nodeType===1&&this.insertBefore(a,this.firstChild)})},before:function(){if(this[0]&&this[0].parentNode)return this.domManip(arguments,!1,function(a){this.parentNode.insertBefore(a,this)});if(arguments.length){var a=f.clean(arguments);return a.push.apply(a,this.toArray()),this
|
20
|
+
.pushStack(a,"before",arguments)}},after:function(){if(this[0]&&this[0].parentNode)return this.domManip(arguments,!1,function(a){this.parentNode.insertBefore(a,this.nextSibling)});if(arguments.length){var a=this.pushStack(this,"after",arguments);return a.push.apply(a,f.clean(arguments)),a}},remove:function(a,b){for(var c=0,d;(d=this[c])!=null;c++)if(!a||f.filter(a,[d]).length)!b&&d.nodeType===1&&(f.cleanData(d.getElementsByTagName("*")),f.cleanData([d])),d.parentNode&&d.parentNode.removeChild(d);return this},empty:function(){for(var a=0,b;(b=this[a])!=null;a++){b.nodeType===1&&f.cleanData(b.getElementsByTagName("*"));while(b.firstChild)b.removeChild(b.firstChild)}return this},clone:function(a,b){return a=a==null?!1:a,b=b==null?a:b,this.map(function(){return f.clone(this,a,b)})},html:function(a){return f.access(this,function(a){var c=this[0]||{},d=0,e=this.length;if(a===b)return c.nodeType===1?c.innerHTML.replace(W,""):null;if(typeof a=="string"&&!ab.test(a)&&(f.support.leadingWhitespace||!X.test(a))&&!gb[(Z.exec(a)||["",""])[1].toLowerCase()]){a=a.replace(Y,"<$1></$2>");try{for(;d<e;d++)c=this[d]||{},c.nodeType===1&&(f.cleanData(c.getElementsByTagName("*")),c.innerHTML=a);c=0}catch(g){}}c&&this.empty().append(a)},null,a,arguments.length)},replaceWith:function(a){return this[0]&&this[0].parentNode?f.isFunction(a)?this.each(function(b){var c=f(this),d=c.html();c.replaceWith(a.call(this,b,d))}):(typeof a!="string"&&(a=f(a).detach()),this.each(function(){var b=this.nextSibling,c=this.parentNode;f(this).remove(),b?f(b).before(a):f(c).append(a)})):this.length?this.pushStack(f(f.isFunction(a)?a():a),"replaceWith",a):this},detach:function(a){return this.remove(a,!0)},domManip:function(a,c,d){var e,g,h,i,j=a[0],k=[];if(!f.support.checkClone&&arguments.length===3&&typeof j=="string"&&db.test(j))return this.each(function(){f(this).domManip(a,c,d,!0)});if(f.isFunction(j))return this.each(function(e){var g=f(this);a[0]=j.call(this,e,c?g.html():b),g.domManip(a,c,d)});if(this[0]){i=j&&j.parentNode,f.support.parentNode&&i&&i.nodeType===11&&i.childNodes.length===this.length?e={fragment:i}:e=f.buildFragment(a,this,k),h=e.fragment,h.childNodes.length===1?g=h=h.firstChild:g=h.firstChild;if(g){c=c&&f.nodeName(g,"tr");for(var l=0,m=this.length,n=m-1;l<m;l++)d.call(c?ib(this[l],g):this[l],e.cacheable||m>1&&l<n?f.clone(h,!0,!0):h)}k.length&&f.each(k,function(a,b){b.src?f.ajax({type:"GET",global:!1,url:b.src,async:!1,dataType:"script"}):f.globalEval((b.text||b.textContent||b.innerHTML||"").replace(fb,"/*$0*/")),b.parentNode&&b.parentNode.removeChild(b)})}return this}}),f.buildFragment=function(a,b,d){var e,g,h,i,j=a[0];return b&&b[0]&&(i=b[0].ownerDocument||b[0]),i.createDocumentFragment||(i=c),a.length===1&&typeof j=="string"&&j.length<512&&i===c&&j.charAt(0)==="<"&&!bb.test(j)&&(f.support.checkClone||!db.test(j))&&(f.support.html5Clone||!cb.test(j))&&(g=!0,h=f.fragments[j],h&&h!==1&&(e=h)),e||(e=i.createDocumentFragment(),f.clean(a,i,e,d)),g&&(f.fragments[j]=h?e:1),{fragment:e,cacheable:g}},f.fragments={},f.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(a,b){f.fn[a]=function(c){var d=[],e=f(c),g=this.length===1&&this[0].parentNode;if(g&&g.nodeType===11&&g.childNodes.length===1&&e.length===1)return e[b](this[0]),this;for(var h=0,i=e.length;h<i;h++){var j=(h>0?this.clone(!0):this).get();f(e[h])[b](j),d=d.concat(j)}return this.pushStack(d,a,e.selector)}}),f.extend({clone:function(a,b,c){var d,e,g,h=f.support.html5Clone||f.isXMLDoc(a)||!cb.test("<"+a.nodeName+">")?a.cloneNode(!0):ob(a);if((!f.support.noCloneEvent||!f.support.noCloneChecked)&&(a.nodeType===1||a.nodeType===11)&&!f.isXMLDoc(a)){kb(a,h),d=lb(a),e=lb(h);for(g=0;d[g];++g)e[g]&&kb(d[g],e[g])}if(b){jb(a,h);if(c){d=lb(a),e=lb(h);for(g=0;d[g];++g)jb(d[g],e[g])}}return d=e=null,h},clean:function(a,b,d,e){var g,h,i,j=[];b=b||c,typeof b.createElement=="undefined"&&(b=b.ownerDocument||b[0]&&b[0].ownerDocument||c);for(var k=0,l;(l=a[k])!=null;k++){typeof l=="number"&&(l+="");if(!l)continue;if(typeof l=="string")if(!_.test(l))l=b.createTextNode(l);else{l=l.replace(Y,"<$1></$2>");var m=(Z.exec(l)||["",""])[1].toLowerCase(),n=gb[m]||gb._default,o=n[0],p=b.createElement("div"),q=hb.childNodes,r;b===c?hb.appendChild(p):U(b).appendChild(p),p.innerHTML=n[1]+l+n[2];while(o--)p=p.lastChild;if(!f.support.tbody){var s=$.test(l),t=m==="table"&&!s?p.firstChild&&p.firstChild.childNodes:n[1]==="<table>"&&!s?p.childNodes:[];for(i=t.length-1;i>=0;--i)f.nodeName(t[i],"tbody")&&!t[i].childNodes.length&&t[i].parentNode.removeChild(t[i])}!f.support.leadingWhitespace&&X.test(l)&&p.insertBefore(b.createTextNode(X.exec(l)[0]),p.firstChild),l=p.childNodes,p&&(p.parentNode.removeChild(p),q.length>0&&(r=q[q.length-1],r&&r.parentNode&&r.parentNode.removeChild(r)))}var u;if(!f.support.appendChecked)if(l[0]&&typeof (u=l.length)=="number")for(i=0;i<u;i++)nb(l[i]);else nb(l);l.nodeType?j.push(l):j=f.merge(j,l)}if(d){g=function(a){return!a.type||eb.test(a.type)};for(k=0;j[k];k++){h=j[k];if(e&&f.nodeName(h,"script")&&(!h.type||eb.test(h.type)))e.push(h.parentNode?h.parentNode.removeChild(h):h);else{if(h.nodeType===1){var v=f.grep(h.getElementsByTagName("script"),g);j.splice.apply(j,[k+1,0].concat(v))}d.appendChild(h)}}}return j},cleanData:function(a){var b,c,d=f.cache,e=f.event.special,g=f.support.deleteExpando;for(var h=0,i;(i=a[h])!=null;h++){if(i.nodeName&&f.noData[i.nodeName.toLowerCase()])continue;c=i[f.expando];if(c){b=d[c];if(b&&b.events){for(var j in b.events)e[j]?f.event.remove(i,j):f.removeEvent(i,j,b.handle);b.handle&&(b.handle.elem=null)}g?delete i[f.expando]:i.removeAttribute&&i.removeAttribute(f.expando),delete d[c]}}}});var pb=/alpha\([^)]*\)/i,qb=/opacity=([^)]*)/,rb=/([A-Z]|^ms)/g,sb=/^[\-+]?(?:\d*\.)?\d+$/i,tb=/^-?(?:\d*\.)?\d+(?!px)[^\d\s]+$/i,ub=/^([\-+])=([\-+.\de]+)/,vb=/^margin/,wb={position:"absolute",visibility:"hidden",display:"block"},xb=["Top","Right","Bottom","Left"],yb,zb,Ab;f.fn.css=function(a,c){return f.access(this,function(a,c,d){return d!==b?f.style(a,c,d):f.css(a,c)},a,c,arguments.length>1)},f.extend({cssHooks:{opacity:{get:function(a,b){if(b){var c=yb(a,"opacity");return c===""?"1":c}return a.style.opacity}}},cssNumber:{fillOpacity:!0,fontWeight:!0,lineHeight:!0,opacity:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{"float":f.support.cssFloat?"cssFloat":"styleFloat"},style:function(a,c,d,e){if(!a||a.nodeType===3||a.nodeType===8||!a.style)return;var g,h,i=f.camelCase(c),j=a.style,k=f.cssHooks[i];c=f.cssProps[i]||i;if(d===b)return k&&"get"in k&&(g=k.get(a,!1,e))!==b?g:j[c];h=typeof d,h==="string"&&(g=ub.exec(d))&&(d=+(g[1]+1)*+g[2]+parseFloat(f.css(a,c)),h="number");if(d==null||h==="number"&&isNaN(d))return;h==="number"&&!f.cssNumber[i]&&(d+="px");if(!k||!("set"in k)||(d=k.set(a,d))!==b)try{j[c]=d}catch(l){}},css:function(a,c,d){var e,g;c=f.camelCase(c),g=f.cssHooks[c],c=f.cssProps[c]||c,c==="cssFloat"&&(c="float");if(g&&"get"in g&&(e=g.get(a,!0,d))!==b)return e;if(yb)return yb(a,c)},swap:function(a,b,c){var d={},e,f;for(f in b)d[f]=a.style[f],a.style[f]=b[f];e=c.call(a);for(f in b)a.style[f]=d[f];return e}}),f.curCSS=f.css,c.defaultView&&c.defaultView.getComputedStyle&&(zb=function(a,b){var c,d,e,g,h=a.style;return b=b.replace(rb,"-$1").toLowerCase(),(d=a.ownerDocument.defaultView)&&(e=d.getComputedStyle(a,null))&&(c=e.getPropertyValue(b),c===""&&!f.contains(a.ownerDocument.documentElement,a)&&(c=f.style(a,b))),!f.support.pixelMargin&&e&&vb.test(b)&&tb.test(c)&&(g=h.width,h.width=c,c=e.width,h.width=g),c}),c.documentElement.currentStyle&&(Ab=function(a,b){var c,d,e,f=a.currentStyle&&a.currentStyle[b],g=a.style;return f==null&&g&&(e=g[b])&&(f=e),tb.test(f)&&(c=g.left,d=a.runtimeStyle&&a.runtimeStyle.left,d&&(a.runtimeStyle.left=a.currentStyle.left),g.left=b==="fontSize"?"1em":f,f=g.pixelLeft+"px",g.left=c,d&&(a.runtimeStyle.left=d)),f===""?"auto":f}),yb=zb||Ab,f.each(["height","width"],function(a,b){f.cssHooks[b]={get:function(a,c,d){if(c)return a.offsetWidth!==0?Bb(a,b,d):f.swap(a,wb,function(){return Bb(a,b,d)})},set:function(a,b){return sb.test(b)?b+"px":b}}}),f.support.opacity||(f.cssHooks.opacity={get:function(a,b){return qb.test((b&&a.currentStyle?a.currentStyle.filter:a.style.filter)||"")?parseFloat(RegExp.$1)/100+"":b?"1":""},set:function(a,b){var c=a.style,d=a.currentStyle,e=f.isNumeric(b)?"alpha(opacity="+b*100+")":"",g=d&&d.filter||c.filter||"";c.zoom=1;if(b>=1&&f.trim(g.replace(pb,""))===""){c.removeAttribute("filter");if(d&&!d.filter)return}c.filter=pb.test(g)?g.replace(pb,e):g+" "+e}}),f(function(){f.support.reliableMarginRight||(f.cssHooks.marginRight={get:function(a,b){return f.swap(a,{display:"inline-block"},function(){return b?yb(a,"margin-right"):a.style.marginRight})}})}),f.expr&&f.expr.filters&&(f.expr.filters.hidden=function(a){var b=a.offsetWidth,c=a.offsetHeight;return b===0&&c===0||!f.support.reliableHiddenOffsets&&(a.style&&a.style.display||f.css(a,"display"))==="none"},f.expr.filters.visible=function(a){return!f.expr.filters.hidden(a)}),f.each({margin:"",padding:"",border:"Width"},function(a,b){f.cssHooks[a+b]={expand:function(c){var d,e=typeof c=="string"?c.split(" "):[c],f={};for(d=0;d<4;d++)f[a+xb[d]+b]=e[d]||e[d-2]||e[0];return f}}});var Cb=/%20/g,Db=/\[\]$/,Eb=/\r?\n/g,Fb=/#.*$/,Gb=/^(.*?):[ \t]*([^\r\n]*)\r?$/mg,Hb=/^(?:color|date|datetime|datetime-local|email|hidden|month|number|password|range|search|tel|text|time|url|week)$/i,Ib=/^(?:about|app|app\-storage|.+\-extension|file|res|widget):$/,Jb=/^(?:GET|HEAD)$/,Kb=/^\/\//,Lb=/\?/,Mb=/<script\b[^<]*(?:(?!<\/script>)<[^<]*)*<\/script>/gi,Nb=/^(?:select|textarea)/i,Ob=/\s+/,Pb=/([?&])_=[^&]*/,Qb=/^([\w\+\.\-]+:)(?:\/\/([^\/?#:]*)(?::(\d+))?)?/,Rb=f.fn.load,Sb={},Tb={},Ub,Vb,Wb=["*/"]+["*"];try{Ub=e.href}catch(Xb){Ub=c.createElement("a"),Ub.href="",Ub=Ub.href}Vb=Qb.exec(Ub.toLowerCase())||[],f.fn.extend({load:function(a,c,d){if(typeof a!="string"&&Rb)return Rb.apply(this,arguments);if(!this.length)return this;var e=a.indexOf(" ");if(e>=0){var g=a.slice(e,a.length);a=a.slice(0,e)}var h="GET";c&&(f.isFunction(c)?(d=c,c=b):typeof c=="object"&&(c=f.param(c,f.ajaxSettings.traditional),h="POST"));var i=this;return f.ajax({url:a,type:h,dataType:"html",data:c,complete:function(a,b,c){c=a.responseText,a.isResolved()&&(a.done(function(a){c=a}),i.html(g?f("<div>").append(c.replace(Mb,"")).find(g):c)),d&&i.each(d,[c,b,a])}}),this},serialize:function(){return f.param(this.serializeArray())},serializeArray:function(){return this.map(function(){return this.elements?f.makeArray(this.elements):this}).filter(function(){return this.name&&!this.disabled&&(this.checked||Nb.test(this.nodeName)||Hb.test(this.type))}).map(function(a,b){var c=f(this).val();return c==null?null:f.isArray(c)?f.map(c,function(a,c){return{name:b.name,value:a.replace(Eb,"\r\n")}}):{name:b.name,value:c.replace(Eb,"\r\n")}}).get()}}),f.each("ajaxStart ajaxStop ajaxComplete ajaxError ajaxSuccess ajaxSend".split(" "),function(a,b){f.fn[b]=function(a){return this.on(b,a)}}),f.each(["get","post"],function(a,c){f[c]=function(a,d,e,g){return f.isFunction(d)&&(g=g||e,e=d,d=b),f.ajax({type:c,url:a,data:d,success:e,dataType:g})}}),f.extend({getScript:function(a,c){return f.get(a,b,c,"script")},getJSON:function(a,b,c){return f.get(a,b,c,"json")},ajaxSetup:function(a,b){return b?$b(a,f.ajaxSettings):(b=a,a=f.ajaxSettings),$b(a,b),a},ajaxSettings:{url:Ub,isLocal:Ib.test(Vb[1]),global:!0,type:"GET",contentType:"application/x-www-form-urlencoded; charset=UTF-8",processData:!0,async:!0,accepts:{xml:"application/xml, text/xml",html:"text/html",text:"text/plain",json:"application/json, text/javascript","*":Wb},contents:{xml:/xml/,html:/html/,json:/json/},responseFields:{xml:"responseXML",text:"responseText"},converters:{"* text":a.String,"text html":!0,"text json":f.parseJSON,"text xml":f.parseXML},flatOptions:{context:!0,url:!0}},ajaxPrefilter:Yb(Sb),ajaxTransport:Yb(Tb),ajax:function(a,c){function w(a,c,l,m){if(s===2)return;s=2,q&&clearTimeout(q),p=b,n=m||"",v.readyState=a>0?4:0;var o,r,u,w=c,x=l?ac(d,v,l):b,y,z;if(a>=200&&a<300||a===304){if(d.ifModified){if(y=v.getResponseHeader("Last-Modified"))f.lastModified[k]=y;if(z=v.getResponseHeader("Etag"))f.etag[k]=z}if(a===304)w="notmodified",o=!0;else try{r=bc(d,x),w="success",o=!0}catch(A){w="parsererror",u=A}}else{u=w;if(!w||a)w="error",a<0&&(a=0)}v.status=a,v.statusText=""+(c||w),o?h.resolveWith(e,[r,w,v]):h.rejectWith(e,[v,w,u]),v.statusCode(j),j=b,t&&g.trigger("ajax"+(o?"Success":"Error"),[v,d,o?r:u]),i.fireWith(e,[v,w]),t&&(g.trigger("ajaxComplete",[v,d]),--f.active||f.event.trigger("ajaxStop"))}typeof a=="object"&&(c=a,a=b),c=c||{};var d=f.ajaxSetup({},c),e=d.context||d,g=e!==d&&(e.nodeType||e instanceof f)?f(e):f.event,h=f.Deferred(),i=f.Callbacks("once memory"),j=d.statusCode||{},k,l={},m={},n,o,p,q,r,s=0,t,u,v={readyState:0,setRequestHeader:function(a,b){if(!s){var c=a.toLowerCase();a=m[c]=m[c]||a,l[a]=b}return this},getAllResponseHeaders:function(){return s===2?n:null},getResponseHeader:function(a){var c;if(s===2){if(!o){o={};while(c=Gb.exec(n))o[c[1].toLowerCase()]=c[2]}c=o[a.toLowerCase()]}return c===b?null:c},overrideMimeType:function(a){return s||(d.mimeType=a),this},abort:function(a){return a=a||"abort",p&&p.abort(a),w(0,a),this}};h.promise(v),v.success=v.done,v.error=v.fail,v.complete=i.add,v.statusCode=function(a){if(a){var b;if(s<2)for(b in a)j[b]=[j[b],a[b]];else b=a[v.status],v.then(b,b)}return this},d.url=((a||d.url)+"").replace(Fb,"").replace(Kb,Vb[1]+"//"),d.dataTypes=f.trim(d.dataType||"*").toLowerCase().split(Ob),d.crossDomain==null&&(r=Qb.exec(d.url.toLowerCase()),d.crossDomain=!(!r||r[1]==Vb[1]&&r[2]==Vb[2]&&(r[3]||(r[1]==="http:"?80:443))==(Vb[3]||(Vb[1]==="http:"?80:443)))),d.data&&d.processData&&typeof d.data!="string"&&(d.data=f.param(d.data,d.traditional)),Zb(Sb,d,c,v);if(s===2)return!1;t=d.global,d.type=d.type.toUpperCase(),d.hasContent=!Jb.test(d.type),t&&f.active++===0&&f.event.trigger("ajaxStart");if(!d.hasContent){d.data&&(d.url+=(Lb.test(d.url)?"&":"?")+d.data,delete d.data),k=d.url;if(d.cache===!1){var x=f.now(),y=d.url.replace(Pb,"$1_="+x);d.url=y+(y===d.url?(Lb.test(d.url)?"&":"?")+"_="+x:"")}}(d.data&&d.hasContent&&d.contentType!==!1||c.contentType)&&v.setRequestHeader("Content-Type",d.contentType),d.ifModified&&(k=k||d.url,f.lastModified[k]&&v.setRequestHeader("If-Modified-Since",f.lastModified[k]),f.etag[k]&&v.setRequestHeader("If-None-Match",f.etag[k])),v.setRequestHeader("Accept",d.dataTypes[0]&&d.accepts[d.dataTypes[0]]?d.accepts[d.dataTypes[0]]+(d.dataTypes[0]!=="*"?", "+Wb+"; q=0.01":""):d.accepts["*"]);for(u in d.headers)v.setRequestHeader(u,d.headers[u]);if(!d.beforeSend||d.beforeSend.call(e,v,d)!==!1&&s!==2){for(u in{success:1,error:1,complete:1})v[u](d[u]);p=Zb(Tb,d,c,v);if(!p)w(-1,"No Transport");else{v.readyState=1,t&&g.trigger("ajaxSend",[v,d]),d.async&&d.timeout>0&&(q=setTimeout(function(){v.abort("timeout")},d.timeout));try{s=1,p.send(l,w)}catch(z){if(!(s<2))throw z;w(-1,z)}}return v}return v.abort(),!1},param:function(a,c){var d=[],e=function(a,b){b=f.isFunction(b)?b():b,d[d.length]=encodeURIComponent(a)+"="+encodeURIComponent(b)};c===b&&(c=f.ajaxSettings.traditional);if(f.isArray(a)||a.jquery&&!f.isPlainObject(a))f.each(a,function(){e(this.name,this.value)});else for(var g in a)_b(g,a[g],c,e);return d.join("&").replace(Cb,"+")}}),f.extend({active:0,lastModified:{},etag:{}});var cc=f.now(),dc=/(\=)\?(&|$)|\?\?/i;f.ajaxSetup({jsonp:"callback",jsonpCallback:function(){return f.expando+"_"+cc++}}),f.ajaxPrefilter("json jsonp",function(b,c,d){var e=typeof b.data=="string"&&/^application\/x\-www\-form\-urlencoded/.test(b.contentType);if(b.dataTypes[0]==="jsonp"||b.jsonp!==!1&&(dc.test(b.url)||e&&dc.test(b.data))){var g,h=b.jsonpCallback=f.isFunction(b.jsonpCallback)?b.jsonpCallback():b.jsonpCallback,i=a[h],j=b.url,k=b.data,l="$1"+h+"$2";return b.jsonp!==!1&&(j=j.replace(dc,l),b.url===j&&(e&&(k=k.replace(dc,l)),b.data===k&&(j+=(/\?/.test(j)?"&":"?")+b.jsonp+"="+h))),b.url=j,b.data=k,a[h]=function(a){g=[a]},d.always(function(){a[h]=i,g&&f.isFunction(i)&&a[h](g[0])}),b.converters["script json"]=function(){return g||f.error(h+" was not called"),g[0]},b.dataTypes[0]="json","script"}}),f.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/javascript|ecmascript/},converters:{"text script":function(a){return f.globalEval(a),a}}}),f.ajaxPrefilter("script",function(a){a.cache===b&&(a.cache=!1),a.crossDomain&&(a.type="GET",a.global=!1)}),f.ajaxTransport("script",function(a){if(a.crossDomain){var d,e=c.head||c.getElementsByTagName("head")[0]||c.documentElement;return{send:function(f,g){d=c.createElement("script"),d.async="async",a.scriptCharset&&(d.charset=a.scriptCharset),d.src=a.url,d.onload=d.onreadystatechange=function(a,c){if(c||!d.readyState||/loaded|complete/.test(d.readyState))d.onload=d.onreadystatechange=null,e&&d.parentNode&&e.removeChild(d),d=b,c||g(200,"success")},e.insertBefore(d,e.firstChild)},abort:function(){d&&d.onload(0,1)}}}});var ec=a.ActiveXObject?function(){for(var a in gc)gc[a](0,1)}:!1,fc=0,gc;f.ajaxSettings.xhr=a.ActiveXObject?function(){return!this.isLocal&&hc()||ic()}:hc,function(a){f.extend(f.support,{ajax:!!a,cors:!!a&&"withCredentials"in a})}(f.ajaxSettings.xhr()),f.support.ajax&&f.ajaxTransport(function(c){if(!c.crossDomain||f.support.cors){var d;return{send:function(e,g){var h=c.xhr(),i,j;c.username?h.open(c.type,c.url,c.async,c.username,c.password):h.open(c.type,c.url,c.async);if(c.xhrFields)for(j in c.xhrFields)h[j]=c.xhrFields[j];c.mimeType&&h.overrideMimeType&&h.overrideMimeType(c.mimeType),!c.crossDomain&&!e["X-Requested-With"]&&(e["X-Requested-With"]="XMLHttpRequest");try{for(j in e)h.setRequestHeader(j,e[j])}catch(k){}h.send(c.hasContent&&c.data||null),d=function(a,e){var j,k,l,m,n;try{if(d&&(e||h.readyState===4)){d=b,i&&(h.onreadystatechange=f.noop,ec&&delete gc[i]);if(e)h.readyState!==4&&h.abort();else{j=h.status,l=h.getAllResponseHeaders(),m={},n=h.responseXML,n&&n.documentElement&&(m.xml=n);try{m.text=h.responseText}catch(a){}try{k=h.statusText}catch(o){k=""}!j&&c.isLocal&&!c.crossDomain?j=m.text?200:404:j===1223&&(j=204)}}}catch(p){e||g(-1,p)}m&&g(j,k,m,l)},!c.async||h.readyState===4?d():(i=++fc,ec&&(gc||(gc={},f(a).unload(ec)),gc[i]=d),h.onreadystatechange=d)},abort:function(){d&&d(0,1)}}}});var jc={},kc,lc,mc=/^(?:toggle|show|hide)$/,nc=/^([+\-]=)?([\d+.\-]+)([a-z%]*)$/i,oc,pc=[["height","marginTop","marginBottom","paddingTop","paddingBottom"],["width","marginLeft","marginRight","paddingLeft","paddingRight"],["opacity"]],qc;f.fn.extend({show:function(a,b,c){var d,e;if(a||a===0)return this.animate(tc("show",3),a,b,c);for(var g=0,h=this.length;g<h;g++)d=this[g],d.style&&(e=d.style.display,!f._data(d,"olddisplay")&&e==="none"&&(e=d.style.display=""),(e===""&&f.css(d,"display")==="none"||!f.contains(d.ownerDocument.documentElement,d))&&f._data(d,"olddisplay",uc(d.nodeName)));for(g=0;g<h;g++){d=this[g];if(d.style){e=d.style.display;if(e===""||e==="none")d.style.display=f._data(d,"olddisplay")||""}}return this},hide:function(a,b,c){if(a||a===0)return this.animate(tc("hide",3),a,b,c);var d,e,g=0,h=this.length;for(;g<h;g++)d=this[g],d.style&&(e=f.css(d,"display"),e!=="none"&&!f._data(d,"olddisplay")&&f._data(d,"olddisplay",e));for(g=0;g<h;g++)this[g].style&&(this[g].style.display="none");return this},_toggle:f.fn.toggle,toggle:function(a,b,c){var d=typeof a=="boolean";return f.isFunction(a)&&f.isFunction(b)?this._toggle.apply(this,arguments):a==null||d?this.each(function(){var b=d?a:f(this).is(":hidden");f(this)[b?"show":"hide"]()}):this.animate(tc("toggle",3),a,b,c),this},fadeTo:function(a,b,c,d){return this.filter(":hidden").css("opacity",0).show().end().animate({opacity:b},a,c,d)},animate:function(a,b,c,d){function g(){e.queue===!1&&f._mark(this);var b=f.extend({},e),c=this.nodeType===1,d=c&&f(this).is(":hidden"),g,h,i,j,k,l,m,n,o,p,q;b.animatedProperties={};for(i in a){g=f.camelCase(i),i!==g&&(a[g]=a[i],delete a[i]);if((k=f.cssHooks[g])&&"expand"in k){l=k.expand(a[g]),delete a[g];for(i in l)i in a||(a[i]=l[i])}}for(g in a){h=a[g],f.isArray(h)?(b.animatedProperties[g]=h[1],h=a[g]=h[0]):b.animatedProperties[g]=b.specialEasing&&b.specialEasing[g]||b.easing||"swing";if(h==="hide"&&d||h==="show"&&!d)return b.complete.call(this);c&&(g==="height"||g==="width")&&(b.overflow=[this.style.overflow,this.style.overflowX,this.style.overflowY],f.css(this,"display")==="inline"&&f.css(this,"float")==="none"&&(!f.support.inlineBlockNeedsLayout||uc(this.nodeName)==="inline"?this.style.display="inline-block":this.style.zoom=1))}b.overflow!=null&&(this.style.overflow="hidden");for(i in a)j=new f.fx(this,b,i),h=a[i],mc.test(h)?(q=f._data(this,"toggle"+i)||(h==="toggle"?d?"show":"hide":0),q?(f._data(this,"toggle"+i,q==="show"?"hide":"show"),j[q]()):j[h]()):(m=nc.exec(h),n=j.cur(),m?(o=parseFloat(m[2]),p=m[3]||(f.cssNumber[i]?"":"px"),p!=="px"&&(f.style(this,i,(o||1)+p),n=(o||1)/j.cur()*n,f.style(this,i,n+p)),m[1]&&(o=(m[1]==="-="?-1:1)*o+n),j.custom(n,o,p)):j.custom(n,h,""));return!0}var e=f.speed(b,c,d);return f.isEmptyObject(a)?this.each(e.complete,[!1]):(a=f.extend({},a),e.queue===!1?this.each(g):this.queue(e.queue,g))},stop:function(a,c,d){return typeof a!="string"&&(d=c,c=a,a=b),c&&a!==!1&&this.queue(a||"fx",[]),this.each(function(){function h(a,b,c){var e=b[c];f.removeData(a,c,!0),e.stop(d)}var b,c=!1,e=f.timers,g=f._data(this);d||f._unmark(!0,this);if(a==null)for(b in g)g[b]&&g[b].stop&&b.indexOf(".run")===b.length-4&&h(this,g,b);else g[b=a+".run"]&&g[b].stop&&h(this,g,b);for(b=e.length;b--;)e[b].elem===this&&(a==null||e[b].queue===a)&&(d?e[b](!0):e[b].saveState(),c=!0,e.splice(b,1));(!d||!c)&&f.dequeue(this,a)})}}),f.each({slideDown:tc("show",1),slideUp:tc("hide",1),slideToggle:tc("toggle",1),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(a,b){f.fn[a]=function(a,c,d){return this.animate(b,a,c,d)}}),f.extend({speed:function(a,b,c){var d=a&&typeof a=="object"?f.extend({},a):{complete:c||!c&&b||f.isFunction(a)&&a,duration:a,easing:c&&b||b&&!f.isFunction(b)&&b};d.duration=f.fx.off?0:typeof d.duration=="number"?d.duration:d.duration in f.fx.speeds?f.fx.speeds[d.duration]:f.fx.speeds._default;if(d.queue==null||d.queue===!0)d.queue="fx";return d.old=d.complete,d.complete=function(a){f.isFunction(d.old)&&d.old.call(this),d.queue?f.dequeue(this,d.queue):a!==!1&&f._unmark(this)},d},easing:{linear:function(a){return a},swing:function(a){return-Math.cos(a*Math.PI)/2+.5}},timers:[],fx:function(a,b,c){this.options=b,this.elem=a,this.prop=c,b.orig=b.orig||{}}}),f.fx.prototype={update:function(){this.options.step&&this.options.step.call(this.elem,this.now,this),(f.fx.step[this.prop]||f.fx.step._default)(this)},cur:function(){if(this.elem[this.prop]==null||!!this.elem.style&&this.elem.style[this.prop]!=null){var a,b=f.css(this.elem,this.prop);return isNaN(a=parseFloat(b))?!b||b==="auto"?0:b:a}return this.elem[this.prop]},custom:function(a,c,d){function h(a){return e.step(a)}var e=this,g=f.fx;this.startTime=qc||rc(),this.end=c,this.now=this.start=a,this.pos=this.state=0,this.unit=d||this.unit||(f.cssNumber[this.prop]?"":"px"),h.queue=this.options.queue,h.elem=this.elem,h.saveState=function(){f._data(e.elem,"fxshow"+e.prop)===b&&(e.options.hide?f._data(e.elem,"fxshow"+e.prop,e.start):e.options.show&&f._data(e.elem,"fxshow"+e.prop,e.end))},h()&&f.timers.push(h)&&!oc&&(oc=setInterval(g.tick,g.interval))},show:function(){var a=f._data(this.elem,"fxshow"+this.prop);this.options.orig[this.prop]=a||f.style(this.elem,this.prop),this.options.show=!0,a!==b?this.custom(this.cur(),a):this.custom(this.prop==="width"||this.prop==="height"?1:0,this.cur()),f(this.elem).show()},hide:function(){this.options.orig[this.prop]=f._data(this.elem,"fxshow"+this.prop)||f.style(this.elem,this.prop),this.options.hide=!0,this.custom(this.cur(),0)},step:function(a){var b,c,d,e=qc||rc(),g=!0,h=this.elem,i=this.options;if(a||e>=i.duration+this.startTime){this.now=this.end,this.pos=this.state=1,this.update(),i.animatedProperties[this.prop]=!0;for(b in i.animatedProperties)i.animatedProperties[b]!==!0&&(g=!1);if(g){i.overflow!=null&&!f.support.shrinkWrapBlocks&&f.each(["","X","Y"],function(a,b){h.style["overflow"+b]=i.overflow[a]}),i.hide&&f(h).hide();if(i.hide||i.show)for(b in i.animatedProperties)f.style(h,b,i.orig[b]),f.removeData(h,"fxshow"+b,!0),f.removeData(h,"toggle"+b,!0);d=i.complete,d&&(i.complete=!1,d.call(h))}return!1}return i.duration==Infinity?this.now=e:(c=e-this.startTime,this.state=c/i.duration,this.pos=f.easing[i.animatedProperties[this.prop]](this.state,c,0,1,i.duration),this.now=this.start+(this.end-this.start)*this.pos),this.update(),!0}},f.extend(f.fx,{tick:function(){var a,b=f.timers,c=0;for(;c<b.length;c++)a=b[c],!a()&&b[c]===a&&b.splice(c--,1);b.length||f.fx.stop()},interval:13,stop:function(){clearInterval(oc),oc=null},speeds:{slow:600,fast:200,_default:400},step:{opacity:function(a){f.style(a.elem,"opacity",a.now)},_default:function(a){a.elem.style&&a.elem.style[a.prop]!=null?a.elem.style[a.prop]=a.now+a.unit:a.elem[a.prop]=a.now}}}),f.each(pc.concat.apply([],pc),function(a,b){b.indexOf("margin")&&(f.fx.step[b]=function(a){f.style(a.elem,b,Math.max(0,a.now)+a.unit)})}),f.expr&&f.expr.filters&&(f.expr.filters.animated=function(a){return f.grep(f.timers,function(b){return a===b.elem}).length});var vc,wc=/^t(?:able|d|h)$/i,xc=/^(?:body|html)$/i;"getBoundingClientRect"in c.documentElement?vc=function(a,b,c,d){try{d=a.getBoundingClientRect()}catch(e){}if(!d||!f.contains(c,a))return d?{top:d.top,left:d.left}:{top:0,left:0};var g=b.body,h=yc(b),i=c.clientTop||g.clientTop||0,j=c.clientLeft||g.clientLeft||0,k=h.pageYOffset||f.support.boxModel&&c.scrollTop||g.scrollTop,l=h.pageXOffset||f.support.boxModel&&c.scrollLeft||g.scrollLeft,m=d.top+k-i,n=d.left+l-j;return{top:m,left:n}}:vc=function(a,b,c){var d,e=a.offsetParent,g=a,h=b.body,i=b.defaultView,j=i?i.getComputedStyle(a,null):a.currentStyle,k=a.offsetTop,l=a.offsetLeft;while((a=a.parentNode)&&a!==h&&a!==c){if(f.support.fixedPosition&&j.position==="fixed")break;d=i?i.getComputedStyle(a,null):a.currentStyle,k-=a.scrollTop,l-=a.scrollLeft,a===e&&(k+=a.offsetTop,l+=a.offsetLeft,f.support.doesNotAddBorder&&(!f.support.doesAddBorderForTableAndCells||!wc.test(a.nodeName))&&(k+=parseFloat(d.borderTopWidth)||0,l+=parseFloat(d.borderLeftWidth)||0),g=e,e=a.offsetParent),f.support.subtractsBorderForOverflowNotVisible&&d.overflow!=="visible"&&(k+=parseFloat(d.borderTopWidth)||0,l+=parseFloat(d.borderLeftWidth)||0),j=d}if(j.position==="relative"||j.position==="static")k+=h.offsetTop,l+=h.offsetLeft;return f.support.fixedPosition&&j.position==="fixed"&&(k+=Math.max(c.scrollTop,h.scrollTop),l+=Math.max(c.scrollLeft,h.scrollLeft)),{top:k,left:l}},f.fn.offset=function(a){if(arguments.length)return a===b?this:this.each(function(b){f.offset.setOffset(this,a,b)});var c=this[0],d=c&&c.ownerDocument;return d?c===d.body?f.offset.bodyOffset(c):vc(c,d,d.documentElement):null},f.offset={bodyOffset:function(a){var b=a.offsetTop,c=a.offsetLeft;return f.support.doesNotIncludeMarginInBodyOffset&&(b+=parseFloat(f.css(a,"marginTop"))||0,c+=parseFloat(f.css(a,"marginLeft"))||0),{top:b,left:c}},setOffset:function(a,b,c){var d=f.css(a,"position");d==="static"&&(a.style.position="relative");var e=f(a),g=e.offset(),h=f.css(a,"top"),i=f.css(a,"left"),j=(d==="absolute"||d==="fixed")&&f.inArray("auto",[h,i])>-1,k={},l={},m,n;j?(l=e.position(),m=l.top,n=l.left):(m=parseFloat(h)||0,n=parseFloat(i)||0),f.isFunction(b)&&(b=b.call(a,c,g)),b.top!=null&&(k.top=b.top-g.top+m),b.left!=null&&(k.left=b.left-g.left+n),"using"in b?b.using.call(a,k):e.css(k)}},f.fn.extend({position:function(){if(!this[0])return null;var a=this[0],b=this.offsetParent(),c=this.offset(),d=xc.test(b[0].nodeName)?{top:0,left:0}:b.offset();return c.top-=parseFloat(f.css(a,"marginTop"))||0,c.left-=parseFloat(f.css(a,"marginLeft"))||0,d.top+=parseFloat(f.css(b[0],"borderTopWidth"))||0,d.left+=parseFloat(f.css(b[0],"borderLeftWidth"))||0,{top:c.top-d.top,left:c.left-d.left}},offsetParent:function(){return this.map(function(){var a=this.offsetParent||c.body;while(a&&!xc.test(a.nodeName)&&f.css(a,"position")==="static")a=a.offsetParent;return a})}}),f.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(a,c){var d=/Y/.test(c);f.fn[a]=function(e){return f.access(this,function(a,e,g){var h=yc(a);if(g===b)return h?c in h?h[c]:f.support.boxModel&&h.document.documentElement[e]||h.document.body[e]:a[e];h?h.scrollTo(d?f(h).scrollLeft():g,d?g:f(h).scrollTop()):a[e]=g},a,e,arguments.length,null)}}),f.each({Height:"height",Width:"width"},function(a,c){var d="client"+a,e="scroll"+a,g="offset"+a;f.fn["inner"+a]=function(){var a=this[0];return a?a.style?parseFloat(f.css(a,c,"padding")):this[c]():null},f.fn["outer"+a]=function(a){var b=this[0];return b?b.style?parseFloat(f.css(b,c,a?"margin":"border")):this[c]():null},f.fn[c]=function(a){return f.access(this,function(a,c,h){var i,j,k,l;if(f.isWindow(a))return i=a.document,j=i.documentElement[d],f.support.boxModel&&j||i.body&&i.body[d]||j;if(a.nodeType===9)return i=a.documentElement,i[d]>=i[e]?i[d]:Math.max(a.body[e],i[e],a.body[g],i[g]);if(h===b)return k=f.css(a,c),l=parseFloat(k),f.isNumeric(l)?l:k;f(a).css(c,h)},c,a,arguments.length,null)}}),a.jQuery=a.$=f,typeof define=="function"&&define.amd&&define.amd.jQuery&&define("jquery",[],function(){return f})})(window),function(a,b){var c;a.rails=c={linkClickSelector:"a[data-confirm], a[data-method], a[data-remote], a[data-disable-with]",inputChangeSelector:"select[data-remote], input[data-remote], textarea[data-remote]",formSubmitSelector:"form",formInputClickSelector:"form input[type=submit], form input[type=image], form button[type=submit], form button:not(button[type])",disableSelector:"input[data-disable-with], button[data-disable-with], textarea[data-disable-with]",enableSelector:"input[data-disable-with]:disabled, button[data-disable-with]:disabled, textarea[data-disable-with]:disabled",requiredInputSelector:"input[name][required]:not([disabled]),textarea[name][required]:not([disabled])",fileInputSelector:"input:file",linkDisableSelector:"a[data-disable-with]",CSRFProtection:function(b){var c=a('meta[name="csrf-token"]').attr("content");c&&b.setRequestHeader("X-CSRF-Token",c)},fire:function(b,c,d){var e=a.Event(c);return b.trigger(e,d),e.result!==!1},confirm:function(a){return confirm(a)},ajax:function(b){return a.ajax(b)},href:function(a){return a.attr("href")},handleRemote:function(d){var e,f,g,h,i,j;if(c.fire(d,"ajax:before")){h=d.data("cross-domain")||null,i=d.data("type")||a.ajaxSettings&&a.ajaxSettings.dataType;if(d.is("form")){e=d.attr("method"),f=d.attr("action"),g=d.serializeArray();var k=d.data("ujs:submit-button");k&&(g.push(k),d.data("ujs:submit-button",null))}else d.is(c.inputChangeSelector)?(e=d.data("method"),f=d.data("url"),g=d.serialize(),d.data("params")&&(g=g+"&"+d.data("params"))):(e=d.data("method"),f=c.href(d),g=d.data("params")||null);return j={type:e||"GET",data:g,dataType:i,crossDomain:h,beforeSend:function(a,e){return e.dataType===b&&a.setRequestHeader("accept","*/*;q=0.5, "+e.accepts.script),c.fire(d,"ajax:beforeSend",[a,e])},success:function(a,b,c){d.trigger("ajax:success",[a,b,c])},complete:function(a,b){d.trigger("ajax:complete",[a,b])},error:function(a,b,c){d.trigger("ajax:error",[a,b,c])}},f&&(j.url=f),c.ajax(j)}return!1},handleMethod:function(d){var e=c.href(d),f=d.data("method"),g=d.attr("target"),h=a("meta[name=csrf-token]").attr("content"),i=a("meta[name=csrf-param]").attr("content"),j=a('<form method="post" action="'+e+'"></form>'),k='<input name="_method" value="'+f+'" type="hidden" />';i!==b&&h!==b&&(k+='<input name="'+i+'" value="'+h+'" type="hidden" />'),g&&j.attr("target",g),j.hide().append(k).appendTo("body"),j.submit()},disableFormElements:function(b){b.find(c.disableSelector).each(function(){var b=a(this),c=b.is("button")?"html":"val";b.data("ujs:enable-with",b[c]()),b[c](b.data("disable-with")),b.prop("disabled",!0)})},enableFormElements:function(b){b.find(c.enableSelector).each(function(){var b=a(this),c=b.is("button")?"html":"val";b.data("ujs:enable-with")&&b[c](b.data("ujs:enable-with")),b.prop("disabled",!1)})},allowAction:function(a){var b=a.data("confirm"),d=!1,e;return b?(c.fire(a,"confirm")&&(d=c.confirm(b),e=c.fire(a,"confirm:complete",[d])),d&&e):!0},blankInputs:function(b,c,d){var e=a(),f,g=c||"input,textarea";return b.find(g).each(function(){f=a(this);if(d?f.val():!f.val())e=e.add(f)}),e.length?e:!1},nonBlankInputs:function(a,b){return c.blankInputs(a,b,!0)},stopEverything:function(b){return a(b.target).trigger("ujs:everythingStopped"),b.stopImmediatePropagation(),!1},callFormSubmitBindings
|
21
|
+
:function(c,d){var e=c.data("events"),f=!0;return e!==b&&e.submit!==b&&a.each(e.submit,function(a,b){if(typeof b.handler=="function")return f=b.handler(d)}),f},disableElement:function(a){a.data("ujs:enable-with",a.html()),a.html(a.data("disable-with")),a.bind("click.railsDisable",function(a){return c.stopEverything(a)})},enableElement:function(a){a.data("ujs:enable-with")!==b&&(a.html(a.data("ujs:enable-with")),a.data("ujs:enable-with",!1)),a.unbind("click.railsDisable")}},a.ajaxPrefilter(function(a,b,d){a.crossDomain||c.CSRFProtection(d)}),a(document).delegate(c.linkDisableSelector,"ajax:complete",function(){c.enableElement(a(this))}),a(document).delegate(c.linkClickSelector,"click.rails",function(d){var e=a(this),f=e.data("method"),g=e.data("params");if(!c.allowAction(e))return c.stopEverything(d);e.is(c.linkDisableSelector)&&c.disableElement(e);if(e.data("remote")!==b)return(d.metaKey||d.ctrlKey)&&(!f||f==="GET")&&!g?!0:(c.handleRemote(e)===!1&&c.enableElement(e),!1);if(e.data("method"))return c.handleMethod(e),!1}),a(document).delegate(c.inputChangeSelector,"change.rails",function(b){var d=a(this);return c.allowAction(d)?(c.handleRemote(d),!1):c.stopEverything(b)}),a(document).delegate(c.formSubmitSelector,"submit.rails",function(d){var e=a(this),f=e.data("remote")!==b,g=c.blankInputs(e,c.requiredInputSelector),h=c.nonBlankInputs(e,c.fileInputSelector);if(!c.allowAction(e))return c.stopEverything(d);if(g&&e.attr("novalidate")==b&&c.fire(e,"ajax:aborted:required",[g]))return c.stopEverything(d);if(f)return h?c.fire(e,"ajax:aborted:file",[h]):!a.support.submitBubbles&&a().jquery<"1.7"&&c.callFormSubmitBindings(e,d)===!1?c.stopEverything(d):(c.handleRemote(e),!1);setTimeout(function(){c.disableFormElements(e)},13)}),a(document).delegate(c.formInputClickSelector,"click.rails",function(b){var d=a(this);if(!c.allowAction(d))return c.stopEverything(b);var e=d.attr("name"),f=e?{name:e,value:d.val()}:null;d.closest("form").data("ujs:submit-button",f)}),a(document).delegate(c.formSubmitSelector,"ajax:beforeSend.rails",function(b){this==b.target&&c.disableFormElements(a(this))}),a(document).delegate(c.formSubmitSelector,"ajax:complete.rails",function(b){this==b.target&&c.enableFormElements(a(this))})}(jQuery);:@created_atf1335715282.9311869��
|
@@ -0,0 +1,21 @@
|
|
1
|
+
o: ActiveSupport::Cache::Entry :@expires_in0:@compressedF:@value"8�{"required_assets_digest"%1a2dc79471515227aafd54563970d306"content_type"application/javascript"
|
2
|
+
class"BundledAsset"
|
3
|
+
mtime"2012-04-28T20:21:50-05:00"
|
4
|
+
* jQuery JavaScript Library v1.7.2
|
5
|
+
* http://jquery.com/
|
6
|
+
*
|
7
|
+
* Copyright 2011, John Resig
|
8
|
+
* Dual licensed under the MIT or GPL Version 2 licenses.
|
9
|
+
* http://jquery.org/license
|
10
|
+
*
|
11
|
+
* Includes Sizzle.js
|
12
|
+
* http://sizzlejs.com/
|
13
|
+
* Copyright 2011, The Dojo Foundation
|
14
|
+
* Released under the MIT, BSD, and GPL Licenses.
|
15
|
+
*
|
16
|
+
* Date: Wed Mar 21 12:46:34 2012 -0700
|
17
|
+
*/
|
18
|
+
(function(a,b){function h(a){var b=g[a]={},c,d;a=a.split(/\s+/);for(c=0,d=a.length;c<d;c++)b[a[c]]=!0;return b}function l(a,c,d){if(d===b&&a.nodeType===1){var e="data-"+c.replace(k,"-$1").toLowerCase();d=a.getAttribute(e);if(typeof d=="string"){try{d=d==="true"?!0:d==="false"?!1:d==="null"?null:f.isNumeric(d)?+d:j.test(d)?f.parseJSON(d):d}catch(g){}f.data(a,c,d)}else d=b}return d}function m(a){for(var b in a){if(b==="data"&&f.isEmptyObject(a[b]))continue;if(b!=="toJSON")return!1}return!0}function n(a,b,c){var d=b+"defer",e=b+"queue",g=b+"mark",h=f._data(a,d);h&&(c==="queue"||!f._data(a,e))&&(c==="mark"||!f._data(a,g))&&setTimeout(function(){!f._data(a,e)&&!f._data(a,g)&&(f.removeData(a,d,!0),h.fire())},0)}function J(){return!1}function K(){return!0}function S(a){return!a||!a.parentNode||a.parentNode.nodeType===11}function T(a,b,c){b=b||0;if(f.isFunction(b))return f.grep(a,function(a,d){var e=!!b.call(a,d,a);return e===c});if(b.nodeType)return f.grep(a,function(a,d){return a===b===c});if(typeof b=="string"){var d=f.grep(a,function(a){return a.nodeType===1});if(O.test(b))return f.filter(b,d,!c);b=f.filter(b,d)}return f.grep(a,function(a,d){return f.inArray(a,b)>=0===c})}function U(a){var b=V.split("|"),c=a.createDocumentFragment();if(c.createElement)while(b.length)c.createElement(b.pop());return c}function ib(a,b){return f.nodeName(a,"table")?a.getElementsByTagName("tbody")[0]||a.appendChild(a.ownerDocument.createElement("tbody")):a}function jb(a,b){if(b.nodeType!==1||!f.hasData(a))return;var c,d,e,g=f._data(a),h=f._data(b,g),i=g.events;if(i){delete h.handle,h.events={};for(c in i)for(d=0,e=i[c].length;d<e;d++)f.event.add(b,c,i[c][d])}h.data&&(h.data=f.extend({},h.data))}function kb(a,b){var c;if(b.nodeType!==1)return;b.clearAttributes&&b.clearAttributes(),b.mergeAttributes&&b.mergeAttributes(a),c=b.nodeName.toLowerCase(),c==="object"?b.outerHTML=a.outerHTML:c!=="input"||a.type!=="checkbox"&&a.type!=="radio"?c==="option"?b.selected=a.defaultSelected:c==="input"||c==="textarea"?b.defaultValue=a.defaultValue:c==="script"&&b.text!==a.text&&(b.text=a.text):(a.checked&&(b.defaultChecked=b.checked=a.checked),b.value!==a.value&&(b.value=a.value)),b.removeAttribute(f.expando),b.removeAttribute("_submit_attached"),b.removeAttribute("_change_attached")}function lb(a){return typeof a.getElementsByTagName!="undefined"?a.getElementsByTagName("*"):typeof a.querySelectorAll!="undefined"?a.querySelectorAll("*"):[]}function mb(a){if(a.type==="checkbox"||a.type==="radio")a.defaultChecked=a.checked}function nb(a){var b=(a.nodeName||"").toLowerCase();b==="input"?mb(a):b!=="script"&&typeof a.getElementsByTagName!="undefined"&&f.grep(a.getElementsByTagName("input"),mb)}function ob(a){var b=c.createElement("div");return hb.appendChild(b),b.innerHTML=a.outerHTML,b.firstChild}function Bb(a,b,c){var d=b==="width"?a.offsetWidth:a.offsetHeight,e=b==="width"?1:0,g=4;if(d>0){if(c!=="border")for(;e<g;e+=2)c||(d-=parseFloat(f.css(a,"padding"+xb[e]))||0),c==="margin"?d+=parseFloat(f.css(a,c+xb[e]))||0:d-=parseFloat(f.css(a,"border"+xb[e]+"Width"))||0;return d+"px"}d=yb(a,b);if(d<0||d==null)d=a.style[b];if(tb.test(d))return d;d=parseFloat(d)||0;if(c)for(;e<g;e+=2)d+=parseFloat(f.css(a,"padding"+xb[e]))||0,c!=="padding"&&(d+=parseFloat(f.css(a,"border"+xb[e]+"Width"))||0),c==="margin"&&(d+=parseFloat(f.css(a,c+xb[e]))||0);return d+"px"}function Yb(a){return function(b,c){typeof b!="string"&&(c=b,b="*");if(f.isFunction(c)){var d=b.toLowerCase().split(Ob),e=0,g=d.length,h,i,j;for(;e<g;e++)h=d[e],j=/^\+/.test(h),j&&(h=h.substr(1)||"*"),i=a[h]=a[h]||[],i[j?"unshift":"push"](c)}}}function Zb(a,c,d,e,f,g){f=f||c.dataTypes[0],g=g||{},g[f]=!0;var h=a[f],i=0,j=h?h.length:0,k=a===Sb,l;for(;i<j&&(k||!l);i++)l=h[i](c,d,e),typeof l=="string"&&(!k||g[l]?l=b:(c.dataTypes.unshift(l),l=Zb(a,c,d,e,l,g)));return(k||!l)&&!g["*"]&&(l=Zb(a,c,d,e,"*",g)),l}function $b(a,c){var d,e,g=f.ajaxSettings.flatOptions||{};for(d in c)c[d]!==b&&((g[d]?a:e||(e={}))[d]=c[d]);e&&f.extend(!0,a,e)}function _b(a,b,c,d){if(f.isArray(b))f.each(b,function(b,e){c||Db.test(a)?d(a,e):_b(a+"["+(typeof e=="object"?b:"")+"]",e,c,d)});else if(!c&&f.type(b)==="object")for(var e in b)_b(a+"["+e+"]",b[e],c,d);else d(a,b)}function ac(a,c,d){var e=a.contents,f=a.dataTypes,g=a.responseFields,h,i,j,k;for(i in g)i in d&&(c[g[i]]=d[i]);while(f[0]==="*")f.shift(),h===b&&(h=a.mimeType||c.getResponseHeader("content-type"));if(h)for(i in e)if(e[i]&&e[i].test(h)){f.unshift(i);break}if(f[0]in d)j=f[0];else{for(i in d){if(!f[0]||a.converters[i+" "+f[0]]){j=i;break}k||(k=i)}j=j||k}if(j)return j!==f[0]&&f.unshift(j),d[j]}function bc(a,c){a.dataFilter&&(c=a.dataFilter(c,a.dataType));var d=a.dataTypes,e={},g,h,i=d.length,j,k=d[0],l,m,n,o,p;for(g=1;g<i;g++){if(g===1)for(h in a.converters)typeof h=="string"&&(e[h.toLowerCase()]=a.converters[h]);l=k,k=d[g];if(k==="*")k=l;else if(l!=="*"&&l!==k){m=l+" "+k,n=e[m]||e["* "+k];if(!n){p=b;for(o in e){j=o.split(" ");if(j[0]===l||j[0]==="*"){p=e[j[1]+" "+k];if(p){o=e[o],o===!0?n=p:p===!0&&(n=o);break}}}}!n&&!p&&f.error("No conversion from "+m.replace(" "," to ")),n!==!0&&(c=n?n(c):p(o(c)))}}return c}function hc(){try{return new a.XMLHttpRequest}catch(b){}}function ic(){try{return new a.ActiveXObject("Microsoft.XMLHTTP")}catch(b){}}function rc(){return setTimeout(sc,0),qc=f.now()}function sc(){qc=b}function tc(a,b){var c={};return f.each(pc.concat.apply([],pc.slice(0,b)),function(){c[this]=a}),c}function uc(a){if(!jc[a]){var b=c.body,d=f("<"+a+">").appendTo(b),e=d.css("display");d.remove();if(e==="none"||e===""){kc||(kc=c.createElement("iframe"),kc.frameBorder=kc.width=kc.height=0),b.appendChild(kc);if(!lc||!kc.createElement)lc=(kc.contentWindow||kc.contentDocument).document,lc.write((f.support.boxModel?"<!doctype html>":"")+"<html><body>"),lc.close();d=lc.createElement(a),lc.body.appendChild(d),e=f.css(d,"display"),b.removeChild(kc)}jc[a]=e}return jc[a]}function yc(a){return f.isWindow(a)?a:a.nodeType===9?a.defaultView||a.parentWindow:!1}var c=a.document,d=a.navigator,e=a.location,f=function(){function J(){if(e.isReady)return;try{c.documentElement.doScroll("left")}catch(a){setTimeout(J,1);return}e.ready()}var e=function(a,b){return new e.fn.init(a,b,h)},f=a.jQuery,g=a.$,h,i=/^(?:[^#<]*(<[\w\W]+>)[^>]*$|#([\w\-]*)$)/,j=/\S/,k=/^\s+/,l=/\s+$/,m=/^<(\w+)\s*\/?>(?:<\/\1>)?$/,n=/^[\],:{}\s]*$/,o=/\\(?:["\\\/bfnrt]|u[0-9a-fA-F]{4})/g,p=/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,q=/(?:^|:|,)(?:\s*\[)+/g,r=/(webkit)[ \/]([\w.]+)/,s=/(opera)(?:.*version)?[ \/]([\w.]+)/,t=/(msie) ([\w.]+)/,u=/(mozilla)(?:.*? rv:([\w.]+))?/,v=/-([a-z]|[0-9])/ig,w=/^-ms-/,x=function(a,b){return(b+"").toUpperCase()},y=d.userAgent,z,A,B,C=Object.prototype.toString,D=Object.prototype.hasOwnProperty,E=Array.prototype.push,F=Array.prototype.slice,G=String.prototype.trim,H=Array.prototype.indexOf,I={};return e.fn=e.prototype={constructor:e,init:function(a,d,f){var g,h,j,k;if(!a)return this;if(a.nodeType)return this.context=this[0]=a,this.length=1,this;if(a==="body"&&!d&&c.body)return this.context=c,this[0]=c.body,this.selector=a,this.length=1,this;if(typeof a=="string"){a.charAt(0)==="<"&&a.charAt(a.length-1)===">"&&a.length>=3?g=[null,a,null]:g=i.exec(a);if(g&&(g[1]||!d)){if(g[1])return d=d instanceof e?d[0]:d,k=d?d.ownerDocument||d:c,j=m.exec(a),j?e.isPlainObject(d)?(a=[c.createElement(j[1])],e.fn.attr.call(a,d,!0)):a=[k.createElement(j[1])]:(j=e.buildFragment([g[1]],[k]),a=(j.cacheable?e.clone(j.fragment):j.fragment).childNodes),e.merge(this,a);h=c.getElementById(g[2]);if(h&&h.parentNode){if(h.id!==g[2])return f.find(a);this.length=1,this[0]=h}return this.context=c,this.selector=a,this}return!d||d.jquery?(d||f).find(a):this.constructor(d).find(a)}return e.isFunction(a)?f.ready(a):(a.selector!==b&&(this.selector=a.selector,this.context=a.context),e.makeArray(a,this))},selector:"",jquery:"1.7.2",length:0,size:function(){return this.length},toArray:function(){return F.call(this,0)},get:function(a){return a==null?this.toArray():a<0?this[this.length+a]:this[a]},pushStack:function(a,b,c){var d=this.constructor();return e.isArray(a)?E.apply(d,a):e.merge(d,a),d.prevObject=this,d.context=this.context,b==="find"?d.selector=this.selector+(this.selector?" ":"")+c:b&&(d.selector=this.selector+"."+b+"("+c+")"),d},each:function(a,b){return e.each(this,a,b)},ready:function(a){return e.bindReady(),A.add(a),this},eq:function(a){return a=+a,a===-1?this.slice(a):this.slice(a,a+1)},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},slice:function(){return this.pushStack(F.apply(this,arguments),"slice",F.call(arguments).join(","))},map:function(a){return this.pushStack(e.map(this,function(b,c){return a.call(b,c,b)}))},end:function(){return this.prevObject||this.constructor(null)},push:E,sort:[].sort,splice:[].splice},e.fn.init.prototype=e.fn,e.extend=e.fn.extend=function(){var a,c,d,f,g,h,i=arguments[0]||{},j=1,k=arguments.length,l=!1;typeof i=="boolean"&&(l=i,i=arguments[1]||{},j=2),typeof i!="object"&&!e.isFunction(i)&&(i={}),k===j&&(i=this,--j);for(;j<k;j++)if((a=arguments[j])!=null)for(c in a){d=i[c],f=a[c];if(i===f)continue;l&&f&&(e.isPlainObject(f)||(g=e.isArray(f)))?(g?(g=!1,h=d&&e.isArray(d)?d:[]):h=d&&e.isPlainObject(d)?d:{},i[c]=e.extend(l,h,f)):f!==b&&(i[c]=f)}return i},e.extend({noConflict:function(b){return a.$===e&&(a.$=g),b&&a.jQuery===e&&(a.jQuery=f),e},isReady:!1,readyWait:1,holdReady:function(a){a?e.readyWait++:e.ready(!0)},ready:function(a){if(a===!0&&!--e.readyWait||a!==!0&&!e.isReady){if(!c.body)return setTimeout(e.ready,1);e.isReady=!0;if(a!==!0&&--e.readyWait>0)return;A.fireWith(c,[e]),e.fn.trigger&&e(c).trigger("ready").off("ready")}},bindReady:function(){if(A)return;A=e.Callbacks("once memory");if(c.readyState==="complete")return setTimeout(e.ready,1);if(c.addEventListener)c.addEventListener("DOMContentLoaded",B,!1),a.addEventListener("load",e.ready,!1);else if(c.attachEvent){c.attachEvent("onreadystatechange",B),a.attachEvent("onload",e.ready);var b=!1;try{b=a.frameElement==null}catch(d){}c.documentElement.doScroll&&b&&J()}},isFunction:function(a){return e.type(a)==="function"},isArray:Array.isArray||function(a){return e.type(a)==="array"},isWindow:function(a){return a!=null&&a==a.window},isNumeric:function(a){return!isNaN(parseFloat(a))&&isFinite(a)},type:function(a){return a==null?String(a):I[C.call(a)]||"object"},isPlainObject:function(a){if(!a||e.type(a)!=="object"||a.nodeType||e.isWindow(a))return!1;try{if(a.constructor&&!D.call(a,"constructor")&&!D.call(a.constructor.prototype,"isPrototypeOf"))return!1}catch(c){return!1}var d;for(d in a);return d===b||D.call(a,d)},isEmptyObject:function(a){for(var b in a)return!1;return!0},error:function(a){throw new Error(a)},parseJSON:function(b){if(typeof b!="string"||!b)return null;b=e.trim(b);if(a.JSON&&a.JSON.parse)return a.JSON.parse(b);if(n.test(b.replace(o,"@").replace(p,"]").replace(q,"")))return(new Function("return "+b))();e.error("Invalid JSON: "+b)},parseXML:function(c){if(typeof c!="string"||!c)return null;var d,f;try{a.DOMParser?(f=new DOMParser,d=f.parseFromString(c,"text/xml")):(d=new ActiveXObject("Microsoft.XMLDOM"),d.async="false",d.loadXML(c))}catch(g){d=b}return(!d||!d.documentElement||d.getElementsByTagName("parsererror").length)&&e.error("Invalid XML: "+c),d},noop:function(){},globalEval:function(b){b&&j.test(b)&&(a.execScript||function(b){a.eval.call(a,b)})(b)},camelCase:function(a){return a.replace(w,"ms-").replace(v,x)},nodeName:function(a,b){return a.nodeName&&a.nodeName.toUpperCase()===b.toUpperCase()},each:function(a,c,d){var f,g=0,h=a.length,i=h===b||e.isFunction(a);if(d){if(i){for(f in a)if(c.apply(a[f],d)===!1)break}else for(;g<h;)if(c.apply(a[g++],d)===!1)break}else if(i){for(f in a)if(c.call(a[f],f,a[f])===!1)break}else for(;g<h;)if(c.call(a[g],g,a[g++])===!1)break;return a},trim:G?function(a){return a==null?"":G.call(a)}:function(a){return a==null?"":a.toString().replace(k,"").replace(l,"")},makeArray:function(a,b){var c=b||[];if(a!=null){var d=e.type(a);a.length==null||d==="string"||d==="function"||d==="regexp"||e.isWindow(a)?E.call(c,a):e.merge(c,a)}return c},inArray:function(a,b,c){var d;if(b){if(H)return H.call(b,a,c);d=b.length,c=c?c<0?Math.max(0,d+c):c:0;for(;c<d;c++)if(c in b&&b[c]===a)return c}return-1},merge:function(a,c){var d=a.length,e=0;if(typeof c.length=="number")for(var f=c.length;e<f;e++)a[d++]=c[e];else while(c[e]!==b)a[d++]=c[e++];return a.length=d,a},grep:function(a,b,c){var d=[],e;c=!!c;for(var f=0,g=a.length;f<g;f++)e=!!b(a[f],f),c!==e&&d.push(a[f]);return d},map:function(a,c,d){var f,g,h=[],i=0,j=a.length,k=a instanceof e||j!==b&&typeof j=="number"&&(j>0&&a[0]&&a[j-1]||j===0||e.isArray(a));if(k)for(;i<j;i++)f=c(a[i],i,d),f!=null&&(h[h.length]=f);else for(g in a)f=c(a[g],g,d),f!=null&&(h[h.length]=f);return h.concat.apply([],h)},guid:1,proxy:function(a,c){if(typeof c=="string"){var d=a[c];c=a,a=d}if(!e.isFunction(a))return b;var f=F.call(arguments,2),g=function(){return a.apply(c,f.concat(F.call(arguments)))};return g.guid=a.guid=a.guid||g.guid||e.guid++,g},access:function(a,c,d,f,g,h,i){var j,k=d==null,l=0,m=a.length;if(d&&typeof d=="object"){for(l in d)e.access(a,c,l,d[l],1,h,f);g=1}else if(f!==b){j=i===b&&e.isFunction(f),k&&(j?(j=c,c=function(a,b,c){return j.call(e(a),c)}):(c.call(a,f),c=null));if(c)for(;l<m;l++)c(a[l],d,j?f.call(a[l],l,c(a[l],d)):f,i);g=1}return g?a:k?c.call(a):m?c(a[0],d):h},now:function(){return(new Date).getTime()},uaMatch:function(a){a=a.toLowerCase();var b=r.exec(a)||s.exec(a)||t.exec(a)||a.indexOf("compatible")<0&&u.exec(a)||[];return{browser:b[1]||"",version:b[2]||"0"}},sub:function(){function a(b,c){return new a.fn.init(b,c)}e.extend(!0,a,this),a.superclass=this,a.fn=a.prototype=this(),a.fn.constructor=a,a.sub=this.sub,a.fn.init=function(d,f){return f&&f instanceof e&&!(f instanceof a)&&(f=a(f)),e.fn.init.call(this,d,f,b)},a.fn.init.prototype=a.fn;var b=a(c);return a},browser:{}}),e.each("Boolean Number String Function Array Date RegExp Object".split(" "),function(a,b){I["[object "+b+"]"]=b.toLowerCase()}),z=e.uaMatch(y),z.browser&&(e.browser[z.browser]=!0,e.browser.version=z.version),e.browser.webkit&&(e.browser.safari=!0),j.test(" ")&&(k=/^[\s\xA0]+/,l=/[\s\xA0]+$/),h=e(c),c.addEventListener?B=function(){c.removeEventListener("DOMContentLoaded",B,!1),e.ready()}:c.attachEvent&&(B=function(){c.readyState==="complete"&&(c.detachEvent("onreadystatechange",B),e.ready())}),e}(),g={};f.Callbacks=function(a){a=a?g[a]||h(a):{};var c=[],d=[],e,i,j,k,l,m,n=function(b){var d,e,g,h,i;for(d=0,e=b.length;d<e;d++)g=b[d],h=f.type(g),h==="array"?n(g):h==="function"&&(!a.unique||!p.has(g))&&c.push(g)},o=function(b,f){f=f||[],e=!a.memory||[b,f],i=!0,j=!0,m=k||0,k=0,l=c.length;for(;c&&m<l;m++)if(c[m].apply(b,f)===!1&&a.stopOnFalse){e=!0;break}j=!1,c&&(a.once?e===!0?p.disable():c=[]:d&&d.length&&(e=d.shift(),p.fireWith(e[0],e[1])))},p={add:function(){if(c){var a=c.length;n(arguments),j?l=c.length:e&&e!==!0&&(k=a,o(e[0],e[1]))}return this},remove:function(){if(c){var b=arguments,d=0,e=b.length;for(;d<e;d++)for(var f=0;f<c.length;f++)if(b[d]===c[f]){j&&f<=l&&(l--,f<=m&&m--),c.splice(f--,1);if(a.unique)break}}return this},has:function(a){if(c){var b=0,d=c.length;for(;b<d;b++)if(a===c[b])return!0}return!1},empty:function(){return c=[],this},disable:function(){return c=d=e=b,this},disabled:function(){return!c},lock:function(){return d=b,(!e||e===!0)&&p.disable(),this},locked:function(){return!d},fireWith:function(b,c){return d&&(j?a.once||d.push([b,c]):(!a.once||!e)&&o(b,c)),this},fire:function(){return p.fireWith(this,arguments),this},fired:function(){return!!i}};return p};var i=[].slice;f.extend({Deferred:function(a){var b=f.Callbacks("once memory"),c=f.Callbacks("once memory"),d=f.Callbacks("memory"),e="pending",g={resolve:b,reject:c,notify:d},h={done:b.add,fail:c.add,progress:d.add,state:function(){return e},isResolved:b.fired,isRejected:c.fired,then:function(a,b,c){return i.done(a).fail(b).progress(c),this},always:function(){return i.done.apply(i,arguments).fail.apply(i,arguments),this},pipe:function(a,b,c){return f.Deferred(function(d){f.each({done:[a,"resolve"],fail:[b,"reject"],progress:[c,"notify"]},function(a,b){var c=b[0],e=b[1],g;f.isFunction(c)?i[a](function(){g=c.apply(this,arguments),g&&f.isFunction(g.promise)?g.promise().then(d.resolve,d.reject,d.notify):d[e+"With"](this===i?d:this,[g])}):i[a](d[e])})}).promise()},promise:function(a){if(a==null)a=h;else for(var b in h)a[b]=h[b];return a}},i=h.promise({}),j;for(j in g)i[j]=g[j].fire,i[j+"With"]=g[j].fireWith;return i.done(function(){e="resolved"},c.disable,d.lock).fail(function(){e="rejected"},b.disable,d.lock),a&&a.call(i,i),i},when:function(a){function l(a){return function(c){b[a]=arguments.length>1?i.call(arguments,0):c,--g||j.resolveWith(j,b)}}function m(a){return function(b){e[a]=arguments.length>1?i.call(arguments,0):b,j.notifyWith(k,e)}}var b=i.call(arguments,0),c=0,d=b.length,e=new Array(d),g=d,h=d,j=d<=1&&a&&f.isFunction(a.promise)?a:f.Deferred(),k=j.promise();if(d>1){for(;c<d;c++)b[c]&&b[c].promise&&f.isFunction(b[c].promise)?b[c].promise().then(l(c),j.reject,m(c)):--g;g||j.resolveWith(j,b)}else j!==a&&j.resolveWith(j,d?[a]:[]);return k}}),f.support=function(){var b,d,e,g,h,i,j,k,l,m,n,o,p=c.createElement("div"),q=c.documentElement;p.setAttribute("className","t"),p.innerHTML=" <link/><table></table><a href='/a' style='top:1px;float:left;opacity:.55;'>a</a><input type='checkbox'/>",d=p.getElementsByTagName("*"),e=p.getElementsByTagName("a")[0];if(!d||!d.length||!e)return{};g=c.createElement("select"),h=g.appendChild(c.createElement("option")),i=p.getElementsByTagName("input")[0],b={leadingWhitespace:p.firstChild.nodeType===3,tbody:!p.getElementsByTagName("tbody").length,htmlSerialize:!!p.getElementsByTagName("link").length,style:/top/.test(e.getAttribute("style")),hrefNormalized:e.getAttribute("href")==="/a",opacity:/^0.55/.test(e.style.opacity),cssFloat:!!e.style.cssFloat,checkOn:i.value==="on",optSelected:h.selected,getSetAttribute:p.className!=="t",enctype:!!c.createElement("form").enctype,html5Clone:c.createElement("nav").cloneNode(!0).outerHTML!=="<:nav></:nav>",submitBubbles:!0,changeBubbles:!0,focusinBubbles:!1,deleteExpando:!0,noCloneEvent:!0,inlineBlockNeedsLayout:!1,shrinkWrapBlocks:!1,reliableMarginRight:!0,pixelMargin:!0},f.boxModel=b.boxModel=c.compatMode==="CSS1Compat",i.checked=!0,b.noCloneChecked=i.cloneNode(!0).checked,g.disabled=!0,b.optDisabled=!h.disabled;try{delete p.test}catch(r){b.deleteExpando=!1}!p.addEventListener&&p.attachEvent&&p.fireEvent&&(p.attachEvent("onclick",function(){b.noCloneEvent=!1}),p.cloneNode(!0).fireEvent("onclick")),i=c.createElement("input"),i.value="t",i.setAttribute("type","radio"),b.radioValue=i.value==="t",i.setAttribute("checked","checked"),i.setAttribute("name","t"),p.appendChild(i),j=c.createDocumentFragment(),j.appendChild(p.lastChild),b.checkClone=j.cloneNode(!0).cloneNode(!0).lastChild.checked,b.appendChecked=i.checked,j.removeChild(i),j.appendChild(p);if(p.attachEvent)for(n in{submit:1,change:1,focusin:1})m="on"+n,o=m in p,o||(p.setAttribute(m,"return;"),o=typeof p[m]=="function"),b[n+"Bubbles"]=o;return j.removeChild(p),j=g=h=p=i=null,f(function(){var d,e,g,h,i,j,l,m,n,q,r,s,t,u=c.getElementsByTagName("body")[0];if(!u)return;m=1,t="padding:0;margin:0;border:",r="position:absolute;top:0;left:0;width:1px;height:1px;",s=t+"0;visibility:hidden;",n="style='"+r+t+"5px solid #000;",q="<div "+n+"display:block;'><div style='"+t+"0;display:block;overflow:hidden;'></div></div>"+"<table "+n+"' cellpadding='0' cellspacing='0'>"+"<tr><td></td></tr></table>",d=c.createElement("div"),d.style.cssText=s+"width:0;height:0;position:static;top:0;margin-top:"+m+"px",u.insertBefore(d,u.firstChild),p=c.createElement("div"),d.appendChild(p),p.innerHTML="<table><tr><td style='"+t+"0;display:none'></td><td>t</td></tr></table>",k=p.getElementsByTagName("td"),o=k[0].offsetHeight===0,k[0].style.display="",k[1].style.display="none",b.reliableHiddenOffsets=o&&k[0].offsetHeight===0,a.getComputedStyle&&(p.innerHTML="",l=c.createElement("div"),l.style.width="0",l.style.marginRight="0",p.style.width="2px",p.appendChild(l),b.reliableMarginRight=(parseInt((a.getComputedStyle(l,null)||{marginRight:0}).marginRight,10)||0)===0),typeof p.style.zoom!="undefined"&&(p.innerHTML="",p.style.width=p.style.padding="1px",p.style.border=0,p.style.overflow="hidden",p.style.display="inline",p.style.zoom=1,b.inlineBlockNeedsLayout=p.offsetWidth===3,p.style.display="block",p.style.overflow="visible",p.innerHTML="<div style='width:5px;'></div>",b.shrinkWrapBlocks=p.offsetWidth!==3),p.style.cssText=r+s,p.innerHTML=q,e=p.firstChild,g=e.firstChild,i=e.nextSibling.firstChild.firstChild,j={doesNotAddBorder:g.offsetTop!==5,doesAddBorderForTableAndCells:i.offsetTop===5},g.style.position="fixed",g.style.top="20px",j.fixedPosition=g.offsetTop===20||g.offsetTop===15,g.style.position=g.style.top="",e.style.overflow="hidden",e.style.position="relative",j.subtractsBorderForOverflowNotVisible=g.offsetTop===-5,j.doesNotIncludeMarginInBodyOffset=u.offsetTop!==m,a.getComputedStyle&&(p.style.marginTop="1%",b.pixelMargin=(a.getComputedStyle(p,null)||{marginTop:0}).marginTop!=="1%"),typeof d.style.zoom!="undefined"&&(d.style.zoom=1),u.removeChild(d),l=p=d=null,f.extend(b,j)}),b}();var j=/^(?:\{.*\}|\[.*\])$/,k=/([A-Z])/g;f.extend({cache:{},uuid:0,expando:"jQuery"+(f.fn.jquery+Math.random()).replace(/\D/g,""),noData:{embed:!0,object:"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000",applet:!0},hasData:function(a){return a=a.nodeType?f.cache[a[f.expando]]:a[f.expando],!!a&&!m(a)},data:function(a,c,d,e){if(!f.acceptData(a))return;var g,h,i,j=f.expando,k=typeof c=="string",l=a.nodeType,m=l?f.cache:a,n=l?a[j]:a[j]&&j,o=c==="events";if((!n||!m[n]||!o&&!e&&!m[n].data)&&k&&d===b)return;n||(l?a[j]=n=++f.uuid:n=j),m[n]||(m[n]={},l||(m[n].toJSON=f.noop));if(typeof c=="object"||typeof c=="function")e?m[n]=f.extend(m[n],c):m[n].data=f.extend(m[n].data,c);return g=h=m[n],e||(h.data||(h.data={}),h=h.data),d!==b&&(h[f.camelCase(c)]=d),o&&!h[c]?g.events:(k?(i=h[c],i==null&&(i=h[f.camelCase(c)])):i=h,i)},removeData:function(a,b,c){if(!f.acceptData(a))return;var d,e,g,h=f.expando,i=a.nodeType,j=i?f.cache:a,k=i?a[h]:h;if(!j[k])return;if(b){d=c?j[k]:j[k].data;if(d){f.isArray(b)||(b in d?b=[b]:(b=f.camelCase(b),b in d?b=[b]:b=b.split(" ")));for(e=0,g=b.length;e<g;e++)delete d[b[e]];if(!(c?m:f.isEmptyObject)(d))return}}if(!c){delete j[k].data;if(!m(j[k]))return}f.support.deleteExpando||!j.setInterval?delete j[k]:j[k]=null,i&&(f.support.deleteExpando?delete a[h]:a.removeAttribute?a.removeAttribute(h):a[h]=null)},_data:function(a,b,c){return f.data(a,b,c,!0)},acceptData:function(a){if(a.nodeName){var b=f.noData[a.nodeName.toLowerCase()];if(b)return b!==!0&&a.getAttribute("classid")===b}return!0}}),f.fn.extend({data:function(a,c){var d,e,g,h,i,j=this[0],k=0,m=null;if(a===b){if(this.length){m=f.data(j);if(j.nodeType===1&&!f._data(j,"parsedAttrs")){g=j.attributes;for(i=g.length;k<i;k++)h=g[k].name,h.indexOf("data-")===0&&(h=f.camelCase(h.substring(5)),l(j,h,m[h]));f._data(j,"parsedAttrs",!0)}}return m}return typeof a=="object"?this.each(function(){f.data(this,a)}):(d=a.split(".",2),d[1]=d[1]?"."+d[1]:"",e=d[1]+"!",f.access(this,function(c){if(c===b)return m=this.triggerHandler("getData"+e,[d[0]]),m===b&&j&&(m=f.data(j,a),m=l(j,a,m)),m===b&&d[1]?this.data(d[0]):m;d[1]=c,this.each(function(){var b=f(this);b.triggerHandler("setData"+e,d),f.data(this,a,c),b.triggerHandler("changeData"+e,d)})},null,c,arguments.length>1,null,!1))},removeData:function(a){return this.each(function(){f.removeData(this,a)})}}),f.extend({_mark:function(a,b){a&&(b=(b||"fx")+"mark",f._data(a,b,(f._data(a,b)||0)+1))},_unmark:function(a,b,c){a!==!0&&(c=b,b=a,a=!1);if(b){c=c||"fx";var d=c+"mark",e=a?0:(f._data(b,d)||1)-1;e?f._data(b,d,e):(f.removeData(b,d,!0),n(b,c,"mark"))}},queue:function(a,b,c){var d;if(a)return b=(b||"fx")+"queue",d=f._data(a,b),c&&(!d||f.isArray(c)?d=f._data(a,b,f.makeArray(c)):d.push(c)),d||[]},dequeue:function(a,b){b=b||"fx";var c=f.queue(a,b),d=c.shift(),e={};d==="inprogress"&&(d=c.shift()),d&&(b==="fx"&&c.unshift("inprogress"),f._data(a,b+".run",e),d.call(a,function(){f.dequeue(a,b)},e)),c.length||(f.removeData(a,b+"queue "+b+".run",!0),n(a,b,"queue"))}}),f.fn.extend({queue:function(a,c){var d=2;return typeof a!="string"&&(c=a,a="fx",d--),arguments.length<d?f.queue(this[0],a):c===b?this:this.each(function(){var b=f.queue(this,a,c);a==="fx"&&b[0]!=="inprogress"&&f.dequeue(this,a)})},dequeue:function(a){return this.each(function(){f.dequeue(this,a)})},delay:function(a,b){return a=f.fx?f.fx.speeds[a]||a:a,b=b||"fx",this.queue(b,function(b,c){var d=setTimeout(b,a);c.stop=function(){clearTimeout(d)}})},clearQueue:function(a){return this.queue(a||"fx",[])},promise:function(a,c){function m(){--h||d.resolveWith(e,[e])}typeof a!="string"&&(c=a,a=b),a=a||"fx";var d=f.Deferred(),e=this,g=e.length,h=1,i=a+"defer",j=a+"queue",k=a+"mark",l;while(g--)if(l=f.data(e[g],i,b,!0)||(f.data(e[g],j,b,!0)||f.data(e[g],k,b,!0))&&f.data(e[g],i,f.Callbacks("once memory"),!0))h++,l.add(m);return m(),d.promise(c)}});var o=/[\n\t\r]/g,p=/\s+/,q=/\r/g,r=/^(?:button|input)$/i,s=/^(?:button|input|object|select|textarea)$/i,t=/^a(?:rea)?$/i,u=/^(?:autofocus|autoplay|async|checked|controls|defer|disabled|hidden|loop|multiple|open|readonly|required|scoped|selected)$/i,v=f.support.getSetAttribute,w,x,y;f.fn.extend({attr:function(a,b){return f.access(this,f.attr,a,b,arguments.length>1)},removeAttr:function(a){return this.each(function(){f.removeAttr(this,a)})},prop:function(a,b){return f.access(this,f.prop,a,b,arguments.length>1)},removeProp:function(a){return a=f.propFix[a]||a,this.each(function(){try{this[a]=b,delete this[a]}catch(c){}})},addClass:function(a){var b,c,d,e,g,h,i;if(f.isFunction(a))return this.each(function(b){f(this).addClass(a.call(this,b,this.className))});if(a&&typeof a=="string"){b=a.split(p);for(c=0,d=this.length;c<d;c++){e=this[c];if(e.nodeType===1)if(!e.className&&b.length===1)e.className=a;else{g=" "+e.className+" ";for(h=0,i=b.length;h<i;h++)~g.indexOf(" "+b[h]+" ")||(g+=b[h]+" ");e.className=f.trim(g)}}}return this},removeClass:function(a){var c,d,e,g,h,i,j;if(f.isFunction(a))return this.each(function(b){f(this).removeClass(a.call(this,b,this.className))});if(a&&typeof a=="string"||a===b){c=(a||"").split(p);for(d=0,e=this.length;d<e;d++){g=this[d];if(g.nodeType===1&&g.className)if(a){h=(" "+g.className+" ").replace(o," ");for(i=0,j=c.length;i<j;i++)h=h.replace(" "+c[i]+" "," ");g.className=f.trim(h)}else g.className=""}}return this},toggleClass:function(a,b){var c=typeof a,d=typeof b=="boolean";return f.isFunction(a)?this.each(function(c){f(this).toggleClass(a.call(this,c,this.className,b),b)}):this.each(function(){if(c==="string"){var e,g=0,h=f(this),i=b,j=a.split(p);while(e=j[g++])i=d?i:!h.hasClass(e),h[i?"addClass":"removeClass"](e)}else if(c==="undefined"||c==="boolean")this.className&&f._data(this,"__className__",this.className),this.className=this.className||a===!1?"":f._data(this,"__className__")||""})},hasClass:function(a){var b=" "+a+" ",c=0,d=this.length;for(;c<d;c++)if(this[c].nodeType===1&&(" "+this[c].className+" ").replace(o," ").indexOf(b)>-1)return!0;return!1},val:function(a){var c,d,e,g=this[0];if(!arguments.length){if(g)return c=f.valHooks[g.type]||f.valHooks[g.nodeName.toLowerCase()],c&&"get"in c&&(d=c.get(g,"value"))!==b?d:(d=g.value,typeof d=="string"?d.replace(q,""):d==null?"":d);return}return e=f.isFunction(a),this.each(function(d){var g=f(this),h;if(this.nodeType!==1)return;e?h=a.call(this,d,g.val()):h=a,h==null?h="":typeof h=="number"?h+="":f.isArray(h)&&(h=f.map(h,function(a){return a==null?"":a+""})),c=f.valHooks[this.type]||f.valHooks[this.nodeName.toLowerCase()];if(!c||!("set"in c)||c.set(this,h,"value")===b)this.value=h})}}),f.extend({valHooks:{option:{get:function(a){var b=a.attributes.value;return!b||b.specified?a.value:a.text}},select:{get:function(a){var b,c,d,e,g=a.selectedIndex,h=[],i=a.options,j=a.type==="select-one";if(g<0)return null;c=j?g:0,d=j?g+1:i.length;for(;c<d;c++){e=i[c];if(e.selected&&(f.support.optDisabled?!e.disabled:e.getAttribute("disabled")===null)&&(!e.parentNode.disabled||!f.nodeName(e.parentNode,"optgroup"))){b=f(e).val();if(j)return b;h.push(b)}}return j&&!h.length&&i.length?f(i[g]).val():h},set:function(a,b){var c=f.makeArray(b);return f(a).find("option").each(function(){this.selected=f.inArray(f(this).val(),c)>=0}),c.length||(a.selectedIndex=-1),c}}},attrFn:{val:!0,css:!0,html:!0,text:!0,data:!0,width:!0,height:!0,offset:!0},attr:function(a,c,d,e){var g,h,i,j=a.nodeType;if(!a||j===3||j===8||j===2)return;if(e&&c in f.attrFn)return f(a)[c](d);if(typeof a.getAttribute=="undefined")return f.prop(a,c,d);i=j!==1||!f.isXMLDoc(a),i&&(c=c.toLowerCase(),h=f.attrHooks[c]||(u.test(c)?x:w));if(d!==b){if(d===null){f.removeAttr(a,c);return}return h&&"set"in h&&i&&(g=h.set(a,d,c))!==b?g:(a.setAttribute(c,""+d),d)}return h&&"get"in h&&i&&(g=h.get(a,c))!==null?g:(g=a.getAttribute(c),g===null?b:g)},removeAttr:function(a,b){var c,d,e,g,h,i=0;if(b&&a.nodeType===1){d=b.toLowerCase().split(p),g=d.length;for(;i<g;i++)e=d[i],e&&(c=f.propFix[e]||e,h=u.test(e),h||f.attr(a,e,""),a.removeAttribute(v?e:c),h&&c in a&&(a[c]=!1))}},attrHooks:{type:{set:function(a,b){if(r.test(a.nodeName)&&a.parentNode)f.error("type property can't be changed");else if(!f.support.radioValue&&b==="radio"&&f.nodeName(a,"input")){var c=a.value;return a.setAttribute("type",b),c&&(a.value=c),b}}},value:{get:function(a,b){return w&&f.nodeName(a,"button")?w.get(a,b):b in a?a.value:null},set:function(a,b,c){if(w&&f.nodeName(a,"button"))return w.set(a,b,c);a.value=b}}},propFix:{tabindex:"tabIndex",readonly:"readOnly","for":"htmlFor","class":"className",maxlength:"maxLength",cellspacing:"cellSpacing",cellpadding:"cellPadding",rowspan:"rowSpan",colspan:"colSpan",usemap:"useMap",frameborder:"frameBorder",contenteditable:"contentEditable"},prop:function(a,c,d){var e,g,h,i=a.nodeType;if(!a||i===3||i===8||i===2)return;return h=i!==1||!f.isXMLDoc(a),h&&(c=f.propFix[c]||c,g=f.propHooks[c]),d!==b?g&&"set"in g&&(e=g.set(a,d,c))!==b?e:a[c]=d:g&&"get"in g&&(e=g.get(a,c))!==null?e:a[c]},propHooks:{tabIndex:{get:function(a){var c=a.getAttributeNode("tabindex");return c&&c.specified?parseInt(c.value,10):s.test(a.nodeName)||t.test(a.nodeName)&&a.href?0:b}}}}),f.attrHooks.tabindex=f.propHooks.tabIndex,x={get:function(a,c){var d,e=f.prop(a,c);return e===!0||typeof e!="boolean"&&(d=a.getAttributeNode(c))&&d.nodeValue!==!1?c.toLowerCase():b},set:function(a,b,c){var d;return b===!1?f.removeAttr(a,c):(d=f.propFix[c]||c,d in a&&(a[d]=!0),a.setAttribute(c,c.toLowerCase())),c}},v||(y={name:!0,id:!0,coords:!0},w=f.valHooks.button={get:function(a,c){var d;return d=a.getAttributeNode(c),d&&(y[c]?d.nodeValue!=="":d.specified)?d.nodeValue:b},set:function(a,b,d){var e=a.getAttributeNode(d);return e||(e=c.createAttribute(d),a.setAttributeNode(e)),e.nodeValue=b+""}},f.attrHooks.tabindex.set=w.set,f.each(["width","height"],function(a,b){f.attrHooks[b]=f.extend(f.attrHooks[b],{set:function(a,c){if(c==="")return a.setAttribute(b,"auto"),c}})}),f.attrHooks.contenteditable={get:w.get,set:function(a,b,c){b===""&&(b="false"),w.set(a,b,c)}}),f.support.hrefNormalized||f.each(["href","src","width","height"],function(a,c){f.attrHooks[c]=f.extend(f.attrHooks[c],{get:function(a){var d=a.getAttribute(c,2);return d===null?b:d}})}),f.support.style||(f.attrHooks.style={get:function(a){return a.style.cssText.toLowerCase()||b},set:function(a,b){return a.style.cssText=""+b}}),f.support.optSelected||(f.propHooks.selected=f.extend(f.propHooks.selected,{get:function(a){var b=a.parentNode;return b&&(b.selectedIndex,b.parentNode&&b.parentNode.selectedIndex),null}})),f.support.enctype||(f.propFix.enctype="encoding"),f.support.checkOn||f.each(["radio","checkbox"],function(){f.valHooks[this]={get:function(a){return a.getAttribute("value")===null?"on":a.value}}}),f.each(["radio","checkbox"],function(){f.valHooks[this]=f.extend(f.valHooks[this],{set:function(a,b){if(f.isArray(b))return a.checked=f.inArray(f(a).val(),b)>=0}})});var z=/^(?:textarea|input|select)$/i,A=/^([^\.]*)?(?:\.(.+))?$/,B=/(?:^|\s)hover(\.\S+)?\b/,C=/^key/,D=/^(?:mouse|contextmenu)|click/,E=/^(?:focusinfocus|focusoutblur)$/,F=/^(\w*)(?:#([\w\-]+))?(?:\.([\w\-]+))?$/,G=function(a){var b=F.exec(a);return b&&(
|
19
|
+
b[1]=(b[1]||"").toLowerCase(),b[3]=b[3]&&new RegExp("(?:^|\\s)"+b[3]+"(?:\\s|$)")),b},H=function(a,b){var c=a.attributes||{};return(!b[1]||a.nodeName.toLowerCase()===b[1])&&(!b[2]||(c.id||{}).value===b[2])&&(!b[3]||b[3].test((c["class"]||{}).value))},I=function(a){return f.event.special.hover?a:a.replace(B,"mouseenter$1 mouseleave$1")};f.event={add:function(a,c,d,e,g){var h,i,j,k,l,m,n,o,p,q,r,s;if(a.nodeType===3||a.nodeType===8||!c||!d||!(h=f._data(a)))return;d.handler&&(p=d,d=p.handler,g=p.selector),d.guid||(d.guid=f.guid++),j=h.events,j||(h.events=j={}),i=h.handle,i||(h.handle=i=function(a){return typeof f=="undefined"||!!a&&f.event.triggered===a.type?b:f.event.dispatch.apply(i.elem,arguments)},i.elem=a),c=f.trim(I(c)).split(" ");for(k=0;k<c.length;k++){l=A.exec(c[k])||[],m=l[1],n=(l[2]||"").split(".").sort(),s=f.event.special[m]||{},m=(g?s.delegateType:s.bindType)||m,s=f.event.special[m]||{},o=f.extend({type:m,origType:l[1],data:e,handler:d,guid:d.guid,selector:g,quick:g&&G(g),namespace:n.join(".")},p),r=j[m];if(!r){r=j[m]=[],r.delegateCount=0;if(!s.setup||s.setup.call(a,e,n,i)===!1)a.addEventListener?a.addEventListener(m,i,!1):a.attachEvent&&a.attachEvent("on"+m,i)}s.add&&(s.add.call(a,o),o.handler.guid||(o.handler.guid=d.guid)),g?r.splice(r.delegateCount++,0,o):r.push(o),f.event.global[m]=!0}a=null},global:{},remove:function(a,b,c,d,e){var g=f.hasData(a)&&f._data(a),h,i,j,k,l,m,n,o,p,q,r,s;if(!g||!(o=g.events))return;b=f.trim(I(b||"")).split(" ");for(h=0;h<b.length;h++){i=A.exec(b[h])||[],j=k=i[1],l=i[2];if(!j){for(j in o)f.event.remove(a,j+b[h],c,d,!0);continue}p=f.event.special[j]||{},j=(d?p.delegateType:p.bindType)||j,r=o[j]||[],m=r.length,l=l?new RegExp("(^|\\.)"+l.split(".").sort().join("\\.(?:.*\\.)?")+"(\\.|$)"):null;for(n=0;n<r.length;n++)s=r[n],(e||k===s.origType)&&(!c||c.guid===s.guid)&&(!l||l.test(s.namespace))&&(!d||d===s.selector||d==="**"&&s.selector)&&(r.splice(n--,1),s.selector&&r.delegateCount--,p.remove&&p.remove.call(a,s));r.length===0&&m!==r.length&&((!p.teardown||p.teardown.call(a,l)===!1)&&f.removeEvent(a,j,g.handle),delete o[j])}f.isEmptyObject(o)&&(q=g.handle,q&&(q.elem=null),f.removeData(a,["events","handle"],!0))},customEvent:{getData:!0,setData:!0,changeData:!0},trigger:function(c,d,e,g){if(!e||e.nodeType!==3&&e.nodeType!==8){var h=c.type||c,i=[],j,k,l,m,n,o,p,q,r,s;if(E.test(h+f.event.triggered))return;h.indexOf("!")>=0&&(h=h.slice(0,-1),k=!0),h.indexOf(".")>=0&&(i=h.split("."),h=i.shift(),i.sort());if((!e||f.event.customEvent[h])&&!f.event.global[h])return;c=typeof c=="object"?c[f.expando]?c:new f.Event(h,c):new f.Event(h),c.type=h,c.isTrigger=!0,c.exclusive=k,c.namespace=i.join("."),c.namespace_re=c.namespace?new RegExp("(^|\\.)"+i.join("\\.(?:.*\\.)?")+"(\\.|$)"):null,o=h.indexOf(":")<0?"on"+h:"";if(!e){j=f.cache;for(l in j)j[l].events&&j[l].events[h]&&f.event.trigger(c,d,j[l].handle.elem,!0);return}c.result=b,c.target||(c.target=e),d=d!=null?f.makeArray(d):[],d.unshift(c),p=f.event.special[h]||{};if(p.trigger&&p.trigger.apply(e,d)===!1)return;r=[[e,p.bindType||h]];if(!g&&!p.noBubble&&!f.isWindow(e)){s=p.delegateType||h,m=E.test(s+h)?e:e.parentNode,n=null;for(;m;m=m.parentNode)r.push([m,s]),n=m;n&&n===e.ownerDocument&&r.push([n.defaultView||n.parentWindow||a,s])}for(l=0;l<r.length&&!c.isPropagationStopped();l++)m=r[l][0],c.type=r[l][1],q=(f._data(m,"events")||{})[c.type]&&f._data(m,"handle"),q&&q.apply(m,d),q=o&&m[o],q&&f.acceptData(m)&&q.apply(m,d)===!1&&c.preventDefault();return c.type=h,!g&&!c.isDefaultPrevented()&&(!p._default||p._default.apply(e.ownerDocument,d)===!1)&&(h!=="click"||!f.nodeName(e,"a"))&&f.acceptData(e)&&o&&e[h]&&(h!=="focus"&&h!=="blur"||c.target.offsetWidth!==0)&&!f.isWindow(e)&&(n=e[o],n&&(e[o]=null),f.event.triggered=h,e[h](),f.event.triggered=b,n&&(e[o]=n)),c.result}return},dispatch:function(c){c=f.event.fix(c||a.event);var d=(f._data(this,"events")||{})[c.type]||[],e=d.delegateCount,g=[].slice.call(arguments,0),h=!c.exclusive&&!c.namespace,i=f.event.special[c.type]||{},j=[],k,l,m,n,o,p,q,r,s,t,u;g[0]=c,c.delegateTarget=this;if(i.preDispatch&&i.preDispatch.call(this,c)===!1)return;if(e&&(!c.button||c.type!=="click")){n=f(this),n.context=this.ownerDocument||this;for(m=c.target;m!=this;m=m.parentNode||this)if(m.disabled!==!0){p={},r=[],n[0]=m;for(k=0;k<e;k++)s=d[k],t=s.selector,p[t]===b&&(p[t]=s.quick?H(m,s.quick):n.is(t)),p[t]&&r.push(s);r.length&&j.push({elem:m,matches:r})}}d.length>e&&j.push({elem:this,matches:d.slice(e)});for(k=0;k<j.length&&!c.isPropagationStopped();k++){q=j[k],c.currentTarget=q.elem;for(l=0;l<q.matches.length&&!c.isImmediatePropagationStopped();l++){s=q.matches[l];if(h||!c.namespace&&!s.namespace||c.namespace_re&&c.namespace_re.test(s.namespace))c.data=s.data,c.handleObj=s,o=((f.event.special[s.origType]||{}).handle||s.handler).apply(q.elem,g),o!==b&&(c.result=o,o===!1&&(c.preventDefault(),c.stopPropagation()))}}return i.postDispatch&&i.postDispatch.call(this,c),c.result},props:"attrChange attrName relatedNode srcElement altKey bubbles cancelable ctrlKey currentTarget eventPhase metaKey relatedTarget shiftKey target timeStamp view which".split(" "),fixHooks:{},keyHooks:{props:"char charCode key keyCode".split(" "),filter:function(a,b){return a.which==null&&(a.which=b.charCode!=null?b.charCode:b.keyCode),a}},mouseHooks:{props:"button buttons clientX clientY fromElement offsetX offsetY pageX pageY screenX screenY toElement".split(" "),filter:function(a,d){var e,f,g,h=d.button,i=d.fromElement;return a.pageX==null&&d.clientX!=null&&(e=a.target.ownerDocument||c,f=e.documentElement,g=e.body,a.pageX=d.clientX+(f&&f.scrollLeft||g&&g.scrollLeft||0)-(f&&f.clientLeft||g&&g.clientLeft||0),a.pageY=d.clientY+(f&&f.scrollTop||g&&g.scrollTop||0)-(f&&f.clientTop||g&&g.clientTop||0)),!a.relatedTarget&&i&&(a.relatedTarget=i===a.target?d.toElement:i),!a.which&&h!==b&&(a.which=h&1?1:h&2?3:h&4?2:0),a}},fix:function(a){if(a[f.expando])return a;var d,e,g=a,h=f.event.fixHooks[a.type]||{},i=h.props?this.props.concat(h.props):this.props;a=f.Event(g);for(d=i.length;d;)e=i[--d],a[e]=g[e];return a.target||(a.target=g.srcElement||c),a.target.nodeType===3&&(a.target=a.target.parentNode),a.metaKey===b&&(a.metaKey=a.ctrlKey),h.filter?h.filter(a,g):a},special:{ready:{setup:f.bindReady},load:{noBubble:!0},focus:{delegateType:"focusin"},blur:{delegateType:"focusout"},beforeunload:{setup:function(a,b,c){f.isWindow(this)&&(this.onbeforeunload=c)},teardown:function(a,b){this.onbeforeunload===b&&(this.onbeforeunload=null)}}},simulate:function(a,b,c,d){var e=f.extend(new f.Event,c,{type:a,isSimulated:!0,originalEvent:{}});d?f.event.trigger(e,null,b):f.event.dispatch.call(b,e),e.isDefaultPrevented()&&c.preventDefault()}},f.event.handle=f.event.dispatch,f.removeEvent=c.removeEventListener?function(a,b,c){a.removeEventListener&&a.removeEventListener(b,c,!1)}:function(a,b,c){a.detachEvent&&a.detachEvent("on"+b,c)},f.Event=function(a,b){if(!(this instanceof f.Event))return new f.Event(a,b);a&&a.type?(this.originalEvent=a,this.type=a.type,this.isDefaultPrevented=a.defaultPrevented||a.returnValue===!1||a.getPreventDefault&&a.getPreventDefault()?K:J):this.type=a,b&&f.extend(this,b),this.timeStamp=a&&a.timeStamp||f.now(),this[f.expando]=!0},f.Event.prototype={preventDefault:function(){this.isDefaultPrevented=K;var a=this.originalEvent;if(!a)return;a.preventDefault?a.preventDefault():a.returnValue=!1},stopPropagation:function(){this.isPropagationStopped=K;var a=this.originalEvent;if(!a)return;a.stopPropagation&&a.stopPropagation(),a.cancelBubble=!0},stopImmediatePropagation:function(){this.isImmediatePropagationStopped=K,this.stopPropagation()},isDefaultPrevented:J,isPropagationStopped:J,isImmediatePropagationStopped:J},f.each({mouseenter:"mouseover",mouseleave:"mouseout"},function(a,b){f.event.special[a]={delegateType:b,bindType:b,handle:function(a){var c=this,d=a.relatedTarget,e=a.handleObj,g=e.selector,h;if(!d||d!==c&&!f.contains(c,d))a.type=e.origType,h=e.handler.apply(this,arguments),a.type=b;return h}}}),f.support.submitBubbles||(f.event.special.submit={setup:function(){if(f.nodeName(this,"form"))return!1;f.event.add(this,"click._submit keypress._submit",function(a){var c=a.target,d=f.nodeName(c,"input")||f.nodeName(c,"button")?c.form:b;d&&!d._submit_attached&&(f.event.add(d,"submit._submit",function(a){a._submit_bubble=!0}),d._submit_attached=!0)})},postDispatch:function(a){a._submit_bubble&&(delete a._submit_bubble,this.parentNode&&!a.isTrigger&&f.event.simulate("submit",this.parentNode,a,!0))},teardown:function(){if(f.nodeName(this,"form"))return!1;f.event.remove(this,"._submit")}}),f.support.changeBubbles||(f.event.special.change={setup:function(){if(z.test(this.nodeName)){if(this.type==="checkbox"||this.type==="radio")f.event.add(this,"propertychange._change",function(a){a.originalEvent.propertyName==="checked"&&(this._just_changed=!0)}),f.event.add(this,"click._change",function(a){this._just_changed&&!a.isTrigger&&(this._just_changed=!1,f.event.simulate("change",this,a,!0))});return!1}f.event.add(this,"beforeactivate._change",function(a){var b=a.target;z.test(b.nodeName)&&!b._change_attached&&(f.event.add(b,"change._change",function(a){this.parentNode&&!a.isSimulated&&!a.isTrigger&&f.event.simulate("change",this.parentNode,a,!0)}),b._change_attached=!0)})},handle:function(a){var b=a.target;if(this!==b||a.isSimulated||a.isTrigger||b.type!=="radio"&&b.type!=="checkbox")return a.handleObj.handler.apply(this,arguments)},teardown:function(){return f.event.remove(this,"._change"),z.test(this.nodeName)}}),f.support.focusinBubbles||f.each({focus:"focusin",blur:"focusout"},function(a,b){var d=0,e=function(a){f.event.simulate(b,a.target,f.event.fix(a),!0)};f.event.special[b]={setup:function(){d++===0&&c.addEventListener(a,e,!0)},teardown:function(){--d===0&&c.removeEventListener(a,e,!0)}}}),f.fn.extend({on:function(a,c,d,e,g){var h,i;if(typeof a=="object"){typeof c!="string"&&(d=d||c,c=b);for(i in a)this.on(i,c,d,a[i],g);return this}d==null&&e==null?(e=c,d=c=b):e==null&&(typeof c=="string"?(e=d,d=b):(e=d,d=c,c=b));if(e===!1)e=J;else if(!e)return this;return g===1&&(h=e,e=function(a){return f().off(a),h.apply(this,arguments)},e.guid=h.guid||(h.guid=f.guid++)),this.each(function(){f.event.add(this,a,e,d,c)})},one:function(a,b,c,d){return this.on(a,b,c,d,1)},off:function(a,c,d){if(a&&a.preventDefault&&a.handleObj){var e=a.handleObj;return f(a.delegateTarget).off(e.namespace?e.origType+"."+e.namespace:e.origType,e.selector,e.handler),this}if(typeof a=="object"){for(var g in a)this.off(g,c,a[g]);return this}if(c===!1||typeof c=="function")d=c,c=b;return d===!1&&(d=J),this.each(function(){f.event.remove(this,a,d,c)})},bind:function(a,b,c){return this.on(a,null,b,c)},unbind:function(a,b){return this.off(a,null,b)},live:function(a,b,c){return f(this.context).on(a,this.selector,b,c),this},die:function(a,b){return f(this.context).off(a,this.selector||"**",b),this},delegate:function(a,b,c,d){return this.on(b,a,c,d)},undelegate:function(a,b,c){return arguments.length==1?this.off(a,"**"):this.off(b,a,c)},trigger:function(a,b){return this.each(function(){f.event.trigger(a,b,this)})},triggerHandler:function(a,b){if(this[0])return f.event.trigger(a,b,this[0],!0)},toggle:function(a){var b=arguments,c=a.guid||f.guid++,d=0,e=function(c){var e=(f._data(this,"lastToggle"+a.guid)||0)%d;return f._data(this,"lastToggle"+a.guid,e+1),c.preventDefault(),b[e].apply(this,arguments)||!1};e.guid=c;while(d<b.length)b[d++].guid=c;return this.click(e)},hover:function(a,b){return this.mouseenter(a).mouseleave(b||a)}}),f.each("blur focus focusin focusout load resize scroll unload click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup error contextmenu".split(" "),function(a,b){f.fn[b]=function(a,c){return c==null&&(c=a,a=null),arguments.length>0?this.on(b,null,a,c):this.trigger(b)},f.attrFn&&(f.attrFn[b]=!0),C.test(b)&&(f.event.fixHooks[b]=f.event.keyHooks),D.test(b)&&(f.event.fixHooks[b]=f.event.mouseHooks)}),function(){function w(a,b,c,e,f,g){for(var h=0,i=e.length;h<i;h++){var j=e[h];if(j){var k=!1;j=j[a];while(j){if(j[d]===c){k=e[j.sizset];break}j.nodeType===1&&!g&&(j[d]=c,j.sizset=h);if(j.nodeName.toLowerCase()===b){k=j;break}j=j[a]}e[h]=k}}}function x(a,b,c,e,f,g){for(var h=0,i=e.length;h<i;h++){var j=e[h];if(j){var k=!1;j=j[a];while(j){if(j[d]===c){k=e[j.sizset];break}if(j.nodeType===1){g||(j[d]=c,j.sizset=h);if(typeof b!="string"){if(j===b){k=!0;break}}else if(m.filter(b,[j]).length>0){k=j;break}}j=j[a]}e[h]=k}}}var a=/((?:\((?:\([^()]+\)|[^()]+)+\)|\[(?:\[[^\[\]]*\]|['"][^'"]*['"]|[^\[\]'"]+)+\]|\\.|[^ >+~,(\[\\]+)+|[>+~])(\s*,\s*)?((?:.|\r|\n)*)/g,d="sizcache"+(Math.random()+"").replace(".",""),e=0,g=Object.prototype.toString,h=!1,i=!0,j=/\\/g,k=/\r\n/g,l=/\W/;[0,0].sort(function(){return i=!1,0});var m=function(b,d,e,f){e=e||[],d=d||c;var h=d;if(d.nodeType!==1&&d.nodeType!==9)return[];if(!b||typeof b!="string")return e;var i,j,k,l,n,q,r,t,u=!0,v=m.isXML(d),w=[],x=b;do{a.exec(""),i=a.exec(x);if(i){x=i[3],w.push(i[1]);if(i[2]){l=i[3];break}}}while(i);if(w.length>1&&p.exec(b))if(w.length===2&&o.relative[w[0]])j=y(w[0]+w[1],d,f);else{j=o.relative[w[0]]?[d]:m(w.shift(),d);while(w.length)b=w.shift(),o.relative[b]&&(b+=w.shift()),j=y(b,j,f)}else{!f&&w.length>1&&d.nodeType===9&&!v&&o.match.ID.test(w[0])&&!o.match.ID.test(w[w.length-1])&&(n=m.find(w.shift(),d,v),d=n.expr?m.filter(n.expr,n.set)[0]:n.set[0]);if(d){n=f?{expr:w.pop(),set:s(f)}:m.find(w.pop(),w.length!==1||w[0]!=="~"&&w[0]!=="+"||!d.parentNode?d:d.parentNode,v),j=n.expr?m.filter(n.expr,n.set):n.set,w.length>0?k=s(j):u=!1;while(w.length)q=w.pop(),r=q,o.relative[q]?r=w.pop():q="",r==null&&(r=d),o.relative[q](k,r,v)}else k=w=[]}k||(k=j),k||m.error(q||b);if(g.call(k)==="[object Array]")if(!u)e.push.apply(e,k);else if(d&&d.nodeType===1)for(t=0;k[t]!=null;t++)k[t]&&(k[t]===!0||k[t].nodeType===1&&m.contains(d,k[t]))&&e.push(j[t]);else for(t=0;k[t]!=null;t++)k[t]&&k[t].nodeType===1&&e.push(j[t]);else s(k,e);return l&&(m(l,h,e,f),m.uniqueSort(e)),e};m.uniqueSort=function(a){if(u){h=i,a.sort(u);if(h)for(var b=1;b<a.length;b++)a[b]===a[b-1]&&a.splice(b--,1)}return a},m.matches=function(a,b){return m(a,null,null,b)},m.matchesSelector=function(a,b){return m(b,null,null,[a]).length>0},m.find=function(a,b,c){var d,e,f,g,h,i;if(!a)return[];for(e=0,f=o.order.length;e<f;e++){h=o.order[e];if(g=o.leftMatch[h].exec(a)){i=g[1],g.splice(1,1);if(i.substr(i.length-1)!=="\\"){g[1]=(g[1]||"").replace(j,""),d=o.find[h](g,b,c);if(d!=null){a=a.replace(o.match[h],"");break}}}}return d||(d=typeof b.getElementsByTagName!="undefined"?b.getElementsByTagName("*"):[]),{set:d,expr:a}},m.filter=function(a,c,d,e){var f,g,h,i,j,k,l,n,p,q=a,r=[],s=c,t=c&&c[0]&&m.isXML(c[0]);while(a&&c.length){for(h in o.filter)if((f=o.leftMatch[h].exec(a))!=null&&f[2]){k=o.filter[h],l=f[1],g=!1,f.splice(1,1);if(l.substr(l.length-1)==="\\")continue;s===r&&(r=[]);if(o.preFilter[h]){f=o.preFilter[h](f,s,d,r,e,t);if(!f)g=i=!0;else if(f===!0)continue}if(f)for(n=0;(j=s[n])!=null;n++)j&&(i=k(j,f,n,s),p=e^i,d&&i!=null?p?g=!0:s[n]=!1:p&&(r.push(j),g=!0));if(i!==b){d||(s=r),a=a.replace(o.match[h],"");if(!g)return[];break}}if(a===q){if(g!=null)break;m.error(a)}q=a}return s},m.error=function(a){throw new Error("Syntax error, unrecognized expression: "+a)};var n=m.getText=function(a){var b,c,d=a.nodeType,e="";if(d){if(d===1||d===9||d===11){if(typeof a.textContent=="string")return a.textContent;if(typeof a.innerText=="string")return a.innerText.replace(k,"");for(a=a.firstChild;a;a=a.nextSibling)e+=n(a)}else if(d===3||d===4)return a.nodeValue}else for(b=0;c=a[b];b++)c.nodeType!==8&&(e+=n(c));return e},o=m.selectors={order:["ID","NAME","TAG"],match:{ID:/#((?:[\w\u00c0-\uFFFF\-]|\\.)+)/,CLASS:/\.((?:[\w\u00c0-\uFFFF\-]|\\.)+)/,NAME:/\[name=['"]*((?:[\w\u00c0-\uFFFF\-]|\\.)+)['"]*\]/,ATTR:/\[\s*((?:[\w\u00c0-\uFFFF\-]|\\.)+)\s*(?:(\S?=)\s*(?:(['"])(.*?)\3|(#?(?:[\w\u00c0-\uFFFF\-]|\\.)*)|)|)\s*\]/,TAG:/^((?:[\w\u00c0-\uFFFF\*\-]|\\.)+)/,CHILD:/:(only|nth|last|first)-child(?:\(\s*(even|odd|(?:[+\-]?\d+|(?:[+\-]?\d*)?n\s*(?:[+\-]\s*\d+)?))\s*\))?/,POS:/:(nth|eq|gt|lt|first|last|even|odd)(?:\((\d*)\))?(?=[^\-]|$)/,PSEUDO:/:((?:[\w\u00c0-\uFFFF\-]|\\.)+)(?:\((['"]?)((?:\([^\)]+\)|[^\(\)]*)+)\2\))?/},leftMatch:{},attrMap:{"class":"className","for":"htmlFor"},attrHandle:{href:function(a){return a.getAttribute("href")},type:function(a){return a.getAttribute("type")}},relative:{"+":function(a,b){var c=typeof b=="string",d=c&&!l.test(b),e=c&&!d;d&&(b=b.toLowerCase());for(var f=0,g=a.length,h;f<g;f++)if(h=a[f]){while((h=h.previousSibling)&&h.nodeType!==1);a[f]=e||h&&h.nodeName.toLowerCase()===b?h||!1:h===b}e&&m.filter(b,a,!0)},">":function(a,b){var c,d=typeof b=="string",e=0,f=a.length;if(d&&!l.test(b)){b=b.toLowerCase();for(;e<f;e++){c=a[e];if(c){var g=c.parentNode;a[e]=g.nodeName.toLowerCase()===b?g:!1}}}else{for(;e<f;e++)c=a[e],c&&(a[e]=d?c.parentNode:c.parentNode===b);d&&m.filter(b,a,!0)}},"":function(a,b,c){var d,f=e++,g=x;typeof b=="string"&&!l.test(b)&&(b=b.toLowerCase(),d=b,g=w),g("parentNode",b,f,a,d,c)},"~":function(a,b,c){var d,f=e++,g=x;typeof b=="string"&&!l.test(b)&&(b=b.toLowerCase(),d=b,g=w),g("previousSibling",b,f,a,d,c)}},find:{ID:function(a,b,c){if(typeof b.getElementById!="undefined"&&!c){var d=b.getElementById(a[1]);return d&&d.parentNode?[d]:[]}},NAME:function(a,b){if(typeof b.getElementsByName!="undefined"){var c=[],d=b.getElementsByName(a[1]);for(var e=0,f=d.length;e<f;e++)d[e].getAttribute("name")===a[1]&&c.push(d[e]);return c.length===0?null:c}},TAG:function(a,b){if(typeof b.getElementsByTagName!="undefined")return b.getElementsByTagName(a[1])}},preFilter:{CLASS:function(a,b,c,d,e,f){a=" "+a[1].replace(j,"")+" ";if(f)return a;for(var g=0,h;(h=b[g])!=null;g++)h&&(e^(h.className&&(" "+h.className+" ").replace(/[\t\n\r]/g," ").indexOf(a)>=0)?c||d.push(h):c&&(b[g]=!1));return!1},ID:function(a){return a[1].replace(j,"")},TAG:function(a,b){return a[1].replace(j,"").toLowerCase()},CHILD:function(a){if(a[1]==="nth"){a[2]||m.error(a[0]),a[2]=a[2].replace(/^\+|\s*/g,"");var b=/(-?)(\d*)(?:n([+\-]?\d*))?/.exec(a[2]==="even"&&"2n"||a[2]==="odd"&&"2n+1"||!/\D/.test(a[2])&&"0n+"+a[2]||a[2]);a[2]=b[1]+(b[2]||1)-0,a[3]=b[3]-0}else a[2]&&m.error(a[0]);return a[0]=e++,a},ATTR:function(a,b,c,d,e,f){var g=a[1]=a[1].replace(j,"");return!f&&o.attrMap[g]&&(a[1]=o.attrMap[g]),a[4]=(a[4]||a[5]||"").replace(j,""),a[2]==="~="&&(a[4]=" "+a[4]+" "),a},PSEUDO:function(b,c,d,e,f){if(b[1]==="not"){if(!((a.exec(b[3])||"").length>1||/^\w/.test(b[3]))){var g=m.filter(b[3],c,d,!0^f);return d||e.push.apply(e,g),!1}b[3]=m(b[3],null,null,c)}else if(o.match.POS.test(b[0])||o.match.CHILD.test(b[0]))return!0;return b},POS:function(a){return a.unshift(!0),a}},filters:{enabled:function(a){return a.disabled===!1&&a.type!=="hidden"},disabled:function(a){return a.disabled===!0},checked:function(a){return a.checked===!0},selected:function(a){return a.parentNode&&a.parentNode.selectedIndex,a.selected===!0},parent:function(a){return!!a.firstChild},empty:function(a){return!a.firstChild},has:function(a,b,c){return!!m(c[3],a).length},header:function(a){return/h\d/i.test(a.nodeName)},text:function(a){var b=a.getAttribute("type"),c=a.type;return a.nodeName.toLowerCase()==="input"&&"text"===c&&(b===c||b===null)},radio:function(a){return a.nodeName.toLowerCase()==="input"&&"radio"===a.type},checkbox:function(a){return a.nodeName.toLowerCase()==="input"&&"checkbox"===a.type},file:function(a){return a.nodeName.toLowerCase()==="input"&&"file"===a.type},password:function(a){return a.nodeName.toLowerCase()==="input"&&"password"===a.type},submit:function(a){var b=a.nodeName.toLowerCase();return(b==="input"||b==="button")&&"submit"===a.type},image:function(a){return a.nodeName.toLowerCase()==="input"&&"image"===a.type},reset:function(a){var b=a.nodeName.toLowerCase();return(b==="input"||b==="button")&&"reset"===a.type},button:function(a){var b=a.nodeName.toLowerCase();return b==="input"&&"button"===a.type||b==="button"},input:function(a){return/input|select|textarea|button/i.test(a.nodeName)},focus:function(a){return a===a.ownerDocument.activeElement}},setFilters:{first:function(a,b){return b===0},last:function(a,b,c,d){return b===d.length-1},even:function(a,b){return b%2===0},odd:function(a,b){return b%2===1},lt:function(a,b,c){return b<c[3]-0},gt:function(a,b,c){return b>c[3]-0},nth:function(a,b,c){return c[3]-0===b},eq:function(a,b,c){return c[3]-0===b}},filter:{PSEUDO:function(a,b,c,d){var e=b[1],f=o.filters[e];if(f)return f(a,c,b,d);if(e==="contains")return(a.textContent||a.innerText||n([a])||"").indexOf(b[3])>=0;if(e==="not"){var g=b[3];for(var h=0,i=g.length;h<i;h++)if(g[h]===a)return!1;return!0}m.error(e)},CHILD:function(a,b){var c,e,f,g,h,i,j,k=b[1],l=a;switch(k){case"only":case"first":while(l=l.previousSibling)if(l.nodeType===1)return!1;if(k==="first")return!0;l=a;case"last":while(l=l.nextSibling)if(l.nodeType===1)return!1;return!0;case"nth":c=b[2],e=b[3];if(c===1&&e===0)return!0;f=b[0],g=a.parentNode;if(g&&(g[d]!==f||!a.nodeIndex)){i=0;for(l=g.firstChild;l;l=l.nextSibling)l.nodeType===1&&(l.nodeIndex=++i);g[d]=f}return j=a.nodeIndex-e,c===0?j===0:j%c===0&&j/c>=0}},ID:function(a,b){return a.nodeType===1&&a.getAttribute("id")===b},TAG:function(a,b){return b==="*"&&a.nodeType===1||!!a.nodeName&&a.nodeName.toLowerCase()===b},CLASS:function(a,b){return(" "+(a.className||a.getAttribute("class"))+" ").indexOf(b)>-1},ATTR:function(a,b){var c=b[1],d=m.attr?m.attr(a,c):o.attrHandle[c]?o.attrHandle[c](a):a[c]!=null?a[c]:a.getAttribute(c),e=d+"",f=b[2],g=b[4];return d==null?f==="!=":!f&&m.attr?d!=null:f==="="?e===g:f==="*="?e.indexOf(g)>=0:f==="~="?(" "+e+" ").indexOf(g)>=0:g?f==="!="?e!==g:f==="^="?e.indexOf(g)===0:f==="$="?e.substr(e.length-g.length)===g:f==="|="?e===g||e.substr(0,g.length+1)===g+"-":!1:e&&d!==!1},POS:function(a,b,c,d){var e=b[2],f=o.setFilters[e];if(f)return f(a,c,b,d)}}},p=o.match.POS,q=function(a,b){return"\\"+(b-0+1)};for(var r in o.match)o.match[r]=new RegExp(o.match[r].source+/(?![^\[]*\])(?![^\(]*\))/.source),o.leftMatch[r]=new RegExp(/(^(?:.|\r|\n)*?)/.source+o.match[r].source.replace(/\\(\d+)/g,q));o.match.globalPOS=p;var s=function(a,b){return a=Array.prototype.slice.call(a,0),b?(b.push.apply(b,a),b):a};try{Array.prototype.slice.call(c.documentElement.childNodes,0)[0].nodeType}catch(t){s=function(a,b){var c=0,d=b||[];if(g.call(a)==="[object Array]")Array.prototype.push.apply(d,a);else if(typeof a.length=="number")for(var e=a.length;c<e;c++)d.push(a[c]);else for(;a[c];c++)d.push(a[c]);return d}}var u,v;c.documentElement.compareDocumentPosition?u=function(a,b){return a===b?(h=!0,0):!a.compareDocumentPosition||!b.compareDocumentPosition?a.compareDocumentPosition?-1:1:a.compareDocumentPosition(b)&4?-1:1}:(u=function(a,b){if(a===b)return h=!0,0;if(a.sourceIndex&&b.sourceIndex)return a.sourceIndex-b.sourceIndex;var c,d,e=[],f=[],g=a.parentNode,i=b.parentNode,j=g;if(g===i)return v(a,b);if(!g)return-1;if(!i)return 1;while(j)e.unshift(j),j=j.parentNode;j=i;while(j)f.unshift(j),j=j.parentNode;c=e.length,d=f.length;for(var k=0;k<c&&k<d;k++)if(e[k]!==f[k])return v(e[k],f[k]);return k===c?v(a,f[k],-1):v(e[k],b,1)},v=function(a,b,c){if(a===b)return c;var d=a.nextSibling;while(d){if(d===b)return-1;d=d.nextSibling}return 1}),function(){var a=c.createElement("div"),d="script"+(new Date).getTime(),e=c.documentElement;a.innerHTML="<a name='"+d+"'/>",e.insertBefore(a,e.firstChild),c.getElementById(d)&&(o.find.ID=function(a,c,d){if(typeof c.getElementById!="undefined"&&!d){var e=c.getElementById(a[1]);return e?e.id===a[1]||typeof e.getAttributeNode!="undefined"&&e.getAttributeNode("id").nodeValue===a[1]?[e]:b:[]}},o.filter.ID=function(a,b){var c=typeof a.getAttributeNode!="undefined"&&a.getAttributeNode("id");return a.nodeType===1&&c&&c.nodeValue===b}),e.removeChild(a),e=a=null}(),function(){var a=c.createElement("div");a.appendChild(c.createComment("")),a.getElementsByTagName("*").length>0&&(o.find.TAG=function(a,b){var c=b.getElementsByTagName(a[1]);if(a[1]==="*"){var d=[];for(var e=0;c[e];e++)c[e].nodeType===1&&d.push(c[e]);c=d}return c}),a.innerHTML="<a href='#'></a>",a.firstChild&&typeof a.firstChild.getAttribute!="undefined"&&a.firstChild.getAttribute("href")!=="#"&&(o.attrHandle.href=function(a){return a.getAttribute("href",2)}),a=null}(),c.querySelectorAll&&function(){var a=m,b=c.createElement("div"),d="__sizzle__";b.innerHTML="<p class='TEST'></p>";if(b.querySelectorAll&&b.querySelectorAll(".TEST").length===0)return;m=function(b,e,f,g){e=e||c;if(!g&&!m.isXML(e)){var h=/^(\w+$)|^\.([\w\-]+$)|^#([\w\-]+$)/.exec(b);if(h&&(e.nodeType===1||e.nodeType===9)){if(h[1])return s(e.getElementsByTagName(b),f);if(h[2]&&o.find.CLASS&&e.getElementsByClassName)return s(e.getElementsByClassName(h[2]),f)}if(e.nodeType===9){if(b==="body"&&e.body)return s([e.body],f);if(h&&h[3]){var i=e.getElementById(h[3]);if(!i||!i.parentNode)return s([],f);if(i.id===h[3])return s([i],f)}try{return s(e.querySelectorAll(b),f)}catch(j){}}else if(e.nodeType===1&&e.nodeName.toLowerCase()!=="object"){var k=e,l=e.getAttribute("id"),n=l||d,p=e.parentNode,q=/^\s*[+~]/.test(b);l?n=n.replace(/'/g,"\\$&"):e.setAttribute("id",n),q&&p&&(e=e.parentNode);try{if(!q||p)return s(e.querySelectorAll("[id='"+n+"'] "+b),f)}catch(r){}finally{l||k.removeAttribute("id")}}}return a(b,e,f,g)};for(var e in a)m[e]=a[e];b=null}(),function(){var a=c.documentElement,b=a.matchesSelector||a.mozMatchesSelector||a.webkitMatchesSelector||a.msMatchesSelector;if(b){var d=!b.call(c.createElement("div"),"div"),e=!1;try{b.call(c.documentElement,"[test!='']:sizzle")}catch(f){e=!0}m.matchesSelector=function(a,c){c=c.replace(/\=\s*([^'"\]]*)\s*\]/g,"='$1']");if(!m.isXML(a))try{if(e||!o.match.PSEUDO.test(c)&&!/!=/.test(c)){var f=b.call(a,c);if(f||!d||a.document&&a.document.nodeType!==11)return f}}catch(g){}return m(c,null,null,[a]).length>0}}}(),function(){var a=c.createElement("div");a.innerHTML="<div class='test e'></div><div class='test'></div>";if(!a.getElementsByClassName||a.getElementsByClassName("e").length===0)return;a.lastChild.className="e";if(a.getElementsByClassName("e").length===1)return;o.order.splice(1,0,"CLASS"),o.find.CLASS=function(a,b,c){if(typeof b.getElementsByClassName!="undefined"&&!c)return b.getElementsByClassName(a[1])},a=null}(),c.documentElement.contains?m.contains=function(a,b){return a!==b&&(a.contains?a.contains(b):!0)}:c.documentElement.compareDocumentPosition?m.contains=function(a,b){return!!(a.compareDocumentPosition(b)&16)}:m.contains=function(){return!1},m.isXML=function(a){var b=(a?a.ownerDocument||a:0).documentElement;return b?b.nodeName!=="HTML":!1};var y=function(a,b,c){var d,e=[],f="",g=b.nodeType?[b]:b;while(d=o.match.PSEUDO.exec(a))f+=d[0],a=a.replace(o.match.PSEUDO,"");a=o.relative[a]?a+"*":a;for(var h=0,i=g.length;h<i;h++)m(a,g[h],e,c);return m.filter(f,e)};m.attr=f.attr,m.selectors.attrMap={},f.find=m,f.expr=m.selectors,f.expr[":"]=f.expr.filters,f.unique=m.uniqueSort,f.text=m.getText,f.isXMLDoc=m.isXML,f.contains=m.contains}();var L=/Until$/,M=/^(?:parents|prevUntil|prevAll)/,N=/,/,O=/^.[^:#\[\.,]*$/,P=Array.prototype.slice,Q=f.expr.match.globalPOS,R={children:!0,contents:!0,next:!0,prev:!0};f.fn.extend({find:function(a){var b=this,c,d;if(typeof a!="string")return f(a).filter(function(){for(c=0,d=b.length;c<d;c++)if(f.contains(b[c],this))return!0});var e=this.pushStack("","find",a),g,h,i;for(c=0,d=this.length;c<d;c++){g=e.length,f.find(a,this[c],e);if(c>0)for(h=g;h<e.length;h++)for(i=0;i<g;i++)if(e[i]===e[h]){e.splice(h--,1);break}}return e},has:function(a){var b=f(a);return this.filter(function(){for(var a=0,c=b.length;a<c;a++)if(f.contains(this,b[a]))return!0})},not:function(a){return this.pushStack(T(this,a,!1),"not",a)},filter:function(a){return this.pushStack(T(this,a,!0),"filter",a)},is:function(a){return!!a&&(typeof a=="string"?Q.test(a)?f(a,this.context).index(this[0])>=0:f.filter(a,this).length>0:this.filter(a).length>0)},closest:function(a,b){var c=[],d,e,g=this[0];if(f.isArray(a)){var h=1;while(g&&g.ownerDocument&&g!==b){for(d=0;d<a.length;d++)f(g).is(a[d])&&c.push({selector:a[d],elem:g,level:h});g=g.parentNode,h++}return c}var i=Q.test(a)||typeof a!="string"?f(a,b||this.context):0;for(d=0,e=this.length;d<e;d++){g=this[d];while(g){if(i?i.index(g)>-1:f.find.matchesSelector(g,a)){c.push(g);break}g=g.parentNode;if(!g||!g.ownerDocument||g===b||g.nodeType===11)break}}return c=c.length>1?f.unique(c):c,this.pushStack(c,"closest",a)},index:function(a){return a?typeof a=="string"?f.inArray(this[0],f(a)):f.inArray(a.jquery?a[0]:a,this):this[0]&&this[0].parentNode?this.prevAll().length:-1},add:function(a,b){var c=typeof a=="string"?f(a,b):f.makeArray(a&&a.nodeType?[a]:a),d=f.merge(this.get(),c);return this.pushStack(S(c[0])||S(d[0])?d:f.unique(d))},andSelf:function(){return this.add(this.prevObject)}}),f.each({parent:function(a){var b=a.parentNode;return b&&b.nodeType!==11?b:null},parents:function(a){return f.dir(a,"parentNode")},parentsUntil:function(a,b,c){return f.dir(a,"parentNode",c)},next:function(a){return f.nth(a,2,"nextSibling")},prev:function(a){return f.nth(a,2,"previousSibling")},nextAll:function(a){return f.dir(a,"nextSibling")},prevAll:function(a){return f.dir(a,"previousSibling")},nextUntil:function(a,b,c){return f.dir(a,"nextSibling",c)},prevUntil:function(a,b,c){return f.dir(a,"previousSibling",c)},siblings:function(a){return f.sibling((a.parentNode||{}).firstChild,a)},children:function(a){return f.sibling(a.firstChild)},contents:function(a){return f.nodeName(a,"iframe")?a.contentDocument||a.contentWindow.document:f.makeArray(a.childNodes)}},function(a,b){f.fn[a]=function(c,d){var e=f.map(this,b,c);return L.test(a)||(d=c),d&&typeof d=="string"&&(e=f.filter(d,e)),e=this.length>1&&!R[a]?f.unique(e):e,(this.length>1||N.test(d))&&M.test(a)&&(e=e.reverse()),this.pushStack(e,a,P.call(arguments).join(","))}}),f.extend({filter:function(a,b,c){return c&&(a=":not("+a+")"),b.length===1?f.find.matchesSelector(b[0],a)?[b[0]]:[]:f.find.matches(a,b)},dir:function(a,c,d){var e=[],g=a[c];while(g&&g.nodeType!==9&&(d===b||g.nodeType!==1||!f(g).is(d)))g.nodeType===1&&e.push(g),g=g[c];return e},nth:function(a,b,c,d){b=b||1;var e=0;for(;a;a=a[c])if(a.nodeType===1&&++e===b)break;return a},sibling:function(a,b){var c=[];for(;a;a=a.nextSibling)a.nodeType===1&&a!==b&&c.push(a);return c}});var V="abbr|article|aside|audio|bdi|canvas|data|datalist|details|figcaption|figure|footer|header|hgroup|mark|meter|nav|output|progress|section|summary|time|video",W=/ jQuery\d+="(?:\d+|null)"/g,X=/^\s+/,Y=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/ig,Z=/<([\w:]+)/,$=/<tbody/i,_=/<|&#?\w+;/,ab=/<(?:script|style)/i,bb=/<(?:script|object|embed|option|style)/i,cb=new RegExp("<(?:"+V+")[\\s/>]","i"),db=/checked\s*(?:[^=]|=\s*.checked.)/i,eb=/\/(java|ecma)script/i,fb=/^\s*<!(?:\[CDATA\[|\-\-)/,gb={option:[1,"<select multiple='multiple'>","</select>"],legend:[1,"<fieldset>","</fieldset>"],thead:[1,"<table>","</table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],col:[2,"<table><tbody></tbody><colgroup>","</colgroup></table>"],area:[1,"<map>","</map>"],_default:[0,"",""]},hb=U(c);gb.optgroup=gb.option,gb.tbody=gb.tfoot=gb.colgroup=gb.caption=gb.thead,gb.th=gb.td,f.support.htmlSerialize||(gb._default=[1,"div<div>","</div>"]),f.fn.extend({text:function(a){return f.access(this,function(a){return a===b?f.text(this):this.empty().append((this[0]&&this[0].ownerDocument||c).createTextNode(a))},null,a,arguments.length)},wrapAll:function(a){if(f.isFunction(a))return this.each(function(b){f(this).wrapAll(a.call(this,b))});if(this[0]){var b=f(a,this[0].ownerDocument).eq(0).clone(!0);this[0].parentNode&&b.insertBefore(this[0]),b.map(function(){var a=this;while(a.firstChild&&a.firstChild.nodeType===1)a=a.firstChild;return a}).append(this)}return this},wrapInner:function(a){return f.isFunction(a)?this.each(function(b){f(this).wrapInner(a.call(this,b))}):this.each(function(){var b=f(this),c=b.contents();c.length?c.wrapAll(a):b.append(a)})},wrap:function(a){var b=f.isFunction(a);return this.each(function(c){f(this).wrapAll(b?a.call(this,c):a)})},unwrap:function(){return this.parent().each(function(){f.nodeName(this,"body")||f(this).replaceWith(this.childNodes)}).end()},append:function(){return this.domManip(arguments,!0,function(a){this.nodeType===1&&this.appendChild(a)})},prepend:function(){return this.domManip(arguments,!0,function(a){this.nodeType===1&&this.insertBefore(a,this.firstChild)})},before:function(){if(this[0]&&this[0].parentNode)return this.domManip(arguments,!1,function(a){this.parentNode.insertBefore(a,this)});if(arguments.length){var a=f.clean(arguments);return a.push.apply(a,this.toArray()),this
|
20
|
+
.pushStack(a,"before",arguments)}},after:function(){if(this[0]&&this[0].parentNode)return this.domManip(arguments,!1,function(a){this.parentNode.insertBefore(a,this.nextSibling)});if(arguments.length){var a=this.pushStack(this,"after",arguments);return a.push.apply(a,f.clean(arguments)),a}},remove:function(a,b){for(var c=0,d;(d=this[c])!=null;c++)if(!a||f.filter(a,[d]).length)!b&&d.nodeType===1&&(f.cleanData(d.getElementsByTagName("*")),f.cleanData([d])),d.parentNode&&d.parentNode.removeChild(d);return this},empty:function(){for(var a=0,b;(b=this[a])!=null;a++){b.nodeType===1&&f.cleanData(b.getElementsByTagName("*"));while(b.firstChild)b.removeChild(b.firstChild)}return this},clone:function(a,b){return a=a==null?!1:a,b=b==null?a:b,this.map(function(){return f.clone(this,a,b)})},html:function(a){return f.access(this,function(a){var c=this[0]||{},d=0,e=this.length;if(a===b)return c.nodeType===1?c.innerHTML.replace(W,""):null;if(typeof a=="string"&&!ab.test(a)&&(f.support.leadingWhitespace||!X.test(a))&&!gb[(Z.exec(a)||["",""])[1].toLowerCase()]){a=a.replace(Y,"<$1></$2>");try{for(;d<e;d++)c=this[d]||{},c.nodeType===1&&(f.cleanData(c.getElementsByTagName("*")),c.innerHTML=a);c=0}catch(g){}}c&&this.empty().append(a)},null,a,arguments.length)},replaceWith:function(a){return this[0]&&this[0].parentNode?f.isFunction(a)?this.each(function(b){var c=f(this),d=c.html();c.replaceWith(a.call(this,b,d))}):(typeof a!="string"&&(a=f(a).detach()),this.each(function(){var b=this.nextSibling,c=this.parentNode;f(this).remove(),b?f(b).before(a):f(c).append(a)})):this.length?this.pushStack(f(f.isFunction(a)?a():a),"replaceWith",a):this},detach:function(a){return this.remove(a,!0)},domManip:function(a,c,d){var e,g,h,i,j=a[0],k=[];if(!f.support.checkClone&&arguments.length===3&&typeof j=="string"&&db.test(j))return this.each(function(){f(this).domManip(a,c,d,!0)});if(f.isFunction(j))return this.each(function(e){var g=f(this);a[0]=j.call(this,e,c?g.html():b),g.domManip(a,c,d)});if(this[0]){i=j&&j.parentNode,f.support.parentNode&&i&&i.nodeType===11&&i.childNodes.length===this.length?e={fragment:i}:e=f.buildFragment(a,this,k),h=e.fragment,h.childNodes.length===1?g=h=h.firstChild:g=h.firstChild;if(g){c=c&&f.nodeName(g,"tr");for(var l=0,m=this.length,n=m-1;l<m;l++)d.call(c?ib(this[l],g):this[l],e.cacheable||m>1&&l<n?f.clone(h,!0,!0):h)}k.length&&f.each(k,function(a,b){b.src?f.ajax({type:"GET",global:!1,url:b.src,async:!1,dataType:"script"}):f.globalEval((b.text||b.textContent||b.innerHTML||"").replace(fb,"/*$0*/")),b.parentNode&&b.parentNode.removeChild(b)})}return this}}),f.buildFragment=function(a,b,d){var e,g,h,i,j=a[0];return b&&b[0]&&(i=b[0].ownerDocument||b[0]),i.createDocumentFragment||(i=c),a.length===1&&typeof j=="string"&&j.length<512&&i===c&&j.charAt(0)==="<"&&!bb.test(j)&&(f.support.checkClone||!db.test(j))&&(f.support.html5Clone||!cb.test(j))&&(g=!0,h=f.fragments[j],h&&h!==1&&(e=h)),e||(e=i.createDocumentFragment(),f.clean(a,i,e,d)),g&&(f.fragments[j]=h?e:1),{fragment:e,cacheable:g}},f.fragments={},f.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(a,b){f.fn[a]=function(c){var d=[],e=f(c),g=this.length===1&&this[0].parentNode;if(g&&g.nodeType===11&&g.childNodes.length===1&&e.length===1)return e[b](this[0]),this;for(var h=0,i=e.length;h<i;h++){var j=(h>0?this.clone(!0):this).get();f(e[h])[b](j),d=d.concat(j)}return this.pushStack(d,a,e.selector)}}),f.extend({clone:function(a,b,c){var d,e,g,h=f.support.html5Clone||f.isXMLDoc(a)||!cb.test("<"+a.nodeName+">")?a.cloneNode(!0):ob(a);if((!f.support.noCloneEvent||!f.support.noCloneChecked)&&(a.nodeType===1||a.nodeType===11)&&!f.isXMLDoc(a)){kb(a,h),d=lb(a),e=lb(h);for(g=0;d[g];++g)e[g]&&kb(d[g],e[g])}if(b){jb(a,h);if(c){d=lb(a),e=lb(h);for(g=0;d[g];++g)jb(d[g],e[g])}}return d=e=null,h},clean:function(a,b,d,e){var g,h,i,j=[];b=b||c,typeof b.createElement=="undefined"&&(b=b.ownerDocument||b[0]&&b[0].ownerDocument||c);for(var k=0,l;(l=a[k])!=null;k++){typeof l=="number"&&(l+="");if(!l)continue;if(typeof l=="string")if(!_.test(l))l=b.createTextNode(l);else{l=l.replace(Y,"<$1></$2>");var m=(Z.exec(l)||["",""])[1].toLowerCase(),n=gb[m]||gb._default,o=n[0],p=b.createElement("div"),q=hb.childNodes,r;b===c?hb.appendChild(p):U(b).appendChild(p),p.innerHTML=n[1]+l+n[2];while(o--)p=p.lastChild;if(!f.support.tbody){var s=$.test(l),t=m==="table"&&!s?p.firstChild&&p.firstChild.childNodes:n[1]==="<table>"&&!s?p.childNodes:[];for(i=t.length-1;i>=0;--i)f.nodeName(t[i],"tbody")&&!t[i].childNodes.length&&t[i].parentNode.removeChild(t[i])}!f.support.leadingWhitespace&&X.test(l)&&p.insertBefore(b.createTextNode(X.exec(l)[0]),p.firstChild),l=p.childNodes,p&&(p.parentNode.removeChild(p),q.length>0&&(r=q[q.length-1],r&&r.parentNode&&r.parentNode.removeChild(r)))}var u;if(!f.support.appendChecked)if(l[0]&&typeof (u=l.length)=="number")for(i=0;i<u;i++)nb(l[i]);else nb(l);l.nodeType?j.push(l):j=f.merge(j,l)}if(d){g=function(a){return!a.type||eb.test(a.type)};for(k=0;j[k];k++){h=j[k];if(e&&f.nodeName(h,"script")&&(!h.type||eb.test(h.type)))e.push(h.parentNode?h.parentNode.removeChild(h):h);else{if(h.nodeType===1){var v=f.grep(h.getElementsByTagName("script"),g);j.splice.apply(j,[k+1,0].concat(v))}d.appendChild(h)}}}return j},cleanData:function(a){var b,c,d=f.cache,e=f.event.special,g=f.support.deleteExpando;for(var h=0,i;(i=a[h])!=null;h++){if(i.nodeName&&f.noData[i.nodeName.toLowerCase()])continue;c=i[f.expando];if(c){b=d[c];if(b&&b.events){for(var j in b.events)e[j]?f.event.remove(i,j):f.removeEvent(i,j,b.handle);b.handle&&(b.handle.elem=null)}g?delete i[f.expando]:i.removeAttribute&&i.removeAttribute(f.expando),delete d[c]}}}});var pb=/alpha\([^)]*\)/i,qb=/opacity=([^)]*)/,rb=/([A-Z]|^ms)/g,sb=/^[\-+]?(?:\d*\.)?\d+$/i,tb=/^-?(?:\d*\.)?\d+(?!px)[^\d\s]+$/i,ub=/^([\-+])=([\-+.\de]+)/,vb=/^margin/,wb={position:"absolute",visibility:"hidden",display:"block"},xb=["Top","Right","Bottom","Left"],yb,zb,Ab;f.fn.css=function(a,c){return f.access(this,function(a,c,d){return d!==b?f.style(a,c,d):f.css(a,c)},a,c,arguments.length>1)},f.extend({cssHooks:{opacity:{get:function(a,b){if(b){var c=yb(a,"opacity");return c===""?"1":c}return a.style.opacity}}},cssNumber:{fillOpacity:!0,fontWeight:!0,lineHeight:!0,opacity:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{"float":f.support.cssFloat?"cssFloat":"styleFloat"},style:function(a,c,d,e){if(!a||a.nodeType===3||a.nodeType===8||!a.style)return;var g,h,i=f.camelCase(c),j=a.style,k=f.cssHooks[i];c=f.cssProps[i]||i;if(d===b)return k&&"get"in k&&(g=k.get(a,!1,e))!==b?g:j[c];h=typeof d,h==="string"&&(g=ub.exec(d))&&(d=+(g[1]+1)*+g[2]+parseFloat(f.css(a,c)),h="number");if(d==null||h==="number"&&isNaN(d))return;h==="number"&&!f.cssNumber[i]&&(d+="px");if(!k||!("set"in k)||(d=k.set(a,d))!==b)try{j[c]=d}catch(l){}},css:function(a,c,d){var e,g;c=f.camelCase(c),g=f.cssHooks[c],c=f.cssProps[c]||c,c==="cssFloat"&&(c="float");if(g&&"get"in g&&(e=g.get(a,!0,d))!==b)return e;if(yb)return yb(a,c)},swap:function(a,b,c){var d={},e,f;for(f in b)d[f]=a.style[f],a.style[f]=b[f];e=c.call(a);for(f in b)a.style[f]=d[f];return e}}),f.curCSS=f.css,c.defaultView&&c.defaultView.getComputedStyle&&(zb=function(a,b){var c,d,e,g,h=a.style;return b=b.replace(rb,"-$1").toLowerCase(),(d=a.ownerDocument.defaultView)&&(e=d.getComputedStyle(a,null))&&(c=e.getPropertyValue(b),c===""&&!f.contains(a.ownerDocument.documentElement,a)&&(c=f.style(a,b))),!f.support.pixelMargin&&e&&vb.test(b)&&tb.test(c)&&(g=h.width,h.width=c,c=e.width,h.width=g),c}),c.documentElement.currentStyle&&(Ab=function(a,b){var c,d,e,f=a.currentStyle&&a.currentStyle[b],g=a.style;return f==null&&g&&(e=g[b])&&(f=e),tb.test(f)&&(c=g.left,d=a.runtimeStyle&&a.runtimeStyle.left,d&&(a.runtimeStyle.left=a.currentStyle.left),g.left=b==="fontSize"?"1em":f,f=g.pixelLeft+"px",g.left=c,d&&(a.runtimeStyle.left=d)),f===""?"auto":f}),yb=zb||Ab,f.each(["height","width"],function(a,b){f.cssHooks[b]={get:function(a,c,d){if(c)return a.offsetWidth!==0?Bb(a,b,d):f.swap(a,wb,function(){return Bb(a,b,d)})},set:function(a,b){return sb.test(b)?b+"px":b}}}),f.support.opacity||(f.cssHooks.opacity={get:function(a,b){return qb.test((b&&a.currentStyle?a.currentStyle.filter:a.style.filter)||"")?parseFloat(RegExp.$1)/100+"":b?"1":""},set:function(a,b){var c=a.style,d=a.currentStyle,e=f.isNumeric(b)?"alpha(opacity="+b*100+")":"",g=d&&d.filter||c.filter||"";c.zoom=1;if(b>=1&&f.trim(g.replace(pb,""))===""){c.removeAttribute("filter");if(d&&!d.filter)return}c.filter=pb.test(g)?g.replace(pb,e):g+" "+e}}),f(function(){f.support.reliableMarginRight||(f.cssHooks.marginRight={get:function(a,b){return f.swap(a,{display:"inline-block"},function(){return b?yb(a,"margin-right"):a.style.marginRight})}})}),f.expr&&f.expr.filters&&(f.expr.filters.hidden=function(a){var b=a.offsetWidth,c=a.offsetHeight;return b===0&&c===0||!f.support.reliableHiddenOffsets&&(a.style&&a.style.display||f.css(a,"display"))==="none"},f.expr.filters.visible=function(a){return!f.expr.filters.hidden(a)}),f.each({margin:"",padding:"",border:"Width"},function(a,b){f.cssHooks[a+b]={expand:function(c){var d,e=typeof c=="string"?c.split(" "):[c],f={};for(d=0;d<4;d++)f[a+xb[d]+b]=e[d]||e[d-2]||e[0];return f}}});var Cb=/%20/g,Db=/\[\]$/,Eb=/\r?\n/g,Fb=/#.*$/,Gb=/^(.*?):[ \t]*([^\r\n]*)\r?$/mg,Hb=/^(?:color|date|datetime|datetime-local|email|hidden|month|number|password|range|search|tel|text|time|url|week)$/i,Ib=/^(?:about|app|app\-storage|.+\-extension|file|res|widget):$/,Jb=/^(?:GET|HEAD)$/,Kb=/^\/\//,Lb=/\?/,Mb=/<script\b[^<]*(?:(?!<\/script>)<[^<]*)*<\/script>/gi,Nb=/^(?:select|textarea)/i,Ob=/\s+/,Pb=/([?&])_=[^&]*/,Qb=/^([\w\+\.\-]+:)(?:\/\/([^\/?#:]*)(?::(\d+))?)?/,Rb=f.fn.load,Sb={},Tb={},Ub,Vb,Wb=["*/"]+["*"];try{Ub=e.href}catch(Xb){Ub=c.createElement("a"),Ub.href="",Ub=Ub.href}Vb=Qb.exec(Ub.toLowerCase())||[],f.fn.extend({load:function(a,c,d){if(typeof a!="string"&&Rb)return Rb.apply(this,arguments);if(!this.length)return this;var e=a.indexOf(" ");if(e>=0){var g=a.slice(e,a.length);a=a.slice(0,e)}var h="GET";c&&(f.isFunction(c)?(d=c,c=b):typeof c=="object"&&(c=f.param(c,f.ajaxSettings.traditional),h="POST"));var i=this;return f.ajax({url:a,type:h,dataType:"html",data:c,complete:function(a,b,c){c=a.responseText,a.isResolved()&&(a.done(function(a){c=a}),i.html(g?f("<div>").append(c.replace(Mb,"")).find(g):c)),d&&i.each(d,[c,b,a])}}),this},serialize:function(){return f.param(this.serializeArray())},serializeArray:function(){return this.map(function(){return this.elements?f.makeArray(this.elements):this}).filter(function(){return this.name&&!this.disabled&&(this.checked||Nb.test(this.nodeName)||Hb.test(this.type))}).map(function(a,b){var c=f(this).val();return c==null?null:f.isArray(c)?f.map(c,function(a,c){return{name:b.name,value:a.replace(Eb,"\r\n")}}):{name:b.name,value:c.replace(Eb,"\r\n")}}).get()}}),f.each("ajaxStart ajaxStop ajaxComplete ajaxError ajaxSuccess ajaxSend".split(" "),function(a,b){f.fn[b]=function(a){return this.on(b,a)}}),f.each(["get","post"],function(a,c){f[c]=function(a,d,e,g){return f.isFunction(d)&&(g=g||e,e=d,d=b),f.ajax({type:c,url:a,data:d,success:e,dataType:g})}}),f.extend({getScript:function(a,c){return f.get(a,b,c,"script")},getJSON:function(a,b,c){return f.get(a,b,c,"json")},ajaxSetup:function(a,b){return b?$b(a,f.ajaxSettings):(b=a,a=f.ajaxSettings),$b(a,b),a},ajaxSettings:{url:Ub,isLocal:Ib.test(Vb[1]),global:!0,type:"GET",contentType:"application/x-www-form-urlencoded; charset=UTF-8",processData:!0,async:!0,accepts:{xml:"application/xml, text/xml",html:"text/html",text:"text/plain",json:"application/json, text/javascript","*":Wb},contents:{xml:/xml/,html:/html/,json:/json/},responseFields:{xml:"responseXML",text:"responseText"},converters:{"* text":a.String,"text html":!0,"text json":f.parseJSON,"text xml":f.parseXML},flatOptions:{context:!0,url:!0}},ajaxPrefilter:Yb(Sb),ajaxTransport:Yb(Tb),ajax:function(a,c){function w(a,c,l,m){if(s===2)return;s=2,q&&clearTimeout(q),p=b,n=m||"",v.readyState=a>0?4:0;var o,r,u,w=c,x=l?ac(d,v,l):b,y,z;if(a>=200&&a<300||a===304){if(d.ifModified){if(y=v.getResponseHeader("Last-Modified"))f.lastModified[k]=y;if(z=v.getResponseHeader("Etag"))f.etag[k]=z}if(a===304)w="notmodified",o=!0;else try{r=bc(d,x),w="success",o=!0}catch(A){w="parsererror",u=A}}else{u=w;if(!w||a)w="error",a<0&&(a=0)}v.status=a,v.statusText=""+(c||w),o?h.resolveWith(e,[r,w,v]):h.rejectWith(e,[v,w,u]),v.statusCode(j),j=b,t&&g.trigger("ajax"+(o?"Success":"Error"),[v,d,o?r:u]),i.fireWith(e,[v,w]),t&&(g.trigger("ajaxComplete",[v,d]),--f.active||f.event.trigger("ajaxStop"))}typeof a=="object"&&(c=a,a=b),c=c||{};var d=f.ajaxSetup({},c),e=d.context||d,g=e!==d&&(e.nodeType||e instanceof f)?f(e):f.event,h=f.Deferred(),i=f.Callbacks("once memory"),j=d.statusCode||{},k,l={},m={},n,o,p,q,r,s=0,t,u,v={readyState:0,setRequestHeader:function(a,b){if(!s){var c=a.toLowerCase();a=m[c]=m[c]||a,l[a]=b}return this},getAllResponseHeaders:function(){return s===2?n:null},getResponseHeader:function(a){var c;if(s===2){if(!o){o={};while(c=Gb.exec(n))o[c[1].toLowerCase()]=c[2]}c=o[a.toLowerCase()]}return c===b?null:c},overrideMimeType:function(a){return s||(d.mimeType=a),this},abort:function(a){return a=a||"abort",p&&p.abort(a),w(0,a),this}};h.promise(v),v.success=v.done,v.error=v.fail,v.complete=i.add,v.statusCode=function(a){if(a){var b;if(s<2)for(b in a)j[b]=[j[b],a[b]];else b=a[v.status],v.then(b,b)}return this},d.url=((a||d.url)+"").replace(Fb,"").replace(Kb,Vb[1]+"//"),d.dataTypes=f.trim(d.dataType||"*").toLowerCase().split(Ob),d.crossDomain==null&&(r=Qb.exec(d.url.toLowerCase()),d.crossDomain=!(!r||r[1]==Vb[1]&&r[2]==Vb[2]&&(r[3]||(r[1]==="http:"?80:443))==(Vb[3]||(Vb[1]==="http:"?80:443)))),d.data&&d.processData&&typeof d.data!="string"&&(d.data=f.param(d.data,d.traditional)),Zb(Sb,d,c,v);if(s===2)return!1;t=d.global,d.type=d.type.toUpperCase(),d.hasContent=!Jb.test(d.type),t&&f.active++===0&&f.event.trigger("ajaxStart");if(!d.hasContent){d.data&&(d.url+=(Lb.test(d.url)?"&":"?")+d.data,delete d.data),k=d.url;if(d.cache===!1){var x=f.now(),y=d.url.replace(Pb,"$1_="+x);d.url=y+(y===d.url?(Lb.test(d.url)?"&":"?")+"_="+x:"")}}(d.data&&d.hasContent&&d.contentType!==!1||c.contentType)&&v.setRequestHeader("Content-Type",d.contentType),d.ifModified&&(k=k||d.url,f.lastModified[k]&&v.setRequestHeader("If-Modified-Since",f.lastModified[k]),f.etag[k]&&v.setRequestHeader("If-None-Match",f.etag[k])),v.setRequestHeader("Accept",d.dataTypes[0]&&d.accepts[d.dataTypes[0]]?d.accepts[d.dataTypes[0]]+(d.dataTypes[0]!=="*"?", "+Wb+"; q=0.01":""):d.accepts["*"]);for(u in d.headers)v.setRequestHeader(u,d.headers[u]);if(!d.beforeSend||d.beforeSend.call(e,v,d)!==!1&&s!==2){for(u in{success:1,error:1,complete:1})v[u](d[u]);p=Zb(Tb,d,c,v);if(!p)w(-1,"No Transport");else{v.readyState=1,t&&g.trigger("ajaxSend",[v,d]),d.async&&d.timeout>0&&(q=setTimeout(function(){v.abort("timeout")},d.timeout));try{s=1,p.send(l,w)}catch(z){if(!(s<2))throw z;w(-1,z)}}return v}return v.abort(),!1},param:function(a,c){var d=[],e=function(a,b){b=f.isFunction(b)?b():b,d[d.length]=encodeURIComponent(a)+"="+encodeURIComponent(b)};c===b&&(c=f.ajaxSettings.traditional);if(f.isArray(a)||a.jquery&&!f.isPlainObject(a))f.each(a,function(){e(this.name,this.value)});else for(var g in a)_b(g,a[g],c,e);return d.join("&").replace(Cb,"+")}}),f.extend({active:0,lastModified:{},etag:{}});var cc=f.now(),dc=/(\=)\?(&|$)|\?\?/i;f.ajaxSetup({jsonp:"callback",jsonpCallback:function(){return f.expando+"_"+cc++}}),f.ajaxPrefilter("json jsonp",function(b,c,d){var e=typeof b.data=="string"&&/^application\/x\-www\-form\-urlencoded/.test(b.contentType);if(b.dataTypes[0]==="jsonp"||b.jsonp!==!1&&(dc.test(b.url)||e&&dc.test(b.data))){var g,h=b.jsonpCallback=f.isFunction(b.jsonpCallback)?b.jsonpCallback():b.jsonpCallback,i=a[h],j=b.url,k=b.data,l="$1"+h+"$2";return b.jsonp!==!1&&(j=j.replace(dc,l),b.url===j&&(e&&(k=k.replace(dc,l)),b.data===k&&(j+=(/\?/.test(j)?"&":"?")+b.jsonp+"="+h))),b.url=j,b.data=k,a[h]=function(a){g=[a]},d.always(function(){a[h]=i,g&&f.isFunction(i)&&a[h](g[0])}),b.converters["script json"]=function(){return g||f.error(h+" was not called"),g[0]},b.dataTypes[0]="json","script"}}),f.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/javascript|ecmascript/},converters:{"text script":function(a){return f.globalEval(a),a}}}),f.ajaxPrefilter("script",function(a){a.cache===b&&(a.cache=!1),a.crossDomain&&(a.type="GET",a.global=!1)}),f.ajaxTransport("script",function(a){if(a.crossDomain){var d,e=c.head||c.getElementsByTagName("head")[0]||c.documentElement;return{send:function(f,g){d=c.createElement("script"),d.async="async",a.scriptCharset&&(d.charset=a.scriptCharset),d.src=a.url,d.onload=d.onreadystatechange=function(a,c){if(c||!d.readyState||/loaded|complete/.test(d.readyState))d.onload=d.onreadystatechange=null,e&&d.parentNode&&e.removeChild(d),d=b,c||g(200,"success")},e.insertBefore(d,e.firstChild)},abort:function(){d&&d.onload(0,1)}}}});var ec=a.ActiveXObject?function(){for(var a in gc)gc[a](0,1)}:!1,fc=0,gc;f.ajaxSettings.xhr=a.ActiveXObject?function(){return!this.isLocal&&hc()||ic()}:hc,function(a){f.extend(f.support,{ajax:!!a,cors:!!a&&"withCredentials"in a})}(f.ajaxSettings.xhr()),f.support.ajax&&f.ajaxTransport(function(c){if(!c.crossDomain||f.support.cors){var d;return{send:function(e,g){var h=c.xhr(),i,j;c.username?h.open(c.type,c.url,c.async,c.username,c.password):h.open(c.type,c.url,c.async);if(c.xhrFields)for(j in c.xhrFields)h[j]=c.xhrFields[j];c.mimeType&&h.overrideMimeType&&h.overrideMimeType(c.mimeType),!c.crossDomain&&!e["X-Requested-With"]&&(e["X-Requested-With"]="XMLHttpRequest");try{for(j in e)h.setRequestHeader(j,e[j])}catch(k){}h.send(c.hasContent&&c.data||null),d=function(a,e){var j,k,l,m,n;try{if(d&&(e||h.readyState===4)){d=b,i&&(h.onreadystatechange=f.noop,ec&&delete gc[i]);if(e)h.readyState!==4&&h.abort();else{j=h.status,l=h.getAllResponseHeaders(),m={},n=h.responseXML,n&&n.documentElement&&(m.xml=n);try{m.text=h.responseText}catch(a){}try{k=h.statusText}catch(o){k=""}!j&&c.isLocal&&!c.crossDomain?j=m.text?200:404:j===1223&&(j=204)}}}catch(p){e||g(-1,p)}m&&g(j,k,m,l)},!c.async||h.readyState===4?d():(i=++fc,ec&&(gc||(gc={},f(a).unload(ec)),gc[i]=d),h.onreadystatechange=d)},abort:function(){d&&d(0,1)}}}});var jc={},kc,lc,mc=/^(?:toggle|show|hide)$/,nc=/^([+\-]=)?([\d+.\-]+)([a-z%]*)$/i,oc,pc=[["height","marginTop","marginBottom","paddingTop","paddingBottom"],["width","marginLeft","marginRight","paddingLeft","paddingRight"],["opacity"]],qc;f.fn.extend({show:function(a,b,c){var d,e;if(a||a===0)return this.animate(tc("show",3),a,b,c);for(var g=0,h=this.length;g<h;g++)d=this[g],d.style&&(e=d.style.display,!f._data(d,"olddisplay")&&e==="none"&&(e=d.style.display=""),(e===""&&f.css(d,"display")==="none"||!f.contains(d.ownerDocument.documentElement,d))&&f._data(d,"olddisplay",uc(d.nodeName)));for(g=0;g<h;g++){d=this[g];if(d.style){e=d.style.display;if(e===""||e==="none")d.style.display=f._data(d,"olddisplay")||""}}return this},hide:function(a,b,c){if(a||a===0)return this.animate(tc("hide",3),a,b,c);var d,e,g=0,h=this.length;for(;g<h;g++)d=this[g],d.style&&(e=f.css(d,"display"),e!=="none"&&!f._data(d,"olddisplay")&&f._data(d,"olddisplay",e));for(g=0;g<h;g++)this[g].style&&(this[g].style.display="none");return this},_toggle:f.fn.toggle,toggle:function(a,b,c){var d=typeof a=="boolean";return f.isFunction(a)&&f.isFunction(b)?this._toggle.apply(this,arguments):a==null||d?this.each(function(){var b=d?a:f(this).is(":hidden");f(this)[b?"show":"hide"]()}):this.animate(tc("toggle",3),a,b,c),this},fadeTo:function(a,b,c,d){return this.filter(":hidden").css("opacity",0).show().end().animate({opacity:b},a,c,d)},animate:function(a,b,c,d){function g(){e.queue===!1&&f._mark(this);var b=f.extend({},e),c=this.nodeType===1,d=c&&f(this).is(":hidden"),g,h,i,j,k,l,m,n,o,p,q;b.animatedProperties={};for(i in a){g=f.camelCase(i),i!==g&&(a[g]=a[i],delete a[i]);if((k=f.cssHooks[g])&&"expand"in k){l=k.expand(a[g]),delete a[g];for(i in l)i in a||(a[i]=l[i])}}for(g in a){h=a[g],f.isArray(h)?(b.animatedProperties[g]=h[1],h=a[g]=h[0]):b.animatedProperties[g]=b.specialEasing&&b.specialEasing[g]||b.easing||"swing";if(h==="hide"&&d||h==="show"&&!d)return b.complete.call(this);c&&(g==="height"||g==="width")&&(b.overflow=[this.style.overflow,this.style.overflowX,this.style.overflowY],f.css(this,"display")==="inline"&&f.css(this,"float")==="none"&&(!f.support.inlineBlockNeedsLayout||uc(this.nodeName)==="inline"?this.style.display="inline-block":this.style.zoom=1))}b.overflow!=null&&(this.style.overflow="hidden");for(i in a)j=new f.fx(this,b,i),h=a[i],mc.test(h)?(q=f._data(this,"toggle"+i)||(h==="toggle"?d?"show":"hide":0),q?(f._data(this,"toggle"+i,q==="show"?"hide":"show"),j[q]()):j[h]()):(m=nc.exec(h),n=j.cur(),m?(o=parseFloat(m[2]),p=m[3]||(f.cssNumber[i]?"":"px"),p!=="px"&&(f.style(this,i,(o||1)+p),n=(o||1)/j.cur()*n,f.style(this,i,n+p)),m[1]&&(o=(m[1]==="-="?-1:1)*o+n),j.custom(n,o,p)):j.custom(n,h,""));return!0}var e=f.speed(b,c,d);return f.isEmptyObject(a)?this.each(e.complete,[!1]):(a=f.extend({},a),e.queue===!1?this.each(g):this.queue(e.queue,g))},stop:function(a,c,d){return typeof a!="string"&&(d=c,c=a,a=b),c&&a!==!1&&this.queue(a||"fx",[]),this.each(function(){function h(a,b,c){var e=b[c];f.removeData(a,c,!0),e.stop(d)}var b,c=!1,e=f.timers,g=f._data(this);d||f._unmark(!0,this);if(a==null)for(b in g)g[b]&&g[b].stop&&b.indexOf(".run")===b.length-4&&h(this,g,b);else g[b=a+".run"]&&g[b].stop&&h(this,g,b);for(b=e.length;b--;)e[b].elem===this&&(a==null||e[b].queue===a)&&(d?e[b](!0):e[b].saveState(),c=!0,e.splice(b,1));(!d||!c)&&f.dequeue(this,a)})}}),f.each({slideDown:tc("show",1),slideUp:tc("hide",1),slideToggle:tc("toggle",1),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(a,b){f.fn[a]=function(a,c,d){return this.animate(b,a,c,d)}}),f.extend({speed:function(a,b,c){var d=a&&typeof a=="object"?f.extend({},a):{complete:c||!c&&b||f.isFunction(a)&&a,duration:a,easing:c&&b||b&&!f.isFunction(b)&&b};d.duration=f.fx.off?0:typeof d.duration=="number"?d.duration:d.duration in f.fx.speeds?f.fx.speeds[d.duration]:f.fx.speeds._default;if(d.queue==null||d.queue===!0)d.queue="fx";return d.old=d.complete,d.complete=function(a){f.isFunction(d.old)&&d.old.call(this),d.queue?f.dequeue(this,d.queue):a!==!1&&f._unmark(this)},d},easing:{linear:function(a){return a},swing:function(a){return-Math.cos(a*Math.PI)/2+.5}},timers:[],fx:function(a,b,c){this.options=b,this.elem=a,this.prop=c,b.orig=b.orig||{}}}),f.fx.prototype={update:function(){this.options.step&&this.options.step.call(this.elem,this.now,this),(f.fx.step[this.prop]||f.fx.step._default)(this)},cur:function(){if(this.elem[this.prop]==null||!!this.elem.style&&this.elem.style[this.prop]!=null){var a,b=f.css(this.elem,this.prop);return isNaN(a=parseFloat(b))?!b||b==="auto"?0:b:a}return this.elem[this.prop]},custom:function(a,c,d){function h(a){return e.step(a)}var e=this,g=f.fx;this.startTime=qc||rc(),this.end=c,this.now=this.start=a,this.pos=this.state=0,this.unit=d||this.unit||(f.cssNumber[this.prop]?"":"px"),h.queue=this.options.queue,h.elem=this.elem,h.saveState=function(){f._data(e.elem,"fxshow"+e.prop)===b&&(e.options.hide?f._data(e.elem,"fxshow"+e.prop,e.start):e.options.show&&f._data(e.elem,"fxshow"+e.prop,e.end))},h()&&f.timers.push(h)&&!oc&&(oc=setInterval(g.tick,g.interval))},show:function(){var a=f._data(this.elem,"fxshow"+this.prop);this.options.orig[this.prop]=a||f.style(this.elem,this.prop),this.options.show=!0,a!==b?this.custom(this.cur(),a):this.custom(this.prop==="width"||this.prop==="height"?1:0,this.cur()),f(this.elem).show()},hide:function(){this.options.orig[this.prop]=f._data(this.elem,"fxshow"+this.prop)||f.style(this.elem,this.prop),this.options.hide=!0,this.custom(this.cur(),0)},step:function(a){var b,c,d,e=qc||rc(),g=!0,h=this.elem,i=this.options;if(a||e>=i.duration+this.startTime){this.now=this.end,this.pos=this.state=1,this.update(),i.animatedProperties[this.prop]=!0;for(b in i.animatedProperties)i.animatedProperties[b]!==!0&&(g=!1);if(g){i.overflow!=null&&!f.support.shrinkWrapBlocks&&f.each(["","X","Y"],function(a,b){h.style["overflow"+b]=i.overflow[a]}),i.hide&&f(h).hide();if(i.hide||i.show)for(b in i.animatedProperties)f.style(h,b,i.orig[b]),f.removeData(h,"fxshow"+b,!0),f.removeData(h,"toggle"+b,!0);d=i.complete,d&&(i.complete=!1,d.call(h))}return!1}return i.duration==Infinity?this.now=e:(c=e-this.startTime,this.state=c/i.duration,this.pos=f.easing[i.animatedProperties[this.prop]](this.state,c,0,1,i.duration),this.now=this.start+(this.end-this.start)*this.pos),this.update(),!0}},f.extend(f.fx,{tick:function(){var a,b=f.timers,c=0;for(;c<b.length;c++)a=b[c],!a()&&b[c]===a&&b.splice(c--,1);b.length||f.fx.stop()},interval:13,stop:function(){clearInterval(oc),oc=null},speeds:{slow:600,fast:200,_default:400},step:{opacity:function(a){f.style(a.elem,"opacity",a.now)},_default:function(a){a.elem.style&&a.elem.style[a.prop]!=null?a.elem.style[a.prop]=a.now+a.unit:a.elem[a.prop]=a.now}}}),f.each(pc.concat.apply([],pc),function(a,b){b.indexOf("margin")&&(f.fx.step[b]=function(a){f.style(a.elem,b,Math.max(0,a.now)+a.unit)})}),f.expr&&f.expr.filters&&(f.expr.filters.animated=function(a){return f.grep(f.timers,function(b){return a===b.elem}).length});var vc,wc=/^t(?:able|d|h)$/i,xc=/^(?:body|html)$/i;"getBoundingClientRect"in c.documentElement?vc=function(a,b,c,d){try{d=a.getBoundingClientRect()}catch(e){}if(!d||!f.contains(c,a))return d?{top:d.top,left:d.left}:{top:0,left:0};var g=b.body,h=yc(b),i=c.clientTop||g.clientTop||0,j=c.clientLeft||g.clientLeft||0,k=h.pageYOffset||f.support.boxModel&&c.scrollTop||g.scrollTop,l=h.pageXOffset||f.support.boxModel&&c.scrollLeft||g.scrollLeft,m=d.top+k-i,n=d.left+l-j;return{top:m,left:n}}:vc=function(a,b,c){var d,e=a.offsetParent,g=a,h=b.body,i=b.defaultView,j=i?i.getComputedStyle(a,null):a.currentStyle,k=a.offsetTop,l=a.offsetLeft;while((a=a.parentNode)&&a!==h&&a!==c){if(f.support.fixedPosition&&j.position==="fixed")break;d=i?i.getComputedStyle(a,null):a.currentStyle,k-=a.scrollTop,l-=a.scrollLeft,a===e&&(k+=a.offsetTop,l+=a.offsetLeft,f.support.doesNotAddBorder&&(!f.support.doesAddBorderForTableAndCells||!wc.test(a.nodeName))&&(k+=parseFloat(d.borderTopWidth)||0,l+=parseFloat(d.borderLeftWidth)||0),g=e,e=a.offsetParent),f.support.subtractsBorderForOverflowNotVisible&&d.overflow!=="visible"&&(k+=parseFloat(d.borderTopWidth)||0,l+=parseFloat(d.borderLeftWidth)||0),j=d}if(j.position==="relative"||j.position==="static")k+=h.offsetTop,l+=h.offsetLeft;return f.support.fixedPosition&&j.position==="fixed"&&(k+=Math.max(c.scrollTop,h.scrollTop),l+=Math.max(c.scrollLeft,h.scrollLeft)),{top:k,left:l}},f.fn.offset=function(a){if(arguments.length)return a===b?this:this.each(function(b){f.offset.setOffset(this,a,b)});var c=this[0],d=c&&c.ownerDocument;return d?c===d.body?f.offset.bodyOffset(c):vc(c,d,d.documentElement):null},f.offset={bodyOffset:function(a){var b=a.offsetTop,c=a.offsetLeft;return f.support.doesNotIncludeMarginInBodyOffset&&(b+=parseFloat(f.css(a,"marginTop"))||0,c+=parseFloat(f.css(a,"marginLeft"))||0),{top:b,left:c}},setOffset:function(a,b,c){var d=f.css(a,"position");d==="static"&&(a.style.position="relative");var e=f(a),g=e.offset(),h=f.css(a,"top"),i=f.css(a,"left"),j=(d==="absolute"||d==="fixed")&&f.inArray("auto",[h,i])>-1,k={},l={},m,n;j?(l=e.position(),m=l.top,n=l.left):(m=parseFloat(h)||0,n=parseFloat(i)||0),f.isFunction(b)&&(b=b.call(a,c,g)),b.top!=null&&(k.top=b.top-g.top+m),b.left!=null&&(k.left=b.left-g.left+n),"using"in b?b.using.call(a,k):e.css(k)}},f.fn.extend({position:function(){if(!this[0])return null;var a=this[0],b=this.offsetParent(),c=this.offset(),d=xc.test(b[0].nodeName)?{top:0,left:0}:b.offset();return c.top-=parseFloat(f.css(a,"marginTop"))||0,c.left-=parseFloat(f.css(a,"marginLeft"))||0,d.top+=parseFloat(f.css(b[0],"borderTopWidth"))||0,d.left+=parseFloat(f.css(b[0],"borderLeftWidth"))||0,{top:c.top-d.top,left:c.left-d.left}},offsetParent:function(){return this.map(function(){var a=this.offsetParent||c.body;while(a&&!xc.test(a.nodeName)&&f.css(a,"position")==="static")a=a.offsetParent;return a})}}),f.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(a,c){var d=/Y/.test(c);f.fn[a]=function(e){return f.access(this,function(a,e,g){var h=yc(a);if(g===b)return h?c in h?h[c]:f.support.boxModel&&h.document.documentElement[e]||h.document.body[e]:a[e];h?h.scrollTo(d?f(h).scrollLeft():g,d?g:f(h).scrollTop()):a[e]=g},a,e,arguments.length,null)}}),f.each({Height:"height",Width:"width"},function(a,c){var d="client"+a,e="scroll"+a,g="offset"+a;f.fn["inner"+a]=function(){var a=this[0];return a?a.style?parseFloat(f.css(a,c,"padding")):this[c]():null},f.fn["outer"+a]=function(a){var b=this[0];return b?b.style?parseFloat(f.css(b,c,a?"margin":"border")):this[c]():null},f.fn[c]=function(a){return f.access(this,function(a,c,h){var i,j,k,l;if(f.isWindow(a))return i=a.document,j=i.documentElement[d],f.support.boxModel&&j||i.body&&i.body[d]||j;if(a.nodeType===9)return i=a.documentElement,i[d]>=i[e]?i[d]:Math.max(a.body[e],i[e],a.body[g],i[g]);if(h===b)return k=f.css(a,c),l=parseFloat(k),f.isNumeric(l)?l:k;f(a).css(c,h)},c,a,arguments.length,null)}}),a.jQuery=a.$=f,typeof define=="function"&&define.amd&&define.amd.jQuery&&define("jquery",[],function(){return f})})(window),function(a,b){var c;a.rails=c={linkClickSelector:"a[data-confirm], a[data-method], a[data-remote], a[data-disable-with]",inputChangeSelector:"select[data-remote], input[data-remote], textarea[data-remote]",formSubmitSelector:"form",formInputClickSelector:"form input[type=submit], form input[type=image], form button[type=submit], form button:not(button[type])",disableSelector:"input[data-disable-with], button[data-disable-with], textarea[data-disable-with]",enableSelector:"input[data-disable-with]:disabled, button[data-disable-with]:disabled, textarea[data-disable-with]:disabled",requiredInputSelector:"input[name][required]:not([disabled]),textarea[name][required]:not([disabled])",fileInputSelector:"input:file",linkDisableSelector:"a[data-disable-with]",CSRFProtection:function(b){var c=a('meta[name="csrf-token"]').attr("content");c&&b.setRequestHeader("X-CSRF-Token",c)},fire:function(b,c,d){var e=a.Event(c);return b.trigger(e,d),e.result!==!1},confirm:function(a){return confirm(a)},ajax:function(b){return a.ajax(b)},href:function(a){return a.attr("href")},handleRemote:function(d){var e,f,g,h,i,j;if(c.fire(d,"ajax:before")){h=d.data("cross-domain")||null,i=d.data("type")||a.ajaxSettings&&a.ajaxSettings.dataType;if(d.is("form")){e=d.attr("method"),f=d.attr("action"),g=d.serializeArray();var k=d.data("ujs:submit-button");k&&(g.push(k),d.data("ujs:submit-button",null))}else d.is(c.inputChangeSelector)?(e=d.data("method"),f=d.data("url"),g=d.serialize(),d.data("params")&&(g=g+"&"+d.data("params"))):(e=d.data("method"),f=c.href(d),g=d.data("params")||null);return j={type:e||"GET",data:g,dataType:i,crossDomain:h,beforeSend:function(a,e){return e.dataType===b&&a.setRequestHeader("accept","*/*;q=0.5, "+e.accepts.script),c.fire(d,"ajax:beforeSend",[a,e])},success:function(a,b,c){d.trigger("ajax:success",[a,b,c])},complete:function(a,b){d.trigger("ajax:complete",[a,b])},error:function(a,b,c){d.trigger("ajax:error",[a,b,c])}},f&&(j.url=f),c.ajax(j)}return!1},handleMethod:function(d){var e=c.href(d),f=d.data("method"),g=d.attr("target"),h=a("meta[name=csrf-token]").attr("content"),i=a("meta[name=csrf-param]").attr("content"),j=a('<form method="post" action="'+e+'"></form>'),k='<input name="_method" value="'+f+'" type="hidden" />';i!==b&&h!==b&&(k+='<input name="'+i+'" value="'+h+'" type="hidden" />'),g&&j.attr("target",g),j.hide().append(k).appendTo("body"),j.submit()},disableFormElements:function(b){b.find(c.disableSelector).each(function(){var b=a(this),c=b.is("button")?"html":"val";b.data("ujs:enable-with",b[c]()),b[c](b.data("disable-with")),b.prop("disabled",!0)})},enableFormElements:function(b){b.find(c.enableSelector).each(function(){var b=a(this),c=b.is("button")?"html":"val";b.data("ujs:enable-with")&&b[c](b.data("ujs:enable-with")),b.prop("disabled",!1)})},allowAction:function(a){var b=a.data("confirm"),d=!1,e;return b?(c.fire(a,"confirm")&&(d=c.confirm(b),e=c.fire(a,"confirm:complete",[d])),d&&e):!0},blankInputs:function(b,c,d){var e=a(),f,g=c||"input,textarea";return b.find(g).each(function(){f=a(this);if(d?f.val():!f.val())e=e.add(f)}),e.length?e:!1},nonBlankInputs:function(a,b){return c.blankInputs(a,b,!0)},stopEverything:function(b){return a(b.target).trigger("ujs:everythingStopped"),b.stopImmediatePropagation(),!1},callFormSubmitBindings
|
21
|
+
:function(c,d){var e=c.data("events"),f=!0;return e!==b&&e.submit!==b&&a.each(e.submit,function(a,b){if(typeof b.handler=="function")return f=b.handler(d)}),f},disableElement:function(a){a.data("ujs:enable-with",a.html()),a.html(a.data("disable-with")),a.bind("click.railsDisable",function(a){return c.stopEverything(a)})},enableElement:function(a){a.data("ujs:enable-with")!==b&&(a.html(a.data("ujs:enable-with")),a.data("ujs:enable-with",!1)),a.unbind("click.railsDisable")}},a.ajaxPrefilter(function(a,b,d){a.crossDomain||c.CSRFProtection(d)}),a(document).delegate(c.linkDisableSelector,"ajax:complete",function(){c.enableElement(a(this))}),a(document).delegate(c.linkClickSelector,"click.rails",function(d){var e=a(this),f=e.data("method"),g=e.data("params");if(!c.allowAction(e))return c.stopEverything(d);e.is(c.linkDisableSelector)&&c.disableElement(e);if(e.data("remote")!==b)return(d.metaKey||d.ctrlKey)&&(!f||f==="GET")&&!g?!0:(c.handleRemote(e)===!1&&c.enableElement(e),!1);if(e.data("method"))return c.handleMethod(e),!1}),a(document).delegate(c.inputChangeSelector,"change.rails",function(b){var d=a(this);return c.allowAction(d)?(c.handleRemote(d),!1):c.stopEverything(b)}),a(document).delegate(c.formSubmitSelector,"submit.rails",function(d){var e=a(this),f=e.data("remote")!==b,g=c.blankInputs(e,c.requiredInputSelector),h=c.nonBlankInputs(e,c.fileInputSelector);if(!c.allowAction(e))return c.stopEverything(d);if(g&&e.attr("novalidate")==b&&c.fire(e,"ajax:aborted:required",[g]))return c.stopEverything(d);if(f)return h?c.fire(e,"ajax:aborted:file",[h]):!a.support.submitBubbles&&a().jquery<"1.7"&&c.callFormSubmitBindings(e,d)===!1?c.stopEverything(d):(c.handleRemote(e),!1);setTimeout(function(){c.disableFormElements(e)},13)}),a(document).delegate(c.formInputClickSelector,"click.rails",function(b){var d=a(this);if(!c.allowAction(d))return c.stopEverything(b);var e=d.attr("name"),f=e?{name:e,value:d.val()}:null;d.closest("form").data("ujs:submit-button",f)}),a(document).delegate(c.formSubmitSelector,"ajax:beforeSend.rails",function(b){this==b.target&&c.disableFormElements(a(this))}),a(document).delegate(c.formSubmitSelector,"ajax:complete.rails",function(b){this==b.target&&c.enableFormElements(a(this))})}(jQuery);:@created_atf1335715283.0148971�
|
Binary file
|
Binary file
|
@@ -0,0 +1,285 @@
|
|
1
|
+
o: ActiveSupport::Cache::Entry :@expires_in0:@compressedF:@value"j${"content_type"application/javascript"
|
2
|
+
class"ProcessedAsset"dependency_digest"%d8d9220e541c203a44e262ae62e1ab4e"
|
3
|
+
mtime"2012-04-28T20:21:50-05:00"
|
4
|
+
mtime"2012-04-28T20:21:50-05:00"digest"%d0fee19d7243ca30c080e48708eace68" path"b/Users/njones/Code/rails_admin/app/assets/javascripts/rails_admin/ra.filtering-multiselect.js"digest"%88eedbff7f1ee38293b5eebff24feb93"required_paths["b/Users/njones/Code/rails_admin/app/assets/javascripts/rails_admin/ra.filtering-multiselect.js"
|
5
|
+
* RailsAdmin filtering multiselect @VERSION
|
6
|
+
*
|
7
|
+
* License
|
8
|
+
*
|
9
|
+
* http://www.railsadmin.org
|
10
|
+
*
|
11
|
+
* Depends:
|
12
|
+
* jquery.ui.core.js
|
13
|
+
* jquery.ui.widget.js
|
14
|
+
*/
|
15
|
+
|
16
|
+
(function($) {
|
17
|
+
$.widget("ra.filteringMultiselect", {
|
18
|
+
_cache: {},
|
19
|
+
options: {
|
20
|
+
createQuery: function(query) {
|
21
|
+
return { query: query };
|
22
|
+
},
|
23
|
+
sortable: false,
|
24
|
+
regional: {
|
25
|
+
up: "Up",
|
26
|
+
down: "Down",
|
27
|
+
add: "Add",
|
28
|
+
chooseAll: "Choose all",
|
29
|
+
chosen: "Chosen records",
|
30
|
+
clearAll: "Clear all",
|
31
|
+
remove: "Remove",
|
32
|
+
selectChoice: "Select your choice(s) and click"
|
33
|
+
},
|
34
|
+
searchDelay: 400,
|
35
|
+
remote_source: null,
|
36
|
+
xhr: false
|
37
|
+
},
|
38
|
+
|
39
|
+
_create: function() {
|
40
|
+
this._cache = {};
|
41
|
+
this._build();
|
42
|
+
this._buildCache();
|
43
|
+
this._bindEvents();
|
44
|
+
},
|
45
|
+
|
46
|
+
_build: function() {
|
47
|
+
var i;
|
48
|
+
|
49
|
+
this.wrapper = $('<div class="ra-multiselect">');
|
50
|
+
|
51
|
+
this.wrapper.insertAfter(this.element);
|
52
|
+
|
53
|
+
this.header = $('<div class="ra-multiselect-header ui-helper-clearfix">');
|
54
|
+
|
55
|
+
this.filter = $('<input type="search" placeholder="' + this.options.regional.search + '" class="ra-multiselect-search"/>');
|
56
|
+
|
57
|
+
this.header.append(this.filter);
|
58
|
+
|
59
|
+
this.wrapper.append(this.header);
|
60
|
+
|
61
|
+
this.columns = {
|
62
|
+
left: $('<div class="ra-multiselect-column ra-multiselect-left">'),
|
63
|
+
center: $('<div class="ra-multiselect-column ra-multiselect-center">'),
|
64
|
+
right: $('<div class="ra-multiselect-column ra-multiselect-right">')
|
65
|
+
};
|
66
|
+
|
67
|
+
for (i in this.columns) {
|
68
|
+
if (this.columns.hasOwnProperty(i)) {
|
69
|
+
this.wrapper.append(this.columns[i]);
|
70
|
+
}
|
71
|
+
}
|
72
|
+
|
73
|
+
this.collection = $('<select multiple="multiple"></select>');
|
74
|
+
|
75
|
+
this.collection.addClass("ra-multiselect-collection");
|
76
|
+
|
77
|
+
this.addAll = $('<a href="#" class="ra-multiselect-item-add-all"><span class="ui-icon ui-icon-circle-triangle-e"></span>' + this.options.regional.chooseAll + '</a>');
|
78
|
+
|
79
|
+
this.columns.left.append(this.collection)
|
80
|
+
.append(this.addAll);
|
81
|
+
|
82
|
+
this.add = $('<a href="#" class="ui-icon ui-icon-circle-triangle-e ra-multiselect-item-add">' + this.options.regional.add + '</a>');
|
83
|
+
|
84
|
+
this.remove = $('<a href="#" class="ui-icon ui-icon-circle-triangle-w ra-multiselect-item-remove">' + this.options.regional.remove + '</a>');
|
85
|
+
|
86
|
+
this.columns.center.append(this.add).append(this.remove)
|
87
|
+
if (this.options.sortable) {
|
88
|
+
this.up = $('<a href="#" class="ui-icon ui-icon-circle-triangle-n ra-multiselect-item-up">' + this.options.regional.up + '</a>');
|
89
|
+
this.down = $('<a href="#" class="ui-icon ui-icon-circle-triangle-s ra-multiselect-item-down">' + this.options.regional.down + '</a>');
|
90
|
+
this.columns.center.append(this.up).append(this.down);
|
91
|
+
}
|
92
|
+
|
93
|
+
this.selection = $('<select class="ra-multiselect-selection" multiple="multiple"></select>');
|
94
|
+
|
95
|
+
this.removeAll = $('<a href="#" class="ra-multiselect-item-remove-all"><span class="ui-icon ui-icon-circle-triangle-w"></span>' + this.options.regional.clearAll + '</a>');
|
96
|
+
|
97
|
+
this.columns.right.append(this.selection)
|
98
|
+
.append(this.removeAll);
|
99
|
+
|
100
|
+
this.element.css({display: "none"});
|
101
|
+
},
|
102
|
+
|
103
|
+
_bindEvents: function() {
|
104
|
+
var widget = this;
|
105
|
+
|
106
|
+
/* Add all to selection */
|
107
|
+
this.addAll.click(function(e){
|
108
|
+
widget._select($('option', widget.collection));
|
109
|
+
e.preventDefault();
|
110
|
+
});
|
111
|
+
|
112
|
+
/* Add to selection */
|
113
|
+
this.add.click(function(e){
|
114
|
+
widget._select($(':selected', widget.collection));
|
115
|
+
e.preventDefault();
|
116
|
+
});
|
117
|
+
|
118
|
+
/* Remove all from selection */
|
119
|
+
this.removeAll.click(function(e){
|
120
|
+
widget._deSelect($('option', widget.selection));
|
121
|
+
e.preventDefault();
|
122
|
+
});
|
123
|
+
|
124
|
+
/* Remove from selection */
|
125
|
+
this.remove.click(function(e){
|
126
|
+
widget._deSelect($(':selected', widget.selection));
|
127
|
+
e.preventDefault();
|
128
|
+
});
|
129
|
+
|
130
|
+
var timeout = null;
|
131
|
+
if(this.options.sortable) {
|
132
|
+
/* Move selection up */
|
133
|
+
this.up.click(function(e){
|
134
|
+
widget._move('up', $(':selected', widget.selection));
|
135
|
+
e.preventDefault();
|
136
|
+
});
|
137
|
+
|
138
|
+
/* Move selection down */
|
139
|
+
this.down.click(function(e){
|
140
|
+
widget._move('down', $(':selected', widget.selection));
|
141
|
+
e.preventDefault();
|
142
|
+
});
|
143
|
+
}
|
144
|
+
|
145
|
+
/* Typing to the filter */
|
146
|
+
this.filter.bind('keyup click', function(e){
|
147
|
+
if (timeout) { clearTimeout(timeout); }
|
148
|
+
timeout = setTimeout(function() {
|
149
|
+
widget._queryFilter(widget.filter.val());
|
150
|
+
}, widget.options.searchDelay
|
151
|
+
);
|
152
|
+
});
|
153
|
+
},
|
154
|
+
|
155
|
+
_queryFilter: function(val) {
|
156
|
+
var widget = this;
|
157
|
+
widget._query(val, function(matches) {
|
158
|
+
var i, html = "";
|
159
|
+
for (i in matches) {
|
160
|
+
if (matches.hasOwnProperty(i) && !widget.selected(matches[i].id)) {
|
161
|
+
html += '<option value="' + matches[i].id + '">' + matches[i].label + '</option>';
|
162
|
+
}
|
163
|
+
}
|
164
|
+
|
165
|
+
widget.collection.html(html);
|
166
|
+
});
|
167
|
+
},
|
168
|
+
|
169
|
+
_buildCache: function(options) {
|
170
|
+
var widget = this;
|
171
|
+
|
172
|
+
this.element.find("option").each(function(i, option) {
|
173
|
+
if (option.selected) {
|
174
|
+
widget._cache[option.value] = option.innerHTML;
|
175
|
+
$(option).clone().appendTo(widget.selection).attr("selected", false);
|
176
|
+
} else {
|
177
|
+
widget._cache[option.value] = option.innerHTML;
|
178
|
+
$(option).clone().appendTo(widget.collection).attr("selected", false);
|
179
|
+
}
|
180
|
+
});
|
181
|
+
},
|
182
|
+
|
183
|
+
_deSelect: function(options) {
|
184
|
+
var widget = this;
|
185
|
+
options.each(function(i, option) {
|
186
|
+
widget.element.find("option[value=" + option.value + "]").removeAttr("selected");
|
187
|
+
});
|
188
|
+
$(options).appendTo(this.collection).attr('selected', false);
|
189
|
+
},
|
190
|
+
|
191
|
+
_query: function(query, success) {
|
192
|
+
|
193
|
+
var i, matches = [];
|
194
|
+
|
195
|
+
if (query === "") {
|
196
|
+
|
197
|
+
if (!this.options.xhr) {
|
198
|
+
for (i in this._cache) {
|
199
|
+
if (this._cache.hasOwnProperty(i)) {
|
200
|
+
matches.push({id: i, label: this._cache[i]});
|
201
|
+
}
|
202
|
+
}
|
203
|
+
}
|
204
|
+
|
205
|
+
success.apply(this, [matches]);
|
206
|
+
|
207
|
+
} else {
|
208
|
+
|
209
|
+
if (this.options.xhr) {
|
210
|
+
|
211
|
+
$.ajax({
|
212
|
+
beforeSend: function(xhr) {
|
213
|
+
xhr.setRequestHeader("Accept", "application/json");
|
214
|
+
},
|
215
|
+
url: this.options.remote_source,
|
216
|
+
data: this.options.createQuery(query),
|
217
|
+
success: success
|
218
|
+
});
|
219
|
+
|
220
|
+
} else {
|
221
|
+
|
222
|
+
query = new RegExp(query + '.*', 'i');
|
223
|
+
|
224
|
+
for (i in this._cache) {
|
225
|
+
if (this._cache.hasOwnProperty(i) && query.test(this._cache[i])) {
|
226
|
+
matches.push({id: i, label: this._cache[i]});
|
227
|
+
}
|
228
|
+
}
|
229
|
+
|
230
|
+
success.apply(this, [matches]);
|
231
|
+
}
|
232
|
+
}
|
233
|
+
},
|
234
|
+
|
235
|
+
_select: function(options) {
|
236
|
+
var widget = this;
|
237
|
+
options.each(function(i, option) {
|
238
|
+
var el = widget.element.find("option[value=" + option.value + "]");
|
239
|
+
if (el.length) {
|
240
|
+
el.attr("selected", "selected");
|
241
|
+
} else {
|
242
|
+
widget.element.append($('<option value="' + option.value + '" selected="selected"></option>'));
|
243
|
+
}
|
244
|
+
});
|
245
|
+
$(options).appendTo(this.selection).attr('selected', false);
|
246
|
+
},
|
247
|
+
|
248
|
+
_move: function(direction, options) {
|
249
|
+
var widget = this;
|
250
|
+
if(direction == 'up') {
|
251
|
+
options.each(function(i, option) {
|
252
|
+
var prev = $(option).prev();
|
253
|
+
if (prev.length > 0) {
|
254
|
+
var el = widget.element.find("option[value=" + option.value + "]");
|
255
|
+
var el_prev = widget.element.find("option[value=" + prev[0].value + "]");
|
256
|
+
el_prev.before(el);
|
257
|
+
prev.before($(option));
|
258
|
+
}
|
259
|
+
});
|
260
|
+
} else {
|
261
|
+
$.fn.reverse = [].reverse; // needed to lower last items first
|
262
|
+
options.reverse().each(function(i, option) {
|
263
|
+
var next = $(option).next();
|
264
|
+
if (next.length > 0) {
|
265
|
+
var el = widget.element.find("option[value=" + option.value + "]");
|
266
|
+
var el_next = widget.element.find("option[value=" + next[0].value + "]");
|
267
|
+
el_next.after(el);
|
268
|
+
next.after($(option));
|
269
|
+
}
|
270
|
+
});
|
271
|
+
}
|
272
|
+
},
|
273
|
+
|
274
|
+
selected: function(value) {
|
275
|
+
return this.element.find("option[value=" + value + "]").attr("selected");
|
276
|
+
},
|
277
|
+
|
278
|
+
destroy: function() {
|
279
|
+
this.wrapper.remove();
|
280
|
+
this.element.css({display: "inline"});
|
281
|
+
$.Widget.prototype.destroy.apply(this, arguments);
|
282
|
+
}
|
283
|
+
});
|
284
|
+
})(jQuery);
|
285
|
+
:@created_atf1335716315.733639��
|
Binary file
|
@@ -0,0 +1,1833 @@
|
|
1
|
+
o: ActiveSupport::Cache::Entry :@expires_in0:@compressedF:@value"�/{"content_type"application/javascript"
|
2
|
+
class"ProcessedAsset"dependency_digest"%48c43e670200428629269c31ae439fd0"
|
3
|
+
mtime"2012-04-20T18:49:51-05:00"
|
4
|
+
mtime"2012-04-20T18:49:51-05:00"digest"%dea6588c6972886e1519b74b14ee79b5" path"h/Library/Ruby/Gems/1.8/gems/jquery-ui-rails-0.2.2/vendor/assets/javascripts/jquery.ui.datepicker.js{@"2012-04-28T19:31:29-05:00@"%33830d8b45ce2f9b31ccd9bdf5f3fc6e@"W/Library/Ruby/Gems/1.8/gems/jquery-rails-2.0.2/vendor/assets/javascripts/jquery.js{@"2012-04-20T18:49:51-05:00@"%7672653a2f5e4eab1758536a65296684@"b/Library/Ruby/Gems/1.8/gems/jquery-ui-rails-0.2.2/vendor/assets/javascripts/jquery.ui.core.js"digest"%2b326ac7516d93124e8fbb37d4041545"required_paths["W/Library/Ruby/Gems/1.8/gems/jquery-rails-2.0.2/vendor/assets/javascripts/jquery.js"b/Library/Ruby/Gems/1.8/gems/jquery-ui-rails-0.2.2/vendor/assets/javascripts/jquery.ui.core.js"h/Library/Ruby/Gems/1.8/gems/jquery-ui-rails-0.2.2/vendor/assets/javascripts/jquery.ui.datepicker.js"
|
5
|
+
|
6
|
+
/*!
|
7
|
+
* jQuery UI Datepicker 1.8.18
|
8
|
+
*
|
9
|
+
* Copyright 2011, AUTHORS.txt (http://jqueryui.com/about)
|
10
|
+
* Dual licensed under the MIT or GPL Version 2 licenses.
|
11
|
+
* http://jquery.org/license
|
12
|
+
*
|
13
|
+
* http://docs.jquery.com/UI/Datepicker
|
14
|
+
*
|
15
|
+
* Depends:
|
16
|
+
* jquery.ui.core.js
|
17
|
+
*/
|
18
|
+
|
19
|
+
(function( $, undefined ) {
|
20
|
+
|
21
|
+
$.extend($.ui, { datepicker: { version: "1.8.18" } });
|
22
|
+
|
23
|
+
var PROP_NAME = 'datepicker';
|
24
|
+
var dpuuid = new Date().getTime();
|
25
|
+
var instActive;
|
26
|
+
|
27
|
+
/* Date picker manager.
|
28
|
+
Use the singleton instance of this class, $.datepicker, to interact with the date picker.
|
29
|
+
Settings for (groups of) date pickers are maintained in an instance object,
|
30
|
+
allowing multiple different settings on the same page. */
|
31
|
+
|
32
|
+
function Datepicker() {
|
33
|
+
this.debug = false; // Change this to true to start debugging
|
34
|
+
this._curInst = null; // The current instance in use
|
35
|
+
this._keyEvent = false; // If the last event was a key event
|
36
|
+
this._disabledInputs = []; // List of date picker inputs that have been disabled
|
37
|
+
this._datepickerShowing = false; // True if the popup picker is showing , false if not
|
38
|
+
this._inDialog = false; // True if showing within a "dialog", false if not
|
39
|
+
this._mainDivId = 'ui-datepicker-div'; // The ID of the main datepicker division
|
40
|
+
this._inlineClass = 'ui-datepicker-inline'; // The name of the inline marker class
|
41
|
+
this._appendClass = 'ui-datepicker-append'; // The name of the append marker class
|
42
|
+
this._triggerClass = 'ui-datepicker-trigger'; // The name of the trigger marker class
|
43
|
+
this._dialogClass = 'ui-datepicker-dialog'; // The name of the dialog marker class
|
44
|
+
this._disableClass = 'ui-datepicker-disabled'; // The name of the disabled covering marker class
|
45
|
+
this._unselectableClass = 'ui-datepicker-unselectable'; // The name of the unselectable cell marker class
|
46
|
+
this._currentClass = 'ui-datepicker-current-day'; // The name of the current day marker class
|
47
|
+
this._dayOverClass = 'ui-datepicker-days-cell-over'; // The name of the day hover marker class
|
48
|
+
this.regional = []; // Available regional settings, indexed by language code
|
49
|
+
this.regional[''] = { // Default regional settings
|
50
|
+
closeText: 'Done', // Display text for close link
|
51
|
+
prevText: 'Prev', // Display text for previous month link
|
52
|
+
nextText: 'Next', // Display text for next month link
|
53
|
+
currentText: 'Today', // Display text for current month link
|
54
|
+
monthNames: ['January','February','March','April','May','June',
|
55
|
+
'July','August','September','October','November','December'], // Names of months for drop-down and formatting
|
56
|
+
monthNamesShort: ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'], // For formatting
|
57
|
+
dayNames: ['Sunday', 'Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday'], // For formatting
|
58
|
+
dayNamesShort: ['Sun', 'Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat'], // For formatting
|
59
|
+
dayNamesMin: ['Su','Mo','Tu','We','Th','Fr','Sa'], // Column headings for days starting at Sunday
|
60
|
+
weekHeader: 'Wk', // Column header for week of the year
|
61
|
+
dateFormat: 'mm/dd/yy', // See format options on parseDate
|
62
|
+
firstDay: 0, // The first day of the week, Sun = 0, Mon = 1, ...
|
63
|
+
isRTL: false, // True if right-to-left language, false if left-to-right
|
64
|
+
showMonthAfterYear: false, // True if the year select precedes month, false for month then year
|
65
|
+
yearSuffix: '' // Additional text to append to the year in the month headers
|
66
|
+
};
|
67
|
+
this._defaults = { // Global defaults for all the date picker instances
|
68
|
+
showOn: 'focus', // 'focus' for popup on focus,
|
69
|
+
// 'button' for trigger button, or 'both' for either
|
70
|
+
showAnim: 'fadeIn', // Name of jQuery animation for popup
|
71
|
+
showOptions: {}, // Options for enhanced animations
|
72
|
+
defaultDate: null, // Used when field is blank: actual date,
|
73
|
+
// +/-number for offset from today, null for today
|
74
|
+
appendText: '', // Display text following the input box, e.g. showing the format
|
75
|
+
buttonText: '...', // Text for trigger button
|
76
|
+
buttonImage: '', // URL for trigger button image
|
77
|
+
buttonImageOnly: false, // True if the image appears alone, false if it appears on a button
|
78
|
+
hideIfNoPrevNext: false, // True to hide next/previous month links
|
79
|
+
// if not applicable, false to just disable them
|
80
|
+
navigationAsDateFormat: false, // True if date formatting applied to prev/today/next links
|
81
|
+
gotoCurrent: false, // True if today link goes back to current selection instead
|
82
|
+
changeMonth: false, // True if month can be selected directly, false if only prev/next
|
83
|
+
changeYear: false, // True if year can be selected directly, false if only prev/next
|
84
|
+
yearRange: 'c-10:c+10', // Range of years to display in drop-down,
|
85
|
+
// either relative to today's year (-nn:+nn), relative to currently displayed year
|
86
|
+
// (c-nn:c+nn), absolute (nnnn:nnnn), or a combination of the above (nnnn:-n)
|
87
|
+
showOtherMonths: false, // True to show dates in other months, false to leave blank
|
88
|
+
selectOtherMonths: false, // True to allow selection of dates in other months, false for unselectable
|
89
|
+
showWeek: false, // True to show week of the year, false to not show it
|
90
|
+
calculateWeek: this.iso8601Week, // How to calculate the week of the year,
|
91
|
+
// takes a Date and returns the number of the week for it
|
92
|
+
shortYearCutoff: '+10', // Short year values < this are in the current century,
|
93
|
+
// > this are in the previous century,
|
94
|
+
// string value starting with '+' for current year + value
|
95
|
+
minDate: null, // The earliest selectable date, or null for no limit
|
96
|
+
maxDate: null, // The latest selectable date, or null for no limit
|
97
|
+
duration: 'fast', // Duration of display/closure
|
98
|
+
beforeShowDay: null, // Function that takes a date and returns an array with
|
99
|
+
// [0] = true if selectable, false if not, [1] = custom CSS class name(s) or '',
|
100
|
+
// [2] = cell title (optional), e.g. $.datepicker.noWeekends
|
101
|
+
beforeShow: null, // Function that takes an input field and
|
102
|
+
// returns a set of custom settings for the date picker
|
103
|
+
onSelect: null, // Define a callback function when a date is selected
|
104
|
+
onChangeMonthYear: null, // Define a callback function when the month or year is changed
|
105
|
+
onClose: null, // Define a callback function when the datepicker is closed
|
106
|
+
numberOfMonths: 1, // Number of months to show at a time
|
107
|
+
showCurrentAtPos: 0, // The position in multipe months at which to show the current month (starting at 0)
|
108
|
+
stepMonths: 1, // Number of months to step back/forward
|
109
|
+
stepBigMonths: 12, // Number of months to step back/forward for the big links
|
110
|
+
altField: '', // Selector for an alternate field to store selected dates into
|
111
|
+
altFormat: '', // The date format to use for the alternate field
|
112
|
+
constrainInput: true, // The input is constrained by the current date format
|
113
|
+
showButtonPanel: false, // True to show button panel, false to not show it
|
114
|
+
autoSize: false, // True to size the input for the date format, false to leave as is
|
115
|
+
disabled: false // The initial disabled state
|
116
|
+
};
|
117
|
+
$.extend(this._defaults, this.regional['']);
|
118
|
+
this.dpDiv = bindHover($('<div id="' + this._mainDivId + '" class="ui-datepicker ui-widget ui-widget-content ui-helper-clearfix ui-corner-all"></div>'));
|
119
|
+
}
|
120
|
+
|
121
|
+
$.extend(Datepicker.prototype, {
|
122
|
+
/* Class name added to elements to indicate already configured with a date picker. */
|
123
|
+
markerClassName: 'hasDatepicker',
|
124
|
+
|
125
|
+
//Keep track of the maximum number of rows displayed (see #7043)
|
126
|
+
maxRows: 4,
|
127
|
+
|
128
|
+
/* Debug logging (if enabled). */
|
129
|
+
log: function () {
|
130
|
+
if (this.debug)
|
131
|
+
console.log.apply('', arguments);
|
132
|
+
},
|
133
|
+
|
134
|
+
// TODO rename to "widget" when switching to widget factory
|
135
|
+
_widgetDatepicker: function() {
|
136
|
+
return this.dpDiv;
|
137
|
+
},
|
138
|
+
|
139
|
+
/* Override the default settings for all instances of the date picker.
|
140
|
+
@param settings object - the new settings to use as defaults (anonymous object)
|
141
|
+
@return the manager object */
|
142
|
+
setDefaults: function(settings) {
|
143
|
+
extendRemove(this._defaults, settings || {});
|
144
|
+
return this;
|
145
|
+
},
|
146
|
+
|
147
|
+
/* Attach the date picker to a jQuery selection.
|
148
|
+
@param target element - the target input field or division or span
|
149
|
+
@param settings object - the new settings to use for this date picker instance (anonymous) */
|
150
|
+
_attachDatepicker: function(target, settings) {
|
151
|
+
// check for settings on the control itself - in namespace 'date:'
|
152
|
+
var inlineSettings = null;
|
153
|
+
for (var attrName in this._defaults) {
|
154
|
+
var attrValue = target.getAttribute('date:' + attrName);
|
155
|
+
if (attrValue) {
|
156
|
+
inlineSettings = inlineSettings || {};
|
157
|
+
try {
|
158
|
+
inlineSettings[attrName] = eval(attrValue);
|
159
|
+
} catch (err) {
|
160
|
+
inlineSettings[attrName] = attrValue;
|
161
|
+
}
|
162
|
+
}
|
163
|
+
}
|
164
|
+
var nodeName = target.nodeName.toLowerCase();
|
165
|
+
var inline = (nodeName == 'div' || nodeName == 'span');
|
166
|
+
if (!target.id) {
|
167
|
+
this.uuid += 1;
|
168
|
+
target.id = 'dp' + this.uuid;
|
169
|
+
}
|
170
|
+
var inst = this._newInst($(target), inline);
|
171
|
+
inst.settings = $.extend({}, settings || {}, inlineSettings || {});
|
172
|
+
if (nodeName == 'input') {
|
173
|
+
this._connectDatepicker(target, inst);
|
174
|
+
} else if (inline) {
|
175
|
+
this._inlineDatepicker(target, inst);
|
176
|
+
}
|
177
|
+
},
|
178
|
+
|
179
|
+
/* Create a new instance object. */
|
180
|
+
_newInst: function(target, inline) {
|
181
|
+
var id = target[0].id.replace(/([^A-Za-z0-9_-])/g, '\\\\$1'); // escape jQuery meta chars
|
182
|
+
return {id: id, input: target, // associated target
|
183
|
+
selectedDay: 0, selectedMonth: 0, selectedYear: 0, // current selection
|
184
|
+
drawMonth: 0, drawYear: 0, // month being drawn
|
185
|
+
inline: inline, // is datepicker inline or not
|
186
|
+
dpDiv: (!inline ? this.dpDiv : // presentation div
|
187
|
+
bindHover($('<div class="' + this._inlineClass + ' ui-datepicker ui-widget ui-widget-content ui-helper-clearfix ui-corner-all"></div>')))};
|
188
|
+
},
|
189
|
+
|
190
|
+
/* Attach the date picker to an input field. */
|
191
|
+
_connectDatepicker: function(target, inst) {
|
192
|
+
var input = $(target);
|
193
|
+
inst.append = $([]);
|
194
|
+
inst.trigger = $([]);
|
195
|
+
if (input.hasClass(this.markerClassName))
|
196
|
+
return;
|
197
|
+
this._attachments(input, inst);
|
198
|
+
input.addClass(this.markerClassName).keydown(this._doKeyDown).
|
199
|
+
keypress(this._doKeyPress).keyup(this._doKeyUp).
|
200
|
+
bind("setData.datepicker", function(event, key, value) {
|
201
|
+
inst.settings[key] = value;
|
202
|
+
}).bind("getData.datepicker", function(event, key) {
|
203
|
+
return this._get(inst, key);
|
204
|
+
});
|
205
|
+
this._autoSize(inst);
|
206
|
+
$.data(target, PROP_NAME, inst);
|
207
|
+
//If disabled option is true, disable the datepicker once it has been attached to the input (see ticket #5665)
|
208
|
+
if( inst.settings.disabled ) {
|
209
|
+
this._disableDatepicker( target );
|
210
|
+
}
|
211
|
+
},
|
212
|
+
|
213
|
+
/* Make attachments based on settings. */
|
214
|
+
_attachments: function(input, inst) {
|
215
|
+
var appendText = this._get(inst, 'appendText');
|
216
|
+
var isRTL = this._get(inst, 'isRTL');
|
217
|
+
if (inst.append)
|
218
|
+
inst.append.remove();
|
219
|
+
if (appendText) {
|
220
|
+
inst.append = $('<span class="' + this._appendClass + '">' + appendText + '</span>');
|
221
|
+
input[isRTL ? 'before' : 'after'](inst.append);
|
222
|
+
}
|
223
|
+
input.unbind('focus', this._showDatepicker);
|
224
|
+
if (inst.trigger)
|
225
|
+
inst.trigger.remove();
|
226
|
+
var showOn = this._get(inst, 'showOn');
|
227
|
+
if (showOn == 'focus' || showOn == 'both') // pop-up date picker when in the marked field
|
228
|
+
input.focus(this._showDatepicker);
|
229
|
+
if (showOn == 'button' || showOn == 'both') { // pop-up date picker when button clicked
|
230
|
+
var buttonText = this._get(inst, 'buttonText');
|
231
|
+
var buttonImage = this._get(inst, 'buttonImage');
|
232
|
+
inst.trigger = $(this._get(inst, 'buttonImageOnly') ?
|
233
|
+
$('<img/>').addClass(this._triggerClass).
|
234
|
+
attr({ src: buttonImage, alt: buttonText, title: buttonText }) :
|
235
|
+
$('<button type="button"></button>').addClass(this._triggerClass).
|
236
|
+
html(buttonImage == '' ? buttonText : $('<img/>').attr(
|
237
|
+
{ src:buttonImage, alt:buttonText, title:buttonText })));
|
238
|
+
input[isRTL ? 'before' : 'after'](inst.trigger);
|
239
|
+
inst.trigger.click(function() {
|
240
|
+
if ($.datepicker._datepickerShowing && $.datepicker._lastInput == input[0])
|
241
|
+
$.datepicker._hideDatepicker();
|
242
|
+
else if ($.datepicker._datepickerShowing && $.datepicker._lastInput != input[0]) {
|
243
|
+
$.datepicker._hideDatepicker();
|
244
|
+
$.datepicker._showDatepicker(input[0]);
|
245
|
+
} else
|
246
|
+
$.datepicker._showDatepicker(input[0]);
|
247
|
+
return false;
|
248
|
+
});
|
249
|
+
}
|
250
|
+
},
|
251
|
+
|
252
|
+
/* Apply the maximum length for the date format. */
|
253
|
+
_autoSize: function(inst) {
|
254
|
+
if (this._get(inst, 'autoSize') && !inst.inline) {
|
255
|
+
var date = new Date(2009, 12 - 1, 20); // Ensure double digits
|
256
|
+
var dateFormat = this._get(inst, 'dateFormat');
|
257
|
+
if (dateFormat.match(/[DM]/)) {
|
258
|
+
var findMax = function(names) {
|
259
|
+
var max = 0;
|
260
|
+
var maxI = 0;
|
261
|
+
for (var i = 0; i < names.length; i++) {
|
262
|
+
if (names[i].length > max) {
|
263
|
+
max = names[i].length;
|
264
|
+
maxI = i;
|
265
|
+
}
|
266
|
+
}
|
267
|
+
return maxI;
|
268
|
+
};
|
269
|
+
date.setMonth(findMax(this._get(inst, (dateFormat.match(/MM/) ?
|
270
|
+
'monthNames' : 'monthNamesShort'))));
|
271
|
+
date.setDate(findMax(this._get(inst, (dateFormat.match(/DD/) ?
|
272
|
+
'dayNames' : 'dayNamesShort'))) + 20 - date.getDay());
|
273
|
+
}
|
274
|
+
inst.input.attr('size', this._formatDate(inst, date).length);
|
275
|
+
}
|
276
|
+
},
|
277
|
+
|
278
|
+
/* Attach an inline date picker to a div. */
|
279
|
+
_inlineDatepicker: function(target, inst) {
|
280
|
+
var divSpan = $(target);
|
281
|
+
if (divSpan.hasClass(this.markerClassName))
|
282
|
+
return;
|
283
|
+
divSpan.addClass(this.markerClassName).append(inst.dpDiv).
|
284
|
+
bind("setData.datepicker", function(event, key, value){
|
285
|
+
inst.settings[key] = value;
|
286
|
+
}).bind("getData.datepicker", function(event, key){
|
287
|
+
return this._get(inst, key);
|
288
|
+
});
|
289
|
+
$.data(target, PROP_NAME, inst);
|
290
|
+
this._setDate(inst, this._getDefaultDate(inst), true);
|
291
|
+
this._updateDatepicker(inst);
|
292
|
+
this._updateAlternate(inst);
|
293
|
+
//If disabled option is true, disable the datepicker before showing it (see ticket #5665)
|
294
|
+
if( inst.settings.disabled ) {
|
295
|
+
this._disableDatepicker( target );
|
296
|
+
}
|
297
|
+
// Set display:block in place of inst.dpDiv.show() which won't work on disconnected elements
|
298
|
+
// http://bugs.jqueryui.com/ticket/7552 - A Datepicker created on a detached div has zero height
|
299
|
+
inst.dpDiv.css( "display", "block" );
|
300
|
+
},
|
301
|
+
|
302
|
+
/* Pop-up the date picker in a "dialog" box.
|
303
|
+
@param input element - ignored
|
304
|
+
@param date string or Date - the initial date to display
|
305
|
+
@param onSelect function - the function to call when a date is selected
|
306
|
+
@param settings object - update the dialog date picker instance's settings (anonymous object)
|
307
|
+
@param pos int[2] - coordinates for the dialog's position within the screen or
|
308
|
+
event - with x/y coordinates or
|
309
|
+
leave empty for default (screen centre)
|
310
|
+
@return the manager object */
|
311
|
+
_dialogDatepicker: function(input, date, onSelect, settings, pos) {
|
312
|
+
var inst = this._dialogInst; // internal instance
|
313
|
+
if (!inst) {
|
314
|
+
this.uuid += 1;
|
315
|
+
var id = 'dp' + this.uuid;
|
316
|
+
this._dialogInput = $('<input type="text" id="' + id +
|
317
|
+
'" style="position: absolute; top: -100px; width: 0px; z-index: -10;"/>');
|
318
|
+
this._dialogInput.keydown(this._doKeyDown);
|
319
|
+
$('body').append(this._dialogInput);
|
320
|
+
inst = this._dialogInst = this._newInst(this._dialogInput, false);
|
321
|
+
inst.settings = {};
|
322
|
+
$.data(this._dialogInput[0], PROP_NAME, inst);
|
323
|
+
}
|
324
|
+
extendRemove(inst.settings, settings || {});
|
325
|
+
date = (date && date.constructor == Date ? this._formatDate(inst, date) : date);
|
326
|
+
this._dialogInput.val(date);
|
327
|
+
|
328
|
+
this._pos = (pos ? (pos.length ? pos : [pos.pageX, pos.pageY]) : null);
|
329
|
+
if (!this._pos) {
|
330
|
+
var browserWidth = document.documentElement.clientWidth;
|
331
|
+
var browserHeight = document.documentElement.clientHeight;
|
332
|
+
var scrollX = document.documentElement.scrollLeft || document.body.scrollLeft;
|
333
|
+
var scrollY = document.documentElement.scrollTop || document.body.scrollTop;
|
334
|
+
this._pos = // should use actual width/height below
|
335
|
+
[(browserWidth / 2) - 100 + scrollX, (browserHeight / 2) - 150 + scrollY];
|
336
|
+
}
|
337
|
+
|
338
|
+
// move input on screen for focus, but hidden behind dialog
|
339
|
+
this._dialogInput.css('left', (this._pos[0] + 20) + 'px').css('top', this._pos[1] + 'px');
|
340
|
+
inst.settings.onSelect = onSelect;
|
341
|
+
this._inDialog = true;
|
342
|
+
this.dpDiv.addClass(this._dialogClass);
|
343
|
+
this._showDatepicker(this._dialogInput[0]);
|
344
|
+
if ($.blockUI)
|
345
|
+
$.blockUI(this.dpDiv);
|
346
|
+
$.data(this._dialogInput[0], PROP_NAME, inst);
|
347
|
+
return this;
|
348
|
+
},
|
349
|
+
|
350
|
+
/* Detach a datepicker from its control.
|
351
|
+
@param target element - the target input field or division or span */
|
352
|
+
_destroyDatepicker: function(target) {
|
353
|
+
var $target = $(target);
|
354
|
+
var inst = $.data(target, PROP_NAME);
|
355
|
+
if (!$target.hasClass(this.markerClassName)) {
|
356
|
+
return;
|
357
|
+
}
|
358
|
+
var nodeName = target.nodeName.toLowerCase();
|
359
|
+
$.removeData(target, PROP_NAME);
|
360
|
+
if (nodeName == 'input') {
|
361
|
+
inst.append.remove();
|
362
|
+
inst.trigger.remove();
|
363
|
+
$target.removeClass(this.markerClassName).
|
364
|
+
unbind('focus', this._showDatepicker).
|
365
|
+
unbind('keydown', this._doKeyDown).
|
366
|
+
unbind('keypress', this._doKeyPress).
|
367
|
+
unbind('keyup', this._doKeyUp);
|
368
|
+
} else if (nodeName == 'div' || nodeName == 'span')
|
369
|
+
$target.removeClass(this.markerClassName).empty();
|
370
|
+
},
|
371
|
+
|
372
|
+
/* Enable the date picker to a jQuery selection.
|
373
|
+
@param target element - the target input field or division or span */
|
374
|
+
_enableDatepicker: function(target) {
|
375
|
+
var $target = $(target);
|
376
|
+
var inst = $.data(target, PROP_NAME);
|
377
|
+
if (!$target.hasClass(this.markerClassName)) {
|
378
|
+
return;
|
379
|
+
}
|
380
|
+
var nodeName = target.nodeName.toLowerCase();
|
381
|
+
if (nodeName == 'input') {
|
382
|
+
target.disabled = false;
|
383
|
+
inst.trigger.filter('button').
|
384
|
+
each(function() { this.disabled = false; }).end().
|
385
|
+
filter('img').css({opacity: '1.0', cursor: ''});
|
386
|
+
}
|
387
|
+
else if (nodeName == 'div' || nodeName == 'span') {
|
388
|
+
var inline = $target.children('.' + this._inlineClass);
|
389
|
+
inline.children().removeClass('ui-state-disabled');
|
390
|
+
inline.find("select.ui-datepicker-month, select.ui-datepicker-year").
|
391
|
+
removeAttr("disabled");
|
392
|
+
}
|
393
|
+
this._disabledInputs = $.map(this._disabledInputs,
|
394
|
+
function(value) { return (value == target ? null : value); }); // delete entry
|
395
|
+
},
|
396
|
+
|
397
|
+
/* Disable the date picker to a jQuery selection.
|
398
|
+
@param target element - the target input field or division or span */
|
399
|
+
_disableDatepicker: function(target) {
|
400
|
+
var $target = $(target);
|
401
|
+
var inst = $.data(target, PROP_NAME);
|
402
|
+
if (!$target.hasClass(this.markerClassName)) {
|
403
|
+
return;
|
404
|
+
}
|
405
|
+
var nodeName = target.nodeName.toLowerCase();
|
406
|
+
if (nodeName == 'input') {
|
407
|
+
target.disabled = true;
|
408
|
+
inst.trigger.filter('button').
|
409
|
+
each(function() { this.disabled = true; }).end().
|
410
|
+
filter('img').css({opacity: '0.5', cursor: 'default'});
|
411
|
+
}
|
412
|
+
else if (nodeName == 'div' || nodeName == 'span') {
|
413
|
+
var inline = $target.children('.' + this._inlineClass);
|
414
|
+
inline.children().addClass('ui-state-disabled');
|
415
|
+
inline.find("select.ui-datepicker-month, select.ui-datepicker-year").
|
416
|
+
attr("disabled", "disabled");
|
417
|
+
}
|
418
|
+
this._disabledInputs = $.map(this._disabledInputs,
|
419
|
+
function(value) { return (value == target ? null : value); }); // delete entry
|
420
|
+
this._disabledInputs[this._disabledInputs.length] = target;
|
421
|
+
},
|
422
|
+
|
423
|
+
/* Is the first field in a jQuery collection disabled as a datepicker?
|
424
|
+
@param target element - the target input field or division or span
|
425
|
+
@return boolean - true if disabled, false if enabled */
|
426
|
+
_isDisabledDatepicker: function(target) {
|
427
|
+
if (!target) {
|
428
|
+
return false;
|
429
|
+
}
|
430
|
+
for (var i = 0; i < this._disabledInputs.length; i++) {
|
431
|
+
if (this._disabledInputs[i] == target)
|
432
|
+
return true;
|
433
|
+
}
|
434
|
+
return false;
|
435
|
+
},
|
436
|
+
|
437
|
+
/* Retrieve the instance data for the target control.
|
438
|
+
@param target element - the target input field or division or span
|
439
|
+
@return object - the associated instance data
|
440
|
+
@throws error if a jQuery problem getting data */
|
441
|
+
_getInst: function(target) {
|
442
|
+
try {
|
443
|
+
return $.data(target, PROP_NAME);
|
444
|
+
}
|
445
|
+
catch (err) {
|
446
|
+
throw 'Missing instance data for this datepicker';
|
447
|
+
}
|
448
|
+
},
|
449
|
+
|
450
|
+
/* Update or retrieve the settings for a date picker attached to an input field or division.
|
451
|
+
@param target element - the target input field or division or span
|
452
|
+
@param name object - the new settings to update or
|
453
|
+
string - the name of the setting to change or retrieve,
|
454
|
+
when retrieving also 'all' for all instance settings or
|
455
|
+
'defaults' for all global defaults
|
456
|
+
@param value any - the new value for the setting
|
457
|
+
(omit if above is an object or to retrieve a value) */
|
458
|
+
_optionDatepicker: function(target, name, value) {
|
459
|
+
var inst = this._getInst(target);
|
460
|
+
if (arguments.length == 2 && typeof name == 'string') {
|
461
|
+
return (name == 'defaults' ? $.extend({}, $.datepicker._defaults) :
|
462
|
+
(inst ? (name == 'all' ? $.extend({}, inst.settings) :
|
463
|
+
this._get(inst, name)) : null));
|
464
|
+
}
|
465
|
+
var settings = name || {};
|
466
|
+
if (typeof name == 'string') {
|
467
|
+
settings = {};
|
468
|
+
settings[name] = value;
|
469
|
+
}
|
470
|
+
if (inst) {
|
471
|
+
if (this._curInst == inst) {
|
472
|
+
this._hideDatepicker();
|
473
|
+
}
|
474
|
+
var date = this._getDateDatepicker(target, true);
|
475
|
+
var minDate = this._getMinMaxDate(inst, 'min');
|
476
|
+
var maxDate = this._getMinMaxDate(inst, 'max');
|
477
|
+
extendRemove(inst.settings, settings);
|
478
|
+
// reformat the old minDate/maxDate values if dateFormat changes and a new minDate/maxDate isn't provided
|
479
|
+
if (minDate !== null && settings['dateFormat'] !== undefined && settings['minDate'] === undefined)
|
480
|
+
inst.settings.minDate = this._formatDate(inst, minDate);
|
481
|
+
if (maxDate !== null && settings['dateFormat'] !== undefined && settings['maxDate'] === undefined)
|
482
|
+
inst.settings.maxDate = this._formatDate(inst, maxDate);
|
483
|
+
this._attachments($(target), inst);
|
484
|
+
this._autoSize(inst);
|
485
|
+
this._setDate(inst, date);
|
486
|
+
this._updateAlternate(inst);
|
487
|
+
this._updateDatepicker(inst);
|
488
|
+
}
|
489
|
+
},
|
490
|
+
|
491
|
+
// change method deprecated
|
492
|
+
_changeDatepicker: function(target, name, value) {
|
493
|
+
this._optionDatepicker(target, name, value);
|
494
|
+
},
|
495
|
+
|
496
|
+
/* Redraw the date picker attached to an input field or division.
|
497
|
+
@param target element - the target input field or division or span */
|
498
|
+
_refreshDatepicker: function(target) {
|
499
|
+
var inst = this._getInst(target);
|
500
|
+
if (inst) {
|
501
|
+
this._updateDatepicker(inst);
|
502
|
+
}
|
503
|
+
},
|
504
|
+
|
505
|
+
/* Set the dates for a jQuery selection.
|
506
|
+
@param target element - the target input field or division or span
|
507
|
+
@param date Date - the new date */
|
508
|
+
_setDateDatepicker: function(target, date) {
|
509
|
+
var inst = this._getInst(target);
|
510
|
+
if (inst) {
|
511
|
+
this._setDate(inst, date);
|
512
|
+
this._updateDatepicker(inst);
|
513
|
+
this._updateAlternate(inst);
|
514
|
+
}
|
515
|
+
},
|
516
|
+
|
517
|
+
/* Get the date(s) for the first entry in a jQuery selection.
|
518
|
+
@param target element - the target input field or division or span
|
519
|
+
@param noDefault boolean - true if no default date is to be used
|
520
|
+
@return Date - the current date */
|
521
|
+
_getDateDatepicker: function(target, noDefault) {
|
522
|
+
var inst = this._getInst(target);
|
523
|
+
if (inst && !inst.inline)
|
524
|
+
this._setDateFromField(inst, noDefault);
|
525
|
+
return (inst ? this._getDate(inst) : null);
|
526
|
+
},
|
527
|
+
|
528
|
+
/* Handle keystrokes. */
|
529
|
+
_doKeyDown: function(event) {
|
530
|
+
var inst = $.datepicker._getInst(event.target);
|
531
|
+
var handled = true;
|
532
|
+
var isRTL = inst.dpDiv.is('.ui-datepicker-rtl');
|
533
|
+
inst._keyEvent = true;
|
534
|
+
if ($.datepicker._datepickerShowing)
|
535
|
+
switch (event.keyCode) {
|
536
|
+
case 9: $.datepicker._hideDatepicker();
|
537
|
+
handled = false;
|
538
|
+
break; // hide on tab out
|
539
|
+
case 13: var sel = $('td.' + $.datepicker._dayOverClass + ':not(.' +
|
540
|
+
$.datepicker._currentClass + ')', inst.dpDiv);
|
541
|
+
if (sel[0])
|
542
|
+
$.datepicker._selectDay(event.target, inst.selectedMonth, inst.selectedYear, sel[0]);
|
543
|
+
var onSelect = $.datepicker._get(inst, 'onSelect');
|
544
|
+
if (onSelect) {
|
545
|
+
var dateStr = $.datepicker._formatDate(inst);
|
546
|
+
|
547
|
+
// trigger custom callback
|
548
|
+
onSelect.apply((inst.input ? inst.input[0] : null), [dateStr, inst]);
|
549
|
+
}
|
550
|
+
else
|
551
|
+
$.datepicker._hideDatepicker();
|
552
|
+
return false; // don't submit the form
|
553
|
+
break; // select the value on enter
|
554
|
+
case 27: $.datepicker._hideDatepicker();
|
555
|
+
break; // hide on escape
|
556
|
+
case 33: $.datepicker._adjustDate(event.target, (event.ctrlKey ?
|
557
|
+
-$.datepicker._get(inst, 'stepBigMonths') :
|
558
|
+
-$.datepicker._get(inst, 'stepMonths')), 'M');
|
559
|
+
break; // previous month/year on page up/+ ctrl
|
560
|
+
case 34: $.datepicker._adjustDate(event.target, (event.ctrlKey ?
|
561
|
+
+$.datepicker._get(inst, 'stepBigMonths') :
|
562
|
+
+$.datepicker._get(inst, 'stepMonths')), 'M');
|
563
|
+
break; // next month/year on page down/+ ctrl
|
564
|
+
case 35: if (event.ctrlKey || event.metaKey) $.datepicker._clearDate(event.target);
|
565
|
+
handled = event.ctrlKey || event.metaKey;
|
566
|
+
break; // clear on ctrl or command +end
|
567
|
+
case 36: if (event.ctrlKey || event.metaKey) $.datepicker._gotoToday(event.target);
|
568
|
+
handled = event.ctrlKey || event.metaKey;
|
569
|
+
break; // current on ctrl or command +home
|
570
|
+
case 37: if (event.ctrlKey || event.metaKey) $.datepicker._adjustDate(event.target, (isRTL ? +1 : -1), 'D');
|
571
|
+
handled = event.ctrlKey || event.metaKey;
|
572
|
+
// -1 day on ctrl or command +left
|
573
|
+
if (event.originalEvent.altKey) $.datepicker._adjustDate(event.target, (event.ctrlKey ?
|
574
|
+
-$.datepicker._get(inst, 'stepBigMonths') :
|
575
|
+
-$.datepicker._get(inst, 'stepMonths')), 'M');
|
576
|
+
// next month/year on alt +left on Mac
|
577
|
+
break;
|
578
|
+
case 38: if (event.ctrlKey || event.metaKey) $.datepicker._adjustDate(event.target, -7, 'D');
|
579
|
+
handled = event.ctrlKey || event.metaKey;
|
580
|
+
break; // -1 week on ctrl or command +up
|
581
|
+
case 39: if (event.ctrlKey || event.metaKey) $.datepicker._adjustDate(event.target, (isRTL ? -1 : +1), 'D');
|
582
|
+
handled = event.ctrlKey || event.metaKey;
|
583
|
+
// +1 day on ctrl or command +right
|
584
|
+
if (event.originalEvent.altKey) $.datepicker._adjustDate(event.target, (event.ctrlKey ?
|
585
|
+
+$.datepicker._get(inst, 'stepBigMonths') :
|
586
|
+
+$.datepicker._get(inst, 'stepMonths')), 'M');
|
587
|
+
// next month/year on alt +right
|
588
|
+
break;
|
589
|
+
case 40: if (event.ctrlKey || event.metaKey) $.datepicker._adjustDate(event.target, +7, 'D');
|
590
|
+
handled = event.ctrlKey || event.metaKey;
|
591
|
+
break; // +1 week on ctrl or command +down
|
592
|
+
default: handled = false;
|
593
|
+
}
|
594
|
+
else if (event.keyCode == 36 && event.ctrlKey) // display the date picker on ctrl+home
|
595
|
+
$.datepicker._showDatepicker(this);
|
596
|
+
else {
|
597
|
+
handled = false;
|
598
|
+
}
|
599
|
+
if (handled) {
|
600
|
+
event.preventDefault();
|
601
|
+
event.stopPropagation();
|
602
|
+
}
|
603
|
+
},
|
604
|
+
|
605
|
+
/* Filter entered characters - based on date format. */
|
606
|
+
_doKeyPress: function(event) {
|
607
|
+
var inst = $.datepicker._getInst(event.target);
|
608
|
+
if ($.datepicker._get(inst, 'constrainInput')) {
|
609
|
+
var chars = $.datepicker._possibleChars($.datepicker._get(inst, 'dateFormat'));
|
610
|
+
var chr = String.fromCharCode(event.charCode == undefined ? event.keyCode : event.charCode);
|
611
|
+
return event.ctrlKey || event.metaKey || (chr < ' ' || !chars || chars.indexOf(chr) > -1);
|
612
|
+
}
|
613
|
+
},
|
614
|
+
|
615
|
+
/* Synchronise manual entry and field/alternate field. */
|
616
|
+
_doKeyUp: function(event) {
|
617
|
+
var inst = $.datepicker._getInst(event.target);
|
618
|
+
if (inst.input.val() != inst.lastVal) {
|
619
|
+
try {
|
620
|
+
var date = $.datepicker.parseDate($.datepicker._get(inst, 'dateFormat'),
|
621
|
+
(inst.input ? inst.input.val() : null),
|
622
|
+
$.datepicker._getFormatConfig(inst));
|
623
|
+
if (date) { // only if valid
|
624
|
+
$.datepicker._setDateFromField(inst);
|
625
|
+
$.datepicker._updateAlternate(inst);
|
626
|
+
$.datepicker._updateDatepicker(inst);
|
627
|
+
}
|
628
|
+
}
|
629
|
+
catch (event) {
|
630
|
+
$.datepicker.log(event);
|
631
|
+
}
|
632
|
+
}
|
633
|
+
return true;
|
634
|
+
},
|
635
|
+
|
636
|
+
/* Pop-up the date picker for a given input field.
|
637
|
+
If false returned from beforeShow event handler do not show.
|
638
|
+
@param input element - the input field attached to the date picker or
|
639
|
+
event - if triggered by focus */
|
640
|
+
_showDatepicker: function(input) {
|
641
|
+
input = input.target || input;
|
642
|
+
if (input.nodeName.toLowerCase() != 'input') // find from button/image trigger
|
643
|
+
input = $('input', input.parentNode)[0];
|
644
|
+
if ($.datepicker._isDisabledDatepicker(input) || $.datepicker._lastInput == input) // already here
|
645
|
+
return;
|
646
|
+
var inst = $.datepicker._getInst(input);
|
647
|
+
if ($.datepicker._curInst && $.datepicker._curInst != inst) {
|
648
|
+
$.datepicker._curInst.dpDiv.stop(true, true);
|
649
|
+
if ( inst && $.datepicker._datepickerShowing ) {
|
650
|
+
$.datepicker._hideDatepicker( $.datepicker._curInst.input[0] );
|
651
|
+
}
|
652
|
+
}
|
653
|
+
var beforeShow = $.datepicker._get(inst, 'beforeShow');
|
654
|
+
var beforeShowSettings = beforeShow ? beforeShow.apply(input, [input, inst]) : {};
|
655
|
+
if(beforeShowSettings === false){
|
656
|
+
//false
|
657
|
+
return;
|
658
|
+
}
|
659
|
+
extendRemove(inst.settings, beforeShowSettings);
|
660
|
+
inst.lastVal = null;
|
661
|
+
$.datepicker._lastInput = input;
|
662
|
+
$.datepicker._setDateFromField(inst);
|
663
|
+
if ($.datepicker._inDialog) // hide cursor
|
664
|
+
input.value = '';
|
665
|
+
if (!$.datepicker._pos) { // position below input
|
666
|
+
$.datepicker._pos = $.datepicker._findPos(input);
|
667
|
+
$.datepicker._pos[1] += input.offsetHeight; // add the height
|
668
|
+
}
|
669
|
+
var isFixed = false;
|
670
|
+
$(input).parents().each(function() {
|
671
|
+
isFixed |= $(this).css('position') == 'fixed';
|
672
|
+
return !isFixed;
|
673
|
+
});
|
674
|
+
if (isFixed && $.browser.opera) { // correction for Opera when fixed and scrolled
|
675
|
+
$.datepicker._pos[0] -= document.documentElement.scrollLeft;
|
676
|
+
$.datepicker._pos[1] -= document.documentElement.scrollTop;
|
677
|
+
}
|
678
|
+
var offset = {left: $.datepicker._pos[0], top: $.datepicker._pos[1]};
|
679
|
+
$.datepicker._pos = null;
|
680
|
+
//to avoid flashes on Firefox
|
681
|
+
inst.dpDiv.empty();
|
682
|
+
// determine sizing offscreen
|
683
|
+
inst.dpDiv.css({position: 'absolute', display: 'block', top: '-1000px'});
|
684
|
+
$.datepicker._updateDatepicker(inst);
|
685
|
+
// fix width for dynamic number of date pickers
|
686
|
+
// and adjust position before showing
|
687
|
+
offset = $.datepicker._checkOffset(inst, offset, isFixed);
|
688
|
+
inst.dpDiv.css({position: ($.datepicker._inDialog && $.blockUI ?
|
689
|
+
'static' : (isFixed ? 'fixed' : 'absolute')), display: 'none',
|
690
|
+
left: offset.left + 'px', top: offset.top + 'px'});
|
691
|
+
if (!inst.inline) {
|
692
|
+
var showAnim = $.datepicker._get(inst, 'showAnim');
|
693
|
+
var duration = $.datepicker._get(inst, 'duration');
|
694
|
+
var postProcess = function() {
|
695
|
+
var cover = inst.dpDiv.find('iframe.ui-datepicker-cover'); // IE6- only
|
696
|
+
if( !! cover.length ){
|
697
|
+
var borders = $.datepicker._getBorders(inst.dpDiv);
|
698
|
+
cover.css({left: -borders[0], top: -borders[1],
|
699
|
+
width: inst.dpDiv.outerWidth(), height: inst.dpDiv.outerHeight()});
|
700
|
+
}
|
701
|
+
};
|
702
|
+
inst.dpDiv.zIndex($(input).zIndex()+1);
|
703
|
+
$.datepicker._datepickerShowing = true;
|
704
|
+
if ($.effects && $.effects[showAnim])
|
705
|
+
inst.dpDiv.show(showAnim, $.datepicker._get(inst, 'showOptions'), duration, postProcess);
|
706
|
+
else
|
707
|
+
inst.dpDiv[showAnim || 'show']((showAnim ? duration : null), postProcess);
|
708
|
+
if (!showAnim || !duration)
|
709
|
+
postProcess();
|
710
|
+
if (inst.input.is(':visible') && !inst.input.is(':disabled'))
|
711
|
+
inst.input.focus();
|
712
|
+
$.datepicker._curInst = inst;
|
713
|
+
}
|
714
|
+
},
|
715
|
+
|
716
|
+
/* Generate the date picker content. */
|
717
|
+
_updateDatepicker: function(inst) {
|
718
|
+
var self = this;
|
719
|
+
self.maxRows = 4; //Reset the max number of rows being displayed (see #7043)
|
720
|
+
var borders = $.datepicker._getBorders(inst.dpDiv);
|
721
|
+
instActive = inst; // for delegate hover events
|
722
|
+
inst.dpDiv.empty().append(this._generateHTML(inst));
|
723
|
+
var cover = inst.dpDiv.find('iframe.ui-datepicker-cover'); // IE6- only
|
724
|
+
if( !!cover.length ){ //avoid call to outerXXXX() when not in IE6
|
725
|
+
cover.css({left: -borders[0], top: -borders[1], width: inst.dpDiv.outerWidth(), height: inst.dpDiv.outerHeight()})
|
726
|
+
}
|
727
|
+
inst.dpDiv.find('.' + this._dayOverClass + ' a').mouseover();
|
728
|
+
var numMonths = this._getNumberOfMonths(inst);
|
729
|
+
var cols = numMonths[1];
|
730
|
+
var width = 17;
|
731
|
+
inst.dpDiv.removeClass('ui-datepicker-multi-2 ui-datepicker-multi-3 ui-datepicker-multi-4').width('');
|
732
|
+
if (cols > 1)
|
733
|
+
inst.dpDiv.addClass('ui-datepicker-multi-' + cols).css('width', (width * cols) + 'em');
|
734
|
+
inst.dpDiv[(numMonths[0] != 1 || numMonths[1] != 1 ? 'add' : 'remove') +
|
735
|
+
'Class']('ui-datepicker-multi');
|
736
|
+
inst.dpDiv[(this._get(inst, 'isRTL') ? 'add' : 'remove') +
|
737
|
+
'Class']('ui-datepicker-rtl');
|
738
|
+
if (inst == $.datepicker._curInst && $.datepicker._datepickerShowing && inst.input &&
|
739
|
+
// #6694 - don't focus the input if it's already focused
|
740
|
+
// this breaks the change event in IE
|
741
|
+
inst.input.is(':visible') && !inst.input.is(':disabled') && inst.input[0] != document.activeElement)
|
742
|
+
inst.input.focus();
|
743
|
+
// deffered render of the years select (to avoid flashes on Firefox)
|
744
|
+
if( inst.yearshtml ){
|
745
|
+
var origyearshtml = inst.yearshtml;
|
746
|
+
setTimeout(function(){
|
747
|
+
//assure that inst.yearshtml didn't change.
|
748
|
+
if( origyearshtml === inst.yearshtml && inst.yearshtml ){
|
749
|
+
inst.dpDiv.find('select.ui-datepicker-year:first').replaceWith(inst.yearshtml);
|
750
|
+
}
|
751
|
+
origyearshtml = inst.yearshtml = null;
|
752
|
+
}, 0);
|
753
|
+
}
|
754
|
+
},
|
755
|
+
|
756
|
+
/* Retrieve the size of left and top borders for an element.
|
757
|
+
@param elem (jQuery object) the element of interest
|
758
|
+
@return (number[2]) the left and top borders */
|
759
|
+
_getBorders: function(elem) {
|
760
|
+
var convert = function(value) {
|
761
|
+
return {thin: 1, medium: 2, thick: 3}[value] || value;
|
762
|
+
};
|
763
|
+
return [parseFloat(convert(elem.css('border-left-width'))),
|
764
|
+
parseFloat(convert(elem.css('border-top-width')))];
|
765
|
+
},
|
766
|
+
|
767
|
+
/* Check positioning to remain on screen. */
|
768
|
+
_checkOffset: function(inst, offset, isFixed) {
|
769
|
+
var dpWidth = inst.dpDiv.outerWidth();
|
770
|
+
var dpHeight = inst.dpDiv.outerHeight();
|
771
|
+
var inputWidth = inst.input ? inst.input.outerWidth() : 0;
|
772
|
+
var inputHeight = inst.input ? inst.input.outerHeight() : 0;
|
773
|
+
var viewWidth = document.documentElement.clientWidth + $(document).scrollLeft();
|
774
|
+
var viewHeight = document.documentElement.clientHeight + $(document).scrollTop();
|
775
|
+
|
776
|
+
offset.left -= (this._get(inst, 'isRTL') ? (dpWidth - inputWidth) : 0);
|
777
|
+
offset.left -= (isFixed && offset.left == inst.input.offset().left) ? $(document).scrollLeft() : 0;
|
778
|
+
offset.top -= (isFixed && offset.top == (inst.input.offset().top + inputHeight)) ? $(document).scrollTop() : 0;
|
779
|
+
|
780
|
+
// now check if datepicker is showing outside window viewport - move to a better place if so.
|
781
|
+
offset.left -= Math.min(offset.left, (offset.left + dpWidth > viewWidth && viewWidth > dpWidth) ?
|
782
|
+
Math.abs(offset.left + dpWidth - viewWidth) : 0);
|
783
|
+
offset.top -= Math.min(offset.top, (offset.top + dpHeight > viewHeight && viewHeight > dpHeight) ?
|
784
|
+
Math.abs(dpHeight + inputHeight) : 0);
|
785
|
+
|
786
|
+
return offset;
|
787
|
+
},
|
788
|
+
|
789
|
+
/* Find an object's position on the screen. */
|
790
|
+
_findPos: function(obj) {
|
791
|
+
var inst = this._getInst(obj);
|
792
|
+
var isRTL = this._get(inst, 'isRTL');
|
793
|
+
while (obj && (obj.type == 'hidden' || obj.nodeType != 1 || $.expr.filters.hidden(obj))) {
|
794
|
+
obj = obj[isRTL ? 'previousSibling' : 'nextSibling'];
|
795
|
+
}
|
796
|
+
var position = $(obj).offset();
|
797
|
+
return [position.left, position.top];
|
798
|
+
},
|
799
|
+
|
800
|
+
/* Hide the date picker from view.
|
801
|
+
@param input element - the input field attached to the date picker */
|
802
|
+
_hideDatepicker: function(input) {
|
803
|
+
var inst = this._curInst;
|
804
|
+
if (!inst || (input && inst != $.data(input, PROP_NAME)))
|
805
|
+
return;
|
806
|
+
if (this._datepickerShowing) {
|
807
|
+
var showAnim = this._get(inst, 'showAnim');
|
808
|
+
var duration = this._get(inst, 'duration');
|
809
|
+
var self = this;
|
810
|
+
var postProcess = function() {
|
811
|
+
$.datepicker._tidyDialog(inst);
|
812
|
+
self._curInst = null;
|
813
|
+
};
|
814
|
+
if ($.effects && $.effects[showAnim])
|
815
|
+
inst.dpDiv.hide(showAnim, $.datepicker._get(inst, 'showOptions'), duration, postProcess);
|
816
|
+
else
|
817
|
+
inst.dpDiv[(showAnim == 'slideDown' ? 'slideUp' :
|
818
|
+
(showAnim == 'fadeIn' ? 'fadeOut' : 'hide'))]((showAnim ? duration : null), postProcess);
|
819
|
+
if (!showAnim)
|
820
|
+
postProcess();
|
821
|
+
this._datepickerShowing = false;
|
822
|
+
var onClose = this._get(inst, 'onClose');
|
823
|
+
if (onClose)
|
824
|
+
onClose.apply((inst.input ? inst.input[0] : null),
|
825
|
+
[(inst.input ? inst.input.val() : ''), inst]);
|
826
|
+
this._lastInput = null;
|
827
|
+
if (this._inDialog) {
|
828
|
+
this._dialogInput.css({ position: 'absolute', left: '0', top: '-100px' });
|
829
|
+
if ($.blockUI) {
|
830
|
+
$.unblockUI();
|
831
|
+
$('body').append(this.dpDiv);
|
832
|
+
}
|
833
|
+
}
|
834
|
+
this._inDialog = false;
|
835
|
+
}
|
836
|
+
},
|
837
|
+
|
838
|
+
/* Tidy up after a dialog display. */
|
839
|
+
_tidyDialog: function(inst) {
|
840
|
+
inst.dpDiv.removeClass(this._dialogClass).unbind('.ui-datepicker-calendar');
|
841
|
+
},
|
842
|
+
|
843
|
+
/* Close date picker if clicked elsewhere. */
|
844
|
+
_checkExternalClick: function(event) {
|
845
|
+
if (!$.datepicker._curInst)
|
846
|
+
return;
|
847
|
+
|
848
|
+
var $target = $(event.target),
|
849
|
+
inst = $.datepicker._getInst($target[0]);
|
850
|
+
|
851
|
+
if ( ( ( $target[0].id != $.datepicker._mainDivId &&
|
852
|
+
$target.parents('#' + $.datepicker._mainDivId).length == 0 &&
|
853
|
+
!$target.hasClass($.datepicker.markerClassName) &&
|
854
|
+
!$target.closest("." + $.datepicker._triggerClass).length &&
|
855
|
+
$.datepicker._datepickerShowing && !($.datepicker._inDialog && $.blockUI) ) ) ||
|
856
|
+
( $target.hasClass($.datepicker.markerClassName) && $.datepicker._curInst != inst ) )
|
857
|
+
$.datepicker._hideDatepicker();
|
858
|
+
},
|
859
|
+
|
860
|
+
/* Adjust one of the date sub-fields. */
|
861
|
+
_adjustDate: function(id, offset, period) {
|
862
|
+
var target = $(id);
|
863
|
+
var inst = this._getInst(target[0]);
|
864
|
+
if (this._isDisabledDatepicker(target[0])) {
|
865
|
+
return;
|
866
|
+
}
|
867
|
+
this._adjustInstDate(inst, offset +
|
868
|
+
(period == 'M' ? this._get(inst, 'showCurrentAtPos') : 0), // undo positioning
|
869
|
+
period);
|
870
|
+
this._updateDatepicker(inst);
|
871
|
+
},
|
872
|
+
|
873
|
+
/* Action for current link. */
|
874
|
+
_gotoToday: function(id) {
|
875
|
+
var target = $(id);
|
876
|
+
var inst = this._getInst(target[0]);
|
877
|
+
if (this._get(inst, 'gotoCurrent') && inst.currentDay) {
|
878
|
+
inst.selectedDay = inst.currentDay;
|
879
|
+
inst.drawMonth = inst.selectedMonth = inst.currentMonth;
|
880
|
+
inst.drawYear = inst.selectedYear = inst.currentYear;
|
881
|
+
}
|
882
|
+
else {
|
883
|
+
var date = new Date();
|
884
|
+
inst.selectedDay = date.getDate();
|
885
|
+
inst.drawMonth = inst.selectedMonth = date.getMonth();
|
886
|
+
inst.drawYear = inst.selectedYear = date.getFullYear();
|
887
|
+
}
|
888
|
+
this._notifyChange(inst);
|
889
|
+
this._adjustDate(target);
|
890
|
+
},
|
891
|
+
|
892
|
+
/* Action for selecting a new month/year. */
|
893
|
+
_selectMonthYear: function(id, select, period) {
|
894
|
+
var target = $(id);
|
895
|
+
var inst = this._getInst(target[0]);
|
896
|
+
inst['selected' + (period == 'M' ? 'Month' : 'Year')] =
|
897
|
+
inst['draw' + (period == 'M' ? 'Month' : 'Year')] =
|
898
|
+
parseInt(select.options[select.selectedIndex].value,10);
|
899
|
+
this._notifyChange(inst);
|
900
|
+
this._adjustDate(target);
|
901
|
+
},
|
902
|
+
|
903
|
+
/* Action for selecting a day. */
|
904
|
+
_selectDay: function(id, month, year, td) {
|
905
|
+
var target = $(id);
|
906
|
+
if ($(td).hasClass(this._unselectableClass) || this._isDisabledDatepicker(target[0])) {
|
907
|
+
return;
|
908
|
+
}
|
909
|
+
var inst = this._getInst(target[0]);
|
910
|
+
inst.selectedDay = inst.currentDay = $('a', td).html();
|
911
|
+
inst.selectedMonth = inst.currentMonth = month;
|
912
|
+
inst.selectedYear = inst.currentYear = year;
|
913
|
+
this._selectDate(id, this._formatDate(inst,
|
914
|
+
inst.currentDay, inst.currentMonth, inst.currentYear));
|
915
|
+
},
|
916
|
+
|
917
|
+
/* Erase the input field and hide the date picker. */
|
918
|
+
_clearDate: function(id) {
|
919
|
+
var target = $(id);
|
920
|
+
var inst = this._getInst(target[0]);
|
921
|
+
this._selectDate(target, '');
|
922
|
+
},
|
923
|
+
|
924
|
+
/* Update the input field with the selected date. */
|
925
|
+
_selectDate: function(id, dateStr) {
|
926
|
+
var target = $(id);
|
927
|
+
var inst = this._getInst(target[0]);
|
928
|
+
dateStr = (dateStr != null ? dateStr : this._formatDate(inst));
|
929
|
+
if (inst.input)
|
930
|
+
inst.input.val(dateStr);
|
931
|
+
this._updateAlternate(inst);
|
932
|
+
var onSelect = this._get(inst, 'onSelect');
|
933
|
+
if (onSelect)
|
934
|
+
onSelect.apply((inst.input ? inst.input[0] : null), [dateStr, inst]); // trigger custom callback
|
935
|
+
else if (inst.input)
|
936
|
+
inst.input.trigger('change'); // fire the change event
|
937
|
+
if (inst.inline)
|
938
|
+
this._updateDatepicker(inst);
|
939
|
+
else {
|
940
|
+
this._hideDatepicker();
|
941
|
+
this._lastInput = inst.input[0];
|
942
|
+
if (typeof(inst.input[0]) != 'object')
|
943
|
+
inst.input.focus(); // restore focus
|
944
|
+
this._lastInput = null;
|
945
|
+
}
|
946
|
+
},
|
947
|
+
|
948
|
+
/* Update any alternate field to synchronise with the main field. */
|
949
|
+
_updateAlternate: function(inst) {
|
950
|
+
var altField = this._get(inst, 'altField');
|
951
|
+
if (altField) { // update alternate field too
|
952
|
+
var altFormat = this._get(inst, 'altFormat') || this._get(inst, 'dateFormat');
|
953
|
+
var date = this._getDate(inst);
|
954
|
+
var dateStr = this.formatDate(altFormat, date, this._getFormatConfig(inst));
|
955
|
+
$(altField).each(function() { $(this).val(dateStr); });
|
956
|
+
}
|
957
|
+
},
|
958
|
+
|
959
|
+
/* Set as beforeShowDay function to prevent selection of weekends.
|
960
|
+
@param date Date - the date to customise
|
961
|
+
@return [boolean, string] - is this date selectable?, what is its CSS class? */
|
962
|
+
noWeekends: function(date) {
|
963
|
+
var day = date.getDay();
|
964
|
+
return [(day > 0 && day < 6), ''];
|
965
|
+
},
|
966
|
+
|
967
|
+
/* Set as calculateWeek to determine the week of the year based on the ISO 8601 definition.
|
968
|
+
@param date Date - the date to get the week for
|
969
|
+
@return number - the number of the week within the year that contains this date */
|
970
|
+
iso8601Week: function(date) {
|
971
|
+
var checkDate = new Date(date.getTime());
|
972
|
+
// Find Thursday of this week starting on Monday
|
973
|
+
checkDate.setDate(checkDate.getDate() + 4 - (checkDate.getDay() || 7));
|
974
|
+
var time = checkDate.getTime();
|
975
|
+
checkDate.setMonth(0); // Compare with Jan 1
|
976
|
+
checkDate.setDate(1);
|
977
|
+
return Math.floor(Math.round((time - checkDate) / 86400000) / 7) + 1;
|
978
|
+
},
|
979
|
+
|
980
|
+
/* Parse a string value into a date object.
|
981
|
+
See formatDate below for the possible formats.
|
982
|
+
|
983
|
+
@param format string - the expected format of the date
|
984
|
+
@param value string - the date in the above format
|
985
|
+
@param settings Object - attributes include:
|
986
|
+
shortYearCutoff number - the cutoff year for determining the century (optional)
|
987
|
+
dayNamesShort string[7] - abbreviated names of the days from Sunday (optional)
|
988
|
+
dayNames string[7] - names of the days from Sunday (optional)
|
989
|
+
monthNamesShort string[12] - abbreviated names of the months (optional)
|
990
|
+
monthNames string[12] - names of the months (optional)
|
991
|
+
@return Date - the extracted date value or null if value is blank */
|
992
|
+
parseDate: function (format, value, settings) {
|
993
|
+
if (format == null || value == null)
|
994
|
+
throw 'Invalid arguments';
|
995
|
+
value = (typeof value == 'object' ? value.toString() : value + '');
|
996
|
+
if (value == '')
|
997
|
+
return null;
|
998
|
+
var shortYearCutoff = (settings ? settings.shortYearCutoff : null) || this._defaults.shortYearCutoff;
|
999
|
+
shortYearCutoff = (typeof shortYearCutoff != 'string' ? shortYearCutoff :
|
1000
|
+
new Date().getFullYear() % 100 + parseInt(shortYearCutoff, 10));
|
1001
|
+
var dayNamesShort = (settings ? settings.dayNamesShort : null) || this._defaults.dayNamesShort;
|
1002
|
+
var dayNames = (settings ? settings.dayNames : null) || this._defaults.dayNames;
|
1003
|
+
var monthNamesShort = (settings ? settings.monthNamesShort : null) || this._defaults.monthNamesShort;
|
1004
|
+
var monthNames = (settings ? settings.monthNames : null) || this._defaults.monthNames;
|
1005
|
+
var year = -1;
|
1006
|
+
var month = -1;
|
1007
|
+
var day = -1;
|
1008
|
+
var doy = -1;
|
1009
|
+
var literal = false;
|
1010
|
+
// Check whether a format character is doubled
|
1011
|
+
var lookAhead = function(match) {
|
1012
|
+
var matches = (iFormat + 1 < format.length && format.charAt(iFormat + 1) == match);
|
1013
|
+
if (matches)
|
1014
|
+
iFormat++;
|
1015
|
+
return matches;
|
1016
|
+
};
|
1017
|
+
// Extract a number from the string value
|
1018
|
+
var getNumber = function(match) {
|
1019
|
+
var isDoubled = lookAhead(match);
|
1020
|
+
var size = (match == '@' ? 14 : (match == '!' ? 20 :
|
1021
|
+
(match == 'y' && isDoubled ? 4 : (match == 'o' ? 3 : 2))));
|
1022
|
+
var digits = new RegExp('^\\d{1,' + size + '}');
|
1023
|
+
var num = value.substring(iValue).match(digits);
|
1024
|
+
if (!num)
|
1025
|
+
throw 'Missing number at position ' + iValue;
|
1026
|
+
iValue += num[0].length;
|
1027
|
+
return parseInt(num[0], 10);
|
1028
|
+
};
|
1029
|
+
// Extract a name from the string value and convert to an index
|
1030
|
+
var getName = function(match, shortNames, longNames) {
|
1031
|
+
var names = $.map(lookAhead(match) ? longNames : shortNames, function (v, k) {
|
1032
|
+
return [ [k, v] ];
|
1033
|
+
}).sort(function (a, b) {
|
1034
|
+
return -(a[1].length - b[1].length);
|
1035
|
+
});
|
1036
|
+
var index = -1;
|
1037
|
+
$.each(names, function (i, pair) {
|
1038
|
+
var name = pair[1];
|
1039
|
+
if (value.substr(iValue, name.length).toLowerCase() == name.toLowerCase()) {
|
1040
|
+
index = pair[0];
|
1041
|
+
iValue += name.length;
|
1042
|
+
return false;
|
1043
|
+
}
|
1044
|
+
});
|
1045
|
+
if (index != -1)
|
1046
|
+
return index + 1;
|
1047
|
+
else
|
1048
|
+
throw 'Unknown name at position ' + iValue;
|
1049
|
+
};
|
1050
|
+
// Confirm that a literal character matches the string value
|
1051
|
+
var checkLiteral = function() {
|
1052
|
+
if (value.charAt(iValue) != format.charAt(iFormat))
|
1053
|
+
throw 'Unexpected literal at position ' + iValue;
|
1054
|
+
iValue++;
|
1055
|
+
};
|
1056
|
+
var iValue = 0;
|
1057
|
+
for (var iFormat = 0; iFormat < format.length; iFormat++) {
|
1058
|
+
if (literal)
|
1059
|
+
if (format.charAt(iFormat) == "'" && !lookAhead("'"))
|
1060
|
+
literal = false;
|
1061
|
+
else
|
1062
|
+
checkLiteral();
|
1063
|
+
else
|
1064
|
+
switch (format.charAt(iFormat)) {
|
1065
|
+
case 'd':
|
1066
|
+
day = getNumber('d');
|
1067
|
+
break;
|
1068
|
+
case 'D':
|
1069
|
+
getName('D', dayNamesShort, dayNames);
|
1070
|
+
break;
|
1071
|
+
case 'o':
|
1072
|
+
doy = getNumber('o');
|
1073
|
+
break;
|
1074
|
+
case 'm':
|
1075
|
+
month = getNumber('m');
|
1076
|
+
break;
|
1077
|
+
case 'M':
|
1078
|
+
month = getName('M', monthNamesShort, monthNames);
|
1079
|
+
break;
|
1080
|
+
case 'y':
|
1081
|
+
year = getNumber('y');
|
1082
|
+
break;
|
1083
|
+
case '@':
|
1084
|
+
var date = new Date(getNumber('@'));
|
1085
|
+
year = date.getFullYear();
|
1086
|
+
month = date.getMonth() + 1;
|
1087
|
+
day = date.getDate();
|
1088
|
+
break;
|
1089
|
+
case '!':
|
1090
|
+
var date = new Date((getNumber('!') - this._ticksTo1970) / 10000);
|
1091
|
+
year = date.getFullYear();
|
1092
|
+
month = date.getMonth() + 1;
|
1093
|
+
day = date.getDate();
|
1094
|
+
break;
|
1095
|
+
case "'":
|
1096
|
+
if (lookAhead("'"))
|
1097
|
+
checkLiteral();
|
1098
|
+
else
|
1099
|
+
literal = true;
|
1100
|
+
break;
|
1101
|
+
default:
|
1102
|
+
checkLiteral();
|
1103
|
+
}
|
1104
|
+
}
|
1105
|
+
if (iValue < value.length){
|
1106
|
+
throw "Extra/unparsed characters found in date: " + value.substring(iValue);
|
1107
|
+
}
|
1108
|
+
if (year == -1)
|
1109
|
+
year = new Date().getFullYear();
|
1110
|
+
else if (year < 100)
|
1111
|
+
year += new Date().getFullYear() - new Date().getFullYear() % 100 +
|
1112
|
+
(year <= shortYearCutoff ? 0 : -100);
|
1113
|
+
if (doy > -1) {
|
1114
|
+
month = 1;
|
1115
|
+
day = doy;
|
1116
|
+
do {
|
1117
|
+
var dim = this._getDaysInMonth(year, month - 1);
|
1118
|
+
if (day <= dim)
|
1119
|
+
break;
|
1120
|
+
month++;
|
1121
|
+
day -= dim;
|
1122
|
+
} while (true);
|
1123
|
+
}
|
1124
|
+
var date = this._daylightSavingAdjust(new Date(year, month - 1, day));
|
1125
|
+
if (date.getFullYear() != year || date.getMonth() + 1 != month || date.getDate() != day)
|
1126
|
+
throw 'Invalid date'; // E.g. 31/02/00
|
1127
|
+
return date;
|
1128
|
+
},
|
1129
|
+
|
1130
|
+
/* Standard date formats. */
|
1131
|
+
ATOM: 'yy-mm-dd', // RFC 3339 (ISO 8601)
|
1132
|
+
COOKIE: 'D, dd M yy',
|
1133
|
+
ISO_8601: 'yy-mm-dd',
|
1134
|
+
RFC_822: 'D, d M y',
|
1135
|
+
RFC_850: 'DD, dd-M-y',
|
1136
|
+
RFC_1036: 'D, d M y',
|
1137
|
+
RFC_1123: 'D, d M yy',
|
1138
|
+
RFC_2822: 'D, d M yy',
|
1139
|
+
RSS: 'D, d M y', // RFC 822
|
1140
|
+
TICKS: '!',
|
1141
|
+
TIMESTAMP: '@',
|
1142
|
+
W3C: 'yy-mm-dd', // ISO 8601
|
1143
|
+
|
1144
|
+
_ticksTo1970: (((1970 - 1) * 365 + Math.floor(1970 / 4) - Math.floor(1970 / 100) +
|
1145
|
+
Math.floor(1970 / 400)) * 24 * 60 * 60 * 10000000),
|
1146
|
+
|
1147
|
+
/* Format a date object into a string value.
|
1148
|
+
The format can be combinations of the following:
|
1149
|
+
d - day of month (no leading zero)
|
1150
|
+
dd - day of month (two digit)
|
1151
|
+
o - day of year (no leading zeros)
|
1152
|
+
oo - day of year (three digit)
|
1153
|
+
D - day name short
|
1154
|
+
DD - day name long
|
1155
|
+
m - month of year (no leading zero)
|
1156
|
+
mm - month of year (two digit)
|
1157
|
+
M - month name short
|
1158
|
+
MM - month name long
|
1159
|
+
y - year (two digit)
|
1160
|
+
yy - year (four digit)
|
1161
|
+
@ - Unix timestamp (ms since 01/01/1970)
|
1162
|
+
! - Windows ticks (100ns since 01/01/0001)
|
1163
|
+
'...' - literal text
|
1164
|
+
'' - single quote
|
1165
|
+
|
1166
|
+
@param format string - the desired format of the date
|
1167
|
+
@param date Date - the date value to format
|
1168
|
+
@param settings Object - attributes include:
|
1169
|
+
dayNamesShort string[7] - abbreviated names of the days from Sunday (optional)
|
1170
|
+
dayNames string[7] - names of the days from Sunday (optional)
|
1171
|
+
monthNamesShort string[12] - abbreviated names of the months (optional)
|
1172
|
+
monthNames string[12] - names of the months (optional)
|
1173
|
+
@return string - the date in the above format */
|
1174
|
+
formatDate: function (format, date, settings) {
|
1175
|
+
if (!date)
|
1176
|
+
return '';
|
1177
|
+
var dayNamesShort = (settings ? settings.dayNamesShort : null) || this._defaults.dayNamesShort;
|
1178
|
+
var dayNames = (settings ? settings.dayNames : null) || this._defaults.dayNames;
|
1179
|
+
var monthNamesShort = (settings ? settings.monthNamesShort : null) || this._defaults.monthNamesShort;
|
1180
|
+
var monthNames = (settings ? settings.monthNames : null) || this._defaults.monthNames;
|
1181
|
+
// Check whether a format character is doubled
|
1182
|
+
var lookAhead = function(match) {
|
1183
|
+
var matches = (iFormat + 1 < format.length && format.charAt(iFormat + 1) == match);
|
1184
|
+
if (matches)
|
1185
|
+
iFormat++;
|
1186
|
+
return matches;
|
1187
|
+
};
|
1188
|
+
// Format a number, with leading zero if necessary
|
1189
|
+
var formatNumber = function(match, value, len) {
|
1190
|
+
var num = '' + value;
|
1191
|
+
if (lookAhead(match))
|
1192
|
+
while (num.length < len)
|
1193
|
+
num = '0' + num;
|
1194
|
+
return num;
|
1195
|
+
};
|
1196
|
+
// Format a name, short or long as requested
|
1197
|
+
var formatName = function(match, value, shortNames, longNames) {
|
1198
|
+
return (lookAhead(match) ? longNames[value] : shortNames[value]);
|
1199
|
+
};
|
1200
|
+
var output = '';
|
1201
|
+
var literal = false;
|
1202
|
+
if (date)
|
1203
|
+
for (var iFormat = 0; iFormat < format.length; iFormat++) {
|
1204
|
+
if (literal)
|
1205
|
+
if (format.charAt(iFormat) == "'" && !lookAhead("'"))
|
1206
|
+
literal = false;
|
1207
|
+
else
|
1208
|
+
output += format.charAt(iFormat);
|
1209
|
+
else
|
1210
|
+
switch (format.charAt(iFormat)) {
|
1211
|
+
case 'd':
|
1212
|
+
output += formatNumber('d', date.getDate(), 2);
|
1213
|
+
break;
|
1214
|
+
case 'D':
|
1215
|
+
output += formatName('D', date.getDay(), dayNamesShort, dayNames);
|
1216
|
+
break;
|
1217
|
+
case 'o':
|
1218
|
+
output += formatNumber('o',
|
1219
|
+
Math.round((new Date(date.getFullYear(), date.getMonth(), date.getDate()).getTime() - new Date(date.getFullYear(), 0, 0).getTime()) / 86400000), 3);
|
1220
|
+
break;
|
1221
|
+
case 'm':
|
1222
|
+
output += formatNumber('m', date.getMonth() + 1, 2);
|
1223
|
+
break;
|
1224
|
+
case 'M':
|
1225
|
+
output += formatName('M', date.getMonth(), monthNamesShort, monthNames);
|
1226
|
+
break;
|
1227
|
+
case 'y':
|
1228
|
+
output += (lookAhead('y') ? date.getFullYear() :
|
1229
|
+
(date.getYear() % 100 < 10 ? '0' : '') + date.getYear() % 100);
|
1230
|
+
break;
|
1231
|
+
case '@':
|
1232
|
+
output += date.getTime();
|
1233
|
+
break;
|
1234
|
+
case '!':
|
1235
|
+
output += date.getTime() * 10000 + this._ticksTo1970;
|
1236
|
+
break;
|
1237
|
+
case "'":
|
1238
|
+
if (lookAhead("'"))
|
1239
|
+
output += "'";
|
1240
|
+
else
|
1241
|
+
literal = true;
|
1242
|
+
break;
|
1243
|
+
default:
|
1244
|
+
output += format.charAt(iFormat);
|
1245
|
+
}
|
1246
|
+
}
|
1247
|
+
return output;
|
1248
|
+
},
|
1249
|
+
|
1250
|
+
/* Extract all possible characters from the date format. */
|
1251
|
+
_possibleChars: function (format) {
|
1252
|
+
var chars = '';
|
1253
|
+
var literal = false;
|
1254
|
+
// Check whether a format character is doubled
|
1255
|
+
var lookAhead = function(match) {
|
1256
|
+
var matches = (iFormat + 1 < format.length && format.charAt(iFormat + 1) == match);
|
1257
|
+
if (matches)
|
1258
|
+
iFormat++;
|
1259
|
+
return matches;
|
1260
|
+
};
|
1261
|
+
for (var iFormat = 0; iFormat < format.length; iFormat++)
|
1262
|
+
if (literal)
|
1263
|
+
if (format.charAt(iFormat) == "'" && !lookAhead("'"))
|
1264
|
+
literal = false;
|
1265
|
+
else
|
1266
|
+
chars += format.charAt(iFormat);
|
1267
|
+
else
|
1268
|
+
switch (format.charAt(iFormat)) {
|
1269
|
+
case 'd': case 'm': case 'y': case '@':
|
1270
|
+
chars += '0123456789';
|
1271
|
+
break;
|
1272
|
+
case 'D': case 'M':
|
1273
|
+
return null; // Accept anything
|
1274
|
+
case "'":
|
1275
|
+
if (lookAhead("'"))
|
1276
|
+
chars += "'";
|
1277
|
+
else
|
1278
|
+
literal = true;
|
1279
|
+
break;
|
1280
|
+
default:
|
1281
|
+
chars += format.charAt(iFormat);
|
1282
|
+
}
|
1283
|
+
return chars;
|
1284
|
+
},
|
1285
|
+
|
1286
|
+
/* Get a setting value, defaulting if necessary. */
|
1287
|
+
_get: function(inst, name) {
|
1288
|
+
return inst.settings[name] !== undefined ?
|
1289
|
+
inst.settings[name] : this._defaults[name];
|
1290
|
+
},
|
1291
|
+
|
1292
|
+
/* Parse existing date and initialise date picker. */
|
1293
|
+
_setDateFromField: function(inst, noDefault) {
|
1294
|
+
if (inst.input.val() == inst.lastVal) {
|
1295
|
+
return;
|
1296
|
+
}
|
1297
|
+
var dateFormat = this._get(inst, 'dateFormat');
|
1298
|
+
var dates = inst.lastVal = inst.input ? inst.input.val() : null;
|
1299
|
+
var date, defaultDate;
|
1300
|
+
date = defaultDate = this._getDefaultDate(inst);
|
1301
|
+
var settings = this._getFormatConfig(inst);
|
1302
|
+
try {
|
1303
|
+
date = this.parseDate(dateFormat, dates, settings) || defaultDate;
|
1304
|
+
} catch (event) {
|
1305
|
+
this.log(event);
|
1306
|
+
dates = (noDefault ? '' : dates);
|
1307
|
+
}
|
1308
|
+
inst.selectedDay = date.getDate();
|
1309
|
+
inst.drawMonth = inst.selectedMonth = date.getMonth();
|
1310
|
+
inst.drawYear = inst.selectedYear = date.getFullYear();
|
1311
|
+
inst.currentDay = (dates ? date.getDate() : 0);
|
1312
|
+
inst.currentMonth = (dates ? date.getMonth() : 0);
|
1313
|
+
inst.currentYear = (dates ? date.getFullYear() : 0);
|
1314
|
+
this._adjustInstDate(inst);
|
1315
|
+
},
|
1316
|
+
|
1317
|
+
/* Retrieve the default date shown on opening. */
|
1318
|
+
_getDefaultDate: function(inst) {
|
1319
|
+
return this._restrictMinMax(inst,
|
1320
|
+
this._determineDate(inst, this._get(inst, 'defaultDate'), new Date()));
|
1321
|
+
},
|
1322
|
+
|
1323
|
+
/* A date may be specified as an exact value or a relative one. */
|
1324
|
+
_determineDate: function(inst, date, defaultDate) {
|
1325
|
+
var offsetNumeric = function(offset) {
|
1326
|
+
var date = new Date();
|
1327
|
+
date.setDate(date.getDate() + offset);
|
1328
|
+
return date;
|
1329
|
+
};
|
1330
|
+
var offsetString = function(offset) {
|
1331
|
+
try {
|
1332
|
+
return $.datepicker.parseDate($.datepicker._get(inst, 'dateFormat'),
|
1333
|
+
offset, $.datepicker._getFormatConfig(inst));
|
1334
|
+
}
|
1335
|
+
catch (e) {
|
1336
|
+
// Ignore
|
1337
|
+
}
|
1338
|
+
var date = (offset.toLowerCase().match(/^c/) ?
|
1339
|
+
$.datepicker._getDate(inst) : null) || new Date();
|
1340
|
+
var year = date.getFullYear();
|
1341
|
+
var month = date.getMonth();
|
1342
|
+
var day = date.getDate();
|
1343
|
+
var pattern = /([+-]?[0-9]+)\s*(d|D|w|W|m|M|y|Y)?/g;
|
1344
|
+
var matches = pattern.exec(offset);
|
1345
|
+
while (matches) {
|
1346
|
+
switch (matches[2] || 'd') {
|
1347
|
+
case 'd' : case 'D' :
|
1348
|
+
day += parseInt(matches[1],10); break;
|
1349
|
+
case 'w' : case 'W' :
|
1350
|
+
day += parseInt(matches[1],10) * 7; break;
|
1351
|
+
case 'm' : case 'M' :
|
1352
|
+
month += parseInt(matches[1],10);
|
1353
|
+
day = Math.min(day, $.datepicker._getDaysInMonth(year, month));
|
1354
|
+
break;
|
1355
|
+
case 'y': case 'Y' :
|
1356
|
+
year += parseInt(matches[1],10);
|
1357
|
+
day = Math.min(day, $.datepicker._getDaysInMonth(year, month));
|
1358
|
+
break;
|
1359
|
+
}
|
1360
|
+
matches = pattern.exec(offset);
|
1361
|
+
}
|
1362
|
+
return new Date(year, month, day);
|
1363
|
+
};
|
1364
|
+
var newDate = (date == null || date === '' ? defaultDate : (typeof date == 'string' ? offsetString(date) :
|
1365
|
+
(typeof date == 'number' ? (isNaN(date) ? defaultDate : offsetNumeric(date)) : new Date(date.getTime()))));
|
1366
|
+
newDate = (newDate && newDate.toString() == 'Invalid Date' ? defaultDate : newDate);
|
1367
|
+
if (newDate) {
|
1368
|
+
newDate.setHours(0);
|
1369
|
+
newDate.setMinutes(0);
|
1370
|
+
newDate.setSeconds(0);
|
1371
|
+
newDate.setMilliseconds(0);
|
1372
|
+
}
|
1373
|
+
return this._daylightSavingAdjust(newDate);
|
1374
|
+
},
|
1375
|
+
|
1376
|
+
/* Handle switch to/from daylight saving.
|
1377
|
+
Hours may be non-zero on daylight saving cut-over:
|
1378
|
+
> 12 when midnight changeover, but then cannot generate
|
1379
|
+
midnight datetime, so jump to 1AM, otherwise reset.
|
1380
|
+
@param date (Date) the date to check
|
1381
|
+
@return (Date) the corrected date */
|
1382
|
+
_daylightSavingAdjust: function(date) {
|
1383
|
+
if (!date) return null;
|
1384
|
+
date.setHours(date.getHours() > 12 ? date.getHours() + 2 : 0);
|
1385
|
+
return date;
|
1386
|
+
},
|
1387
|
+
|
1388
|
+
/* Set the date(s) directly. */
|
1389
|
+
_setDate: function(inst, date, noChange) {
|
1390
|
+
var clear = !date;
|
1391
|
+
var origMonth = inst.selectedMonth;
|
1392
|
+
var origYear = inst.selectedYear;
|
1393
|
+
var newDate = this._restrictMinMax(inst, this._determineDate(inst, date, new Date()));
|
1394
|
+
inst.selectedDay = inst.currentDay = newDate.getDate();
|
1395
|
+
inst.drawMonth = inst.selectedMonth = inst.currentMonth = newDate.getMonth();
|
1396
|
+
inst.drawYear = inst.selectedYear = inst.currentYear = newDate.getFullYear();
|
1397
|
+
if ((origMonth != inst.selectedMonth || origYear != inst.selectedYear) && !noChange)
|
1398
|
+
this._notifyChange(inst);
|
1399
|
+
this._adjustInstDate(inst);
|
1400
|
+
if (inst.input) {
|
1401
|
+
inst.input.val(clear ? '' : this._formatDate(inst));
|
1402
|
+
}
|
1403
|
+
},
|
1404
|
+
|
1405
|
+
/* Retrieve the date(s) directly. */
|
1406
|
+
_getDate: function(inst) {
|
1407
|
+
var startDate = (!inst.currentYear || (inst.input && inst.input.val() == '') ? null :
|
1408
|
+
this._daylightSavingAdjust(new Date(
|
1409
|
+
inst.currentYear, inst.currentMonth, inst.currentDay)));
|
1410
|
+
return startDate;
|
1411
|
+
},
|
1412
|
+
|
1413
|
+
/* Generate the HTML for the current state of the date picker. */
|
1414
|
+
_generateHTML: function(inst) {
|
1415
|
+
var today = new Date();
|
1416
|
+
today = this._daylightSavingAdjust(
|
1417
|
+
new Date(today.getFullYear(), today.getMonth(), today.getDate())); // clear time
|
1418
|
+
var isRTL = this._get(inst, 'isRTL');
|
1419
|
+
var showButtonPanel = this._get(inst, 'showButtonPanel');
|
1420
|
+
var hideIfNoPrevNext = this._get(inst, 'hideIfNoPrevNext');
|
1421
|
+
var navigationAsDateFormat = this._get(inst, 'navigationAsDateFormat');
|
1422
|
+
var numMonths = this._getNumberOfMonths(inst);
|
1423
|
+
var showCurrentAtPos = this._get(inst, 'showCurrentAtPos');
|
1424
|
+
var stepMonths = this._get(inst, 'stepMonths');
|
1425
|
+
var isMultiMonth = (numMonths[0] != 1 || numMonths[1] != 1);
|
1426
|
+
var currentDate = this._daylightSavingAdjust((!inst.currentDay ? new Date(9999, 9, 9) :
|
1427
|
+
new Date(inst.currentYear, inst.currentMonth, inst.currentDay)));
|
1428
|
+
var minDate = this._getMinMaxDate(inst, 'min');
|
1429
|
+
var maxDate = this._getMinMaxDate(inst, 'max');
|
1430
|
+
var drawMonth = inst.drawMonth - showCurrentAtPos;
|
1431
|
+
var drawYear = inst.drawYear;
|
1432
|
+
if (drawMonth < 0) {
|
1433
|
+
drawMonth += 12;
|
1434
|
+
drawYear--;
|
1435
|
+
}
|
1436
|
+
if (maxDate) {
|
1437
|
+
var maxDraw = this._daylightSavingAdjust(new Date(maxDate.getFullYear(),
|
1438
|
+
maxDate.getMonth() - (numMonths[0] * numMonths[1]) + 1, maxDate.getDate()));
|
1439
|
+
maxDraw = (minDate && maxDraw < minDate ? minDate : maxDraw);
|
1440
|
+
while (this._daylightSavingAdjust(new Date(drawYear, drawMonth, 1)) > maxDraw) {
|
1441
|
+
drawMonth--;
|
1442
|
+
if (drawMonth < 0) {
|
1443
|
+
drawMonth = 11;
|
1444
|
+
drawYear--;
|
1445
|
+
}
|
1446
|
+
}
|
1447
|
+
}
|
1448
|
+
inst.drawMonth = drawMonth;
|
1449
|
+
inst.drawYear = drawYear;
|
1450
|
+
var prevText = this._get(inst, 'prevText');
|
1451
|
+
prevText = (!navigationAsDateFormat ? prevText : this.formatDate(prevText,
|
1452
|
+
this._daylightSavingAdjust(new Date(drawYear, drawMonth - stepMonths, 1)),
|
1453
|
+
this._getFormatConfig(inst)));
|
1454
|
+
var prev = (this._canAdjustMonth(inst, -1, drawYear, drawMonth) ?
|
1455
|
+
'<a class="ui-datepicker-prev ui-corner-all" onclick="DP_jQuery_' + dpuuid +
|
1456
|
+
'.datepicker._adjustDate(\'#' + inst.id + '\', -' + stepMonths + ', \'M\');"' +
|
1457
|
+
' title="' + prevText + '"><span class="ui-icon ui-icon-circle-triangle-' + ( isRTL ? 'e' : 'w') + '">' + prevText + '</span></a>' :
|
1458
|
+
(hideIfNoPrevNext ? '' : '<a class="ui-datepicker-prev ui-corner-all ui-state-disabled" title="'+ prevText +'"><span class="ui-icon ui-icon-circle-triangle-' + ( isRTL ? 'e' : 'w') + '">' + prevText + '</span></a>'));
|
1459
|
+
var nextText = this._get(inst, 'nextText');
|
1460
|
+
nextText = (!navigationAsDateFormat ? nextText : this.formatDate(nextText,
|
1461
|
+
this._daylightSavingAdjust(new Date(drawYear, drawMonth + stepMonths, 1)),
|
1462
|
+
this._getFormatConfig(inst)));
|
1463
|
+
var next = (this._canAdjustMonth(inst, +1, drawYear, drawMonth) ?
|
1464
|
+
'<a class="ui-datepicker-next ui-corner-all" onclick="DP_jQuery_' + dpuuid +
|
1465
|
+
'.datepicker._adjustDate(\'#' + inst.id + '\', +' + stepMonths + ', \'M\');"' +
|
1466
|
+
' title="' + nextText + '"><span class="ui-icon ui-icon-circle-triangle-' + ( isRTL ? 'w' : 'e') + '">' + nextText + '</span></a>' :
|
1467
|
+
(hideIfNoPrevNext ? '' : '<a class="ui-datepicker-next ui-corner-all ui-state-disabled" title="'+ nextText + '"><span class="ui-icon ui-icon-circle-triangle-' + ( isRTL ? 'w' : 'e') + '">' + nextText + '</span></a>'));
|
1468
|
+
var currentText = this._get(inst, 'currentText');
|
1469
|
+
var gotoDate = (this._get(inst, 'gotoCurrent') && inst.currentDay ? currentDate : today);
|
1470
|
+
currentText = (!navigationAsDateFormat ? currentText :
|
1471
|
+
this.formatDate(currentText, gotoDate, this._getFormatConfig(inst)));
|
1472
|
+
var controls = (!inst.inline ? '<button type="button" class="ui-datepicker-close ui-state-default ui-priority-primary ui-corner-all" onclick="DP_jQuery_' + dpuuid +
|
1473
|
+
'.datepicker._hideDatepicker();">' + this._get(inst, 'closeText') + '</button>' : '');
|
1474
|
+
var buttonPanel = (showButtonPanel) ? '<div class="ui-datepicker-buttonpane ui-widget-content">' + (isRTL ? controls : '') +
|
1475
|
+
(this._isInRange(inst, gotoDate) ? '<button type="button" class="ui-datepicker-current ui-state-default ui-priority-secondary ui-corner-all" onclick="DP_jQuery_' + dpuuid +
|
1476
|
+
'.datepicker._gotoToday(\'#' + inst.id + '\');"' +
|
1477
|
+
'>' + currentText + '</button>' : '') + (isRTL ? '' : controls) + '</div>' : '';
|
1478
|
+
var firstDay = parseInt(this._get(inst, 'firstDay'),10);
|
1479
|
+
firstDay = (isNaN(firstDay) ? 0 : firstDay);
|
1480
|
+
var showWeek = this._get(inst, 'showWeek');
|
1481
|
+
var dayNames = this._get(inst, 'dayNames');
|
1482
|
+
var dayNamesShort = this._get(inst, 'dayNamesShort');
|
1483
|
+
var dayNamesMin = this._get(inst, 'dayNamesMin');
|
1484
|
+
var monthNames = this._get(inst, 'monthNames');
|
1485
|
+
var monthNamesShort = this._get(inst, 'monthNamesShort');
|
1486
|
+
var beforeShowDay = this._get(inst, 'beforeShowDay');
|
1487
|
+
var showOtherMonths = this._get(inst, 'showOtherMonths');
|
1488
|
+
var selectOtherMonths = this._get(inst, 'selectOtherMonths');
|
1489
|
+
var calculateWeek = this._get(inst, 'calculateWeek') || this.iso8601Week;
|
1490
|
+
var defaultDate = this._getDefaultDate(inst);
|
1491
|
+
var html = '';
|
1492
|
+
for (var row = 0; row < numMonths[0]; row++) {
|
1493
|
+
var group = '';
|
1494
|
+
this.maxRows = 4;
|
1495
|
+
for (var col = 0; col < numMonths[1]; col++) {
|
1496
|
+
var selectedDate = this._daylightSavingAdjust(new Date(drawYear, drawMonth, inst.selectedDay));
|
1497
|
+
var cornerClass = ' ui-corner-all';
|
1498
|
+
var calender = '';
|
1499
|
+
if (isMultiMonth) {
|
1500
|
+
calender += '<div class="ui-datepicker-group';
|
1501
|
+
if (numMonths[1] > 1)
|
1502
|
+
switch (col) {
|
1503
|
+
case 0: calender += ' ui-datepicker-group-first';
|
1504
|
+
cornerClass = ' ui-corner-' + (isRTL ? 'right' : 'left'); break;
|
1505
|
+
case numMonths[1]-1: calender += ' ui-datepicker-group-last';
|
1506
|
+
cornerClass = ' ui-corner-' + (isRTL ? 'left' : 'right'); break;
|
1507
|
+
default: calender += ' ui-datepicker-group-middle'; cornerClass = ''; break;
|
1508
|
+
}
|
1509
|
+
calender += '">';
|
1510
|
+
}
|
1511
|
+
calender += '<div class="ui-datepicker-header ui-widget-header ui-helper-clearfix' + cornerClass + '">' +
|
1512
|
+
(/all|left/.test(cornerClass) && row == 0 ? (isRTL ? next : prev) : '') +
|
1513
|
+
(/all|right/.test(cornerClass) && row == 0 ? (isRTL ? prev : next) : '') +
|
1514
|
+
this._generateMonthYearHeader(inst, drawMonth, drawYear, minDate, maxDate,
|
1515
|
+
row > 0 || col > 0, monthNames, monthNamesShort) + // draw month headers
|
1516
|
+
'</div><table class="ui-datepicker-calendar"><thead>' +
|
1517
|
+
'<tr>';
|
1518
|
+
var thead = (showWeek ? '<th class="ui-datepicker-week-col">' + this._get(inst, 'weekHeader') + '</th>' : '');
|
1519
|
+
for (var dow = 0; dow < 7; dow++) { // days of the week
|
1520
|
+
var day = (dow + firstDay) % 7;
|
1521
|
+
thead += '<th' + ((dow + firstDay + 6) % 7 >= 5 ? ' class="ui-datepicker-week-end"' : '') + '>' +
|
1522
|
+
'<span title="' + dayNames[day] + '">' + dayNamesMin[day] + '</span></th>';
|
1523
|
+
}
|
1524
|
+
calender += thead + '</tr></thead><tbody>';
|
1525
|
+
var daysInMonth = this._getDaysInMonth(drawYear, drawMonth);
|
1526
|
+
if (drawYear == inst.selectedYear && drawMonth == inst.selectedMonth)
|
1527
|
+
inst.selectedDay = Math.min(inst.selectedDay, daysInMonth);
|
1528
|
+
var leadDays = (this._getFirstDayOfMonth(drawYear, drawMonth) - firstDay + 7) % 7;
|
1529
|
+
var curRows = Math.ceil((leadDays + daysInMonth) / 7); // calculate the number of rows to generate
|
1530
|
+
var numRows = (isMultiMonth ? this.maxRows > curRows ? this.maxRows : curRows : curRows); //If multiple months, use the higher number of rows (see #7043)
|
1531
|
+
this.maxRows = numRows;
|
1532
|
+
var printDate = this._daylightSavingAdjust(new Date(drawYear, drawMonth, 1 - leadDays));
|
1533
|
+
for (var dRow = 0; dRow < numRows; dRow++) { // create date picker rows
|
1534
|
+
calender += '<tr>';
|
1535
|
+
var tbody = (!showWeek ? '' : '<td class="ui-datepicker-week-col">' +
|
1536
|
+
this._get(inst, 'calculateWeek')(printDate) + '</td>');
|
1537
|
+
for (var dow = 0; dow < 7; dow++) { // create date picker days
|
1538
|
+
var daySettings = (beforeShowDay ?
|
1539
|
+
beforeShowDay.apply((inst.input ? inst.input[0] : null), [printDate]) : [true, '']);
|
1540
|
+
var otherMonth = (printDate.getMonth() != drawMonth);
|
1541
|
+
var unselectable = (otherMonth && !selectOtherMonths) || !daySettings[0] ||
|
1542
|
+
(minDate && printDate < minDate) || (maxDate && printDate > maxDate);
|
1543
|
+
tbody += '<td class="' +
|
1544
|
+
((dow + firstDay + 6) % 7 >= 5 ? ' ui-datepicker-week-end' : '') + // highlight weekends
|
1545
|
+
(otherMonth ? ' ui-datepicker-other-month' : '') + // highlight days from other months
|
1546
|
+
((printDate.getTime() == selectedDate.getTime() && drawMonth == inst.selectedMonth && inst._keyEvent) || // user pressed key
|
1547
|
+
(defaultDate.getTime() == printDate.getTime() && defaultDate.getTime() == selectedDate.getTime()) ?
|
1548
|
+
// or defaultDate is current printedDate and defaultDate is selectedDate
|
1549
|
+
' ' + this._dayOverClass : '') + // highlight selected day
|
1550
|
+
(unselectable ? ' ' + this._unselectableClass + ' ui-state-disabled': '') + // highlight unselectable days
|
1551
|
+
(otherMonth && !showOtherMonths ? '' : ' ' + daySettings[1] + // highlight custom dates
|
1552
|
+
(printDate.getTime() == currentDate.getTime() ? ' ' + this._currentClass : '') + // highlight selected day
|
1553
|
+
(printDate.getTime() == today.getTime() ? ' ui-datepicker-today' : '')) + '"' + // highlight today (if different)
|
1554
|
+
((!otherMonth || showOtherMonths) && daySettings[2] ? ' title="' + daySettings[2] + '"' : '') + // cell title
|
1555
|
+
(unselectable ? '' : ' onclick="DP_jQuery_' + dpuuid + '.datepicker._selectDay(\'#' +
|
1556
|
+
inst.id + '\',' + printDate.getMonth() + ',' + printDate.getFullYear() + ', this);return false;"') + '>' + // actions
|
1557
|
+
(otherMonth && !showOtherMonths ? ' ' : // display for other months
|
1558
|
+
(unselectable ? '<span class="ui-state-default">' + printDate.getDate() + '</span>' : '<a class="ui-state-default' +
|
1559
|
+
(printDate.getTime() == today.getTime() ? ' ui-state-highlight' : '') +
|
1560
|
+
(printDate.getTime() == currentDate.getTime() ? ' ui-state-active' : '') + // highlight selected day
|
1561
|
+
(otherMonth ? ' ui-priority-secondary' : '') + // distinguish dates from other months
|
1562
|
+
'" href="#">' + printDate.getDate() + '</a>')) + '</td>'; // display selectable date
|
1563
|
+
printDate.setDate(printDate.getDate() + 1);
|
1564
|
+
printDate = this._daylightSavingAdjust(printDate);
|
1565
|
+
}
|
1566
|
+
calender += tbody + '</tr>';
|
1567
|
+
}
|
1568
|
+
drawMonth++;
|
1569
|
+
if (drawMonth > 11) {
|
1570
|
+
drawMonth = 0;
|
1571
|
+
drawYear++;
|
1572
|
+
}
|
1573
|
+
calender += '</tbody></table>' + (isMultiMonth ? '</div>' +
|
1574
|
+
((numMonths[0] > 0 && col == numMonths[1]-1) ? '<div class="ui-datepicker-row-break"></div>' : '') : '');
|
1575
|
+
group += calender;
|
1576
|
+
}
|
1577
|
+
html += group;
|
1578
|
+
}
|
1579
|
+
html += buttonPanel + ($.browser.msie && parseInt($.browser.version,10) < 7 && !inst.inline ?
|
1580
|
+
'<iframe src="javascript:false;" class="ui-datepicker-cover" frameborder="0"></iframe>' : '');
|
1581
|
+
inst._keyEvent = false;
|
1582
|
+
return html;
|
1583
|
+
},
|
1584
|
+
|
1585
|
+
/* Generate the month and year header. */
|
1586
|
+
_generateMonthYearHeader: function(inst, drawMonth, drawYear, minDate, maxDate,
|
1587
|
+
secondary, monthNames, monthNamesShort) {
|
1588
|
+
var changeMonth = this._get(inst, 'changeMonth');
|
1589
|
+
var changeYear = this._get(inst, 'changeYear');
|
1590
|
+
var showMonthAfterYear = this._get(inst, 'showMonthAfterYear');
|
1591
|
+
var html = '<div class="ui-datepicker-title">';
|
1592
|
+
var monthHtml = '';
|
1593
|
+
// month selection
|
1594
|
+
if (secondary || !changeMonth)
|
1595
|
+
monthHtml += '<span class="ui-datepicker-month">' + monthNames[drawMonth] + '</span>';
|
1596
|
+
else {
|
1597
|
+
var inMinYear = (minDate && minDate.getFullYear() == drawYear);
|
1598
|
+
var inMaxYear = (maxDate && maxDate.getFullYear() == drawYear);
|
1599
|
+
monthHtml += '<select class="ui-datepicker-month" ' +
|
1600
|
+
'onchange="DP_jQuery_' + dpuuid + '.datepicker._selectMonthYear(\'#' + inst.id + '\', this, \'M\');" ' +
|
1601
|
+
'>';
|
1602
|
+
for (var month = 0; month < 12; month++) {
|
1603
|
+
if ((!inMinYear || month >= minDate.getMonth()) &&
|
1604
|
+
(!inMaxYear || month <= maxDate.getMonth()))
|
1605
|
+
monthHtml += '<option value="' + month + '"' +
|
1606
|
+
(month == drawMonth ? ' selected="selected"' : '') +
|
1607
|
+
'>' + monthNamesShort[month] + '</option>';
|
1608
|
+
}
|
1609
|
+
monthHtml += '</select>';
|
1610
|
+
}
|
1611
|
+
if (!showMonthAfterYear)
|
1612
|
+
html += monthHtml + (secondary || !(changeMonth && changeYear) ? ' ' : '');
|
1613
|
+
// year selection
|
1614
|
+
if ( !inst.yearshtml ) {
|
1615
|
+
inst.yearshtml = '';
|
1616
|
+
if (secondary || !changeYear)
|
1617
|
+
html += '<span class="ui-datepicker-year">' + drawYear + '</span>';
|
1618
|
+
else {
|
1619
|
+
// determine range of years to display
|
1620
|
+
var years = this._get(inst, 'yearRange').split(':');
|
1621
|
+
var thisYear = new Date().getFullYear();
|
1622
|
+
var determineYear = function(value) {
|
1623
|
+
var year = (value.match(/c[+-].*/) ? drawYear + parseInt(value.substring(1), 10) :
|
1624
|
+
(value.match(/[+-].*/) ? thisYear + parseInt(value, 10) :
|
1625
|
+
parseInt(value, 10)));
|
1626
|
+
return (isNaN(year) ? thisYear : year);
|
1627
|
+
};
|
1628
|
+
var year = determineYear(years[0]);
|
1629
|
+
var endYear = Math.max(year, determineYear(years[1] || ''));
|
1630
|
+
year = (minDate ? Math.max(year, minDate.getFullYear()) : year);
|
1631
|
+
endYear = (maxDate ? Math.min(endYear, maxDate.getFullYear()) : endYear);
|
1632
|
+
inst.yearshtml += '<select class="ui-datepicker-year" ' +
|
1633
|
+
'onchange="DP_jQuery_' + dpuuid + '.datepicker._selectMonthYear(\'#' + inst.id + '\', this, \'Y\');" ' +
|
1634
|
+
'>';
|
1635
|
+
for (; year <= endYear; year++) {
|
1636
|
+
inst.yearshtml += '<option value="' + year + '"' +
|
1637
|
+
(year == drawYear ? ' selected="selected"' : '') +
|
1638
|
+
'>' + year + '</option>';
|
1639
|
+
}
|
1640
|
+
inst.yearshtml += '</select>';
|
1641
|
+
|
1642
|
+
html += inst.yearshtml;
|
1643
|
+
inst.yearshtml = null;
|
1644
|
+
}
|
1645
|
+
}
|
1646
|
+
html += this._get(inst, 'yearSuffix');
|
1647
|
+
if (showMonthAfterYear)
|
1648
|
+
html += (secondary || !(changeMonth && changeYear) ? ' ' : '') + monthHtml;
|
1649
|
+
html += '</div>'; // Close datepicker_header
|
1650
|
+
return html;
|
1651
|
+
},
|
1652
|
+
|
1653
|
+
/* Adjust one of the date sub-fields. */
|
1654
|
+
_adjustInstDate: function(inst, offset, period) {
|
1655
|
+
var year = inst.drawYear + (period == 'Y' ? offset : 0);
|
1656
|
+
var month = inst.drawMonth + (period == 'M' ? offset : 0);
|
1657
|
+
var day = Math.min(inst.selectedDay, this._getDaysInMonth(year, month)) +
|
1658
|
+
(period == 'D' ? offset : 0);
|
1659
|
+
var date = this._restrictMinMax(inst,
|
1660
|
+
this._daylightSavingAdjust(new Date(year, month, day)));
|
1661
|
+
inst.selectedDay = date.getDate();
|
1662
|
+
inst.drawMonth = inst.selectedMonth = date.getMonth();
|
1663
|
+
inst.drawYear = inst.selectedYear = date.getFullYear();
|
1664
|
+
if (period == 'M' || period == 'Y')
|
1665
|
+
this._notifyChange(inst);
|
1666
|
+
},
|
1667
|
+
|
1668
|
+
/* Ensure a date is within any min/max bounds. */
|
1669
|
+
_restrictMinMax: function(inst, date) {
|
1670
|
+
var minDate = this._getMinMaxDate(inst, 'min');
|
1671
|
+
var maxDate = this._getMinMaxDate(inst, 'max');
|
1672
|
+
var newDate = (minDate && date < minDate ? minDate : date);
|
1673
|
+
newDate = (maxDate && newDate > maxDate ? maxDate : newDate);
|
1674
|
+
return newDate;
|
1675
|
+
},
|
1676
|
+
|
1677
|
+
/* Notify change of month/year. */
|
1678
|
+
_notifyChange: function(inst) {
|
1679
|
+
var onChange = this._get(inst, 'onChangeMonthYear');
|
1680
|
+
if (onChange)
|
1681
|
+
onChange.apply((inst.input ? inst.input[0] : null),
|
1682
|
+
[inst.selectedYear, inst.selectedMonth + 1, inst]);
|
1683
|
+
},
|
1684
|
+
|
1685
|
+
/* Determine the number of months to show. */
|
1686
|
+
_getNumberOfMonths: function(inst) {
|
1687
|
+
var numMonths = this._get(inst, 'numberOfMonths');
|
1688
|
+
return (numMonths == null ? [1, 1] : (typeof numMonths == 'number' ? [1, numMonths] : numMonths));
|
1689
|
+
},
|
1690
|
+
|
1691
|
+
/* Determine the current maximum date - ensure no time components are set. */
|
1692
|
+
_getMinMaxDate: function(inst, minMax) {
|
1693
|
+
return this._determineDate(inst, this._get(inst, minMax + 'Date'), null);
|
1694
|
+
},
|
1695
|
+
|
1696
|
+
/* Find the number of days in a given month. */
|
1697
|
+
_getDaysInMonth: function(year, month) {
|
1698
|
+
return 32 - this._daylightSavingAdjust(new Date(year, month, 32)).getDate();
|
1699
|
+
},
|
1700
|
+
|
1701
|
+
/* Find the day of the week of the first of a month. */
|
1702
|
+
_getFirstDayOfMonth: function(year, month) {
|
1703
|
+
return new Date(year, month, 1).getDay();
|
1704
|
+
},
|
1705
|
+
|
1706
|
+
/* Determines if we should allow a "next/prev" month display change. */
|
1707
|
+
_canAdjustMonth: function(inst, offset, curYear, curMonth) {
|
1708
|
+
var numMonths = this._getNumberOfMonths(inst);
|
1709
|
+
var date = this._daylightSavingAdjust(new Date(curYear,
|
1710
|
+
curMonth + (offset < 0 ? offset : numMonths[0] * numMonths[1]), 1));
|
1711
|
+
if (offset < 0)
|
1712
|
+
date.setDate(this._getDaysInMonth(date.getFullYear(), date.getMonth()));
|
1713
|
+
return this._isInRange(inst, date);
|
1714
|
+
},
|
1715
|
+
|
1716
|
+
/* Is the given date in the accepted range? */
|
1717
|
+
_isInRange: function(inst, date) {
|
1718
|
+
var minDate = this._getMinMaxDate(inst, 'min');
|
1719
|
+
var maxDate = this._getMinMaxDate(inst, 'max');
|
1720
|
+
return ((!minDate || date.getTime() >= minDate.getTime()) &&
|
1721
|
+
(!maxDate || date.getTime() <= maxDate.getTime()));
|
1722
|
+
},
|
1723
|
+
|
1724
|
+
/* Provide the configuration settings for formatting/parsing. */
|
1725
|
+
_getFormatConfig: function(inst) {
|
1726
|
+
var shortYearCutoff = this._get(inst, 'shortYearCutoff');
|
1727
|
+
shortYearCutoff = (typeof shortYearCutoff != 'string' ? shortYearCutoff :
|
1728
|
+
new Date().getFullYear() % 100 + parseInt(shortYearCutoff, 10));
|
1729
|
+
return {shortYearCutoff: shortYearCutoff,
|
1730
|
+
dayNamesShort: this._get(inst, 'dayNamesShort'), dayNames: this._get(inst, 'dayNames'),
|
1731
|
+
monthNamesShort: this._get(inst, 'monthNamesShort'), monthNames: this._get(inst, 'monthNames')};
|
1732
|
+
},
|
1733
|
+
|
1734
|
+
/* Format the given date for display. */
|
1735
|
+
_formatDate: function(inst, day, month, year) {
|
1736
|
+
if (!day) {
|
1737
|
+
inst.currentDay = inst.selectedDay;
|
1738
|
+
inst.currentMonth = inst.selectedMonth;
|
1739
|
+
inst.currentYear = inst.selectedYear;
|
1740
|
+
}
|
1741
|
+
var date = (day ? (typeof day == 'object' ? day :
|
1742
|
+
this._daylightSavingAdjust(new Date(year, month, day))) :
|
1743
|
+
this._daylightSavingAdjust(new Date(inst.currentYear, inst.currentMonth, inst.currentDay)));
|
1744
|
+
return this.formatDate(this._get(inst, 'dateFormat'), date, this._getFormatConfig(inst));
|
1745
|
+
}
|
1746
|
+
});
|
1747
|
+
|
1748
|
+
/*
|
1749
|
+
* Bind hover events for datepicker elements.
|
1750
|
+
* Done via delegate so the binding only occurs once in the lifetime of the parent div.
|
1751
|
+
* Global instActive, set by _updateDatepicker allows the handlers to find their way back to the active picker.
|
1752
|
+
*/
|
1753
|
+
function bindHover(dpDiv) {
|
1754
|
+
var selector = 'button, .ui-datepicker-prev, .ui-datepicker-next, .ui-datepicker-calendar td a';
|
1755
|
+
return dpDiv.bind('mouseout', function(event) {
|
1756
|
+
var elem = $( event.target ).closest( selector );
|
1757
|
+
if ( !elem.length ) {
|
1758
|
+
return;
|
1759
|
+
}
|
1760
|
+
elem.removeClass( "ui-state-hover ui-datepicker-prev-hover ui-datepicker-next-hover" );
|
1761
|
+
})
|
1762
|
+
.bind('mouseover', function(event) {
|
1763
|
+
var elem = $( event.target ).closest( selector );
|
1764
|
+
if ($.datepicker._isDisabledDatepicker( instActive.inline ? dpDiv.parent()[0] : instActive.input[0]) ||
|
1765
|
+
!elem.length ) {
|
1766
|
+
return;
|
1767
|
+
}
|
1768
|
+
elem.parents('.ui-datepicker-calendar').find('a').removeClass('ui-state-hover');
|
1769
|
+
elem.addClass('ui-state-hover');
|
1770
|
+
if (elem.hasClass('ui-datepicker-prev')) elem.addClass('ui-datepicker-prev-hover');
|
1771
|
+
if (elem.hasClass('ui-datepicker-next')) elem.addClass('ui-datepicker-next-hover');
|
1772
|
+
});
|
1773
|
+
}
|
1774
|
+
|
1775
|
+
/* jQuery extend now ignores nulls! */
|
1776
|
+
function extendRemove(target, props) {
|
1777
|
+
$.extend(target, props);
|
1778
|
+
for (var name in props)
|
1779
|
+
if (props[name] == null || props[name] == undefined)
|
1780
|
+
target[name] = props[name];
|
1781
|
+
return target;
|
1782
|
+
};
|
1783
|
+
|
1784
|
+
/* Determine whether an object is an array. */
|
1785
|
+
function isArray(a) {
|
1786
|
+
return (a && (($.browser.safari && typeof a == 'object' && a.length) ||
|
1787
|
+
(a.constructor && a.constructor.toString().match(/\Array\(\)/))));
|
1788
|
+
};
|
1789
|
+
|
1790
|
+
/* Invoke the datepicker functionality.
|
1791
|
+
@param options string - a command, optionally followed by additional parameters or
|
1792
|
+
Object - settings for attaching new datepicker functionality
|
1793
|
+
@return jQuery object */
|
1794
|
+
$.fn.datepicker = function(options){
|
1795
|
+
|
1796
|
+
/* Verify an empty collection wasn't passed - Fixes #6976 */
|
1797
|
+
if ( !this.length ) {
|
1798
|
+
return this;
|
1799
|
+
}
|
1800
|
+
|
1801
|
+
/* Initialise the date picker. */
|
1802
|
+
if (!$.datepicker.initialized) {
|
1803
|
+
$(document).mousedown($.datepicker._checkExternalClick).
|
1804
|
+
find('body').append($.datepicker.dpDiv);
|
1805
|
+
$.datepicker.initialized = true;
|
1806
|
+
}
|
1807
|
+
|
1808
|
+
var otherArgs = Array.prototype.slice.call(arguments, 1);
|
1809
|
+
if (typeof options == 'string' && (options == 'isDisabled' || options == 'getDate' || options == 'widget'))
|
1810
|
+
return $.datepicker['_' + options + 'Datepicker'].
|
1811
|
+
apply($.datepicker, [this[0]].concat(otherArgs));
|
1812
|
+
if (options == 'option' && arguments.length == 2 && typeof arguments[1] == 'string')
|
1813
|
+
return $.datepicker['_' + options + 'Datepicker'].
|
1814
|
+
apply($.datepicker, [this[0]].concat(otherArgs));
|
1815
|
+
return this.each(function() {
|
1816
|
+
typeof options == 'string' ?
|
1817
|
+
$.datepicker['_' + options + 'Datepicker'].
|
1818
|
+
apply($.datepicker, [this].concat(otherArgs)) :
|
1819
|
+
$.datepicker._attachDatepicker(this, options);
|
1820
|
+
});
|
1821
|
+
};
|
1822
|
+
|
1823
|
+
$.datepicker = new Datepicker(); // singleton instance
|
1824
|
+
$.datepicker.initialized = false;
|
1825
|
+
$.datepicker.uuid = new Date().getTime();
|
1826
|
+
$.datepicker.version = "1.8.18";
|
1827
|
+
|
1828
|
+
// Workaround for #4055
|
1829
|
+
// Add another global to avoid noConflict issues with inline event handlers
|
1830
|
+
window['DP_jQuery_' + dpuuid] = $;
|
1831
|
+
|
1832
|
+
})(jQuery);
|
1833
|
+
:@created_atf1335716315.665298�>
|