保誠-保戶業務員媒合平台
Jack
2021-11-14 b3b9387ff3e29ddabed067a3916c54ad2b70ad56
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
30
31
32
package com.pollex.pam.web.rest;
 
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
 
import com.pollex.pam.service.AppointmentService;
import com.pollex.pam.service.dto.AppointmentCreateDTO;
 
@RestController
@RequestMapping("/api/appointment")
public class AppointmentResource {
    
    @Autowired
    AppointmentService appointmentService;
    
    @PostMapping("/customer/create")
    public void clientCreateAppointment(@RequestBody AppointmentCreateDTO appointmentCreateDTO) {
        appointmentService.customerCreateAppointment(appointmentCreateDTO);
    }
    
    @PostMapping("/markAsContacted")
    public void markAsContacted(@RequestBody Long appointmentId) {
        appointmentService.markAsContacted(appointmentId);
    }
    
    
}