Udskrivning af låner-stregkoder til alle klasser på én gang - med klassebetegnelse
Når jeg vælger at udskrive lånerlister til alle klasser på en gang, kommer alle elevers stregkoder ud i en lang smøre uden opdeling i klasser. Jeg skal måske bruge en anden printskabelon - men hvilken?
-
Jeg kan ikke lige finde en skabelon her på Cicero Connect, men jeg kan give dig den vi bruger.
0 -
<#-- @ftlvariable name="data" type="com.dantek.dl.client.administrationclient.loaner.printmodel.LoanerSearchOutputModel" -->
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml">
<#-- For landscape mode specify the number of wanted columns and rows in the next two lines and change the pagewidth. Fx columns = 6, rows = 5 and pagewidth = 28 -->
<#assign columns = 3>
<#assign rows = 10>
<#assign page = 0>
<#assign pagewidth = 19>
<#assign columnsep = 0.5>
<#assign cellwidth = (pagewidth - (columnsep * (columns - 1))) / columns>
<#macro missingcells>
<td>
<table class="noBorder">
<tr><td class="navn"> </td></tr>
<tr><td class="stregkode"><div> </div></td></tr>
<tr><td class="nummer"> </td></tr>
</table>
</td>
</#macro>
<head>
<meta http-equiv="content-type" content="text/html;charset=UTF-8"/>
<style>
@page {
size: 21cm 29.7cm;
margin: .5cm 1cm .5cm 1cm;
}
body {
padding: 0px;
margin: 0px;
font-family: "Ubuntu Light", sans-serif;
font-size: 16px;
font-style: normal;
-webkit-print-color-adjust: exact;
}
div.page > p {
-webkit-margin-before: 0em;
margin-top: 0px;
line-height: 1;
}
div.page:first {
page-break-before: avoid;
}
div.page {
page-break-before: always;
}
span.pagenumber {
float:right;
}
span.header {
width:100%;
display:block;
text-align: center;
}
p:empty {
display:none;
}
table {
border-spacing:0px;
border-collapse: collapse;
border: 0px solid black;
font-size: inherit;
width: 100%;
page-break-inside:auto;
}
table tr {
page-break-inside:avoid;
page-break-after:auto;
}
table.noBorder {
page-break-inside:avoid;
border: 0px;
width: ${cellwidth}cm;
}
table td {
border-bottom: 0px solid black;
padding: 6px 5px 6px 5px;
text-align: center;
page-break-inside: avoid;
}
table.noBorder td{
border-bottom: 0px solid black;
padding: 0px;
}
table.breakAfter {
page-break-inside: avoid;
page-break-after: always;
width: ${pagewidth}cm;
}
table.breakAfter:last-of-type {
page-break-inside: avoid;
page-break-after: auto;
width: ${pagewidth}cm;
}
.title {
font-size: 14px;
line-height: 0.1;
}
.criterion {
padding-right: 20px;
font-size: 24pt;
}
.barcode {
}
.navn {
height: 9mm;
}
.stregkode {
transform:scale(1.3,1.3);
height: 11mm;
}
.nummer {
height: 5mm;
font-size:8pt;
}
</style>
</head>
<body>
<div class="page">
<#assign Groups = []/>
<#if (data.results.numberOfResults > 0)>
<#list data.results.rows as loaner>
<#list loaner.loanerGroups as loanerGroup>
<#if (!Groups?seq_contains(loanerGroup))>
<#assign Groups = Groups + [loanerGroup]>
</#if>
</#list>
</#list>
<#list Groups?sort as groupName>
<#assign page = 0/>
<#assign done = 0/>
<#assign loaners = []/>
<#list data.results.rows?sort_by("name") as loaner>
<#if loaner.loanerGroups?seq_contains(groupName)>
<#assign loaners = loaners + [loaner]>
</#if>
</#list>
<#list loaners?chunk(rows * columns) as loanerPageChunk>
<p>
<#assign page = page + 1>
<span class="header">
<span class="criterion"><b>${groupName}</b></span>
<span style="float:right;">${page}</span>
<#assign done = 1>
</span>
</p>
<table class="breakAfter">
<#list loanerPageChunk?chunk(columns) as loanerTriple>
<tr>
<#list loanerTriple as loaner>
<td>
<table class="noBorder">
<tr><td class="navn">${(loaner.name)!""}</td></tr>
<tr><td class="stregkode"><div>${(loaner.numberBarCode)!""}</div></td></tr>
<tr><td class="nummer">${(loaner.number)!""}</td></tr>
</table>
</td>
</#list>
<#if (columns-(loanerTriple?size) > 0)>
<#list 1..(columns-(loanerTriple?size)) as iter><@missingcells/></#list>
</#if>
</tr>
</#list>
</table>
<#if (loanerPageChunk_has_next && done == 0)>
<#assign page = page + 1>
<div class="page">
<p>
<span class="header">
<span class="criterion"><b>${groupName}</b></span>
${page}
</span>
</p>
</#if>
</#list>
</#list>
</#if>
</div>
</body>
</html>0 -
Men du skal have adgang til F7 for at bruge den...ellers skal du have fat i jeres systemadministrator...
0 -
Du kan også bruge Systematics standard skabelon. Tryk "Gendan til standardværdi". Husk at tage en kopi af din nuværende skabelon først, hvis du af en eller anden grund skulle ønske at gå tilbage.
0 -
Måske skulle funktionen bare virke.
0
Log ind for at efterlade en kommentar.
Kommentarer
5 kommentarer