-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fourth frontend features and some backend fixes #74
Changes from all commits
0e5f064
c14e02a
9da398b
98e2606
6e3d38f
ca80f02
56813bd
379c6fd
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,3 @@ | ||
#!/bin/sh | ||
|
||
consul agent -config-file=/consul/config/consul.hcl -bootstrap-expect=1 \ | ||
| grep -v "This request used the token query parameter which is deprecated and will be removed" | ||
consul agent -config-file=/consul/config/consul.hcl -bootstrap-expect=1 | grep -v "This request used the token query parameter which is deprecated and will be removed" |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -14,5 +14,6 @@ class MatchmakerSecuredPaths : SpringSecuredPaths { | |
Path("/api/**"), | ||
Not(Path("/api/people/{person_id}", HttpMethod.PUT)), | ||
Not(Path("/api/monitoring/healthcheck", HttpMethod.GET)), | ||
Not(Path("/api/suggestions", HttpMethod.OPTIONS)), | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Тут, наверное, нужно сделать какой-нибудь wildcard и все |
||
) | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,7 +6,7 @@ COPY package*.json ./ | |
|
||
RUN npm install | ||
|
||
# COPY .cert ./.cert | ||
COPY .cert ./.cert | ||
|
||
COPY dist ./dist | ||
|
||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
export interface Coordinates { | ||
latitude: number | ||
longitude: number | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
import { Coordinates } from './Coordinates.ts' | ||
|
||
export interface Location { | ||
id: number | ||
name: string | ||
coordinates: Coordinates | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
export interface Faculty { | ||
id: number | ||
longName: string | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
import axios from 'axios' | ||
import React from 'react' | ||
import { backendPeopleUrl } from '@/shared/api' | ||
import { Faculty } from '@/entities/registration-data/model/faculty.ts' | ||
|
||
export function getFaculties( | ||
setFaculties: React.Dispatch<React.SetStateAction<Array<Faculty>>>, | ||
) { | ||
const url = `${backendPeopleUrl}/api/faculties` | ||
|
||
axios | ||
.get(url) | ||
.then((response) => { | ||
console.log(response.data) | ||
//FIXME after integration with backend | ||
setFaculties(response.data) | ||
}) | ||
.catch((error) => { | ||
console.error('Error getting faculties: ', error) | ||
//TODO remove after integration with backend | ||
setFaculties([{ id: 1, longName: 'piict' }]) | ||
Comment on lines
+19
to
+21
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Это уже можно убрать? |
||
}) | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
import axios from 'axios' | ||
import React from 'react' | ||
import { backendPeopleUrl } from '@/shared/api' | ||
import { Location } from '@/entities/registration-data/model/Location.ts' | ||
|
||
export function getLocations( | ||
setLocations: React.Dispatch<React.SetStateAction<Array<Location>>>, | ||
) { | ||
const url = `${backendPeopleUrl}/api/locations` | ||
|
||
axios | ||
.get(url) | ||
.then((response) => { | ||
console.log(response.data) | ||
//FIXME after integration with backend | ||
setLocations(response.data) | ||
}) | ||
.catch((error) => { | ||
console.error('Error getting locations: ', error) | ||
//TODO remove after integration with backend | ||
setLocations([ | ||
{ | ||
id: 1, | ||
name: 'ITMO University, Kronverkskiy Avenue', | ||
coordinates: { | ||
latitude: 59.957478, | ||
longitude: 30.308014, | ||
}, | ||
}, | ||
]) | ||
Comment on lines
+19
to
+30
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Это уже можно убрать? |
||
}) | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Хммм, а может быть это даже можно в какой-то общий для всех модуль унести, потому что я для работы
WebClient
сам велосипедноSSLContext
собираю. Может быть, эта штука сделает так, чтобы оно работало само.