package com.izouma.nineth.web.mobile.open.v1;


import com.izouma.nineth.domain.AppVersion;
import com.izouma.nineth.service.AppVersionService;
import lombok.AllArgsConstructor;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/appVersion")
@AllArgsConstructor
public class AppVersionControllerOpenV1 {
    private final AppVersionService appVersionService;
    /**
     * 查看是否需要更新
     * @param appVersion 查看是否需要更新
     * @return
     */
    @PostMapping("/checkUpdate")
    public AppVersion checkUpdate(String platForm, String appVersion) {
        return appVersionService.checkUpdate(platForm, appVersion);
    }
}
