From 7d37b4c46d373b956c6c7994dab4fc5a86e73aec Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Tue, 5 Mar 2019 13:04:54 +0100 Subject: [PATCH] CSS --- htdocs/core/tpl/resource_view.tpl.php | 58 ++++++++++++--------------- htdocs/theme/eldy/style.css.php | 24 ++++++----- htdocs/theme/md/style.css.php | 30 +++++++++++--- 3 files changed, 64 insertions(+), 48 deletions(-) diff --git a/htdocs/core/tpl/resource_view.tpl.php b/htdocs/core/tpl/resource_view.tpl.php index 673045afddc..76a565cf7d6 100644 --- a/htdocs/core/tpl/resource_view.tpl.php +++ b/htdocs/core/tpl/resource_view.tpl.php @@ -13,30 +13,23 @@ $form= new Form($db); print '
'; -if($mode == 'edit' ) -{ - print '
'; - print '
'.$langs->trans('Resource').'
'; - print '
'.$langs->trans('Type').'
'; - print '
'.$langs->trans('Busy').'
'; - print '
'.$langs->trans('Mandatory').'
'; - print '
'; - print '
'; -} -else -{ - print '
'; - print '
'.$langs->trans('Resource').'
'; - print '
'.$langs->trans('Type').'
'; - print '
'.$langs->trans('Busy').'
'; - print '
'.$langs->trans('Mandatory').'
'; - print '
'; - print '
'; -} +print '
'; + +print '
'; +print '
'.$langs->trans('Resource').'
'; +print '
'.$langs->trans('Type').'
'; +print '
'.$langs->trans('Busy').'
'; +print '
'.$langs->trans('Mandatory').'
'; +print '
'; +print '
'; + +print ''; +print ''; +print ''; +print ''; if( (array) $linked_resources && count($linked_resources) > 0) { - foreach ($linked_resources as $linked_resource) { @@ -46,20 +39,17 @@ if( (array) $linked_resources && count($linked_resources) > 0) if ($mode == 'edit' && $linked_resource['rowid'] == GETPOST('lineid')) { - - print ''; - print ''; - print ''; - print ''; - print ''; - print ''; + print '
'; + print ''; + print ''; + print ''; print '
'.$object_resource->getNomUrl(1).'
'; print '
'.$object_resource->type_label.'
'; print '
'.$form->selectyesno('busy', $linked_resource['busy']?1:0, 1).'
'; print '
'.$form->selectyesno('mandatory', $linked_resource['mandatory']?1:0, 1).'
'; print '
'; - print ''; + print '
'; } else { @@ -67,7 +57,7 @@ if( (array) $linked_resources && count($linked_resources) > 0) if ($linked_resource['rowid'] == GETPOST('lineid')) $style='style="background: orange;"'; - print '
'; + print '
'; print '
'; print $object_resource->getNomUrl(1); @@ -95,20 +85,22 @@ if( (array) $linked_resources && count($linked_resources) > 0) print ''; print '
'; - print ''; + print '
'; } } } else { - print '
'; + print '
'; print '
'.$langs->trans('NoResourceLinked').'
'; print '
'; print '
'; print '
'; print '
'; - print ''; + print '
'; } +print ''; + print '
'; ?> diff --git a/htdocs/theme/eldy/style.css.php b/htdocs/theme/eldy/style.css.php index db4b494179d..3772cb9d86b 100644 --- a/htdocs/theme/eldy/style.css.php +++ b/htdocs/theme/eldy/style.css.php @@ -3037,7 +3037,7 @@ div.pagination li.paginationafterarrows { box-shadow: unset; -webkit-box-shadow: unset; } -.oddeven, .evenodd, .impair, .nohover .impair:hover, tr.impair td.nohover +.oddeven, .evenodd, .impair, .nohover .impair:hover, tr.impair td.nohover, .tagtr.oddeven { font-family: ; margin-bottom: 1px; @@ -3051,7 +3051,7 @@ div.pagination li.paginationafterarrows { background-color: #; } -.oddeven, .evenodd, .pair, .nohover .pair:hover, tr.pair td.nohover { +.oddeven, .evenodd, .pair, .nohover .pair:hover, tr.pair td.nohover, .tagtr.oddeven { font-family: ; margin-bottom: 1px; color: #202020; @@ -3117,7 +3117,7 @@ div.liste_titre_bydiv { /*width: calc(100% - 1px); 1px more, i don't know why so i remove */ width: calc(100%); } -tr.liste_titre, tr.liste_titre_sel, form.liste_titre, form.liste_titre_sel, table.dataTable.tr +tr.liste_titre, tr.liste_titre_sel, form.liste_titre, form.liste_titre_sel, table.dataTable.tr, tagtr.liste_titre { height: 26px !important; } @@ -3128,11 +3128,10 @@ div.colorback /* for the form "assign user" on time spent view */ margin-top: 5px; border: 1px solid #ddd; } -div.liste_titre_bydiv, .liste_titre div.tagtr, tr.liste_titre, tr.liste_titre_sel, form.liste_titre, form.liste_titre_sel, table.dataTable thead tr +div.liste_titre_bydiv, .liste_titre div.tagtr, tr.liste_titre, tr.liste_titre_sel, .tagtr.liste_titre, .tagtr.liste_titre_sel, form.liste_titre, form.liste_titre_sel, table.dataTable thead tr { background: rgb(); font-weight: ; -/* border-bottom: 1px solid #ddd; */ color: rgb(); font-family: ; @@ -3257,19 +3256,24 @@ div.tabBar .noborder { /* Prepare to remove class pair - impair */ .noborder > tbody > tr:nth-child(even):not(.liste_titre), .liste > tbody > tr:nth-child(even):not(.liste_titre), -div:not(.fichecenter):not(.fichehalfleft):not(.ficheaddleft) > .border > tbody > tr:nth-of-type(even):not(.liste_titre), .liste > tbody > tr:nth-of-type(even):not(.liste_titre) { +div:not(.fichecenter):not(.fichehalfleft):not(.ficheaddleft) > .border > tbody > tr:nth-of-type(even):not(.liste_titre), .liste > tbody > tr:nth-of-type(even):not(.liste_titre), +div:not(.fichecenter):not(.fichehalfleft):not(.ficheaddleft) .oddeven.tagtr:nth-of-type(even):not(.liste_titre) +{ background: linear-gradient(bottom, rgb() 85%, rgb() 100%); background: -o-linear-gradient(bottom, rgb() 85%, rgb() 100%); background: -moz-linear-gradient(bottom, rgb() 85%, rgb() 100%); background: -webkit-linear-gradient(bottom, rgb() 85%, rgb() 100%); background: -ms-linear-gradient(bottom, rgb() 85%, rgb() 100%); } -.noborder > tbody > tr:nth-child(even):not(:last-child) td:not(.liste_titre), .liste > tbody > tr:nth-child(even):not(:last-child) td:not(.liste_titre) { +.noborder > tbody > tr:nth-child(even):not(:last-child) td:not(.liste_titre), .liste > tbody > tr:nth-child(even):not(:last-child) td:not(.liste_titre), +.noborder .oddeven.tagtr:nth-child(even):not(:last-child) .tagtd:not(.liste_titre) +{ border-bottom: 1px solid #ddd; } .noborder > tbody > tr:nth-child(odd):not(.liste_titre), .liste > tbody > tr:nth-child(odd):not(.liste_titre), -div:not(.fichecenter):not(.fichehalfleft):not(.ficheaddleft) > .border > tbody > tr:nth-of-type(odd):not(.liste_titre), .liste > tbody > tr:nth-of-type(odd):not(.liste_titre) +div:not(.fichecenter):not(.fichehalfleft):not(.ficheaddleft) > .border > tbody > tr:nth-of-type(odd):not(.liste_titre), .liste > tbody > tr:nth-of-type(odd):not(.liste_titre), +div:not(.fichecenter):not(.fichehalfleft):not(.ficheaddleft) .oddeven.tagtr:nth-of-type(odd):not(.liste_titre) { background: linear-gradient(bottom, rgb() 85%, rgb() 100%); background: -o-linear-gradient(bottom, rgb() 85%, rgb() 100%); @@ -3277,7 +3281,9 @@ div:not(.fichecenter):not(.fichehalfleft):not(.ficheaddleft) > .border > tbody > background: -webkit-linear-gradient(bottom, rgb() 85%, rgb() 100%); background: -ms-linear-gradient(bottom, rgb() 85%, rgb() 100%); } -.noborder > tbody > tr:nth-child(odd):not(:last-child) td:not(.liste_titre), .liste > tbody > tr:nth-child(odd):not(:last-child) td:not(.liste_titre) { +.noborder > tbody > tr:nth-child(odd):not(:last-child) td:not(.liste_titre), .liste > tbody > tr:nth-child(odd):not(:last-child) td:not(.liste_titre), +.noborder .oddeven.tagtr:nth-child(odd):not(:last-child) .tagtd:not(.liste_titre) +{ border-bottom: 1px solid #ddd; } diff --git a/htdocs/theme/md/style.css.php b/htdocs/theme/md/style.css.php index 85918a43245..b54006f3e6c 100644 --- a/htdocs/theme/md/style.css.php +++ b/htdocs/theme/md/style.css.php @@ -2765,6 +2765,10 @@ table.liste th, table.noborder th, table.noborder tr.liste_titre td { table.noborder td, div.noborder form, div.noborder form div, table.tableforservicepart1 td, table.tableforservicepart2 td { padding: 4px 6px 4px 6px; /* t r b l */ } +form.tagtable { + padding: unset !important; + border: unset !important; +} table.liste td, table.noborder td, div.noborder form div { padding: 8px 6px 8px 6px; /* t r b l */ @@ -3079,11 +3083,11 @@ div.liste_titre_bydiv { padding: 2px 0px 2px 0; width: calc(100% - 1px); } -tr.liste_titre, tr.liste_titre_sel, form.liste_titre, form.liste_titre_sel, table.dataTable.tr +tr.liste_titre, tr.liste_titre_sel, form.liste_titre, form.liste_titre_sel, table.dataTable.tr, tagtr.liste_titre { height: 26px !important; } -div.liste_titre_bydiv, .liste_titre div.tagtr, tr.liste_titre, tr.liste_titre_sel, form.liste_titre, form.liste_titre_sel, table.dataTable thead tr +div.liste_titre_bydiv, .liste_titre div.tagtr, tr.liste_titre, tr.liste_titre_sel, .tagtr.liste_titre, .tagtr.liste_titre_sel, form.liste_titre, form.liste_titre_sel, table.dataTable thead tr { background: rgb(); font-weight: ; @@ -3211,28 +3215,42 @@ div .tdtop { /* Prepare to remove class pair - impair */ -.noborder > tbody > tr:nth-child(even):not(.liste_titre), .liste > tbody > tr:nth-child(even):not(.liste_titre) { +.noborder > tbody > tr:nth-child(even):not(.liste_titre), .liste > tbody > tr:nth-child(even):not(.liste_titre), +div:not(.fichecenter):not(.fichehalfleft):not(.ficheaddleft) > .border > tbody > tr:nth-of-type(even):not(.liste_titre), .liste > tbody > tr:nth-of-type(even):not(.liste_titre), +div:not(.fichecenter):not(.fichehalfleft):not(.ficheaddleft) .oddeven.tagtr:nth-of-type(even):not(.liste_titre) +{ background: linear-gradient(to bottom, rgb() 85%, rgb() 100%); background: -o-linear-gradient(bottom, rgb() 85%, rgb() 100%); background: -moz-linear-gradient(bottom, rgb() 85%, rgb() 100%); background: -webkit-linear-gradient(bottom, rgb() 85%, rgb() 100%); background: -ms-linear-gradient(bottom, rgb() 85%, rgb() 100%); } -.noborder > tbody > tr:nth-child(even):not(:last-child) td:not(.liste_titre), .liste > tbody > tr:nth-child(even):not(:last-child) td:not(.liste_titre) { +.noborder > tbody > tr:nth-child(even):not(:last-child) td:not(.liste_titre), .liste > tbody > tr:nth-child(even):not(:last-child) td:not(.liste_titre), +.noborder .tagtr:nth-child(even):not(:last-child) .oddeven.tagtd:not(.liste_titre) +{ border-bottom: 1px solid #ddd; } -.noborder > tbody > tr:nth-child(odd):not(.liste_titre), .liste > tbody > tr:nth-child(odd):not(.liste_titre) { +.noborder > tbody > tr:nth-child(odd):not(.liste_titre), .liste > tbody > tr:nth-child(odd):not(.liste_titre), +div:not(.fichecenter):not(.fichehalfleft):not(.ficheaddleft) > .border > tbody > tr:nth-of-type(odd):not(.liste_titre), .liste > tbody > tr:nth-of-type(odd):not(.liste_titre), +div:not(.fichecenter):not(.fichehalfleft):not(.ficheaddleft) .oddeven.tagtr:nth-of-type(odd):not(.liste_titre) +{ background: linear-gradient(to bottom, rgb() 85%, rgb() 100%); background: -o-linear-gradient(bottom, rgb() 85%, rgb() 100%); background: -moz-linear-gradient(bottom, rgb() 85%, rgb() 100%); background: -webkit-linear-gradient(bottom, rgb() 85%, rgb() 100%); background: -ms-linear-gradient(bottom, rgb() 85%, rgb() 100%); } -.noborder > tbody > tr:nth-child(odd):not(:last-child) td:not(.liste_titre), .liste > tbody > tr:nth-child(odd):not(:last-child) td:not(.liste_titre) { +.noborder > tbody > tr:nth-child(odd):not(:last-child) td:not(.liste_titre), .liste > tbody > tr:nth-child(odd):not(:last-child) td:not(.liste_titre), +.noborder .tagtr:nth-child(odd):not(:last-child) .oddeven.tagtd:not(.liste_titre) +{ border-bottom: 1px solid #ddd; } +ul.noborder li:nth-child(even):not(.liste_titre) { + background-color: rgb() !important; +} + /* * Boxes