Skip to content
Snippets Groups Projects
Commit 7c3c4cc0 authored by poka's avatar poka Committed by Pierre-Jean CHANCELLIER
Browse files

Add certifications numbers

parent 92c84fe3
No related branches found
No related tags found
No related merge requests found
......@@ -37,6 +37,7 @@ build/Release
# Dependency directories
node_modules/
jspm_packages/
package-lock.json
# TypeScript v1 declaration files
typings/
......
......@@ -3,6 +3,9 @@
## Build Setup
```bash
# use node 16
$ nvm use 16
# install dependencies
$ npm install
......
......@@ -39,14 +39,7 @@ export default {
},
getMediaPreference() {
const hasDarkPreference = window.matchMedia(
"(prefers-color-scheme: dark)"
).matches;
if (hasDarkPreference) {
return "dark-theme";
} else {
return "light-theme";
}
return localStorage.getItem("user-theme");
},
},
};
......
......@@ -27,14 +27,14 @@ export default {
type: String,
required: true,
validator: function (value) {
const types = ['recieved','sent']
const types = ['received','sent']
return types.indexOf(value) !== -1
}
}
},
methods : {
getNeighbor(certif) {
return this.type == "recieved" ? certif.from : certif.to
return this.type == "received" ? certif.from : certif.to
}
},
computed : {
......
This diff is collapsed.
......@@ -13,13 +13,13 @@
</div>
<div class="row mt-3" v-if="idFromHash.status != 'REVOKED'">
<div class="col-12 col-md-6 mb-3">
<h3>{{ $t('certifications.recues') }}
<h3>{{ $t('certifications.recues') }} ({{ idFromHash.received_certifications.certifications.length }})
<BadgeCertifStatus :limitDate="idFromHash.received_certifications.limit" :memberStatus="idFromHash.status" />
</h3>
<CertifList :certifs="idFromHash.received_certifications.certifications" type="recieved" />
<CertifList :certifs="idFromHash.received_certifications.certifications" type="received" />
</div>
<div class="col-12 col-md-6">
<h3>{{ $t('certifications.envoyees') }}</h3>
<h3>{{ $t('certifications.envoyees') }} ({{ idFromHash.sent_certifications.length }})</h3>
<CertifList :certifs="idFromHash.sent_certifications" type="sent" />
</div>
</div>
......@@ -30,8 +30,10 @@
<script>
import {SEARCH_MEMBER} from "@/graphql/queries"
import CertifStatus from '~/components/badge/CertifStatus.vue';
export default {
components: { CertifStatus },
data() {
// Variables locales
return {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment