保誠-保戶業務員媒合平台
Tomas
2021-12-22 847792a08f17d7b2a6c6ef90aa9e956cee671da3
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
import { http } from '~/assets/ts/services/httpClient';
 
import { AppointmentLog } from '../models/appointment.model';
 
// 標記為已聯絡
export function markAsContact(appointmentId: number) {
    const headers = {
        Authorization: 'Bearer ' + localStorage.getItem('id_token')
    }
    // TODO: 跟後端確認,這裡的 API 不應該傳回 void, 而是應該是更新後的資料 - Ben 2021/11/16
    return http.post('/appointment/markAsContacted/'+appointmentId, undefined, {headers})
            .then(res => res.data)
}
 
export function getMyReviewLog(): Promise<AppointmentLog[]> {
    const headers = {
        Authorization: 'Bearer ' + localStorage.getItem('id_token')
    }
    return http.get('/satisfaction/getMySatisfaction', { headers }).then(res => res.data);
}
 
 
// 顧問登入顯示新預約單筆數後觸發
export function allAppointmentsView() {
    const headers = {
        Authorization: 'Bearer ' + localStorage.getItem('id_token')
    }
    return http.post('/consultant/record/allAppointmentsView', undefined, {headers})
}