mail_engine 0.0.1 → 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- data/.yardoc/checksums +12 -11
- data/.yardoc/objects/ActionMailer.dat +0 -0
- data/.yardoc/objects/ActionMailer/Base.dat +0 -0
- data/.yardoc/objects/ActionMailer/Base/collect_responses_and_parts_order_i.dat +0 -0
- data/.yardoc/objects/ActionMailer/Base/mail_i.dat +0 -0
- data/.yardoc/objects/ActionMailer/Base/origin_mail_i.dat +0 -0
- data/.yardoc/objects/ActionMailer/Base/set_layout_and_partials_i.dat +0 -0
- data/.yardoc/objects/ActionMailer/Collector.dat +0 -0
- data/.yardoc/objects/ActionMailer/Collector/custom_i.dat +0 -0
- data/.yardoc/objects/MailEngine.dat +0 -0
- data/.yardoc/objects/MailEngine/ActsAsMailReceiver.dat +0 -0
- data/.yardoc/objects/MailEngine/ActsAsMailReceiver/ClassMethods.dat +0 -0
- data/.yardoc/objects/MailEngine/ActsAsMailReceiver/ClassMethods/acts_as_mail_receiver_i.dat +0 -0
- data/.yardoc/objects/MailEngine/ActsAsMailReceiver/ClassMethods/check_method_existance_21_i.dat +0 -0
- data/.yardoc/objects/MailEngine/Base.dat +0 -0
- data/.yardoc/objects/MailEngine/Base/_40_40configurations.dat +0 -0
- data/.yardoc/objects/MailEngine/Base/current_config_c.dat +0 -0
- data/.yardoc/objects/MailEngine/Base/send_marketing_mail_c.dat +0 -0
- data/.yardoc/objects/MailEngine/Configuration.dat +0 -0
- data/.yardoc/objects/MailEngine/Configuration/load_c.dat +0 -0
- data/.yardoc/objects/MailEngine/CopyMigrations.dat +0 -0
- data/.yardoc/objects/MailEngine/CopyMigrations/copy_migrations_i.dat +0 -0
- data/.yardoc/objects/MailEngine/CopyResources.dat +0 -0
- data/.yardoc/objects/MailEngine/CopyResources/copy_resources_i.dat +0 -0
- data/.yardoc/objects/MailEngine/CreateConfig.dat +0 -0
- data/.yardoc/objects/MailEngine/CreateConfig/create_config_file_i.dat +0 -0
- data/.yardoc/objects/MailEngine/Engine.dat +0 -0
- data/.yardoc/objects/MailEngine/HtmlDocumentAssetsReplacer.dat +0 -0
- data/.yardoc/objects/MailEngine/HtmlDocumentAssetsReplacer/check_21_c.dat +0 -0
- data/.yardoc/objects/MailEngine/HtmlDocumentAssetsReplacer/get_resource_url_c.dat +0 -0
- data/.yardoc/objects/MailEngine/HtmlDocumentAssetsReplacer/process_c.dat +0 -0
- data/.yardoc/objects/MailEngine/HtmlDocumentAssetsReplacer/replace_resource_in_html_c.dat +0 -0
- data/.yardoc/objects/MailEngine/Install.dat +0 -0
- data/.yardoc/objects/MailEngine/Install/copy_migrations_i.dat +0 -0
- data/.yardoc/objects/MailEngine/Install/copy_resources_i.dat +0 -0
- data/.yardoc/objects/MailEngine/Install/create_config_i.dat +0 -0
- data/.yardoc/objects/MailEngine/MailLogSubscriber.dat +0 -0
- data/.yardoc/objects/MailEngine/MailLogSubscriber/deliver_i.dat +0 -0
- data/.yardoc/objects/MailEngine/PLACEHOLDERS_IN_LAYOUT.dat +0 -0
- data/.yardoc/objects/MailEngine/Sendgrid.dat +0 -0
- data/.yardoc/objects/MailEngine/Sendgrid/Base.dat +0 -0
- data/.yardoc/objects/MailEngine/Sendgrid/Base/ClassMethods.dat +0 -0
- data/.yardoc/objects/MailEngine/Sendgrid/Base/ClassMethods/sendgrid_header_i.dat +0 -0
- data/.yardoc/objects/MailEngine/Sendgrid/Base/InstanceMethods.dat +0 -0
- data/.yardoc/objects/MailEngine/Sendgrid/FilterSetting.dat +0 -0
- data/.yardoc/objects/MailEngine/Sendgrid/FilterSetting/data_3D_i.dat +0 -0
- data/.yardoc/objects/MailEngine/Sendgrid/FilterSetting/data_i.dat +0 -0
- data/.yardoc/objects/MailEngine/Sendgrid/FilterSetting/initialize_i.dat +0 -0
- data/.yardoc/objects/MailEngine/Sendgrid/FilterSetting/validate_config_21_i.dat +0 -0
- data/.yardoc/objects/MailEngine/Sendgrid/RestApi.dat +0 -0
- data/.yardoc/objects/MailEngine/Sendgrid/RestApi/blocks_c.dat +0 -0
- data/.yardoc/objects/MailEngine/Sendgrid/RestApi/bounces_c.dat +0 -0
- data/.yardoc/objects/MailEngine/Sendgrid/RestApi/invalidemails_c.dat +0 -0
- data/.yardoc/objects/MailEngine/Sendgrid/RestApi/spamreports_c.dat +0 -0
- data/.yardoc/objects/MailEngine/Sendgrid/RestApi/stats_c.dat +0 -0
- data/.yardoc/objects/MailEngine/Sendgrid/RestApiError.dat +0 -0
- data/.yardoc/objects/MailEngine/Sendgrid/SmtpApi.dat +0 -0
- data/.yardoc/objects/MailEngine/Sendgrid/SmtpApi/add_sub_val_i.dat +0 -0
- data/.yardoc/objects/MailEngine/Sendgrid/SmtpApi/add_to_i.dat +0 -0
- data/.yardoc/objects/MailEngine/Sendgrid/SmtpApi/category_i.dat +0 -0
- data/.yardoc/objects/MailEngine/Sendgrid/SmtpApi/filters_i.dat +0 -0
- data/.yardoc/objects/MailEngine/Sendgrid/SmtpApi/initialize_i.dat +0 -0
- data/.yardoc/objects/MailEngine/Sendgrid/SmtpApi/set_unique_args_i.dat +0 -0
- data/.yardoc/objects/MailEngine/Sendgrid/SmtpApi/to_hash_i.dat +0 -0
- data/.yardoc/objects/MailEngine/Sendgrid/SmtpApi/to_json_i.dat +0 -0
- data/.yardoc/objects/MailEngine/Sendgrid/SmtpApi/to_s_i.dat +0 -0
- data/.yardoc/objects/MailEngine/VERSION.dat +0 -0
- data/.yardoc/objects/MailEngine/ZipProcessor.dat +0 -0
- data/.yardoc/objects/MailEngine/ZipProcessor/extract_all_files_c.dat +0 -0
- data/.yardoc/objects/root.dat +0 -0
- data/Gemfile +16 -13
- data/Gemfile.lock +69 -46
- data/README.mkd +14 -2
- data/VERSION +1 -1
- data/app/controllers/mail_engine/application_controller.rb +4 -0
- data/app/controllers/mail_engine/mail_logs_controller.rb +1 -1
- data/app/controllers/mail_engine/mail_schedules_controller.rb +4 -4
- data/app/controllers/mail_engine/mail_template_files_controller.rb +4 -4
- data/app/controllers/mail_engine/mail_templates_controller.rb +16 -11
- data/app/controllers/mail_engine/reports_controller.rb +5 -1
- data/app/helpers/mail_engine/mail_engine_helper.rb +1 -1
- data/app/mailers/mail_engine/mail_dispatcher.rb +16 -9
- data/app/models/mail_engine/mail_log.rb +1 -1
- data/app/models/mail_engine/mail_schedule.rb +14 -12
- data/app/models/mail_engine/mail_template.rb +81 -55
- data/app/models/mail_engine/mail_template_file.rb +4 -3
- data/app/views/layouts/mail_engine/mail_engine.html.erb +31 -18
- data/app/views/layouts/mail_engine/simple.html.erb +14 -0
- data/app/views/mail_engine/dashboard/index.html.erb +18 -1
- data/app/views/mail_engine/mail_logs/_related_logs.html.erb +29 -0
- data/app/views/mail_engine/mail_logs/index.html.erb +5 -5
- data/app/views/mail_engine/mail_schedules/_form.html.erb +6 -5
- data/app/views/mail_engine/mail_schedules/index.html.erb +13 -8
- data/app/views/mail_engine/mail_schedules/show.html.erb +2 -0
- data/app/views/mail_engine/mail_template_files/_form.html.erb +20 -10
- data/app/views/mail_engine/mail_template_files/edit.html.erb +2 -0
- data/app/views/mail_engine/mail_template_files/new.html.erb +2 -0
- data/app/views/mail_engine/mail_templates/_form.html.erb +65 -12
- data/app/views/mail_engine/mail_templates/_layout_selector.html.erb +3 -3
- data/app/views/mail_engine/mail_templates/duplicate.html.erb +11 -7
- data/app/views/mail_engine/mail_templates/index.html.erb +25 -21
- data/app/views/mail_engine/mail_templates/new_by_upload.html.erb +11 -5
- data/app/views/mail_engine/mail_templates/partial_options.html.erb +2 -2
- data/app/views/mail_engine/mail_templates/show.html.erb +19 -29
- data/app/views/mail_engine/reports/charts/blocks.html.erb +2 -2
- data/app/views/mail_engine/reports/charts/bounces.html.erb +2 -2
- data/app/views/mail_engine/reports/charts/invalidemails.html.erb +2 -2
- data/app/views/mail_engine/reports/charts/spamreports.html.erb +2 -2
- data/app/views/mail_engine/reports/index.html.erb +40 -5
- data/config/routes.rb +5 -6
- data/db/migrate/20110114030841_create_table_mail_template.rb +1 -0
- data/doc/ActionMailer.html +108 -0
- data/doc/ActionMailer/Base.html +193 -0
- data/doc/ActionMailer/Collector.html +175 -0
- data/doc/MailEngine.html +146 -0
- data/doc/MailEngine/ActsAsMailReceiver.html +97 -0
- data/doc/MailEngine/ActsAsMailReceiver/ClassMethods.html +187 -0
- data/doc/MailEngine/Base.html +297 -0
- data/doc/MailEngine/Configuration.html +181 -0
- data/doc/MailEngine/CopyMigrations.html +187 -0
- data/doc/MailEngine/CopyResources.html +171 -0
- data/doc/MailEngine/CreateConfig.html +193 -0
- data/doc/MailEngine/CreateMigration.html +187 -0
- data/doc/MailEngine/Engine.html +100 -0
- data/doc/MailEngine/HtmlDocumentAssetsReplacer.html +397 -0
- data/doc/MailEngine/Install.html +273 -0
- data/doc/MailEngine/MailLogSubscriber.html +204 -0
- data/doc/MailEngine/Sendgrid.html +101 -0
- data/doc/MailEngine/Sendgrid/Base.html +97 -0
- data/doc/MailEngine/Sendgrid/Base/ClassMethods.html +150 -0
- data/doc/MailEngine/Sendgrid/Base/InstanceMethods.html +81 -0
- data/doc/MailEngine/Sendgrid/FilterSetting.html +257 -0
- data/doc/MailEngine/Sendgrid/RestApi.html +476 -0
- data/doc/MailEngine/Sendgrid/RestApiError.html +100 -0
- data/doc/MailEngine/Sendgrid/SmtpApi.html +604 -0
- data/doc/MailEngine/ZipProcessor.html +267 -0
- data/doc/_index.html +21 -7
- data/doc/class_list.html +1 -1
- data/doc/file.README.html +231 -0
- data/doc/index.html +231 -0
- data/doc/method_list.html +45 -21
- data/doc/top-level-namespace.html +88 -0
- data/lib/mail_engine.rb +7 -1
- data/lib/mail_engine/action_mailer_patch.rb +7 -0
- data/lib/mail_engine/acts_as_mail_receiver.rb +40 -6
- data/lib/mail_engine/base.rb +28 -7
- data/lib/mail_engine/configuration.rb +3 -0
- data/lib/mail_engine/engine.rb +5 -5
- data/lib/mail_engine/generators/{create_migration.rb → copy_migrations.rb} +4 -3
- data/lib/mail_engine/generators/copy_resources.rb +13 -0
- data/lib/mail_engine/generators/install.rb +21 -0
- data/lib/mail_engine/generators/templates/mail_engine_config.yml +10 -1
- data/lib/mail_engine/html_document_assets_replacer.rb +12 -23
- data/lib/mail_engine/mail_log_subscriber.rb +13 -5
- data/lib/mail_engine/zip_processor.rb +10 -1
- data/mail_engine.gemspec +336 -110
- data/public/images/mail_engine/header_and_footer_layout.png +0 -0
- data/public/images/mail_engine/icons/add.png +0 -0
- data/public/images/mail_engine/icons/copy.png +0 -0
- data/public/images/mail_engine/icons/delete.png +0 -0
- data/public/images/mail_engine/icons/edit.gif +0 -0
- data/public/images/mail_engine/icons/missing.png +0 -0
- data/public/images/mail_engine/icons/save.png +0 -0
- data/public/images/mail_engine/icons/show.png +0 -0
- data/public/images/mail_engine/logo.gif +0 -0
- data/public/images/mail_engine/logo.png +0 -0
- data/public/images/mail_engine/none_layout.png +0 -0
- data/public/images/mail_engine/only_footer_layout.png +0 -0
- data/public/images/mail_engine/unselect_header_and_footer_layout.png +0 -0
- data/public/images/mail_engine/unselect_none_layout.png +0 -0
- data/public/images/mail_engine/unselect_only_footer_layout.png +0 -0
- data/public/javascripts/mail_engine/fancybox/blank.gif +0 -0
- data/public/javascripts/mail_engine/fancybox/fancy_close.png +0 -0
- data/public/javascripts/mail_engine/fancybox/fancy_loading.png +0 -0
- data/public/javascripts/mail_engine/fancybox/fancy_nav_left.png +0 -0
- data/public/javascripts/mail_engine/fancybox/fancy_nav_right.png +0 -0
- data/public/javascripts/mail_engine/fancybox/fancy_shadow_e.png +0 -0
- data/public/javascripts/mail_engine/fancybox/fancy_shadow_n.png +0 -0
- data/public/javascripts/mail_engine/fancybox/fancy_shadow_ne.png +0 -0
- data/public/javascripts/mail_engine/fancybox/fancy_shadow_nw.png +0 -0
- data/public/javascripts/mail_engine/fancybox/fancy_shadow_s.png +0 -0
- data/public/javascripts/mail_engine/fancybox/fancy_shadow_se.png +0 -0
- data/public/javascripts/mail_engine/fancybox/fancy_shadow_sw.png +0 -0
- data/public/javascripts/mail_engine/fancybox/fancy_shadow_w.png +0 -0
- data/public/javascripts/mail_engine/fancybox/fancy_title_left.png +0 -0
- data/public/javascripts/mail_engine/fancybox/fancy_title_main.png +0 -0
- data/public/javascripts/mail_engine/fancybox/fancy_title_over.png +0 -0
- data/public/javascripts/mail_engine/fancybox/fancy_title_right.png +0 -0
- data/public/javascripts/mail_engine/fancybox/fancybox-x.png +0 -0
- data/public/javascripts/mail_engine/fancybox/fancybox-y.png +0 -0
- data/public/javascripts/mail_engine/fancybox/fancybox.png +0 -0
- data/public/javascripts/mail_engine/fancybox/jquery.easing-1.3.pack.js +72 -0
- data/public/javascripts/mail_engine/fancybox/jquery.fancybox-1.3.4.css +359 -0
- data/public/javascripts/mail_engine/fancybox/jquery.fancybox-1.3.4.js +1156 -0
- data/public/javascripts/mail_engine/fancybox/jquery.fancybox-1.3.4.pack.js +46 -0
- data/public/javascripts/mail_engine/fancybox/jquery.mousewheel-3.0.4.pack.js +14 -0
- data/public/javascripts/mail_engine/jquery-ui.min.js +577 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/jquery.iframe-auto-height.plugin.js +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/jquery.string.js +0 -0
- data/{test/dummy/public/javascripts/mail_engine_application.js → public/javascripts/mail_engine/mail_engine.js} +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/jquery.markitup.js +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/css/images/bold.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/css/images/css.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/css/images/italic.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/css/images/picture.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/css/images/stroke.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/css/images/tag.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/css/images/text_align_center.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/css/images/text_align_justify.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/css/images/text_align_left.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/css/images/text_align_right.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/css/images/text_indent.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/css/images/text_letterspacing.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/css/images/text_linespacing.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/css/images/text_lowercase.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/css/images/text_padding_bottom.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/css/images/text_padding_left.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/css/images/text_padding_right.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/css/images/text_padding_top.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/css/images/text_uppercase.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/css/readme.txt +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/css/set.js +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/css/style.css +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/default/images/bold.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/default/images/clean.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/default/images/image.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/default/images/italic.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/default/images/link.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/default/images/picture.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/default/images/preview.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/default/images/stroke.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/default/set.js +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/default/style.css +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/html/images/bold.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/html/images/clean.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/html/images/h1.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/html/images/h2.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/html/images/h3.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/html/images/h4.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/html/images/h5.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/html/images/h6.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/html/images/image.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/html/images/italic.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/html/images/link.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/html/images/list-bullet.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/html/images/list-item.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/html/images/list-numeric.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/html/images/paragraph.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/html/images/picture.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/html/images/preview.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/html/images/stroke.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/html/readme.txt +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/html/set.js +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/sets/html/style.css +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/skins/markitup/images/bg-container.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/skins/markitup/images/bg-editor-bbcode.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/skins/markitup/images/bg-editor-dotclear.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/skins/markitup/images/bg-editor-html.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/skins/markitup/images/bg-editor-json.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/skins/markitup/images/bg-editor-markdown.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/skins/markitup/images/bg-editor-textile.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/skins/markitup/images/bg-editor-wiki.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/skins/markitup/images/bg-editor-xml.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/skins/markitup/images/bg-editor.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/skins/markitup/images/handle.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/skins/markitup/images/menu.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/skins/markitup/images/submenu.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/skins/markitup/style.css +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/skins/simple/images/handle.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/skins/simple/images/menu.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/skins/simple/images/submenu.png +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/skins/simple/style.css +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/templates/preview.css +0 -0
- data/{test/dummy/public/javascripts → public/javascripts/mail_engine}/markitup/templates/preview.html +0 -0
- data/public/stylesheets/mail_engine/jquery-ui/smoothness/images/ui-bg_flat_0_aaaaaa_40x100.png +0 -0
- data/public/stylesheets/mail_engine/jquery-ui/smoothness/images/ui-bg_flat_75_ffffff_40x100.png +0 -0
- data/public/stylesheets/mail_engine/jquery-ui/smoothness/images/ui-bg_glass_55_fbf9ee_1x400.png +0 -0
- data/public/stylesheets/mail_engine/jquery-ui/smoothness/images/ui-bg_glass_65_ffffff_1x400.png +0 -0
- data/public/stylesheets/mail_engine/jquery-ui/smoothness/images/ui-bg_glass_75_dadada_1x400.png +0 -0
- data/public/stylesheets/mail_engine/jquery-ui/smoothness/images/ui-bg_glass_75_e6e6e6_1x400.png +0 -0
- data/public/stylesheets/mail_engine/jquery-ui/smoothness/images/ui-bg_glass_95_fef1ec_1x400.png +0 -0
- data/public/stylesheets/mail_engine/jquery-ui/smoothness/images/ui-bg_highlight-soft_75_cccccc_1x100.png +0 -0
- data/public/stylesheets/mail_engine/jquery-ui/smoothness/images/ui-icons_222222_256x240.png +0 -0
- data/public/stylesheets/mail_engine/jquery-ui/smoothness/images/ui-icons_2e83ff_256x240.png +0 -0
- data/public/stylesheets/mail_engine/jquery-ui/smoothness/images/ui-icons_454545_256x240.png +0 -0
- data/public/stylesheets/mail_engine/jquery-ui/smoothness/images/ui-icons_888888_256x240.png +0 -0
- data/public/stylesheets/mail_engine/jquery-ui/smoothness/images/ui-icons_cd0a0a_256x240.png +0 -0
- data/public/stylesheets/mail_engine/jquery-ui/smoothness/jquery-ui.css +544 -0
- data/{test/dummy/public/stylesheets → public/stylesheets/mail_engine}/style.css +6 -2
- data/test/dummy/app/controllers/application_controller.rb +0 -8
- data/test/dummy/app/models/user.rb +6 -4
- data/test/dummy/config/application.rb +2 -2
- data/test/dummy/config/database.yml +2 -2
- data/test/dummy/db/migrate/20110114030841_create_table_mail_template.rb +1 -0
- data/test/dummy/db/migrate/20110206025002_create_mail_logs.rb +1 -1
- data/test/dummy/db/schema.rb +1 -0
- data/test/dummy/public/images/mail_engine/icons/add.png +0 -0
- data/test/dummy/public/images/mail_engine/icons/copy.png +0 -0
- data/test/dummy/public/images/mail_engine/icons/delete.png +0 -0
- data/test/dummy/public/images/mail_engine/icons/edit.gif +0 -0
- data/test/dummy/public/images/mail_engine/icons/missing.png +0 -0
- data/test/dummy/public/images/mail_engine/icons/save.png +0 -0
- data/test/dummy/public/images/mail_engine/icons/show.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/fancybox/blank.gif +0 -0
- data/test/dummy/public/javascripts/mail_engine/fancybox/fancy_close.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/fancybox/fancy_loading.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/fancybox/fancy_nav_left.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/fancybox/fancy_nav_right.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/fancybox/fancy_shadow_e.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/fancybox/fancy_shadow_n.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/fancybox/fancy_shadow_ne.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/fancybox/fancy_shadow_nw.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/fancybox/fancy_shadow_s.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/fancybox/fancy_shadow_se.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/fancybox/fancy_shadow_sw.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/fancybox/fancy_shadow_w.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/fancybox/fancy_title_left.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/fancybox/fancy_title_main.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/fancybox/fancy_title_over.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/fancybox/fancy_title_right.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/fancybox/fancybox-x.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/fancybox/fancybox-y.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/fancybox/fancybox.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/fancybox/jquery.easing-1.3.pack.js +72 -0
- data/test/dummy/public/javascripts/mail_engine/fancybox/jquery.fancybox-1.3.4.css +359 -0
- data/test/dummy/public/javascripts/mail_engine/fancybox/jquery.fancybox-1.3.4.js +1156 -0
- data/test/dummy/public/javascripts/mail_engine/fancybox/jquery.fancybox-1.3.4.pack.js +46 -0
- data/test/dummy/public/javascripts/mail_engine/fancybox/jquery.mousewheel-3.0.4.pack.js +14 -0
- data/test/dummy/public/javascripts/mail_engine/jquery-ui.min.js +577 -0
- data/test/dummy/public/javascripts/mail_engine/jquery.iframe-auto-height.plugin.js +50 -0
- data/test/dummy/public/javascripts/mail_engine/jquery.string.js +425 -0
- data/test/dummy/public/javascripts/mail_engine/mail_engine.js +2 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/jquery.markitup.js +564 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/css/images/bold.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/css/images/css.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/css/images/italic.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/css/images/picture.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/css/images/stroke.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/css/images/tag.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/css/images/text_align_center.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/css/images/text_align_justify.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/css/images/text_align_left.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/css/images/text_align_right.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/css/images/text_indent.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/css/images/text_letterspacing.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/css/images/text_linespacing.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/css/images/text_lowercase.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/css/images/text_padding_bottom.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/css/images/text_padding_left.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/css/images/text_padding_right.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/css/images/text_padding_top.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/css/images/text_uppercase.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/css/readme.txt +28 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/css/set.js +52 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/css/style.css +72 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/default/images/bold.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/default/images/clean.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/default/images/image.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/default/images/italic.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/default/images/link.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/default/images/picture.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/default/images/preview.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/default/images/stroke.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/default/set.js +27 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/default/style.css +27 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/html/images/bold.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/html/images/clean.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/html/images/h1.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/html/images/h2.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/html/images/h3.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/html/images/h4.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/html/images/h5.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/html/images/h6.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/html/images/image.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/html/images/italic.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/html/images/link.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/html/images/list-bullet.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/html/images/list-item.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/html/images/list-numeric.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/html/images/paragraph.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/html/images/picture.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/html/images/preview.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/html/images/stroke.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/html/readme.txt +11 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/html/set.js +40 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/sets/html/style.css +59 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/skins/markitup/images/bg-container.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/skins/markitup/images/bg-editor-bbcode.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/skins/markitup/images/bg-editor-dotclear.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/skins/markitup/images/bg-editor-html.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/skins/markitup/images/bg-editor-json.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/skins/markitup/images/bg-editor-markdown.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/skins/markitup/images/bg-editor-textile.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/skins/markitup/images/bg-editor-wiki.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/skins/markitup/images/bg-editor-xml.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/skins/markitup/images/bg-editor.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/skins/markitup/images/handle.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/skins/markitup/images/menu.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/skins/markitup/images/submenu.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/skins/markitup/style.css +147 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/skins/simple/images/handle.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/skins/simple/images/menu.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/skins/simple/images/submenu.png +0 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/skins/simple/style.css +118 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/templates/preview.css +5 -0
- data/test/dummy/public/javascripts/mail_engine/markitup/templates/preview.html +11 -0
- data/test/dummy/public/stylesheets/mail_engine/jquery-ui/smoothness/images/ui-bg_flat_0_aaaaaa_40x100.png +0 -0
- data/test/dummy/public/stylesheets/mail_engine/jquery-ui/smoothness/images/ui-bg_flat_75_ffffff_40x100.png +0 -0
- data/test/dummy/public/stylesheets/mail_engine/jquery-ui/smoothness/images/ui-bg_glass_55_fbf9ee_1x400.png +0 -0
- data/test/dummy/public/stylesheets/mail_engine/jquery-ui/smoothness/images/ui-bg_glass_65_ffffff_1x400.png +0 -0
- data/test/dummy/public/stylesheets/mail_engine/jquery-ui/smoothness/images/ui-bg_glass_75_dadada_1x400.png +0 -0
- data/test/dummy/public/stylesheets/mail_engine/jquery-ui/smoothness/images/ui-bg_glass_75_e6e6e6_1x400.png +0 -0
- data/test/dummy/public/stylesheets/mail_engine/jquery-ui/smoothness/images/ui-bg_glass_95_fef1ec_1x400.png +0 -0
- data/test/dummy/public/stylesheets/mail_engine/jquery-ui/smoothness/images/ui-bg_highlight-soft_75_cccccc_1x100.png +0 -0
- data/test/dummy/public/stylesheets/mail_engine/jquery-ui/smoothness/images/ui-icons_222222_256x240.png +0 -0
- data/test/dummy/public/stylesheets/mail_engine/jquery-ui/smoothness/images/ui-icons_2e83ff_256x240.png +0 -0
- data/test/dummy/public/stylesheets/mail_engine/jquery-ui/smoothness/images/ui-icons_454545_256x240.png +0 -0
- data/test/dummy/public/stylesheets/mail_engine/jquery-ui/smoothness/images/ui-icons_888888_256x240.png +0 -0
- data/test/dummy/public/stylesheets/mail_engine/jquery-ui/smoothness/images/ui-icons_cd0a0a_256x240.png +0 -0
- data/test/dummy/public/stylesheets/mail_engine/jquery-ui/smoothness/jquery-ui.css +544 -0
- data/test/dummy/public/stylesheets/mail_engine/style.css +685 -0
- data/test/factories.rb +31 -4
- data/test/functional/mail_engine/{mail_schedules_controller_controller_test.rb → dashboard_controller_test.rb} +2 -2
- data/test/functional/mail_engine/{mail_templates_controller_controller_test.rb → mail_logs_controller_test.rb} +2 -2
- data/test/functional/mail_engine/mail_schedules_controller_test.rb +8 -0
- data/test/functional/mail_engine/mail_template_files_controller_test.rb +8 -0
- data/test/functional/mail_engine/mail_templates_controller_test.rb +8 -0
- data/test/functional/mail_engine/reports_controller_test.rb +8 -0
- data/test/functional/user_mailer_test.rb +14 -0
- data/test/test_helper.rb +4 -1
- data/test/unit/mail_engine/mail_log_test.rb +1 -1
- data/test/unit/mail_engine/mail_schedule_test.rb +34 -1
- data/test/unit/mail_engine/mail_template_test.rb +51 -12
- data/test/unit/user_test.rb +20 -0
- metadata +370 -125
- data/.yardoc/objects/MailEngine/Base/send_mail_c.dat +0 -0
- data/.yardoc/objects/MailEngine/CreateMigration.dat +0 -0
- data/.yardoc/objects/MailEngine/CreateMigration/create_migrations_i.dat +0 -0
- data/.yardoc/objects/MailEngine/HtmlDocumentAssetsReplacer/replace_resource_filename_in_html_c.dat +0 -0
- data/.yardoc/objects/MailEngine/HtmlDocumentAssetsReplacer/replace_resource_url_in_html_c.dat +0 -0
- data/.yardoc/objects/PLACEHOLDERS_IN_LAYOUT.dat +0 -0
- data/lib/mail_engine/placeholders_in_layout.rb +0 -5
- data/test/dummy/public/javascripts/jquery.nyroModal/img/ajaxLoader.gif +0 -0
- data/test/dummy/public/javascripts/jquery.nyroModal/img/close.gif +0 -0
- data/test/dummy/public/javascripts/jquery.nyroModal/img/next.gif +0 -0
- data/test/dummy/public/javascripts/jquery.nyroModal/img/prev.gif +0 -0
- data/test/dummy/public/javascripts/jquery.nyroModal/js/jquery.nyroModal-ie6.js +0 -186
- data/test/dummy/public/javascripts/jquery.nyroModal/js/jquery.nyroModal-ie6.min.js +0 -9
- data/test/dummy/public/javascripts/jquery.nyroModal/js/jquery.nyroModal.custom.js +0 -1599
- data/test/dummy/public/javascripts/jquery.nyroModal/js/jquery.nyroModal.custom.min.js +0 -34
- data/test/dummy/public/javascripts/jquery.nyroModal/styles/nyroModal.css +0 -102
- data/test/dummy/public/stylesheets/.gitkeep +0 -0
@@ -3,7 +3,7 @@
|
|
3
3
|
<div class="clearer"></div>
|
4
4
|
|
5
5
|
<!-- list all kinds of layouts -->
|
6
|
-
<% PLACEHOLDERS_IN_LAYOUT.keys.each do |layout_name| %>
|
6
|
+
<% MailEngine::PLACEHOLDERS_IN_LAYOUT.keys.each do |layout_name| %>
|
7
7
|
<div class="layout_option_item left">
|
8
8
|
<%= f.radio_button :layout, layout_name, :class => "layout_option hidden", :ref => layout_name %>
|
9
9
|
|
@@ -14,12 +14,12 @@
|
|
14
14
|
<% end %>
|
15
15
|
<div class="clearer"></div>
|
16
16
|
|
17
|
-
<% PLACEHOLDERS_IN_LAYOUT.keys.each do |layout_name| %>
|
17
|
+
<% MailEngine::PLACEHOLDERS_IN_LAYOUT.keys.each do |layout_name| %>
|
18
18
|
<!-- list all placeholders -->
|
19
19
|
<div class="placeholder_list <%= layout_name %> quiet" style="margin-left: 7px"></div>
|
20
20
|
<% end %>
|
21
21
|
|
22
|
-
<
|
22
|
+
<div class="hint">Choose a template layout.</div>
|
23
23
|
</div>
|
24
24
|
|
25
25
|
<script>
|
@@ -1,13 +1,11 @@
|
|
1
1
|
<div class="post">
|
2
|
-
<div class="post-title">
|
3
|
-
<h2>
|
4
|
-
Duplicate Mail Tempate
|
5
|
-
</h2>
|
6
|
-
</div>
|
7
2
|
<div class="post-body">
|
3
|
+
<h1>Duplicate Mail Tempate</h1>
|
4
|
+
<hr />
|
5
|
+
|
8
6
|
<%= form_for(@mail_template, :url => duplicate_mail_template_path(@mail_template, :type => params[:type])) do |f| %>
|
9
7
|
<% if @duplicated_mail_template.errors.any? %>
|
10
|
-
<
|
8
|
+
<p id="error_explanation">
|
11
9
|
<h2><%= pluralize(@duplicated_mail_template.errors.count, "error") %> prohibited this mail_template from being saved:</h2>
|
12
10
|
|
13
11
|
<ul>
|
@@ -15,7 +13,7 @@
|
|
15
13
|
<li><%= msg %></li>
|
16
14
|
<% end %>
|
17
15
|
</ul>
|
18
|
-
</
|
16
|
+
</p>
|
19
17
|
<% end %>
|
20
18
|
|
21
19
|
<div class="field">
|
@@ -23,6 +21,11 @@
|
|
23
21
|
<%= f.text_field :name, :class => "text" %>
|
24
22
|
</div>
|
25
23
|
|
24
|
+
<div class="field">
|
25
|
+
<%= f.label :subject %><br />
|
26
|
+
<%= f.text_field :subject, :class => "text" %>
|
27
|
+
</div>
|
28
|
+
|
26
29
|
<div class="field">
|
27
30
|
<%= f.label :path, 'Template Path' %><br />
|
28
31
|
<%= f.text_field :path, :class => "text" %>
|
@@ -37,5 +40,6 @@
|
|
37
40
|
<%= f.submit "Duplicate", :class => "button" %>
|
38
41
|
</div>
|
39
42
|
<% end %>
|
43
|
+
|
40
44
|
</div>
|
41
45
|
</div>
|
@@ -1,12 +1,13 @@
|
|
1
1
|
<div class="post">
|
2
2
|
<div class="post-title"><h2><%= mail_template_list_title(params[:type]) %></h2></div>
|
3
3
|
<div class="post-body">
|
4
|
-
|
4
|
+
<%= show_no_record(@mail_templates) do %>
|
5
5
|
<table class="data-table">
|
6
6
|
<tr>
|
7
7
|
<th>Name</th>
|
8
8
|
<th>Template Path</th>
|
9
9
|
<% if params[:type] != 'partial' %>
|
10
|
+
<th>Subject</th>
|
10
11
|
<th>Layout</th>
|
11
12
|
<th>Partials</th>
|
12
13
|
<% end %>
|
@@ -18,33 +19,36 @@
|
|
18
19
|
<td><%= mail_template.name %></td>
|
19
20
|
<td><%= mail_template.path %></td>
|
20
21
|
<% if params[:type] != 'partial' %>
|
22
|
+
<td><%= mail_template.subject %></td>
|
21
23
|
<td><%= mail_template.layout %></td>
|
22
24
|
<td><%= mail_template.partials.map(&:name).join(" , ") %></td>
|
23
25
|
<% end %>
|
24
|
-
<td>
|
25
|
-
<table style="margin-bottom: 0px">
|
26
|
+
<td style="width: 200px;">
|
27
|
+
<table style="margin-bottom: 0px;">
|
26
28
|
<% mail_template.variations.group_by(&:locale).each do |locale, templates| %>
|
27
29
|
<tr>
|
28
|
-
<td colspan="
|
30
|
+
<td colspan="2" style="background-color: grey; font-weight: bold; color: white; padding: 2px 5px"><%= locale.humanize %></td>
|
29
31
|
</tr>
|
30
32
|
<% templates.each do |template| %>
|
31
|
-
|
32
|
-
<
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
33
|
+
<% if template.persisted? %>
|
34
|
+
<tr>
|
35
|
+
<td><%= template.locale %>.<%= template.format %></td>
|
36
|
+
<td>
|
37
|
+
<%= link_to image_tag('mail_engine/icons/show.png', :alt => "Show"), mail_template_path(template) %>
|
38
|
+
<%= link_to image_tag('mail_engine/icons/edit.gif', :alt => "Edit"), edit_mail_template_path(template) %>
|
39
|
+
<%= link_to image_tag('mail_engine/icons/delete.png', :alt => "Delete"), mail_template_path(template, :type => params[:type]), :confirm => 'Are you sure?', :method => :delete %>
|
40
|
+
<%= link_to image_tag('mail_engine/icons/copy.png', :alt => "Copy"), duplicate_mail_template_path(template, :type => params[:type]), :class => "fancybox iframe" %>
|
41
|
+
</td>
|
42
|
+
</tr>
|
43
|
+
<% else %>
|
44
|
+
<tr>
|
45
|
+
<td class='quiet' colspan='2'>
|
46
|
+
<%= image_tag('mail_engine/icons/missing.png', :alt => "Missing", :class=>"left", :style => "margin-bottom: 0px") %>
|
47
|
+
Missing: <%= template.locale %>.<%= template.format %>
|
48
|
+
</td>
|
49
|
+
<%#= link_to image_tag('mail_engine/icons/add.png', :alt => "Add"), new_mail_template_path(:type => params[:type]) %>
|
50
|
+
</tr>
|
46
51
|
<% end %>
|
47
|
-
</tr>
|
48
52
|
<% end %>
|
49
53
|
<% end %>
|
50
54
|
</table>
|
@@ -54,7 +58,7 @@
|
|
54
58
|
</table>
|
55
59
|
|
56
60
|
<div class="left">
|
57
|
-
<%=
|
61
|
+
<%= paginate @mail_templates %>
|
58
62
|
</div>
|
59
63
|
<% end %>
|
60
64
|
|
@@ -7,7 +7,7 @@
|
|
7
7
|
<div class="post-body">
|
8
8
|
<%= form_for(@mail_template, :url => create_by_upload_mail_templates_path, :html => {:multipart => true}) do |f| %>
|
9
9
|
<% if @mail_template.errors.any? %>
|
10
|
-
<
|
10
|
+
<p id="error_explanation">
|
11
11
|
<h2><%= pluralize(@mail_template.errors.count, "error") %> prohibited this mail_template from being saved:</h2>
|
12
12
|
|
13
13
|
<ul>
|
@@ -15,28 +15,36 @@
|
|
15
15
|
<li><%= msg %></li>
|
16
16
|
<% end %>
|
17
17
|
</ul>
|
18
|
-
</
|
18
|
+
</p>
|
19
19
|
<% end %>
|
20
20
|
|
21
21
|
<div class="field">
|
22
22
|
<%= f.label :name %><br />
|
23
23
|
<%= f.text_field :name, :class => "text" %>
|
24
24
|
</div>
|
25
|
+
|
26
|
+
<div class="field">
|
27
|
+
<%= f.label :subject %><br />
|
28
|
+
<%= f.text_field :subject, :class => "text" %>
|
29
|
+
</div>
|
30
|
+
|
25
31
|
<div class="field">
|
26
32
|
<%= f.label :path, 'Template Path' %><br />
|
27
33
|
<%= f.text_field :path, :class => "text" %>
|
28
34
|
</div>
|
35
|
+
|
29
36
|
<div class="field">
|
30
37
|
<%= f.label :locale %><br />
|
31
38
|
<%= f.select :locale, I18n.available_locales.map(&:to_s) %>
|
32
39
|
</div>
|
40
|
+
|
33
41
|
<div class="field">
|
34
42
|
<label>Zip File</label><br />
|
35
43
|
<% if @mail_template.zip_file.present? %>
|
36
44
|
<div class="loud">Do you to change this uploaded file: <b><%= link_to File.basename(@mail_template.zip_file_url), @mail_template.zip_file_url %></b> ?</div>
|
37
45
|
<% end %>
|
38
46
|
|
39
|
-
<%= f.file_field :zip_file, :style => 'padding: 10px;' %>
|
47
|
+
<%= f.file_field :zip_file, :style => 'padding: 10px;', :class => "text" %>
|
40
48
|
<%= f.hidden_field :zip_file_cache %>
|
41
49
|
|
42
50
|
<h5>Note:</h5>
|
@@ -45,8 +53,6 @@
|
|
45
53
|
<li>Only one html file.</li>
|
46
54
|
<li>File should less than 1MB.</li>
|
47
55
|
</ol>
|
48
|
-
|
49
|
-
|
50
56
|
</div>
|
51
57
|
|
52
58
|
<%= f.hidden_field :for_marketing, :value => (f.object.for_marketing || params[:type] == 'marketing') %>
|
@@ -1,9 +1,9 @@
|
|
1
1
|
<% @tmp_mail_template.template_partials.each do |template_partial| %>
|
2
2
|
<%= fields_for "mail_engine_mail_template[template_partials_attributes][#{template_partial.id || template_partial.object_id}]", template_partial do |partial_form| %>
|
3
|
-
<
|
3
|
+
<b>Choose partial for <%= partial_form.object.placeholder_name %>:</b>
|
4
4
|
|
5
5
|
<!-- list all partials -->
|
6
|
-
|
6
|
+
<%= show_no_record partials = MailEngine::MailTemplate.partial.where(:format => params[:template_format], :locale => params[:template_locale]) do %>
|
7
7
|
<ul class="partial_option_list">
|
8
8
|
<% partials.each do |partial| %>
|
9
9
|
<li>
|
@@ -10,7 +10,25 @@
|
|
10
10
|
<%= @mail_template.full_path %>
|
11
11
|
</td>
|
12
12
|
</tr>
|
13
|
+
<tr>
|
14
|
+
<td>Locale</td>
|
15
|
+
<td>
|
16
|
+
<%= @mail_template.locale %>
|
17
|
+
</td>
|
18
|
+
</tr>
|
19
|
+
<tr>
|
20
|
+
<td>Format</td>
|
21
|
+
<td>
|
22
|
+
<%= @mail_template.format %>
|
23
|
+
</td>
|
24
|
+
</tr>
|
13
25
|
<% unless @mail_template.partial? %>
|
26
|
+
<tr>
|
27
|
+
<td>Subject</td>
|
28
|
+
<td>
|
29
|
+
<%= @mail_template.subject %>
|
30
|
+
</td>
|
31
|
+
</tr>
|
14
32
|
<tr>
|
15
33
|
<td>Layout</td>
|
16
34
|
<td>
|
@@ -25,35 +43,7 @@
|
|
25
43
|
<iframe width="100%" class="bordered" src="<%= body_mail_template_path(@mail_template, :format => @mail_template.format) %>"></iframe>
|
26
44
|
</p>
|
27
45
|
|
28
|
-
|
29
|
-
<h4>Sending Logs</h4>
|
30
|
-
<% show_no_record(logs = @mail_template.logs) do %>
|
31
|
-
<table class="data-table">
|
32
|
-
<tr>
|
33
|
-
<th>Subject</th>
|
34
|
-
<th>Sender</th>
|
35
|
-
<th>Recipient</th>
|
36
|
-
<th>mime_type</th>
|
37
|
-
<th>Sent at</th>
|
38
|
-
<th></th>
|
39
|
-
</tr>
|
40
|
-
|
41
|
-
<% logs.each do |log| %>
|
42
|
-
<tr class="even">
|
43
|
-
<td><%= log.subject %></td>
|
44
|
-
<td><%= log.sender %></td>
|
45
|
-
<td><%= log.recipient %></td>
|
46
|
-
<td><%= log.mime_type %></td>
|
47
|
-
<td><%= log.created_at %></td>
|
48
|
-
<td>
|
49
|
-
<%= link_to 'Show', mail_log_path(log) %>
|
50
|
-
<%= link_to 'Destroy', mail_log_path(log), :confirm => 'Are you sure?', :method => :delete %>
|
51
|
-
</td>
|
52
|
-
</tr>
|
53
|
-
<% end %>
|
54
|
-
</table>
|
55
|
-
<% end %>
|
56
|
-
</p>
|
46
|
+
<%= render "mail_engine/mail_logs/related_logs", :logs => @mail_template.logs %>
|
57
47
|
</div>
|
58
48
|
<br />
|
59
49
|
<h2>
|
@@ -1,12 +1,12 @@
|
|
1
1
|
<h1><%= params[:type].titleize %></h1>
|
2
2
|
|
3
|
-
|
3
|
+
<%= show_no_record(@result) do %>
|
4
4
|
<table class="data-table">
|
5
5
|
<tr>
|
6
6
|
<th>Email</th>
|
7
7
|
<th>Status</th>
|
8
8
|
<th>Reason</th>
|
9
|
-
<th>Created At</th>
|
9
|
+
<th width="120">Created At</th>
|
10
10
|
</tr>
|
11
11
|
|
12
12
|
<% @result.each do |record| %>
|
@@ -1,12 +1,12 @@
|
|
1
1
|
<h1><%= params[:type].titleize %></h1>
|
2
2
|
|
3
|
-
|
3
|
+
<%= show_no_record(@result) do %>
|
4
4
|
<table class="data-table">
|
5
5
|
<tr>
|
6
6
|
<th>Email</th>
|
7
7
|
<th>Status</th>
|
8
8
|
<th>Reason</th>
|
9
|
-
<th>Created At</th>
|
9
|
+
<th width="120">Created At</th>
|
10
10
|
</tr>
|
11
11
|
|
12
12
|
<% @result.each do |record| %>
|
@@ -1,11 +1,11 @@
|
|
1
1
|
<h1><%= params[:type].titleize %></h1>
|
2
2
|
|
3
|
-
|
3
|
+
<%= show_no_record(@result) do %>
|
4
4
|
<table class="data-table">
|
5
5
|
<tr>
|
6
6
|
<th>Email</th>
|
7
7
|
<th>Reason</th>
|
8
|
-
<th>Created At</th>
|
8
|
+
<th width="120">Created At</th>
|
9
9
|
</tr>
|
10
10
|
|
11
11
|
<% @result.each do |record| %>
|
@@ -1,10 +1,10 @@
|
|
1
1
|
<h1><%= params[:type].titleize %></h1>
|
2
2
|
|
3
|
-
|
3
|
+
<%= show_no_record(@result) do %>
|
4
4
|
<table class="data-table">
|
5
5
|
<tr>
|
6
6
|
<th>Email</th>
|
7
|
-
<th>Created At</th>
|
7
|
+
<th width="120">Created At</th>
|
8
8
|
</tr>
|
9
9
|
|
10
10
|
<% @result.each do |record| %>
|
@@ -1,3 +1,6 @@
|
|
1
|
+
<!-- used for google chart -->
|
2
|
+
<script type='text/javascript' src='https://www.google.com/jsapi'></script>
|
3
|
+
|
1
4
|
<script type="text/javascript">
|
2
5
|
// show historical line chart
|
3
6
|
function drawLine() {
|
@@ -20,19 +23,51 @@
|
|
20
23
|
chart.draw(data, {width: 960, height: 300, title: 'History Reports', chartArea: {left:0,top:0,width:"80%",height:"90%"} });
|
21
24
|
}
|
22
25
|
|
26
|
+
// load google chart package.
|
23
27
|
var stats_data = <%= raw @stats_data.to_json %>;
|
24
28
|
google.load("visualization", "1", {packages:["corechart"]});
|
25
29
|
google.setOnLoadCallback(drawLine);
|
30
|
+
|
31
|
+
$(function(){
|
32
|
+
// add date picker
|
33
|
+
var dates = $("#report_from, #report_to").datepicker({
|
34
|
+
defaultDate: "0",
|
35
|
+
changeMonth: false,
|
36
|
+
numberOfMonths: 1,
|
37
|
+
dateFormat: "yy-mm-dd",
|
38
|
+
onSelect: function(selectedDate) {
|
39
|
+
var option = this.id == "report_from" ? "minDate" : "maxDate",
|
40
|
+
instance = $(this).data("datepicker"),
|
41
|
+
date = $.datepicker.parseDate(
|
42
|
+
instance.settings.dateFormat || $.datepicker._defaults.dateFormat,
|
43
|
+
selectedDate,
|
44
|
+
instance.settings
|
45
|
+
);
|
46
|
+
dates.not(this).datepicker("option", option, date);
|
47
|
+
}
|
48
|
+
});
|
49
|
+
});
|
26
50
|
</script>
|
27
51
|
|
28
52
|
<div class="historical-report left" style="margin-top: 10px">
|
29
|
-
<h2>History Report</h2>
|
30
|
-
|
53
|
+
<h2 class="left">History Report</h2>
|
54
|
+
<!-- data range select -->
|
31
55
|
|
32
|
-
<div
|
56
|
+
<div class="right" style="margin-right: 40px; margin-bottom: 50px">
|
57
|
+
<%= form_for :report, reports_path, :html => {:method => :get} do |f| %>
|
58
|
+
<%= f.label :from %>
|
59
|
+
<%= f.text_field :from, :class => "text", :value => params[:report].try(:[], :from) || 1.weeks.ago.to_date.to_s(:db) %>
|
33
60
|
|
34
|
-
|
35
|
-
|
61
|
+
<%= f.label :to %>
|
62
|
+
<%= f.text_field :to, :class => "text", :value => params[:report].try(:[], :to) || Time.now.to_date.to_s(:db) %>
|
63
|
+
<input type="submit" class="refresh_report_list button" value="Submit">
|
64
|
+
<% end %>
|
65
|
+
</div>
|
66
|
+
<div class="clearer"></div>
|
67
|
+
|
68
|
+
<div id='line_chart'></div>
|
69
|
+
<div class="history" style="margin-top: 50px;">
|
70
|
+
<table border="0" cellspacing="5" cellpadding="5" class="data-table" style="width: 95%;">
|
36
71
|
<tr>
|
37
72
|
<th>Date</th>
|
38
73
|
<th>Requests</th>
|
data/config/routes.rb
CHANGED
@@ -1,26 +1,24 @@
|
|
1
1
|
module MailEngine
|
2
2
|
Rails.application.routes.draw do
|
3
|
-
scope "
|
3
|
+
scope MailEngine::Base.current_config["mount_at"], :module => :mail_engine do
|
4
4
|
match '/', :controller => "dashboard", :action => "index", :as => :mail_engine_dashboard
|
5
5
|
|
6
6
|
resources :mail_templates do
|
7
7
|
member do
|
8
8
|
get :duplicate
|
9
9
|
put :duplicate
|
10
|
-
|
11
10
|
get :preview
|
12
11
|
post :preview
|
13
|
-
|
14
12
|
get :body
|
15
13
|
post :body
|
16
|
-
|
17
14
|
post :send_test_mail
|
18
15
|
end
|
19
16
|
|
20
17
|
collection do
|
21
|
-
# used before mail template
|
18
|
+
# used before mail template been saved
|
22
19
|
post :preview
|
23
20
|
|
21
|
+
get :get_existed_subject
|
24
22
|
get :new_by_upload
|
25
23
|
post :create_by_upload
|
26
24
|
post :partial_options
|
@@ -35,12 +33,13 @@ module MailEngine
|
|
35
33
|
end
|
36
34
|
end
|
37
35
|
|
38
|
-
resources :mail_logs
|
39
36
|
resources :reports do
|
40
37
|
collection do
|
41
38
|
get :chart
|
42
39
|
end
|
43
40
|
end
|
41
|
+
|
42
|
+
resources :mail_logs
|
44
43
|
end
|
45
44
|
|
46
45
|
# match ':controller(/:action(/:id(.:format)))', :controller => /admin\/[^\/]+/
|