diff --git a/app/views/camps/_form.haml b/app/views/camps/_form.haml index 10cbc31d..f9a7ea53 100755 --- a/app/views/camps/_form.haml +++ b/app/views/camps/_form.haml @@ -138,6 +138,11 @@ = t("form_dream_name") = @camp.name + - if current_user && (current_user.guide || current_user.admin) + .combo + = form.label t("approve_dream") + = form.check_box :approved_status + .menu-heading %ul %li diff --git a/config/locales/en.yml b/config/locales/en.yml index e6af02b2..153bf379 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -97,6 +97,7 @@ en: form_dream_name_en_label: Dream name in English (required) form_dream_name_label: Dream name (required) form_dream_name_guidetext_html: What's your dream prototype called? + approve_dream: approve dream form_subtitle_en_label: Summarize your dream in English (required) form_subtitle_label: Summarize your dream (required) form_subtitle_guidetext_html: Brief summary of the dream prototype you are applying diff --git a/config/locales/he.yml b/config/locales/he.yml index d79912d1..b97c8de1 100755 --- a/config/locales/he.yml +++ b/config/locales/he.yml @@ -115,6 +115,7 @@ he: form_dream_id: "מספר החלום" form_dream_name_guidetext_html: "איך קוראים לחלום שלך?" form_dream_name_en_label: "שם החלום באנגלית (נדרש)" + approve_dream: אשר חלום form_subtitle_label: "סיכום החלום במשפט (נדרש)" form_subtitle_guidetext_html: "סיכום קצר של החלום שאת מציעה. סיכום זה יופיע בעמוד הראשי של האתר וגם בתוכנייה של מידברן (ולכן חשוב למלא במדויק). תעשי את זה קצר, עד 256 תווים." form_subtitle_en_label: "סיכום החלום במשפט באנגלית (נדרש)" diff --git a/db/migrate/20190218195040_add_approval_status_to_camp.rb b/db/migrate/20190218195040_add_approval_status_to_camp.rb new file mode 100644 index 00000000..b2471b32 --- /dev/null +++ b/db/migrate/20190218195040_add_approval_status_to_camp.rb @@ -0,0 +1,5 @@ +class AddApprovalStatusToCamp < ActiveRecord::Migration + def change + add_column :camps, :approved_status, :boolean, :default => false + end +end diff --git a/db/schema.rb b/db/schema.rb index 07976f22..e2654a8a 100644 --- a/db/schema.rb +++ b/db/schema.rb @@ -11,7 +11,7 @@ # # It's strongly recommended that you check this file into your version control system. -ActiveRecord::Schema.define(version: 20190121165734) do +ActiveRecord::Schema.define(version: 20190218195040) do create_table "active_admin_comments", force: :cascade do |t| t.string "namespace", :index=>{:name=>"index_active_admin_comments_on_namespace"} @@ -177,6 +177,7 @@ t.integer "camp_manager_id" t.integer "requested_funds" t.integer "requested_funds_fallback" + t.boolean "approved_status", :default=>false end create_table "grants", force: :cascade do |t|