Skip to content

Commit

Permalink
[Fix] barList 조회 api default param 수정 #32
Browse files Browse the repository at this point in the history
  • Loading branch information
soonki-98 committed Nov 30, 2022
1 parent a311e02 commit f476607
Showing 1 changed file with 9 additions and 10 deletions.
19 changes: 9 additions & 10 deletions src/apis/bar.ts
Original file line number Diff line number Diff line change
@@ -1,19 +1,18 @@
import { BarType } from '@lib/types';
import RestAPI from './restapi';


class BarAPI {
/**
* 술집 목록 조회
* @param latitude
* @param longitude
* @param zoomLevel
* @param moodTag
* @param drinkTag
*/
/**
* 술집 목록 조회
* @param latitude
* @param longitude
* @param zoomLevel
* @param moodTag
* @param drinkTag
*/
public async getBarList(data: BarType.barSearchTyoe) {
try {
const { latitude, longitude, zoomLevel, moodTag, drinkTag } = data;
const { latitude, longitude, zoomLevel = 6, moodTag = '', drinkTag = '' } = data;
const result = await RestAPI.get(
`/api/bars?latitude=${latitude}&longitude=${longitude}&level=${zoomLevel}&barMoodTagNames=${moodTag}&barAlcoholTagNames=${drinkTag}`
);
Expand Down

0 comments on commit f476607

Please sign in to comment.