修改bug
This commit is contained in:
parent
94ace3d13e
commit
006f2e80e4
|
@ -80,6 +80,8 @@
|
||||||
<artifactId>hutool-http</artifactId>
|
<artifactId>hutool-http</artifactId>
|
||||||
<version>${hutool.version}</version>
|
<version>${hutool.version}</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
|
|
||||||
</dependencies>
|
</dependencies>
|
||||||
<build>
|
<build>
|
||||||
<plugins>
|
<plugins>
|
||||||
|
|
|
@ -0,0 +1,295 @@
|
||||||
|
package org.jeecg.modules.kc.blZycc.controller;
|
||||||
|
|
||||||
|
import java.util.Arrays;
|
||||||
|
import java.util.HashMap;
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
import java.util.stream.Collectors;
|
||||||
|
import java.io.IOException;
|
||||||
|
import java.io.UnsupportedEncodingException;
|
||||||
|
import java.net.URLDecoder;
|
||||||
|
import javax.servlet.http.HttpServletRequest;
|
||||||
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
|
import com.alibaba.fastjson.JSONObject;
|
||||||
|
import org.jeecg.common.api.vo.Result;
|
||||||
|
import org.jeecg.common.system.query.QueryGenerator;
|
||||||
|
import org.jeecg.common.util.SpringContextUtils;
|
||||||
|
import org.jeecg.common.util.oConvertUtils;
|
||||||
|
import org.jeecg.modules.kc.blZycc.entity.BlZycc;
|
||||||
|
import org.jeecg.modules.kc.blZycc.service.IBlZyccService;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||||
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||||
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
|
||||||
|
import org.jeecg.modules.tools.AuthService;
|
||||||
|
import org.jeecg.modules.tools.Global;
|
||||||
|
import org.jeecgframework.poi.excel.ExcelImportUtil;
|
||||||
|
import org.jeecgframework.poi.excel.def.NormalExcelConstants;
|
||||||
|
import org.jeecgframework.poi.excel.entity.ExportParams;
|
||||||
|
import org.jeecgframework.poi.excel.entity.ImportParams;
|
||||||
|
import org.jeecgframework.poi.excel.view.JeecgEntityExcelView;
|
||||||
|
import org.jeecg.common.system.base.controller.JeecgController;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.beans.factory.annotation.Value;
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
import org.springframework.web.multipart.MultipartFile;
|
||||||
|
import org.springframework.web.multipart.MultipartHttpServletRequest;
|
||||||
|
import org.springframework.web.servlet.ModelAndView;
|
||||||
|
import com.alibaba.fastjson.JSON;
|
||||||
|
import io.swagger.annotations.Api;
|
||||||
|
import io.swagger.annotations.ApiOperation;
|
||||||
|
import org.jeecg.common.aspect.annotation.AutoLog;
|
||||||
|
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: bl_zycc
|
||||||
|
* @Author: jeecg-boot
|
||||||
|
* @Date: 2024-04-13
|
||||||
|
* @Version: V1.0
|
||||||
|
*/
|
||||||
|
@Api(tags="bl_zycc")
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/blZycc/blZycc")
|
||||||
|
@Slf4j
|
||||||
|
public class BlZyccController extends JeecgController<BlZycc, IBlZyccService> {
|
||||||
|
@Autowired
|
||||||
|
private IBlZyccService blZyccService;
|
||||||
|
@Autowired
|
||||||
|
private AuthService authService;
|
||||||
|
|
||||||
|
private static String uploadpath;
|
||||||
|
|
||||||
|
@Value("${jeecg.path.upload}")
|
||||||
|
public void setUploadPath(String uploadPath) {
|
||||||
|
this.uploadpath = uploadPath;
|
||||||
|
}
|
||||||
|
// private static AuthService authService = SpringContextUtils.getBean(AuthService.class);
|
||||||
|
/**
|
||||||
|
* 分页列表查询
|
||||||
|
*
|
||||||
|
* @param blZycc
|
||||||
|
* @param pageNo
|
||||||
|
* @param pageSize
|
||||||
|
* @param req
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
//@AutoLog(value = "bl_zycc-分页列表查询")
|
||||||
|
@ApiOperation(value="bl_zycc-分页列表查询", notes="bl_zycc-分页列表查询")
|
||||||
|
@GetMapping(value = "/list")
|
||||||
|
public Result<IPage<BlZycc>> queryPageList(BlZycc blZycc,
|
||||||
|
@RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
|
||||||
|
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
|
||||||
|
HttpServletRequest req) {
|
||||||
|
QueryWrapper<BlZycc> queryWrapper = QueryGenerator.initQueryWrapper(blZycc, req.getParameterMap());
|
||||||
|
Page<BlZycc> page = new Page<BlZycc>(pageNo, pageSize);
|
||||||
|
IPage<BlZycc> pageList = blZyccService.page(page, queryWrapper);
|
||||||
|
return Result.OK(pageList);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 添加
|
||||||
|
*
|
||||||
|
* @param blZycc
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@AutoLog(value = "bl_zycc-添加")
|
||||||
|
@ApiOperation(value="bl_zycc-添加", notes="bl_zycc-添加")
|
||||||
|
@PostMapping(value = "/add")
|
||||||
|
public Result<String> add(@RequestBody BlZycc blZycc) {
|
||||||
|
blZyccService.save(blZycc);
|
||||||
|
return Result.OK("添加成功!");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 编辑
|
||||||
|
*
|
||||||
|
* @param blZycc
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@AutoLog(value = "bl_zycc-编辑")
|
||||||
|
@ApiOperation(value="bl_zycc-编辑", notes="bl_zycc-编辑")
|
||||||
|
@RequestMapping(value = "/edit", method = {RequestMethod.PUT,RequestMethod.POST})
|
||||||
|
public Result<String> edit(@RequestBody BlZycc blZycc) {
|
||||||
|
blZyccService.updateById(blZycc);
|
||||||
|
return Result.OK("编辑成功!");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 通过id删除
|
||||||
|
*
|
||||||
|
* @param id
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@AutoLog(value = "bl_zycc-通过id删除")
|
||||||
|
@ApiOperation(value="bl_zycc-通过id删除", notes="bl_zycc-通过id删除")
|
||||||
|
@DeleteMapping(value = "/delete")
|
||||||
|
public Result<String> delete(@RequestParam(name="id",required=true) String id) {
|
||||||
|
blZyccService.removeById(id);
|
||||||
|
return Result.OK("删除成功!");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除
|
||||||
|
*
|
||||||
|
* @param ids
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@AutoLog(value = "bl_zycc-批量删除")
|
||||||
|
@ApiOperation(value="bl_zycc-批量删除", notes="bl_zycc-批量删除")
|
||||||
|
@RequiresPermissions("blZycc:bl_zycc:deleteBatch")
|
||||||
|
@DeleteMapping(value = "/deleteBatch")
|
||||||
|
public Result<String> deleteBatch(@RequestParam(name="ids",required=true) String ids) {
|
||||||
|
this.blZyccService.removeByIds(Arrays.asList(ids.split(",")));
|
||||||
|
return Result.OK("批量删除成功!");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 通过id查询
|
||||||
|
*
|
||||||
|
* @param id
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
//@AutoLog(value = "bl_zycc-通过id查询")
|
||||||
|
@ApiOperation(value="bl_zycc-通过id查询", notes="bl_zycc-通过id查询")
|
||||||
|
@GetMapping(value = "/queryById")
|
||||||
|
public Result<BlZycc> queryById(@RequestParam(name="id",required=true) String id) {
|
||||||
|
BlZycc blZycc = blZyccService.getById(id);
|
||||||
|
if(blZycc==null) {
|
||||||
|
return Result.error("未找到对应数据");
|
||||||
|
}
|
||||||
|
return Result.OK(blZycc);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 导出excel
|
||||||
|
*
|
||||||
|
* @param request
|
||||||
|
* @param blZycc
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("blZycc:bl_zycc:exportXls")
|
||||||
|
@RequestMapping(value = "/exportXls")
|
||||||
|
public ModelAndView exportXls(HttpServletRequest request, BlZycc blZycc) {
|
||||||
|
return super.exportXls(request, blZycc, BlZycc.class, "bl_zycc");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 通过excel导入数据
|
||||||
|
*
|
||||||
|
* @param request
|
||||||
|
* @param response
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("blZycc:bl_zycc:importExcel")
|
||||||
|
@RequestMapping(value = "/importExcel", method = RequestMethod.POST)
|
||||||
|
public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) {
|
||||||
|
return super.importExcel(request, response, BlZycc.class);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@AutoLog(value = "维普外网上传")
|
||||||
|
@ApiOperation(value="维普外网上传", notes="维普外网上传")
|
||||||
|
@PostMapping(value = "/zyccUpload")
|
||||||
|
public Result<BlZycc> zyccUpload(@RequestBody BlZycc blZycc) {
|
||||||
|
BlZycc blZyccPar =blZyccService.zyccUpload(blZycc);
|
||||||
|
return Result.OK(blZyccPar);
|
||||||
|
}
|
||||||
|
|
||||||
|
@AutoLog(value = "维普外网开始检测")
|
||||||
|
@ApiOperation(value="维普外网开始检测", notes="维普外网开始检测")
|
||||||
|
@PostMapping(value = "/wwKsjc")
|
||||||
|
public Result<String> wwKsjc(@RequestBody BlZycc blZycc) {
|
||||||
|
blZyccService.wwKsjc(blZycc);
|
||||||
|
return Result.OK("添加成功!");
|
||||||
|
}
|
||||||
|
|
||||||
|
@AutoLog(value = "维普外网检测结果")
|
||||||
|
@ApiOperation(value="维普外网检测结果", notes="维普外网检测结果")
|
||||||
|
@PostMapping(value = "/wwCxjcjg")
|
||||||
|
public Result<Map<String,String>> wwCxjcjg(@RequestBody BlZycc blZycc) {
|
||||||
|
Map<String,String> map = blZyccService.wwCxjcjg(blZycc);
|
||||||
|
return Result.OK(map);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@AutoLog(value = "小范围比对上传")
|
||||||
|
@ApiOperation(value="小范围比对上传", notes="小范围比对上传")
|
||||||
|
@PostMapping(value = "/xfwbdUpload")
|
||||||
|
public Result<BlZycc> xfwbdUpload(@RequestBody BlZycc blZycc) {
|
||||||
|
blZycc.setPaperid(blZycc.getXnpaperid());
|
||||||
|
blZycc.setFilePath(blZycc.getXnfilePath());
|
||||||
|
BlZycc blZyccPar = blZyccService.xfwbdUpload(blZycc);
|
||||||
|
return Result.OK(blZyccPar);
|
||||||
|
}
|
||||||
|
|
||||||
|
@AutoLog(value = "小范围比对开始检测")
|
||||||
|
@ApiOperation(value="小范围比对开始检测", notes="小范围比对开始检测")
|
||||||
|
@PostMapping(value = "/xfwbdKsjc")
|
||||||
|
public Result<String> xfwbdKsjc(@RequestBody BlZycc blZycc) {
|
||||||
|
blZyccService.xfwbdKsjc(blZycc);
|
||||||
|
return Result.OK("添加成功!");
|
||||||
|
}
|
||||||
|
|
||||||
|
@AutoLog(value = "小范围比对查询检测结果")
|
||||||
|
@ApiOperation(value="小范围比对查询检测结果", notes="小范围比对查询检测结果")
|
||||||
|
@PostMapping(value = "/xfwbdCxjcjg")
|
||||||
|
public Result<Map<String,String>> xfwbdCxjcjg(@RequestBody BlZycc blZycc) {
|
||||||
|
blZycc.setPaperid(blZycc.getXnpaperid());
|
||||||
|
Map<String,String> map = blZyccService.xfwbdCxjcjg(blZycc);
|
||||||
|
return Result.OK(map);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@AutoLog(value = "维普aigc上传")
|
||||||
|
@ApiOperation(value="维普aigc上传", notes="维普aigc上传")
|
||||||
|
@PostMapping(value = "/aigcUpload")
|
||||||
|
public Result<BlZycc> aigcUpload(@RequestBody BlZycc blZycc) {
|
||||||
|
blZycc.setPaperid(blZycc.getAigcpaperid());
|
||||||
|
blZycc.setFilePath(blZycc.getAigcfilePath());
|
||||||
|
BlZycc blZyccPar = blZyccService.aigcUpload(blZycc);
|
||||||
|
return Result.OK(blZyccPar);
|
||||||
|
}
|
||||||
|
|
||||||
|
@AutoLog(value = "AIGC开始检测")
|
||||||
|
@ApiOperation(value="AIGC开始检测", notes="AIGC开始检测")
|
||||||
|
@PostMapping(value = "/aigcKsjc")
|
||||||
|
public Result<String> aigcKsjc(@RequestBody BlZycc blZycc) {
|
||||||
|
blZyccService.aigcKsjc(blZycc);
|
||||||
|
return Result.OK("添加成功!");
|
||||||
|
}
|
||||||
|
|
||||||
|
@AutoLog(value = "AIGC获取检测结果")
|
||||||
|
@ApiOperation(value="AIGC获取检测结果", notes="AIGC获取检测结果")
|
||||||
|
@PostMapping(value = "/aigcCxjcjg")
|
||||||
|
public Result<Map<String,String>> aigcCxjcjg(@RequestBody BlZycc blZycc) {
|
||||||
|
blZycc.setPaperid(blZycc.getAigcpaperid());
|
||||||
|
Map<String,String> map = blZyccService.aigcCxjcjg(blZycc);
|
||||||
|
return Result.OK(map);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@AutoLog(value = "获取图片比对人数接口")
|
||||||
|
@ApiOperation(value="获取图片比对人数接口", notes="获取图片比对人数接口")
|
||||||
|
@PostMapping(value = "/getPicPerno")
|
||||||
|
public Result<Map<String,String>> getPicPerno(@RequestBody BlZycc blZycc) {
|
||||||
|
Map<String,String> map = new HashMap<>();
|
||||||
|
// String sign = authService.getAuth();
|
||||||
|
// System.out.println("sign:--->"+sign);
|
||||||
|
String filePath = uploadpath+"/"+blZycc.getFacefilePath();
|
||||||
|
String ret = authService.faceDetect(filePath);
|
||||||
|
JSONObject object= JSONObject.parseObject(ret);
|
||||||
|
JSONObject object2= JSONObject.parseObject(object.get("result").toString());
|
||||||
|
map.put("facenum",object2.getString("face_num"));
|
||||||
|
return Result.OK(map);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
}
|
|
@ -0,0 +1,78 @@
|
||||||
|
package org.jeecg.modules.kc.blZycc.entity;
|
||||||
|
|
||||||
|
import java.io.Serializable;
|
||||||
|
import java.io.UnsupportedEncodingException;
|
||||||
|
import java.util.Date;
|
||||||
|
import java.math.BigDecimal;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.annotation.*;
|
||||||
|
import lombok.Data;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
import org.jeecgframework.poi.excel.annotation.Excel;
|
||||||
|
import org.jeecg.common.aspect.annotation.Dict;
|
||||||
|
import io.swagger.annotations.ApiModel;
|
||||||
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
|
import lombok.EqualsAndHashCode;
|
||||||
|
import lombok.experimental.Accessors;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: bl_zycc
|
||||||
|
* @Author: jeecg-boot
|
||||||
|
* @Date: 2024-04-13
|
||||||
|
* @Version: V1.0
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@TableName("bl_zycc")
|
||||||
|
@Accessors(chain = true)
|
||||||
|
@EqualsAndHashCode(callSuper = false)
|
||||||
|
@ApiModel(value="bl_zycc对象", description="bl_zycc")
|
||||||
|
public class BlZycc implements Serializable {
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
|
/**id*/
|
||||||
|
@TableId(type = IdType.ASSIGN_ID)
|
||||||
|
@ApiModelProperty(value = "id")
|
||||||
|
private java.lang.String id;
|
||||||
|
/**createBy*/
|
||||||
|
@ApiModelProperty(value = "createBy")
|
||||||
|
private java.lang.String createBy;
|
||||||
|
/**createTime*/
|
||||||
|
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
|
||||||
|
@DateTimeFormat(pattern="yyyy-MM-dd")
|
||||||
|
@ApiModelProperty(value = "createTime")
|
||||||
|
private java.util.Date createTime;
|
||||||
|
/**updateBy*/
|
||||||
|
@ApiModelProperty(value = "updateBy")
|
||||||
|
private java.lang.String updateBy;
|
||||||
|
/**updateTime*/
|
||||||
|
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
|
||||||
|
@DateTimeFormat(pattern="yyyy-MM-dd")
|
||||||
|
@ApiModelProperty(value = "updateTime")
|
||||||
|
private java.util.Date updateTime;
|
||||||
|
/**filePath*/
|
||||||
|
@Excel(name = "filePath", width = 15)
|
||||||
|
@ApiModelProperty(value = "filePath")
|
||||||
|
private java.lang.String filePath;
|
||||||
|
|
||||||
|
private String paperid;
|
||||||
|
private String cateid;
|
||||||
|
private String catename;
|
||||||
|
private String content;
|
||||||
|
// private String message;
|
||||||
|
|
||||||
|
@TableField(exist = false)
|
||||||
|
private String xnpaperid;
|
||||||
|
@TableField(exist = false)
|
||||||
|
private String aigcpaperid;
|
||||||
|
@TableField(exist = false)
|
||||||
|
private String xnfilePath;
|
||||||
|
@TableField(exist = false)
|
||||||
|
private String aigcfilePath;
|
||||||
|
@TableField(exist = false)
|
||||||
|
private String message;
|
||||||
|
@TableField(exist = false)
|
||||||
|
private String facefilePath;
|
||||||
|
|
||||||
|
|
||||||
|
}
|
|
@ -0,0 +1,17 @@
|
||||||
|
package org.jeecg.modules.kc.blZycc.mapper;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import org.apache.ibatis.annotations.Param;
|
||||||
|
import org.jeecg.modules.kc.blZycc.entity.BlZycc;
|
||||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: bl_zycc
|
||||||
|
* @Author: jeecg-boot
|
||||||
|
* @Date: 2024-04-13
|
||||||
|
* @Version: V1.0
|
||||||
|
*/
|
||||||
|
public interface BlZyccMapper extends BaseMapper<BlZycc> {
|
||||||
|
|
||||||
|
}
|
|
@ -0,0 +1,5 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||||
|
<mapper namespace="org.jeecg.modules.kc.blZycc.mapper.BlZyccMapper">
|
||||||
|
|
||||||
|
</mapper>
|
|
@ -0,0 +1,31 @@
|
||||||
|
package org.jeecg.modules.kc.blZycc.service;
|
||||||
|
|
||||||
|
import org.jeecg.modules.kc.blZycc.entity.BlZycc;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: bl_zycc
|
||||||
|
* @Author: jeecg-boot
|
||||||
|
* @Date: 2024-04-13
|
||||||
|
* @Version: V1.0
|
||||||
|
*/
|
||||||
|
public interface IBlZyccService extends IService<BlZycc> {
|
||||||
|
|
||||||
|
public BlZycc zyccUpload(BlZycc blZycc);
|
||||||
|
public String wwKsjc(BlZycc blZycc);
|
||||||
|
public Map<String,String> wwCxjcjg(BlZycc blZycc);
|
||||||
|
|
||||||
|
BlZycc aigcUpload(BlZycc blZycc);
|
||||||
|
|
||||||
|
BlZycc xfwbdUpload(BlZycc blZycc);
|
||||||
|
|
||||||
|
public String xfwbdKsjc(BlZycc blZycc);
|
||||||
|
|
||||||
|
public Map<String,String> xfwbdCxjcjg(BlZycc blZycc);
|
||||||
|
|
||||||
|
public String aigcKsjc(BlZycc blZycc);
|
||||||
|
|
||||||
|
public Map<String,String> aigcCxjcjg(BlZycc blZycc);
|
||||||
|
}
|
|
@ -0,0 +1,598 @@
|
||||||
|
package org.jeecg.modules.kc.blZycc.service.impl;
|
||||||
|
|
||||||
|
import com.alibaba.fastjson.JSON;
|
||||||
|
import com.alibaba.fastjson.JSONArray;
|
||||||
|
import com.alibaba.fastjson.JSONObject;
|
||||||
|
import org.apache.commons.lang3.StringUtils;
|
||||||
|
import org.jeecg.common.util.PmsUtil;
|
||||||
|
import org.jeecg.modules.kc.blZycc.entity.BlZycc;
|
||||||
|
import org.jeecg.modules.kc.blZycc.mapper.BlZyccMapper;
|
||||||
|
import org.jeecg.modules.kc.blZycc.service.IBlZyccService;
|
||||||
|
import org.springframework.beans.factory.annotation.Value;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
|
|
||||||
|
import javax.activation.MimetypesFileTypeMap;
|
||||||
|
import java.io.*;
|
||||||
|
import java.net.HttpURLConnection;
|
||||||
|
import java.net.URL;
|
||||||
|
import java.nio.charset.StandardCharsets;
|
||||||
|
import java.text.SimpleDateFormat;
|
||||||
|
import java.util.*;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: bl_zycc
|
||||||
|
* @Author: jeecg-boot
|
||||||
|
* @Date: 2024-04-13
|
||||||
|
* @Version: V1.0
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
public class BlZyccServiceImpl extends ServiceImpl<BlZyccMapper, BlZycc> implements IBlZyccService {
|
||||||
|
|
||||||
|
|
||||||
|
private static String uploadpath;//SpringContextUtils.getApplicationContext().getEnvironment().getProperty("jeecg.path.upload")
|
||||||
|
|
||||||
|
@Value("${jeecg.path.upload}")
|
||||||
|
public void setUploadPath(String uploadPath) {
|
||||||
|
this.uploadpath = uploadPath;
|
||||||
|
}
|
||||||
|
|
||||||
|
private static String weipuId;
|
||||||
|
|
||||||
|
@Value("${weipu.userId}")
|
||||||
|
public void setWeipuId(String weipuId) {
|
||||||
|
this.weipuId = weipuId;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
private static String weipuKey;
|
||||||
|
@Value("${weipu.userKey}")
|
||||||
|
public void setWeipuKey(String weipuKey) {
|
||||||
|
this.weipuKey = weipuKey;
|
||||||
|
}
|
||||||
|
|
||||||
|
private static String cateid = "20241111111111";//范围库唯一标识
|
||||||
|
private static String catename = "测试库";//范围库名称
|
||||||
|
|
||||||
|
//维普外网上传
|
||||||
|
@Override
|
||||||
|
public BlZycc zyccUpload(BlZycc blZycc) {
|
||||||
|
String url = "https://vims.fanyu.com/toole/jianceorgan/papersubmit.aspx";
|
||||||
|
//文件路径,文件存在,不存在的话需要先下载下来
|
||||||
|
String fileName = uploadpath+"/"+blZycc.getFilePath();
|
||||||
|
Map<String, String> textMap = new HashMap<String, String>();
|
||||||
|
//可以设置多个input的name,value
|
||||||
|
String sign = getSign();
|
||||||
|
textMap.put("userid", weipuId);
|
||||||
|
textMap.put("sign", sign);
|
||||||
|
String titlePar =fileName.substring(fileName.lastIndexOf("/")+1,fileName.length());
|
||||||
|
String title = titlePar.split("_")[0];
|
||||||
|
textMap.put("title", title);
|
||||||
|
textMap.put("author", "测试作者A");
|
||||||
|
//设置file的name,路径
|
||||||
|
Map<String, String> fileMap = new HashMap<String, String>();
|
||||||
|
fileMap.put("file", fileName);
|
||||||
|
String contentType = "";//image/png
|
||||||
|
String ret = formUpload(url, textMap, fileMap,contentType);
|
||||||
|
System.out.println("1-------->"+ret);
|
||||||
|
JSONObject object= JSONObject.parseObject(ret);
|
||||||
|
if("true".equals(object.getString("success"))){
|
||||||
|
String listpaper = object.getString("listpaper");
|
||||||
|
JSONArray jsonArray = (JSONArray) JSONArray.parse(listpaper);
|
||||||
|
JSONObject object2= jsonArray.getJSONObject(0);
|
||||||
|
String paperid = object2.getString("paperid");
|
||||||
|
System.out.println("2-------->"+paperid);
|
||||||
|
blZycc.setPaperid(paperid);
|
||||||
|
baseMapper.insert(blZycc);
|
||||||
|
|
||||||
|
//提交后直接开始检测
|
||||||
|
String message = wwKsjc(blZycc);
|
||||||
|
System.out.println("21-------->"+message);
|
||||||
|
blZycc.setMessage(message);
|
||||||
|
}else{
|
||||||
|
System.out.println("3-------->");
|
||||||
|
}
|
||||||
|
return blZycc;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String wwKsjc(BlZycc blZycc) {
|
||||||
|
String url = "https://vims.fanyu.com/toole/jianceorgan/paperbegincheck.aspx";
|
||||||
|
//文件路径,文件存在,不存在的话需要先下载下来
|
||||||
|
String paperid = blZycc.getPaperid();
|
||||||
|
Map<String, String> textMap = new HashMap<String, String>();
|
||||||
|
//可以设置多个input的name,value
|
||||||
|
String sign = getSign();
|
||||||
|
textMap.put("userid", weipuId);
|
||||||
|
textMap.put("sign", sign);
|
||||||
|
textMap.put("paperids", paperid);//资源id
|
||||||
|
String contentType = "";//image/png
|
||||||
|
Map<String, String> fileMap = new HashMap<String, String>();
|
||||||
|
String ret = formUpload(url, textMap, fileMap,contentType);
|
||||||
|
System.out.println("1--xfwbdKsjc------>"+ret);
|
||||||
|
JSONObject object= JSONObject.parseObject(ret);
|
||||||
|
String message = object.getString("message");
|
||||||
|
if("true".equals(object.getString("success"))){//返回值只有{"success":true,"message":"提交比对成功,资源开始比对..."}
|
||||||
|
System.out.println("message----->"+message);
|
||||||
|
}else{
|
||||||
|
System.out.println("3--xfwbdKsjc------>");
|
||||||
|
}
|
||||||
|
return message;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public Map<String,String> wwCxjcjg(BlZycc blZycc) {
|
||||||
|
String url = "https://vims.fanyu.com/toole/jianceorgan/paperlist.aspx";
|
||||||
|
//文件路径,文件存在,不存在的话需要先下载下来
|
||||||
|
String paperid = blZycc.getPaperid();
|
||||||
|
Map<String, String> textMap = new HashMap<String, String>();
|
||||||
|
//可以设置多个input的name,value
|
||||||
|
String sign = getSign();
|
||||||
|
textMap.put("userid", weipuId);
|
||||||
|
textMap.put("sign", sign);
|
||||||
|
textMap.put("paperids", paperid);//资源id,可多个,用逗号分割
|
||||||
|
String contentType = "";//image/png
|
||||||
|
Map<String, String> fileMap = new HashMap<String, String>();
|
||||||
|
String ret = formUpload(url, textMap, fileMap,contentType);
|
||||||
|
System.out.println("1-------->"+ret);
|
||||||
|
JSONObject object= JSONObject.parseObject(ret);
|
||||||
|
if("true".equals(object.getString("success"))){
|
||||||
|
//{"success":true,"message":"查询成功", "datalist":[{"dataid":568,"message":"","paperguid":"5c384d6bd69y9ba9","papertitle":"","filestateid":2,"paperword":1958,"percentage":0,"duplicatepercentage":0,"quotepercentage":0,"paichupercentage":0,"selfyypercentage":0,"ownpercentage":100,"authorpercentage":0,"checkdate":"2024-04-13 13:51:51","paperviewurl":"https://vims.fanyu.com/toole/smallcheck/getonlineurl?guid=5c384d6bd69y9ba9","paperdownurl":"https://vims.fanyu.com/toole/smallcheck/getdownloadurl?guid=5c384d6bd69y9ba9"}]}
|
||||||
|
//filestateid 检测状态{0未检测,1检测中,2检测完成, 3检测失败}
|
||||||
|
String listpaper = object.getString("listpaper");
|
||||||
|
JSONArray jsonArray = (JSONArray) JSONArray.parse(listpaper);
|
||||||
|
JSONObject object2= jsonArray.getJSONObject(0);
|
||||||
|
String filestateid = object2.getString("filestateid");
|
||||||
|
if(StringUtils.equals(filestateid,"0")){
|
||||||
|
System.out.println(paperid+":未检测");
|
||||||
|
}else if(StringUtils.equals(filestateid,"1")){
|
||||||
|
System.out.println(paperid+":检测中");
|
||||||
|
}else if(StringUtils.equals(filestateid,"2")){
|
||||||
|
System.out.println(paperid+":检测完成");
|
||||||
|
}else if(StringUtils.equals(filestateid,"3")){
|
||||||
|
System.out.println(paperid+":检测失败;"+object2.getString("message"));
|
||||||
|
}else{
|
||||||
|
System.out.println(paperid+":当前状态:"+filestateid+";"+object2.getString("message"));
|
||||||
|
}
|
||||||
|
System.out.println("listpaper----->"+listpaper);//结果结合
|
||||||
|
System.out.println("object2----->"+object2);//实际单挑数据结果
|
||||||
|
Map<String,String> map = new HashMap<String,String>();
|
||||||
|
map.put("duplicatepercentage",object2.getString("duplicatepercentage"));//复写率
|
||||||
|
map.put("paperdownurl",object2.getString("paperdownurl"));//报告下载地址
|
||||||
|
map.put("paperword",object2.getString("paperword"));//论文字数
|
||||||
|
map.put("paichupercentage",object2.getString("paichupercentage"));//他引率
|
||||||
|
map.put("paperviewurl",object2.getString("paperviewurl"));//报告在线查看地址
|
||||||
|
map.put("papertitle",object2.getString("papertitle"));//论文标题
|
||||||
|
map.put("ownpercentage",object2.getString("ownpercentage"));//自写率
|
||||||
|
map.put("percentage",object2.getString("percentage"));//相似率
|
||||||
|
map.put("paperguid",object2.getString("paperguid"));//报告编号
|
||||||
|
map.put("quotepercentage",object2.getString("quotepercentage"));//引用率
|
||||||
|
map.put("selfyypercentage",object2.getString("selfyypercentage"));//自引率
|
||||||
|
map.put("authorpercentage",object2.getString("authorpercentage"));//专业术语率
|
||||||
|
map.put("checkdate",object2.getString("checkdate"));//检测时间
|
||||||
|
map.put("papermsg",object2.getString("papermsg"));//其他信息
|
||||||
|
map.put("filestateid",object2.getString("filestateid"));//检测状态0:未检测;1:检测中;2:检测完成;3:检测失败;
|
||||||
|
map.put("message",object.getString("message"));
|
||||||
|
|
||||||
|
return map;
|
||||||
|
}else{
|
||||||
|
System.out.println("3-------->");
|
||||||
|
Map<String,String> map = new HashMap<String,String>();
|
||||||
|
map.put("success","false");
|
||||||
|
map.put("message",object.getString("message"));
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
//小范围比对上传文档
|
||||||
|
@Override
|
||||||
|
public BlZycc xfwbdUpload(BlZycc blZycc) {
|
||||||
|
String url = "https://vims.fanyu.com/toole/smallcheck/submitData";
|
||||||
|
//文件路径,文件存在,不存在的话需要先下载下来
|
||||||
|
String fileName = uploadpath+"/"+blZycc.getFilePath();
|
||||||
|
Map<String, String> textMap = new HashMap<String, String>();
|
||||||
|
String titlePar =fileName.substring(fileName.lastIndexOf("/")+1,fileName.length());
|
||||||
|
String title = titlePar.split("_")[0];
|
||||||
|
//可以设置多个input的name,value
|
||||||
|
String sign = getSign();
|
||||||
|
textMap.put("userid", weipuId);
|
||||||
|
textMap.put("sign", sign);
|
||||||
|
textMap.put("title", title);//标题
|
||||||
|
textMap.put("author", "test01");//作者
|
||||||
|
textMap.put("cateid", cateid);//范围库唯一标识
|
||||||
|
textMap.put("catename", catename);//范围库名称
|
||||||
|
//设置file的name,路径
|
||||||
|
Map<String, String> fileMap = new HashMap<String, String>();
|
||||||
|
fileMap.put("file", fileName);
|
||||||
|
String contentType = "";//image/png
|
||||||
|
String ret = formUpload(url, textMap, fileMap,contentType);
|
||||||
|
System.out.println("1-------->"+ret);
|
||||||
|
JSONObject object= JSONObject.parseObject(ret);
|
||||||
|
if("true".equals(object.getString("success"))){
|
||||||
|
String listpaper = object.getString("datainfo");
|
||||||
|
JSONObject object2= JSON.parseObject(listpaper);
|
||||||
|
String paperid = object2.getString("dataid");//资源id 后续提交比对/删除文档会试用
|
||||||
|
System.out.println("2-------->"+paperid);
|
||||||
|
blZycc.setPaperid(paperid);
|
||||||
|
blZycc.setXnpaperid(paperid);
|
||||||
|
blZycc.setCateid(cateid);
|
||||||
|
blZycc.setCatename(catename);
|
||||||
|
baseMapper.insert(blZycc);
|
||||||
|
|
||||||
|
//提交后直接开始检测
|
||||||
|
String message = xfwbdKsjc(blZycc);
|
||||||
|
System.out.println("21-------->"+message);
|
||||||
|
blZycc.setMessage(message);
|
||||||
|
}else{
|
||||||
|
System.out.println("3-------->");
|
||||||
|
}
|
||||||
|
return blZycc;
|
||||||
|
}
|
||||||
|
|
||||||
|
//小范围比对开始检测
|
||||||
|
@Override
|
||||||
|
public String xfwbdKsjc(BlZycc blZycc) {
|
||||||
|
String url = "https://vims.fanyu.com/toole/smallcheck/beginCheck";
|
||||||
|
//文件路径,文件存在,不存在的话需要先下载下来
|
||||||
|
String paperid = blZycc.getPaperid();
|
||||||
|
Map<String, String> textMap = new HashMap<String, String>();
|
||||||
|
//可以设置多个input的name,value
|
||||||
|
String sign = getSign();
|
||||||
|
textMap.put("userid", weipuId);
|
||||||
|
textMap.put("sign", sign);
|
||||||
|
textMap.put("cateid", cateid);//比对库的id
|
||||||
|
textMap.put("dataids", paperid);//资源id
|
||||||
|
String contentType = "";//image/png
|
||||||
|
Map<String, String> fileMap = new HashMap<String, String>();
|
||||||
|
String ret = formUpload(url, textMap, fileMap,contentType);
|
||||||
|
System.out.println("1--xfwbdKsjc------>"+ret);
|
||||||
|
JSONObject object= JSONObject.parseObject(ret);
|
||||||
|
// if("true".equals(object.getString("success"))){//返回值只有{"success":true,"message":"提交比对成功,资源开始比对..."}
|
||||||
|
//
|
||||||
|
// }else{
|
||||||
|
// System.out.println("3--xfwbdKsjc------>");
|
||||||
|
// }
|
||||||
|
String message = object.getString("message");
|
||||||
|
return message;
|
||||||
|
}
|
||||||
|
|
||||||
|
//小范围比对查询检测结果
|
||||||
|
@Override
|
||||||
|
public Map<String,String> xfwbdCxjcjg(BlZycc blZycc) {
|
||||||
|
String url = "https://vims.fanyu.com/toole/smallcheck/searchCheckStatus";
|
||||||
|
//文件路径,文件存在,不存在的话需要先下载下来
|
||||||
|
String paperid = blZycc.getPaperid();
|
||||||
|
Map<String, String> textMap = new HashMap<String, String>();
|
||||||
|
//可以设置多个input的name,value
|
||||||
|
String sign = getSign();
|
||||||
|
textMap.put("userid", weipuId);
|
||||||
|
textMap.put("sign", sign);
|
||||||
|
textMap.put("cateid", cateid);//比对库的id
|
||||||
|
textMap.put("dataids", paperid);//资源id
|
||||||
|
String contentType = "";//image/png
|
||||||
|
Map<String, String> fileMap = new HashMap<String, String>();
|
||||||
|
String ret = formUpload(url, textMap, fileMap,contentType);
|
||||||
|
System.out.println("1-------->"+ret);
|
||||||
|
JSONObject object= JSONObject.parseObject(ret);
|
||||||
|
if("true".equals(object.getString("success"))){
|
||||||
|
//{"success":true,"message":"查询成功", "datalist":[{"dataid":568,"message":"","paperguid":"5c384d6bd69y9ba9","papertitle":"","filestateid":2,"paperword":1958,"percentage":0,"duplicatepercentage":0,"quotepercentage":0,"paichupercentage":0,"selfyypercentage":0,"ownpercentage":100,"authorpercentage":0,"checkdate":"2024-04-13 13:51:51","paperviewurl":"https://vims.fanyu.com/toole/smallcheck/getonlineurl?guid=5c384d6bd69y9ba9","paperdownurl":"https://vims.fanyu.com/toole/smallcheck/getdownloadurl?guid=5c384d6bd69y9ba9"}]}
|
||||||
|
//filestateid 检测状态{0未检测,1检测中,2检测完成, 3检测失败}
|
||||||
|
String listpaper = object.getString("datalist");
|
||||||
|
JSONArray jsonArray = (JSONArray) JSONArray.parse(listpaper);
|
||||||
|
JSONObject object2= jsonArray.getJSONObject(0);
|
||||||
|
String filestateid = object2.getString("filestateid");
|
||||||
|
if(StringUtils.equals(filestateid,"0")){
|
||||||
|
System.out.println(paperid+":未检测");
|
||||||
|
}else if(StringUtils.equals(filestateid,"1")){
|
||||||
|
System.out.println(paperid+":检测中");
|
||||||
|
}else if(StringUtils.equals(filestateid,"2")){
|
||||||
|
System.out.println(paperid+":检测完成");
|
||||||
|
}else if(StringUtils.equals(filestateid,"3")){
|
||||||
|
System.out.println(paperid+":检测失败;"+object2.getString("message"));
|
||||||
|
}else{
|
||||||
|
System.out.println(paperid+":当前状态:"+filestateid+";"+object2.getString("message"));
|
||||||
|
}
|
||||||
|
System.out.println("listpaper----->"+listpaper);//结果结合
|
||||||
|
System.out.println("object2----->"+object2);//实际单挑数据结果
|
||||||
|
Map<String,String> map = new HashMap<String,String>();
|
||||||
|
map.put("duplicatepercentage",object2.getString("duplicatepercentage"));//复写率
|
||||||
|
map.put("paperdownurl",object2.getString("paperdownurl"));//报告下载地址
|
||||||
|
map.put("paperword",object2.getString("paperword"));//论文字数
|
||||||
|
map.put("paichupercentage",object2.getString("paichupercentage"));//他引率
|
||||||
|
map.put("paperviewurl",object2.getString("paperviewurl"));//报告在线查看地址
|
||||||
|
map.put("papertitle",object2.getString("papertitle"));//论文标题
|
||||||
|
map.put("ownpercentage",object2.getString("ownpercentage"));//自写率
|
||||||
|
map.put("percentage",object2.getString("percentage"));//相似率
|
||||||
|
map.put("paperguid",object2.getString("paperguid"));//报告编号
|
||||||
|
map.put("quotepercentage",object2.getString("quotepercentage"));//引用率
|
||||||
|
map.put("selfyypercentage",object2.getString("selfyypercentage"));//自引率
|
||||||
|
map.put("authorpercentage",object2.getString("authorpercentage"));//专业术语率
|
||||||
|
map.put("checkdate",object2.getString("checkdate"));//检测时间
|
||||||
|
map.put("papermsg",object2.getString("papermsg"));//其他信息
|
||||||
|
map.put("filestateid",object2.getString("filestateid"));//检测状态0:未检测;1:检测中;2:检测完成;3:检测失败;
|
||||||
|
map.put("message",object.getString("message"));
|
||||||
|
|
||||||
|
return map;
|
||||||
|
}else{
|
||||||
|
System.out.println("3-------->");
|
||||||
|
Map<String,String> map = new HashMap<String,String>();
|
||||||
|
map.put("success","false");
|
||||||
|
map.put("message",object.getString("message"));
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
//aigc上传
|
||||||
|
@Override
|
||||||
|
public BlZycc aigcUpload(BlZycc blZycc) {
|
||||||
|
|
||||||
|
String url = "https://vims.fanyu.com/tool/AIGCCheck/paperSubmit";
|
||||||
|
//文件路径,文件存在,不存在的话需要先下载下来
|
||||||
|
String fileName = uploadpath+"/"+blZycc.getFilePath();
|
||||||
|
Map<String, String> textMap = new HashMap<String, String>();
|
||||||
|
//可以设置多个input的name,value
|
||||||
|
String sign = getSign();
|
||||||
|
textMap.put("userid", weipuId);
|
||||||
|
textMap.put("sign", sign);
|
||||||
|
String titlePar =fileName.substring(fileName.lastIndexOf("/")+1,fileName.length());
|
||||||
|
String title = titlePar.split("_")[0];
|
||||||
|
textMap.put("title", title);
|
||||||
|
textMap.put("number", "202405112244");
|
||||||
|
textMap.put("author", "测试作者B");
|
||||||
|
//设置file的name,路径
|
||||||
|
Map<String, String> fileMap = new HashMap<String, String>();
|
||||||
|
fileMap.put("file", fileName);
|
||||||
|
String contentType = "";//image/png
|
||||||
|
String ret = formUpload(url, textMap, fileMap,contentType);
|
||||||
|
System.out.println("1-------->"+ret);
|
||||||
|
JSONObject object= JSONObject.parseObject(ret);
|
||||||
|
if("true".equals(object.getString("success"))){
|
||||||
|
|
||||||
|
|
||||||
|
String listpaper = object.getString("listPaper");
|
||||||
|
JSONArray jsonArray = (JSONArray) JSONArray.parse(listpaper);
|
||||||
|
JSONObject object2= jsonArray.getJSONObject(0);
|
||||||
|
String paperid = object2.getString("paperid");
|
||||||
|
System.out.println("2-------->"+paperid);
|
||||||
|
blZycc.setPaperid(paperid);
|
||||||
|
blZycc.setAigcpaperid(paperid);
|
||||||
|
baseMapper.insert(blZycc);
|
||||||
|
|
||||||
|
//提交后直接开始检测
|
||||||
|
String message = aigcKsjc(blZycc);
|
||||||
|
System.out.println("21-------->"+message);
|
||||||
|
blZycc.setMessage(message);
|
||||||
|
}else{
|
||||||
|
System.out.println("3-------->");
|
||||||
|
}
|
||||||
|
return blZycc;
|
||||||
|
}
|
||||||
|
|
||||||
|
//aigc开始检测
|
||||||
|
@Override
|
||||||
|
public String aigcKsjc(BlZycc blZycc) {
|
||||||
|
|
||||||
|
String url = "https://vims.fanyu.com/tool/AIGCCheck/paperBeginCheck\n";
|
||||||
|
//文件路径,文件存在,不存在的话需要先下载下来
|
||||||
|
String paperid = blZycc.getPaperid();
|
||||||
|
Map<String, String> textMap = new HashMap<String, String>();
|
||||||
|
//可以设置多个input的name,value
|
||||||
|
String sign = getSign();
|
||||||
|
textMap.put("userid", weipuId);
|
||||||
|
textMap.put("sign", sign);
|
||||||
|
textMap.put("paperids", paperid);//资源id
|
||||||
|
String contentType = "";//image/png
|
||||||
|
Map<String, String> fileMap = new HashMap<String, String>();
|
||||||
|
String ret = formUpload(url, textMap, fileMap,contentType);
|
||||||
|
System.out.println("1--xfwbdKsjc------>"+ret);
|
||||||
|
JSONObject object= JSONObject.parseObject(ret);
|
||||||
|
// if("true".equals(object.getString("success"))){//返回值只有{"success":true,"message":"提交比对成功,资源开始比对..."}
|
||||||
|
// String message = object.getString("message");
|
||||||
|
// System.out.println("message----->"+message);
|
||||||
|
// }else{
|
||||||
|
// System.out.println("3--xfwbdKsjc------>");
|
||||||
|
// }
|
||||||
|
String message = object.getString("message");
|
||||||
|
return message;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public Map<String,String> aigcCxjcjg(BlZycc blZycc) {
|
||||||
|
String url = "https://vims.fanyu.com/tool/AIGCCheck/searchPaper";
|
||||||
|
//文件路径,文件存在,不存在的话需要先下载下来
|
||||||
|
String paperid = blZycc.getPaperid();
|
||||||
|
Map<String, String> textMap = new HashMap<String, String>();
|
||||||
|
//可以设置多个input的name,value
|
||||||
|
String sign = getSign();
|
||||||
|
textMap.put("userid", weipuId);
|
||||||
|
textMap.put("sign", sign);
|
||||||
|
textMap.put("paperids", paperid);//资源id,可多个,用逗号分割
|
||||||
|
String contentType = "";//image/png
|
||||||
|
Map<String, String> fileMap = new HashMap<String, String>();
|
||||||
|
String ret = formUpload(url, textMap, fileMap,contentType);
|
||||||
|
System.out.println("1-------->"+ret);
|
||||||
|
JSONObject object= JSONObject.parseObject(ret);
|
||||||
|
if("true".equals(object.getString("success"))){
|
||||||
|
//{"success":true,"message":"查询成功", "datalist":[{"dataid":568,"message":"","paperguid":"5c384d6bd69y9ba9","papertitle":"","filestateid":2,"paperword":1958,"percentage":0,"duplicatepercentage":0,"quotepercentage":0,"paichupercentage":0,"selfyypercentage":0,"ownpercentage":100,"authorpercentage":0,"checkdate":"2024-04-13 13:51:51","paperviewurl":"https://vims.fanyu.com/toole/smallcheck/getonlineurl?guid=5c384d6bd69y9ba9","paperdownurl":"https://vims.fanyu.com/toole/smallcheck/getdownloadurl?guid=5c384d6bd69y9ba9"}]}
|
||||||
|
//filestateid 检测状态{0未检测,1检测中,2检测完成, 3检测失败}
|
||||||
|
String listpaper = object.getString("listpaper");
|
||||||
|
JSONArray jsonArray = (JSONArray) JSONArray.parse(listpaper);
|
||||||
|
JSONObject object2= jsonArray.getJSONObject(0);
|
||||||
|
String filestateid = object2.getString("filestateid");
|
||||||
|
if(StringUtils.equals(filestateid,"0")){
|
||||||
|
System.out.println(paperid+":未检测");
|
||||||
|
}else if(StringUtils.equals(filestateid,"1")){
|
||||||
|
System.out.println(paperid+":检测中");
|
||||||
|
}else if(StringUtils.equals(filestateid,"2")){
|
||||||
|
System.out.println(paperid+":检测完成");
|
||||||
|
}else if(StringUtils.equals(filestateid,"3")){
|
||||||
|
System.out.println(paperid+":检测失败;"+object2.getString("message"));
|
||||||
|
}else{
|
||||||
|
System.out.println(paperid+":当前状态:"+filestateid+";"+object2.getString("message"));
|
||||||
|
}
|
||||||
|
System.out.println("listpaper----->"+listpaper);//结果结合
|
||||||
|
System.out.println("object2----->"+object2);//实际单挑数据结果
|
||||||
|
Map<String,String> map = new HashMap<String,String>();
|
||||||
|
|
||||||
|
|
||||||
|
map.put("paperguid",object2.getString("paperguid"));//报告编号
|
||||||
|
map.put("papertitle",object2.getString("papertitle"));//论文标题
|
||||||
|
map.put("filestateid",object2.getString("filestateid"));//检测状态0:未检测;1:检测中;2:检测完成;3:检测失败;
|
||||||
|
map.put("checkdate",object2.getString("checkdate"));//检测时间
|
||||||
|
map.put("paperword",object2.getString("paperword"));//论文字数
|
||||||
|
map.put("aiRate",object2.getString("aiRate"));//疑似ai全文占比
|
||||||
|
map.put("humanRate",object2.getString("humanRate"));//人工占比
|
||||||
|
map.put("paperviewurl",object2.getString("paperviewurl"));//报告在线查看地址
|
||||||
|
map.put("paperdownurl",object2.getString("paperdownurl"));//报告下载地址
|
||||||
|
map.put("papermsg",object2.getString("papermsg"));//其他信息
|
||||||
|
|
||||||
|
// map.put("duplicatepercentage",object2.getString("duplicatepercentage"));//复写率
|
||||||
|
// map.put("paichupercentage",object2.getString("paichupercentage"));//他引率
|
||||||
|
// map.put("ownpercentage",object2.getString("ownpercentage"));//自写率
|
||||||
|
// map.put("percentage",object2.getString("percentage"));//相似率
|
||||||
|
// map.put("quotepercentage",object2.getString("quotepercentage"));//引用率
|
||||||
|
// map.put("selfyypercentage",object2.getString("selfyypercentage"));//自引率
|
||||||
|
// map.put("authorpercentage",object2.getString("authorpercentage"));//专业术语率
|
||||||
|
map.put("message",object.getString("message"));
|
||||||
|
|
||||||
|
return map;
|
||||||
|
}else{
|
||||||
|
System.out.println("3-------->");
|
||||||
|
Map<String,String> map = new HashMap<String,String>();
|
||||||
|
map.put("success","false");
|
||||||
|
map.put("message",object.getString("message"));
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
//生成sign
|
||||||
|
public static String getSign() {
|
||||||
|
String userid = weipuId;
|
||||||
|
String key = weipuKey;
|
||||||
|
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH");
|
||||||
|
String time = sdf.format( new Date());
|
||||||
|
String md5Text = userid + key + time;
|
||||||
|
String sign = org.springframework.util.DigestUtils.md5DigestAsHex((md5Text).getBytes()).toLowerCase();
|
||||||
|
return sign;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 上传图片
|
||||||
|
* @param urlStr
|
||||||
|
* @param textMap
|
||||||
|
* @param fileMap
|
||||||
|
* @param contentType 没有传入文件类型默认采用application/octet-stream
|
||||||
|
* contentType非空采用filename匹配默认的图片类型
|
||||||
|
* @return 返回response数据
|
||||||
|
*/
|
||||||
|
@SuppressWarnings("rawtypes")
|
||||||
|
public static String formUpload(String urlStr, Map<String, String> textMap,
|
||||||
|
Map<String, String> fileMap,String contentType) {
|
||||||
|
String res = "";
|
||||||
|
HttpURLConnection conn = null;
|
||||||
|
// boundary就是request头和上传文件内容的分隔符
|
||||||
|
String BOUNDARY = "---------------------------123821742118716";
|
||||||
|
try {
|
||||||
|
URL url = new URL(urlStr);
|
||||||
|
conn = (HttpURLConnection) url.openConnection();
|
||||||
|
conn.setConnectTimeout(5000);
|
||||||
|
conn.setReadTimeout(30000);
|
||||||
|
conn.setDoOutput(true);
|
||||||
|
conn.setDoInput(true);
|
||||||
|
conn.setUseCaches(false);
|
||||||
|
conn.setRequestMethod("POST");
|
||||||
|
conn.setRequestProperty("Connection", "Keep-Alive");
|
||||||
|
conn.setRequestProperty("Content-Type","multipart/form-data; boundary=" + BOUNDARY);
|
||||||
|
OutputStream out = new DataOutputStream(conn.getOutputStream());
|
||||||
|
// text
|
||||||
|
if (textMap != null) {
|
||||||
|
StringBuffer strBuf = new StringBuffer();
|
||||||
|
Iterator iter = textMap.entrySet().iterator();
|
||||||
|
while (iter.hasNext()) {
|
||||||
|
Map.Entry entry = (Map.Entry) iter.next();
|
||||||
|
String inputName = (String) entry.getKey();
|
||||||
|
String inputValue = (String) entry.getValue();
|
||||||
|
if (inputValue == null) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
strBuf.append("\r\n").append("--").append(BOUNDARY).append("\r\n");
|
||||||
|
strBuf.append("Content-Disposition: form-data; name=\"" + inputName + "\"\r\n\r\n");
|
||||||
|
strBuf.append(inputValue);
|
||||||
|
}
|
||||||
|
out.write(strBuf.toString().getBytes(StandardCharsets.UTF_8));
|
||||||
|
}
|
||||||
|
// file
|
||||||
|
if (fileMap != null) {
|
||||||
|
Iterator iter = fileMap.entrySet().iterator();
|
||||||
|
while (iter.hasNext()) {
|
||||||
|
Map.Entry entry = (Map.Entry) iter.next();
|
||||||
|
String inputName = (String) entry.getKey();
|
||||||
|
String inputValue = (String) entry.getValue();
|
||||||
|
if (inputValue == null) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
File file = new File(inputValue);
|
||||||
|
String filename = file.getName();
|
||||||
|
|
||||||
|
//没有传入文件类型,同时根据文件获取不到类型,默认采用application/octet-stream
|
||||||
|
contentType = new MimetypesFileTypeMap().getContentType(file);
|
||||||
|
//contentType非空采用filename匹配默认的图片类型
|
||||||
|
if(!"".equals(contentType)){
|
||||||
|
if (filename.endsWith(".png")) {
|
||||||
|
contentType = "image/png";
|
||||||
|
}else if (filename.endsWith(".jpg") || filename.endsWith(".jpeg") || filename.endsWith(".jpe")) {
|
||||||
|
contentType = "image/jpeg";
|
||||||
|
}else if (filename.endsWith(".gif")) {
|
||||||
|
contentType = "image/gif";
|
||||||
|
}else if (filename.endsWith(".ico")) {
|
||||||
|
contentType = "image/image/x-icon";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (contentType == null || "".equals(contentType)) {
|
||||||
|
contentType = "application/octet-stream";
|
||||||
|
}
|
||||||
|
StringBuffer strBuf = new StringBuffer();
|
||||||
|
strBuf.append("\r\n").append("--").append(BOUNDARY).append("\r\n");
|
||||||
|
strBuf.append("Content-Disposition: form-data; name=\"" + inputName + "\"; filename=\"" + filename + "\"\r\n");
|
||||||
|
strBuf.append("Content-Type:" + contentType + "\r\n\r\n");
|
||||||
|
out.write(strBuf.toString().getBytes());
|
||||||
|
DataInputStream in = new DataInputStream(new FileInputStream(file));
|
||||||
|
int bytes = 0;
|
||||||
|
byte[] bufferOut = new byte[1024];
|
||||||
|
while ((bytes = in.read(bufferOut)) != -1) {
|
||||||
|
out.write(bufferOut, 0, bytes);
|
||||||
|
}
|
||||||
|
in.close();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
byte[] endData = ("\r\n--" + BOUNDARY + "--\r\n").getBytes();
|
||||||
|
out.write(endData);
|
||||||
|
out.flush();
|
||||||
|
out.close();
|
||||||
|
// 读取返回数据
|
||||||
|
StringBuffer strBuf = new StringBuffer();
|
||||||
|
BufferedReader reader = new BufferedReader(new InputStreamReader(conn.getInputStream()));
|
||||||
|
String line = null;
|
||||||
|
while ((line = reader.readLine()) != null) {
|
||||||
|
strBuf.append(line).append("\n");
|
||||||
|
}
|
||||||
|
res = strBuf.toString();
|
||||||
|
reader.close();
|
||||||
|
reader = null;
|
||||||
|
} catch (Exception e) {
|
||||||
|
System.out.println("发送POST请求出错。" + urlStr);
|
||||||
|
e.printStackTrace();
|
||||||
|
} finally {
|
||||||
|
if (conn != null) {
|
||||||
|
conn.disconnect();
|
||||||
|
conn = null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return res;
|
||||||
|
}
|
||||||
|
}
|
|
@ -3,6 +3,7 @@ package org.jeecg.modules.kc.grab.SynchronizationService;
|
||||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||||
import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
|
import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
|
||||||
import lombok.extern.slf4j.Slf4j;
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.apache.commons.lang3.StringUtils;
|
||||||
import org.jeecg.common.api.vo.Result;
|
import org.jeecg.common.api.vo.Result;
|
||||||
import org.jeecg.common.util.DateUtils;
|
import org.jeecg.common.util.DateUtils;
|
||||||
import org.jeecg.modules.kc.grab.SynchronizationService.base.BaseSync;
|
import org.jeecg.modules.kc.grab.SynchronizationService.base.BaseSync;
|
||||||
|
@ -11,6 +12,8 @@ import org.jeecg.modules.kc.kcKetangbiaoSkrqLog.entity.KcKetangbiaoSkrqLog;
|
||||||
import org.jeecg.modules.kc.kcKetangbiaoSkrqLog.service.IKcKetangbiaoSkrqLogService;
|
import org.jeecg.modules.kc.kcKetangbiaoSkrqLog.service.IKcKetangbiaoSkrqLogService;
|
||||||
import org.jeecg.modules.kc.kcSysConfig.entity.KcSysConfig;
|
import org.jeecg.modules.kc.kcSysConfig.entity.KcSysConfig;
|
||||||
import org.jeecg.modules.kc.kcSysConfig.service.IKcSysConfigService;
|
import org.jeecg.modules.kc.kcSysConfig.service.IKcSysConfigService;
|
||||||
|
import org.jeecg.modules.kc.kcTtksdpz.entity.KcTtksdpz;
|
||||||
|
import org.jeecg.modules.kc.kcTtksdpz.service.IKcTtksdpzService;
|
||||||
import org.jeecg.modules.kc.kcXqxnHistory.service.IKcXqxnHistoryService;
|
import org.jeecg.modules.kc.kcXqxnHistory.service.IKcXqxnHistoryService;
|
||||||
import org.jeecg.modules.kc.ktgl.entity.KcKechengbiao;
|
import org.jeecg.modules.kc.ktgl.entity.KcKechengbiao;
|
||||||
import org.jeecg.modules.kc.ktgl.entity.KcKetangbiao;
|
import org.jeecg.modules.kc.ktgl.entity.KcKetangbiao;
|
||||||
|
@ -51,6 +54,9 @@ public class SyncKcktStat extends BaseSync {
|
||||||
@Autowired
|
@Autowired
|
||||||
private IKcKetangbiaoSkrqLogService kcKetangbiaoSkrqLogService;
|
private IKcKetangbiaoSkrqLogService kcKetangbiaoSkrqLogService;
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private IKcTtksdpzService kcTtksdpzService;
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void execute(JobExecutionContext jobExecutionContext) {
|
public void execute(JobExecutionContext jobExecutionContext) {
|
||||||
start();
|
start();
|
||||||
|
@ -198,6 +204,54 @@ public class SyncKcktStat extends BaseSync {
|
||||||
KcKetangbiaoUpdateWrapper.eq("skrq",KcKetangbiaoSkrqLog.getSkrq());
|
KcKetangbiaoUpdateWrapper.eq("skrq",KcKetangbiaoSkrqLog.getSkrq());
|
||||||
kcKetangbiaoService.update(KcKetangbiaoUpdateWrapper);
|
kcKetangbiaoService.update(KcKetangbiaoUpdateWrapper);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
//---------------------20240416新增手动调停课逻辑------------------
|
||||||
|
try {
|
||||||
|
String dqsj = DateUtils.formatDate(dateNow,"yyyy-MM-dd");
|
||||||
|
QueryWrapper<KcTtksdpz> kcTtksdpzQueryWrapper = new QueryWrapper<>();
|
||||||
|
kcTtksdpzQueryWrapper.eq("fjsj",dqsj);
|
||||||
|
List<KcTtksdpz> sdpzList = kcTtksdpzService.list(kcTtksdpzQueryWrapper);
|
||||||
|
// 停课:代表在放假时间内,不上课
|
||||||
|
// 调课:放假时间上调课时间内的课程
|
||||||
|
for(KcTtksdpz kcTtksdpz:sdpzList){
|
||||||
|
String tklx = kcTtksdpz.getTklx();
|
||||||
|
if(StringUtils.equals("1",tklx)){//调课
|
||||||
|
String fjsj = DateUtils.formatDate(kcTtksdpz.getFjsj(),"yyyy-MM-dd");//放假时间
|
||||||
|
String tksj = DateUtils.formatDate(kcTtksdpz.getTksj(),"yyyy-MM-dd");//调课时间
|
||||||
|
|
||||||
|
//更具调课时间修改成放假时间
|
||||||
|
UpdateWrapper<KcKetangbiao> KcKetangbiaoUpdateWrapper = new UpdateWrapper<>();
|
||||||
|
KcKetangbiaoUpdateWrapper.set("skrq",fjsj);
|
||||||
|
KcKetangbiaoUpdateWrapper.set("is_delete","0");
|
||||||
|
KcKetangbiaoUpdateWrapper.eq("skrq",tksj);
|
||||||
|
kcKetangbiaoService.update(KcKetangbiaoUpdateWrapper);
|
||||||
|
|
||||||
|
kcTtksdpz.setZxsj(dateNow);
|
||||||
|
kcTtksdpz.setZxsql1("update kc_ketangbiao set skrq = '"+fjsj+"' , is_delete = '0' where skrq = '"+tksj+"'");
|
||||||
|
kcTtksdpzService.updateById(kcTtksdpz);
|
||||||
|
}else if(StringUtils.equals("0",tklx)){//停课
|
||||||
|
String fjsj = DateUtils.formatDate(kcTtksdpz.getFjsj(),"yyyy-MM-dd");//放假时间
|
||||||
|
|
||||||
|
//更具调课时间修改成放假时间
|
||||||
|
UpdateWrapper<KcKetangbiao> KcKetangbiaoUpdateWrapper = new UpdateWrapper<>();
|
||||||
|
KcKetangbiaoUpdateWrapper.set("is_delete","1");
|
||||||
|
KcKetangbiaoUpdateWrapper.eq("skrq",fjsj);
|
||||||
|
kcKetangbiaoService.update(KcKetangbiaoUpdateWrapper);
|
||||||
|
|
||||||
|
kcTtksdpz.setZxsj(dateNow);
|
||||||
|
kcTtksdpz.setZxsql1("update kc_ketangbiao set is_delete = '0' where skrq = '"+fjsj+"'");
|
||||||
|
kcTtksdpzService.updateById(kcTtksdpz);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} catch (Exception e){
|
||||||
|
e.printStackTrace();
|
||||||
|
}
|
||||||
|
|
||||||
|
//---------------------20240416新增手动调停课逻辑------------------
|
||||||
|
|
||||||
|
|
||||||
}catch (Exception e){
|
}catch (Exception e){
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
}
|
}
|
||||||
|
|
|
@ -70,7 +70,7 @@ public class SyncWechartTsxx extends BaseSync {
|
||||||
queryWrapper.ge("scheduleddatetime",DateUtils.formatDate(nowTime2,"yyyy-MM-dd HH:mm:ss"));
|
queryWrapper.ge("scheduleddatetime",DateUtils.formatDate(nowTime2,"yyyy-MM-dd HH:mm:ss"));
|
||||||
queryWrapper.le("scheduleddatetime",DateUtils.formatDate(nowTime,"yyyy-MM-dd HH:mm:ss"));
|
queryWrapper.le("scheduleddatetime",DateUtils.formatDate(nowTime,"yyyy-MM-dd HH:mm:ss"));
|
||||||
queryWrapper.eq("status","0");
|
queryWrapper.eq("status","0");
|
||||||
List<KcMessagelistcopy> list =kcMessagelistcopyService.list();
|
List<KcMessagelistcopy> list =kcMessagelistcopyService.list(queryWrapper);
|
||||||
for(KcMessagelistcopy KcMessagelistcopy:list){
|
for(KcMessagelistcopy KcMessagelistcopy:list){
|
||||||
|
|
||||||
// 模板参数
|
// 模板参数
|
||||||
|
|
|
@ -0,0 +1,176 @@
|
||||||
|
package org.jeecg.modules.kc.kcEvaluationsHisrecord.controller;
|
||||||
|
|
||||||
|
import java.util.Arrays;
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
import java.util.stream.Collectors;
|
||||||
|
import java.io.IOException;
|
||||||
|
import java.io.UnsupportedEncodingException;
|
||||||
|
import java.net.URLDecoder;
|
||||||
|
import javax.servlet.http.HttpServletRequest;
|
||||||
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
import org.jeecg.common.api.vo.Result;
|
||||||
|
import org.jeecg.common.system.query.QueryGenerator;
|
||||||
|
import org.jeecg.common.util.oConvertUtils;
|
||||||
|
import org.jeecg.modules.kc.kcEvaluationsHisrecord.entity.KcEvaluationsHisrecord;
|
||||||
|
import org.jeecg.modules.kc.kcEvaluationsHisrecord.service.IKcEvaluationsHisrecordService;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||||
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||||
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
|
||||||
|
import org.jeecgframework.poi.excel.ExcelImportUtil;
|
||||||
|
import org.jeecgframework.poi.excel.def.NormalExcelConstants;
|
||||||
|
import org.jeecgframework.poi.excel.entity.ExportParams;
|
||||||
|
import org.jeecgframework.poi.excel.entity.ImportParams;
|
||||||
|
import org.jeecgframework.poi.excel.view.JeecgEntityExcelView;
|
||||||
|
import org.jeecg.common.system.base.controller.JeecgController;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
import org.springframework.web.multipart.MultipartFile;
|
||||||
|
import org.springframework.web.multipart.MultipartHttpServletRequest;
|
||||||
|
import org.springframework.web.servlet.ModelAndView;
|
||||||
|
import com.alibaba.fastjson.JSON;
|
||||||
|
import io.swagger.annotations.Api;
|
||||||
|
import io.swagger.annotations.ApiOperation;
|
||||||
|
import org.jeecg.common.aspect.annotation.AutoLog;
|
||||||
|
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: 历史听课数据
|
||||||
|
* @Author: jeecg-boot
|
||||||
|
* @Date: 2024-04-16
|
||||||
|
* @Version: V1.0
|
||||||
|
*/
|
||||||
|
@Api(tags="历史听课数据")
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/kcEvaluationsHisrecord/kcEvaluationsHisrecord")
|
||||||
|
@Slf4j
|
||||||
|
public class KcEvaluationsHisrecordController extends JeecgController<KcEvaluationsHisrecord, IKcEvaluationsHisrecordService> {
|
||||||
|
@Autowired
|
||||||
|
private IKcEvaluationsHisrecordService kcEvaluationsHisrecordService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分页列表查询
|
||||||
|
*
|
||||||
|
* @param kcEvaluationsHisrecord
|
||||||
|
* @param pageNo
|
||||||
|
* @param pageSize
|
||||||
|
* @param req
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
//@AutoLog(value = "历史听课数据-分页列表查询")
|
||||||
|
@ApiOperation(value="历史听课数据-分页列表查询", notes="历史听课数据-分页列表查询")
|
||||||
|
@GetMapping(value = "/list")
|
||||||
|
public Result<IPage<KcEvaluationsHisrecord>> queryPageList(KcEvaluationsHisrecord kcEvaluationsHisrecord,
|
||||||
|
@RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
|
||||||
|
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
|
||||||
|
HttpServletRequest req) {
|
||||||
|
QueryWrapper<KcEvaluationsHisrecord> queryWrapper = QueryGenerator.initQueryWrapper(kcEvaluationsHisrecord, req.getParameterMap());
|
||||||
|
Page<KcEvaluationsHisrecord> page = new Page<KcEvaluationsHisrecord>(pageNo, pageSize);
|
||||||
|
IPage<KcEvaluationsHisrecord> pageList = kcEvaluationsHisrecordService.page(page, queryWrapper);
|
||||||
|
return Result.OK(pageList);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 添加
|
||||||
|
*
|
||||||
|
* @param kcEvaluationsHisrecord
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@AutoLog(value = "历史听课数据-添加")
|
||||||
|
@ApiOperation(value="历史听课数据-添加", notes="历史听课数据-添加")
|
||||||
|
@PostMapping(value = "/add")
|
||||||
|
public Result<String> add(@RequestBody KcEvaluationsHisrecord kcEvaluationsHisrecord) {
|
||||||
|
kcEvaluationsHisrecordService.save(kcEvaluationsHisrecord);
|
||||||
|
return Result.OK("添加成功!");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 编辑
|
||||||
|
*
|
||||||
|
* @param kcEvaluationsHisrecord
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@AutoLog(value = "历史听课数据-编辑")
|
||||||
|
@ApiOperation(value="历史听课数据-编辑", notes="历史听课数据-编辑")
|
||||||
|
@RequestMapping(value = "/edit", method = {RequestMethod.PUT,RequestMethod.POST})
|
||||||
|
public Result<String> edit(@RequestBody KcEvaluationsHisrecord kcEvaluationsHisrecord) {
|
||||||
|
kcEvaluationsHisrecordService.updateById(kcEvaluationsHisrecord);
|
||||||
|
return Result.OK("编辑成功!");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 通过id删除
|
||||||
|
*
|
||||||
|
* @param id
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@AutoLog(value = "历史听课数据-通过id删除")
|
||||||
|
@ApiOperation(value="历史听课数据-通过id删除", notes="历史听课数据-通过id删除")
|
||||||
|
@RequiresPermissions("kcEvaluationsHisrecord:kc_evaluations_hisrecord:delete")
|
||||||
|
@DeleteMapping(value = "/delete")
|
||||||
|
public Result<String> delete(@RequestParam(name="id",required=true) String id) {
|
||||||
|
kcEvaluationsHisrecordService.removeById(id);
|
||||||
|
return Result.OK("删除成功!");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除
|
||||||
|
*
|
||||||
|
* @param ids
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@AutoLog(value = "历史听课数据-批量删除")
|
||||||
|
@ApiOperation(value="历史听课数据-批量删除", notes="历史听课数据-批量删除")
|
||||||
|
@RequiresPermissions("kcEvaluationsHisrecord:kc_evaluations_hisrecord:deleteBatch")
|
||||||
|
@DeleteMapping(value = "/deleteBatch")
|
||||||
|
public Result<String> deleteBatch(@RequestParam(name="ids",required=true) String ids) {
|
||||||
|
this.kcEvaluationsHisrecordService.removeByIds(Arrays.asList(ids.split(",")));
|
||||||
|
return Result.OK("批量删除成功!");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 通过id查询
|
||||||
|
*
|
||||||
|
* @param id
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
//@AutoLog(value = "历史听课数据-通过id查询")
|
||||||
|
@ApiOperation(value="历史听课数据-通过id查询", notes="历史听课数据-通过id查询")
|
||||||
|
@GetMapping(value = "/queryById")
|
||||||
|
public Result<KcEvaluationsHisrecord> queryById(@RequestParam(name="id",required=true) String id) {
|
||||||
|
KcEvaluationsHisrecord kcEvaluationsHisrecord = kcEvaluationsHisrecordService.getById(id);
|
||||||
|
if(kcEvaluationsHisrecord==null) {
|
||||||
|
return Result.error("未找到对应数据");
|
||||||
|
}
|
||||||
|
return Result.OK(kcEvaluationsHisrecord);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 导出excel
|
||||||
|
*
|
||||||
|
* @param request
|
||||||
|
* @param kcEvaluationsHisrecord
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("kcEvaluationsHisrecord:kc_evaluations_hisrecord:exportXls")
|
||||||
|
@RequestMapping(value = "/exportXls")
|
||||||
|
public ModelAndView exportXls(HttpServletRequest request, KcEvaluationsHisrecord kcEvaluationsHisrecord) {
|
||||||
|
return super.exportXls(request, kcEvaluationsHisrecord, KcEvaluationsHisrecord.class, "历史听课数据");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 通过excel导入数据
|
||||||
|
*
|
||||||
|
* @param request
|
||||||
|
* @param response
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("kcEvaluationsHisrecord:kc_evaluations_hisrecord:importExcel")
|
||||||
|
@RequestMapping(value = "/importExcel", method = RequestMethod.POST)
|
||||||
|
public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) {
|
||||||
|
return super.importExcel(request, response, KcEvaluationsHisrecord.class);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
|
@ -0,0 +1,103 @@
|
||||||
|
package org.jeecg.modules.kc.kcEvaluationsHisrecord.entity;
|
||||||
|
|
||||||
|
import java.io.Serializable;
|
||||||
|
import java.io.UnsupportedEncodingException;
|
||||||
|
import java.util.Date;
|
||||||
|
import java.math.BigDecimal;
|
||||||
|
import com.baomidou.mybatisplus.annotation.IdType;
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableId;
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableName;
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableLogic;
|
||||||
|
import lombok.Data;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
import org.jeecgframework.poi.excel.annotation.Excel;
|
||||||
|
import org.jeecg.common.aspect.annotation.Dict;
|
||||||
|
import io.swagger.annotations.ApiModel;
|
||||||
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
|
import lombok.EqualsAndHashCode;
|
||||||
|
import lombok.experimental.Accessors;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: 历史听课数据
|
||||||
|
* @Author: jeecg-boot
|
||||||
|
* @Date: 2024-04-16
|
||||||
|
* @Version: V1.0
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@TableName("kc_evaluations_hisrecord")
|
||||||
|
@Accessors(chain = true)
|
||||||
|
@EqualsAndHashCode(callSuper = false)
|
||||||
|
@ApiModel(value="kc_evaluations_hisrecord对象", description="历史听课数据")
|
||||||
|
public class KcEvaluationsHisrecord implements Serializable {
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
|
/**学年学期*/
|
||||||
|
@Excel(name = "学年学期", width = 15)
|
||||||
|
@ApiModelProperty(value = "学年学期")
|
||||||
|
private java.lang.String xnxq;
|
||||||
|
/**课程编号*/
|
||||||
|
@Excel(name = "课程编号", width = 15)
|
||||||
|
@ApiModelProperty(value = "课程编号")
|
||||||
|
private java.lang.String kcbh;
|
||||||
|
/**课程名称*/
|
||||||
|
@Excel(name = "课程名称", width = 15)
|
||||||
|
@ApiModelProperty(value = "课程名称")
|
||||||
|
private java.lang.String kcmc;
|
||||||
|
/**开课院系*/
|
||||||
|
@Excel(name = "开课院系", width = 15)
|
||||||
|
@ApiModelProperty(value = "开课院系")
|
||||||
|
private java.lang.String kkdw;
|
||||||
|
/**上课教师*/
|
||||||
|
@Excel(name = "上课教师", width = 15)
|
||||||
|
@ApiModelProperty(value = "上课教师")
|
||||||
|
private java.lang.String skjs;
|
||||||
|
/**听课教师*/
|
||||||
|
@Excel(name = "听课教师", width = 15)
|
||||||
|
@ApiModelProperty(value = "听课教师")
|
||||||
|
private java.lang.String tkjs;
|
||||||
|
/**课堂教学总体印象评价(综合评分)*/
|
||||||
|
@Excel(name = "课堂教学总体印象评价(综合评分)", width = 15)
|
||||||
|
@ApiModelProperty(value = "课堂教学总体印象评价(综合评分)")
|
||||||
|
private java.lang.String col01;
|
||||||
|
/**无迟到、早退、旷课现象(学生情况)*/
|
||||||
|
@Excel(name = "无迟到、早退、旷课现象(学生情况)", width = 15)
|
||||||
|
@ApiModelProperty(value = "无迟到、早退、旷课现象(学生情况)")
|
||||||
|
private java.lang.String col02;
|
||||||
|
/**课堂教学秩序好、无喧闹、打瞌睡、发短信、玩手机等现象(学生情况)*/
|
||||||
|
@Excel(name = "课堂教学秩序好、无喧闹、打瞌睡、发短信、玩手机等现象(学生情况)", width = 15)
|
||||||
|
@ApiModelProperty(value = "课堂教学秩序好、无喧闹、打瞌睡、发短信、玩手机等现象(学生情况)")
|
||||||
|
private java.lang.String col03;
|
||||||
|
/**上课认真听讲、积极思考,主动与老师交流互动(学生情况)*/
|
||||||
|
@Excel(name = "上课认真听讲、积极思考,主动与老师交流互动(学生情况)", width = 15)
|
||||||
|
@ApiModelProperty(value = "上课认真听讲、积极思考,主动与老师交流互动(学生情况)")
|
||||||
|
private java.lang.String col04;
|
||||||
|
/**讲课有热情、精神饱满,能够调动学生情绪,课堂气氛活跃(教师情况)*/
|
||||||
|
@Excel(name = "讲课有热情、精神饱满,能够调动学生情绪,课堂气氛活跃(教师情况)", width = 15)
|
||||||
|
@ApiModelProperty(value = "讲课有热情、精神饱满,能够调动学生情绪,课堂气氛活跃(教师情况)")
|
||||||
|
private java.lang.String col05;
|
||||||
|
/**教学目标明确,内容丰富,重点突出,语言表达清楚(教师情况)*/
|
||||||
|
@Excel(name = "教学目标明确,内容丰富,重点突出,语言表达清楚(教师情况)", width = 15)
|
||||||
|
@ApiModelProperty(value = "教学目标明确,内容丰富,重点突出,语言表达清楚(教师情况)")
|
||||||
|
private java.lang.String col06;
|
||||||
|
/**授课有启发性,能给予学生思考、联想、创新的启迪(教师情况)*/
|
||||||
|
@Excel(name = "授课有启发性,能给予学生思考、联想、创新的启迪(教师情况)", width = 15)
|
||||||
|
@ApiModelProperty(value = "授课有启发性,能给予学生思考、联想、创新的启迪(教师情况)")
|
||||||
|
private java.lang.String col07;
|
||||||
|
/**能有效利用各种教学媒体,课件或板书使用效果好(教师情况)*/
|
||||||
|
@Excel(name = "能有效利用各种教学媒体,课件或板书使用效果好(教师情况)", width = 15)
|
||||||
|
@ApiModelProperty(value = "能有效利用各种教学媒体,课件或板书使用效果好(教师情况)")
|
||||||
|
private java.lang.String col08;
|
||||||
|
/**仪表得体,按时上下课,严格要求学生(教师情况)*/
|
||||||
|
@Excel(name = "仪表得体,按时上下课,严格要求学生(教师情况)", width = 15)
|
||||||
|
@ApiModelProperty(value = "仪表得体,按时上下课,严格要求学生(教师情况)")
|
||||||
|
private java.lang.String col09;
|
||||||
|
/**意见或建议*/
|
||||||
|
@Excel(name = "意见或建议", width = 15)
|
||||||
|
@ApiModelProperty(value = "意见或建议")
|
||||||
|
private java.lang.String col10;
|
||||||
|
/**数据来源*/
|
||||||
|
@Excel(name = "数据来源", width = 15)
|
||||||
|
@ApiModelProperty(value = "数据来源")
|
||||||
|
private java.lang.String source;
|
||||||
|
}
|
|
@ -0,0 +1,17 @@
|
||||||
|
package org.jeecg.modules.kc.kcEvaluationsHisrecord.mapper;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import org.apache.ibatis.annotations.Param;
|
||||||
|
import org.jeecg.modules.kc.kcEvaluationsHisrecord.entity.KcEvaluationsHisrecord;
|
||||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: 历史听课数据
|
||||||
|
* @Author: jeecg-boot
|
||||||
|
* @Date: 2024-04-16
|
||||||
|
* @Version: V1.0
|
||||||
|
*/
|
||||||
|
public interface KcEvaluationsHisrecordMapper extends BaseMapper<KcEvaluationsHisrecord> {
|
||||||
|
|
||||||
|
}
|
|
@ -0,0 +1,5 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||||
|
<mapper namespace="org.jeecg.modules.kc.kcEvaluationsHisrecord.mapper.KcEvaluationsHisrecordMapper">
|
||||||
|
|
||||||
|
</mapper>
|
|
@ -0,0 +1,14 @@
|
||||||
|
package org.jeecg.modules.kc.kcEvaluationsHisrecord.service;
|
||||||
|
|
||||||
|
import org.jeecg.modules.kc.kcEvaluationsHisrecord.entity.KcEvaluationsHisrecord;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: 历史听课数据
|
||||||
|
* @Author: jeecg-boot
|
||||||
|
* @Date: 2024-04-16
|
||||||
|
* @Version: V1.0
|
||||||
|
*/
|
||||||
|
public interface IKcEvaluationsHisrecordService extends IService<KcEvaluationsHisrecord> {
|
||||||
|
|
||||||
|
}
|
|
@ -0,0 +1,19 @@
|
||||||
|
package org.jeecg.modules.kc.kcEvaluationsHisrecord.service.impl;
|
||||||
|
|
||||||
|
import org.jeecg.modules.kc.kcEvaluationsHisrecord.entity.KcEvaluationsHisrecord;
|
||||||
|
import org.jeecg.modules.kc.kcEvaluationsHisrecord.mapper.KcEvaluationsHisrecordMapper;
|
||||||
|
import org.jeecg.modules.kc.kcEvaluationsHisrecord.service.IKcEvaluationsHisrecordService;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: 历史听课数据
|
||||||
|
* @Author: jeecg-boot
|
||||||
|
* @Date: 2024-04-16
|
||||||
|
* @Version: V1.0
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
public class KcEvaluationsHisrecordServiceImpl extends ServiceImpl<KcEvaluationsHisrecordMapper, KcEvaluationsHisrecord> implements IKcEvaluationsHisrecordService {
|
||||||
|
|
||||||
|
}
|
|
@ -16,6 +16,8 @@ import org.jeecg.common.api.vo.Result;
|
||||||
import org.jeecg.common.system.query.QueryGenerator;
|
import org.jeecg.common.system.query.QueryGenerator;
|
||||||
import org.jeecg.common.system.vo.LoginUser;
|
import org.jeecg.common.system.vo.LoginUser;
|
||||||
import org.jeecg.common.util.oConvertUtils;
|
import org.jeecg.common.util.oConvertUtils;
|
||||||
|
import org.jeecg.modules.kc.grab.imports.entity.Xxhbuser;
|
||||||
|
import org.jeecg.modules.kc.grab.imports.service.IXxhbuserService;
|
||||||
import org.jeecg.modules.kc.kcEvaluationsStat.entity.KcEvaluationsStat;
|
import org.jeecg.modules.kc.kcEvaluationsStat.entity.KcEvaluationsStat;
|
||||||
import org.jeecg.modules.kc.kcEvaluationsStat.service.IKcEvaluationsStatService;
|
import org.jeecg.modules.kc.kcEvaluationsStat.service.IKcEvaluationsStatService;
|
||||||
|
|
||||||
|
@ -24,6 +26,7 @@ import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||||
import lombok.extern.slf4j.Slf4j;
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
|
||||||
|
import org.jeecg.modules.system.service.impl.SysBaseApiImpl;
|
||||||
import org.jeecgframework.poi.excel.ExcelImportUtil;
|
import org.jeecgframework.poi.excel.ExcelImportUtil;
|
||||||
import org.jeecgframework.poi.excel.def.NormalExcelConstants;
|
import org.jeecgframework.poi.excel.def.NormalExcelConstants;
|
||||||
import org.jeecgframework.poi.excel.entity.ExportParams;
|
import org.jeecgframework.poi.excel.entity.ExportParams;
|
||||||
|
@ -55,6 +58,11 @@ import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||||
public class KcEvaluationsStatController extends JeecgController<KcEvaluationsStat, IKcEvaluationsStatService> {
|
public class KcEvaluationsStatController extends JeecgController<KcEvaluationsStat, IKcEvaluationsStatService> {
|
||||||
@Autowired
|
@Autowired
|
||||||
private IKcEvaluationsStatService kcEvaluationsStatService;
|
private IKcEvaluationsStatService kcEvaluationsStatService;
|
||||||
|
@Autowired
|
||||||
|
private IXxhbuserService xxhbuserService;
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private SysBaseApiImpl sysBaseApi;
|
||||||
|
|
||||||
@Value("${jeecg.path.upload}")
|
@Value("${jeecg.path.upload}")
|
||||||
private String upLoadPath;
|
private String upLoadPath;
|
||||||
|
@ -78,7 +86,19 @@ public class KcEvaluationsStatController extends JeecgController<KcEvaluationsSt
|
||||||
kcEvaluationsStat.setCol13("*"+kcEvaluationsStat.getCol13()+"*");
|
kcEvaluationsStat.setCol13("*"+kcEvaluationsStat.getCol13()+"*");
|
||||||
}
|
}
|
||||||
|
|
||||||
QueryWrapper<KcEvaluationsStat> queryWrapper = QueryGenerator.initQueryWrapper(kcEvaluationsStat, req.getParameterMap());
|
LoginUser sysUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
|
||||||
|
System.out.println("--->"+JSON.toJSONString(sysUser));
|
||||||
|
|
||||||
|
List<String> roleList = sysBaseApi.getRolesByUsername(sysUser.getUsername());
|
||||||
|
String adminRole = "1";//0 admin 1教务秘书
|
||||||
|
for(String role :roleList){
|
||||||
|
if(org.apache.commons.lang.StringUtils.equals("admin",role)){
|
||||||
|
adminRole = "0";
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
QueryWrapper<KcEvaluationsStat> queryWrapper = QueryGenerator.initQueryWrapper("a",kcEvaluationsStat, req.getParameterMap());
|
||||||
if(StringUtils.isNotBlank(kcEvaluationsStat.getSzkc())){
|
if(StringUtils.isNotBlank(kcEvaluationsStat.getSzkc())){
|
||||||
String szkc = kcEvaluationsStat.getSzkc();
|
String szkc = kcEvaluationsStat.getSzkc();
|
||||||
if(StringUtils.equals("1",szkc)){
|
if(StringUtils.equals("1",szkc)){
|
||||||
|
@ -87,6 +107,15 @@ public class KcEvaluationsStatController extends JeecgController<KcEvaluationsSt
|
||||||
queryWrapper.eq("col59","否");
|
queryWrapper.eq("col59","否");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if(StringUtils.equals("1",adminRole)){
|
||||||
|
QueryWrapper<Xxhbuser> xxhbuserQueryWrapper = new QueryWrapper<>();
|
||||||
|
xxhbuserQueryWrapper.eq("gh",sysUser.getUsername());
|
||||||
|
xxhbuserQueryWrapper.last("limit 1");
|
||||||
|
Xxhbuser xxhbuser = xxhbuserService.getOne(xxhbuserQueryWrapper);
|
||||||
|
queryWrapper.eq("col10",xxhbuser.getDwmc());
|
||||||
|
}
|
||||||
|
queryWrapper.eq(StringUtils.isNotBlank(kcEvaluationsStat.getSkjsdw()),"b.dwmc",kcEvaluationsStat.getSkjsdw());
|
||||||
|
|
||||||
// queryWrapper.eq(StringUtils.isNotBlank(kcEvaluationsStat.getSzkc()),"c.szkc",kcEvaluationsStat.getSzkc());
|
// queryWrapper.eq(StringUtils.isNotBlank(kcEvaluationsStat.getSzkc()),"c.szkc",kcEvaluationsStat.getSzkc());
|
||||||
Page<KcEvaluationsStat> page = new Page<KcEvaluationsStat>(pageNo, pageSize);
|
Page<KcEvaluationsStat> page = new Page<KcEvaluationsStat>(pageNo, pageSize);
|
||||||
IPage<KcEvaluationsStat> pageList = kcEvaluationsStatService.page(page, queryWrapper);
|
IPage<KcEvaluationsStat> pageList = kcEvaluationsStatService.page(page, queryWrapper);
|
||||||
|
|
|
@ -264,6 +264,8 @@ public class KcEvaluationsStat implements Serializable {
|
||||||
@TableField(exist = false)
|
@TableField(exist = false)
|
||||||
@Dict(dicCode = "yn")
|
@Dict(dicCode = "yn")
|
||||||
private java.lang.String szkc;
|
private java.lang.String szkc;
|
||||||
|
@TableField(exist = false)
|
||||||
|
private java.lang.String skjsdw;//授课教师单位
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -1133,4 +1133,11 @@ select max(id) as id,gh,xqxn from KC_EXPORT_CONFIG_TPKWCQKJZGLX where xqxn = #{x
|
||||||
<update id="updateHuanhang">
|
<update id="updateHuanhang">
|
||||||
update kc_evaluations set textanscontent = REPLACE(textanscontent, '\n', ' ')
|
update kc_evaluations set textanscontent = REPLACE(textanscontent, '\n', ' ')
|
||||||
</update>
|
</update>
|
||||||
|
|
||||||
|
<select id="selectPage" resultType="org.jeecg.modules.kc.kcEvaluationsStat.entity.KcEvaluationsStat">
|
||||||
|
select a.*,b.dwmc as skjsdw from kc_evaluations_stat a
|
||||||
|
left join xxhbuser b on a.col05 = b.gh
|
||||||
|
${ew.customSqlSegment}
|
||||||
|
|
||||||
|
</select>
|
||||||
</mapper>
|
</mapper>
|
|
@ -191,18 +191,34 @@ public class KcGongkaikeController extends JeecgController<KcGongkaike, IKcGongk
|
||||||
String xnxq = kcGongkaike.getXnxq();
|
String xnxq = kcGongkaike.getXnxq();
|
||||||
|
|
||||||
QueryWrapper<KcGongkaike> queryWrapper = QueryGenerator.initQueryWrapper(kcGongkaike, req.getParameterMap());
|
QueryWrapper<KcGongkaike> queryWrapper = QueryGenerator.initQueryWrapper(kcGongkaike, req.getParameterMap());
|
||||||
if(StringUtils.isEmpty(xnxq)){
|
// if(StringUtils.isEmpty(xnxq)){
|
||||||
KcSysConfig kcSysConfig = kcSysConfigService.getById("1");
|
// KcSysConfig kcSysConfig = kcSysConfigService.getById("1");
|
||||||
queryWrapper.ge("rq",kcSysConfig.getBxqkssj());
|
// queryWrapper.ge("rq",kcSysConfig.getBxqkssj());
|
||||||
queryWrapper.le("rq",kcSysConfig.getBxqjssj());
|
// queryWrapper.le("rq",kcSysConfig.getBxqjssj());
|
||||||
}else{QueryWrapper<KcXqxnHistory> kcXqxnHistoryQueryWrapper = new QueryWrapper<>();
|
// }else{QueryWrapper<KcXqxnHistory> kcXqxnHistoryQueryWrapper = new QueryWrapper<>();
|
||||||
kcXqxnHistoryQueryWrapper.eq("title",xnxq);
|
// kcXqxnHistoryQueryWrapper.eq("title",xnxq);
|
||||||
KcXqxnHistory KcXqxnHistory = kcXqxnHistoryService.getOne(kcXqxnHistoryQueryWrapper);queryWrapper.ge("rq",KcXqxnHistory.getStartTime());
|
// KcXqxnHistory KcXqxnHistory = kcXqxnHistoryService.getOne(kcXqxnHistoryQueryWrapper);queryWrapper.ge("rq",KcXqxnHistory.getStartTime());
|
||||||
queryWrapper.le("rq",KcXqxnHistory.getEndTime());
|
// queryWrapper.le("rq",KcXqxnHistory.getEndTime());
|
||||||
}
|
// }
|
||||||
Page<KcGongkaike> page = new Page<KcGongkaike>(pageNo, pageSize);
|
Page<KcGongkaike> page = new Page<KcGongkaike>(pageNo, pageSize);
|
||||||
IPage<KcGongkaike> pageList = kcGongkaikeService.getIndexList(page, queryWrapper);
|
IPage<KcGongkaike> pageList = kcGongkaikeService.getIndexList(page, queryWrapper);
|
||||||
return Result.OK(pageList);
|
return Result.OK(pageList);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@AutoLog(value = "批量修改前台是否展示")
|
||||||
|
@ApiOperation(value="批量修改前台是否展示", notes="批量修改前台是否展示")
|
||||||
|
@RequestMapping(value = "/editBatch", method = {RequestMethod.PUT,RequestMethod.POST})
|
||||||
|
public Result<String> editBatch(@RequestBody KcGongkaike kcGongkaike) {
|
||||||
|
String ids[] = kcGongkaike.getId().split(",");
|
||||||
|
String sfxs = kcGongkaike.getSfxs();
|
||||||
|
for(String id:ids){
|
||||||
|
KcGongkaike kcGongkaikePar = new KcGongkaike();
|
||||||
|
kcGongkaikePar.setId(id);
|
||||||
|
kcGongkaikePar.setSfxs(sfxs);
|
||||||
|
kcGongkaikeService.updateById(kcGongkaikePar);
|
||||||
|
}
|
||||||
|
return Result.OK("编辑成功!");
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,176 @@
|
||||||
|
package org.jeecg.modules.kc.kcTtksdpz.controller;
|
||||||
|
|
||||||
|
import java.util.Arrays;
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
import java.util.stream.Collectors;
|
||||||
|
import java.io.IOException;
|
||||||
|
import java.io.UnsupportedEncodingException;
|
||||||
|
import java.net.URLDecoder;
|
||||||
|
import javax.servlet.http.HttpServletRequest;
|
||||||
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
import org.jeecg.common.api.vo.Result;
|
||||||
|
import org.jeecg.common.system.query.QueryGenerator;
|
||||||
|
import org.jeecg.common.util.oConvertUtils;
|
||||||
|
import org.jeecg.modules.kc.kcTtksdpz.entity.KcTtksdpz;
|
||||||
|
import org.jeecg.modules.kc.kcTtksdpz.service.IKcTtksdpzService;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||||
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||||
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
|
||||||
|
import org.jeecgframework.poi.excel.ExcelImportUtil;
|
||||||
|
import org.jeecgframework.poi.excel.def.NormalExcelConstants;
|
||||||
|
import org.jeecgframework.poi.excel.entity.ExportParams;
|
||||||
|
import org.jeecgframework.poi.excel.entity.ImportParams;
|
||||||
|
import org.jeecgframework.poi.excel.view.JeecgEntityExcelView;
|
||||||
|
import org.jeecg.common.system.base.controller.JeecgController;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
import org.springframework.web.multipart.MultipartFile;
|
||||||
|
import org.springframework.web.multipart.MultipartHttpServletRequest;
|
||||||
|
import org.springframework.web.servlet.ModelAndView;
|
||||||
|
import com.alibaba.fastjson.JSON;
|
||||||
|
import io.swagger.annotations.Api;
|
||||||
|
import io.swagger.annotations.ApiOperation;
|
||||||
|
import org.jeecg.common.aspect.annotation.AutoLog;
|
||||||
|
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: 调停课配置
|
||||||
|
* @Author: jeecg-boot
|
||||||
|
* @Date: 2024-04-16
|
||||||
|
* @Version: V1.0
|
||||||
|
*/
|
||||||
|
@Api(tags="调停课配置")
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/kcTtksdpz/kcTtksdpz")
|
||||||
|
@Slf4j
|
||||||
|
public class KcTtksdpzController extends JeecgController<KcTtksdpz, IKcTtksdpzService> {
|
||||||
|
@Autowired
|
||||||
|
private IKcTtksdpzService kcTtksdpzService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分页列表查询
|
||||||
|
*
|
||||||
|
* @param kcTtksdpz
|
||||||
|
* @param pageNo
|
||||||
|
* @param pageSize
|
||||||
|
* @param req
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
//@AutoLog(value = "调停课配置-分页列表查询")
|
||||||
|
@ApiOperation(value="调停课配置-分页列表查询", notes="调停课配置-分页列表查询")
|
||||||
|
@GetMapping(value = "/list")
|
||||||
|
public Result<IPage<KcTtksdpz>> queryPageList(KcTtksdpz kcTtksdpz,
|
||||||
|
@RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
|
||||||
|
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
|
||||||
|
HttpServletRequest req) {
|
||||||
|
QueryWrapper<KcTtksdpz> queryWrapper = QueryGenerator.initQueryWrapper(kcTtksdpz, req.getParameterMap());
|
||||||
|
Page<KcTtksdpz> page = new Page<KcTtksdpz>(pageNo, pageSize);
|
||||||
|
IPage<KcTtksdpz> pageList = kcTtksdpzService.page(page, queryWrapper);
|
||||||
|
return Result.OK(pageList);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 添加
|
||||||
|
*
|
||||||
|
* @param kcTtksdpz
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@AutoLog(value = "调停课配置-添加")
|
||||||
|
@ApiOperation(value="调停课配置-添加", notes="调停课配置-添加")
|
||||||
|
@PostMapping(value = "/add")
|
||||||
|
public Result<String> add(@RequestBody KcTtksdpz kcTtksdpz) {
|
||||||
|
kcTtksdpzService.save(kcTtksdpz);
|
||||||
|
return Result.OK("添加成功!");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 编辑
|
||||||
|
*
|
||||||
|
* @param kcTtksdpz
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@AutoLog(value = "调停课配置-编辑")
|
||||||
|
@ApiOperation(value="调停课配置-编辑", notes="调停课配置-编辑")
|
||||||
|
@RequestMapping(value = "/edit", method = {RequestMethod.PUT,RequestMethod.POST})
|
||||||
|
public Result<String> edit(@RequestBody KcTtksdpz kcTtksdpz) {
|
||||||
|
kcTtksdpzService.updateById(kcTtksdpz);
|
||||||
|
return Result.OK("编辑成功!");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 通过id删除
|
||||||
|
*
|
||||||
|
* @param id
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@AutoLog(value = "调停课配置-通过id删除")
|
||||||
|
@ApiOperation(value="调停课配置-通过id删除", notes="调停课配置-通过id删除")
|
||||||
|
@RequiresPermissions("kcTtksdpz:kc_ttksdpz:delete")
|
||||||
|
@DeleteMapping(value = "/delete")
|
||||||
|
public Result<String> delete(@RequestParam(name="id",required=true) String id) {
|
||||||
|
kcTtksdpzService.removeById(id);
|
||||||
|
return Result.OK("删除成功!");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除
|
||||||
|
*
|
||||||
|
* @param ids
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@AutoLog(value = "调停课配置-批量删除")
|
||||||
|
@ApiOperation(value="调停课配置-批量删除", notes="调停课配置-批量删除")
|
||||||
|
@RequiresPermissions("kcTtksdpz:kc_ttksdpz:deleteBatch")
|
||||||
|
@DeleteMapping(value = "/deleteBatch")
|
||||||
|
public Result<String> deleteBatch(@RequestParam(name="ids",required=true) String ids) {
|
||||||
|
this.kcTtksdpzService.removeByIds(Arrays.asList(ids.split(",")));
|
||||||
|
return Result.OK("批量删除成功!");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 通过id查询
|
||||||
|
*
|
||||||
|
* @param id
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
//@AutoLog(value = "调停课配置-通过id查询")
|
||||||
|
@ApiOperation(value="调停课配置-通过id查询", notes="调停课配置-通过id查询")
|
||||||
|
@GetMapping(value = "/queryById")
|
||||||
|
public Result<KcTtksdpz> queryById(@RequestParam(name="id",required=true) String id) {
|
||||||
|
KcTtksdpz kcTtksdpz = kcTtksdpzService.getById(id);
|
||||||
|
if(kcTtksdpz==null) {
|
||||||
|
return Result.error("未找到对应数据");
|
||||||
|
}
|
||||||
|
return Result.OK(kcTtksdpz);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 导出excel
|
||||||
|
*
|
||||||
|
* @param request
|
||||||
|
* @param kcTtksdpz
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("kcTtksdpz:kc_ttksdpz:exportXls")
|
||||||
|
@RequestMapping(value = "/exportXls")
|
||||||
|
public ModelAndView exportXls(HttpServletRequest request, KcTtksdpz kcTtksdpz) {
|
||||||
|
return super.exportXls(request, kcTtksdpz, KcTtksdpz.class, "调停课配置");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 通过excel导入数据
|
||||||
|
*
|
||||||
|
* @param request
|
||||||
|
* @param response
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("kcTtksdpz:kc_ttksdpz:importExcel")
|
||||||
|
@RequestMapping(value = "/importExcel", method = RequestMethod.POST)
|
||||||
|
public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) {
|
||||||
|
return super.importExcel(request, response, KcTtksdpz.class);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
|
@ -0,0 +1,86 @@
|
||||||
|
package org.jeecg.modules.kc.kcTtksdpz.entity;
|
||||||
|
|
||||||
|
import java.io.Serializable;
|
||||||
|
import java.io.UnsupportedEncodingException;
|
||||||
|
import java.util.Date;
|
||||||
|
import java.math.BigDecimal;
|
||||||
|
import com.baomidou.mybatisplus.annotation.IdType;
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableId;
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableName;
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableLogic;
|
||||||
|
import lombok.Data;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
import org.jeecgframework.poi.excel.annotation.Excel;
|
||||||
|
import org.jeecg.common.aspect.annotation.Dict;
|
||||||
|
import io.swagger.annotations.ApiModel;
|
||||||
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
|
import lombok.EqualsAndHashCode;
|
||||||
|
import lombok.experimental.Accessors;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: 调停课配置
|
||||||
|
* @Author: jeecg-boot
|
||||||
|
* @Date: 2024-04-16
|
||||||
|
* @Version: V1.0
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@TableName("kc_ttksdpz")
|
||||||
|
@Accessors(chain = true)
|
||||||
|
@EqualsAndHashCode(callSuper = false)
|
||||||
|
@ApiModel(value="kc_ttksdpz对象", description="调停课配置")
|
||||||
|
public class KcTtksdpz implements Serializable {
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
|
/**id*/
|
||||||
|
@TableId(type = IdType.ASSIGN_ID)
|
||||||
|
@ApiModelProperty(value = "id")
|
||||||
|
private java.lang.String id;
|
||||||
|
/**操作人*/
|
||||||
|
@ApiModelProperty(value = "操作人")
|
||||||
|
private java.lang.String createBy;
|
||||||
|
/**操作时间*/
|
||||||
|
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
|
||||||
|
@DateTimeFormat(pattern="yyyy-MM-dd")
|
||||||
|
@ApiModelProperty(value = "操作时间")
|
||||||
|
private java.util.Date createTime;
|
||||||
|
/**updateBy*/
|
||||||
|
@ApiModelProperty(value = "updateBy")
|
||||||
|
private java.lang.String updateBy;
|
||||||
|
/**updateTime*/
|
||||||
|
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
|
||||||
|
@DateTimeFormat(pattern="yyyy-MM-dd")
|
||||||
|
@ApiModelProperty(value = "updateTime")
|
||||||
|
private java.util.Date updateTime;
|
||||||
|
/**调课类型*/
|
||||||
|
@Excel(name = "调课类型", width = 15, dicCode = "tklx_type")
|
||||||
|
@Dict(dicCode = "tklx_type")
|
||||||
|
@ApiModelProperty(value = "调课类型")
|
||||||
|
private java.lang.String tklx;
|
||||||
|
/**放假时间*/
|
||||||
|
@Excel(name = "放假时间", width = 15, format = "yyyy-MM-dd")
|
||||||
|
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
|
||||||
|
@DateTimeFormat(pattern="yyyy-MM-dd")
|
||||||
|
@ApiModelProperty(value = "放假时间")
|
||||||
|
private java.util.Date fjsj;
|
||||||
|
/**调课时间*/
|
||||||
|
@Excel(name = "调课时间", width = 15, format = "yyyy-MM-dd")
|
||||||
|
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
|
||||||
|
@DateTimeFormat(pattern="yyyy-MM-dd")
|
||||||
|
@ApiModelProperty(value = "调课时间")
|
||||||
|
private java.util.Date tksj;
|
||||||
|
/**执行时间*/
|
||||||
|
@Excel(name = "执行时间", width = 15, format = "yyyy-MM-dd")
|
||||||
|
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
|
||||||
|
@DateTimeFormat(pattern="yyyy-MM-dd")
|
||||||
|
@ApiModelProperty(value = "执行时间")
|
||||||
|
private java.util.Date zxsj;
|
||||||
|
/**执行sql1*/
|
||||||
|
@Excel(name = "执行sql1", width = 15)
|
||||||
|
@ApiModelProperty(value = "执行sql1")
|
||||||
|
private java.lang.String zxsql1;
|
||||||
|
/**执行sql2*/
|
||||||
|
@Excel(name = "执行sql2", width = 15)
|
||||||
|
@ApiModelProperty(value = "执行sql2")
|
||||||
|
private java.lang.String zxsql2;
|
||||||
|
}
|
|
@ -0,0 +1,17 @@
|
||||||
|
package org.jeecg.modules.kc.kcTtksdpz.mapper;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import org.apache.ibatis.annotations.Param;
|
||||||
|
import org.jeecg.modules.kc.kcTtksdpz.entity.KcTtksdpz;
|
||||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: 调停课配置
|
||||||
|
* @Author: jeecg-boot
|
||||||
|
* @Date: 2024-04-16
|
||||||
|
* @Version: V1.0
|
||||||
|
*/
|
||||||
|
public interface KcTtksdpzMapper extends BaseMapper<KcTtksdpz> {
|
||||||
|
|
||||||
|
}
|
|
@ -0,0 +1,5 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||||
|
<mapper namespace="org.jeecg.modules.kc.kcTtksdpz.mapper.KcTtksdpzMapper">
|
||||||
|
|
||||||
|
</mapper>
|
|
@ -0,0 +1,14 @@
|
||||||
|
package org.jeecg.modules.kc.kcTtksdpz.service;
|
||||||
|
|
||||||
|
import org.jeecg.modules.kc.kcTtksdpz.entity.KcTtksdpz;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: 调停课配置
|
||||||
|
* @Author: jeecg-boot
|
||||||
|
* @Date: 2024-04-16
|
||||||
|
* @Version: V1.0
|
||||||
|
*/
|
||||||
|
public interface IKcTtksdpzService extends IService<KcTtksdpz> {
|
||||||
|
|
||||||
|
}
|
|
@ -0,0 +1,19 @@
|
||||||
|
package org.jeecg.modules.kc.kcTtksdpz.service.impl;
|
||||||
|
|
||||||
|
import org.jeecg.modules.kc.kcTtksdpz.entity.KcTtksdpz;
|
||||||
|
import org.jeecg.modules.kc.kcTtksdpz.mapper.KcTtksdpzMapper;
|
||||||
|
import org.jeecg.modules.kc.kcTtksdpz.service.IKcTtksdpzService;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: 调停课配置
|
||||||
|
* @Author: jeecg-boot
|
||||||
|
* @Date: 2024-04-16
|
||||||
|
* @Version: V1.0
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
public class KcTtksdpzServiceImpl extends ServiceImpl<KcTtksdpzMapper, KcTtksdpz> implements IKcTtksdpzService {
|
||||||
|
|
||||||
|
}
|
|
@ -98,15 +98,73 @@ public class KcWechatSendLogController extends JeecgController<KcWechatSendLog,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// appId
|
// // appId
|
||||||
private static final String appId = "wx59920eb69d611d7f";//东师
|
// private static final String appId = "wx59920eb69d611d7f";//东师
|
||||||
|
//
|
||||||
|
// // appIdSecret
|
||||||
|
// private static final String appIdSecret = "bf0c19af0e956f447ede4dd902ea63b7";//东师
|
||||||
|
|
||||||
|
// appId
|
||||||
|
private static final String appId = "wx031697a8ca09a5ce";//东师
|
||||||
|
|
||||||
|
private static final String agentid = "1000065";//
|
||||||
// appIdSecret
|
// appIdSecret
|
||||||
private static final String appIdSecret = "bf0c19af0e956f447ede4dd902ea63b7";//东师
|
private static final String appIdSecret = "6Qhnge3xfzAQMDX2TcjEyE0vUGP96hP9OTYUsYBze2Y";//东师
|
||||||
|
|
||||||
//微信通知点击后跳转的页面
|
//微信通知点击后跳转的页面
|
||||||
private static final String domainTo = "https://zxkccx.webvpn.nenu.edu.cn";
|
private static final String domainTo = "https://zxkccx.webvpn.nenu.edu.cn";
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
public void sendWxmessage(KcWechatSendLog kcWechatSendLog) {
|
public void sendWxmessage(KcWechatSendLog kcWechatSendLog) {
|
||||||
|
String openId = kcWechatSendLog.getOpenid();//曹老师账号
|
||||||
|
System.out.println("openId:"+openId+"");
|
||||||
|
if(StringUtils.isNotEmpty(openId)){
|
||||||
|
try {
|
||||||
|
String urlToken = "https://qyapi.weixin.qq.com/cgi-bin/gettoken?corpid="+ appId +"&corpsecret=" + appIdSecret;
|
||||||
|
System.out.println("urlToken: "+ urlToken);
|
||||||
|
String res = HttpUtil.get(urlToken);
|
||||||
|
JSONObject jsonObjectToken = JSONObject.parseObject(res);
|
||||||
|
System.out.println("jsonObjectToken:{}"+ jsonObjectToken);
|
||||||
|
String accessToken = jsonObjectToken.getString("access_token");
|
||||||
|
System.out.println("accessToken:{}"+ accessToken);
|
||||||
|
|
||||||
|
// 微信的基础accessToken
|
||||||
|
String url = "https://qyapi.weixin.qq.com/cgi-bin/message/send?access_token=" + accessToken;
|
||||||
|
Map<String, Object> sendMag = new HashMap<>();
|
||||||
|
|
||||||
|
// 1、xx老师,你好,您本学期(2023秋)听课要求为:5次,当前实际听课次数:3次,请尽快完成本学期的听课任务。
|
||||||
|
String html = kcWechatSendLog.getYtkcs();
|
||||||
|
html = html + "\n<a href=\""+domainTo+"\">查看</a>";
|
||||||
|
sendMag.put("content", html);//授课老师推送内容
|
||||||
|
RestTemplate restTemplate = new RestTemplate();
|
||||||
|
//拼接base参数
|
||||||
|
Map<String, Object> sendBody = new HashMap<>();
|
||||||
|
sendBody.put("touser", openId); // openId
|
||||||
|
sendBody.put("msgtype", "text"); // 消息类型,此时固定为:text
|
||||||
|
sendBody.put("agentid", agentid); // 企业id
|
||||||
|
sendBody.put("text",sendMag); //发送内容
|
||||||
|
ResponseEntity<String> forEntity = restTemplate.postForEntity(url, sendBody, String.class);
|
||||||
|
JSONObject jsonObject2 = JSONObject.parseObject(forEntity.getBody());
|
||||||
|
System.out.println("jsonObject2 : " + jsonObject2);
|
||||||
|
String messageCode = jsonObject2.getString("errcode");
|
||||||
|
String msgId = jsonObject2.getString("msgid");
|
||||||
|
System.out.println("messageCode : " + messageCode + ", msgId: " +msgId);
|
||||||
|
kcWechatSendLog.setRemark(jsonObject2.toString());
|
||||||
|
kcWechatSendLogService.updateById(kcWechatSendLog);
|
||||||
|
}catch (Exception e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
kcWechatSendLog.setRemark(e.getMessage());
|
||||||
|
kcWechatSendLogService.updateById(kcWechatSendLog);
|
||||||
|
}
|
||||||
|
}else{
|
||||||
|
kcWechatSendLog.setRemark("未获取到openid");
|
||||||
|
kcWechatSendLogService.updateById(kcWechatSendLog);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public void sendWxmessage2(KcWechatSendLog kcWechatSendLog) {
|
||||||
String openId = kcWechatSendLog.getOpenid();//曹老师账号
|
String openId = kcWechatSendLog.getOpenid();//曹老师账号
|
||||||
System.out.println("openId:"+openId+"");
|
System.out.println("openId:"+openId+"");
|
||||||
if(StringUtils.isNotEmpty(openId)){
|
if(StringUtils.isNotEmpty(openId)){
|
||||||
|
|
|
@ -56,7 +56,7 @@
|
||||||
SELECT pk.*, au.assess1 as tksf,xnxq.title as xqxn,if(kcb.szkc='1','是','否') as szkc FROM
|
SELECT pk.*, au.assess1 as tksf,xnxq.title as xqxn,if(kcb.szkc='1','是','否') as szkc FROM
|
||||||
(
|
(
|
||||||
SELECT
|
SELECT
|
||||||
k.id,c.gh as userid, c.xm as username, c.dwh as college, k.kkdw, k.kcmc, k.kcxz, k.skjs, k.week as zc, k.hh as jc, p.up_date, p.up_time, p.id AS evaId, p.evaluationver,
|
k.id,c.gh as userid, c.xm as username, c.dwmc as college, k.kkdw, k.kcmc, k.kcxz, k.skjs, k.week as zc, k.hh as jc, p.up_date, p.up_time, p.id AS evaId, p.evaluationver,
|
||||||
k.bz,k.skrq,k.kechengbiaoid,
|
k.bz,k.skrq,k.kechengbiaoid,
|
||||||
p.source
|
p.source
|
||||||
FROM kc_ketangbiao k, kc_evaluation p, xxhbuser c
|
FROM kc_ketangbiao k, kc_evaluation p, xxhbuser c
|
||||||
|
@ -362,7 +362,7 @@
|
||||||
SELECT pk.*, au.assess1 as tksf,xnxq.title as xqxn,if(kcb.szkc='1','是','否') as szkc FROM
|
SELECT pk.*, au.assess1 as tksf,xnxq.title as xqxn,if(kcb.szkc='1','是','否') as szkc FROM
|
||||||
(
|
(
|
||||||
SELECT
|
SELECT
|
||||||
k.id,c.gh as userid, c.xm as username, c.dwh as college, k.kkdw, k.kcmc, k.kcxz, k.skjs, k.week as zc, k.hh as jc, p.up_date, p.up_time, p.id AS evaId, p.evaluationver,
|
k.id,c.gh as userid, c.xm as username, c.dwmc as college, k.kkdw, k.kcmc, k.kcxz, k.skjs, k.week as zc, k.hh as jc, p.up_date, p.up_time, p.id AS evaId, p.evaluationver,
|
||||||
k.bz,k.skrq,k.kechengbiaoid,
|
k.bz,k.skrq,k.kechengbiaoid,
|
||||||
p.source
|
p.source
|
||||||
FROM kc_ketangbiao k, kc_evaluation p, xxhbuser c
|
FROM kc_ketangbiao k, kc_evaluation p, xxhbuser c
|
||||||
|
|
|
@ -0,0 +1,121 @@
|
||||||
|
package org.jeecg.modules.tools;
|
||||||
|
|
||||||
|
|
||||||
|
import com.alibaba.fastjson.JSONObject;
|
||||||
|
import org.jeecg.modules.tools.baidu.Base64Util;
|
||||||
|
import org.jeecg.modules.tools.baidu.FileUtil;
|
||||||
|
import org.jeecg.modules.tools.baidu.GsonUtils;
|
||||||
|
import org.jeecg.modules.tools.baidu.HttpUtil;
|
||||||
|
import org.springframework.stereotype.Component;
|
||||||
|
|
||||||
|
import java.io.*;
|
||||||
|
import java.net.HttpURLConnection;
|
||||||
|
import java.net.URL;
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.HashMap;
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取token类
|
||||||
|
*/
|
||||||
|
@Component
|
||||||
|
public class AuthService {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取权限token
|
||||||
|
* @return 返回示例:
|
||||||
|
* {
|
||||||
|
* "access_token": "24.460da4889caad24cccdb1fea17221975.2592000.1491995545.282335-1234567",
|
||||||
|
* "expires_in": 2592000
|
||||||
|
* }
|
||||||
|
*/
|
||||||
|
public static String getAuth() {
|
||||||
|
// 官网获取的 API Key 更新为你注册的
|
||||||
|
String clientId = "gt8XUOLS6ljpm5qHoSMztddu";
|
||||||
|
// 官网获取的 Secret Key 更新为你注册的
|
||||||
|
String clientSecret = "uErTrp2o3UBJZ1UgAV5RL1cbNx019Fvb";
|
||||||
|
return getAuth(clientId, clientSecret);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取API访问token
|
||||||
|
* 该token有一定的有效期,需要自行管理,当失效时需重新获取.
|
||||||
|
* @param ak - 百度云官网获取的 API Key
|
||||||
|
* @param sk - 百度云官网获取的 Securet Key
|
||||||
|
* @return assess_token 示例:
|
||||||
|
* "24.460da4889caad24cccdb1fea17221975.2592000.1491995545.282335-1234567"
|
||||||
|
*/
|
||||||
|
public static String getAuth(String ak, String sk) {
|
||||||
|
// 获取token地址
|
||||||
|
String authHost = "https://aip.baidubce.com/oauth/2.0/token?";
|
||||||
|
String getAccessTokenUrl = authHost
|
||||||
|
// 1. grant_type为固定参数
|
||||||
|
+ "grant_type=client_credentials"
|
||||||
|
// 2. 官网获取的 API Key
|
||||||
|
+ "&client_id=" + ak
|
||||||
|
// 3. 官网获取的 Secret Key
|
||||||
|
+ "&client_secret=" + sk;
|
||||||
|
try {
|
||||||
|
URL realUrl = new URL(getAccessTokenUrl);
|
||||||
|
// 打开和URL之间的连接
|
||||||
|
HttpURLConnection connection = (HttpURLConnection) realUrl.openConnection();
|
||||||
|
connection.setRequestMethod("GET");
|
||||||
|
connection.connect();
|
||||||
|
// 获取所有响应头字段
|
||||||
|
Map<String, List<String>> map = connection.getHeaderFields();
|
||||||
|
// 遍历所有的响应头字段
|
||||||
|
for (String key : map.keySet()) {
|
||||||
|
System.err.println(key + "--->" + map.get(key));
|
||||||
|
}
|
||||||
|
// 定义 BufferedReader输入流来读取URL的响应
|
||||||
|
BufferedReader in = new BufferedReader(new InputStreamReader(connection.getInputStream()));
|
||||||
|
String result = "";
|
||||||
|
String line;
|
||||||
|
while ((line = in.readLine()) != null) {
|
||||||
|
result += line;
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
* 返回结果示例
|
||||||
|
*/
|
||||||
|
System.err.println("result:" + result);
|
||||||
|
JSONObject jsonObject = JSONObject.parseObject(result);
|
||||||
|
String access_token = jsonObject.getString("access_token");
|
||||||
|
return access_token;
|
||||||
|
} catch (Exception e) {
|
||||||
|
System.err.printf("获取token失败!");
|
||||||
|
e.printStackTrace(System.err);
|
||||||
|
}
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public String faceDetect(String filePath) {
|
||||||
|
// 请求url
|
||||||
|
String url = "https://aip.baidubce.com/rest/2.0/face/v3/detect";
|
||||||
|
try {
|
||||||
|
Map<String, Object> map = new HashMap<>();
|
||||||
|
byte[] imageByte = FileUtil.readFileByBytes(filePath);
|
||||||
|
String base64Image = Base64Util.encode(imageByte);
|
||||||
|
|
||||||
|
|
||||||
|
map.put("image", base64Image);
|
||||||
|
map.put("image_type", "BASE64");
|
||||||
|
map.put("max_face_num", "120");
|
||||||
|
|
||||||
|
String param = GsonUtils.toJson(map);
|
||||||
|
// List<String> list = new ArrayList<>();
|
||||||
|
// list.add(param);
|
||||||
|
// 注意这里仅为了简化编码每一次请求都去获取access_token,线上环境access_token有过期时间, 客户端可自行缓存,过期后重新获取。
|
||||||
|
String accessToken = getAuth();
|
||||||
|
|
||||||
|
// String result = HttpUtil.post(url, accessToken, "application/json", list.toString());
|
||||||
|
String result = HttpUtil.post(url, accessToken, "application/json", param);
|
||||||
|
System.out.println(result);
|
||||||
|
return result;
|
||||||
|
} catch (Exception e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
}
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,65 @@
|
||||||
|
package org.jeecg.modules.tools.baidu;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Base64 工具类
|
||||||
|
*/
|
||||||
|
public class Base64Util {
|
||||||
|
private static final char last2byte = (char) Integer.parseInt("00000011", 2);
|
||||||
|
private static final char last4byte = (char) Integer.parseInt("00001111", 2);
|
||||||
|
private static final char last6byte = (char) Integer.parseInt("00111111", 2);
|
||||||
|
private static final char lead6byte = (char) Integer.parseInt("11111100", 2);
|
||||||
|
private static final char lead4byte = (char) Integer.parseInt("11110000", 2);
|
||||||
|
private static final char lead2byte = (char) Integer.parseInt("11000000", 2);
|
||||||
|
private static final char[] encodeTable = new char[]{'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O', 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z', 'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z', '0', '1', '2', '3', '4', '5', '6', '7', '8', '9', '+', '/'};
|
||||||
|
|
||||||
|
public Base64Util() {
|
||||||
|
}
|
||||||
|
|
||||||
|
public static String encode(byte[] from) {
|
||||||
|
StringBuilder to = new StringBuilder((int) ((double) from.length * 1.34D) + 3);
|
||||||
|
int num = 0;
|
||||||
|
char currentByte = 0;
|
||||||
|
|
||||||
|
int i;
|
||||||
|
for (i = 0; i < from.length; ++i) {
|
||||||
|
for (num %= 8; num < 8; num += 6) {
|
||||||
|
switch (num) {
|
||||||
|
case 0:
|
||||||
|
currentByte = (char) (from[i] & lead6byte);
|
||||||
|
currentByte = (char) (currentByte >>> 2);
|
||||||
|
case 1:
|
||||||
|
case 3:
|
||||||
|
case 5:
|
||||||
|
default:
|
||||||
|
break;
|
||||||
|
case 2:
|
||||||
|
currentByte = (char) (from[i] & last6byte);
|
||||||
|
break;
|
||||||
|
case 4:
|
||||||
|
currentByte = (char) (from[i] & last4byte);
|
||||||
|
currentByte = (char) (currentByte << 2);
|
||||||
|
if (i + 1 < from.length) {
|
||||||
|
currentByte = (char) (currentByte | (from[i + 1] & lead2byte) >>> 6);
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
case 6:
|
||||||
|
currentByte = (char) (from[i] & last2byte);
|
||||||
|
currentByte = (char) (currentByte << 4);
|
||||||
|
if (i + 1 < from.length) {
|
||||||
|
currentByte = (char) (currentByte | (from[i + 1] & lead4byte) >>> 4);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
to.append(encodeTable[currentByte]);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (to.length() % 4 != 0) {
|
||||||
|
for (i = 4 - to.length() % 4; i > 0; --i) {
|
||||||
|
to.append("=");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return to.toString();
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,72 @@
|
||||||
|
package org.jeecg.modules.tools.baidu;
|
||||||
|
|
||||||
|
import java.io.*;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 文件读取工具类
|
||||||
|
*/
|
||||||
|
public class FileUtil {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 读取文件内容,作为字符串返回
|
||||||
|
*/
|
||||||
|
public static String readFileAsString(String filePath) throws IOException {
|
||||||
|
File file = new File(filePath);
|
||||||
|
if (!file.exists()) {
|
||||||
|
throw new FileNotFoundException(filePath);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (file.length() > 1024 * 1024 * 1024) {
|
||||||
|
throw new IOException("File is too large");
|
||||||
|
}
|
||||||
|
|
||||||
|
StringBuilder sb = new StringBuilder((int) (file.length()));
|
||||||
|
// 创建字节输入流
|
||||||
|
FileInputStream fis = new FileInputStream(filePath);
|
||||||
|
// 创建一个长度为10240的Buffer
|
||||||
|
byte[] bbuf = new byte[10240];
|
||||||
|
// 用于保存实际读取的字节数
|
||||||
|
int hasRead = 0;
|
||||||
|
while ( (hasRead = fis.read(bbuf)) > 0 ) {
|
||||||
|
sb.append(new String(bbuf, 0, hasRead));
|
||||||
|
}
|
||||||
|
fis.close();
|
||||||
|
return sb.toString();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 根据文件路径读取byte[] 数组
|
||||||
|
*/
|
||||||
|
public static byte[] readFileByBytes(String filePath) throws IOException {
|
||||||
|
File file = new File(filePath);
|
||||||
|
if (!file.exists()) {
|
||||||
|
throw new FileNotFoundException(filePath);
|
||||||
|
} else {
|
||||||
|
ByteArrayOutputStream bos = new ByteArrayOutputStream((int) file.length());
|
||||||
|
BufferedInputStream in = null;
|
||||||
|
|
||||||
|
try {
|
||||||
|
in = new BufferedInputStream(new FileInputStream(file));
|
||||||
|
short bufSize = 1024;
|
||||||
|
byte[] buffer = new byte[bufSize];
|
||||||
|
int len1;
|
||||||
|
while (-1 != (len1 = in.read(buffer, 0, bufSize))) {
|
||||||
|
bos.write(buffer, 0, len1);
|
||||||
|
}
|
||||||
|
|
||||||
|
byte[] var7 = bos.toByteArray();
|
||||||
|
return var7;
|
||||||
|
} finally {
|
||||||
|
try {
|
||||||
|
if (in != null) {
|
||||||
|
in.close();
|
||||||
|
}
|
||||||
|
} catch (IOException var14) {
|
||||||
|
var14.printStackTrace();
|
||||||
|
}
|
||||||
|
|
||||||
|
bos.close();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,29 @@
|
||||||
|
/*
|
||||||
|
* Copyright (C) 2017 Baidu, Inc. All Rights Reserved.
|
||||||
|
*/
|
||||||
|
package org.jeecg.modules.tools.baidu;
|
||||||
|
|
||||||
|
import com.google.gson.Gson;
|
||||||
|
import com.google.gson.GsonBuilder;
|
||||||
|
import com.google.gson.JsonParseException;
|
||||||
|
|
||||||
|
import java.lang.reflect.Type;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Json工具类.
|
||||||
|
*/
|
||||||
|
public class GsonUtils {
|
||||||
|
private static Gson gson = new GsonBuilder().create();
|
||||||
|
|
||||||
|
public static String toJson(Object value) {
|
||||||
|
return gson.toJson(value);
|
||||||
|
}
|
||||||
|
|
||||||
|
public static <T> T fromJson(String json, Class<T> classOfT) throws JsonParseException {
|
||||||
|
return gson.fromJson(json, classOfT);
|
||||||
|
}
|
||||||
|
|
||||||
|
public static <T> T fromJson(String json, Type typeOfT) throws JsonParseException {
|
||||||
|
return (T) gson.fromJson(json, typeOfT);
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,77 @@
|
||||||
|
package org.jeecg.modules.tools.baidu;
|
||||||
|
|
||||||
|
import java.io.BufferedReader;
|
||||||
|
import java.io.DataOutputStream;
|
||||||
|
import java.io.InputStreamReader;
|
||||||
|
import java.net.HttpURLConnection;
|
||||||
|
import java.net.URL;
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* http 工具类
|
||||||
|
*/
|
||||||
|
public class HttpUtil {
|
||||||
|
|
||||||
|
public static String post(String requestUrl, String accessToken, String params)
|
||||||
|
throws Exception {
|
||||||
|
String contentType = "application/x-www-form-urlencoded";
|
||||||
|
return HttpUtil.post(requestUrl, accessToken, contentType, params);
|
||||||
|
}
|
||||||
|
|
||||||
|
public static String post(String requestUrl, String accessToken, String contentType, String params)
|
||||||
|
throws Exception {
|
||||||
|
String encoding = "UTF-8";
|
||||||
|
if (requestUrl.contains("nlp")) {
|
||||||
|
encoding = "GBK";
|
||||||
|
}
|
||||||
|
return HttpUtil.post(requestUrl, accessToken, contentType, params, encoding);
|
||||||
|
}
|
||||||
|
|
||||||
|
public static String post(String requestUrl, String accessToken, String contentType, String params, String encoding)
|
||||||
|
throws Exception {
|
||||||
|
String url = requestUrl + "?access_token=" + accessToken;
|
||||||
|
return HttpUtil.postGeneralUrl(url, contentType, params, encoding);
|
||||||
|
}
|
||||||
|
|
||||||
|
public static String postGeneralUrl(String generalUrl, String contentType, String params, String encoding)
|
||||||
|
throws Exception {
|
||||||
|
URL url = new URL(generalUrl);
|
||||||
|
// 打开和URL之间的连接
|
||||||
|
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
|
||||||
|
connection.setRequestMethod("POST");
|
||||||
|
// 设置通用的请求属性
|
||||||
|
connection.setRequestProperty("Content-Type", contentType);
|
||||||
|
connection.setRequestProperty("Connection", "Keep-Alive");
|
||||||
|
connection.setUseCaches(false);
|
||||||
|
connection.setDoOutput(true);
|
||||||
|
connection.setDoInput(true);
|
||||||
|
|
||||||
|
// 得到请求的输出流对象
|
||||||
|
DataOutputStream out = new DataOutputStream(connection.getOutputStream());
|
||||||
|
out.write(params.getBytes(encoding));
|
||||||
|
out.flush();
|
||||||
|
out.close();
|
||||||
|
|
||||||
|
// 建立实际的连接
|
||||||
|
connection.connect();
|
||||||
|
// 获取所有响应头字段
|
||||||
|
Map<String, List<String>> headers = connection.getHeaderFields();
|
||||||
|
// 遍历所有的响应头字段
|
||||||
|
for (String key : headers.keySet()) {
|
||||||
|
System.err.println(key + "--->" + headers.get(key));
|
||||||
|
}
|
||||||
|
// 定义 BufferedReader输入流来读取URL的响应
|
||||||
|
BufferedReader in = null;
|
||||||
|
in = new BufferedReader(
|
||||||
|
new InputStreamReader(connection.getInputStream(), encoding));
|
||||||
|
String result = "";
|
||||||
|
String getLine;
|
||||||
|
while ((getLine = in.readLine()) != null) {
|
||||||
|
result += getLine;
|
||||||
|
}
|
||||||
|
in.close();
|
||||||
|
System.err.println("result:" + result);
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
}
|
|
@ -318,3 +318,7 @@ ffmpeg:
|
||||||
isDeleteSourceFile: true
|
isDeleteSourceFile: true
|
||||||
# 压缩文件扩展名范围
|
# 压缩文件扩展名范围
|
||||||
extensionFilter: png,jpg,jpeg
|
extensionFilter: png,jpg,jpeg
|
||||||
|
# 维普检测接口
|
||||||
|
weipu:
|
||||||
|
userId: 765996
|
||||||
|
userKey: 330ed91f6c7e4600a454a6a5216723bf
|
6
pom.xml
6
pom.xml
|
@ -143,6 +143,12 @@
|
||||||
<!-- <artifactId>jeecg-boot-base-core</artifactId>-->
|
<!-- <artifactId>jeecg-boot-base-core</artifactId>-->
|
||||||
<!-- </dependency>-->
|
<!-- </dependency>-->
|
||||||
|
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.baidu.aip</groupId>
|
||||||
|
<artifactId>java-sdk</artifactId>
|
||||||
|
<version>4.16.18</version>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
</dependencies>
|
</dependencies>
|
||||||
|
|
||||||
<dependencyManagement>
|
<dependencyManagement>
|
||||||
|
|
Loading…
Reference in New Issue