diff --git a/backend/.env.dist b/backend/.env.dist
index 0a95eda6c..033417025 100644
--- a/backend/.env.dist
+++ b/backend/.env.dist
@@ -1,9 +1,9 @@
-CONFIG_VERSION=v3.2022-03-29
+CONFIG_VERSION=v4.2022-04-05
# Server
PORT=4000
JWT_SECRET=secret123
-JWT_EXPIRES_IN=10m
+JWT_EXPIRES_IN=30m
GRAPHIQL=false
GDT_API_URL=https://gdt.gradido.net
@@ -41,7 +41,7 @@ EMAIL_PASSWORD=xxx
EMAIL_SMTP_URL=gmail.com
EMAIL_SMTP_PORT=587
EMAIL_LINK_VERIFICATION=http://localhost/checkEmail/{optin}{code}
-EMAIL_LINK_SETPASSWORD=http://localhost/reset/{optin}
+EMAIL_LINK_SETPASSWORD=http://localhost/reset-password/{optin}
EMAIL_LINK_FORGOTPASSWORD=http://localhost/forgot-password
EMAIL_CODE_VALID_TIME=1440
EMAIL_CODE_REQUEST_TIME=10
diff --git a/backend/.env.template b/backend/.env.template
index 66cac7a7c..011e413df 100644
--- a/backend/.env.template
+++ b/backend/.env.template
@@ -2,7 +2,7 @@ CONFIG_VERSION=$BACKEND_CONFIG_VERSION
# Server
JWT_SECRET=$JWT_SECRET
-JWT_EXPIRES_IN=10m
+JWT_EXPIRES_IN=$JWT_EXPIRES_IN
GRAPHIQL=false
GDT_API_URL=$GDT_API_URL
diff --git a/backend/src/config/index.ts b/backend/src/config/index.ts
index 50388d29a..fe9b40ccc 100644
--- a/backend/src/config/index.ts
+++ b/backend/src/config/index.ts
@@ -14,7 +14,7 @@ const constants = {
DECAY_START_TIME: new Date('2021-05-13 17:46:31'), // GMT+0
CONFIG_VERSION: {
DEFAULT: 'DEFAULT',
- EXPECTED: 'v3.2022-03-29',
+ EXPECTED: 'v4.2022-04-05',
CURRENT: '',
},
}
@@ -22,7 +22,7 @@ const constants = {
const server = {
PORT: process.env.PORT || 4000,
JWT_SECRET: process.env.JWT_SECRET || 'secret123',
- JWT_EXPIRES_IN: process.env.JWT_EXPIRES_IN || '10m',
+ JWT_EXPIRES_IN: process.env.JWT_EXPIRES_IN || '30m',
GRAPHIQL: process.env.GRAPHIQL === 'true' || false,
GDT_API_URL: process.env.GDT_API_URL || 'https://gdt.gradido.net',
PRODUCTION: process.env.NODE_ENV === 'production' || false,
diff --git a/backend/src/graphql/resolver/TransactionResolver.ts b/backend/src/graphql/resolver/TransactionResolver.ts
index aa1bba639..8747f14a3 100644
--- a/backend/src/graphql/resolver/TransactionResolver.ts
+++ b/backend/src/graphql/resolver/TransactionResolver.ts
@@ -263,6 +263,9 @@ export class TransactionResolver {
if (recipientUser.deletedAt) {
throw new Error('The recipient account was deleted')
}
+ if (!recipientUser.emailChecked) {
+ throw new Error('The recipient account is not activated')
+ }
if (!isHexPublicKey(recipientUser.pubKey.toString('hex'))) {
throw new Error('invalid recipient public key')
}
diff --git a/deployment/bare_metal/.env.dist b/deployment/bare_metal/.env.dist
index f2b0bcbb3..8254fd9c2 100644
--- a/deployment/bare_metal/.env.dist
+++ b/deployment/bare_metal/.env.dist
@@ -18,7 +18,23 @@ WEBHOOK_GITHUB_SECRET=secret
WEBHOOK_GITHUB_BRANCH=master
# backend
-BACKEND_CONFIG_VERSION=v3.2022-03-29
+BACKEND_CONFIG_VERSION=v4.2022-04-05
+
+JWT_EXPIRES_IN=30m
+GDT_API_URL=https://gdt.gradido.net
+
+TYPEORM_LOGGING_RELATIVE_PATH=../deployment/bare_metal/log/typeorm.backend.log
+
+KLICKTIPP=false
+KLICKTIPP_USER=
+KLICKTIPP_PASSWORD=
+KLICKTIPP_APIKEY_DE=
+KLICKTIPP_APIKEY_EN=
+
+COMMUNITY_NAME="Gradido Development Stage1"
+COMMUNITY_URL=https://stage1.gradido.net/
+COMMUNITY_REGISTER_URL=https://stage1.gradido.net/register
+COMMUNITY_DESCRIPTION="Gradido Development Stage1 Test Community"
EMAIL=true
EMAIL_USERNAME=peter@lustig.de
@@ -26,28 +42,13 @@ EMAIL_SENDER=peter@lustig.de
EMAIL_PASSWORD=1234
EMAIL_SMTP_URL=smtp.lustig.de
EMAIL_LINK_VERIFICATION=https://stage1.gradido.net/checkEmail/{optin}{code}
-EMAIL_LINK_SETPASSWORD=https://stage1.gradido.net/reset/{optin}
+EMAIL_LINK_SETPASSWORD=https://stage1.gradido.net/reset-password/{optin}
EMAIL_LINK_FORGOTPASSWORD=https://stage1.gradido.net/forgot-password
EMAIL_CODE_VALID_TIME=1440
EMAIL_CODE_REQUEST_TIME=10
-TYPEORM_LOGGING_RELATIVE_PATH=../deployment/bare_metal/log/typeorm.backend.log
-
WEBHOOK_ELOPAGE_SECRET=secret
-GDT_API_URL=https://gdt.gradido.net
-
-COMMUNITY_NAME="Gradido Development Stage1"
-COMMUNITY_URL=https://stage1.gradido.net/
-COMMUNITY_REGISTER_URL=https://stage1.gradido.net/register
-COMMUNITY_DESCRIPTION="Gradido Development Stage1 Test Community"
-
-KLICKTIPP=false
-KLICKTIPP_USER=
-KLICKTIPP_PASSWORD=
-KLICKTIPP_APIKEY_DE=
-KLICKTIPP_APIKEY_EN=
-
# database
DATABASE_CONFIG_VERSION=v1.2022-03-18
diff --git a/docu/presentation/gradido-as-platform.drawio b/docu/presentation/gradido-as-platform.drawio
new file mode 100644
index 000000000..9ddcad246
--- /dev/null
+++ b/docu/presentation/gradido-as-platform.drawio
@@ -0,0 +1,132 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/docu/presentation/scope-of-gradido.odp b/docu/presentation/scope-of-gradido.odp
new file mode 100644
index 000000000..821bd1563
Binary files /dev/null and b/docu/presentation/scope-of-gradido.odp differ
diff --git a/docu/presentation/scope-of-gradido.pdf b/docu/presentation/scope-of-gradido.pdf
new file mode 100644
index 000000000..adc45e8d4
Binary files /dev/null and b/docu/presentation/scope-of-gradido.pdf differ
diff --git a/frontend/src/components/GddSend/TransactionForm.vue b/frontend/src/components/GddSend/TransactionForm.vue
index a0ac3d3bc..62361c4d0 100644
--- a/frontend/src/components/GddSend/TransactionForm.vue
+++ b/frontend/src/components/GddSend/TransactionForm.vue
@@ -224,7 +224,7 @@ export default {
},
},
created() {
- this.form.email = this.recipientEmail ? this.recipientEmail : ''
+ this.form.email = this.recipientEmail ? this.recipientEmail : this.form.email
},
}
diff --git a/frontend/src/components/GddTransactionList.spec.js b/frontend/src/components/GddTransactionList.spec.js
index aeecf43cc..fbcb10bdd 100644
--- a/frontend/src/components/GddTransactionList.spec.js
+++ b/frontend/src/components/GddTransactionList.spec.js
@@ -23,6 +23,8 @@ describe('GddTransactionList', () => {
return mount(GddTransactionList, { localVue, mocks })
}
+ const decayStartBlock = new Date(2001, 8, 9)
+
describe('mount', () => {
beforeEach(() => {
wrapper = Wrapper()
@@ -84,7 +86,6 @@ describe('GddTransactionList', () => {
describe('with transactions', () => {
beforeEach(async () => {
- const decayStartBlock = new Date(2001, 8, 9)
await wrapper.setProps({
transactions: [
{
@@ -406,78 +407,58 @@ describe('GddTransactionList', () => {
})
describe('pagination buttons', () => {
- const transactions = Array.from({ length: 42 }, (_, idx) => {
- return {
- amount: '3.14',
- balanceDate: '2021-04-29T17:26:40+00:00',
- decay: {},
- memo: 'Kreiszahl PI',
- linkedUser: {
- firstName: 'Bibi',
- lastName: 'Bloxberg',
- __typename: 'User',
- },
- id: idx + 1,
- typeId: 'RECEIVE',
- balance: '33.33',
- }
- })
-
- let paginationButtons
-
beforeEach(async () => {
await wrapper.setProps({
- transactions,
+ transactions: Array.from({ length: 42 }, (_, idx) => {
+ return {
+ amount: '3.14',
+ balanceDate: '2021-04-29T17:26:40+00:00',
+ decay: {},
+ memo: 'Kreiszahl PI',
+ linkedUser: {
+ firstName: 'Bibi',
+ lastName: 'Bloxberg',
+ __typename: 'User',
+ },
+ id: idx + 1,
+ typeId: 'RECEIVE',
+ balance: '33.33',
+ }
+ }),
transactionCount: 42,
+ decayStartBlock,
+ pageSize: 25,
showPagination: true,
- decayStartBlock: new Date(),
})
- paginationButtons = wrapper.find('div.pagination-buttons')
})
- it('shows the pagination buttons', () => {
- expect(paginationButtons.exists()).toBeTruthy()
+ describe('next page button clicked', () => {
+ beforeEach(async () => {
+ jest.clearAllMocks()
+ await wrapper.findComponent({ name: 'BPagination' }).vm.$emit('input', 2)
+ })
+
+ it('emits update transactions', () => {
+ expect(wrapper.emitted('update-transactions')).toEqual(
+ expect.arrayContaining([[{ currentPage: 2, pageSize: 25 }]]),
+ )
+ })
+ })
+ })
+
+ describe('show no pagination', () => {
+ beforeEach(async () => {
+ await wrapper.setProps({
+ transactions: [],
+ transactionCount: 2,
+ decayStartBlock,
+ pageSize: 25,
+ showPagination: false,
+ })
})
- it('has the previous button disabled', () => {
- expect(paginationButtons.find('button.previous-page').attributes('disabled')).toBe(
- 'disabled',
- )
- })
-
- it('shows the text "1 / 2"', () => {
- expect(paginationButtons.find('p.text-center').text()).toBe('1 math.div 2')
- })
-
- it('emits update-transactions when next button is clicked', async () => {
- await paginationButtons.find('button.next-page').trigger('click')
- expect(wrapper.emitted('update-transactions')[1]).toEqual([
- { currentPage: 2, pageSize: 25 },
- ])
- })
-
- it('shows text "2 / 2" when next button is clicked', async () => {
- await paginationButtons.find('button.next-page').trigger('click')
- expect(paginationButtons.find('p.text-center').text()).toBe('2 math.div 2')
- })
-
- it('has next-button disabled when next button is clicked', async () => {
- await paginationButtons.find('button.next-page').trigger('click')
- expect(paginationButtons.find('button.next-page').attributes('disabled')).toBe('disabled')
- })
-
- it('scrolls to top after loading next page', async () => {
- await paginationButtons.find('button.next-page').trigger('click')
- expect(scrollToMock).toBeCalled()
- })
-
- it('emits update-transactions when preivous button is clicked after next buton', async () => {
- await paginationButtons.find('button.next-page').trigger('click')
- await paginationButtons.find('button.previous-page').trigger('click')
- expect(wrapper.emitted('update-transactions')[2]).toEqual([
- { currentPage: 1, pageSize: 25 },
- ])
- expect(scrollToMock).toBeCalled()
+ it('shows no pagination buttons', () => {
+ expect(wrapper.find('ul.pagination').exists()).toBe(false)
})
})
})
diff --git a/frontend/src/components/GddTransactionList.vue b/frontend/src/components/GddTransactionList.vue
index 55a11063c..4498034e9 100644
--- a/frontend/src/components/GddTransactionList.vue
+++ b/frontend/src/components/GddTransactionList.vue
@@ -63,12 +63,17 @@
-
+ align="center"
+ >
+
{{ $t('transaction.nullTransactions') }}
@@ -78,7 +83,6 @@
diff --git a/frontend/src/locales/de.json b/frontend/src/locales/de.json
index 80f7ded25..600b36e65 100644
--- a/frontend/src/locales/de.json
+++ b/frontend/src/locales/de.json
@@ -143,7 +143,6 @@
"login": "Anmeldung",
"math": {
"aprox": "~",
- "div": "/",
"equal": "=",
"exclaim": "!",
"pipe": "|"
diff --git a/frontend/src/locales/en.json b/frontend/src/locales/en.json
index 500cceaae..ef9a14c0a 100644
--- a/frontend/src/locales/en.json
+++ b/frontend/src/locales/en.json
@@ -143,7 +143,6 @@
"login": "Login",
"math": {
"aprox": "~",
- "div": "/",
"equal": "=",
"exclaim": "!",
"pipe": "|"
diff --git a/frontend/src/pages/Send.spec.js b/frontend/src/pages/Send.spec.js
index dd32fdb09..447fdde33 100644
--- a/frontend/src/pages/Send.spec.js
+++ b/frontend/src/pages/Send.spec.js
@@ -85,10 +85,9 @@ describe('Send', () => {
})
it('restores the previous data in the formular', () => {
- /* expect(wrapper.find('#input-group-1').find('input').vm.$el.value).toBe(
+ expect(wrapper.find('#input-group-1').find('input').vm.$el.value).toBe(
'user@example.org',
)
- */
expect(wrapper.find('#input-group-2').find('input').vm.$el.value).toBe('23.45')
expect(wrapper.find('#input-group-3').find('textarea').vm.$el.value).toBe(
'Make the best of it!',