package com.wang.jintaidome.controller;

import com.wang.jintaidome.Constants;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.*;

import java.util.HashMap;
import java.util.Map;

@CrossOrigin
@RestController
@RequestMapping("/lqkj/inspect")
@Slf4j
public class InspectController {
    private static final String localMacString = "localMac";


    @PostMapping(value = "/mac")
    public Boolean inspectMac(@RequestBody(required = false) Map Mac) {
        if (null != Mac && null != Mac.get(localMacString)) {
            if (Constants.entity.containsKey(Mac.get(localMacString))) {
                return true;
            }
        }
        return false;
    }
}
