package org.springblade.third.doordevice.feign.qinlin;

import org.springblade.core.tool.api.R;
import org.springblade.third.doordevice.entity.QinlinApiLog;
import org.springblade.third.doordevice.entity.qinlin.*;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

/**
 * @author zwx
 * @create 2020/12/16 1:37
 */
@FeignClient(value = "cyzh-third", path = "/qinLin")
public interface IQLinClient {

    @PostMapping("/addUser")
    public R<String> addUser(@RequestBody QLinUser qLinUser);

    @PostMapping("/deleteUser")
    public R<String> deleteUser(@RequestBody QLinUser qLinUser);

    @PostMapping("/deleteUserPermission")
    public R<String> deleteUserPermission(@RequestBody QLinUserDevice qLinUserDevice);

    @PostMapping("/deleteDevice")
    public R<String> deleteDevice(@RequestBody QLinDevice qLinDevice);

    @PostMapping("/getDeviceInfo")
    public R<String> getDeviceInfo(@RequestBody QLinDevice qLinDevice);

    @PostMapping("/remoteOpenDoor")
    public R remoteOpenDoor(@RequestBody QLinUserDevice qLinUserDevice);

    @PostMapping("/getLogs")
    public R<String> getLogs(@RequestBody QLinQuery qLinQuery);

    @PostMapping(value = "/recordQinLinApiLog")
    public R<String> recordQinLinApiLog(@RequestBody QinlinApiLog qinlinApiLog);

    @PostMapping(value = "/addCommunity")
    public R<String> addCommunity(@RequestBody QLinCommunityDevices qLinCommunityDevices);

    @PostMapping(value = "/addDevices")
    public R<String> addDevices(@RequestBody QLinCommunityDevices qLinCommunityDevices);

}
