Search in sources :

Example 1 with SysClient

use of vip.mate.system.entity.SysClient in project matecloud by matevip.

the class SysClientServiceImpl method status.

@Override
public boolean status(String ids, String status) {
    Collection<? extends Serializable> collection = CollectionUtil.stringToCollection(ids);
    for (Object id : collection) {
        SysClient sysClient = this.baseMapper.selectById(CollectionUtil.objectToLong(id, 0L));
        sysClient.setStatus(status);
        this.baseMapper.updateById(sysClient);
    }
    return true;
}
Also used : SysClient(vip.mate.system.entity.SysClient)

Example 2 with SysClient

use of vip.mate.system.entity.SysClient in project matecloud by matevip.

the class SysClientServiceImpl method export.

@Override
public List<SysClientPOI> export() {
    LambdaQueryWrapper<SysClient> queryWrapper = new LambdaQueryWrapper<>();
    queryWrapper.eq(SysClient::getIsDeleted, 0);
    List<SysClient> sysClients = this.baseMapper.selectList(queryWrapper);
    return sysClients.stream().map(sysClient -> {
        SysClientPOI sysClientPOI = new SysClientPOI();
        BeanUtils.copyProperties(sysClient, sysClientPOI);
        return sysClientPOI;
    }).collect(Collectors.toList());
}
Also used : ServiceImpl(com.baomidou.mybatisplus.extension.service.impl.ServiceImpl) Wrappers(com.baomidou.mybatisplus.core.toolkit.Wrappers) Search(vip.mate.core.database.entity.Search) SysClientMapper(vip.mate.system.mapper.SysClientMapper) Collection(java.util.Collection) LambdaQueryWrapper(com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper) PageUtil(vip.mate.core.database.util.PageUtil) Collectors(java.util.stream.Collectors) Serializable(java.io.Serializable) StrUtil(cn.hutool.core.util.StrUtil) SysClient(vip.mate.system.entity.SysClient) List(java.util.List) Service(org.springframework.stereotype.Service) IPage(com.baomidou.mybatisplus.core.metadata.IPage) ISysClientService(vip.mate.system.service.ISysClientService) BeanUtils(org.springframework.beans.BeanUtils) CollectionUtil(vip.mate.core.web.util.CollectionUtil) SysClientPOI(vip.mate.system.poi.SysClientPOI) SysClientPOI(vip.mate.system.poi.SysClientPOI) SysClient(vip.mate.system.entity.SysClient) LambdaQueryWrapper(com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper)

Aggregations

SysClient (vip.mate.system.entity.SysClient)2 StrUtil (cn.hutool.core.util.StrUtil)1 LambdaQueryWrapper (com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper)1 IPage (com.baomidou.mybatisplus.core.metadata.IPage)1 Wrappers (com.baomidou.mybatisplus.core.toolkit.Wrappers)1 ServiceImpl (com.baomidou.mybatisplus.extension.service.impl.ServiceImpl)1 Serializable (java.io.Serializable)1 Collection (java.util.Collection)1 List (java.util.List)1 Collectors (java.util.stream.Collectors)1 BeanUtils (org.springframework.beans.BeanUtils)1 Service (org.springframework.stereotype.Service)1 Search (vip.mate.core.database.entity.Search)1 PageUtil (vip.mate.core.database.util.PageUtil)1 CollectionUtil (vip.mate.core.web.util.CollectionUtil)1 SysClientMapper (vip.mate.system.mapper.SysClientMapper)1 SysClientPOI (vip.mate.system.poi.SysClientPOI)1 ISysClientService (vip.mate.system.service.ISysClientService)1