package com.sqx.modules.dlssqjl.service.impl;

import cn.hutool.core.date.DateTime;
import cn.hutool.core.date.DateUtil;
import cn.hutool.core.util.NumberUtil;
import com.alibaba.fastjson.JSONObject;
import com.baidu.aip.face.AipFace;
import com.baidu.aip.face.MatchRequest;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.core.toolkit.StringUtils;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.google.common.collect.Lists;
import com.google.common.collect.Maps;
import com.sqx.common.utils.PageUtils;
import com.sqx.common.utils.Result;
import com.sqx.face.FaceMain;
import com.sqx.map.CommonMapUtils;
import com.sqx.modules.app.entity.UserMoney;
import com.sqx.modules.app.service.UserMoneyService;
import com.sqx.modules.artificer.dao.ArtificerDao;
import com.sqx.modules.artificer.dao.OrdersDao;
import com.sqx.modules.artificer.dao.UserRechargeDao;
import com.sqx.modules.artificer.entity.*;
import com.sqx.modules.artificer.service.ArtificerService;
import com.sqx.modules.artificer.service.ArtificerTimeService;
import com.sqx.modules.artificer.service.CollectArtificerService;
import com.sqx.modules.common.dao.CommonInfoDao;
import com.sqx.modules.common.service.CommonInfoService;
import com.sqx.modules.dlssqjl.dao.DlssqjlDao;
import com.sqx.modules.dlssqjl.entity.Dlssqjl;
import com.sqx.modules.dlssqjl.service.DlssqjlService;
import com.sqx.modules.message.entity.MessageInfo;
import com.sqx.modules.message.service.MessageService;
import com.sqx.modules.pay.dao.CashOutDao;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.math.BigDecimal;
import java.math.RoundingMode;
import java.text.SimpleDateFormat;
import java.time.LocalDateTime;
import java.util.*;
import java.util.stream.Collectors;

import static com.sqx.modules.utils.PeriodUtil.calculationPeriod;


@Service
public class DlssqjlServiceImpl extends ServiceImpl<DlssqjlDao, Dlssqjl> implements DlssqjlService {


    @Override
    public Result selectDlssqjlPage(Integer page, Integer limit, String name, String phone) {
        Page<Dlssqjl> pages=new Page<>(page,limit);
        IPage<Dlssqjl> dlssqjlIPage = baseMapper.selectDlssqjlPage(pages, name, phone);
        return Result.success().put("data",new PageUtils(dlssqjlIPage));
    }
}