@nixweb/nixloc-ui 0.0.297 → 0.0.299
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
<div class="wrapper">
|
|
7
7
|
<span :class="{ disabled: disabled }" class="minus" @click="decrement">-</span>
|
|
8
8
|
<span :class="{ disabled: disabled }" class="num" @click="showEdit = true" v-if="!showEdit">{{ number }}</span>
|
|
9
|
-
<input v-if="showEdit" class="input" type="number" @keyup.enter.prevent="
|
|
9
|
+
<input v-if="showEdit" class="input" type="number" @keyup.enter.prevent="enter" :disabled="disabled"
|
|
10
10
|
v-model="number" />
|
|
11
11
|
<span v-if="showEdit" :class="{ disabled: disabled }" @click="showEdit = false">
|
|
12
12
|
<i class="fa-solid fa-check"></i>
|
|
@@ -31,6 +31,7 @@ export default {
|
|
|
31
31
|
"triggerEvent",
|
|
32
32
|
"min",
|
|
33
33
|
"max",
|
|
34
|
+
"changed"
|
|
34
35
|
],
|
|
35
36
|
data() {
|
|
36
37
|
return {
|
|
@@ -56,11 +57,17 @@ export default {
|
|
|
56
57
|
this.executeFilter();
|
|
57
58
|
}
|
|
58
59
|
},
|
|
60
|
+
enter(){
|
|
61
|
+
this.showEdit = false;
|
|
62
|
+
if (this.changed) this.changed();
|
|
63
|
+
},
|
|
59
64
|
executeFilter() {
|
|
60
65
|
if (this.fieldTarget) {
|
|
61
66
|
let obj = { fieldTarget: this.fieldTarget, value: this.number };
|
|
62
67
|
this.addFilter(obj);
|
|
63
68
|
}
|
|
69
|
+
|
|
70
|
+
if (this.changed) this.changed();
|
|
64
71
|
},
|
|
65
72
|
},
|
|
66
73
|
watch: {
|
|
@@ -6,20 +6,11 @@
|
|
|
6
6
|
<Tip :field="field" :formName="formName" />
|
|
7
7
|
</label>
|
|
8
8
|
<div class="inner-addon right-addon">
|
|
9
|
-
<i
|
|
10
|
-
v-if="notifications.length > 0 && formDirty"
|
|
11
|
-
class="required glyphicon fas fa-exclamation-triangle"
|
|
12
|
-
></i>
|
|
9
|
+
<i v-if="notifications.length > 0 && formDirty" class="required glyphicon fas fa-exclamation-triangle"></i>
|
|
13
10
|
<slot v-else></slot>
|
|
14
|
-
<input
|
|
15
|
-
|
|
16
|
-
:
|
|
17
|
-
v-mask="mask || withoutMask"
|
|
18
|
-
v-bind:value="value"
|
|
19
|
-
v-on:input="$emit('input', $event.target.value)"
|
|
20
|
-
class="form-control"
|
|
21
|
-
:class="{ required: notifications.length > 0 && formDirty }"
|
|
22
|
-
/>
|
|
11
|
+
<input type="password" :disabled="disabled" :placeholder="titlePlaceholder" v-mask="mask || withoutMask"
|
|
12
|
+
v-bind:value="value" v-on:input="$emit('input', $event.target.value)" class="form-control"
|
|
13
|
+
:class="{ required: notifications.length > 0 && formDirty }" />
|
|
23
14
|
</div>
|
|
24
15
|
<div v-if="formDirty">
|
|
25
16
|
<div v-for="message in notifications" :key="message">
|
|
@@ -42,6 +33,7 @@ export default {
|
|
|
42
33
|
"field",
|
|
43
34
|
"titleColor",
|
|
44
35
|
"placeholder",
|
|
36
|
+
"disabled",
|
|
45
37
|
"mask",
|
|
46
38
|
"formName",
|
|
47
39
|
"required",
|
|
@@ -144,6 +136,7 @@ input::placeholder {
|
|
|
144
136
|
color: #94aa2a;
|
|
145
137
|
font-size: 14px;
|
|
146
138
|
}
|
|
139
|
+
|
|
147
140
|
.invalid {
|
|
148
141
|
color: #f0134d;
|
|
149
142
|
font-size: 14px;
|
|
@@ -43,28 +43,37 @@
|
|
|
43
43
|
:class="convertClass(row[obj.fieldComparison], obj.classCssBody)">
|
|
44
44
|
<TableButton v-if="obj.ifFieldEqual == row[obj.field]" :obj="obj" :row="row" />
|
|
45
45
|
</div>
|
|
46
|
-
<div v-if="obj.type === 'link'"
|
|
46
|
+
<div v-if="obj.type === 'link'" :style="obj.styleBody"
|
|
47
47
|
:class="convertClass(row[obj.fieldComparison], obj.classCssBody)" @click="navegateTo(obj, row)">
|
|
48
|
-
<
|
|
49
|
-
|
|
48
|
+
<div class="div-progress" v-if="idSelected == row.id">
|
|
49
|
+
<ProgressBar bgColor="orange" bColor="#CCCCCC" size="4" :value="loadingProgress" :max="100" />
|
|
50
|
+
</div>
|
|
51
|
+
<div class="link" v-else>
|
|
52
|
+
<span> {{ row[obj.field] }}</span>
|
|
53
|
+
<div class="field-second">{{ row[obj.fieldSecond] }}</div>
|
|
54
|
+
</div>
|
|
50
55
|
</div>
|
|
51
56
|
</div>
|
|
52
57
|
</template>
|
|
53
58
|
<script>
|
|
54
59
|
import TableButton from "@nixweb/nixloc-ui/src/component/shared/TableButton.vue";
|
|
55
60
|
import DisplayPeriodRent from "@nixweb/nixloc-ui/src/component/rental/DisplayPeriodRent";
|
|
61
|
+
import ProgressBar from "@nixweb/nixloc-ui/src/component/shared/ProgressBar";
|
|
56
62
|
|
|
57
63
|
import { mapMutations } from "vuex";
|
|
58
64
|
|
|
59
65
|
export default {
|
|
60
66
|
name: "TableItem",
|
|
61
|
-
components: { TableButton, DisplayPeriodRent },
|
|
67
|
+
components: { TableButton, DisplayPeriodRent, ProgressBar },
|
|
62
68
|
props: {
|
|
63
69
|
obj: Object,
|
|
64
70
|
row: Object,
|
|
65
71
|
},
|
|
66
72
|
data() {
|
|
67
|
-
return {
|
|
73
|
+
return {
|
|
74
|
+
idSelected: "",
|
|
75
|
+
loadingProgress: 0,
|
|
76
|
+
};
|
|
68
77
|
},
|
|
69
78
|
computed: {
|
|
70
79
|
urlImage() {
|
|
@@ -94,17 +103,43 @@ export default {
|
|
|
94
103
|
return eval(conditionVisibility);
|
|
95
104
|
},
|
|
96
105
|
navegateTo(obj, row) {
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
106
|
+
this.idSelected = row.id;
|
|
107
|
+
this.startLoading(obj, row);
|
|
108
|
+
},
|
|
109
|
+
startLoading(obj, row) {
|
|
110
|
+
let self = this;
|
|
111
|
+
const interval = setInterval(() => {
|
|
112
|
+
if (self.loadingProgress < 100) {
|
|
113
|
+
self.loadingProgress += 10;
|
|
114
|
+
} else {
|
|
115
|
+
clearInterval(interval);
|
|
116
|
+
}
|
|
117
|
+
}, 50);
|
|
118
|
+
}
|
|
119
|
+
},
|
|
120
|
+
watch: {
|
|
121
|
+
loadingProgress: {
|
|
122
|
+
handler(loadingProgress) {
|
|
123
|
+
if (loadingProgress == 100) {
|
|
124
|
+
if (this.obj.routeName) {
|
|
125
|
+
this.$router.push({
|
|
126
|
+
name: this.obj.routeName,
|
|
127
|
+
params: { id: this.row.id, type: this.row.type },
|
|
128
|
+
});
|
|
129
|
+
} else {
|
|
130
|
+
this.addEvent({
|
|
131
|
+
name: this.obj.eventName,
|
|
132
|
+
data: this.row,
|
|
133
|
+
});
|
|
134
|
+
|
|
135
|
+
let self = this;
|
|
136
|
+
setTimeout(function () {
|
|
137
|
+
self.idSelected = "";
|
|
138
|
+
}, 200);
|
|
139
|
+
}
|
|
140
|
+
}
|
|
141
|
+
},
|
|
142
|
+
deep: true,
|
|
108
143
|
},
|
|
109
144
|
},
|
|
110
145
|
};
|
|
@@ -172,5 +207,8 @@ export default {
|
|
|
172
207
|
cursor: pointer;
|
|
173
208
|
}
|
|
174
209
|
|
|
175
|
-
|
|
210
|
+
.div-progress {
|
|
211
|
+
margin-top: 11px;
|
|
212
|
+
width: 200px;
|
|
213
|
+
}
|
|
176
214
|
</style>
|
|
@@ -3,13 +3,8 @@
|
|
|
3
3
|
<Loading :center="false" v-if="loading" />
|
|
4
4
|
<div v-else>
|
|
5
5
|
<ScrollBar :minHeight="200" :maxHeight="300">
|
|
6
|
-
<Timeline
|
|
7
|
-
|
|
8
|
-
order="desc"
|
|
9
|
-
:uniqueTimeline="true"
|
|
10
|
-
:timeline-items="timelineItems"
|
|
11
|
-
message-when-no-items="Nenhum registro encontrado!"
|
|
12
|
-
/>
|
|
6
|
+
<Timeline dateLocale="pt-BR" order="desc" :uniqueTimeline="true" :timeline-items="timelineItems"
|
|
7
|
+
message-when-no-items="Nenhum registro encontrado!" />
|
|
13
8
|
</ScrollBar>
|
|
14
9
|
</div>
|
|
15
10
|
</div>
|
|
@@ -53,7 +53,7 @@
|
|
|
53
53
|
</div>
|
|
54
54
|
</div>
|
|
55
55
|
</div>
|
|
56
|
-
<div v-if="attachments.length == 0">
|
|
56
|
+
<div class="title" v-if="attachments.length == 0">
|
|
57
57
|
Nenhum arquivo adicionado!
|
|
58
58
|
</div>
|
|
59
59
|
</b-col>
|
|
@@ -380,7 +380,7 @@ export default {
|
|
|
380
380
|
color: green;
|
|
381
381
|
}
|
|
382
382
|
|
|
383
|
-
.title {
|
|
383
|
+
.title-file {
|
|
384
384
|
font-size: 18px;
|
|
385
385
|
margin-bottom: 20px;
|
|
386
386
|
}
|