package com.backendsys.modules.system.controller;

import com.backendsys.modules.common.config.security.annotations.Anonymous;
import com.backendsys.modules.common.utils.Result;
import com.backendsys.modules.system.service.SysLanguageService;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.tags.Tag;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

@Validated
@RestController
@Tag(name = "语言枚举")
public class SysLanguageController {

    @Autowired
    private SysLanguageService sysLanguageService;

    @Anonymous
    @Operation(summary = "获取语言枚举值")
    @GetMapping("/api/system/language/getLanguageList")
    public Result getLanguageList() {
        return Result.success().put("data", sysLanguageService.selectLanguageList());
    }

}
