package com.friday.custody.service.basicService.impl;

import com.friday.custody.context.PublicDataStrategyContext;
import com.friday.custody.req.QueryDataReq;
import com.friday.custody.service.basicService.PublicDataBasicService;
import com.friday.custody.utils.R;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service("publicDataBasicService")
@Slf4j
public class PublicDataBasicServiceImpl implements PublicDataBasicService {

    @Autowired
    PublicDataStrategyContext publicDataStrategyContext;

    public R queryData(QueryDataReq vo) {
        log.info("查询公共数据成功：租户：{}，type：{}",vo.getTenantName(), vo.getType());
        return publicDataStrategyContext.getPublicData(vo);
    }
}
