Subversion Repositories ALCASAR

Rev

Rev 2179 | Details | Compare with Previous | Last modification | View Log

Rev Author Line No. Line
2168 tom.houday 1
<?php
2
/**
3
 * Tickets template for TicketsGenerator
4
 *
2851 rexy 5
 * @author    Tom Houdayer & Rexy
2168 tom.houday 6
 * @copyright Copyright (C) ALCASAR (http://www.alcasar.net)
7
 * @license   GPL-3.0
8
 * @version   $Id: tickets.template.php 2851 2020-07-16 21:54:46Z rexy $
9
 */
10
 
11
$langue_imp = $language;
12
require __DIR__ . '/../langues_imp.php';
13
 
14
$img_logoAlcasar      = __DIR__ . '/../../../../images/logo-alcasar.png';
15
$img_logoOrganization = __DIR__ . '/../../../../images/organisme.png';
16
?>
17
<!doctype html>
18
<html>
19
<head>
20
	<meta charset="utf-8">
21
	<style>
2851 rexy 22
	@font-face {
23
		font-family: 'DejaVuSerif';
24
		src: url("/usr/share/fonts/TTF/dejavu/DejaVuSerif.ttf") format('truetype');
25
	}	
2168 tom.houday 26
		body {
27
			margin: 0;
28
		}
29
		.ticket {
2179 tom.houday 30
			margin: 14px 0;
2168 tom.houday 31
			width: 50%;
32
			display: inline-block;
2851 rexy 33
			font-family: 'DejaVuSerif';
2179 tom.houday 34
			font-size: 8px;
35
			line-height: 16px;
2168 tom.houday 36
		}
37
		.ticket-header {
2179 tom.houday 38
			min-height:  30px;
39
			line-height: 30px;
40
			font-size: 10px;
2168 tom.houday 41
			text-align: center;
42
		}
43
		.ticket-header > .ticket-title {
44
			color: red;
45
			font-weight: bold;
46
		}
47
		.ticket-box {
48
			position: relative;
49
			border: 1px solid black;
50
			border-radius: 10px;
2179 tom.houday 51
			width: 220px;
2168 tom.houday 52
			margin: 0 auto;
53
		}
54
		.ticket-box > .logo {
55
			position: absolute;
56
			display: inline-block;
2179 tom.houday 57
			width:  60px;
58
			height: 60px;
2168 tom.houday 59
			text-align: center;
60
		}
61
		.ticket-box > .logo img {
62
			max-width:  100%;
63
			max-height: 100%;
64
		}
65
		.ticket-box > .logo-alcasar {
2179 tom.houday 66
			top:  -30px;
67
			left: -30px;
2168 tom.houday 68
		}
69
		.ticket-box > .logo-organization {
2179 tom.houday 70
			top:   -30px;
71
			right: -30px;
2168 tom.houday 72
		}
73
		.ticket-body {
74
			position: relative;
75
			z-index: 10;
76
			padding: 5px;
77
		}
78
		.ticket-body > div > span {
79
			display: inline-block;
80
		}
81
		.ticket-body > div.spacer {
2179 tom.houday 82
			height: 10px;
2168 tom.houday 83
		}
84
		.ticket-body > div > span.key {
2179 tom.houday 85
			width: 52%;
2168 tom.houday 86
			text-align: right;
87
		}
88
		.ticket-body > div > span.value {
2179 tom.houday 89
			width: 48%;
2168 tom.houday 90
			font-weight: bold;
91
		}
92
		.ticket-footer > .infos {
2179 tom.houday 93
			font-size: 7px;
94
			height: 52px;
2168 tom.houday 95
		}
96
		.center {
97
			text-align: center;
98
		}
99
	</style>
100
</head>
101
<body>
102
	<?php foreach ($users as $user):
103
	  ?><div class="ticket">
104
			<div class="ticket-header">
105
				<span class="ticket-title"><?= $l_title_imp ?></span>
106
			</div>
107
			<div class="ticket-box">
108
				<div class="logo logo-alcasar"><img src="<?= $img_logoAlcasar ?>" alt=""></div>
109
				<div class="logo logo-organization"><img src="<?= $img_logoOrganization ?>" alt=""></div>
110
				<div class="ticket-body">
111
					<div class="spacer"></div>
112
					<div><span class="key"><?= $l_login_imp ?>&nbsp;</span><span class="value"><?= $user->username ?></span></div>
113
					<div><span class="key"><?= $l_password_imp ?>&nbsp;</span><span class="value"><?= $user->password ?></span></div>
114
					<div class="spacer"></div>
115
					<div><span class="key"><?= $l_max_all_session_imp ?>&nbsp;</span><span class="value"><?= $user->maxAllSession ?></span></div>
116
					<div><span class="key"><?= $l_session_timeout_imp ?>&nbsp;</span><span class="value"><?= $user->sessionTimeout ?></span></div>
117
					<div><span class="key"><?= $l_max_daily_session_imp ?>&nbsp;</span><span class="value"><?= $user->maxDailySession ?></span></div>
118
					<div><span class="key"><?= $l_expiration_imp ?>&nbsp;</span><span class="value"><?= $user->expiration ?></span></div>
119
					<div class="spacer"></div>
120
				</div>
121
			</div>
122
			<div class="ticket-footer">
123
				<?php if ($user->isDuplicate): ?>
124
					<div class="infos center">
125
						<p><?= $l_duplicate ?></p>
126
					</div>
127
				<?php else: ?>
128
					<div class="infos">
129
						<p><?= nl2br($l_explain, false) ?></p>
130
					</div>
131
				<?php endif; ?>
132
				<div class="credits center"><?= $l_footer_imp ?></div>
133
			</div>
134
		</div><?php
135
	endforeach; ?>
136
</body>
137
</html>