Merge branch 'master' into update-admin-yarn-lock

This commit is contained in:
elweyn 2023-01-23 10:57:31 +01:00
commit 5fa6afbd90
27 changed files with 174 additions and 118 deletions

View File

@ -35,7 +35,6 @@ jobs:
build_test_admin: build_test_admin:
name: Docker Build Test - Admin Interface name: Docker Build Test - Admin Interface
runs-on: ubuntu-latest runs-on: ubuntu-latest
#needs: [nothing]
steps: steps:
########################################################################## ##########################################################################
# CHECKOUT CODE ########################################################## # CHECKOUT CODE ##########################################################
@ -437,7 +436,7 @@ jobs:
report_name: Coverage Frontend report_name: Coverage Frontend
type: lcov type: lcov
result_path: ./coverage/lcov.info result_path: ./coverage/lcov.info
min_coverage: 92 min_coverage: 93
token: ${{ github.token }} token: ${{ github.token }}
############################################################################## ##############################################################################

View File

@ -4,8 +4,24 @@ All notable changes to this project will be documented in this file. Dates are d
Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog). Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
#### [1.17.1](https://github.com/gradido/gradido/compare/1.17.0...1.17.1)
- refactor(frontend): change contribution memo add word-break [`#2583`](https://github.com/gradido/gradido/pull/2583)
- refactor(admin): add text-break on all table memo fields [`#2584`](https://github.com/gradido/gradido/pull/2584)
- fix(frontend): throw proper frontend warning errors [`#2586`](https://github.com/gradido/gradido/pull/2586)
- refactor(frontend): equalize en with fr languages. [`#2585`](https://github.com/gradido/gradido/pull/2585)
- refactor(frontend): forgot password unit tests [`#2582`](https://github.com/gradido/gradido/pull/2582)
- fix(frontend): fix min value for hours input [`#2581`](https://github.com/gradido/gradido/pull/2581)
- fix(frontend): change dropdown placement calender no-flip true [`#2580`](https://github.com/gradido/gradido/pull/2580)
- refactor(frontend): link send result style [`#2577`](https://github.com/gradido/gradido/pull/2577)
- refactor(frontend): remove vertical scrolling & small fixes [`#2578`](https://github.com/gradido/gradido/pull/2578)
- refactor(frontend): tyle mobile device auth template [`#2576`](https://github.com/gradido/gradido/pull/2576)
#### [1.17.0](https://github.com/gradido/gradido/compare/1.16.0...1.17.0) #### [1.17.0](https://github.com/gradido/gradido/compare/1.16.0...1.17.0)
> 18 January 2023
- chore(release): v1.17.0 [`#2575`](https://github.com/gradido/gradido/pull/2575)
- fix(frontend): submit contribution text [`#2573`](https://github.com/gradido/gradido/pull/2573) - fix(frontend): submit contribution text [`#2573`](https://github.com/gradido/gradido/pull/2573)
- fix(backend): admin cannot delete confirmed contribution [`#2571`](https://github.com/gradido/gradido/pull/2571) - fix(backend): admin cannot delete confirmed contribution [`#2571`](https://github.com/gradido/gradido/pull/2571)
- fix(frontend): english locales - horas -> hours [`#2572`](https://github.com/gradido/gradido/pull/2572) - fix(frontend): english locales - horas -> hours [`#2572`](https://github.com/gradido/gradido/pull/2572)

View File

@ -3,7 +3,7 @@
"description": "Administraion Interface for Gradido", "description": "Administraion Interface for Gradido",
"main": "index.js", "main": "index.js",
"author": "Moriz Wahl", "author": "Moriz Wahl",
"version": "1.17.0", "version": "1.17.1",
"license": "Apache-2.0", "license": "Apache-2.0",
"private": false, "private": false,
"scripts": { "scripts": {

View File

@ -88,7 +88,7 @@ export default {
return `${value} GDD` return `${value} GDD`
}, },
}, },
{ key: 'memo', label: this.$t('transactionlist.memo') }, { key: 'memo', label: this.$t('transactionlist.memo'), class: 'text-break' },
], ],
} }
}, },

View File

@ -57,7 +57,7 @@ const propsData = {
return value + ' GDD' return value + ' GDD'
}, },
}, },
{ key: 'memo', label: 'text' }, { key: 'memo', label: 'text', class: 'text-break' },
{ {
key: 'date', key: 'date',
label: 'date', label: 'date',

View File

@ -67,7 +67,7 @@ export default {
return `${value} GDD` return `${value} GDD`
}, },
}, },
{ key: 'memo', label: this.$t('transactionlist.memo') }, { key: 'memo', label: this.$t('transactionlist.memo'), class: 'text-break' },
{ {
key: 'validUntil', key: 'validUntil',
label: this.$t('transactionlink.valid_until'), label: this.$t('transactionlink.valid_until'),

View File

@ -99,7 +99,7 @@ export default {
return value + ' GDD' return value + ' GDD'
}, },
}, },
{ key: 'memo', label: this.$t('text') }, { key: 'memo', label: this.$t('text'), class: 'text-break' },
{ {
key: 'date', key: 'date',
label: this.$t('date'), label: this.$t('date'),

View File

@ -1,6 +1,6 @@
{ {
"name": "gradido-backend", "name": "gradido-backend",
"version": "1.17.0", "version": "1.17.1",
"description": "Gradido unified backend providing an API-Service for Gradido Transactions", "description": "Gradido unified backend providing an API-Service for Gradido Transactions",
"main": "src/index.ts", "main": "src/index.ts",
"repository": "https://github.com/gradido/gradido/backend", "repository": "https://github.com/gradido/gradido/backend",

View File

@ -1,6 +1,6 @@
{ {
"name": "gradido-database", "name": "gradido-database",
"version": "1.17.0", "version": "1.17.1",
"description": "Gradido Database Tool to execute database migrations", "description": "Gradido Database Tool to execute database migrations",
"main": "src/index.ts", "main": "src/index.ts",
"repository": "https://github.com/gradido/gradido/database", "repository": "https://github.com/gradido/gradido/database",

View File

@ -1,6 +1,6 @@
{ {
"name": "bootstrap-vue-gradido-wallet", "name": "bootstrap-vue-gradido-wallet",
"version": "1.17.0", "version": "1.17.1",
"private": true, "private": true,
"scripts": { "scripts": {
"start": "node run/server.js", "start": "node run/server.js",

View File

@ -18,7 +18,7 @@
"date": "01 janvier 2023", "date": "01 janvier 2023",
"text": "Compte Gradido 2023 : nouveau design et communautés décentralisées", "text": "Compte Gradido 2023 : nouveau design et communautés décentralisées",
"url": "https://gradido.net/fr/gradido-konto-2023-neues-design-und-dezentrale-communities/", "url": "https://gradido.net/fr/gradido-konto-2023-neues-design-und-dezentrale-communities/",
"extra": "Ce sont souvent les personnes les plus discrètes qui créent silencieusement, avec application et passion, les bases de grands développements. Notre site Développeur ont effectué ces derniers mois un travail préparatoire formidable qui sera mis à profit en 2023." "extra": "Ce sont souvent les personnes les plus discrètes qui créent silencieusement, avec application et passion, les bases de grands développements. Nos développeurs ont effectués ces derniers mois un travail préparatoire formidable qui sera mis à profit en 2023."
}, },
{ {
"locale": "es", "locale": "es",

View File

@ -1,17 +1,31 @@
<template> <template>
<div class="clipboard-copy"> <div class="clipboard-copy">
<div v-if="canCopyLink" size="lg" class="mb-5"> <div v-if="canCopyLink" class="mb-5">
<div class="d-flex"> <div>
<div> <label>{{ $t('gdd_per_link.copy-link') }}</label>
<label>{{ $t('gdd_per_link.copy-link') }}</label> <div
<div class="pointer text-center bg-secondary gradido-border-radius p-4" @click="copyLink"> class="pointer text-center bg-secondary gradido-border-radius p-3"
{{ link }} @click="copyLink"
data-test="copyLink"
>
{{ link }}
<div>
<b-button class="p-4">
<b-icon icon="link45deg"></b-icon>
</b-button>
</div> </div>
</div> </div>
<div class="ml-5"> </div>
<label>{{ $t('gdd_per_link.copy-link-with-text') }}</label> <div class="mt-5">
<label>{{ $t('gdd_per_link.copy-link-with-text') }}</label>
<div
class="pointer text-center bg-secondary gradido-border-radius p-3"
data-test="copyLinkWithText"
@click="copyLinkWithText"
>
{{ linkText }}
<div> <div>
<b-button @click="copyLinkWithText" class="p-4"> <b-button class="p-4">
<b-icon icon="link45deg"></b-icon> <b-icon icon="link45deg"></b-icon>
</b-button> </b-button>
</div> </div>

View File

@ -17,7 +17,7 @@
:label-no-date-selected="$t('contribution.noDateSelected')" :label-no-date-selected="$t('contribution.noDateSelected')"
required required
:disabled="this.form.id !== null" :disabled="this.form.id !== null"
:dropleft="true" :no-flip="true"
> >
<template #nav-prev-year><span></span></template> <template #nav-prev-year><span></span></template>
<template #nav-next-year><span></span></template> <template #nav-next-year><span></span></template>
@ -35,12 +35,12 @@
v-model="form.hours" v-model="form.hours"
:name="$t('form.hours')" :name="$t('form.hours')"
:label="$t('form.hours')" :label="$t('form.hours')"
placeholder="0.5" placeholder="0.25"
:rules="{ :rules="{
required: true, required: true,
min: 0.5, min: 0.25,
max: validMaxTime, max: validMaxTime,
gddCreationTime: [0.5, validMaxTime], gddCreationTime: [0.25, validMaxTime],
}" }"
:validMaxTime="validMaxTime" :validMaxTime="validMaxTime"
@updateAmount="updateAmount" @updateAmount="updateAmount"

View File

@ -16,12 +16,15 @@
<b-avatar v-else :icon="icon" :variant="variant" size="3em"></b-avatar> <b-avatar v-else :icon="icon" :variant="variant" size="3em"></b-avatar>
</b-col> </b-col>
<b-col> <b-col>
<div v-if="firstName" class="mr-3 font-weight-bold">{{ firstName }} {{ lastName }}</div> <div v-if="firstName" class="mr-3 font-weight-bold">
{{ firstName }} {{ lastName }}
<b-icon :icon="icon" :variant="variant"></b-icon>
</div>
<div class="small"> <div class="small">
{{ $d(new Date(contributionDate), 'monthAndYear') }} {{ $d(new Date(contributionDate), 'monthAndYear') }}
</div> </div>
<div class="mt-3 font-weight-bold">{{ $t('contributionText') }}</div> <div class="mt-3 font-weight-bold">{{ $t('contributionText') }}</div>
<div class="mb-3">{{ memo }}</div> <div class="mb-3 text-break word-break">{{ memo }}</div>
<div v-if="state === 'IN_PROGRESS'" class="text-205"> <div v-if="state === 'IN_PROGRESS'" class="text-205">
{{ $t('contribution.alert.answerQuestion') }} {{ $t('contribution.alert.answerQuestion') }}
</div> </div>

View File

@ -10,6 +10,12 @@ const mocks = {
$tc: jest.fn((tc) => tc), $tc: jest.fn((tc) => tc),
$t: jest.fn((t) => t), $t: jest.fn((t) => t),
$d: jest.fn((d) => d), $d: jest.fn((d) => d),
$store: {
state: {
firstName: 'Bibi',
lastName: 'Bloxberg',
},
},
} }
const propsData = { const propsData = {

View File

@ -7,6 +7,7 @@
:memo="memo" :memo="memo"
:validUntil="validUntil" :validUntil="validUntil"
></clipboard-copy> ></clipboard-copy>
<label>{{ $t('qrCode') }}</label>
<div class="text-center"> <div class="text-center">
<div><figure-qr-code :link="link" /></div> <div><figure-qr-code :link="link" /></div>
<div> <div>

View File

@ -18,6 +18,7 @@
rows="4" rows="4"
max-rows="4" max-rows="4"
:disabled="disabled" :disabled="disabled"
no-resize
></b-form-textarea> ></b-form-textarea>
<b-form-invalid-feedback v-bind="ariaMsg"> <b-form-invalid-feedback v-bind="ariaMsg">
{{ errors[0] }} {{ errors[0] }}

View File

@ -17,6 +17,12 @@ const mocks = {
$apollo: { $apollo: {
query: apolloQueryMock, query: apolloQueryMock,
}, },
$store: {
state: {
firstName: 'Bibi',
lastName: 'Bloxberg',
},
},
} }
const propsData = { const propsData = {
@ -102,10 +108,10 @@ describe('TransactionLinkSummary', () => {
describe('click on transaction links', () => { describe('click on transaction links', () => {
beforeEach(async () => { beforeEach(async () => {
wrapper.find('div.transaction-slot-link').trigger('click') wrapper.find('div.row').trigger('click')
}) })
it.skip('calls the API to get the list transaction links', () => { it('calls the API to get the list transaction links', () => {
expect(apolloQueryMock).toBeCalledWith({ expect(apolloQueryMock).toBeCalledWith({
query: listTransactionLinks, query: listTransactionLinks,
variables: { variables: {
@ -115,14 +121,14 @@ describe('TransactionLinkSummary', () => {
}) })
}) })
it.skip('has four transactionLinks', () => { it('has four transactionLinks', () => {
expect(wrapper.vm.transactionLinks).toHaveLength(4) expect(wrapper.vm.transactionLinks).toHaveLength(4)
}) })
describe('close transaction link details', () => { describe('close transaction link details', () => {
beforeEach(() => { beforeEach(() => {
jest.clearAllMocks() jest.clearAllMocks()
wrapper.find('div.transaction-slot-link').trigger('click') wrapper.find('div.row').trigger('click')
}) })
it('does not call the API', () => { it('does not call the API', () => {
@ -136,10 +142,10 @@ describe('TransactionLinkSummary', () => {
describe('reopen transaction link details', () => { describe('reopen transaction link details', () => {
beforeEach(() => { beforeEach(() => {
jest.clearAllMocks() jest.clearAllMocks()
wrapper.find('div.transaction-slot-link').trigger('click') wrapper.find('div.row').trigger('click')
}) })
it.skip('calls the API to get the list transaction links', () => { it('calls the API to get the list transaction links', () => {
expect(apolloQueryMock).toBeCalledWith({ expect(apolloQueryMock).toBeCalledWith({
query: listTransactionLinks, query: listTransactionLinks,
variables: { variables: {
@ -149,7 +155,7 @@ describe('TransactionLinkSummary', () => {
}) })
}) })
it.skip('has four transactionLinks', () => { it('has four transactionLinks', () => {
expect(wrapper.vm.transactionLinks).toHaveLength(4) expect(wrapper.vm.transactionLinks).toHaveLength(4)
}) })
}) })
@ -215,7 +221,7 @@ describe('TransactionLinkSummary', () => {
}) })
it('has eight transactionLinks', () => { it('has eight transactionLinks', () => {
expect(wrapper.vm.transactionLinks).toHaveLength(4) expect(wrapper.vm.transactionLinks).toHaveLength(8)
}) })
it('loads more transaction links', () => { it('loads more transaction links', () => {
@ -230,19 +236,19 @@ describe('TransactionLinkSummary', () => {
describe('close transaction link list', () => { describe('close transaction link list', () => {
beforeEach(async () => { beforeEach(async () => {
wrapper.find('div.transaction-slot-link').trigger('click') wrapper.find('div.row').trigger('click')
}) })
describe('reopen transaction link list', () => { describe('reopen transaction link list', () => {
beforeEach(async () => { beforeEach(async () => {
jest.clearAllMocks() jest.clearAllMocks()
wrapper.find('div.transaction-slot-link').trigger('click') wrapper.find('div.row').trigger('click')
}) })
it.skip('calls the API once', () => { it('calls the API once', () => {
expect(apolloQueryMock).toBeCalledTimes(1) expect(apolloQueryMock).toBeCalledTimes(1)
}) })
it.skip('calls the API with current page one', () => { it('calls the API with current page one', () => {
expect(apolloQueryMock).toBeCalledWith({ expect(apolloQueryMock).toBeCalledWith({
query: listTransactionLinks, query: listTransactionLinks,
variables: { variables: {
@ -289,10 +295,10 @@ describe('TransactionLinkSummary', () => {
}) })
}) })
describe.skip('loads transaction links with error', () => { describe('loads transaction links with error', () => {
beforeEach(() => { beforeEach(() => {
apolloQueryMock.mockRejectedValue({ message: 'OUCH!' }) apolloQueryMock.mockRejectedValue({ message: 'OUCH!' })
wrapper.find('div.transaction-slot-link').trigger('click') wrapper.find('div.row').trigger('click')
}) })
it('toasts an error message', () => { it('toasts an error message', () => {

View File

@ -37,7 +37,8 @@
"contribution": { "contribution": {
"activity": "Tätigkeit", "activity": "Tätigkeit",
"alert": { "alert": {
"answerQuestion": "Bitte beantworte die Rückfrage!", "answerQuestion": "Bitte beantworte diese Rückfrage.",
"answerQuestionToast": "Du hast eine Rückfrage auf einen Beitrag. Bitte antworte auf diese.",
"communityNoteList": "Hier findest du alle eingereichten und bestätigten Beiträge von allen Mitgliedern aus dieser Gemeinschaft.", "communityNoteList": "Hier findest du alle eingereichten und bestätigten Beiträge von allen Mitgliedern aus dieser Gemeinschaft.",
"confirm": "bestätigt", "confirm": "bestätigt",
"deleted": "gelöscht", "deleted": "gelöscht",

View File

@ -37,7 +37,8 @@
"contribution": { "contribution": {
"activity": "Activity", "activity": "Activity",
"alert": { "alert": {
"answerQuestion": "Please answer the question", "answerQuestion": "Please answer the question.",
"answerQuestionToast": "You have a question about a post. Please reply to it.",
"communityNoteList": "Here you will find all submitted and confirmed contributions from all members of this community.", "communityNoteList": "Here you will find all submitted and confirmed contributions from all members of this community.",
"confirm": "confirmed", "confirm": "confirmed",
"deleted": "deleted", "deleted": "deleted",

View File

@ -1,4 +1,6 @@
{ {
"(": "(",
")": ")",
"100": "100%", "100": "100%",
"1000thanks": "1000 mercis d'être avec nous!", "1000thanks": "1000 mercis d'être avec nous!",
"125": "125%", "125": "125%",
@ -20,25 +22,25 @@
"community": { "community": {
"choose-another-community": "Choisissez une autre communauté", "choose-another-community": "Choisissez une autre communauté",
"community": "Communauté", "community": "Communauté",
"communityMember": "Vous etes un membre actif",
"continue-to-registration": "Continuez l´inscription", "continue-to-registration": "Continuez l´inscription",
"current-community": "Communauté actuelle",
"members": "Membres",
"moderator": "Modérateur", "moderator": "Modérateur",
"moderators": "Modérateurs", "moderators": "Modérateurs",
"myContributions": "Mes contributions aux biens communs", "myContributions": "Mes contributions",
"noOpenContributionLinkText": "Currently there are no automatic creations.",
"openContributionLinks": "liste de liens de contribution publique", "openContributionLinks": "liste de liens de contribution publique",
"openContributionLinkText": "Les {count} créations automatiques suivantes sont actuellement fournies par la communauté \"{name}\".", "openContributionLinkText": "Les {count} créations automatiques suivantes sont actuellement fournies par la communauté \"{name}\".",
"other-communities": "Autres communautés", "submitContribution": "Contribuer"
"statistic": "Statistiques",
"submitContribution": "écrire",
"switch-to-this-community": "Passer à cette communauté"
}, },
"communityInfo": "Information communauté^^",
"contact": "Contact",
"contribution": { "contribution": {
"activity": "Activité", "activity": "Activité",
"alert": { "alert": {
"answerQuestion": "S'il te plais répond à la question", "answerQuestion": "S'il te plais répond à la question",
"communityNoteList": "Vous trouverez ci-contre toutes les contributions versées et certifiées de tous les membres de cette communauté.", "communityNoteList": "Vous trouverez ci-contre toutes les contributions versées et certifiées de tous les membres de cette communauté.",
"confirm": " Approuvé", "confirm": "Approuvé",
"deleted": "Supprimé",
"in_progress": "Il y a une question du modérateur.", "in_progress": "Il y a une question du modérateur.",
"myContributionNoteList": "À tout moment vous pouvez éditer ou supprimer les données qui n´ont pas été confirmées.", "myContributionNoteList": "À tout moment vous pouvez éditer ou supprimer les données qui n´ont pas été confirmées.",
"pending": "Inscription en attente de validation", "pending": "Inscription en attente de validation",
@ -65,6 +67,8 @@
"thanksYouWith": "vous remercie avec", "thanksYouWith": "vous remercie avec",
"unique": "(unique)" "unique": "(unique)"
}, },
"contributionText": "Texte de la contribution",
"creation": "Création",
"decay": { "decay": {
"before_startblock_transaction": "Cette transaction n´est pas péremptoire.", "before_startblock_transaction": "Cette transaction n´est pas péremptoire.",
"calculation_decay": "Calcul de la décroissance", "calculation_decay": "Calcul de la décroissance",
@ -84,6 +88,7 @@
} }
}, },
"delete": "Supprimer", "delete": "Supprimer",
"edit": "modifier",
"em-dash": "—", "em-dash": "—",
"error": { "error": {
"email-already-sent": "Nous vous avons déjà envoyé un email il y a moins de 10 minutes.", "email-already-sent": "Nous vous avons déjà envoyé un email il y a moins de 10 minutes.",
@ -121,7 +126,7 @@
"firstname": " Prénom", "firstname": " Prénom",
"from": "de", "from": "de",
"generate_now": "Produire maintenant", "generate_now": "Produire maintenant",
"hours": "Uren", "hours": "Heures",
"lastname": "Nom", "lastname": "Nom",
"memo": "Note", "memo": "Note",
"message": "Message", "message": "Message",
@ -147,7 +152,8 @@
"to": "à", "to": "à",
"to1": "à", "to1": "à",
"validation": { "validation": {
"gddSendAmount": "L´espace {_field_} doit comprendre un nombre entre {min} et {max} avec un maximum de deux chiffres après la virgule", "gddCreationTime": "Le champ {_field_} doit comprendre un nombre entre {min} et {max} avec un maximum de une décimale.",
"gddSendAmount": "Le champ {_field_} doit comprendre un nombre entre {min} et {max} avec un maximum de deux chiffres après la virgule",
"is-not": "Vous ne pouvez pas vous envoyer de Gradido à vous-même", "is-not": "Vous ne pouvez pas vous envoyer de Gradido à vous-même",
"usernmae-regex": "Le nom d´utilisateur doit commencer par une lettre, suivi d´au moins deux caractères alphanumériques.", "usernmae-regex": "Le nom d´utilisateur doit commencer par une lettre, suivi d´au moins deux caractères alphanumériques.",
"usernmae-unique": "Ce nom d´utilisateur est déjà pris." "usernmae-unique": "Ce nom d´utilisateur est déjà pris."
@ -155,13 +161,13 @@
"your_amount": "Votre montant" "your_amount": "Votre montant"
}, },
"GDD": "GDD", "GDD": "GDD",
"gddKonto": "Compte GDD",
"gdd_per_link": { "gdd_per_link": {
"choose-amount": "Sélectionnez le montant que vous souhaitez envoyer via lien. Vous pouvez également joindre un message. Cliquez sur créer maintenant pour établir un lien que vous pourrez partager.", "choose-amount": "Sélectionnez le montant que vous souhaitez envoyer via lien. Vous pouvez également joindre un message. Cliquez sur créer maintenant pour établir un lien que vous pourrez partager.",
"copy-link": "Copier le lien", "copy-link": "Copier le lien",
"copy-link-with-text": "Copier le lien et le texte", "copy-link-with-text": "Copier le lien et le texte",
"created": "Le lien a été créé!", "created": "Le lien a été créé!",
"credit-your-gradido": "Pour l´accréditation du Gradido, cliquer sur le lien!", "credit-your-gradido": "Pour l´accréditation du Gradido, cliquer sur le lien!",
"decay-14-day": "Perte sur 14 jours",
"delete-the-link": "Supprimer le lien?", "delete-the-link": "Supprimer le lien?",
"deleted": "Le lien a été supprimé!", "deleted": "Le lien a été supprimé!",
"expiredOn": "A expiré le", "expiredOn": "A expiré le",
@ -188,6 +194,7 @@
"validUntil": "Valide jusqu´au", "validUntil": "Valide jusqu´au",
"validUntilDate": "Le lien est valide jusqu´au {date}." "validUntilDate": "Le lien est valide jusqu´au {date}."
}, },
"GDT": "GDT",
"gdt": { "gdt": {
"calculation": "Calcul de Gradido Transform", "calculation": "Calcul de Gradido Transform",
"contribution": "Contribution", "contribution": "Contribution",
@ -199,22 +206,25 @@
"funding": "Aux contributions au financement", "funding": "Aux contributions au financement",
"gdt": "Gradido Transform", "gdt": "Gradido Transform",
"gdt-received": "Gradido Transform (GDT) perçu", "gdt-received": "Gradido Transform (GDT) perçu",
"gdtKonto": "Compte GDT",
"no-transactions": "Vous ne possédez pas encore Gradido Transform (GDT).", "no-transactions": "Vous ne possédez pas encore Gradido Transform (GDT).",
"not-reachable": "Le Serveur GDT n´est pas accessible.", "not-reachable": "Le Serveur GDT n´est pas accessible.",
"publisher": "Un membre que vous avez référé a apporté un contribution", "publisher": "Un membre que vous avez référé a apporté un contribution",
"raise": "Augmentation", "raise": "Augmentation",
"recruited-member": "Membre invité" "recruited-member": "Membre invité"
}, },
"h": "h",
"language": "Langage", "language": "Langage",
"link-load": "Enregistrer le dernier lien | Enregistrer les derniers {n} liens | Enregistrer plus de {n} liens", "link-load": "Enregistrer le dernier lien | Enregistrer les derniers {n} liens | Enregistrer plus de {n} liens",
"login": "Connexion", "login": "Connexion",
"math": { "math": {
"aprox": "~",
"asterisk": "*", "asterisk": "*",
"equal": "=", "equal": "=",
"minus": "", "minus": "",
"pipe": "|" "pipe": "|"
}, },
"maxReached": "Max. atteint",
"member": "Membre",
"message": { "message": {
"activateEmail": "Votre compte n´a pas encore été activé. Veuillez vérifier vos emails et cliquer sur le lien d´activation ou faites la demande d´un nouveau lien en utilisant la page qui permet de générer un nouveau mot de passe.", "activateEmail": "Votre compte n´a pas encore été activé. Veuillez vérifier vos emails et cliquer sur le lien d´activation ou faites la demande d´un nouveau lien en utilisant la page qui permet de générer un nouveau mot de passe.",
"checkEmail": "Votre email a bien été vérifié. Vous pouvez vous enregistrer maintenant.", "checkEmail": "Votre email a bien été vérifié. Vous pouvez vous enregistrer maintenant.",
@ -231,13 +241,22 @@
"community": "Communauté", "community": "Communauté",
"info": "Information", "info": "Information",
"logout": "Déconnexion", "logout": "Déconnexion",
"members_area": "Partie réservée aux membres",
"overview": "Aperçu", "overview": "Aperçu",
"profile": "Mon profile",
"send": "Envoyer", "send": "Envoyer",
"settings": "Configuration",
"support": "Aide", "support": "Aide",
"transactions": "Transactions" "transactions": "Transactions"
}, },
"openHours": "Heures ouverte",
"pageTitle": {
"community": "Ma communauté",
"gdt": "Vos transactions GDT",
"information": "{community}",
"overview": "Bienvenue {name}",
"send": "Envoyé Gradidos",
"settings": "Configuration",
"transactions": "Vos transactions"
},
"qrCode": "QR Code", "qrCode": "QR Code",
"send_gdd": "Envoyer GDD", "send_gdd": "Envoyer GDD",
"send_per_link": "Envoyer GDD via lien", "send_per_link": "Envoyer GDD via lien",
@ -248,6 +267,8 @@
"warningText": "Êtes-vous toujours connecté?" "warningText": "Êtes-vous toujours connecté?"
}, },
"settings": { "settings": {
"hideAmountGDD": "Votre montant GDD est caché.",
"hideAmountGDT": "Votre montant GDT est caché.",
"language": { "language": {
"changeLanguage": "Changer la langue", "changeLanguage": "Changer la langue",
"de": "Deutsch", "de": "Deutsch",
@ -280,7 +301,9 @@
"text": "Sauvegardez votre nouveau mot de passe maintenant, que vous pourrez utiliser pour vous connecter à votre compte Gradido dans le futur." "text": "Sauvegardez votre nouveau mot de passe maintenant, que vous pourrez utiliser pour vous connecter à votre compte Gradido dans le futur."
}, },
"subtitle": "Si vous avez oublié votre mot de passe, vous pouvez le réinitialiser ici." "subtitle": "Si vous avez oublié votre mot de passe, vous pouvez le réinitialiser ici."
} },
"showAmountGDD": "Votre montant GDD est visible.",
"showAmountGDT": "Votre montant GDT est visible."
}, },
"signin": "S´identifier", "signin": "S´identifier",
"signup": "S´inscrire", "signup": "S´inscrire",
@ -302,11 +325,8 @@
"uppercase": "Une lettre majuscule requise." "uppercase": "Une lettre majuscule requise."
} }
}, },
"statistic": { "status": "Statu",
"totalGradidoAvailable": "GDD total en circulation", "submitted": "Envoyé",
"totalGradidoCreated": "GDD total puisé",
"totalGradidoDecayed": "Total de GDD écoulé"
},
"success": "Avec succès", "success": "Avec succès",
"time": { "time": {
"days": "Jours", "days": "Jours",
@ -318,8 +338,7 @@
"years": "Année" "years": "Année"
}, },
"transaction": { "transaction": {
"gdd-text": "Transactions Gradido", "lastTransactions": "Dernières transactions",
"gdt-text": "Transactions de GradidoTransform",
"nullTransactions": "Vous n´avez pas encore de transaction effectuée sur votre compte.", "nullTransactions": "Vous n´avez pas encore de transaction effectuée sur votre compte.",
"receiverDeleted": "Le compte du destinataire n´existe plus", "receiverDeleted": "Le compte du destinataire n´existe plus",
"receiverNotFound": "Destinataire inconnu", "receiverNotFound": "Destinataire inconnu",

View File

@ -24,15 +24,7 @@ export const copyLinks = {
}, },
copyLinkWithText() { copyLinkWithText() {
navigator.clipboard navigator.clipboard
.writeText( .writeText(this.linkText)
`${this.link}
${this.$store.state.firstName} ${this.$t('transaction-link.send_you')} ${this.amount} Gradido.
"${this.memo}"
${this.$t('gdd_per_link.credit-your-gradido')} ${this.$t('gdd_per_link.validUntilDate', {
date: this.$d(new Date(this.validUntil), 'short'),
})}
${this.$t('gdd_per_link.link-hint')}`,
)
.then(() => { .then(() => {
this.toastSuccess(this.$t('gdd_per_link.link-and-text-copied')) this.toastSuccess(this.$t('gdd_per_link.link-and-text-copied'))
}) })
@ -42,4 +34,15 @@ ${this.$t('gdd_per_link.link-hint')}`,
}) })
}, },
}, },
computed: {
linkText() {
return `${this.link}
${this.$store.state.firstName} ${this.$t('transaction-link.send_you')} ${this.amount} Gradido.
"${this.memo}"
${this.$t('gdd_per_link.credit-your-gradido')} ${this.$t('gdd_per_link.validUntilDate', {
date: this.$d(new Date(this.validUntil), 'short'),
})}
${this.$t('gdd_per_link.link-hint')}`
},
},
} }

View File

@ -282,7 +282,7 @@ export default {
if (this.$route.hash !== '#my') { if (this.$route.hash !== '#my') {
this.$router.push({ path: '/community#my' }) this.$router.push({ path: '/community#my' })
} }
this.toastInfo('Du hast eine Rückfrage auf eine Contribution. Bitte beantworte diese!') this.toastInfo(this.$t('contribution.alert.answerQuestionToast'))
} }
}) })
.catch((err) => { .catch((err) => {

View File

@ -1,4 +1,4 @@
import { mount, RouterLinkStub } from '@vue/test-utils' import { mount } from '@vue/test-utils'
import flushPromises from 'flush-promises' import flushPromises from 'flush-promises'
import { toastErrorSpy } from '@test/testSetup' import { toastErrorSpy } from '@test/testSetup'
import ForgotPassword from './ForgotPassword' import ForgotPassword from './ForgotPassword'
@ -7,43 +7,28 @@ const mockAPIcall = jest.fn()
const localVue = global.localVue const localVue = global.localVue
const mockRouterPush = jest.fn() const mocks = {
$t: jest.fn((t) => t),
const stubs = { $apollo: {
RouterLink: RouterLinkStub, mutate: mockAPIcall,
} },
$route: {
const createMockObject = (comingFrom) => { params: {
return { comingFrom: '',
localVue,
mocks: {
$t: jest.fn((t) => t),
$router: {
push: mockRouterPush,
},
$apollo: {
mutate: mockAPIcall,
},
$route: {
params: {
comingFrom,
},
},
}, },
stubs, },
}
} }
describe('ForgotPassword', () => { describe('ForgotPassword', () => {
let wrapper let wrapper
const Wrapper = (functionN) => { const Wrapper = () => {
return mount(ForgotPassword, functionN) return mount(ForgotPassword, { localVue, mocks })
} }
describe('mount', () => { describe('mount', () => {
beforeEach(() => { beforeEach(() => {
wrapper = Wrapper(createMockObject()) wrapper = Wrapper()
}) })
it('renders the component', () => { it('renders the component', () => {
@ -110,12 +95,6 @@ describe('ForgotPassword', () => {
expect(wrapper.find('.test-message-button').attributes('href')).toBe('/login') expect(wrapper.find('.test-message-button').attributes('href')).toBe('/login')
}) })
it.skip('click redirects to "/login"', async () => {
// wrapper.find('.test-message-button').trigger('click')
// await wrapper.vm.$nextTick()
expect(mockRouterPush).toBeCalledWith('/login')
})
it('toasts a standard error message', () => { it('toasts a standard error message', () => {
expect(toastErrorSpy).toBeCalledWith('error.email-already-sent') expect(toastErrorSpy).toBeCalledWith('error.email-already-sent')
}) })
@ -144,13 +123,20 @@ describe('ForgotPassword', () => {
it('button link redirects to "/login"', () => { it('button link redirects to "/login"', () => {
expect(wrapper.find('.test-message-button').attributes('href')).toBe('/login') expect(wrapper.find('.test-message-button').attributes('href')).toBe('/login')
}) })
it.skip('click redirects to "/login"', () => {
// expect(mockRouterPush).toBeCalledWith('/login')
})
}) })
}) })
}) })
}) })
describe('route has coming from ', () => {
beforeEach(() => {
mocks.$route.params.comingFrom = 'coming from'
wrapper = Wrapper()
})
it('changes subtitle', () => {
expect(wrapper.vm.subtitle).toBe('settings.password.resend_subtitle')
})
})
}) })
}) })

View File

@ -254,7 +254,7 @@ describe('Send', () => {
describe('copy link with success', () => { describe('copy link with success', () => {
beforeEach(async () => { beforeEach(async () => {
navigatorClipboardMock.mockResolvedValue() navigatorClipboardMock.mockResolvedValue()
await wrapper.find('.pointer').trigger('click') await wrapper.find('div[data-test="copyLink"]').trigger('click')
}) })
it('should call clipboard.writeText', () => { it('should call clipboard.writeText', () => {
@ -270,7 +270,7 @@ describe('Send', () => {
describe('copy link with error', () => { describe('copy link with error', () => {
beforeEach(async () => { beforeEach(async () => {
navigatorClipboardMock.mockRejectedValue() navigatorClipboardMock.mockRejectedValue()
await wrapper.find('.clipboard-copy').find('.btn-secondary').trigger('click') await wrapper.find('div[data-test="copyLink"]').trigger('click')
}) })
it('toasts error message', () => { it('toasts error message', () => {
@ -292,7 +292,7 @@ describe('Send', () => {
describe('copy link and text with success', () => { describe('copy link and text with success', () => {
beforeEach(async () => { beforeEach(async () => {
navigatorClipboardMock.mockResolvedValue() navigatorClipboardMock.mockResolvedValue()
await wrapper.findAll('button').at(0).trigger('click') await wrapper.find('div[data-test="copyLinkWithText"]').trigger('click')
}) })
it('should call clipboard.writeText', () => { it('should call clipboard.writeText', () => {
@ -312,7 +312,7 @@ describe('Send', () => {
describe('copy link and text with error', () => { describe('copy link and text with error', () => {
beforeEach(async () => { beforeEach(async () => {
navigatorClipboardMock.mockRejectedValue() navigatorClipboardMock.mockRejectedValue()
await wrapper.findAll('button').at(0).trigger('click') await wrapper.find('div[data-test="copyLinkWithText"]').trigger('click')
}) })
it('toasts error message', () => { it('toasts error message', () => {

View File

@ -70,6 +70,6 @@ console.warn = (m) => {
} }
// throw errors for vue warnings to force the programmers to take care about warnings // throw errors for vue warnings to force the programmers to take care about warnings
Vue.config.warnHandler = (w) => { Vue.config.warnHandler = async (w) => {
throw new Error(w) throw new Error(w)
} }

View File

@ -1,6 +1,6 @@
{ {
"name": "gradido", "name": "gradido",
"version": "1.17.0", "version": "1.17.1",
"description": "Gradido", "description": "Gradido",
"main": "index.js", "main": "index.js",
"repository": "git@github.com:gradido/gradido.git", "repository": "git@github.com:gradido/gradido.git",