package com.fs.qywx.controller;

import com.fs.common.core.controller.BaseController;
import com.fs.common.core.domain.R;
import com.fs.common.core.page.TableDataInfo;
import com.fs.qywx.domain.QywxApp;
import com.fs.qywx.domain.QywxCompany;
import com.fs.qywx.service.IQywxAppService;
import com.fs.qywx.vo.QywxCompanyListVO;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * 企业微信三方应用授权公司Controller
 *
 * @author fs
 * @date 2023-12-11
 */
@RestController
@RequestMapping("/qywx/app")
public class QywxAppController extends BaseController {

    @Autowired
    private IQywxAppService qywxAppService;

    /**
     * 查询企业微信三方应用授权公司列表
     */
    @PreAuthorize("@ss.hasPermi('qywx:app:list')")
    @GetMapping("/alist")
    public R getList()
    {
        List<QywxApp> list = qywxAppService.selectQywxAppList(new QywxApp());
        return R.ok().put("data",list);
    }
}
