package com.yd.dal.service.agms.impl;

import com.github.pagehelper.Page;
import com.github.pagehelper.PageHelper;
import com.github.pagehelper.PageInfo;
import com.yd.api.agms.vo.practitioner.PractitionerFileSharing;
import com.yd.dal.mapper.agms.AgmsPractitionerMapper;
import com.yd.dal.service.agms.AgmsPractitionerDALService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * @author xxy
 */
@Service("agmsPractitionerDALService")
public class AgmsPractitionerDALServiceImpl implements AgmsPractitionerDALService {

    @Autowired
    private AgmsPractitionerMapper mapper;
    @Override
    public PageInfo<PractitionerFileSharing> practitionerFileSharingList(Long[] mdDropOptionIds, Integer isActive, int pageNum, int size) {
        PageHelper.startPage(pageNum, size);
        Page<PractitionerFileSharing> practitionerFileShares = mapper.practitionerFileSharingList(mdDropOptionIds,isActive);
        PageInfo<PractitionerFileSharing> pageInfo = new PageInfo<>(practitionerFileShares);
        return pageInfo;
    }
}
