Skip to content
Snippets Groups Projects
Commit 0dd4161a authored by Thomas Bock's avatar Thomas Bock :speech_balloon:
Browse files

short list

parent 143693cb
No related branches found
No related tags found
No related merge requests found
$(document).ready(function () {
if (window.location.hash) {
var no = window.location.hash.split("#")[1],
......
function(head, req) {
var mustache = require("lib/couchapp/mustache"),
share = require("lib/vaclab/share"),
sk = req.query.startkey,
ek = req.query.endkey,
header = this.templates.header_short,
body = this.templates.body_short,
foot = this.templates.foot_short,
row, i = 1,
all = {},
titleadd = "";
start({
headers: {
"Content-type": "text/html; charset=utf-8"
}
});
if (sk && ek) {
var startyear = sk.split("_")[0],
endyear = ek.split("_")[0]
titleadd = startyear == endyear ? startyear : startyear + " bis " + endyear;
}
send(mustache.to_html(header, {
"Title": "AZ " + titleadd
}));
while (row = getRow()) {
var rv = row.value,
ak = rv.Certificate + rv.Year;
if (all[ak]) {
for (var k in rv) {
all[ak][k] = rv[k];
}
} else {
rv.Number = i++;
all[ak] = rv;
}
}
for (var j in all) {
var obj = all[j];
if (!obj.DateCertificate) {
obj.DateCertificate = "<button class='gen_cert'>Certificate</button>";
} else {
obj.DateCertificate = "<input class='date_cert' type='date' value='" + obj.DateCertificate + "'>"
}
send(mustache.to_html(body, obj));
}
send(mustache.to_html(foot, {
"Date": "nil",
"Title": "Übersicht Aktenzeichen " + titleadd
}));
};
......@@ -4,9 +4,9 @@ function(head, req) {
share = require("lib/vaclab/share"),
sk = req.query.startkey,
ek = req.query.endkey,
header = this.templates.header,
body = this.templates.body,
foot = this.templates.foot,
header = this.templates.header_full,
body = this.templates.body_full,
foot = this.templates.foot_full,
row, i = 1,
all = {},
titleadd = "";
......
<tr class="ref_{{OrderNumber}}" data-ref="{{OrderNumber}}">
<td class="ref_{{OrderNumber}} no_{{Number}} {{Standard}}" title="Normal" data-row="{{Number}}">
{{Standard}}
</td>
<td class="no_{{Number}}" title="Vorgang" data-row="{{Number}}">
{{OrderNumber}}
</td>
<td class="no_{{Number}}" title="KS" data-row="{{Number}}">
<a target="_blank" href="http://a73434.berlin.ptb.de:5984/vl_db/_design/applications/diwan2.html?id={{id}}"
target="_blank"><b>{{Certificate}}</b></a>
</td>
<td class="no_{{Number}}" title="Aktenzeichen" data-row="{{Number}}">
<b> {{ReferenceNo}} </b>
</td>
<td class="no_{{Number}}" title="allgemeines Aktenzeichen" data-row="{{Number}}">
<b> {{CommonReferenceNo}} </b>
</td>
......@@ -17,6 +24,7 @@
<td class="ref_{{OrderNumber}} no_{{Number}}" title="SAP" data-row="{{Number}}">
<a target="_blank" href="http://a73434.berlin.ptb.de:5984/vl_db/_design/applications/sofa.html?key={{CommonReferenceNo}}">{{SAP}}</a>
</td>
<td class="ref_{{OrderNumber}} no_{{Number}}" title="Hinweise zum Vorgang" data-row="{{Number}}">
<a target="_blank" href="http://a73434.berlin.ptb.de:5984/vl_db/_design/applications/sofa.html?key={{CommonReferenceNo}}">{{BurComment}}</a>
</td>
......@@ -51,9 +59,11 @@
<a target="_blank" href="http://a73434:5984/vl_db/_design/applications/ottomane.html?key=%22{{CustomerSign}}%20({{CustomerName}})%22">
{{DebitorenNr}}</a>
</td>
<td class="no_{{Number}}" title="Kundentyp" data-row="{{Number}}">
{{CustomerType}}
</td>
<td class="no_{{Number}}" title="Ansprechpartner" data-row="{{Number}}">
<a target="_blank" href="http://a73434:5984/vl_db/_design/applications/ottomane.html?key=%22{{CustomerSign}}%20({{CustomerName}})%22">
{{ContactName}}</a>
......@@ -69,12 +79,11 @@
<a target="_blank" href="http://a73434.berlin.ptb.de:5984/_utils/#/database/vl_db/_design/share/_view/CalibrationObject?key=%22{{DeviceName}}%22">
{{DeviceType}}
</td>
<td class="no_{{Number}}" title="Name des Kalibrierziels (Typ)" data-row="{{Number}}">
<a target="_blank" href="http://a73434.berlin.ptb.de:5984/_utils/#/database/vl_db/_design/share/_view/ToDo?key=%22{{ToDoName}}({{ToDoType}})%22">{{ToDoName}} ({{ToDoType}})</a>
</td>
<td class="ref_{{OrderNumber}} no_{{Number}} {{Standard}}" title="Normal" data-row="{{Number}}">
{{Standard}}
</td>
<td class="no_{{Number}}" title="Messbeauftragter" data-row="{{Number}}">
{{MeasMaintainer}}
......@@ -96,6 +105,10 @@
data-cert="{{Certificate}}"
data-year="{{Year}}">{{{DateCertificate}}}
</td>
<td class="no_{{Number}}" title="Datum Versand" data-row="{{Number}}">
{{{DateShipping}}}
</td>
<td class="no_{{Number}}" title="Fakturaanforderung" data-row="{{Number}}">
<a target="_blank" href="http://a73434.berlin.ptb.de:5984/vl_db/_design/applications/sofa.html?key={{CommonReferenceNo}}">{{Fakturaanforderung}}</a>
......
<tr class="ref_{{OrderNumber}}" data-ref="{{OrderNumber}}">
<td class="no_{{Number}}" title="KS" data-row="{{Number}}">
<b>{{Certificate}}</b>
</td>
<td class="no_{{Number}}" title="Aktenzeichen" data-row="{{Number}}">
<b> {{ReferenceNo}} </b>
</td>
<td class="ref_{{OrderNumber}} no_{{Number}} {{CustCommentAvailable}}"
title="Kundenname" data-row="{{Number}}">
{{CustomerName}}
</td>
<td class="no_{{Number}}" title="Kundentyp" data-row="{{Number}}">
{{CustomerType}}
</td>
<td class="no_{{Number}}" title="Gegenstand" data-row="{{Number}}">
{{DeviceType}}
</td>
</tr>
File moved
</tbody>
</table>
</div>
</div>
</body>
</html>
......@@ -7,7 +7,8 @@
<title>{{Title}}</title>
<style type="text/css">
body {
body {
font-size: 0.9em; // oder
font-size: 90%;
font-family: Helvetica, Arial, sans-serif;
......@@ -17,7 +18,7 @@
.ref_odd {
background-color:#f5e598;
}
/* */
#child {
width: 100%;
height: 800px;
......@@ -27,10 +28,10 @@
max-width: none;
min-width: 0px;
}
.vl { background-color:#FFFFE0;
border-collapse:collapse;
/*border-collapse:collapse;*/
white-space:nowrap;
}
.vl th {
......@@ -40,11 +41,12 @@
height: 40px;
}
/* */
.vl td, .vl th {
padding:5px;
solid #8a8673;
padding:3px;
solid: #8a8673;
}
.CE3 { color:white;background-color: #AA9A39; }
.FM1 { color:white;background-color: #452F74; }
......@@ -58,8 +60,8 @@
.selected { color:black; background-color: #ff6600; }
.w { color:black;background-color: #ECE8FA; }
overflow: scroll; /* Scrollbar are always visible */
overflow: auto; /* Scrollbar is displayed as it's needed */
overflow: scroll; /* Scrollbar are always visible */
overflow: auto; /* Scrollbar is displayed as it's needed */
</style>
</head>
......@@ -69,6 +71,7 @@
<table id="az" class="table vl" border="1">
<thead>
<tr>
<th>Standard</th>
<th>Vorgang</th>
<th>KS</th>
<th>Aktenzeichen (AZ)</th>
......@@ -89,7 +92,7 @@
<th>Gegenstand</th>
<th>Kalibrierziel</th>
<th>Standard</th>
<th>Messbeauftragter</th>
<th>Erstelldatum</th>
......@@ -97,6 +100,7 @@
<th><b>Solltermin</b></th>
<th>Start Messung</th>
<th>Datum KS</th>
<th>Datum Versand</th>
<th>Fakturaanforderung </th>
<th>Faktura</th>
......
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<script type="text/javascript"
src="../../js/jquery-3.1.1.min.js"></script>
<title>{{Title}}</title>
<style type="text/css">
body {
font-size: 0.9em; // oder
font-size: 90%;
font-family: Helvetica, Arial, sans-serif;
line-height: 100%;
background-color:#e8e7e0;
}
.ref_odd {
background-color:#f5e598;
}
/*
#child {
width: 100%;
height: 800px;
overflow: scroll;
max-height: none;
min-height: 0px;
max-width: none;
min-width: 0px;
}
*/
.vl { background-color:#FFFFE0;
/*border-collapse:collapse;*/
white-space:nowrap;
}
.vl th {
background-color:#1b1a0b;
color:white;
font-size: 110%;
height: 40px;
}
/* */
.vl td, .vl th {
padding:3px;
solid: #8a8673;
}
</style>
</head>
<body>
<div id="parent">
<div id="child">
<table id="az" class="table vl" border="1">
<thead>
<tr>
<th>KS</th>
<th>Aktenzeichen (AZ)</th>
<th>Kunde</th>
<th>Typ</th>
<th>Gegenstand</th>
</tr>
</thead>
<tbody>
......@@ -70,6 +70,7 @@ function(doc) {
BurComment: db.Comment || none,
DateInvoice: burDate["invoice"]|| missing,
DateTerm: burDate["terminated"]|| missing,
DateShipping: burDate["shipping"] || missing,
ConfirmationAmount: confAmo["manual"] || missing,
InvoiceAmount: invAmo["manual"] || missing,
Faktura:f,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment