diff options
author | 2019-09-02 11:28:39 +0200 | |
---|---|---|
committer | 2019-09-02 11:28:39 +0200 | |
commit | 88a89ea3eb88f76ff9a2b9b856db855a7e15a46c (patch) | |
tree | db1447567b31f227f28a78710e24fffaca4eb582 /src/components/auth | |
parent | fix missing icons (diff) | |
download | ferdium-app-88a89ea3eb88f76ff9a2b9b856db855a7e15a46c.tar.gz ferdium-app-88a89ea3eb88f76ff9a2b9b856db855a7e15a46c.tar.zst ferdium-app-88a89ea3eb88f76ff9a2b9b856db855a7e15a46c.zip |
Remove user type from signup
Diffstat (limited to 'src/components/auth')
-rw-r--r-- | src/components/auth/Signup.js | 30 |
1 files changed, 4 insertions, 26 deletions
diff --git a/src/components/auth/Signup.js b/src/components/auth/Signup.js index d9b83eeb8..7724bb908 100644 --- a/src/components/auth/Signup.js +++ b/src/components/auth/Signup.js | |||
@@ -31,10 +31,10 @@ const messages = defineMessages({ | |||
31 | id: 'signup.email.label', | 31 | id: 'signup.email.label', |
32 | defaultMessage: '!!!Email address', | 32 | defaultMessage: '!!!Email address', |
33 | }, | 33 | }, |
34 | companyLabel: { | 34 | // companyLabel: { |
35 | id: 'signup.company.label', | 35 | // id: 'signup.company.label', |
36 | defaultMessage: '!!!Company', | 36 | // defaultMessage: '!!!Company', |
37 | }, | 37 | // }, |
38 | passwordLabel: { | 38 | passwordLabel: { |
39 | id: 'signup.password.label', | 39 | id: 'signup.password.label', |
40 | defaultMessage: '!!!Password', | 40 | defaultMessage: '!!!Password', |
@@ -79,20 +79,6 @@ export default @observer class Signup extends Component { | |||
79 | 79 | ||
80 | form = new Form({ | 80 | form = new Form({ |
81 | fields: { | 81 | fields: { |
82 | accountType: { | ||
83 | value: 'individual', | ||
84 | validators: [required], | ||
85 | options: [{ | ||
86 | value: 'individual', | ||
87 | label: 'Individual', | ||
88 | }, { | ||
89 | value: 'non-profit', | ||
90 | label: 'Non-Profit', | ||
91 | }, { | ||
92 | value: 'company', | ||
93 | label: 'Company', | ||
94 | }], | ||
95 | }, | ||
96 | firstname: { | 82 | firstname: { |
97 | label: this.context.intl.formatMessage(messages.firstnameLabel), | 83 | label: this.context.intl.formatMessage(messages.firstnameLabel), |
98 | value: '', | 84 | value: '', |
@@ -108,10 +94,6 @@ export default @observer class Signup extends Component { | |||
108 | value: '', | 94 | value: '', |
109 | validators: [required, email], | 95 | validators: [required, email], |
110 | }, | 96 | }, |
111 | organization: { | ||
112 | label: this.context.intl.formatMessage(messages.companyLabel), | ||
113 | value: '', // TODO: make required when accountType: company | ||
114 | }, | ||
115 | password: { | 97 | password: { |
116 | label: this.context.intl.formatMessage(messages.passwordLabel), | 98 | label: this.context.intl.formatMessage(messages.passwordLabel), |
117 | value: '', | 99 | value: '', |
@@ -151,7 +133,6 @@ export default @observer class Signup extends Component { | |||
151 | In Dev Mode your data is not persistent. Please use the live app for accesing the production API. | 133 | In Dev Mode your data is not persistent. Please use the live app for accesing the production API. |
152 | </Infobox> | 134 | </Infobox> |
153 | )} | 135 | )} |
154 | <Radio field={form.$('accountType')} showLabel={false} /> | ||
155 | <div className="grid__row"> | 136 | <div className="grid__row"> |
156 | <Input field={form.$('firstname')} focus /> | 137 | <Input field={form.$('firstname')} focus /> |
157 | <Input field={form.$('lastname')} /> | 138 | <Input field={form.$('lastname')} /> |
@@ -162,9 +143,6 @@ export default @observer class Signup extends Component { | |||
162 | showPasswordToggle | 143 | showPasswordToggle |
163 | scorePassword | 144 | scorePassword |
164 | /> | 145 | /> |
165 | {form.$('accountType').value === 'company' && ( | ||
166 | <Input field={form.$('organization')} /> | ||
167 | )} | ||
168 | {error.code === 'email-duplicate' && ( | 146 | {error.code === 'email-duplicate' && ( |
169 | <p className="error-message center">{intl.formatMessage(messages.emailDuplicate)}</p> | 147 | <p className="error-message center">{intl.formatMessage(messages.emailDuplicate)}</p> |
170 | )} | 148 | )} |