Mercurial > gemma
annotate client/src/components/importoverview/AdditionalLog.vue @ 2703:c887666b110f
import_overview: increase log fontsize. errors in log are marked red
author | Thomas Junk <thomas.junk@intevation.de> |
---|---|
date | Mon, 18 Mar 2019 15:49:41 +0100 |
parents | 39a05f8c34e6 |
children | cefef8234d27 |
rev | line source |
---|---|
2594 | 1 <template> |
2599 | 2 <div class="additionallog d-flex flex-column text-left"> |
2597 | 3 <div class="d-flex flex-row" v-for="(line, index) in logLines" :key="index"> |
2674
b219ca1514f4
overview2: highlight warnings in logs
Thomas Junk <thomas.junk@intevation.de>
parents:
2608
diff
changeset
|
4 <small |
b219ca1514f4
overview2: highlight warnings in logs
Thomas Junk <thomas.junk@intevation.de>
parents:
2608
diff
changeset
|
5 :class="[ |
b219ca1514f4
overview2: highlight warnings in logs
Thomas Junk <thomas.junk@intevation.de>
parents:
2608
diff
changeset
|
6 'kind', |
b219ca1514f4
overview2: highlight warnings in logs
Thomas Junk <thomas.junk@intevation.de>
parents:
2608
diff
changeset
|
7 { |
2703
c887666b110f
import_overview: increase log fontsize. errors in log are marked red
Thomas Junk <thomas.junk@intevation.de>
parents:
2685
diff
changeset
|
8 'text-danger': /error/.test(line.kind), |
2674
b219ca1514f4
overview2: highlight warnings in logs
Thomas Junk <thomas.junk@intevation.de>
parents:
2608
diff
changeset
|
9 'text-warning': /warn/.test(line.kind), |
2703
c887666b110f
import_overview: increase log fontsize. errors in log are marked red
Thomas Junk <thomas.junk@intevation.de>
parents:
2685
diff
changeset
|
10 'font-weight-bold': /warn|error/.test(line.kind) |
2674
b219ca1514f4
overview2: highlight warnings in logs
Thomas Junk <thomas.junk@intevation.de>
parents:
2608
diff
changeset
|
11 } |
b219ca1514f4
overview2: highlight warnings in logs
Thomas Junk <thomas.junk@intevation.de>
parents:
2608
diff
changeset
|
12 ]" |
b219ca1514f4
overview2: highlight warnings in logs
Thomas Junk <thomas.junk@intevation.de>
parents:
2608
diff
changeset
|
13 >{{ line.kind.toUpperCase() }}</small |
b219ca1514f4
overview2: highlight warnings in logs
Thomas Junk <thomas.junk@intevation.de>
parents:
2608
diff
changeset
|
14 > |
b219ca1514f4
overview2: highlight warnings in logs
Thomas Junk <thomas.junk@intevation.de>
parents:
2608
diff
changeset
|
15 <small |
b219ca1514f4
overview2: highlight warnings in logs
Thomas Junk <thomas.junk@intevation.de>
parents:
2608
diff
changeset
|
16 :class="[ |
b219ca1514f4
overview2: highlight warnings in logs
Thomas Junk <thomas.junk@intevation.de>
parents:
2608
diff
changeset
|
17 'time', |
b219ca1514f4
overview2: highlight warnings in logs
Thomas Junk <thomas.junk@intevation.de>
parents:
2608
diff
changeset
|
18 { |
2703
c887666b110f
import_overview: increase log fontsize. errors in log are marked red
Thomas Junk <thomas.junk@intevation.de>
parents:
2685
diff
changeset
|
19 'text-danger': /error/.test(line.kind), |
2674
b219ca1514f4
overview2: highlight warnings in logs
Thomas Junk <thomas.junk@intevation.de>
parents:
2608
diff
changeset
|
20 'text-warning': /warn/.test(line.kind), |
2703
c887666b110f
import_overview: increase log fontsize. errors in log are marked red
Thomas Junk <thomas.junk@intevation.de>
parents:
2685
diff
changeset
|
21 'font-weight-bold': /warn|error/.test(line.kind) |
2674
b219ca1514f4
overview2: highlight warnings in logs
Thomas Junk <thomas.junk@intevation.de>
parents:
2608
diff
changeset
|
22 } |
b219ca1514f4
overview2: highlight warnings in logs
Thomas Junk <thomas.junk@intevation.de>
parents:
2608
diff
changeset
|
23 ]" |
b219ca1514f4
overview2: highlight warnings in logs
Thomas Junk <thomas.junk@intevation.de>
parents:
2608
diff
changeset
|
24 >{{ line.time }}</small |
b219ca1514f4
overview2: highlight warnings in logs
Thomas Junk <thomas.junk@intevation.de>
parents:
2608
diff
changeset
|
25 > |
b219ca1514f4
overview2: highlight warnings in logs
Thomas Junk <thomas.junk@intevation.de>
parents:
2608
diff
changeset
|
26 <small |
b219ca1514f4
overview2: highlight warnings in logs
Thomas Junk <thomas.junk@intevation.de>
parents:
2608
diff
changeset
|
27 :class="[ |
b219ca1514f4
overview2: highlight warnings in logs
Thomas Junk <thomas.junk@intevation.de>
parents:
2608
diff
changeset
|
28 'message', |
b219ca1514f4
overview2: highlight warnings in logs
Thomas Junk <thomas.junk@intevation.de>
parents:
2608
diff
changeset
|
29 { |
2703
c887666b110f
import_overview: increase log fontsize. errors in log are marked red
Thomas Junk <thomas.junk@intevation.de>
parents:
2685
diff
changeset
|
30 'text-danger': /error/.test(line.kind), |
2674
b219ca1514f4
overview2: highlight warnings in logs
Thomas Junk <thomas.junk@intevation.de>
parents:
2608
diff
changeset
|
31 'text-warning': /warn/.test(line.kind), |
2703
c887666b110f
import_overview: increase log fontsize. errors in log are marked red
Thomas Junk <thomas.junk@intevation.de>
parents:
2685
diff
changeset
|
32 'font-weight-bold': /warn|error/.test(line.kind) |
2674
b219ca1514f4
overview2: highlight warnings in logs
Thomas Junk <thomas.junk@intevation.de>
parents:
2608
diff
changeset
|
33 } |
b219ca1514f4
overview2: highlight warnings in logs
Thomas Junk <thomas.junk@intevation.de>
parents:
2608
diff
changeset
|
34 ]" |
b219ca1514f4
overview2: highlight warnings in logs
Thomas Junk <thomas.junk@intevation.de>
parents:
2608
diff
changeset
|
35 >{{ line.message }}</small |
b219ca1514f4
overview2: highlight warnings in logs
Thomas Junk <thomas.junk@intevation.de>
parents:
2608
diff
changeset
|
36 > |
2597 | 37 </div> |
2594 | 38 </div> |
39 </template> | |
40 | |
41 <script> | |
42 /* This is Free Software under GNU Affero General Public License v >= 3.0 | |
43 * without warranty, see README.md and license for details. | |
44 * | |
45 * SPDX-License-Identifier: AGPL-3.0-or-later | |
46 * License-Filename: LICENSES/AGPL-3.0.txt | |
47 * | |
48 * Copyright (C) 2018 by via donau | |
49 * – Österreichische Wasserstraßen-Gesellschaft mbH | |
50 * Software engineering by Intevation GmbH | |
51 * | |
52 * Author(s): | |
53 * Thomas Junk <thomas.junk@intevation.de> | |
54 */ | |
55 export default { | |
56 name: "additionallogs", | |
2685
39a05f8c34e6
import_overview: Refactoring of detailed information.
Thomas Junk <thomas.junk@intevation.de>
parents:
2674
diff
changeset
|
57 props: ["details"], |
2597 | 58 data() { |
59 return { | |
2685
39a05f8c34e6
import_overview: Refactoring of detailed information.
Thomas Junk <thomas.junk@intevation.de>
parents:
2674
diff
changeset
|
60 logLines: this.details.entries |
2597 | 61 }; |
62 } | |
2594 | 63 }; |
64 </script> | |
65 | |
2599 | 66 <style lang="scss" scoped> |
2608
13377f2a5c42
overview2: agm details prototype implemented
Thomas Junk <thomas.junk@intevation.de>
parents:
2599
diff
changeset
|
67 .additionallog { |
13377f2a5c42
overview2: agm details prototype implemented
Thomas Junk <thomas.junk@intevation.de>
parents:
2599
diff
changeset
|
68 width: 600px; |
13377f2a5c42
overview2: agm details prototype implemented
Thomas Junk <thomas.junk@intevation.de>
parents:
2599
diff
changeset
|
69 max-height: 20vh; |
13377f2a5c42
overview2: agm details prototype implemented
Thomas Junk <thomas.junk@intevation.de>
parents:
2599
diff
changeset
|
70 overflow-y: auto; |
13377f2a5c42
overview2: agm details prototype implemented
Thomas Junk <thomas.junk@intevation.de>
parents:
2599
diff
changeset
|
71 } |
2599 | 72 .kind { |
2703
c887666b110f
import_overview: increase log fontsize. errors in log are marked red
Thomas Junk <thomas.junk@intevation.de>
parents:
2685
diff
changeset
|
73 width: 8%; |
2599 | 74 } |
75 .time { | |
2674
b219ca1514f4
overview2: highlight warnings in logs
Thomas Junk <thomas.junk@intevation.de>
parents:
2608
diff
changeset
|
76 width: 24%; |
2599 | 77 } |
2703
c887666b110f
import_overview: increase log fontsize. errors in log are marked red
Thomas Junk <thomas.junk@intevation.de>
parents:
2685
diff
changeset
|
78 |
c887666b110f
import_overview: increase log fontsize. errors in log are marked red
Thomas Junk <thomas.junk@intevation.de>
parents:
2685
diff
changeset
|
79 small { |
c887666b110f
import_overview: increase log fontsize. errors in log are marked red
Thomas Junk <thomas.junk@intevation.de>
parents:
2685
diff
changeset
|
80 font-size: smaller; |
c887666b110f
import_overview: increase log fontsize. errors in log are marked red
Thomas Junk <thomas.junk@intevation.de>
parents:
2685
diff
changeset
|
81 } |
2599 | 82 </style> |