From baa377581ed06c2fb44777c717ca9111b8a5d4c7 Mon Sep 17 00:00:00 2001 From: Andreas Granig Date: Tue, 2 Jul 2013 22:09:52 +0200 Subject: [PATCH] Some more layout cleanups. --- lib/NGCP/Panel/Field/Domain.pm | 4 ++-- lib/NGCP/Panel/Form/Domain.pm | 1 + lib/NGCP/Panel/Form/Subscriber.pm | 8 ++++---- share/layout/html.tt | 1 - share/static/css/main.css | 15 ++++++++++++++- share/static/css/ngcp.css | 9 --------- 6 files changed, 21 insertions(+), 17 deletions(-) delete mode 100644 share/static/css/ngcp.css diff --git a/lib/NGCP/Panel/Field/Domain.pm b/lib/NGCP/Panel/Field/Domain.pm index 6d81abbef2..8efb2e3696 100644 --- a/lib/NGCP/Panel/Field/Domain.pm +++ b/lib/NGCP/Panel/Field/Domain.pm @@ -10,8 +10,8 @@ has_field 'id' => ( required => 1, template => 'share/templates/helpers/datatables_field.tt', ajax_src => '/domain/ajax', - table_titles => ['#', 'Domain'], - table_fields => ['id', 'domain'], + table_titles => ['Domain'], + table_fields => ['domain'], ); has_field 'create' => ( diff --git a/lib/NGCP/Panel/Form/Domain.pm b/lib/NGCP/Panel/Form/Domain.pm index 965c3c1599..6fad07012a 100644 --- a/lib/NGCP/Panel/Form/Domain.pm +++ b/lib/NGCP/Panel/Form/Domain.pm @@ -17,6 +17,7 @@ has_field 'id' => ( has_field 'domain' => ( type => 'Text', required => 1, + label => 'SIP Domain', ); has_field 'save' => ( diff --git a/lib/NGCP/Panel/Form/Subscriber.pm b/lib/NGCP/Panel/Form/Subscriber.pm index cf5ab6e0ee..5a474d97d2 100644 --- a/lib/NGCP/Panel/Form/Subscriber.pm +++ b/lib/NGCP/Panel/Form/Subscriber.pm @@ -33,7 +33,7 @@ has_field 'e164' => ( has_field 'e164.cc' => ( type => 'PosInteger', label => 'cc:', - element_attr => { class => ['e164_cc'] }, + element_attr => { class => ['ngcp_e164_cc'] }, do_label => 0, do_wrapper => 0, ); @@ -41,7 +41,7 @@ has_field 'e164.cc' => ( has_field 'e164.ac' => ( type => 'PosInteger', label => 'ac:', - element_attr => { class => ['e164_ac'] }, + element_attr => { class => ['ngcp_e164_ac'] }, do_label => 0, do_wrapper => 0, ); @@ -49,7 +49,7 @@ has_field 'e164.ac' => ( has_field 'e164.sn' => ( type => 'PosInteger', label => 'sn:', - element_attr => { class => ['e164_sn'] }, + element_attr => { class => ['ngcp_e164_sn'] }, do_label => 0, do_wrapper => 0, ); @@ -94,7 +94,7 @@ has_field 'save' => ( has_block 'fields' => ( tag => 'div', class => [qw/modal-body/], - render_list => [qw/webusername webpassword e164 sipusername sipdomain sippassword administrative external_id/], + render_list => [qw/webusername webpassword e164 sipusername sipdomain sippassword external_id administrative/ ], ); has_block 'actions' => ( diff --git a/share/layout/html.tt b/share/layout/html.tt index fe54a14be5..9d1a47ad0c 100644 --- a/share/layout/html.tt +++ b/share/layout/html.tt @@ -22,7 +22,6 @@ - diff --git a/share/static/css/main.css b/share/static/css/main.css index cc99941a66..43077b8625 100644 --- a/share/static/css/main.css +++ b/share/static/css/main.css @@ -14,7 +14,7 @@ div.ngcp-modal { max-width: 816px; width: 100%; margin: -250px 0 0 -408px; - top: 50%; + /*top: 50%;*/ left: 50%; /* override responsive css (bootstrap-responsive.css) */ display: block; } @@ -191,3 +191,16 @@ div.ngcp-modal .control-group.error .dataTables_wrapper input[type="text"] { .ngcp-quickform div.form-actions { padding-left: 0px; } + +/* ------------- + Various form fields +----------------*/ +input.ngcp_e164_cc { + width: 4em; +} +input.ngcp_e164_ac { + width: 4em; +} +input.ngcp_e164_sn { + width: 15em; +} diff --git a/share/static/css/ngcp.css b/share/static/css/ngcp.css deleted file mode 100644 index 03c2111a0c..0000000000 --- a/share/static/css/ngcp.css +++ /dev/null @@ -1,9 +0,0 @@ -input.e164_cc { - width: 4em; -} -input.e164_ac { - width: 4em; -} -input.e164_sn { - width: 15em; -}