@burh/nuxt-core 1.0.188 → 1.0.190

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.
@@ -111,11 +111,12 @@ $green: #2dce89 !default;
111
111
  $teal: #11cdef !default;
112
112
  $cyan: #2bffc6 !default;
113
113
  // NEW COLORS
114
- $search: #5983fe !default;
115
- $recruitment: #39e2fd !default;
116
- $university: #0c95fc !default;
114
+ $search: #1da1f1 !default;
115
+ $recruitment: #0c95fc !default;
116
+ $university: #39e2fd !default;
117
117
  $interviews: #ff539d !default;
118
118
  $workus: #ff7d7e !default;
119
+ $corp-university: #5983fe !default;
119
120
  $store: #9d35fc !default;
120
121
  $tests: #8be77a !default;
121
122
  $buffer: #ffacff !default;
@@ -147,6 +148,7 @@ $colors: map-merge(
147
148
  "university": $university,
148
149
  "interviews": $interviews,
149
150
  "workus": $workus,
151
+ "corp-university": $corp-university,
150
152
  "store": $store,
151
153
  "tests": $tests,
152
154
  "buffer": $buffer,
@@ -275,6 +275,7 @@ export default {
275
275
  height: 163px;
276
276
  top: 120;
277
277
  border-radius: 50%;
278
+ margin-bottom: 20px;
278
279
  }
279
280
  }
280
281
 
@@ -1,9 +1,9 @@
1
1
  <template>
2
2
  <div class="bg-white content-right tabs">
3
3
  <el-tabs
4
- :class="activeName"
4
+ :class="active"
5
5
  class="mt-3 ml-4 handle-icon-color"
6
- v-model="activeName"
6
+ v-model="active"
7
7
  >
8
8
  <el-tab-pane class="history" name="history">
9
9
  <span class="tab__icon" slot="label">
@@ -16,21 +16,20 @@
16
16
  <div class="line mb-3"></div>
17
17
 
18
18
  <div
19
- v-show="userData.user_applied_job.length > 0"
20
19
  class="mt-3"
21
- v-for="(applied, index) in userData.user_applied_job"
20
+ v-for="(item, index) in orderByDate(companyHistory())"
22
21
  :key="index"
23
22
  >
24
23
  <p class="history-text mb-0">
25
- Se candidatou na vaga {{ applied.job.title }}
24
+ {{item.text}}
26
25
  </p>
27
- <span>{{ applied.subscribe_at | convertDate }}</span>
26
+ <span>{{ item.date | convertDate }}</span>
28
27
  </div>
29
28
  <p
30
- v-show="userData.user_applied_job.length === 0"
29
+ v-show="companyHistory().length === 0"
31
30
  class="history-text"
32
31
  >
33
- Nenhuma vaga aplicada.
32
+ Histórico vazio.
34
33
  </p>
35
34
  </el-tab-pane>
36
35
 
@@ -141,9 +140,35 @@ export default {
141
140
  default: true
142
141
  }
143
142
  },
143
+ mounted(){
144
+ this.companyHistory();
145
+ },
144
146
  methods: {
145
147
  cleatInput() {
146
148
  this.newNote = '';
149
+ },
150
+ companyHistory(){
151
+ let sms = this.userData.company_sms.map(x => ({ 'date': x.created_at, 'text': 'Recebeu um SMS' }));
152
+ let tests = this.userData.tests.map(x => ({ 'date': x.finished_at, 'text': `Finalizou o teste ${x.test.name.toUpperCase()}` }));
153
+ let discs = this.userData.solides.map(x => ({ 'date': x.end, 'text': 'Realizou um teste DISC' }));
154
+
155
+ return sms.concat(tests, discs);
156
+ },
157
+ orderByDate(data) {
158
+ let sortedArray = data.sort((a, b) => {
159
+ a = [
160
+ a.date || '2020/01/01'
161
+ ];
162
+
163
+ b = [
164
+ b.date || '2020/01/01'
165
+ ];
166
+
167
+ return (new Date(b) - new Date(a));
168
+
169
+ });
170
+
171
+ return sortedArray;
147
172
  }
148
173
  },
149
174
  data() {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@burh/nuxt-core",
3
- "version": "1.0.188",
3
+ "version": "1.0.190",
4
4
  "description": "Design System and Components.",
5
5
  "author": "Burh",
6
6
  "scripts": {