Commit ba384dc0 by rongkailun

Merge remote-tracking branch 'origin/master'

parents 210c56d9 76e5c9d1
...@@ -128,9 +128,7 @@ public class BikefirmController { ...@@ -128,9 +128,7 @@ public class BikefirmController {
//新增查询日志 //新增查询日志
searchgtinlogService.save(searchgtinlogEntity); searchgtinlogService.save(searchgtinlogEntity);
return R.ok(). return R.ok().put("data", bikefirmService.getBikeFirm(bikeFirmVo));
put("data", bikefirmService.getBikeFirm(bikeFirmVo));
} }
......
...@@ -41,9 +41,11 @@ public class CasesController { ...@@ -41,9 +41,11 @@ public class CasesController {
@RequestMapping("/api/frontList") @RequestMapping("/api/frontList")
@Login @Login
// @RequiresPermissions("manage:partners:list") // @RequiresPermissions("manage:partners:list")
public R frontList(){ public R frontList(@RequestBody Map<String, Object> params){
List<CasesEntity> casesList = this.casesService.frontList();
return R.ok().put("casesList", casesList); PageUtils pageUtils = new PageUtils(this.casesService.getPageList(params));
return R.ok().put("data", pageUtils);
} }
......
...@@ -42,8 +42,6 @@ public class LogLoginController { ...@@ -42,8 +42,6 @@ public class LogLoginController {
private SysCaptchaService sysCaptchaService; private SysCaptchaService sysCaptchaService;
/** /**
* 用户登录 * 用户登录
*/ */
...@@ -51,11 +49,11 @@ public class LogLoginController { ...@@ -51,11 +49,11 @@ public class LogLoginController {
@Login @Login
// @RequiresPermissions("manage:member:list") // @RequiresPermissions("manage:member:list")
public R login(@RequestBody Map<String, Object> params, HttpServletRequest request, HttpServletResponse response){ public R login(@RequestBody Map<String, Object> params, HttpServletRequest request, HttpServletResponse response){
/*DomesticCodeVo domesticCodeVo = new DomesticCodeVo(); DomesticCodeVo domesticCodeVo = new DomesticCodeVo(params.get("uuid").toString(),params.get("captcha").toString());
boolean captcha = sysCaptchaService.validate(domesticCodeVo.getUuid(), domesticCodeVo.getCaptcha()); boolean captcha = sysCaptchaService.validate(domesticCodeVo.getUuid(), domesticCodeVo.getCaptcha());
if(!captcha){ if(!captcha){
return R.error("验证码不正确"); return R.error("验证码不正确");
}*/ }
return R.ok().put("data",logLoginService.login(params,request,response)); return R.ok().put("data",logLoginService.login(params,request,response));
} }
......
...@@ -54,9 +54,11 @@ public class PartnersController extends AbstractController { ...@@ -54,9 +54,11 @@ public class PartnersController extends AbstractController {
@RequestMapping("/api/frontList") @RequestMapping("/api/frontList")
@Login @Login
// @RequiresPermissions("manage:partners:list") // @RequiresPermissions("manage:partners:list")
public R frontList(/*@RequestBody Map<String, Object> params*/){ public R frontList(@RequestBody Map<String, Object> params){
List<PartnersEntity> partnersList = this.partnersService.frontList(null);
return R.ok().put("partnersList", partnersList); PageUtils pageUtils = new PageUtils(this.partnersService.frontList(params));
return R.ok().put("data", pageUtils);
} }
......
...@@ -3,7 +3,9 @@ package io.office.modules.manage.controller; ...@@ -3,7 +3,9 @@ package io.office.modules.manage.controller;
import java.util.Arrays; import java.util.Arrays;
import java.util.Map; import java.util.Map;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import io.office.modules.app.annotation.Login; import io.office.modules.app.annotation.Login;
import io.office.modules.manage.entity.TycpdmFirmEntity;
import org.apache.shiro.authz.annotation.RequiresPermissions; import org.apache.shiro.authz.annotation.RequiresPermissions;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PathVariable; import org.springframework.web.bind.annotation.PathVariable;
...@@ -35,14 +37,26 @@ public class TycpdmFirmChangeController { ...@@ -35,14 +37,26 @@ public class TycpdmFirmChangeController {
/** /**
* 列表 * 列表
*/ */
@RequestMapping("/list") @RequestMapping("/authApi/findlist")
// @RequiresPermissions("manage:tycpdmfirmchange:list") // @RequiresPermissions("manage:tycpdmfirmchange:list")
public R list(@RequestParam Map<String, Object> params){ public R list(@RequestBody Map<String, Object> params){
PageUtils page = tycpdmFirmChangeService.queryPage(params); Page<TycpdmFirmChangeEntity> findlist = tycpdmFirmChangeService.findlist(params,
new Page(Integer.valueOf(params.get("page").toString()),
return R.ok().put("page", page); Integer.valueOf(params.get("limit").toString())));
PageUtils pageUtils = new PageUtils(findlist);
return R.ok().put("data", pageUtils);
} }
/**
* 根据用户名获取企业认证信息
*/
@RequestMapping("/authApi/findUserName")
// @RequiresPermissions("manage:tycpdmfirm:save")
public R findUserName(@RequestParam("userName") String userName){
TycpdmFirmChangeEntity userName1 = tycpdmFirmChangeService.findUserName(userName);
return R.ok().put("data",userName1);
}
/** /**
* 信息 * 信息
......
...@@ -12,6 +12,7 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page; ...@@ -12,6 +12,7 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import io.office.common.exception.RRException; import io.office.common.exception.RRException;
import io.office.modules.app.annotation.Login; import io.office.modules.app.annotation.Login;
import io.office.modules.manage.dao.MemberDao; import io.office.modules.manage.dao.MemberDao;
import io.office.modules.manage.dao.TycpdmFirmDao;
import io.office.modules.manage.entity.MemberEntity; import io.office.modules.manage.entity.MemberEntity;
import io.office.modules.manage.entity.ProductEntity; import io.office.modules.manage.entity.ProductEntity;
import io.office.modules.manage.entity.TycpdmFirmChangeEntity; import io.office.modules.manage.entity.TycpdmFirmChangeEntity;
...@@ -50,6 +51,8 @@ public class TycpdmFirmController extends AbstractController { ...@@ -50,6 +51,8 @@ public class TycpdmFirmController extends AbstractController {
private TycpdmFirmService tycpdmFirmService; private TycpdmFirmService tycpdmFirmService;
@Autowired @Autowired
private TycpdmFirmDao tycpdmFirmDao;
@Autowired
private TycpdmFirmChangeService tycpdmFirmChangeService; private TycpdmFirmChangeService tycpdmFirmChangeService;
@Autowired @Autowired
private MemberDao memberDao; private MemberDao memberDao;
...@@ -103,9 +106,10 @@ public class TycpdmFirmController extends AbstractController { ...@@ -103,9 +106,10 @@ public class TycpdmFirmController extends AbstractController {
*/ */
@RequestMapping("/authApi/save") @RequestMapping("/authApi/save")
// @RequiresPermissions("manage:tycpdmfirm:save") // @RequiresPermissions("manage:tycpdmfirm:save")
public R save(@RequestBody Map body,@RequestParam("status")int status ) throws InvocationTargetException, IllegalAccessException { public R save(@RequestBody Map body) throws InvocationTargetException, IllegalAccessException {
TycpdmFirmEntity tycpdmFirm = new TycpdmFirmEntity(); TycpdmFirmEntity tycpdmFirm = new TycpdmFirmEntity();
TycpdmFirmChangeEntity tycpdmFirmChangeEntity = new TycpdmFirmChangeEntity(); TycpdmFirmChangeEntity tycpdmFirmChangeEntity = new TycpdmFirmChangeEntity();
Integer status = body.get("status")==null?0:Integer.valueOf(String.valueOf(body.get("status")));
Integer id=0; Integer id=0;
if (status==1){ if (status==1){
...@@ -114,6 +118,14 @@ public class TycpdmFirmController extends AbstractController { ...@@ -114,6 +118,14 @@ public class TycpdmFirmController extends AbstractController {
if (baseUser==null){ if (baseUser==null){
throw new RRException("用户名不能为空"); throw new RRException("用户名不能为空");
} }
String firmname = tycpdmFirm.getFirmname();
if (firmname==null||"".equals(tycpdmFirm)){
throw new RRException("企业名称不能为空");
}
int count=tycpdmFirmDao.selectByIdFirmName(firmname,1);
if (count>0){
throw new RRException("企业名称已经存在");
}
//第一步不存储状态 第二部存储 //第一步不存储状态 第二部存储
//tycpdmFirm.setLogoutFlag(0); //审核状态 0待审核 1审核成功 2审核失败 //tycpdmFirm.setLogoutFlag(0); //审核状态 0待审核 1审核成功 2审核失败
tycpdmFirmService.save(tycpdmFirm); tycpdmFirmService.save(tycpdmFirm);
......
package io.office.modules.manage.dao; package io.office.modules.manage.dao;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import io.office.modules.manage.entity.CasesEntity; import io.office.modules.manage.entity.CasesEntity;
import com.baomidou.mybatisplus.core.mapper.BaseMapper; import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Mapper; import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select; import org.apache.ibatis.annotations.Select;
import java.util.List; import java.util.List;
...@@ -17,5 +19,5 @@ import java.util.List; ...@@ -17,5 +19,5 @@ import java.util.List;
@Mapper @Mapper
public interface CasesDao extends BaseMapper<CasesEntity> { public interface CasesDao extends BaseMapper<CasesEntity> {
@Select("select * from Cases where status=#{status} and levels>#{levels} order by id desc") @Select("select * from Cases where status=#{status} and levels>#{levels} order by id desc")
List<CasesEntity> selectByStatusAndLevels(String status, String levels); List<CasesEntity> selectByStatusAndLevels(@Param("status") String status,@Param("levels") String levels, Page page);
} }
...@@ -4,6 +4,7 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page; ...@@ -4,6 +4,7 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import io.office.modules.manage.entity.*; import io.office.modules.manage.entity.*;
import com.baomidou.mybatisplus.core.mapper.BaseMapper; import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import io.office.modules.manage.entity.dto.NewsParams; import io.office.modules.manage.entity.dto.NewsParams;
import io.office.modules.manage.vo.response.SearchVo;
import org.apache.ibatis.annotations.Mapper; import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param; import org.apache.ibatis.annotations.Param;
...@@ -92,4 +93,6 @@ public interface NewsDao extends BaseMapper<NewsEntity> { ...@@ -92,4 +93,6 @@ public interface NewsDao extends BaseMapper<NewsEntity> {
List<NewtopicEntity> zttjList(); List<NewtopicEntity> zttjList();
List<NewsEntity> relatedLinks(Map<String, Object> params); List<NewsEntity> relatedLinks(Map<String, Object> params);
List<SearchVo> getSearchInfo(@Param("name") String name,@Param("type") String type, Page page);
} }
package io.office.modules.manage.dao; package io.office.modules.manage.dao;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import io.office.modules.manage.entity.TycpdmFirmChangeEntity; import io.office.modules.manage.entity.TycpdmFirmChangeEntity;
import com.baomidou.mybatisplus.core.mapper.BaseMapper; import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import io.office.modules.manage.entity.TycpdmFirmEntity;
import org.apache.ibatis.annotations.Mapper; import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update; import org.apache.ibatis.annotations.Update;
import org.springframework.data.repository.query.Param; import org.springframework.data.repository.query.Param;
import java.util.List;
import java.util.Map;
/** /**
* ${comments} * ${comments}
* *
...@@ -20,4 +26,12 @@ public interface TycpdmFirmChangeDao extends BaseMapper<TycpdmFirmChangeEntity> ...@@ -20,4 +26,12 @@ public interface TycpdmFirmChangeDao extends BaseMapper<TycpdmFirmChangeEntity>
@Update("UPDATE tycpdm_firm_change SET logout_flag = #{logout_flag} WHERE id = #{id}") @Update("UPDATE tycpdm_firm_change SET logout_flag = #{logout_flag} WHERE id = #{id}")
void updateBYIdLogoutFlag(@Param("logout_flag") String logout_flag, @Param("id") String id); void updateBYIdLogoutFlag(@Param("logout_flag") String logout_flag, @Param("id") String id);
Integer findTycpdmFirmLogoutFlagCountALL(@Param("levels")Integer levels,@Param("logout_flag")Integer logout_flag);
List<TycpdmFirmChangeEntity> selectTycpdmFirmList(Map<String, Object> params, Page page);
@Select("select * from tycpdm_firm_change where base_user=#{userName}")
TycpdmFirmChangeEntity findUserName(@Param("userName") String userName);
} }
...@@ -35,4 +35,7 @@ public interface TycpdmFirmDao extends BaseMapper<TycpdmFirmEntity> { ...@@ -35,4 +35,7 @@ public interface TycpdmFirmDao extends BaseMapper<TycpdmFirmEntity> {
@Update("UPDATE tycpdm_firm SET logout_flag = #{logout_flag} WHERE f_id = #{id}") @Update("UPDATE tycpdm_firm SET logout_flag = #{logout_flag} WHERE f_id = #{id}")
void updateBYIdLogoutFlag(@Param("logout_flag") String logout_flag, @Param("id") String id); void updateBYIdLogoutFlag(@Param("logout_flag") String logout_flag, @Param("id") String id);
@Select("select count(1) from tycpdm_firm where firmName=#{firmname} and logout_flag=#{logout_flag}")
int selectByIdFirmName(@Param("firmname")String firmname, @Param("logout_flag")int logout_flag);
} }
package io.office.modules.manage.service; package io.office.modules.manage.service;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService; import com.baomidou.mybatisplus.extension.service.IService;
import io.office.common.utils.PageUtils; import io.office.common.utils.PageUtils;
import io.office.modules.manage.entity.CasesEntity; import io.office.modules.manage.entity.CasesEntity;
...@@ -18,7 +19,9 @@ public interface CasesService extends IService<CasesEntity> { ...@@ -18,7 +19,9 @@ public interface CasesService extends IService<CasesEntity> {
PageUtils queryPage(Map<String, Object> params); PageUtils queryPage(Map<String, Object> params);
List<CasesEntity> frontList();
Page<CasesEntity> getPageList(Map<String, Object> params);
} }
...@@ -6,6 +6,7 @@ import io.office.common.utils.PageUtils; ...@@ -6,6 +6,7 @@ import io.office.common.utils.PageUtils;
import io.office.common.utils.R; import io.office.common.utils.R;
import io.office.modules.manage.entity.*; import io.office.modules.manage.entity.*;
import io.office.modules.manage.entity.dto.NewsParams; import io.office.modules.manage.entity.dto.NewsParams;
import io.office.modules.manage.vo.response.SearchVo;
import io.office.modules.sys.entity.SysUserEntity; import io.office.modules.sys.entity.SysUserEntity;
import java.util.*; import java.util.*;
...@@ -90,5 +91,7 @@ public interface NewsService extends IService<NewsEntity> { ...@@ -90,5 +91,7 @@ public interface NewsService extends IService<NewsEntity> {
List<NewtopicEntity> zttjList(); List<NewtopicEntity> zttjList();
List<NewsEntity> relatedLinks(Map<String, Object> params); List<NewsEntity> relatedLinks(Map<String, Object> params);
Page<SearchVo> getSearchInfo(String name,String type, Page page);
} }
...@@ -27,6 +27,6 @@ public interface PartnersService extends IService<PartnersEntity> { ...@@ -27,6 +27,6 @@ public interface PartnersService extends IService<PartnersEntity> {
R verifyPartners(PartnersEntity partnersEntity, SysUserEntity user); R verifyPartners(PartnersEntity partnersEntity, SysUserEntity user);
List<PartnersEntity> frontList(Map<String, Object> params); Page<PartnersEntity> frontList(Map<String, Object> params);
} }
package io.office.modules.manage.service; package io.office.modules.manage.service;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService; import com.baomidou.mybatisplus.extension.service.IService;
import io.office.common.utils.PageUtils; import io.office.common.utils.PageUtils;
import io.office.modules.manage.entity.TycpdmFirmChangeEntity; import io.office.modules.manage.entity.TycpdmFirmChangeEntity;
import io.office.modules.manage.entity.TycpdmFirmEntity;
import org.springframework.web.multipart.MultipartFile; import org.springframework.web.multipart.MultipartFile;
import java.util.Map; import java.util.Map;
...@@ -19,5 +21,9 @@ public interface TycpdmFirmChangeService extends IService<TycpdmFirmChangeEntity ...@@ -19,5 +21,9 @@ public interface TycpdmFirmChangeService extends IService<TycpdmFirmChangeEntity
PageUtils queryPage(Map<String, Object> params); PageUtils queryPage(Map<String, Object> params);
void uploadFile(MultipartFile file, Integer id); void uploadFile(MultipartFile file, Integer id);
Page<TycpdmFirmChangeEntity> findlist(Map<String, Object> params, Page page);
TycpdmFirmChangeEntity findUserName(String userName);
} }
package io.office.modules.manage.service.impl; package io.office.modules.manage.service.impl;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.apache.commons.lang.StringUtils;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import java.util.List;
import java.util.Map; import java.util.Map;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage; import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
...@@ -21,6 +23,7 @@ public class CasesServiceImpl extends ServiceImpl<CasesDao, CasesEntity> impleme ...@@ -21,6 +23,7 @@ public class CasesServiceImpl extends ServiceImpl<CasesDao, CasesEntity> impleme
@Autowired @Autowired
private CasesDao casesDao; private CasesDao casesDao;
@Override @Override
public PageUtils queryPage(Map<String, Object> params) { public PageUtils queryPage(Map<String, Object> params) {
IPage<CasesEntity> page = this.page( IPage<CasesEntity> page = this.page(
...@@ -32,10 +35,27 @@ public class CasesServiceImpl extends ServiceImpl<CasesDao, CasesEntity> impleme ...@@ -32,10 +35,27 @@ public class CasesServiceImpl extends ServiceImpl<CasesDao, CasesEntity> impleme
} }
@Override @Override
public List<CasesEntity> frontList() { public Page<CasesEntity> getPageList(Map<String, Object> params) {
//E page, @Param("ew") Wrapper<T> queryWrapper
Page page = new Page(Integer.valueOf(params.get("page").toString()),
Integer.valueOf(params.get("size").toString()));
QueryWrapper<CasesEntity> queryWrapper = new QueryWrapper<>();
queryWrapper.eq("status", "1");
queryWrapper.gt("levels", "0");
if (params.get("title") != null && StringUtils.isNotBlank(params.get("title").toString())) {
queryWrapper.like("title", params.get("title").toString());
}
if (params.get("service") != null && StringUtils.isNotBlank(params.get("service").toString())) {
queryWrapper.like("service",params.get("service").toString());
}
return casesDao.selectPage(page, queryWrapper);
}
/* public List<CasesEntity> frontList() {
String status="1";//代表审核状态,编辑从后台提交专题后,默认初始状态为status=0,审核成功status=1,审核失败status=-1 String status="1";//代表审核状态,编辑从后台提交专题后,默认初始状态为status=0,审核成功status=1,审核失败status=-1
String levels="0";//levels代表级别,取值从0到9。其中,0代表隐藏,1级以上可以显示,9级为最高级 String levels="0";//levels代表级别,取值从0到9。其中,0代表隐藏,1级以上可以显示,9级为最高级
return casesDao.selectByStatusAndLevels(status,levels); return casesDao.selectByStatusAndLevels(status,levels,page);
} }*/
} }
\ No newline at end of file
...@@ -2,7 +2,9 @@ package io.office.modules.manage.service.impl; ...@@ -2,7 +2,9 @@ package io.office.modules.manage.service.impl;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page; import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import io.office.common.utils.R; import io.office.common.utils.R;
import io.office.modules.manage.entity.CasesEntity;
import io.office.modules.sys.entity.SysUserEntity; import io.office.modules.sys.entity.SysUserEntity;
import org.apache.commons.lang.StringUtils;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
...@@ -75,10 +77,28 @@ public class PartnersServiceImpl extends ServiceImpl<PartnersDao, PartnersEntity ...@@ -75,10 +77,28 @@ public class PartnersServiceImpl extends ServiceImpl<PartnersDao, PartnersEntity
} }
@Override @Override
public List<PartnersEntity> frontList(Map<String, Object> params) { public Page<PartnersEntity> frontList(Map<String, Object> params) {
String status="1";//代表审核状态,编辑从后台提交专题后,默认初始状态为status=0,审核成功status=1,审核失败status=-1 /* String status="1";//代表审核状态,编辑从后台提交专题后,默认初始状态为status=0,审核成功status=1,审核失败status=-1
String levels="0";//levels代表级别,取值从0到9。其中,0代表隐藏,1级以上可以显示,9级为最高级 String levels="0";//levels代表级别,取值从0到9。其中,0代表隐藏,1级以上可以显示,9级为最高级*/
return partnersDao.selectByStatusAndLevels(status,levels);
Page page = new Page(Integer.valueOf(params.get("page").toString()),
Integer.valueOf(params.get("size").toString()));
QueryWrapper<PartnersEntity> queryWrapper = new QueryWrapper<>();
queryWrapper.eq("status", "1");
queryWrapper.gt("levels", "0");
if (params.get("firmname") != null && StringUtils.isNotBlank(params.get("firmname").toString())) {
queryWrapper.like("firmname", params.get("firmname").toString());
}
if (params.get("service") != null && StringUtils.isNotBlank(params.get("service").toString())) {
queryWrapper.like("service",params.get("service").toString());
}
if (params.get("technology") != null && StringUtils.isNotBlank(params.get("technology").toString())) {
queryWrapper.like("technology",params.get("technology").toString());
}
return baseMapper.selectPage(page, queryWrapper);
//return partnersDao.selectByStatusAndLevels(status,levels);
} }
} }
\ No newline at end of file
package io.office.modules.manage.service.impl; package io.office.modules.manage.service.impl;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import io.office.common.exception.RRException; import io.office.common.exception.RRException;
import io.office.modules.manage.entity.TycpdmFirmEntity;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value; import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import java.io.File; import java.io.File;
import java.io.IOException; import java.io.IOException;
import java.util.List;
import java.util.Map; import java.util.Map;
import java.util.UUID; import java.util.UUID;
...@@ -84,4 +87,16 @@ public class TycpdmFirmChangeServiceImpl extends ServiceImpl<TycpdmFirmChangeDao ...@@ -84,4 +87,16 @@ public class TycpdmFirmChangeServiceImpl extends ServiceImpl<TycpdmFirmChangeDao
} }
} }
@Override
public Page<TycpdmFirmChangeEntity> findlist(Map<String, Object> params, Page page) {
List<TycpdmFirmChangeEntity> list = tycpdmFirmChangeDao.selectTycpdmFirmList(params,page);
page.setRecords(list);
return page;
}
@Override
public TycpdmFirmChangeEntity findUserName(String userName) {
return tycpdmFirmChangeDao.findUserName(userName);
}
} }
\ No newline at end of file
...@@ -89,6 +89,7 @@ public class TycpdmFirmServiceImpl extends ServiceImpl<TycpdmFirmDao, TycpdmFirm ...@@ -89,6 +89,7 @@ public class TycpdmFirmServiceImpl extends ServiceImpl<TycpdmFirmDao, TycpdmFirm
throw new RRException("无权访问"); throw new RRException("无权访问");
} }
//审核状态 0待审核 1审核成功 2审核失败 //审核状态 0待审核 1审核成功 2审核失败
//查询审核数据
Integer countAll=tycpdmFirmDao.findTycpdmFirmLogoutFlagCountALL(levels,null);//查询 申请总数 Integer countAll=tycpdmFirmDao.findTycpdmFirmLogoutFlagCountALL(levels,null);//查询 申请总数
Integer auditCount=tycpdmFirmDao.findTycpdmFirmLogoutFlagCountALL(levels,0);//查询 等待审核 0 Integer auditCount=tycpdmFirmDao.findTycpdmFirmLogoutFlagCountALL(levels,0);//查询 等待审核 0
Integer throughCount=tycpdmFirmDao.findTycpdmFirmLogoutFlagCountALL(levels,1);//查询 通过审核 1 Integer throughCount=tycpdmFirmDao.findTycpdmFirmLogoutFlagCountALL(levels,1);//查询 通过审核 1
...@@ -97,6 +98,15 @@ public class TycpdmFirmServiceImpl extends ServiceImpl<TycpdmFirmDao, TycpdmFirm ...@@ -97,6 +98,15 @@ public class TycpdmFirmServiceImpl extends ServiceImpl<TycpdmFirmDao, TycpdmFirm
map.put("auditCount",auditCount); map.put("auditCount",auditCount);
map.put("throughCount",throughCount); map.put("throughCount",throughCount);
map.put("notThroughCount",notThroughCount); map.put("notThroughCount",notThroughCount);
//查询变更数据
Integer countChangeAll=tycpdmFirmChangeDao.findTycpdmFirmLogoutFlagCountALL(levels,null);//查询 申请总数
Integer auditChangeCount=tycpdmFirmChangeDao.findTycpdmFirmLogoutFlagCountALL(levels,0);//查询 等待审核 0
Integer throughChangeCount=tycpdmFirmChangeDao.findTycpdmFirmLogoutFlagCountALL(levels,1);//查询 通过审核 1
Integer notThroughChangeCount=tycpdmFirmChangeDao.findTycpdmFirmLogoutFlagCountALL(levels,2);//查询 未通过审核 2
map.put("countChangeAll",countChangeAll);
map.put("auditChangeCount",auditChangeCount);
map.put("throughChangeCount",throughChangeCount);
map.put("notThroughChangeCount",notThroughChangeCount);
return map; return map;
} }
......
package io.office.modules.manage.utils;
import com.qiniu.util.Md5;
import org.apache.commons.lang.StringUtils;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.stereotype.Component;
/**
* 
 @description:
*
* @author wudi
* @date 10:47 2021/12/13
*/
@Component
public class LogUtils {
private static LogUtils logUtils;
private static Logger logger = null;
private static String switchStr = "Y";
private static boolean switchBoolean = false;
private LogUtils() {
logger = LoggerFactory.getLogger(LogUtils.class);
if (StringUtils.isNotBlank(switchStr) && switchStr.equalsIgnoreCase("Y")) {
switchBoolean = true;
}
}
// 使用 synchronized 修饰,临界资源的同步互斥访问
public static synchronized LogUtils getLogUtils() {
if (logUtils == null) {
logUtils = new LogUtils();
}
return logUtils;
}
public void printTime(Class clzss,String message, Long time) {
if (switchBoolean) {
logger.info("kafka >> [{}] [{}] 耗时:{} ms",clzss, message, System.currentTimeMillis() - time);
Runnable task = () -> {
System.out.println("记录日志.......");
};
Thread thread = new Thread(task);
thread.start();
}
}
public Long printCurrentTime(Class clzss) {
Long currentTime = System.currentTimeMillis();
if (switchBoolean) {
logger.info("kafka >> [{}] 当前时间:{}", clzss,currentTime);
}
return currentTime;
}
public void printMessage(String var1, Object... var2) {
logger.info(var1, var2);
}
public static void main(String[] args) {
//Long currentTime = LogUtils.getLogUtils().printCurrentTime();
// LogUtils.getLogUtils().printTime(Md5.class,"测试的方法", currentTime);
LogUtils.getLogUtils().printMessage("测试方法 {} {}","3","2");
System.out.println(LogUtils.getLogUtils() == LogUtils.getLogUtils());
}
}
...@@ -17,6 +17,11 @@ public class DomesticCodeVo implements Serializable { ...@@ -17,6 +17,11 @@ public class DomesticCodeVo implements Serializable {
private String captcha; private String captcha;
private String uuid; private String uuid;
public DomesticCodeVo(String uuid,String captcha) {
this.captcha = captcha;
this.uuid = uuid;
}
private String type; private String type;
private String code; private String code;
......
package io.office.modules.manage.vo.response;
import lombok.Data;
import java.io.Serializable;
import java.util.Date;
/**
*
* 
 @description:
*
* @author wudi
* @date 15:08 2021/12/14
*/
@Data
public class SearchVo implements Serializable {
private int id;
private String title;
private String keyword;
private String content;
private String type;
private String urlid;
private Date date;
private String source;
}
...@@ -607,4 +607,24 @@ AND Id != #{id} ...@@ -607,4 +607,24 @@ AND Id != #{id}
</if> </if>
order by releasedate desc order by releasedate desc
</select> </select>
<select id="getSearchInfo" parameterType="string" resultType="io.office.modules.manage.vo.response.SearchVo">
select * from NewsSearch
<where>
<if test="name!=null and name!=''">
(title like concat('%',#{name},'%') or keyword like concat('%',#{name},'%') or content like concat('%',#{name},'%'))
</if>
<if test="type!=null and type!=''">
and type in (${type})
</if>
</where>
</select>
</mapper> </mapper>
\ No newline at end of file
...@@ -55,4 +55,32 @@ ...@@ -55,4 +55,32 @@
</resultMap> </resultMap>
<select id="findTycpdmFirmLogoutFlagCountALL" parameterType="java.lang.Integer" resultType="java.lang.Integer">
select count(*) from tycpdm_firm_change a left join tycpdm_user_service b on a.f_id=b.f_id
where 1=1
<if test="levels ==-99">
and branchcode=#{levels}
</if>
<if test="logout_flag !=null">
and logout_flag=#{logout_flag}
</if>
and logout_flag &lt;&gt;-1;
</select>
<select id="selectTycpdmFirmList" resultMap="tycpdmFirmChangeMap" parameterType="java.util.Map">
select * from tycpdm_firm_change where 1=1
<if test="params.firmName !='' and params.firmName !=null">
and firmName like concat('%',#{params.firmName},'%')
</if>
<if test="params.logout_flag !='' and params.logout_flag !=null">
and logout_flag =#{params.logout_flag}
</if>
<if test="params.branchCode !='' and params.branchCode !=null">
and branchCode =#{params.branchCode}
</if>
</select>
</mapper> </mapper>
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment