Debug responsive of v7

This commit is contained in:
Laurent Destailleur 2017-11-24 14:23:25 +01:00
parent 8450c78dff
commit 3db52b5f9e
8 changed files with 90 additions and 43 deletions

View File

@ -41,10 +41,7 @@ require_once DOL_DOCUMENT_ROOT.'/fourn/class/fournisseur.facture.class.php';
require_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php';
require_once DOL_DOCUMENT_ROOT.'/core/lib/functions.lib.php';
$langs->load("banks");
$langs->load("categories");
$langs->load("companies");
$langs->load("bills");
$langs->loadLangs(array("banks","categories","companies","bills","trips"));
$action=GETPOST('action', 'alpha');
$id=GETPOST('account','int');
@ -705,7 +702,7 @@ else
$newline=0;
}
elseif ($links[$key]['type']=='user') {
print '<a href="'.DOL_URL_ROOT.'/user/card.php?rowid='.$links[$key]['url_id'].'">';
print '<a href="'.DOL_URL_ROOT.'/user/card.php?id='.$links[$key]['url_id'].'">';
print img_object($langs->trans('ShowUser'),'user').' ';
print $links[$key]['label'];
print '</a>';

View File

@ -3791,7 +3791,7 @@ else if ($id > 0 || ! empty($ref))
// List of payments already done
print '<div class="div-table-responsive-no-min">';
print '<table class="noborder paymenttable" width="100%">';
print '<tr class="liste_titre">';
@ -4002,6 +4002,7 @@ else if ($id > 0 || ! empty($ref))
}
print '</table>';
print '</div>';
// Margin Infos
if (! empty($conf->margin->enabled)) {

View File

@ -591,7 +591,9 @@ if ($object->id > 0)
/*
* Withdrawals
*/
*/
print '<div class="div-table-responsive-no-min">';
print '<table class="noborder" width="100%">';
print '<tr class="liste_titre">';
@ -664,7 +666,6 @@ if ($object->id > 0)
{
$obj = $db->fetch_object($result);
print '<tr class="oddeven">';
print '<td align="left">'.dol_print_date($db->jdate($obj->date_demande),'day')."</td>\n";
@ -689,7 +690,8 @@ if ($object->id > 0)
print "</tr>\n";
$i++;
}
if (! $num)
print '<tr class="oddeven"><td colspan="7" class="opacitymedium">'.$langs->trans("None").'</td></tr>';
$db->free($result);
}
else
@ -698,6 +700,7 @@ if ($object->id > 0)
}
print "</table>";
print '</div>';
}

View File

@ -1067,22 +1067,25 @@ if (empty($conf->global->MAIN_DISABLE_JQUERY_JNOTIFY) && ! defined('DISABLE_JQUE
?>
// Defined properties for JNotify
$(document).ready(function() {
$.jnotify.setup({
delay: 3000 // the default time to show each notification (in milliseconds)
, sticky: false // determines if the message should be considered "sticky" (user must manually close notification)
, closeLabel: "&times;" // the HTML to use for the "Close" link
, showClose: true // determines if the "Close" link should be shown if notification is also sticky
, fadeSpeed: 1000 // the speed to fade messages out (in milliseconds)
, slideSpeed: 250 // the speed used to slide messages out (in milliseconds)
, classContainer: "jnotify-container"
, classNotification: "jnotify-notification"
, classBackground: "jnotify-background"
, classClose: "jnotify-close"
, classMessage: "jnotify-message"
, init: null // callback that occurs when the main jnotify container is created
, create: null // callback that occurs when when the note is created (occurs just before appearing in DOM)
, beforeRemove: null // callback that occurs when before the notification starts to fade away
});
if (typeof $.jnotify == 'function')
{
$.jnotify.setup({
delay: 3000 // the default time to show each notification (in milliseconds)
, sticky: false // determines if the message should be considered "sticky" (user must manually close notification)
, closeLabel: "&times;" // the HTML to use for the "Close" link
, showClose: true // determines if the "Close" link should be shown if notification is also sticky
, fadeSpeed: 1000 // the speed to fade messages out (in milliseconds)
, slideSpeed: 250 // the speed used to slide messages out (in milliseconds)
, classContainer: "jnotify-container"
, classNotification: "jnotify-notification"
, classBackground: "jnotify-background"
, classClose: "jnotify-close"
, classMessage: "jnotify-message"
, init: null // callback that occurs when the main jnotify container is created
, create: null // callback that occurs when when the note is created (occurs just before appearing in DOM)
, beforeRemove: null // callback that occurs when before the notification starts to fade away
});
}
});
<?php } ?>

View File

@ -1119,7 +1119,7 @@ function dol_get_fiche_head($links=array(), $active='', $title='', $notab=0, $pi
if (count($keys)) $maxkey=max($keys);
}
//$conf->global->MAIN_MAXTABS_IN_CARD=3;
if (! empty($conf->dol_optimize_smallscreen)) $conf->global->MAIN_MAXTABS_IN_CARD=2;
// Show tabs
$bactive=false;
@ -1132,9 +1132,8 @@ function dol_get_fiche_head($links=array(), $active='', $title='', $notab=0, $pi
{
if ((is_numeric($active) && $i == $active) || (! empty($links[$i][2]) && ! is_numeric($active) && $active == $links[$i][2]))
{
// si l'active est présent dans la box
if ($i >= $limittoshow)
$limittoshow--;
// If active tab is already present
if ($i >= $limittoshow) $limittoshow--;
}
}
@ -1146,7 +1145,9 @@ function dol_get_fiche_head($links=array(), $active='', $title='', $notab=0, $pi
$bactive=true;
}
else
{
$isactive=false;
}
if ($i < $limittoshow || $isactive)
{
@ -1155,11 +1156,11 @@ function dol_get_fiche_head($links=array(), $active='', $title='', $notab=0, $pi
{
if (!empty($links[$i][0]))
{
$out.='<a data-role="button" class="tabimage" href="'.$links[$i][0].'">'.$links[$i][1].'</a>'."\n";
$out.='<a class="tabimage" href="'.$links[$i][0].'">'.$links[$i][1].'</a>'."\n";
}
else
{
$out.='<span data-role="button" class="tabspan">'.$links[$i][1].'</span>'."\n";
$out.='<span class="tabspan">'.$links[$i][1].'</span>'."\n";
}
}
else if (! empty($links[$i][1]))
@ -1167,11 +1168,15 @@ function dol_get_fiche_head($links=array(), $active='', $title='', $notab=0, $pi
//print "x $i $active ".$links[$i][2]." z";
if ($isactive)
{
$out.='<a data-role="button"'.(! empty($links[$i][2])?' id="'.$links[$i][2].'"':'').' class="tabactive tab inline-block" href="'.$links[$i][0].'">'.$links[$i][1].'</a>'."\n";
$out.='<a'.(! empty($links[$i][2])?' id="'.$links[$i][2].'"':'').' class="tabactive tab inline-block" href="'.$links[$i][0].'">';
$out.=$links[$i][1];
$out.='</a>'."\n";
}
else
{
$out.='<a data-role="button"'.(! empty($links[$i][2])?' id="'.$links[$i][2].'"':'').' class="tabunactive tab inline-block" href="'.$links[$i][0].'">'.$links[$i][1].'</a>'."\n";
$out.='<a'.(! empty($links[$i][2])?' id="'.$links[$i][2].'"':'').' class="tabunactive tab inline-block" href="'.$links[$i][0].'">';
$out.=$links[$i][1];
$out.='</a>'."\n";
}
}
$out.='</div>';
@ -1182,9 +1187,9 @@ function dol_get_fiche_head($links=array(), $active='', $title='', $notab=0, $pi
if (! $popuptab)
{
$popuptab=1;
$outmore.='<div class="popuptabset">';
$outmore.='<div class="popuptabset wordwrap">'; // The css used to hide/show popup
}
$outmore.='<div class="popuptab" style="display:inherit;">';
$outmore.='<div class="popuptab wordwrap" style="display:inherit;">';
if (isset($links[$i][2]) && $links[$i][2] == 'image')
{
if (!empty($links[$i][0]))
@ -1194,8 +1199,11 @@ function dol_get_fiche_head($links=array(), $active='', $title='', $notab=0, $pi
}
else if (! empty($links[$i][1]))
$outmore.='<a'.(! empty($links[$i][2])?' id="'.$links[$i][2].'"':'').' class="inline-block" href="'.$links[$i][0].'">'.$links[$i][1].'</a>'."\n";
{
$outmore.='<a'.(! empty($links[$i][2])?' id="'.$links[$i][2].'"':'').' class="wordwrap inline-block" href="'.$links[$i][0].'">';
$outmore.=preg_replace('/([a-z])\/([a-z])/i', '\\1 / \\2', $links[$i][1]); // Replace x/y with x / y to allow wrap on long composed texts.
$outmore.='</a>'."\n";
}
$outmore.='</div>';
$nbintab++;
@ -1206,15 +1214,21 @@ function dol_get_fiche_head($links=array(), $active='', $title='', $notab=0, $pi
if ($displaytab > $limittoshow)
{
$left=($langs->trans("DIRECTION") == 'rtl'?'right':'left');
$right=($langs->trans("DIRECTION") == 'rtl'?'left':'right');
$tabsname=str_replace("@", "", $picto);
$out.='<div id="moretabs'.$tabsname.'" class="inline-block tabsElem">';
$out.='<a href="#" data-role="button" class="tab moretab inline-block tabunactive">'.$langs->trans("More").'... ('.$nbintab.')</a>';
$out.='<div id="moretabsList'.$tabsname.'" style="position: absolute; left: -999em;text-align: left;margin:0px;padding:2px">'.$outmore.'</div>';
$out.='<a href="#" class="tab moretab inline-block tabunactive">'.$langs->trans("More").'... ('.$nbintab.')</a>';
$out.='<div id="moretabsList'.$tabsname.'" style="position: absolute; '.$left.': -999em; text-align: '.$left.'; margin:0px; padding:2px">';
$out.=$outmore;
$out.='</div>';
$out.='<div></div>';
$out.="</div>\n";
$out.="<script>";
$out.="$('#moretabs".$tabsname."').mouseenter( function() { $('#moretabsList".$tabsname."').css('left','auto');});";
$out.="$('#moretabs".$tabsname."').mouseleave( function() { $('#moretabsList".$tabsname."').css('left','-999em');});";
$out.="$('#moretabs".$tabsname."').mouseenter( function() { console.log('mouseenter ".$left."'); $('#moretabsList".$tabsname."').css('".$left."','auto');});";
$out.="$('#moretabs".$tabsname."').mouseleave( function() { console.log('mouseleave ".$left."'); $('#moretabsList".$tabsname."').css('".$left."','-999em');});";
$out.="</script>";
}

View File

@ -30,6 +30,7 @@ require_once DOL_DOCUMENT_ROOT.'/fourn/class/fournisseur.facture.class.php';
require_once DOL_DOCUMENT_ROOT.'/core/lib/fourn.lib.php';
require_once DOL_DOCUMENT_ROOT.'/core/lib/functions2.lib.php';
$langs->load('companies');
$langs->load('bills');
$id = GETPOST("facid",'int')?GETPOST("facid",'int'):GETPOST("id",'int');

View File

@ -456,6 +456,9 @@ fieldset { border: 1px solid #AAAAAA !important; }
.trextrafieldseparator td {
border-bottom: 2px solid rgb(120,120,120) !important;
}
input#onlinepaymenturl, input#directdownloadlink {
opacity: 0.7;
}
hr { border: 0; border-top: 1px solid #ccc; }
@ -581,6 +584,9 @@ textarea.centpercent {
.nowraponall {
white-space: nowrap;
}
.wordwrap {
word-wrap: break-word;
}
.nobold {
font-weight: normal !important;
}
@ -911,6 +917,9 @@ select.selectarrowonleft option {
body {
font-size: <?php print $fontsize+3; ?>px;
}
div.refidno {
font-size: <?php print $fontsize+3; ?>px !important;
}
}
/* Force values for small screen 570 */
@ -919,6 +928,9 @@ select.selectarrowonleft option {
body {
font-size: <?php print $fontsize+3; ?>px;
}
div.refidno {
font-size: <?php print $fontsize+3; ?>px !important;
}
.divmainbodylarge { margin-left: 20px !important; margin-right: 20px !important; }
@ -932,7 +944,8 @@ select.selectarrowonleft option {
margin-top: <?php print ($dol_hide_topmenu?'12':'6'); ?>px !important;
}
div.titre {
line-height: 2em;
margin-top: 12px;
/* line-height: 2em; */
}
.border tbody tr, .border tbody tr td, div.tabBar table.border tr, div.tabBar table.border tr td, div.tabBar div.border .table-border-row, div.tabBar div.border .table-key-border-col, div.tabBar div.border .table-val-border-col {
height: 40px !important;
@ -4080,6 +4093,7 @@ div#ecm-layout-center {
max-width: 1024px;
padding-left: 10px !important;
padding-right: 10px !important;
word-wrap: break-word;
}
.jnotify-container .jnotify-notification .jnotify-message {
font-weight: normal;
@ -4887,6 +4901,10 @@ div.tabsElem a.tab {
div.tmenuleft {
display: none;
}
.dropdown dd ul {
max-width: 300px;
}
}
/* rule to reduce top menu - 2nd reduction */
@media only screen and (max-width: <?php echo round($nbtopmenuentries * $fontsize * 5, 0) + 24; ?>px) /* reduction 2 */

View File

@ -589,6 +589,9 @@ textarea.centpercent {
.nowraponall {
white-space: nowrap;
}
.wordwrap {
word-wrap: break-word;
}
.nobold {
font-weight: normal !important;
}
@ -908,6 +911,9 @@ select.selectarrowonleft option {
body {
font-size: <?php print $fontsize+3; ?>px;
}
div.refidno {
font-size: <?php print $fontsize+3; ?>px !important;
}
}
/* Force values for small screen 570 */
@ -916,6 +922,9 @@ select.selectarrowonleft option {
body {
font-size: <?php print $fontsize+3; ?>px;
}
div.refidno {
font-size: <?php print $fontsize+3; ?>px !important;
}
.divmainbodylarge { margin-left: 20px; margin-right: 20px; }
@ -929,7 +938,8 @@ select.selectarrowonleft option {
margin-top: <?php print ($dol_hide_topmenu?'12':'6'); ?>px !important;
}
div.titre {
line-height: 2em;
margin-top: 12px;
/* line-height: 2em; */
}
.border tbody tr, .border tbody tr td, div.tabBar table.border tr {
height: 40px !important;