diff options
author | 2022-06-23 18:10:39 +0200 | |
---|---|---|
committer | 2022-06-23 16:10:39 +0000 | |
commit | 6b2c2b8dfb86245a1747bf7977159f5129461863 (patch) | |
tree | 28944f62a962d8a658262ea902f8554d4419fa9e /src/containers/auth/SetupAssistantScreen.tsx | |
parent | chore: featureStore and GlobalErrorStore JS => TS (diff) | |
download | ferdium-app-6b2c2b8dfb86245a1747bf7977159f5129461863.tar.gz ferdium-app-6b2c2b8dfb86245a1747bf7977159f5129461863.tar.zst ferdium-app-6b2c2b8dfb86245a1747bf7977159f5129461863.zip |
chore: servicesStore + models into typescript (#344)
Diffstat (limited to 'src/containers/auth/SetupAssistantScreen.tsx')
-rw-r--r-- | src/containers/auth/SetupAssistantScreen.tsx | 26 |
1 files changed, 14 insertions, 12 deletions
diff --git a/src/containers/auth/SetupAssistantScreen.tsx b/src/containers/auth/SetupAssistantScreen.tsx index 44bd32772..8f1871776 100644 --- a/src/containers/auth/SetupAssistantScreen.tsx +++ b/src/containers/auth/SetupAssistantScreen.tsx | |||
@@ -11,22 +11,22 @@ import UserStore from '../../stores/UserStore'; | |||
11 | 11 | ||
12 | interface IProps { | 12 | interface IProps { |
13 | stores: { | 13 | stores: { |
14 | services?: ServicesStore, | 14 | services: ServicesStore; |
15 | router: RouterStore, | 15 | router: RouterStore; |
16 | recipes?: RecipesStore, | 16 | recipes?: RecipesStore; |
17 | user?: UserStore, | 17 | user?: UserStore; |
18 | }, | 18 | }; |
19 | actions: { | 19 | actions: { |
20 | user: UserStore, | 20 | user: UserStore; |
21 | service: ServicesStore, | 21 | service: ServicesStore; |
22 | recipe: RecipesStore, | 22 | recipe: RecipesStore; |
23 | }, | 23 | }; |
24 | }; | 24 | }; |
25 | 25 | ||
26 | class SetupAssistantScreen extends Component<IProps> { | 26 | class SetupAssistantScreen extends Component<IProps> { |
27 | state = { | 27 | state = { |
28 | isSettingUpServices: false, | 28 | isSettingUpServices: false, |
29 | } | 29 | }; |
30 | 30 | ||
31 | // TODO: Why are these hardcoded here? Do they need to conform to specific services in the packaged recipes? If so, its more important to fix this | 31 | // TODO: Why are these hardcoded here? Do they need to conform to specific services in the packaged recipes? If so, its more important to fix this |
32 | services = { | 32 | services = { |
@@ -69,7 +69,9 @@ class SetupAssistantScreen extends Component<IProps> { | |||
69 | }; | 69 | }; |
70 | 70 | ||
71 | async setupServices(serviceConfig) { | 71 | async setupServices(serviceConfig) { |
72 | const { stores: { services, router } } = this.props; | 72 | const { |
73 | stores: { services, router }, | ||
74 | } = this.props; | ||
73 | 75 | ||
74 | this.setState({ | 76 | this.setState({ |
75 | isSettingUpServices: true, | 77 | isSettingUpServices: true, |
@@ -79,7 +81,7 @@ class SetupAssistantScreen extends Component<IProps> { | |||
79 | for (const config of serviceConfig) { | 81 | for (const config of serviceConfig) { |
80 | const serviceData = { | 82 | const serviceData = { |
81 | name: this.services[config.id].name, | 83 | name: this.services[config.id].name, |
82 | team: config.team | 84 | team: config.team, |
83 | }; | 85 | }; |
84 | 86 | ||
85 | await services._createService({ | 87 | await services._createService({ |