Merge branch '1637-generate-link-backend' of https://github.com/gradido/gradido into 1637-generate-link-backend

This commit is contained in:
elweyn 2022-04-08 08:15:13 +02:00
commit 38ee27005f
8 changed files with 159 additions and 23 deletions

View File

@ -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
@ -42,7 +42,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

View File

@ -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

View File

@ -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,

View File

@ -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')
}

View File

@ -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

View File

@ -0,0 +1,132 @@
<mxfile host="65bd71144e">
<diagram id="qH1decoyufLOWHgfqT4g" name="Page-1">
<mxGraphModel dx="888" dy="633" grid="1" gridSize="10" guides="1" tooltips="1" connect="1" arrows="1" fold="1" page="1" pageScale="1" pageWidth="850" pageHeight="1100" math="0" shadow="0">
<root>
<mxCell id="0"/>
<mxCell id="1" parent="0"/>
<mxCell id="2" value="" style="rounded=0;whiteSpace=wrap;html=1;" parent="1" vertex="1">
<mxGeometry x="310" y="230" width="220" height="200" as="geometry"/>
</mxCell>
<mxCell id="3" value="Communities" style="ellipse;whiteSpace=wrap;html=1;aspect=fixed;" parent="1" vertex="1">
<mxGeometry x="330" y="330" width="80" height="80" as="geometry"/>
</mxCell>
<mxCell id="4" value="" style="shape=flexArrow;endArrow=classic;startArrow=classic;html=1;" parent="1" edge="1">
<mxGeometry width="100" height="100" relative="1" as="geometry">
<mxPoint x="450" y="390" as="sourcePoint"/>
<mxPoint x="485" y="350" as="targetPoint"/>
</mxGeometry>
</mxCell>
<mxCell id="5" value="Relationships" style="edgeLabel;html=1;align=center;verticalAlign=middle;resizable=0;points=[];" parent="4" vertex="1" connectable="0">
<mxGeometry x="0.2283" y="-3" relative="1" as="geometry">
<mxPoint x="11" y="33" as="offset"/>
</mxGeometry>
</mxCell>
<mxCell id="6" value="Money&lt;br&gt;Creation" style="rhombus;whiteSpace=wrap;html=1;" parent="1" vertex="1">
<mxGeometry x="430" y="240" width="80" height="80" as="geometry"/>
</mxCell>
<mxCell id="7" value="&lt;br&gt;Money&amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;nbsp;&lt;br&gt;Transfer&amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;nbsp;" style="triangle;whiteSpace=wrap;html=1;" parent="1" vertex="1">
<mxGeometry x="340" y="240" width="60" height="80" as="geometry"/>
</mxCell>
<mxCell id="11" value="" style="ellipse;whiteSpace=wrap;html=1;aspect=fixed;" vertex="1" parent="1">
<mxGeometry x="485" y="330" width="20" height="20" as="geometry"/>
</mxCell>
<mxCell id="14" value="" style="ellipse;whiteSpace=wrap;html=1;aspect=fixed;" vertex="1" parent="1">
<mxGeometry x="431" y="390" width="20" height="20" as="geometry"/>
</mxCell>
<mxCell id="17" value="" style="rounded=0;whiteSpace=wrap;html=1;" vertex="1" parent="1">
<mxGeometry x="530" y="230" width="120" height="200" as="geometry"/>
</mxCell>
<mxCell id="18" value="Abilities &amp;amp;&lt;br&gt;Talents&amp;nbsp;" style="shape=hexagon;perimeter=hexagonPerimeter2;whiteSpace=wrap;html=1;fixedSize=1;" vertex="1" parent="1">
<mxGeometry x="543" y="250" width="100" height="60" as="geometry"/>
</mxCell>
<mxCell id="20" style="edgeStyle=none;html=1;exitX=1;exitY=0.5;exitDx=0;exitDy=0;" edge="1" parent="1" source="6" target="18">
<mxGeometry relative="1" as="geometry"/>
</mxCell>
<mxCell id="24" style="edgeStyle=none;html=1;exitX=0.5;exitY=0;exitDx=0;exitDy=0;dashed=1;dashPattern=1 2;" edge="1" parent="1" source="22" target="18">
<mxGeometry relative="1" as="geometry"/>
</mxCell>
<mxCell id="22" value="User Management" style="shape=hexagon;perimeter=hexagonPerimeter2;whiteSpace=wrap;html=1;fixedSize=1;" vertex="1" parent="1">
<mxGeometry x="543" y="342" width="100" height="60" as="geometry"/>
</mxCell>
<mxCell id="23" value="" style="endArrow=classic;html=1;entryX=0;entryY=0.5;entryDx=0;entryDy=0;dashed=1;dashPattern=1 2;" edge="1" parent="1" target="22">
<mxGeometry width="50" height="50" relative="1" as="geometry">
<mxPoint x="500" y="372" as="sourcePoint"/>
<mxPoint x="530" y="310" as="targetPoint"/>
</mxGeometry>
</mxCell>
<mxCell id="25" value="" style="shape=or;whiteSpace=wrap;html=1;direction=south;" vertex="1" parent="1">
<mxGeometry x="438" y="430" width="70" height="40" as="geometry"/>
</mxCell>
<mxCell id="26" value="" style="shape=or;whiteSpace=wrap;html=1;direction=south;" vertex="1" parent="1">
<mxGeometry x="559" y="430" width="70" height="40" as="geometry"/>
</mxCell>
<mxCell id="27" value="" style="shape=or;whiteSpace=wrap;html=1;direction=north;" vertex="1" parent="1">
<mxGeometry x="559" y="190" width="70" height="40" as="geometry"/>
</mxCell>
<mxCell id="28" value="" style="shape=or;whiteSpace=wrap;html=1;direction=east;" vertex="1" parent="1">
<mxGeometry x="650" y="340" width="40" height="70" as="geometry"/>
</mxCell>
<mxCell id="29" value="" style="shape=or;whiteSpace=wrap;html=1;direction=north;" vertex="1" parent="1">
<mxGeometry x="439" y="190" width="70" height="40" as="geometry"/>
</mxCell>
<mxCell id="30" value="" style="shape=or;whiteSpace=wrap;html=1;direction=north;" vertex="1" parent="1">
<mxGeometry x="333" y="190" width="70" height="40" as="geometry"/>
</mxCell>
<mxCell id="31" value="" style="shape=or;whiteSpace=wrap;html=1;direction=east;" vertex="1" parent="1">
<mxGeometry x="650" y="248" width="40" height="70" as="geometry"/>
</mxCell>
<mxCell id="32" value="" style="shape=or;whiteSpace=wrap;html=1;direction=south;" vertex="1" parent="1">
<mxGeometry x="336" y="430" width="70" height="40" as="geometry"/>
</mxCell>
<mxCell id="33" value="" style="shape=or;whiteSpace=wrap;html=1;direction=west;" vertex="1" parent="1">
<mxGeometry x="270" y="245" width="40" height="70" as="geometry"/>
</mxCell>
<mxCell id="34" value="" style="shape=or;whiteSpace=wrap;html=1;direction=west;" vertex="1" parent="1">
<mxGeometry x="270" y="335" width="40" height="70" as="geometry"/>
</mxCell>
<mxCell id="36" value="" style="shape=dataStorage;whiteSpace=wrap;html=1;fixedSize=1;direction=west;" vertex="1" parent="1">
<mxGeometry x="677" y="337" width="83" height="75" as="geometry"/>
</mxCell>
<mxCell id="37" value="Dating App" style="rounded=0;whiteSpace=wrap;html=1;" vertex="1" parent="1">
<mxGeometry x="740" y="330" width="100" height="100" as="geometry"/>
</mxCell>
<mxCell id="38" value="" style="shape=dataStorage;whiteSpace=wrap;html=1;fixedSize=1;direction=west;" vertex="1" parent="1">
<mxGeometry x="677" y="244" width="83" height="75" as="geometry"/>
</mxCell>
<mxCell id="39" value="Local Area Search for Abilities &amp;amp; Talents" style="rounded=0;whiteSpace=wrap;html=1;" vertex="1" parent="1">
<mxGeometry x="740" y="227" width="100" height="103" as="geometry"/>
</mxCell>
<mxCell id="40" value="" style="shape=dataStorage;whiteSpace=wrap;html=1;fixedSize=1;direction=south;" vertex="1" parent="1">
<mxGeometry x="437" y="120" width="75" height="83" as="geometry"/>
</mxCell>
<mxCell id="41" value="Micro Creations to gamify Applications" style="rounded=0;whiteSpace=wrap;html=1;" vertex="1" parent="1">
<mxGeometry x="424" y="47" width="100" height="103" as="geometry"/>
</mxCell>
<mxCell id="42" value="" style="shape=dataStorage;whiteSpace=wrap;html=1;fixedSize=1;direction=south;" vertex="1" parent="1">
<mxGeometry x="330" y="120" width="75" height="83" as="geometry"/>
</mxCell>
<mxCell id="43" value="Marketplace" style="rounded=0;whiteSpace=wrap;html=1;" vertex="1" parent="1">
<mxGeometry x="317" y="47" width="100" height="103" as="geometry"/>
</mxCell>
<mxCell id="44" value="" style="shape=dataStorage;whiteSpace=wrap;html=1;fixedSize=1;direction=north;" vertex="1" parent="1">
<mxGeometry x="436" y="457" width="75" height="83" as="geometry"/>
</mxCell>
<mxCell id="45" value="Search Engine" style="rounded=0;whiteSpace=wrap;html=1;" vertex="1" parent="1">
<mxGeometry x="424" y="507" width="100" height="103" as="geometry"/>
</mxCell>
<mxCell id="46" value="" style="shape=dataStorage;whiteSpace=wrap;html=1;fixedSize=1;direction=north;" vertex="1" parent="1">
<mxGeometry x="333" y="456" width="75" height="83" as="geometry"/>
</mxCell>
<mxCell id="47" value="Chat" style="rounded=0;whiteSpace=wrap;html=1;" vertex="1" parent="1">
<mxGeometry x="319" y="506" width="100" height="103" as="geometry"/>
</mxCell>
<mxCell id="48" value="" style="shape=dataStorage;whiteSpace=wrap;html=1;fixedSize=1;direction=north;" vertex="1" parent="1">
<mxGeometry x="556" y="457" width="75" height="83" as="geometry"/>
</mxCell>
<mxCell id="49" value="Newsletter" style="rounded=0;whiteSpace=wrap;html=1;" vertex="1" parent="1">
<mxGeometry x="544" y="507" width="100" height="103" as="geometry"/>
</mxCell>
</root>
</mxGraphModel>
</diagram>
</mxfile>

Binary file not shown.

Binary file not shown.