-
Notifications
You must be signed in to change notification settings - Fork 1
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
기타 접근성 정보 내려주기 #331
기타 접근성 정보 내려주기 #331
Conversation
🔥🔥🔥 Backend CI Failed. github action link 🔥🔥🔥 |
🔥🔥🔥 Backend CI Failed. github action link 🔥🔥🔥 |
🔥🔥🔥 Backend CI Failed. github action link 🔥🔥🔥 |
🔥🔥🔥 Backend CI Failed. github action link 🔥🔥🔥 |
🔥🔥🔥 Backend CI Failed. github action link 🔥🔥🔥 |
🔥🔥🔥 Backend CI Failed. github action link 🔥🔥🔥 |
created_at TIMESTAMP(6) WITH TIME ZONE NOT NULL DEFAULT CURRENT_TIMESTAMP, | ||
updated_at TIMESTAMP(6) WITH TIME ZONE NOT NULL DEFAULT CURRENT_TIMESTAMP, | ||
category VARCHAR(32) AS ExternalAccessibilityCategory NOT NULL, | ||
details TEXT, |
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.
JSON 필드로 하려고 했는데 sqldelight 버그가 있어서 해결된 버전으로 올려야 하는데 과정에서 change 들 때문에 깨지는게 있어서 그냥 TEXT 로 저장한다.
sqldelight/sqldelight#5030
🔥🔥🔥 Backend CI Failed. github action link 🔥🔥🔥 |
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.
현재 기능에는 전혀 문제 없어 보여서 lgtm
|
||
ExternalAccessibility: | ||
type: object | ||
properties: |
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.
required 필드 안 둬도 되나요?
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.
@@ -24,6 +29,25 @@ data class Location( | |||
fun minusLat(length: Length) = copy( | |||
lat = lat - length.toLatDiff() | |||
) | |||
|
|||
fun distanceMeter(location: Location): Length { |
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.
LocationUtils.calculateDistance()가 있습니당
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.
} | ||
|
||
|
||
private fun levenshtein(s1: String, s2: String, cost: Map<Pair<Char, Char>, Int> = emptyMap()): Int { |
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.
ㅋㅋ
.filter { | ||
searchText ?: return@filter true | ||
searchText.isSimilarWith(it.name) | ||
} |
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.
별다른 정렬 로직은 없나요?
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.
일단은 UX 상에서 없어서 쉽게 가고, 나중에 필요할 시 추가하겠습니다
data class ExternalAccessibility( | ||
val id: String, | ||
val name: String, | ||
val location: Location, | ||
val address: String, | ||
val createdAt: Instant, | ||
val updatedAt: Instant, | ||
val category: ExternalAccessibilityCategory, | ||
val toiletDetails: ToiletAccessibilityDetails?, | ||
) |
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.
외부 데이터를 연동해올 때 쓸 수 있는 멱등키 같은 게 column으로 들어가 있으면 나중에 여러 데이터 소스에서 여러 번 불러올 때 더 좋을 것 같군요
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.
(소스별 prefix + 소스에서제공하는 id) 를 멱등키로 업데이트 하려고 합니다. 이걸 externalAccessibility.id 로 저장할 예정
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.
그러면 id가 멱등키로 쓰인다는 주석이 있으면 좋겠습니닷
🔥🔥🔥 Backend CI Failed. github action link 🔥🔥🔥 |
🔥🔥🔥 Backend CI Failed. github action link 🔥🔥🔥 |
화장실과 같은 외부 소스에서 가져온 접근성 정보를 저장하고 조회할 수 있도록 한다.
external_accessibility 라는 도메인을 별도로 만들고 그곳 안에서 작업함.