接口
//1.传一个参数
@GetMapping("/getCaseByincident/{incidentNumber}")
public PoliceVo getCaseByincident(@PathVariable("incidentNumber") String incidentNumber) {}
//2.传对象
@PostMapping("/getPoliceByIncident")
public IncidentVo getByCase(@RequestBody PoliceDto policeDto) {}
api
//1.传一个参数
incidentByPoliceSituation(policeSituationCode) {
return `${eventBase}/policeSituationByIncident/getIncidentByPoliceSituation/${policeSituationCode}`
},
//2.传对象
policeSituationByIncident() {
return `${eventBase}/policeSituationByIncident/getPoliceByIncident`
},
axios
//1.传一个参数
this.$axios.get(api.incidentByPoliceSituation(policeSituationCode)).then((res)=>{})
//2.传对象
this.$axios.post(api.policeSituationByIncident(), data).then((response) => {})