diff options
Diffstat (limited to 'app/views')
-rw-r--r-- | app/views/sip_accounts/_form_core.html.haml | 1 | ||||
-rw-r--r-- | app/views/sip_accounts/show.html.haml | 5 | ||||
-rw-r--r-- | app/views/voicemail_accounts/_form.html.haml | 7 | ||||
-rw-r--r-- | app/views/voicemail_accounts/_form_core.html.haml | 3 | ||||
-rw-r--r-- | app/views/voicemail_accounts/_index_core.html.haml | 15 | ||||
-rw-r--r-- | app/views/voicemail_accounts/edit.html.haml | 3 | ||||
-rw-r--r-- | app/views/voicemail_accounts/index.html.haml | 6 | ||||
-rw-r--r-- | app/views/voicemail_accounts/new.html.haml | 3 | ||||
-rw-r--r-- | app/views/voicemail_accounts/show.html.haml | 19 | ||||
-rw-r--r-- | app/views/voicemail_settings/_form.html.haml | 3 | ||||
-rw-r--r-- | app/views/voicemail_settings/_form_core.html.haml | 17 | ||||
-rw-r--r-- | app/views/voicemail_settings/_index_core.html.haml | 14 | ||||
-rw-r--r-- | app/views/voicemail_settings/edit.html.haml | 2 | ||||
-rw-r--r-- | app/views/voicemail_settings/index.html.haml | 6 | ||||
-rw-r--r-- | app/views/voicemail_settings/new.html.haml | 3 | ||||
-rw-r--r-- | app/views/voicemail_settings/show.html.haml | 33 |
16 files changed, 109 insertions, 31 deletions
diff --git a/app/views/sip_accounts/_form_core.html.haml b/app/views/sip_accounts/_form_core.html.haml index d7c65d0..2e4882e 100644 --- a/app/views/sip_accounts/_form_core.html.haml +++ b/app/views/sip_accounts/_form_core.html.haml @@ -14,3 +14,4 @@ = f.input :hotdeskable, :label => t('sip_accounts.form.hotdeskable.label'), :hint => conditional_hint('sip_accounts.form.hotdeskable.hint') = f.input :clip_no_screening, :label => t('sip_accounts.form.clip_no_screening.label'), :hint => conditional_hint('sip_accounts.form.clip_no_screening.hint') = f.input :language_code, :collection => Language.all.collect{|l| [l.to_s, l.code]}, :label => t('sip_accounts.form.language_code.label'), :hint => conditional_hint('sip_accounts.form.language_id.hint'), :include_blank => false + = f.input :voicemail_account_id, :collection => @possible_voicemail_accounts.collect{|l| [l.to_s, l.id]}, :label => t('sip_accounts.form.voicemail_account_id.label'), :hint => conditional_hint('voicemail_accounts.form.sip_account_id.hint'), :include_blank => true diff --git a/app/views/sip_accounts/show.html.haml b/app/views/sip_accounts/show.html.haml index e79907f..a7cd3ce 100644 --- a/app/views/sip_accounts/show.html.haml +++ b/app/views/sip_accounts/show.html.haml @@ -37,6 +37,11 @@ %strong= t('sip_accounts.show.hotdeskable') + ":" %td = @sip_account.hotdeskable == true ? t('simple_form.yes') : t('simple_form.no') + %tr + %td + %strong= t('sip_accounts.show.voicemail_account') + ":" + %td + = @sip_account.voicemail_account - if @sip_account.registration.try(:network_ip) && @sip_account.registration.try(:network_port) %tr diff --git a/app/views/voicemail_accounts/_form.html.haml b/app/views/voicemail_accounts/_form.html.haml new file mode 100644 index 0000000..1e5ffc0 --- /dev/null +++ b/app/views/voicemail_accounts/_form.html.haml @@ -0,0 +1,7 @@ += simple_form_for([@parent, @voicemail_account]) do |f| + = f.error_notification + + = render "form_core", :f => f + + .form-actions + = f.button :submit, conditional_t('voicemail_accounts.form.submit') diff --git a/app/views/voicemail_accounts/_form_core.html.haml b/app/views/voicemail_accounts/_form_core.html.haml new file mode 100644 index 0000000..a13ae51 --- /dev/null +++ b/app/views/voicemail_accounts/_form_core.html.haml @@ -0,0 +1,3 @@ +.inputs + = f.input :name, :label => t('voicemail_accounts.form.name.label'), :hint => conditional_hint('voicemail_accounts.form.name.hint') + = f.input :active, :label => t('voicemail_accounts.form.active.label'), :hint => conditional_hint('voicemail_accounts.form.active.hint') diff --git a/app/views/voicemail_accounts/_index_core.html.haml b/app/views/voicemail_accounts/_index_core.html.haml new file mode 100644 index 0000000..908c2b4 --- /dev/null +++ b/app/views/voicemail_accounts/_index_core.html.haml @@ -0,0 +1,15 @@ +%table.table.table-striped + %tr + %th + %th= t('voicemail_accounts.index.name') + + + - for voicemail_account in voicemail_accounts + %tr + %td + - if voicemail_account.active + %i.icon-ok + - else + %i.icon-ban-circle + %td= voicemail_account.name + =render :partial => 'shared/index_view_edit_destroy_part', :locals => {:parent => voicemail_account.voicemail_accountable, :child => voicemail_account}
\ No newline at end of file diff --git a/app/views/voicemail_accounts/edit.html.haml b/app/views/voicemail_accounts/edit.html.haml new file mode 100644 index 0000000..8d1518e --- /dev/null +++ b/app/views/voicemail_accounts/edit.html.haml @@ -0,0 +1,3 @@ +- content_for :title, t("voicemail_accounts.edit.page_title") + += render "form"
\ No newline at end of file diff --git a/app/views/voicemail_accounts/index.html.haml b/app/views/voicemail_accounts/index.html.haml new file mode 100644 index 0000000..2bc8ae4 --- /dev/null +++ b/app/views/voicemail_accounts/index.html.haml @@ -0,0 +1,6 @@ +- content_for :title, t("voicemail_accounts.index.page_title") + +- if @voicemail_accounts && @voicemail_accounts.count > 0 + = render "index_core", :voicemail_accounts => @voicemail_accounts + += render :partial => 'shared/create_link', :locals => {:parent => @parent, :child_class => VoicemailAccount}
\ No newline at end of file diff --git a/app/views/voicemail_accounts/new.html.haml b/app/views/voicemail_accounts/new.html.haml new file mode 100644 index 0000000..193779d --- /dev/null +++ b/app/views/voicemail_accounts/new.html.haml @@ -0,0 +1,3 @@ +- content_for :title, t("voicemail_accounts.new.page_title") + += render "form"
\ No newline at end of file diff --git a/app/views/voicemail_accounts/show.html.haml b/app/views/voicemail_accounts/show.html.haml new file mode 100644 index 0000000..06b4d1a --- /dev/null +++ b/app/views/voicemail_accounts/show.html.haml @@ -0,0 +1,19 @@ +- content_for :title, t("voicemail_accounts.show.page_title") + +%p + %strong= t('voicemail_accounts.show.uuid') + ":" + = @voicemail_account.uuid +%p + %strong= t('voicemail_accounts.show.name') + ":" + = @voicemail_account.name +%p + %strong= t('voicemail_accounts.show.active') + ":" + = @voicemail_account.active + += render :partial => 'shared/show_edit_destroy_part', :locals => { :parent => @parent, :child => @voicemail_account } + +%h3= t('voicemail_settings.index.page_title') +- if @voicemail_account.voicemail_settings.any? + = render "voicemail_settings/index_core", :voicemail_settings => @voicemail_account.voicemail_settings + %br += render :partial => 'shared/create_link', :locals => { :parent => @voicemail_account, :child_class => VoicemailSetting }
\ No newline at end of file diff --git a/app/views/voicemail_settings/_form.html.haml b/app/views/voicemail_settings/_form.html.haml index cd43b2d..08fc37b 100644 --- a/app/views/voicemail_settings/_form.html.haml +++ b/app/views/voicemail_settings/_form.html.haml @@ -1,4 +1,5 @@ -= simple_form_for([@sip_account,@voicemail_setting]) do |f| + += simple_form_for([@voicemail_account, @voicemail_setting]) do |f| = f.error_notification = render "form_core", :f => f diff --git a/app/views/voicemail_settings/_form_core.html.haml b/app/views/voicemail_settings/_form_core.html.haml index 08bdfc2..bf47e46 100644 --- a/app/views/voicemail_settings/_form_core.html.haml +++ b/app/views/voicemail_settings/_form_core.html.haml @@ -1,11 +1,10 @@ .inputs + - if !@no_edit or !@no_edit[:name] + = f.input :name, :collection => VoicemailSetting::VOICEMAIL_SETTINGS.keys.collect{|i, k| [t("voicemail_settings.settings.#{i}"), i]}, :label => t('voicemail_settings.form.name.label'), :hint => conditional_hint('voicemail_settings.form.name.hint'), :autofocus => true, :include_blank => false + = f.input :value, :label => t('voicemail_settings.form.value.label'), :hint => conditional_hint('voicemail_settings.form.value.hint') + - else + = f.input :value, :label => t("voicemail_settings.settings.#{@no_edit[:name][:name]}"), :hint => conditional_hint('voicemail_settings.form.value.hint'), :as => @no_edit[:name][:input] - = f.input :greeting_path, :as => :select, :label => t('voicemail_settings.form.greeting.label'), :hint => conditional_hint('voicemail_settings.form.greeting.hint'), :collection => @greeting_files - = f.input :name_path, :as => :select, :label => t('voicemail_settings.form.name.label'), :hint => conditional_hint('voicemail_settings.form.name.hint'), :collection => @name_files - - = f.input :password, :label => t('voicemail_settings.form.pin.label'), :hint => conditional_hint('voicemail_settings.form.pin.hint') - - = f.input :notify, :as => :boolean, :label => t('voicemail_settings.form.notify.label'), :hint => conditional_hint('voicemail_settings.form.notify.hint') - = f.input :attachment, :as => :boolean, :label => t('voicemail_settings.form.attachment.label'), :hint => conditional_hint('voicemail_settings.form.attachment.hint') - = f.input :mark_read, :as => :boolean, :label => t('voicemail_settings.form.mark_read.label'), :hint => conditional_hint('voicemail_settings.form.mark_read.hint') - = f.input :purge, :as => :boolean, :label => t('voicemail_settings.form.purge.label'), :hint => conditional_hint('voicemail_settings.form.purge.hint') + - if !@no_edit or !@no_edit[:description] + = f.input :description, :label => t('voicemail_settings.form.description.label'), :hint => conditional_hint('voicemail_settings.form.description.hint') + diff --git a/app/views/voicemail_settings/_index_core.html.haml b/app/views/voicemail_settings/_index_core.html.haml new file mode 100644 index 0000000..94ebfb1 --- /dev/null +++ b/app/views/voicemail_settings/_index_core.html.haml @@ -0,0 +1,14 @@ +%table.table.table-striped + %thead + %tr + %th= t('voicemail_settings.index.name') + %th= t('voicemail_settings.index.value') + %th= t('voicemail_settings.index.description') + + %tbody + - for voicemail_setting in voicemail_settings + %tr + %td= voicemail_setting.name + %td= voicemail_setting.value + %td= voicemail_setting.description + =render :partial => 'shared/index_view_edit_destroy_part', :locals => {:parent => voicemail_setting.voicemail_account, :child => voicemail_setting} diff --git a/app/views/voicemail_settings/edit.html.haml b/app/views/voicemail_settings/edit.html.haml index 56e5765..cb9924b 100644 --- a/app/views/voicemail_settings/edit.html.haml +++ b/app/views/voicemail_settings/edit.html.haml @@ -1,3 +1,3 @@ - content_for :title, t("voicemail_settings.edit.page_title") -= render "form" += render "form"
\ No newline at end of file diff --git a/app/views/voicemail_settings/index.html.haml b/app/views/voicemail_settings/index.html.haml new file mode 100644 index 0000000..5eb9940 --- /dev/null +++ b/app/views/voicemail_settings/index.html.haml @@ -0,0 +1,6 @@ +- content_for :title, t("voicemail_settings.index.page_title") + +- if @voicemail_settings && @voicemail_settings.count > 0 + = render "index_core", :voicemail_settings => @voicemail_settings + += render :partial => 'shared/create_link', :locals => {:parent => @voicemail_account, :child_class => VoicemailSetting} diff --git a/app/views/voicemail_settings/new.html.haml b/app/views/voicemail_settings/new.html.haml new file mode 100644 index 0000000..6eddc39 --- /dev/null +++ b/app/views/voicemail_settings/new.html.haml @@ -0,0 +1,3 @@ +- content_for :title, t("voicemail_settings.new.page_title") + += render "form"
\ No newline at end of file diff --git a/app/views/voicemail_settings/show.html.haml b/app/views/voicemail_settings/show.html.haml index e156d7b..f1a3e61 100644 --- a/app/views/voicemail_settings/show.html.haml +++ b/app/views/voicemail_settings/show.html.haml @@ -1,26 +1,19 @@ - content_for :title, t("voicemail_settings.show.page_title") %p - %strong= t('voicemail_settings.show.greeting_path') + ":" - = File.basename(@voicemail_setting.greeting_path.to_s) - + %strong= t('voicemail_settings.show.voicemail_id') + ":" + = @voicemail_setting.voicemail %p - %strong= t('voicemail_settings.show.name_path') + ":" - = File.basename(@voicemail_setting.name_path.to_s) - + %strong= t('voicemail_settings.show.name') + ":" + = @voicemail_setting.name +%p + %strong= t('voicemail_settings.show.value') + ":" + = @voicemail_setting.value +%p + %strong= t('voicemail_settings.show.class_type') + ":" + = @voicemail_setting.class_type %p - %strong= t('voicemail_settings.show.flags') + ":" - - if @voicemail_setting.notify - %br - = "- " + t('voicemail_settings.show.notify') - - if @voicemail_setting.attachment - %br - = "- " + t('voicemail_settings.show.attachment') - - if @voicemail_setting.mark_read - %br - = "- " + t('voicemail_settings.show.mark_read') - - if @voicemail_setting.purge - %br - = "- " + t('voicemail_settings.show.purge') + %strong= t('voicemail_settings.show.description') + ":" + = @voicemail_setting.description -= link_to t('voicemail_settings.actions.edit'), edit_sip_account_voicemail_setting_path(@sip_account, @voicemail_setting) += render :partial => 'shared/show_edit_destroy_part', :locals => {:parent => @voicemail_setting.voicemail_account, :child => @voicemail_setting}
\ No newline at end of file |