dolibarr 19.0.3
info-box.inc.php
1<?php
2if (!defined('ISLOADEDBYSTEELSHEET')) {
3 die('Must be call by steelsheet');
4} ?>
5/* <style type="text/css" > */
6
7
8/*
9 * Component: Info Box
10 * -------------------
11 */
12
13<?php
14include_once DOL_DOCUMENT_ROOT.'/core/lib/functions2.lib.php';
15
16$prefix = '';
17if (getDolGlobalString('THEME_INFOBOX_COLOR_ON_BACKGROUND')) {
18 $prefix = 'background-';
19}
20
21if (!isset($conf->global->THEME_SATURATE_RATIO)) {
22 $conf->global->THEME_SATURATE_RATIO = 0.7;
23}
24if (GETPOSTISSET('THEME_SATURATE_RATIO')) {
25 $conf->global->THEME_SATURATE_RATIO = GETPOST('THEME_SATURATE_RATIO', 'int');
26}
27
28?>
29
30.customer-back {
31 background-color: #65953d !important;
32 color: #FFF !important;
33 padding: 2px;
34 margin: 2px;
35 border-radius: 3px;
36}
37.vendor-back {
38 background-color: #599caf !important;
39 color: #FFF !important;
40 padding: 2px;
41 margin: 2px;
42 border-radius: 3px;
43}
44.user-back {
45 background-color: #79633f !important;
46 color: #FFF !important;
47 padding: 2px;
48 margin: 2px;
49 border-radius: 3px;
50}
51.member-company-back {
52 padding: 2px 7px 2px 7px;
53 background-color: #e4e4e4;
54 color: #666;
55 border-radius: 10px;
56 white-space: nowrap;
57}
58.member-individual-back {
59 padding: 2px 7px 2px 7px;
60 background-color: #e4e4e4;
61 color: #666;
62 border-radius: 10px;
63 white-space: nowrap;
64}
65
66.bg-infobox-project{
67 <?php echo $prefix; ?>color: #6c6aa8 !important;
68}
69.bg-infobox-action{
70 <?php echo $prefix; ?>color: #a47080 !important;
71}
72.bg-infobox-propal, .bg-infobox-facture, .bg-infobox-commande {
73 <?php echo $prefix; ?>color: #65953d !important;
74}
75.bg-infobox-supplier_proposal, .bg-infobox-invoice_supplier, .bg-infobox-order_supplier {
76 <?php echo $prefix; ?>color: #599caf !important;
77}
78.bg-infobox-contrat, .bg-infobox-ticket{
79 <?php echo $prefix; ?>color: #46a676 !important;
80}
81.bg-infobox-bank_account{
82 <?php echo $prefix; ?>color: #b0a53e !important;
83}
84.bg-infobox-adherent, .bg-infobox-member{
85 <?php echo $prefix; ?>color: #79633f !important;
86}
87.bg-infobox-expensereport{
88 <?php echo $prefix; ?>color: #79633f !important;
89}
90.bg-infobox-holiday{
91 <?php echo $prefix; ?>color: #755114 !important;
92}
93
94
95.infobox-adherent, .infobox-member {
96 color: #79633f;
97}
98.infobox-project{
99 color: #6c6aa8;
100}
101.infobox-action{
102 color: #a47080;
103}
104/* Color for customer object */
105.infobox-propal:not(.pictotitle):not(.error),
106.infobox-facture:not(.pictotitle):not(.error),
107.infobox-commande:not(.pictotitle):not(.error) {
108 color: #65953d;
109}
110/* Color for vendor object */
111.infobox-supplier_proposal:not(.pictotitle):not(.error),
112.infobox-invoice_supplier:not(.pictotitle):not(.error),
113.infobox-order_supplier:not(.pictotitle):not(.error) {
114 color: #599caf;
115}
116
117.infobox-contrat, .infobox-ticket{
118 color: #46a676;
119}
120.infobox-bank_account{
121 color: #b0a53e;
122}
123.infobox-adherent, .infobox-member {
124 color: #79633f;
125}
126.infobox-expensereport{
127 color: #79633f;
128}
129.infobox-holiday{
130 color: #755114;
131}
132
133
134.info-box-module.--external span.info-box-icon-version {
135 background: #bbb;
136}
137
138a.info-box-text.info-box-text-a {
139 /* display: table-cell; */
140 display: contents;
141}
142a.info-box-text-a i.fa.fa-exclamation-triangle {
143 font-size: 0.9em;
144}
145
146.info-box {
147 display: block;
148 position: relative;
149 min-height: 90px;
150 background: var(--colorbacklineimpair2);
151 width: 100%;
152 /* box-shadow: 1px 1px 2px rgba(0, 0, 0, 0.1); */
153 border-radius: 2px;
154 margin-bottom: 15px;
155 border: 1px solid #e9e9e9;
156}
157.info-box.info-box-sm {
158 min-height: 80px;
159 margin-bottom: 10px;
160}
161.info-box-more {
162 float: right;
163 top: 4px;
164 position: absolute;
165 right: 10px;
166}
167
168.info-box small {
169 font-size: 14px;
170}
171.info-box:not(.info-box-kanban) .progress {
172 background: rgba(0, 0, 0, 0.2);
173 margin: 5px -10px 5px -10px;
174 height: 2px;
175}
176.info-box .progress,
177.info-box .progress .progress-bar {
178 border-radius: 0;
179}
180
181.info-box:not(.info-box-kanban) .progress .progress-bar {
182 float: left;
183 width: 0;
184 height: 100%;
185 font-size: 12px;
186 line-height: 20px;
187 color: #fff;
188 text-align: center;
189 background-color: #337ab7;
190 -webkit-box-shadow: inset 0 -1px 0 rgba(0,0,0,.15);
191 box-shadow: inset 0 -1px 0 rgba(0,0,0,.15);
192 -webkit-transition: width .6s ease;
193 -o-transition: width .6s ease;
194 transition: width .6s ease;
195}
196.info-box-icon {
197 display: block;
198 overflow: hidden;
199 float: left;
200 /* height: 90px; */
201 width: 86px;
202 text-align: center;
203 font-size: 45px;
204 line-height: 90px;
205 background: var(--colorbacktitle1) !important;
206 <?php if (isset($conf->global->THEME_SATURATE_RATIO)) { ?>
207 filter: saturate(<?php echo $conf->global->THEME_SATURATE_RATIO; ?>);
208 <?php } ?>
209}
210
211.info-box-module .info-box-icon {
212 padding-top: 4px;
213 padding-bottom: 4px;
214}
215.info-box-sm .info-box-icon, .info-box-sm .info-box-img {
216 height: 96px !important; /* must match height of info-box-sm .info-box-content */
217 width: 80px;
218 font-size: 25px;
219 line-height: 92px;
220}
221.info-box-order {
222 border-top-left-radius: 2px;
223 border-top-right-radius: 0;
224 border-bottom-right-radius: 0;
225 border-bottom-left-radius: 2px;
226 display: block;
227 overflow: hidden;
228 float: left;
229 height: 115px;
230 width: 88px;
231 text-align: center;
232 font-size: 2.3em;
233 line-height: 115px;
234 margin-right: 10px;
235 background: var(--colorbacktitle1) !important;
236}
237.opened-dash-board-wrap .info-box .info-box-icon {
238 font-size: 2em;
239}
240.opened-dash-board-wrap .info-box-sm .info-box-icon {
241 line-height: 80px;
242}
243.info-box-module .info-box-icon {
244 height: 98px;
245}
246.info-box-icon > img {
247 max-width: 85%;
248}
249.info-box-module .info-box-icon > img {
250 max-width: 55%;
251}
252
253.info-box-line {
254 line-height: 1.2em;
255}
256.info-box-line-text {
257 overflow: hidden;
258 width: calc(100% - 76px);
259 text-overflow: ellipsis;
260}
261
262.info-box-icon-text {
263 box-sizing: border-box;
264 display: block;
265 position: absolute;
266 width: 90px;
267 bottom: 0px;
268 color: #ffffff;
269 background-color: rgba(0,0,0,0.1);
270 cursor: default;
271
272 font-size: 10px;
273 line-height: 15px;
274 padding: 0px 3px;
275 text-align: center;
276 opacity: 0;
277 -webkit-transition: opacity 0.5s, visibility 0s 0.5s;
278 transition: opacity 0.5s, visibility 0s 0.5s;
279}
280
281.info-box-icon-version {
282 box-sizing: border-box;
283 display: block;
284 position: absolute;
285 width: 90px;
286 bottom: 0px;
287 color: #ffffff;
288 background-color: rgba(0,0,0,0.1);
289 cursor: default;
290
291 font-size: 10px;
292 line-height: 1.5em;
293 padding: 4px 3px;
294 text-align: center;
295 opacity: 1;
296 -webkit-transition: opacity 0.5s, visibility 0s 0.5s;
297 transition: opacity 0.5s, visibility 0s 0.5s;
298}
299
300.box-flex-item.info-box-module.--disabled {
301 /* opacity: 0.6; */
302}
303
304.info-box-actions {
305 position: absolute;
306 right: 0;
307 bottom: 0;
308}
309
310/* customize section img box on list of products */
311.info-box-img {
312 height: 105px !important;
313 width: 88px;
314 border-top-left-radius: 2px;
315 border-top-right-radius: 0;
316 border-bottom-right-radius: 0;
317 border-bottom-left-radius: 2px;
318 display: block;
319 overflow: hidden;
320 float: left;
321 text-align: center;
322 font-size: 2.8em;
323 line-height: 90px;
324 margin-right: 5px;
325 background: var(--colorbacktitle1) !important;
326}
327.info-box-img > img {
328 width: 90%;
329 position: relative;
330 top: 50%;
331 left: 50%;
332 transform: translate(-50%, -50%);
333}
334
335
336<?php if (!getDolGlobalString('MAIN_DISABLE_GLOBAL_BOXSTATS') && getDolGlobalString('MAIN_INCLUDE_GLOBAL_STATS_IN_OPENED_DASHBOARD')) { ?>
337.info-box-icon-text{
338 opacity: 1;
339}
340<?php } ?>
341
342.info-box-sm .info-box-icon-text, .info-box-sm .info-box-icon-version{
343 overflow: hidden;
344 width: 80px;
345}
346.info-box:hover .info-box-icon-text{
347 opacity: 1;
348}
349
350.info-box-content {
351 padding-top: 5px;
352 padding-bottom: 5px;
353 padding-left: 10px;
354 padding-right: 5px;
355 margin-left: 84px;
356}
357.info-box-sm .info-box-content {
358 margin-left: 80px;
359 height: 86px; /* 96 - margins of .info-box-sm .info-box-content */
360}
361.info-box-sm .info-box-module-enabled {
362 /* background: linear-gradient(0.35turn, #fff, #fff, #f6faf8, #e4efe8) */
363 background: var(--infoboxmoduleenabledbgcolor);
364}
365.info-box-content-warning span.font-status4 {
366 color: #bc9526 !important;
367}
368
369.info-box-number {
370 display: block;
371 font-weight: bold;
372 font-size: 18px;
373}
374.progress-description,
375.info-box-text,
376.info-box-title{
377 display: block;
378 font-size: 12px;
379 white-space: nowrap;
380 overflow: hidden;
381 text-overflow: ellipsis;
382}
383.info-box-title{
384 text-transform: uppercase;
385 font-weight: bold;
386 margin-bottom: 6px;
387}
388.info-box-title {
389 width: calc(100% - 20px);
390}
391.info-box-text{
392 font-size: 0.90em;
393}
394.info-box-text:first-letter{text-transform: uppercase}
395a.info-box-text{ text-decoration: none;}
396
397
398.info-box-more {
399 display: block;
400}
401.progress-description {
402 margin: 0;
403}
404
405
406
407/* ICONS INFO BOX */
408<?php
409include_once DOL_DOCUMENT_ROOT.'/core/lib/functions2.lib.php';
410
411$prefix = '';
412if (getDolGlobalString('THEME_INFOBOX_COLOR_ON_BACKGROUND')) {
413 $prefix = 'background-';
414}
415
416if (!isset($conf->global->THEME_SATURATE_RATIO)) {
417 $conf->global->THEME_SATURATE_RATIO = 0.7;
418}
419if (GETPOSTISSET('THEME_SATURATE_RATIO')) {
420 $conf->global->THEME_SATURATE_RATIO = GETPOST('THEME_SATURATE_RATIO', 'int');
421}
422?>
423.bg-infobox-project i.fa{
424 color: #605ca8 !important;
425}
426.bg-infobox-action i.fa{
427 color: #d84b80 !important;
428}
429.bg-infobox-propal i.fa,
430.bg-infobox-facture i.fa,
431.bg-infobox-commande i.fa{
432 color: #abb87b !important;
433}
434.bg-infobox-supplier_proposal i.fa,
435.bg-infobox-invoice_supplier i.fa,
436.bg-infobox-order_supplier i.fa{
437 color: #40b0cf !important;
438}
439.bg-infobox-contrat i.fa, .bg-infobox-ticket i.fa{
440 color: #20a68a !important;
441}
442.bg-infobox-bank_account i.fa{
443 color: #b0a53e !important;
444}
445.bg-infobox-adherent i.fa, .bg-infobox-member i.fa{
446 color: #755114 !important;
447}
448.bg-infobox-expensereport i.fa{
449 color: #755114 !important;
450}
451.bg-infobox-holiday i.fa{
452 color: #755114 !important;
453}
454
455
456.fa-dol-action:before {
457 content: "\f073";
458}
459.fa-dol-propal:before,
460.fa-dol-supplier_proposal:before {
461 content: "\f573";
462}
463.fa-dol-facture:before,
464.fa-dol-invoice_supplier:before {
465 content: "\f571";
466}
467.fa-dol-project:before {
468 content: "\f542";
469}
470.fa-dol-commande:before,
471.fa-dol-order_supplier:before {
472 content: "\f570";
473}
474.fa-dol-contrat:before {
475 content: "\f1e6";
476}
477.fa-dol-ticket:before {
478 content: "\f3ff";
479}
480.fa-dol-bank_account:before {
481 content: "\f19c";
482}
483.fa-dol-member:before {
484 content: "\f0c0";
485}
486.fa-dol-expensereport:before {
487 content: "\f555";
488}
489.fa-dol-holiday:before {
490 content: "\f5ca";
491}
492
493
494/* USING FONTAWESOME FOR WEATHER */
495.info-box-weather .info-box-icon{
496 background: var(--colorbacktitle1) !important;
497}
498.fa-weather-level0:before{
499 content: "\f185";
500 color : #cfbf00;
501}
502.fa-weather-level1:before{
503 content: "\f6c4";
504 color : #bc9526;
505}
506.fa-weather-level2:before{
507 content: "\f743";
508 color : #b16000;
509}
510.fa-weather-level3:before{
511 content: "\f740";
512 color : #b04000;
513}
514.fa-weather-level4:before{
515 content: "\f0e7";
516 color : #b01000;
517}
518
519
520/* USING IMAGES FOR WEATHER INTEAD OF FONT AWESOME */
521/* For other themes just uncomment this part */
522/*.info-box-weather-level0,
523.info-box-weather-level1,
524.info-box-weather-level2,
525.info-box-weather-level3,
526.info-box-weather-level4 {
527 background-position: 15px 50%;
528 background-repeat: no-repeat;
529}
530
531.info-box-weather .info-box-icon{
532 display: none !important;
533}
534.info-box-weather-level0 {
535 background-image: url("img/weather/weather-clear.png");
536}
537.info-box-weather-level1 {
538 background-image: url("img/weather/weather-few-clouds.png");
539}
540.info-box-weather-level2 {
541 background-image: url("img/weather/weather-clouds.png");
542}
543.info-box-weather-level3 {
544 background-image: url("img/weather/weather-many-clouds.png");
545}
546.info-box-weather-level4 {
547 background-image: url("img/weather/weather-storm.png");
548}*/
549
550
551
552.box-flex-container{
553 display: flex; /* or inline-flex */
554 flex-direction: row;
555 flex-wrap: wrap;
556 width: 100%;
557 margin: 0 0 0 -15px;
558 /*justify-content: space-between;*/
559}
560
561.box-flex-grow-zero{
562 flex-grow: 0 !important;
563}
564
565.box-flex-item{
566 flex-grow : 1;
567 flex-shrink: 1;
568 flex-basis: auto;
569
570 width: 280px;
571 margin: 5px 0px 0px 15px;
572}
573.box-flex-item.filler{
574 margin: 0px 0px 0px 15px !important;
575 height: 0;
576}
577
578.info-box-title {
579 width: calc(100% - 20px);
580}
581.info-box-module {
582 min-width: 350px;
583 max-width: 350px;
584}
585.info-box-module .info-box-content {
586 height: 6.3em;
587}
588.fright {
589 float:right;
590}
591
592@media only screen and (max-width: 1740px) {
593 .info-box-module {
594 min-width: 315px;
595 max-width: 315px;
596 }
597}
598@media only screen and (max-width: 767px) {
599 .info-box-module {
600 min-width: 260px;
601 }
602 .info-box-sm .info-box-icon {
603 width: 60px;
604 }
605 .info-box-sm .info-box-content {
606 margin-left: 60px;
607 }
608 .info-box-content {
609 padding-top: 5px;
610 padding-bottom: 5px;
611 padding-left: 10px;
612 padding-right: 2px;
613 }
614 .info-box-line-text {
615 width: calc(100% - 92px);
616 max-width: calc(100% - 82px);
617 }
618}
619
620
621
print $script_file $mode $langs defaultlang(is_numeric($duration_value) ? " delay=". $duration_value :"").(is_numeric($duration_value2) ? " after cd cd cd description as description
Only used if Module[ID]Desc translation string is not found.
GETPOST($paramname, $check='alphanohtml', $method=0, $filter=null, $options=null, $noreplace=0)
Return value of a param into GET or POST supervariable.
getDolGlobalString($key, $default='')
Return dolibarr global constant string value.
rtl background position