Optimize code, rebase api path, fix typo
This commit is contained in:
parent
16917a088f
commit
d101d81763
13 changed files with 111 additions and 100 deletions
|
|
@ -1,10 +1,10 @@
|
|||
//import type {Exam} from '$lib/data/CMSDataType'
|
||||
import {apibase} from '$lib/data/CMSDataType'
|
||||
import { error } from '@sveltejs/kit'
|
||||
import dayjs from 'dayjs'
|
||||
import type { PageServerLoad } from './$types'
|
||||
export const load: PageServerLoad = async ({params,fetch}) => {
|
||||
const id = params.id+""
|
||||
const res = await fetch("/api/qualifying/"+id)
|
||||
const res = await fetch(apibase+"/qualifying/"+id)
|
||||
if(res.status==404){
|
||||
throw error(404,{message:`ค้นหาข้อมูลสอบคัดเลือก ${id}ไม่พบ`})
|
||||
}
|
||||
|
|
|
|||
|
|
@ -18,7 +18,7 @@
|
|||
</a>
|
||||
</li>
|
||||
<li>
|
||||
<span class="breadTaxt">ประกาศเกี่ยวกับการคัดเลือกบุคลากรกทม.</span>
|
||||
<span class="breadTaxt">ประกาศเกี่ยวกับการคัดเลือกบุคลากรของกทม.</span>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue