1.URL
http://124.223.60.234:8080/system/maintenance/service/addMaintenanceService
2.请求参数
2.1请求头
在Headers里面增加token:对应登录验证成功后,data里面对应的tokenId
2.2.参数示例
{
"serviceTypeId": "C647C6DC090E479395D4FDB94C07496F",
"supplierId": "41415068A1434A258ABE0AA22FB361AD",
"occurrence": 0,
"status": 0,
"dateTime": "2025-11-13 00:00:00",
"serverName":"xxxxxxxx",
"vehicleCurrentInfoList": [{
"vehicleId": "BB265AAF08ED407CBFE6E295328EA766",
"currentMileage": 125.5,
"currentEngineHours": 0
}, {
"vehicleId": "5F35BD2687C9454EAC4BF6D91A6D2E8E",
"currentMileage": 3546.2,
"currentEngineHours": 0
}],
"invoiceNum": "545454SSVC5656",
"descInfo": "ssssssssssssssssssss",
"attachmentFiles": "",
"workInfos": "[{\"id\":\"4C1BA7C87D2D48A3BA80DF0200A526CE\",\"count\":2,\"price\":30.00},{\"id\":\"DF29C1ADA353496084C5110BC36DAC2C\",\"count\":2,\"price\":30.00}]",
"partInfos": "[{\"id\":\"12D109E9EF9D4BBC88F8293A52556F17\",\"count\":2,\"price\":30.00},{\"id\":\"44B54D74E38343A08B883D3AD93364E3\",\"count\":2,\"price\":40.00}]",
"reminderList": [{
"reminderName": "Oil Change",
"nextReminder": "{\"dateTime\":\"2025-12-13\",\"mileage\":5000,\"motorHours\":6000}",
"repeatInterval": "{\"interval\":6,\"unitType\":3,\"mileage\":6000,\"motorHours\":2000}",
"notifyBefore": "{\"interval\":2,\"unitType\":2,\"mileage\":500,\"motorHours\":200}",
"subscribers": "[{\"type\":0},{\"type\":1,\"emailList\":[\"leave_iot@163.com\",\"leaveiot@163.com\"]}]"
}]
}
2.3.参数说明
| 字段 | 类型 | 说明 | 是否必须 |
|---|---|---|---|
| serviceTypeId | String | 服务类型唯一标识 | Y |
| supplierId | String | 供应商唯一标识 | Y |
| occurrence | Integer | 执行次数(0:单次服务;1:周期服务) | Y |
| status | Integer | 状态(默认为 0; 0 - 待处理、1 - 已完成) | Y |
| dateTime | String | 业务发生时间,格式为 “yyyy-MM-dd HH:mm:ss” | Y |
| serverName | String | 服务名称 | Y |
| vehicleCurrentInfoList | Array | 车辆当前信息列表,存储单台或多台车辆的实时状态数据 | Y |
| vehicleCurrentInfoList.vehicleId | String | 车辆唯一标识 | Y |
| vehicleCurrentInfoList.currentMileage | Double | 车辆当前里程数(单位:公里) | Y |
| vehicleCurrentInfoList.currentEngineHours | Integer | 车辆当前发动机运行时长(单位:小时,默认为 0) | N |
| invoiceNum | String | 发票编号,唯一标识一张发票 | Y |
| descInfo | String | 业务描述信息,用于记录业务相关备注、说明等 | Y |
| attachmentFiles | String | 附件文件URL,多个URL的JSON字符串 | N |
| workInfos | String | 工作项信息列表,JSON 格式字符串。存储工作项 ID、数量、单价等信息 | Y |
| workInfos.id | String | 工作项唯一标识 | |
| workInfos.count | Integer | 工作项数量 | Y |
| workInfos.price | Double | 工作项单价 | Y |
| workInfos.completed | int | 是否完成 | Y |
| workInfos.descInfo | Double | 描述 | Y |
| partInfos | String | 配件信息列表,JSON 格式字符串。存储配件 ID、数量、单价等信息 | Y |
| partInfos.id | String | 配件唯一标识 | Y |
| partInfos.partCode | String | 配件编码 | Y |
| partInfos.count | Integer | 配件数量 | Y |
| partInfos.price | Double | 配件单价 | Y |
| partInfos.descInfo | Double | 描述 | Y |
| reminderList | Array | 提醒任务列表,存储需要执行的提醒规则、下次提醒时间等信息 | Y |
| reminderList.reminderName | String | 提醒名称(如 “Oil Change - 换油提醒”) | Y |
| reminderList.nextReminder | String | 下次提醒信息,JSON 格式字符串。包含下次提醒时间(dateTime)、里程(mileage)、发动机时长(motorHours) | Y |
| reminderList.repeatInterval | String | 重复提醒间隔,JSON 格式字符串。interval - 间隔数值;unitType - 时间单位(如 1-天;2-周; 3 - 月);mileage - 里程间隔;motorHours - 发动机时长间隔 | Y |
| reminderList.notifyBefore | String | 提前通知配置,JSON 格式字符串。interval - 提前数值;unitType - 时间单位(如 1-天;2-周; 3 - 月);mileage - 提前里程;motorHours - 提前发动机时长 | Y |
| reminderList.subscribers | String | 订阅人列表,JSON 格式字符串。type - 订阅类型(0 - 产生报警,1 - 推送邮件通知);emailList - 指定订阅人邮箱数组(仅 type=1 时生效) | Y |
| reminderList.status | int | 1:关闭;2:超期;用户只需要关注激活/关闭;激活状态下通过时间判断是否超期 | Y |
3.接口应答
3.1.返回示例
{
"code": 200,
"message": "Operation succeeded",
"data": null
}
3.2.返回结果说明
| 字段 | 类型 | 说明 |
|---|---|---|
| code | int | 返回状态 |
| message | String | 返回结果描述 |
| data | object | 返回结果体 |
Author:admin Create time:2025-11-13 16:19
Last editor:admin Update time:2025-11-24 14:17
Last editor:admin Update time:2025-11-24 14:17