@burh/nuxt-core 1.0.295 → 1.0.298

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.
@@ -1,196 +1,227 @@
1
1
  <template>
2
- <div class="bg-white content-left">
3
- <div class="profile w-100 text-center">
4
- <div class="avatar">
5
- <img
6
- v-if="userData.urlAvatar"
7
- :src="userData.urlAvatar"
8
- :alt="userData.name"
9
- />
10
- <div v-else class="no-image">
11
- {{ userData.name }}
12
- </div>
13
- </div>
14
-
15
- <h5 class="mb-0 text-wrap" :class="{ 'mt-5': !userData.urlAvatar }" v-html="highlightText(search, `${userData.name} ${userData.last_name}`)"></h5>
16
-
17
- <p class="user-info" v-if="userData.user_experience.length > 0" v-html="highlightText(search, `${userData.user_experience[0].job_title} em ${userData.user_experience[0].company}`)"></p>
18
-
19
- <span v-if="userData.user_address">
20
- <i class="fas fa-map-marker-alt"></i>
21
- {{ userData.user_address.city_name }} -
22
- {{ userData.user_address.region_code }}
23
- </span>
24
- <br>
25
- <span v-if="userData.user_complementary_information.wage_pretension > 1">Pretenção salarial: R$ {{userData.user_complementary_information.wage_pretension}}</span>
26
- </div>
27
-
28
- <div
29
- class="deficiency title-block mt-3 ml-4"
30
- v-if="userData.user_deficiency"
31
- >
32
- <div class="d-flex align-items-center">
33
- <i class="fas fa-wheelchair"></i>
34
- <h6 class="mb-0 ml-2">Deficiência</h6>
35
- </div>
36
- <div class="line"></div>
37
- <p>
38
- {{ userData.user_deficiency.deficiency_id | allDeficiencies }} -
39
- {{ userData.user_deficiency.cid }}
40
- </p>
41
-
42
- <p v-show="userData.user_deficiency.appliance">
43
- Acessório: {{ userData.user_deficiency.appliance }}
44
- </p>
45
-
46
- <p v-show="userData.user_deficiency.apparatus">
47
- Necessidade: {{ userData.user_deficiency.apparatus }}
48
- </p>
49
-
50
- <p v-show="userData.user_deficiency.course">
51
- Curso: {{ userData.user_deficiency.course }}
52
- </p>
53
-
54
- <p v-show="userData.user_deficiency.note">
55
- Anotações: {{ userData.user_deficiency.note }}
56
- </p>
57
-
58
- <p v-show="userData.user_deficiency.transport === 1">
59
- Utiliza transporte coletivo
60
- </p>
61
-
62
- <p v-show="userData.user_deficiency.vehicle === 1">
63
- Possuí veículo adaptado
64
- </p>
65
-
66
- <p v-show="userData.user_deficiency.escort === 1">
67
- Precisa de acompanhante
68
- </p>
69
- </div>
70
-
71
- <div
72
- v-show="userData.user_desired_job.length > 0"
73
- class="desidered title-block mt-3 ml-4"
74
- >
75
- <h6 class="mb-0">Cargos desejados</h6>
76
- <div class="line"></div>
77
-
78
- <p
79
- v-for="(des, index) in userData.user_desired_job"
80
- :key="`skill-${index}`"
81
- class="ml-1 mt-1 mb-0 text-capitalize"
82
- v-html="highlightText(search, des.occupation)"
83
- ></p>
84
- </div>
85
-
86
- <div
87
- v-show="userData.user_language.length > 0"
88
- class="languages title-block mt-3 ml-4"
89
- >
90
- <h6 class="mb-0">Idiomas</h6>
91
- <div class="line"></div>
92
-
93
- <p
94
- class="mb-1 text-capitalize"
95
- v-for="(lan, index) in userData.user_language"
96
- :key="index"
97
- v-html="highlightText(search, `${lan.language[0].name} ${languageLevel(lan.level)}`)"
98
- ></p>
99
- </div>
100
-
101
- <div
102
- v-show="userData.user_skill.length > 0"
103
- class="skills title-block ml-4"
104
- >
105
- <h6 class="mb-0">Habilidades</h6>
106
- <div class="line"></div>
107
-
108
- <p
109
- v-for="(skill, index) in userData.user_skill"
110
- :key="`skill-${index}`"
111
- class="ml-1 mt-1 mb-0 text-capitalize"
112
- v-html="highlightText(search, skill.skill_word)"
113
- ></p>
114
- </div>
115
-
116
- <div class="socials text-center mt-5">
117
- <a
118
- :href="baseUrl + '/' + userData.slug.slug"
119
- class="text-center"
120
- target="_blank"
121
- rel="noopener noreferrer"
122
- >
123
- <img
124
- class="no-social"
125
- src="../../../../assets/images/burhCv.svg"
126
- alt="Burh"
127
- />
128
- </a>
129
- <a
130
- v-show="userData.user_complementary_information.facebook_url"
131
- :href="userData.user_complementary_information.facebook_url"
132
- target="_blank"
133
- class="ml-2"
134
- rel="noopener noreferrer"
135
- >
136
- <img
137
- class="no-social"
138
- src="../../../../assets/images/facebookCv.svg"
139
- alt="Facebook"
140
- />
141
- </a>
142
- <a
143
- v-show="userData.user_complementary_information.linkedin_url"
144
- :href="userData.user_complementary_information.linkedin_url"
145
- target="_blank"
146
- class="ml-2"
147
- rel="noopener noreferrer"
148
- >
149
- <img
150
- class="no-social"
151
- src="../../../../assets/images/linkedinCv.svg"
152
- alt="Linkdin"
153
- />
154
- </a>
155
- <a
156
- v-show="userData.user_complementary_information.website"
157
- :href="userData.user_complementary_information.website"
158
- class="text-center ml-2"
159
- target="_blank"
160
- rel="noopener noreferrer"
161
- >
162
- <img
163
- class="no-social"
164
- src="../../../../assets/images/webCv.svg"
165
- alt="Web"
166
- />
167
- </a>
168
- </div>
169
-
170
- <div class="burh-code text-center mt-4">
171
- <vue-qrcode
172
- :value="baseUrl + '/' + userData.slug.slug"
173
- :options="{ width: 98, height: 98 }"
174
- class="border qr-code"
175
- ></vue-qrcode>
176
- <p class="mb-0">Código BURH</p>
177
- <span class="qr-id">{{ userData.id }}</span><br>
178
- <div class="teste-block">
179
- <span
180
- class="font-weight-normal mt-2 d-block"
181
- v-if="!isLocked"
182
- >Data de atualização: {{$moment(userData.updated_at).format('DD/MM/YYYY H:mm')}}
183
- <!-- <template v-if="isLocked" @click="$emit('open-contact', isLocked)">
2
+ <div class="bg-white content-left">
3
+ <div class="profile w-100 text-center">
4
+ <div class="avatar">
5
+ <img
6
+ v-if="userData.urlAvatar"
7
+ :src="userData.urlAvatar"
8
+ :alt="userData.name"
9
+ />
10
+ <div v-else class="no-image">
11
+ {{ userData.name }}
12
+ </div>
13
+ </div>
14
+
15
+ <h5
16
+ class="mb-0 text-wrap"
17
+ :class="{ 'mt-5': !userData.urlAvatar }"
18
+ v-html="
19
+ highlightText(
20
+ search,
21
+ `${userData.name} ${userData.last_name}`
22
+ )
23
+ "
24
+ ></h5>
25
+
26
+ <p
27
+ class="user-info"
28
+ v-if="userData.user_experience.length > 0"
29
+ v-html="
30
+ highlightText(
31
+ search,
32
+ `${userData.user_experience[0].job_title} em ${userData.user_experience[0].company}`
33
+ )
34
+ "
35
+ ></p>
36
+
37
+ <span v-if="userData.user_address">
38
+ <i class="fas fa-map-marker-alt"></i>
39
+ {{ userData.user_address.city_name }} -
40
+ {{ userData.user_address.region_code }}
41
+ </span>
42
+ <br />
43
+ <span
44
+ v-if="
45
+ userData.user_complementary_information.wage_pretension > 1
46
+ "
47
+ >Pretensão salarial:
48
+ {{
49
+ userData.user_complementary_information.wage_pretension
50
+ | convertMoney
51
+ }}</span
52
+ >
53
+ </div>
54
+
55
+ <div
56
+ class="deficiency title-block mt-3 ml-4"
57
+ v-if="userData.user_deficiency"
58
+ >
59
+ <div class="d-flex align-items-center">
60
+ <i class="fas fa-wheelchair"></i>
61
+ <h6 class="mb-0 ml-2">Deficiência</h6>
62
+ </div>
63
+ <div class="line"></div>
64
+ <p>
65
+ {{ userData.user_deficiency.deficiency_id | allDeficiencies }} -
66
+ {{ userData.user_deficiency.cid }}
67
+ </p>
68
+
69
+ <p v-show="userData.user_deficiency.appliance">
70
+ Acessório: {{ userData.user_deficiency.appliance }}
71
+ </p>
72
+
73
+ <p v-show="userData.user_deficiency.apparatus">
74
+ Necessidade: {{ userData.user_deficiency.apparatus }}
75
+ </p>
76
+
77
+ <p v-show="userData.user_deficiency.course">
78
+ Curso: {{ userData.user_deficiency.course }}
79
+ </p>
80
+
81
+ <p v-show="userData.user_deficiency.note">
82
+ Anotações: {{ userData.user_deficiency.note }}
83
+ </p>
84
+
85
+ <p v-show="userData.user_deficiency.transport === 1">
86
+ Utiliza transporte coletivo
87
+ </p>
88
+
89
+ <p v-show="userData.user_deficiency.vehicle === 1">
90
+ Possuí veículo adaptado
91
+ </p>
92
+
93
+ <p v-show="userData.user_deficiency.escort === 1">
94
+ Precisa de acompanhante
95
+ </p>
96
+ </div>
97
+
98
+ <div
99
+ v-show="userData.user_desired_job.length > 0"
100
+ class="desidered title-block mt-3 ml-4"
101
+ >
102
+ <h6 class="mb-0">Cargos desejados</h6>
103
+ <div class="line"></div>
104
+
105
+ <p
106
+ v-for="(des, index) in userData.user_desired_job"
107
+ :key="`skill-${index}`"
108
+ class="ml-1 mt-1 mb-0 text-capitalize"
109
+ v-html="highlightText(search, des.occupation)"
110
+ ></p>
111
+ </div>
112
+
113
+ <div
114
+ v-show="userData.user_language.length > 0"
115
+ class="languages title-block mt-3 ml-4"
116
+ >
117
+ <h6 class="mb-0">Idiomas</h6>
118
+ <div class="line"></div>
119
+
120
+ <p
121
+ class="mb-1 text-capitalize"
122
+ v-for="(lan, index) in userData.user_language"
123
+ :key="index"
124
+ v-html="
125
+ highlightText(
126
+ search,
127
+ `${lan.language[0].name} ${languageLevel(lan.level)}`
128
+ )
129
+ "
130
+ ></p>
131
+ </div>
132
+
133
+ <div
134
+ v-show="userData.user_skill.length > 0"
135
+ class="skills title-block ml-4"
136
+ >
137
+ <h6 class="mb-0">Habilidades</h6>
138
+ <div class="line"></div>
139
+
140
+ <p
141
+ v-for="(skill, index) in userData.user_skill"
142
+ :key="`skill-${index}`"
143
+ class="ml-1 mt-1 mb-0 text-capitalize"
144
+ v-html="highlightText(search, skill.skill_word)"
145
+ ></p>
146
+ </div>
147
+
148
+ <div class="socials text-center mt-5">
149
+ <a
150
+ :href="baseUrl + '/' + userData.slug.slug"
151
+ class="text-center"
152
+ target="_blank"
153
+ rel="noopener noreferrer"
154
+ >
155
+ <img
156
+ class="no-social"
157
+ src="../../../../assets/images/burhCv.svg"
158
+ alt="Burh"
159
+ />
160
+ </a>
161
+ <a
162
+ v-show="userData.user_complementary_information.facebook_url"
163
+ :href="userData.user_complementary_information.facebook_url"
164
+ target="_blank"
165
+ class="ml-2"
166
+ rel="noopener noreferrer"
167
+ >
168
+ <img
169
+ class="no-social"
170
+ src="../../../../assets/images/facebookCv.svg"
171
+ alt="Facebook"
172
+ />
173
+ </a>
174
+ <a
175
+ v-show="userData.user_complementary_information.linkedin_url"
176
+ :href="userData.user_complementary_information.linkedin_url"
177
+ target="_blank"
178
+ class="ml-2"
179
+ rel="noopener noreferrer"
180
+ >
181
+ <img
182
+ class="no-social"
183
+ src="../../../../assets/images/linkedinCv.svg"
184
+ alt="Linkdin"
185
+ />
186
+ </a>
187
+ <a
188
+ v-show="userData.user_complementary_information.website"
189
+ :href="userData.user_complementary_information.website"
190
+ class="text-center ml-2"
191
+ target="_blank"
192
+ rel="noopener noreferrer"
193
+ >
194
+ <img
195
+ class="no-social"
196
+ src="../../../../assets/images/webCv.svg"
197
+ alt="Web"
198
+ />
199
+ </a>
200
+ </div>
201
+
202
+ <div class="burh-code text-center mt-4">
203
+ <vue-qrcode
204
+ :value="baseUrl + '/' + userData.slug.slug"
205
+ :options="{ width: 98, height: 98 }"
206
+ class="border qr-code"
207
+ ></vue-qrcode>
208
+ <p class="mb-0">Código BURH</p>
209
+ <span class="qr-id">{{ userData.id }}</span
210
+ ><br />
211
+ <div class="teste-block">
212
+ <span class="font-weight-normal mt-2 d-block" v-if="!isLocked"
213
+ >Data de atualização:
214
+ {{ $moment(userData.updated_at).format('DD/MM/YYYY H:mm') }}
215
+ <!-- <template v-if="isLocked" @click="$emit('open-contact', isLocked)">
184
216
  <i class="fa fa-lock"></i>
185
217
  </template>
186
218
  <template v-else>
187
219
  {{$moment(userData.updated_at).format('DD/MM/YYYY H:mm')}}
188
220
  </template> -->
189
- </span>
190
- </div>
191
- </div>
192
-
193
- </div>
221
+ </span>
222
+ </div>
223
+ </div>
224
+ </div>
194
225
  </template>
195
226
 
196
227
  <script>
@@ -199,134 +230,144 @@ import VueQrcode from '@chenfengyuan/vue-qrcode';
199
230
  import swal from 'sweetalert2';
200
231
 
201
232
  export default {
202
- name: 'user-cv-left-side',
203
- components: {
204
- VueQrcode,
205
-
206
- },
207
- computed: {
208
- currentCompany() {
209
- return this.$store.state.company.currentCompany;
210
- },
211
- },
212
- props: {
213
- userData: Object,
214
- baseUrl: String,
215
- search: {
216
- type: String,
217
- default: ''
218
- }
219
- },
220
- data() {
221
- return {
222
- isLocked: !this.companyHasProduct(
223
- this.$store.state.loja.showableProducts['BUSCA_AVANCADA']
224
- ),
225
- };
226
- },
227
- methods: {
228
- highlightText(search, text) {
229
- if (search.length < 2) return text;
230
-
231
- const regex = new RegExp(search.toLowerCase(), 'gmi');
232
- return String(text || '').replace(regex, `<span class="search-highlight">${search}</span>`);
233
- },
234
- getTime(
235
- { start_year = null, end_year = null, start_month, end_month },
236
- textHappening = 'Cursando'
237
- ) {
238
- const isHappening = !end_month && !end_year;
239
-
240
- if (isHappening) {
241
- return textHappening;
242
- }
243
-
244
- const dateInitial = this.$moment(
245
- ['1', start_month.toString(), start_year.toString()],
246
- 'DD/MM/YYYY'
247
- );
248
- const dateDone = this.$moment(
249
- ['1', end_month.toString(), end_year.toString()],
250
- 'DD/MM/YYYY'
251
- );
252
- const diffDuration = this.$moment.duration(
253
- dateDone.diff(dateInitial)
254
- );
255
- const years = diffDuration.years();
256
- const months = diffDuration.months();
257
-
258
- if (years) {
259
- return years > 1 ? `(${years} anos)` : `(${years} ano)`;
260
- }
261
-
262
- return months > 1
263
- ? `(${months} meses)`
264
- : months == 1
265
- ? `(${months} mês)`
266
- : '';
267
- },
268
- languageLevel(level) {
269
- switch (parseInt(level)) {
270
- case 1:
271
- return 'Iniciante';
272
- case 2:
273
- return 'Elementar';
274
- case 3:
275
- return 'Pré-intermediário';
276
- case 4:
277
- return 'Intermediário';
278
- case 5:
279
- return 'Intermediário Superior';
280
- case 6:
281
- return 'Avançado';
282
- case 7:
283
- return 'Fluente';
284
- default:
285
- return '';
286
- }
287
- },
288
- treatPhone(phone) {
289
- if (phone) {
290
- if (phone == '0' || phone.length < 9 || !phone) {
291
- return 'não cadastrado';
292
- }
293
- }
294
-
295
- return phone;
296
- },
297
- treatCellphone(cellphone) {
298
- if (cellphone) {
299
- if (cellphone == '0' || cellphone.length < 11 || !cellphone) {
300
- return 'não cadastrado';
301
- }
302
- }
303
-
304
- return cellphone;
305
- },
306
- handleGetPrefixes(name = '') {
307
- return getPrefixes(name);
308
- },
309
- treatEndDate(end_month, end_year) {
310
- if (end_month && end_year) {
311
- return `${end_month}/${end_year}`;
312
- }
313
- return '';
314
- }
315
- },
316
- filters: {
317
- allDeficiencies(id) {
318
- const typeDeficiency = {
319
- 1: 'Deficiência Física',
320
- 2: 'Deficiência Visual',
321
- 3: 'Deficiência Mental',
322
- 4: 'Deficiência Auditiva',
323
- 5: 'Deficiência Fonológica',
324
- 6: 'Deficiência Múltipla'
325
- };
326
-
327
- return typeDeficiency[id] || '-';
328
- }
329
- }
233
+ name: 'user-cv-left-side',
234
+ components: {
235
+ VueQrcode
236
+ },
237
+ computed: {
238
+ currentCompany() {
239
+ return this.$store.state.company.currentCompany;
240
+ }
241
+ },
242
+ props: {
243
+ userData: Object,
244
+ baseUrl: String,
245
+ search: {
246
+ type: String,
247
+ default: ''
248
+ }
249
+ },
250
+ data() {
251
+ return {
252
+ isLocked: !this.companyHasProduct(
253
+ this.$store.state.loja.showableProducts['BUSCA_AVANCADA']
254
+ )
255
+ };
256
+ },
257
+ methods: {
258
+ highlightText(search, text) {
259
+ if (search.length < 2) return text;
260
+
261
+ const regex = new RegExp(search.toLowerCase(), 'gmi');
262
+ return String(text || '').replace(
263
+ regex,
264
+ `<span class="search-highlight">${search}</span>`
265
+ );
266
+ },
267
+ getTime(
268
+ { start_year = null, end_year = null, start_month, end_month },
269
+ textHappening = 'Cursando'
270
+ ) {
271
+ const isHappening = !end_month && !end_year;
272
+
273
+ if (isHappening) {
274
+ return textHappening;
275
+ }
276
+
277
+ const dateInitial = this.$moment(
278
+ ['1', start_month.toString(), start_year.toString()],
279
+ 'DD/MM/YYYY'
280
+ );
281
+ const dateDone = this.$moment(
282
+ ['1', end_month.toString(), end_year.toString()],
283
+ 'DD/MM/YYYY'
284
+ );
285
+ const diffDuration = this.$moment.duration(
286
+ dateDone.diff(dateInitial)
287
+ );
288
+ const years = diffDuration.years();
289
+ const months = diffDuration.months();
290
+
291
+ if (years) {
292
+ return years > 1 ? `(${years} anos)` : `(${years} ano)`;
293
+ }
294
+
295
+ return months > 1
296
+ ? `(${months} meses)`
297
+ : months == 1
298
+ ? `(${months} mês)`
299
+ : '';
300
+ },
301
+ languageLevel(level) {
302
+ switch (parseInt(level)) {
303
+ case 1:
304
+ return 'Iniciante';
305
+ case 2:
306
+ return 'Elementar';
307
+ case 3:
308
+ return 'Pré-intermediário';
309
+ case 4:
310
+ return 'Intermediário';
311
+ case 5:
312
+ return 'Intermediário Superior';
313
+ case 6:
314
+ return 'Avançado';
315
+ case 7:
316
+ return 'Fluente';
317
+ default:
318
+ return '';
319
+ }
320
+ },
321
+ treatPhone(phone) {
322
+ if (phone) {
323
+ if (phone == '0' || phone.length < 9 || !phone) {
324
+ return 'não cadastrado';
325
+ }
326
+ }
327
+
328
+ return phone;
329
+ },
330
+ treatCellphone(cellphone) {
331
+ if (cellphone) {
332
+ if (cellphone == '0' || cellphone.length < 11 || !cellphone) {
333
+ return 'não cadastrado';
334
+ }
335
+ }
336
+
337
+ return cellphone;
338
+ },
339
+ handleGetPrefixes(name = '') {
340
+ return getPrefixes(name);
341
+ },
342
+ treatEndDate(end_month, end_year) {
343
+ if (end_month && end_year) {
344
+ return `${end_month}/${end_year}`;
345
+ }
346
+ return '';
347
+ }
348
+ },
349
+ filters: {
350
+ allDeficiencies(id) {
351
+ const typeDeficiency = {
352
+ 1: 'Deficiência Física',
353
+ 2: 'Deficiência Visual',
354
+ 3: 'Deficiência Mental',
355
+ 4: 'Deficiência Auditiva',
356
+ 5: 'Deficiência Fonológica',
357
+ 6: 'Deficiência Múltipla'
358
+ };
359
+
360
+ return typeDeficiency[id] || '-';
361
+ },
362
+ convertMoney(money) {
363
+ let moneyAux = parseFloat(money);
364
+ let m = moneyAux.toLocaleString('pt-BR', {
365
+ style: 'currency',
366
+ currency: 'BRL'
367
+ });
368
+ return m;
369
+ }
370
+ }
330
371
  };
331
372
  </script>
332
373
 
@@ -334,12 +375,12 @@ export default {
334
375
  @import '@burh/nuxt-core/assets/sass/burh-ds/variables/_colors.scss';
335
376
 
336
377
  /deep/ .search-highlight {
337
- background: rgb(255, 252, 61);
338
- color: #000;
378
+ background: rgb(255, 252, 61);
379
+ color: #000;
339
380
  }
340
381
 
341
- .teste-block{
342
- display: inline !important;
382
+ .teste-block {
383
+ display: inline !important;
343
384
  }
344
385
  .qr-id {
345
386
  color: #32325d !important;
@@ -351,7 +392,7 @@ export default {
351
392
 
352
393
  .profile {
353
394
  .avatar {
354
- background: transparent!important;
395
+ background: transparent !important;
355
396
  img {
356
397
  width: 178.14px;
357
398
  height: 163px;
@@ -61,8 +61,8 @@
61
61
  <h5 class="font-weight-bold mt-4 ml-3">Contatos</h5>
62
62
  <div class="ml-3 info-text">
63
63
  <span v-if="userData.email != null">Email: {{userData.email}}</span><br>
64
- <span v-if="userData.user_contact.cellphone != null && userData.user_contact.cellphone.length > 1 ">Celular: {{phoneMask(userData.user_contact.cellphone)}}</span><br>
65
- <span v-if="userData.user_contact.phone != null && userData.user_contact.phone.length > 1">Telefone: {{phoneMask(userData.user_contact.phone)}}</span>
64
+ <span v-if="userData.user_contact && userData.user_contact.cellphone != null && userData.user_contact.cellphone.length > 1 ">Celular: {{phoneMask(userData.user_contact.cellphone)}}</span><br>
65
+ <span v-if="userData.user_contact && userData.user_contact.phone != null && userData.user_contact.phone.length > 1">Telefone: {{phoneMask(userData.user_contact.phone)}}</span>
66
66
  </div>
67
67
 
68
68
  <!-- EDUCAÇÃO -->
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@burh/nuxt-core",
3
- "version": "1.0.295",
3
+ "version": "1.0.298",
4
4
  "description": "Design System and Components.",
5
5
  "author": "Burh",
6
6
  "scripts": {