annotate client/src/components/importschedule/Importscheduledetail.vue @ 1586:3a30a6f4c96d

unattended imports: translations added
author Thomas Junk <thomas.junk@intevation.de>
date Fri, 14 Dec 2018 11:02:46 +0100
parents b5d7770fe632
children af17c29df8f0
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
1430
4e24c2db0bf5 automatic imports: added missing components
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
1 <template>
1532
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
2 <div
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
3 class="importscheduledetails fadeIn animated"
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
4 v-if="importScheduleDetailVisible"
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
5 >
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
6 <div class="card h-100 shadow-xs">
1480
9b81ac91a43e fix: linting
Thomas Junk <thomas.junk@intevation.de>
parents: 1455
diff changeset
7 <h6
9b81ac91a43e fix: linting
Thomas Junk <thomas.junk@intevation.de>
parents: 1455
diff changeset
8 class="mb-0 py-2 px-3 border-bottom d-flex text-info align-items-center"
9b81ac91a43e fix: linting
Thomas Junk <thomas.junk@intevation.de>
parents: 1455
diff changeset
9 >
1455
33dda08d67be unified layout for adminsection
Thomas Junk <thomas.junk@intevation.de>
parents: 1430
diff changeset
10 <translate>New import</translate>
33dda08d67be unified layout for adminsection
Thomas Junk <thomas.junk@intevation.de>
parents: 1430
diff changeset
11 <span @click="closeDetailview" class="closebutton">
1430
4e24c2db0bf5 automatic imports: added missing components
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
12 <font-awesome-icon icon="times"></font-awesome-icon>
4e24c2db0bf5 automatic imports: added missing components
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
13 </span>
1455
33dda08d67be unified layout for adminsection
Thomas Junk <thomas.junk@intevation.de>
parents: 1430
diff changeset
14 </h6>
1430
4e24c2db0bf5 automatic imports: added missing components
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
15 <div class="card-body">
1586
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
16 <form @submit.prevent="save" class="ml-2 mr-2">
1532
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
17 <div class="d-flex flex-row w-100">
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
18 <div class="flex-column w-100">
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
19 <div class="flex-row text-left">
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
20 <small class="text-muted">
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
21 <translate>Imports</translate>
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
22 </small>
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
23 </div>
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
24 <select v-model="import_" class="custom-select" id="import_">
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
25 <option v-for="option in this.$options.imports" :key="option">{{
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
26 option
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
27 }}</option>
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
28 </select>
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
29 </div>
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
30 </div>
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
31 <div class="d-flex flex-row mt-3 w-100 justify-content-between">
1586
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
32 <div class="flex-column w-100">
1532
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
33 <div class="flex-row text-left">
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
34 <small class="text-muted">
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
35 <translate>Importtype</translate>
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
36 </small>
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
37 </div>
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
38 <select v-model="import_" class="custom-select" id="importtype">
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
39 <option
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
40 v-for="option in this.$options.importtype"
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
41 :key="option"
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
42 >{{ option }}</option
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
43 >
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
44 </select>
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
45 </div>
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
46 </div>
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
47 <div class="flex-column mt-3 w-100 mr-2">
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
48 <div class="flex-row text-left">
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
49 <small class="text-muted">
1570
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
50 <translate>Simple Schedule</translate>
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
51 </small>
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
52 </div>
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
53 <div class="flex-flex-row text-left">
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
54 <toggle-button
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
55 v-model="easyCron"
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
56 class="mt-2"
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
57 :speed="100"
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
58 :labels="{
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
59 checked: this.$options.on,
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
60 unchecked: this.$options.off
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
61 }"
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
62 :width="50"
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
63 :height="20"
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
64 />
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
65 </div>
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
66 </div>
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
67 <div class="flex-column w-100 mr-2">
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
68 <div class="flex-row text-left">
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
69 <small class="text-muted">
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
70 <translate>Schedule</translate>
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
71 </small>
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
72 </div>
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
73 <div v-if="easyCron" class="text-left w-50">
1575
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
74 <select v-model="simple" class="form-control"
1586
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
75 ><option value="weekly"><translate>Weekly</translate></option>
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
76 <option value="monthly"><translate>Monthly</translate></option>
1570
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
77 </select>
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
78 </div>
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
79 <div v-if="!easyCron" class="text-left w-100">
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
80 <div class="d-flex flex-row">
1586
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
81 <h4 class="mt-auto mb-auto mr-2">{{ $options.EVERY }}</h4>
1570
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
82 <select
1571
b3f2d43f43e4 added 15minutes as custom value
Thomas Junk <thomas.junk@intevation.de>
parents: 1570
diff changeset
83 style="width: 130px;"
1570
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
84 v-model="cronMode"
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
85 class="form-control"
1575
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
86 @change="clearInputs"
1570
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
87 >
1586
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
88 <option
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
89 v-for="(option, key) in $options.CRONMODE"
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
90 :value="key"
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
91 :key="key"
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
92 >{{ option }}</option
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
93 >
1570
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
94 </select>
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
95 <div v-if="cronMode == 'hour'" class="ml-2 d-flex flex-row">
1586
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
96 <h4 class="mt-auto mb-auto">{{ $options.ON }}</h4>
1570
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
97 <input
1575
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
98 v-model="minutes"
1570
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
99 style="width:50px"
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
100 class="ml-2 mr-2 form-control"
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
101 type="text"
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
102 />
1586
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
103 <h4 class="mt-auto mb-auto">{{ $options.MINUTESPAST }}</h4>
1570
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
104 </div>
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
105 <div v-if="cronMode == 'day'" class="ml-2 d-flex flex-row">
1586
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
106 <h4 class="mt-auto mb-auto">{{ $options.AT }}</h4>
1570
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
107 <input
1575
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
108 v-model="hour"
1570
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
109 style="width:50px"
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
110 class="ml-2 mr-2 form-control"
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
111 type="text"
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
112 />
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
113 <input
1575
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
114 v-model="minutes"
1570
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
115 style="width:50px"
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
116 class="ml-2 mr-2 form-control"
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
117 type="text"
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
118 />
1586
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
119 <h4 class="mt-auto mb-auto">{{ $options.OCLOCK }}</h4>
1570
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
120 </div>
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
121 <div v-if="cronMode == 'week'" class="ml-2 d-flex flex-row">
1586
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
122 <h4 class="ml-2 mr-3 mt-auto mb-auto">{{ $options.ON }}</h4>
1575
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
123 <select v-model="day" class="form-control">
1586
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
124 <option
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
125 v-for="(option, key) in $options.DAYSOFWEEK"
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
126 :key="key"
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
127 :value="key"
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
128 >{{ option }}</option
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
129 >
1570
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
130 </select>
1586
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
131 <h4 class="ml-2 mt-auto mb-auto">{{ $options.AT }}</h4>
1570
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
132 <input
1575
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
133 v-model="hour"
1570
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
134 style="width:50px"
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
135 class="ml-2 mr-2 form-control"
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
136 type="text"
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
137 />
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
138 <input
1575
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
139 v-model="minutes"
1570
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
140 style="width:50px"
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
141 class="ml-2 mr-2 form-control"
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
142 type="text"
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
143 />
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
144 </div>
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
145 <div v-if="cronMode == 'month'" class="ml-2 d-flex flex-row">
1586
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
146 <h4 class="ml-2 mt-auto mb-auto">{{ $options.ON }}</h4>
1570
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
147 <input
1575
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
148 v-model="dayOfMonth"
1570
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
149 style="width:50px"
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
150 class="ml-2 mr-2 form-control"
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
151 type="text"
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
152 />
1586
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
153 <h4 class="mt-auto mb-auto">{{ $options.AT }}</h4>
1570
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
154 <input
1575
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
155 v-model="hour"
1570
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
156 style="width:50px"
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
157 class="ml-2 mr-2 form-control"
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
158 type="text"
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
159 />
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
160 <input
1575
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
161 v-model="minutes"
1570
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
162 style="width:50px"
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
163 class="ml-2 mr-2 form-control"
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
164 type="text"
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
165 />
1586
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
166 <h4 class="mt-auto mb-auto">{{ $options.OCLOCK }}</h4>
1570
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
167 </div>
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
168 <div v-if="cronMode == 'year'" class="ml-2 d-flex flex-row">
1586
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
169 <h4 class="ml-2 mt-auto mb-auto">{{ $options.ON }}</h4>
1570
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
170 <input
1575
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
171 v-model="dayOfMonth"
1570
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
172 style="width:50px"
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
173 class="ml-2 mr-2 form-control"
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
174 type="text"
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
175 />
1586
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
176 <h4 class="mt-auto mb-auto">{{ $options.OF }}</h4>
1575
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
177 <select v-model="month" class="ml-2 mr-2 form-control">
1586
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
178 <option
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
179 v-for="(option, key) in $options.MONTHS"
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
180 :value="key"
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
181 :key="key"
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
182 >{{ option }}</option
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
183 >
1570
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
184 </select>
1586
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
185 <h4 class="mt-auto mb-auto">{{ $options.ON }}</h4>
1570
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
186 <input
1575
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
187 v-model="hour"
1570
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
188 style="width:50px"
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
189 class="ml-2 mr-2 form-control"
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
190 type="text"
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
191 />
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
192 <input
1575
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
193 v-model="minutes"
1570
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
194 style="width:50px"
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
195 class="ml-2 mr-2 form-control"
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
196 type="text"
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
197 />
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
198 </div>
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
199 </div>
1575
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
200 <div class="mt-3 w-50 d-flex flex-row">
1586
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
201 <h5 class="mt-auto mb-auto mr-2">
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
202 <translate>Cronstring</translate>
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
203 </h5>
1575
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
204 <input class="form-control" :value="cronString" type="text" />
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
205 </div>
1570
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
206 </div>
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
207 </div>
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
208 <div class="flex-column mt-3 w-100 mr-2">
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
209 <div class="flex-row text-left">
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
210 <small class="text-muted">
1532
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
211 <translate>Email Notification</translate>
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
212 </small>
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
213 </div>
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
214 <div class="flex-flex-row text-left">
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
215 <toggle-button
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
216 v-model="eMailNotification"
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
217 class="mt-2"
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
218 :speed="100"
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
219 :labels="{
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
220 checked: this.$options.on,
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
221 unchecked: this.$options.off
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
222 }"
1542
31c6c7bd6190 layout issues
Thomas Junk <thomas.junk@intevation.de>
parents: 1532
diff changeset
223 :width="50"
31c6c7bd6190 layout issues
Thomas Junk <thomas.junk@intevation.de>
parents: 1532
diff changeset
224 :height="20"
1532
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
225 />
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
226 </div>
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
227 </div>
1565
faa045ebdf0c select first surveydate after identification of bottleneck
Thomas Junk <thomas.junk@intevation.de>
parents: 1558
diff changeset
228 <div class="flex-column w-100 mr-2">
1532
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
229 <div class="flex-row text-left">
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
230 <small class="text-muted"> <translate>Email</translate> </small>
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
231 </div>
1565
faa045ebdf0c select first surveydate after identification of bottleneck
Thomas Junk <thomas.junk@intevation.de>
parents: 1558
diff changeset
232 <input
faa045ebdf0c select first surveydate after identification of bottleneck
Thomas Junk <thomas.junk@intevation.de>
parents: 1558
diff changeset
233 :disabled="!eMailNotification"
faa045ebdf0c select first surveydate after identification of bottleneck
Thomas Junk <thomas.junk@intevation.de>
parents: 1558
diff changeset
234 class="form-control"
faa045ebdf0c select first surveydate after identification of bottleneck
Thomas Junk <thomas.junk@intevation.de>
parents: 1558
diff changeset
235 type="text"
faa045ebdf0c select first surveydate after identification of bottleneck
Thomas Junk <thomas.junk@intevation.de>
parents: 1558
diff changeset
236 />
1532
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
237 </div>
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
238 <button type="submit" class="shadow-sm btn btn-info submit-button">
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
239 <translate>Submit</translate>
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
240 </button>
1586
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
241 <button type="button" class="shadow-sm btn btn-outline-info trigger">
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
242 <font-awesome-icon
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
243 class="fa-fw mr-2"
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
244 fixed-width
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
245 icon="play"
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
246 ></font-awesome-icon
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
247 ><translate>Trigger import</translate>
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
248 </button>
1529
Thomas Junk <thomas.junk@intevation.de>
parents: 1480
diff changeset
249 </form>
1430
4e24c2db0bf5 automatic imports: added missing components
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
250 </div>
4e24c2db0bf5 automatic imports: added missing components
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
251 </div>
4e24c2db0bf5 automatic imports: added missing components
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
252 </div>
4e24c2db0bf5 automatic imports: added missing components
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
253 </template>
4e24c2db0bf5 automatic imports: added missing components
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
254
4e24c2db0bf5 automatic imports: added missing components
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
255 <script>
4e24c2db0bf5 automatic imports: added missing components
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
256 import { mapState } from "vuex";
1558
0ded4c56978e refac: component filestructure. remove admin/map hierarchy
Thomas Junk <thomas.junk@intevation.de>
parents: 1542
diff changeset
257 import { displayInfo } from "../../lib/errors.js";
1586
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
258 import app from "../../main.js";
1430
4e24c2db0bf5 automatic imports: added missing components
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
259
4e24c2db0bf5 automatic imports: added missing components
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
260 export default {
4e24c2db0bf5 automatic imports: added missing components
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
261 name: "importscheduledetail",
1529
Thomas Junk <thomas.junk@intevation.de>
parents: 1480
diff changeset
262 data() {
Thomas Junk <thomas.junk@intevation.de>
parents: 1480
diff changeset
263 return {
1565
faa045ebdf0c select first surveydate after identification of bottleneck
Thomas Junk <thomas.junk@intevation.de>
parents: 1558
diff changeset
264 importType: null,
1532
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
265 schedule: null,
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
266 import_: null,
1565
faa045ebdf0c select first surveydate after identification of bottleneck
Thomas Junk <thomas.junk@intevation.de>
parents: 1558
diff changeset
267 eMailNotification: false,
1570
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
268 easyCron: true,
1575
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
269 cronMode: "",
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
270 minutes: null,
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
271 month: null,
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
272 hour: null,
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
273 day: null,
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
274 dayOfMonth: null,
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
275 simple: null
1529
Thomas Junk <thomas.junk@intevation.de>
parents: 1480
diff changeset
276 };
Thomas Junk <thomas.junk@intevation.de>
parents: 1480
diff changeset
277 },
1575
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
278 watch: {
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
279 cronString() {
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
280 if (this.isWeekly(this.cronString)) {
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
281 this.simple = "weekly";
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
282 }
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
283 if (this.isMonthly(this.cronString)) {
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
284 this.simple = "monthly";
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
285 }
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
286 }
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
287 },
1586
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
288 EVERY: app.$gettext("Every"),
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
289 MINUTESPAST: app.$gettext("minutes past"),
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
290 ON: app.$gettext("on"),
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
291 OF: app.$gettext("of"),
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
292 AT: app.$gettext("at"),
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
293 OCLOCK: app.$gettext("o' clock"),
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
294 CRONMODE: {
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
295 "15minutes": app.$gettext("15 minutes"),
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
296 hour: app.$gettext("hour"),
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
297 day: app.$gettext("day"),
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
298 week: app.$gettext("week"),
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
299 month: app.$gettext("month"),
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
300 year: app.$gettext("year")
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
301 },
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
302 DAYSOFWEEK: {
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
303 1: app.$gettext("Monday"),
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
304 2: app.$gettext("Tuesday"),
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
305 3: app.$gettext("Wednesday"),
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
306 4: app.$gettext("Thursday"),
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
307 5: app.$gettext("Friday"),
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
308 6: app.$gettext("Saturday"),
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
309 0: app.$gettext("Sunday")
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
310 },
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
311 MONTHS: {
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
312 1: app.$gettext("January"),
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
313 2: app.$gettext("February"),
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
314 3: app.$gettext("March"),
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
315 4: app.$gettext("April"),
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
316 5: app.$gettext("May"),
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
317 6: app.$gettext("June"),
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
318 7: app.$gettext("July"),
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
319 8: app.$gettext("August"),
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
320 9: app.$gettext("September"),
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
321 10: app.$gettext("October"),
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
322 11: app.$gettext("November"),
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
323 12: app.$gettext("December")
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
324 },
1430
4e24c2db0bf5 automatic imports: added missing components
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
325 computed: {
1575
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
326 ...mapState("imports", ["importScheduleDetailVisible"]),
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
327 cronString: {
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
328 get() {
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
329 let getValue = value => {
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
330 return this[value] ? this[value] : "*";
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
331 };
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
332 if (this.cronMode === "15minutes") return "*/15 * * * *";
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
333 const min = getValue("minutes");
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
334 const h = getValue("hour");
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
335 const dm = getValue("dayOfMonth");
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
336 const m = getValue("month");
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
337 const wd = getValue("day");
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
338 return `${min} ${h} ${dm} ${m} ${wd}`;
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
339 }
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
340 }
1430
4e24c2db0bf5 automatic imports: added missing components
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
341 },
4e24c2db0bf5 automatic imports: added missing components
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
342 methods: {
1575
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
343 isWeekly(cron) {
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
344 return /\d{1,2} \d{1,2} \* \* \d{1}/.test(cron);
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
345 },
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
346 isMonthly(cron) {
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
347 return /\d{1,2} \d{1,2} \d{1,2} \* \*/.test(cron);
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
348 },
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
349 clearInputs() {
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
350 this.minutes = null;
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
351 this.month = null;
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
352 this.hour = null;
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
353 this.day = null;
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
354 this.dayOfMonth = null;
51f924cbac23 Feat: Importscheduler renamed to "unattended imports"
Thomas Junk <thomas.junk@intevation.de>
parents: 1571
diff changeset
355 },
1532
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
356 save() {
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
357 displayInfo({
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
358 title: "Import",
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
359 message: "under construction"
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
360 });
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
361 },
1430
4e24c2db0bf5 automatic imports: added missing components
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
362 closeDetailview() {
4e24c2db0bf5 automatic imports: added missing components
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
363 this.$store.commit("imports/clearImportScheduleDetail");
4e24c2db0bf5 automatic imports: added missing components
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
364 this.$store.commit("imports/setImportScheduleDetailInvisible");
4e24c2db0bf5 automatic imports: added missing components
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
365 }
1532
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
366 },
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
367 imports: [],
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
368 importtype: [],
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
369 on: "on",
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
370 off: "off",
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
371 periods: {
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
372 DAILY: "daily",
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
373 MONTHLY: "monthly"
1430
4e24c2db0bf5 automatic imports: added missing components
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
374 }
4e24c2db0bf5 automatic imports: added missing components
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
375 };
4e24c2db0bf5 automatic imports: added missing components
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
376 </script>
4e24c2db0bf5 automatic imports: added missing components
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
377
1455
33dda08d67be unified layout for adminsection
Thomas Junk <thomas.junk@intevation.de>
parents: 1430
diff changeset
378 <style lang="scss" scoped>
33dda08d67be unified layout for adminsection
Thomas Junk <thomas.junk@intevation.de>
parents: 1430
diff changeset
379 .importscheduledetails {
1570
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
380 height: 620px;
424793472f28 nice advanced schedule selection
Thomas Junk <thomas.junk@intevation.de>
parents: 1565
diff changeset
381 width: 100%;
1455
33dda08d67be unified layout for adminsection
Thomas Junk <thomas.junk@intevation.de>
parents: 1430
diff changeset
382 margin-top: $offset;
1529
Thomas Junk <thomas.junk@intevation.de>
parents: 1480
diff changeset
383 margin-right: $offset;
1455
33dda08d67be unified layout for adminsection
Thomas Junk <thomas.junk@intevation.de>
parents: 1430
diff changeset
384 }
1532
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
385
1586
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
386 .trigger {
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
387 position: absolute;
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
388 left: $large-offset;
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
389 bottom: $offset;
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
390 }
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
391
1532
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
392 .submit-button {
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
393 position: absolute;
1586
3a30a6f4c96d unattended imports: translations added
Thomas Junk <thomas.junk@intevation.de>
parents: 1576
diff changeset
394 right: $large-offset;
1532
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
395 bottom: $offset;
44e094330272 automatic imports: fields added
Thomas Junk <thomas.junk@intevation.de>
parents: 1529
diff changeset
396 }
1430
4e24c2db0bf5 automatic imports: added missing components
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
397 </style>