-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
π¦π§ β [SSM-30 SSM-31]: Stations are now being created with p/m config
- Loading branch information
1 parent
f89d120
commit 78c1268
Showing
9 changed files
with
433 additions
and
310 deletions.
There are no files selected for viewing
57 changes: 57 additions & 0 deletions
57
app/api/gameplay/communityStations/projects/31011/route.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
import { NextRequest, NextResponse } from 'next/server'; | ||
|
||
interface Project { | ||
id: string; | ||
name: string; | ||
identifier: string; | ||
} | ||
|
||
interface Mission { | ||
id: string; | ||
name: string; | ||
type: string; | ||
project: string; | ||
missionRouteId?: number; | ||
} | ||
|
||
interface CommunityStationConfig { | ||
stationName: string; | ||
inventoryItemId: number; | ||
projects: Project[]; | ||
missions: Mission[]; | ||
} | ||
|
||
const greenhouseStation: CommunityStationConfig = { | ||
stationName: "Greenhouse", | ||
inventoryItemId: 31011, | ||
projects: [ | ||
{ | ||
id: "1", | ||
name: "Wildwatch Burrowing Owls", | ||
identifier: "zoodex-burrOwls", | ||
}, | ||
{ | ||
id: "2", | ||
name: "Iguanas from Above", | ||
identifier: "zoodex-iguanasFromAbove", | ||
}, | ||
], | ||
missions: [ | ||
{ | ||
id: "1", | ||
name: "Spot an owl in the wild", | ||
type: "Upload", | ||
project: "1", | ||
}, | ||
{ | ||
id: "2", | ||
name: "Track iguana movement", | ||
type: "Analysis", | ||
project: "2", | ||
}, | ||
], | ||
}; | ||
|
||
export async function GET(req: NextRequest) { | ||
return NextResponse.json(greenhouseStation); | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
import { NextRequest, NextResponse } from 'next/server'; | ||
|
||
interface Project { | ||
id: string; | ||
name: string; | ||
identifier: string; | ||
// isUnlocked: boolean; | ||
// level: number; | ||
} | ||
|
||
interface Mission { | ||
id: string; | ||
name: string; | ||
type: string; | ||
// completionRate: number; | ||
project: string; | ||
// level: number; | ||
// isUnlocked: boolean; | ||
} | ||
|
||
interface CommunityStationConfig { | ||
stationName: string; | ||
inventoryItemId: number; | ||
projects: Project[]; | ||
missions: Mission[]; | ||
} | ||
|
||
const greenhouseStation: CommunityStationConfig = { | ||
stationName: "Greenhouse", | ||
inventoryItemId: 31011, | ||
projects: [ | ||
{ | ||
id: "1", | ||
name: "Wildwatch Burrowing Owls", | ||
identifier: "zoodex-burrOwls", | ||
}, | ||
{ | ||
id: "2", | ||
name: "Iguanas from Above", | ||
identifier: "zoodex-iguanasFromAbove", | ||
}, | ||
], | ||
missions: [ | ||
{ | ||
id: "1", | ||
name: "Spot an owl in the wild", | ||
type: "Upload", | ||
project: "1", | ||
}, | ||
{ | ||
id: "2", | ||
name: "Track iguana movement", | ||
type: "Analysis", | ||
project: "2", | ||
}, | ||
], | ||
}; | ||
|
||
export async function GET(req: NextRequest) { | ||
return NextResponse.json(greenhouseStation); | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.