Compare commits

..

2 Commits

Author SHA1 Message Date
曹磊 c41418ffec Merge remote-tracking branch 'origin/main' 2024-09-06 14:00:38 +08:00
曹磊 3fd1da4f0b 毕业论文 2024-09-06 13:59:57 +08:00
15 changed files with 1702 additions and 0 deletions

View File

@ -0,0 +1,239 @@
package org.jeecg.modules.demo.lwKhcl.controller;
import javax.annotation.Resource;
import javax.servlet.http.HttpServletRequest;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import org.apache.poi.ss.usermodel.Workbook;
import org.apache.shiro.SecurityUtils;
import org.jeecg.common.api.vo.Result;
import org.jeecg.common.system.query.QueryGenerator;
import org.jeecg.common.system.vo.LoginUser;
import org.jeecg.common.util.oConvertUtils;
import org.jeecg.config.JeecgBaseConfig;
import org.jeecg.modules.demo.lwKhcl.entity.LwKhcl;
import org.jeecg.modules.demo.lwKhcl.entity.LwKhclCj;
import org.jeecg.modules.demo.lwKhcl.entity.LwKhclXq;
import org.jeecg.modules.demo.lwKhcl.service.ILwKhclService;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import lombok.extern.slf4j.Slf4j;
import org.jeecg.common.system.base.controller.JeecgController;
import org.jeecgframework.poi.excel.ExcelExportUtil;
import org.jeecgframework.poi.excel.annotation.Excel;
import org.jeecgframework.poi.excel.def.NormalExcelConstants;
import org.jeecgframework.poi.excel.entity.ExportParams;
import org.jeecgframework.poi.excel.entity.params.ExcelExportEntity;
import org.jeecgframework.poi.excel.view.JeecgEntityExcelView;
import org.jeecgframework.poi.util.ExcelUtil;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.servlet.ModelAndView;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import java.io.FileOutputStream;
import java.lang.reflect.Field;
import java.lang.reflect.InvocationHandler;
import java.lang.reflect.Proxy;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
import java.util.Map;
/**
* @Description: lw_khcl
* @Author: jeecg-boot
* @Date: 2024-09-05
* @Version: V1.0
*/
@Api(tags="lw_khcl")
@RestController
@RequestMapping("/lwKhcl/lwKhcl")
@Slf4j
public class LwKhclController extends JeecgController<LwKhcl, ILwKhclService> {
@Autowired
private ILwKhclService lwKhclService;
@Resource
private JeecgBaseConfig jeecgBaseConfig;
/**
* 分页列表查询
*
* @param lwKhcl
* @param pageNo
* @param pageSize
* @param req
* @return
*/
//@AutoLog(value = "lw_khcl-分页列表查询")
@ApiOperation(value="lw_khcl-分页列表查询", notes="lw_khcl-分页列表查询")
@GetMapping(value = "/list")
public Result<IPage<LwKhcl>> queryPageList(LwKhcl lwKhcl,
@RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
HttpServletRequest req) {
String bynf = req.getParameter("bynf");
String ssyxmc = req.getParameter("ssyxmc");
String ssxnzymc = req.getParameter("ssxnzymc");
Page<LwKhcl> page = new Page<LwKhcl>(pageNo, pageSize);
IPage<LwKhcl> pageList = lwKhclService.getPage(page, bynf, ssyxmc, ssxnzymc);
return Result.OK(pageList);
}
/**
* 通过id查询
*
* @param id
* @return
*/
//@AutoLog(value = "lw_khcl-通过id查询")
@ApiOperation(value="lw_khcl-通过id查询", notes="lw_khcl-通过id查询")
@GetMapping(value = "/queryById")
public Result<LwKhcl> queryById(@RequestParam(name="id",required=true) String id) {
LwKhcl lwKhcl = lwKhclService.getById(id);
if(lwKhcl==null) {
return Result.error("未找到对应数据");
}
return Result.OK(lwKhcl);
}
/**
* 导出excel
* @param request
* @param lwKhcl
*/
@RequestMapping(value = "/exportXls")
public ModelAndView exportXls(HttpServletRequest request, LwKhcl lwKhcl) {
LoginUser sysUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
String bynf = request.getParameter("bynf");
String ssyxmc = request.getParameter("ssyxmc");
String ssxnzymc = request.getParameter("ssxnzymc");
List<LwKhcl> exportList = lwKhclService.getList(bynf, ssyxmc, ssxnzymc);
// Step.3 AutoPoi 导出Excel
ModelAndView mv = new ModelAndView(new JeecgEntityExcelView());
//此处设置的filename无效 ,前端会重更新设置一下
mv.addObject(NormalExcelConstants.FILE_NAME, "论文考核材料列表");
mv.addObject(NormalExcelConstants.CLASS, LwKhcl.class);
//update-begin--Author:liusq Date:20210126 for图片导出报错ImageBasePath未设置--------------------
ExportParams exportParams=new ExportParams("论文考核材料", "导出人:" + sysUser.getRealname(), "sheet1");
exportParams.setImageBasePath(jeecgBaseConfig.getPath().getUpload());
//update-end--Author:liusq Date:20210126 for图片导出报错ImageBasePath未设置----------------------
mv.addObject(NormalExcelConstants.PARAMS,exportParams);
mv.addObject(NormalExcelConstants.DATA_LIST, exportList);
return mv;
}
/**
* 分页列表查询
*
* @param lwKhclCj
* @param pageNo
* @param pageSize
* @param req
* @return
*/
//@AutoLog(value = "lw_khcl-分页列表查询")
@ApiOperation(value="lw_khcl-分页列表查询", notes="lw_khcl-分页列表查询")
@GetMapping(value = "/cjList")
public Result<IPage<LwKhclCj>> queryCjPageList(LwKhclCj lwKhclCj,
@RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
HttpServletRequest req) {
String bynf = req.getParameter("bynf");
String ssyxmc = req.getParameter("ssyxmc");
String ssxnzymc = req.getParameter("ssxnzymc");
String xsxm = req.getParameter("xsxm");
String zdjsxm = req.getParameter("zdjsxm");
String bylwTm = req.getParameter("bylwTm");
Page<LwKhclCj> page = new Page<LwKhclCj>(pageNo, pageSize);
IPage<LwKhclCj> pageList = lwKhclService.getCjPage(page, bynf, ssyxmc, ssxnzymc, xsxm, zdjsxm, bylwTm);
return Result.OK(pageList);
}
/**
* 导出excel
* @param request
* @param lwKhclCj
*/
@RequestMapping(value = "/cjExportXls")
public ModelAndView cjExportXls(HttpServletRequest request, LwKhclCj lwKhclCj) {
LoginUser sysUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
String bynf = request.getParameter("bynf");
String ssyxmc = request.getParameter("ssyxmc");
String ssxnzymc = request.getParameter("ssxnzymc");
String xsxm = request.getParameter("xsxm");
String zdjsxm = request.getParameter("zdjsxm");
String bylwTm = request.getParameter("bylwTm");
List<LwKhclCj> exportList = lwKhclService.getCjList(bynf, ssyxmc, ssxnzymc, xsxm, zdjsxm, bylwTm);
// Step.3 AutoPoi 导出Excel
ModelAndView mv = new ModelAndView(new JeecgEntityExcelView());
//此处设置的filename无效 ,前端会重更新设置一下
mv.addObject(NormalExcelConstants.FILE_NAME, "论文考核材料成绩");
mv.addObject(NormalExcelConstants.CLASS, LwKhclCj.class);
//update-begin--Author:liusq Date:20210126 for图片导出报错ImageBasePath未设置--------------------
ExportParams exportParams=new ExportParams("论文考核材料成绩", "导出人:" + sysUser.getRealname(), "sheet1");
exportParams.setImageBasePath(jeecgBaseConfig.getPath().getUpload());
//update-end--Author:liusq Date:20210126 for图片导出报错ImageBasePath未设置----------------------
mv.addObject(NormalExcelConstants.PARAMS,exportParams);
mv.addObject(NormalExcelConstants.DATA_LIST, exportList);
return mv;
}
/**
* 分页列表查询
*
* @param lwKhclXq
* @param pageNo
* @param pageSize
* @param req
* @return
*/
//@AutoLog(value = "lw_khcl-分页列表查询")
@ApiOperation(value="lw_khcl-分页列表查询", notes="lw_khcl-分页列表查询")
@GetMapping(value = "/xqList")
public Result<IPage<LwKhclXq>> queryXqPageList(LwKhclXq lwKhclXq,
@RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
HttpServletRequest req) {
String xsxh = req.getParameter("xsxh");
String xsxm = req.getParameter("xsxm");
String ssxnzymc = req.getParameter("ssxnzymc");
String ktbg = req.getParameter("ktbg");
String zqjc = req.getParameter("zqjc");
String lwzg = req.getParameter("lwzg");
Page<LwKhclXq> page = new Page<LwKhclXq>(pageNo, pageSize);
IPage<LwKhclXq> pageList = lwKhclService.getXqPage(page, xsxh,xsxm,ssxnzymc,ktbg,zqjc,lwzg);
return Result.OK(pageList);
}
/**
* 导出excel
* @param request
* @param lwKhclXq
*/
@RequestMapping(value = "/xqExportXls")
public ModelAndView xqExportXls(HttpServletRequest request, LwKhclXq lwKhclXq) {
LoginUser sysUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
String xsxh = request.getParameter("xsxh");
String xsxm = request.getParameter("xsxm");
String ssxnzymc = request.getParameter("ssxnzymc");
String ktbg = request.getParameter("ktbg");
String zqjc = request.getParameter("zqjc");
String lwzg = request.getParameter("lwzg");
List<LwKhclXq> exportList = lwKhclService.getXqList(xsxh,xsxm,ssxnzymc,ktbg,zqjc,lwzg);
// Step.3 AutoPoi 导出Excel
ModelAndView mv = new ModelAndView(new JeecgEntityExcelView());
//此处设置的filename无效 ,前端会重更新设置一下
mv.addObject(NormalExcelConstants.FILE_NAME, "论文考核材料成绩");
mv.addObject(NormalExcelConstants.CLASS, LwKhclXq.class);
//update-begin--Author:liusq Date:20210126 for图片导出报错ImageBasePath未设置--------------------
ExportParams exportParams=new ExportParams("论文考核材料成绩", "导出人:" + sysUser.getRealname(), "sheet1");
exportParams.setImageBasePath(jeecgBaseConfig.getPath().getUpload());
//update-end--Author:liusq Date:20210126 for图片导出报错ImageBasePath未设置----------------------
mv.addObject(NormalExcelConstants.PARAMS,exportParams);
mv.addObject(NormalExcelConstants.DATA_LIST, exportList);
return mv;
}
}

View File

@ -0,0 +1,45 @@
package org.jeecg.modules.demo.lwKhcl.entity;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import org.jeecg.common.aspect.annotation.Dict;
import org.jeecgframework.poi.excel.annotation.Excel;
import java.io.Serializable;
/**
* @Description: lw_khcl
* @Author: jeecg-boot
* @Date: 2024-09-05
* @Version: V1.0
*/
@Data
@TableName("lw_khcl")
@Accessors(chain = true)
@EqualsAndHashCode(callSuper = false)
@ApiModel(value="lw_khcl对象", description="lw_khcl")
public class LwKhcl implements Serializable {
private static final long serialVersionUID = 1L;
/**主键*/
@TableId(type = IdType.ASSIGN_ID)
@ApiModelProperty(value = "主键")
private String id;
/**毕业年份*/
@Excel(name = "毕业年份", width = 15)
@ApiModelProperty(value = "毕业年份")
private String bynf;
/**所属院系名称*/
@Excel(name = "所属院系名称", width = 25)
@ApiModelProperty(value = "所属院系名称")
private String ssyxmc;
/**所属校内专业(大类)名称*/
@Excel(name = "所属校内专业(大类)名称", width = 35)
@ApiModelProperty(value = "所属校内专业(大类)名称")
private String ssxnzymc;
}

View File

@ -0,0 +1,88 @@
package org.jeecg.modules.demo.lwKhcl.entity;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import org.jeecg.common.aspect.annotation.Dict;
import org.jeecgframework.poi.excel.annotation.Excel;
import java.io.Serializable;
/**
* @Description: lw_khcl
* @Author: jeecg-boot
* @Date: 2024-09-05
* @Version: V1.0
*/
@Data
@TableName("lw_khcl")
@Accessors(chain = true)
@EqualsAndHashCode(callSuper = false)
@ApiModel(value="lw_khcl对象", description="lw_khcl")
public class LwKhclCj implements Serializable {
private static final long serialVersionUID = 1L;
/**主键*/
@TableId(type = IdType.ASSIGN_ID)
@ApiModelProperty(value = "主键")
private String id;
/**学生学号*/
@Excel(name = "学生学号", width = 15)
@ApiModelProperty(value = "学生学号")
private String xsxh;
/**学生姓名*/
@Excel(name = "学生姓名", width = 15)
@ApiModelProperty(value = "学生姓名")
private String xsxm;
/**毕业年份*/
@Excel(name = "毕业年份", width = 15)
@ApiModelProperty(value = "毕业年份")
private String bynf;
/**班级*/
@Excel(name = "班级", width = 15)
@ApiModelProperty(value = "班级")
private String bj;
/**毕业论文(设计)题目*/
@Excel(name = "毕业论文(设计)题目", width = 30)
@ApiModelProperty(value = "毕业论文(设计)题目")
private String bylwTm;
/**毕业论文(设计)类别*/
@Excel(name = "毕业论文(设计)类别", width = 30)
@ApiModelProperty(value = "毕业论文(设计)类别")
private String bylwLb;
/**毕业论文(设计)成绩*/
@Excel(name = "毕业论文(设计)成绩", width = 15)
@ApiModelProperty(value = "毕业论文(设计)成绩")
private String bylwCj;
/**指导教师姓名*/
@Excel(name = "指导教师姓名", width = 15)
@ApiModelProperty(value = "指导教师姓名")
private String zdjsxm;
/**指导教师职称*/
@Excel(name = "指导教师职称", width = 15)
@ApiModelProperty(value = "指导教师职称")
private String zdjszc;
/**所属院系名称*/
@Excel(name = "所属院系名称", width = 20)
@ApiModelProperty(value = "所属院系名称")
private String ssyxmc;
/**所属校内专业(大类)名称*/
@Excel(name = "所属校内专业(大类)名称", width = 20)
@ApiModelProperty(value = "所属校内专业(大类)名称")
private String ssxnzymc;
/**是否实现电子化管理*/
@Excel(name = "是否实现电子化管理", width = 15)
@ApiModelProperty(value = "是否实现电子化管理")
private String sfsxdzhgl;
/**关键词*/
@ApiModelProperty(value = "关键词")
private String gjc;
/**查重结果*/
@ApiModelProperty(value = "查重结果")
private String ccjg;
}

View File

@ -0,0 +1,77 @@
package org.jeecg.modules.demo.lwKhcl.entity;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import org.jeecg.common.aspect.annotation.Dict;
import org.jeecgframework.poi.excel.annotation.Excel;
import java.io.Serializable;
/**
* @Description: lw_khcl
* @Author: jeecg-boot
* @Date: 2024-09-05
* @Version: V1.0
*/
@Data
@TableName("lw_khcl")
@Accessors(chain = true)
@EqualsAndHashCode(callSuper = false)
@ApiModel(value="lw_khcl对象", description="lw_khcl")
public class LwKhclXq implements Serializable {
private static final long serialVersionUID = 1L;
/**主键*/
@TableId(type = IdType.ASSIGN_ID)
@ApiModelProperty(value = "主键")
private String id;
/**学生学号*/
@Excel(name = "学生学号", width = 15)
@ApiModelProperty(value = "学生学号")
private String xsxh;
/**学生姓名*/
@Excel(name = "学生姓名", width = 15)
@ApiModelProperty(value = "学生姓名")
private String xsxm;
/**毕业年份*/
@Excel(name = "毕业年份", width = 15)
@ApiModelProperty(value = "毕业年份")
private String bynf;
/**班级*/
@Excel(name = "班级", width = 15)
@ApiModelProperty(value = "班级")
private String bj;
/**毕业论文(设计)题目*/
@Excel(name = "毕业论文(设计)题目", width = 30)
@ApiModelProperty(value = "毕业论文(设计)题目")
private String bylwTm;
/**毕业论文(设计)类别*/
@Excel(name = "毕业论文(设计)类别", width = 30)
@ApiModelProperty(value = "毕业论文(设计)类别")
private String bylwLb;
// @Excel(name = "开题报告", width = 30)
@ApiModelProperty(value = "开题报告")
private String ktbg;
/**开题报告审核意见*/
// @Excel(name = "开题报告审核意见", width = 30)
@ApiModelProperty(value = "开题报告审核意见")
private String ktbgshyj;
/**中期检查*/
// @Excel(name = "中期检查", width = 30)
@ApiModelProperty(value = "中期检查")
private String zqjc;
/**论文终稿*/
// @Excel(name = "论文终稿", width = 30)
@ApiModelProperty(value = "论文终稿")
private String lwzg;
/**检测报告等材料*/
// @Excel(name = "检测报告等材料", width = 30)
@ApiModelProperty(value = "检测报告等材料")
private String jcbgdcl;
}

View File

@ -0,0 +1,26 @@
package org.jeecg.modules.demo.lwKhcl.mapper;
import java.util.List;
import java.util.Map;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.apache.ibatis.annotations.Param;
import org.jeecg.modules.demo.lwKhcl.entity.LwKhcl;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.jeecg.modules.demo.lwKhcl.entity.LwKhclCj;
import org.jeecg.modules.demo.lwKhcl.entity.LwKhclXq;
/**
* @Description: lw_khcl
* @Author: jeecg-boot
* @Date: 2024-09-05
* @Version: V1.0
*/
public interface LwKhclMapper extends BaseMapper<LwKhcl> {
List<LwKhcl> getPage(Page<LwKhcl> page, @Param("bynf")String bynf, @Param("ssyxmc")String ssyxmc, @Param("ssxnzymc")String ssxnzymc);
List<LwKhclCj> getCjPage(Page<LwKhclCj> page, @Param("bynf")String bynf, @Param("ssyxmc")String ssyxmc, @Param("ssxnzymc")String ssxnzymc, @Param("xsxm")String xsxm, @Param("zdjsxm")String zdjsxm, @Param("bylwTm")String bylwTm);
List<LwKhclXq> getXqPage(Page<LwKhclXq> page, @Param("xsxh")String xsxh, @Param("xsxm")String xsxm, @Param("ssxnzymc")String ssxnzymc, @Param("ktbg")String ktbg, @Param("zqjc")String zqjc, @Param("lwzg")String lwzg);
}

View File

@ -0,0 +1,78 @@
<?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.demo.lwKhcl.mapper.LwKhclMapper">
<select id="getPage" parameterType="String" resultType="org.jeecg.modules.demo.lwKhcl.entity.LwKhcl">
select bynf,ssyxmc,ssxnzymc
from lw_khcl
where 1=1
<if test="bynf!=null and bynf!=''">
and bynf = #{bynf}
</if>
<if test="ssyxmc!=null and ssyxmc!=''">
<bind name="bindssyxmc" value="'%'+ssyxmc+'%'"/>
and ssyxmc like #{bindssyxmc}
</if>
<if test="ssxnzymc!=null and ssxnzymc!=''">
<bind name="bindssxnzymc" value="'%'+ssxnzymc+'%'"/>
and ssxnzymc like #{bindssxnzymc}
</if>
group by bynf,ssyxmc,ssxnzymc
order by bynf DESC
</select>
<select id="getCjPage" parameterType="String" resultType="org.jeecg.modules.demo.lwKhcl.entity.LwKhclCj">
select *
from lw_khcl
where bynf = #{bynf}
and ssyxmc = #{ssyxmc}
and ssxnzymc = #{ssxnzymc}
<if test="xsxm!=null and xsxm!=''">
<bind name="bindxsxm" value="'%'+xsxm+'%'"/>
and xsxm like #{bindxsxm}
</if>
<if test="zdjsxm!=null and zdjsxm!=''">
<bind name="bindzdjsxm" value="'%'+zdjsxm+'%'"/>
and zdjsxm like #{bindzdjsxm}
</if>
<if test="bylwTm!=null and bylwTm!=''">
<bind name="bindbylwTm" value="'%'+bylwTm+'%'"/>
and bylwTm like #{bindbylwTm}
</if>
order by xsxh
</select>
<select id="getXqPage" parameterType="String" resultType="org.jeecg.modules.demo.lwKhcl.entity.LwKhclXq">
select *
from lw_khcl
where xsxh = #{xsxh}
<if test="xsxm!=null and xsxm!=''">
<bind name="bindxsxm" value="'%'+xsxm+'%'"/>
and xsxm like #{bindxsxm}
</if>
<if test="ssxnzymc!=null and ssxnzymc!=''">
<bind name="bindssxnzymc" value="'%'+ssxnzymc+'%'"/>
and ssxnzymc like #{bindssxnzymc}
</if>
<if test="ktbg!=null and ktbg==1">
and ktbg is not null
</if>
<if test="ktbg!=null and ktbg==0">
and ktbg is null
</if>
<if test="zqjc!=null and zqjc==1">
and zqjc is not null
</if>
<if test="zqjc!=null and zqjc==0">
and zqjc is null
</if>
<if test="lwzg!=null and lwzg==1">
and lwzg is not null
</if>
<if test="lwzg!=null and lwzg==0">
and lwzg is null
</if>
order by xsxh
</select>
</mapper>

View File

@ -0,0 +1,27 @@
package org.jeecg.modules.demo.lwKhcl.service;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.jeecg.modules.demo.lwKhcl.entity.LwKhcl;
import com.baomidou.mybatisplus.extension.service.IService;
import org.jeecg.modules.demo.lwKhcl.entity.LwKhclCj;
import org.jeecg.modules.demo.lwKhcl.entity.LwKhclXq;
import java.util.List;
import java.util.Map;
/**
* @Description: lw_khcl
* @Author: jeecg-boot
* @Date: 2024-09-05
* @Version: V1.0
*/
public interface ILwKhclService extends IService<LwKhcl> {
Page<LwKhcl> getPage(Page<LwKhcl> page, String bynf, String ssyxmc, String ssxnzymc);
List<LwKhcl> getList(String bynf, String ssyxmc, String ssxnzymc);
Page<LwKhclCj> getCjPage(Page<LwKhclCj> page, String bynf, String ssyxmc, String ssxnzymc, String xsxm, String zdjsxm, String bylwTm);
List<LwKhclCj> getCjList(String bynf, String ssyxmc, String ssxnzymc, String xsxm, String zdjsxm, String bylwTm);
Page<LwKhclXq> getXqPage(Page<LwKhclXq> page, String xsxh, String xsxm, String ssxnzymc, String ktbg, String zqjc, String lwzg);
List<LwKhclXq> getXqList(String xsxh, String xsxm, String ssxnzymc, String ktbg, String zqjc, String lwzg);
}

View File

@ -0,0 +1,55 @@
package org.jeecg.modules.demo.lwKhcl.service.impl;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.jeecg.modules.demo.lwKhcl.entity.LwKhcl;
import org.jeecg.modules.demo.lwKhcl.entity.LwKhclCj;
import org.jeecg.modules.demo.lwKhcl.entity.LwKhclXq;
import org.jeecg.modules.demo.lwKhcl.mapper.LwKhclMapper;
import org.jeecg.modules.demo.lwKhcl.service.ILwKhclService;
import org.springframework.stereotype.Service;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import java.util.List;
import java.util.Map;
/**
* @Description: lw_khcl
* @Author: jeecg-boot
* @Date: 2024-09-05
* @Version: V1.0
*/
@Service
public class LwKhclServiceImpl extends ServiceImpl<LwKhclMapper, LwKhcl> implements ILwKhclService {
@Override
public Page<LwKhcl> getPage(Page<LwKhcl> page, String bynf, String ssyxmc, String ssxnzymc){
return page.setRecords(baseMapper.getPage(page, bynf, ssyxmc, ssxnzymc));
}
@Override
public List<LwKhcl> getList(String bynf, String ssyxmc, String ssxnzymc){
return baseMapper.getPage(null, bynf, ssyxmc, ssxnzymc);
}
@Override
public Page<LwKhclCj> getCjPage(Page<LwKhclCj> page, String bynf, String ssyxmc, String ssxnzymc, String xsxm, String zdjsxm, String bylwTm){
return page.setRecords(baseMapper.getCjPage(page, bynf, ssyxmc, ssxnzymc, xsxm, zdjsxm, bylwTm));
}
@Override
public List<LwKhclCj> getCjList(String bynf, String ssyxmc, String ssxnzymc, String xsxm, String zdjsxm, String bylwTm){
return baseMapper.getCjPage(null, bynf, ssyxmc, ssxnzymc, xsxm, zdjsxm, bylwTm);
}
@Override
public Page<LwKhclXq> getXqPage(Page<LwKhclXq> page, String xsxh, String xsxm, String ssxnzymc, String ktbg, String zqjc, String lwzg){
return page.setRecords(baseMapper.getXqPage(page, xsxh ,xsxm, ssxnzymc, ktbg, zqjc, lwzg));
}
@Override
public List<LwKhclXq> getXqList(String xsxh, String xsxm, String ssxnzymc, String ktbg, String zqjc, String lwzg){
return baseMapper.getXqPage(null, xsxh ,xsxm, ssxnzymc, ktbg, zqjc, lwzg);
}
}

View File

@ -0,0 +1,29 @@
import { defHttp } from '/@/utils/http/axios';
import { useMessage } from "/@/hooks/web/useMessage";
const { createConfirm } = useMessage();
enum Api {
list = '/lwKhcl/lwKhcl/list',
cjList = '/lwKhcl/lwKhcl/cjList',
xqList = '/lwKhcl/lwKhcl/xqList',
exportXls = '/lwKhcl/lwKhcl/exportXls',
cjExportXls = '/lwKhcl/lwKhcl/cjExportXls',
xqExportXls = '/lwKhcl/lwKhcl/xqExportXls',
}
/**
* api
* @param params
*/
export const getExportUrl = Api.exportXls;
export const getCjExportUrl = Api.cjExportXls;
export const getXqExportUrl = Api.xqExportXls;
/**
*
* @param params
*/
export const list = (params) => defHttp.get({ url: Api.list, params });
export const cjList = (params) => defHttp.get({ url: Api.cjList, params });
export const xqList = (params) => defHttp.get({ url: Api.xqList, params });

View File

@ -0,0 +1,254 @@
import {BasicColumn} from '/@/components/Table';
import {FormSchema} from '/@/components/Table';
import { rules} from '/@/utils/helper/validator';
import { render } from '/@/utils/common/renderUtils';
import { getWeekMonthQuarterYear } from '/@/utils';
//列表数据
export const columns: BasicColumn[] = [
{
title: '毕业年份',
align: "center",
dataIndex: 'bynf'
},
{
title: '学院',
align: "center",
dataIndex: 'ssyxmc'
},
{
title: '所属校内专业(大类)名称',
align: "center",
dataIndex: 'ssxnzymc'
},
];
//列表数据
export const columnsCj: BasicColumn[] = [
{
title: '学号',
align: "center",
dataIndex: 'xsxh',
width:120,
},
{
title: '学生姓名',
align: "center",
dataIndex: 'xsxm',
width:120,
},
{
title: '毕业年份',
align: "center",
dataIndex: 'bynf',
width:120,
},
{
title: '班级',
align: "center",
dataIndex: 'bj',
width:120,
},
{
title: '毕业论文(设计)题目',
align: "center",
dataIndex: 'bylwTm',
width:220,
},
{
title: '毕业论文(设计)类别',
align: "center",
dataIndex: 'bylwLb',
width:220,
},
{
title: '毕业论文(设计)成绩',
align: "center",
dataIndex: 'bylwCj',
width:220,
},
{
title: '指导教师姓名',
align: "center",
dataIndex: 'zdjsxm',
width:120,
},
{
title: '指导教师职称',
align: "center",
dataIndex: 'zdjszc',
width:120,
},
{
title: '所属院系名称',
align: "center",
dataIndex: 'ssyxmc',
width:120,
},
{
title: '所属校内专业(大类)名称',
align: "center",
dataIndex: 'ssxnzymc',
width:220,
},
{
title: '是否电子化管理',
align: "center",
dataIndex: 'sfsxdzhgl',
width:120,
},
{
title: '关键词',
align: "center",
dataIndex: 'gjc',
width:120,
},
{
title: '查重结果',
align: "center",
dataIndex: 'ccjg',
width:120,
slots: { customRender: 'ccjg' },
}
];
//列表数据
export const columnsXq: BasicColumn[] = [
{
title: '学生学号',
align: "center",
dataIndex: 'xsxh',
width:120,
},
{
title: '学生姓名',
align: "center",
dataIndex: 'xsxm',
width:120,
},
{
title: '毕业年份',
align: "center",
dataIndex: 'bynf',
width:120,
},
{
title: '班级',
align: "center",
dataIndex: 'bj',
width:120,
},
{
title: '毕业论文(设计)题目',
align: "center",
dataIndex: 'bylwTm',
width:220,
},
{
title: '毕业论文(设计)类别',
align: "center",
dataIndex: 'bylwLb',
width:220,
},
{
title: '开题报告',
align: "center",
dataIndex: 'ktbg',
width:200,
children: [
{
title: '预览',
dataIndex: 'ktbg',
width: 100,
slots: { customRender: 'ktbg_yl' },
},
{
title: '下载',
dataIndex: 'ktbg',
width: 100,
slots: { customRender: 'ktbg_xz' },
},
],
},
{
title: '开题报告审核意见',
align: "center",
dataIndex: 'ktbgshyj',
width:200,
children: [
{
title: '预览',
dataIndex: 'ktbgshyj',
width: 100,
slots: { customRender: 'ktbgshyj_yl' },
},
{
title: '下载',
dataIndex: 'ktbgshyj',
width: 100,
slots: { customRender: 'ktbgshyj_xz' },
},
],
},
{
title: '中期检查',
align: "center",
dataIndex: 'zqjc',
width:200,
children: [
{
title: '预览',
dataIndex: 'zqjc',
width: 100,
slots: { customRender: 'zqjc_yl' },
},
{
title: '下载',
dataIndex: 'zqjc',
width: 100,
slots: { customRender: 'zqjc_xz' },
},
],
},
{
title: '论文终稿',
align: "center",
dataIndex: 'lwzg',
width:200,
children: [
{
title: '预览',
dataIndex: 'lwzg',
width: 100,
slots: { customRender: 'lwzg_yl' },
},
{
title: '下载',
dataIndex: 'lwzg',
width: 100,
slots: { customRender: 'lwzg_xz' },
},
],
},
{
title: '检测报告等材料',
align: "center",
dataIndex: 'jcbgdcl',
width:200,
children: [
{
title: '预览',
dataIndex: 'jcbgdcl',
width: 100,
slots: { customRender: 'jcbgdcl_yl' },
},
{
title: '下载',
dataIndex: 'jcbgdcl',
width: 100,
slots: { customRender: 'jcbgdcl_xz' },
},
],
},
];

View File

@ -0,0 +1,211 @@
<template>
<div class="p-2">
<!--查询区域-->
<div class="jeecg-basic-table-form-container">
<a-form ref="formRef" @keyup.enter.native="searchQuery" :model="queryParam" :label-col="labelCol" :wrapper-col="wrapperCol">
<a-row :gutter="24">
<a-col :lg="6">
<a-form-item name="xsxm">
<template #label><span title="学生姓名">学生姓名</span></template>
<a-input placeholder="请输入学生姓名" v-model:value="queryParam.xsxm" allow-clear ></a-input>
</a-form-item>
</a-col>
<a-col :lg="6">
<a-form-item name="zdjsxm">
<template #label><span title="指导教师">指导教师</span></template>
<a-input placeholder="请输入指导教师" v-model:value="queryParam.zdjsxm" allow-clear ></a-input>
</a-form-item>
</a-col>
<a-col :lg="6">
<a-form-item name="bylwTm">
<template #label><span title="论文题目">论文题目</span></template>
<a-input placeholder="请输入论文题目" v-model:value="queryParam.bylwTm" allow-clear ></a-input>
</a-form-item>
</a-col>
<a-col :xl="6" :lg="7" :md="8" :sm="24">
<span style="float: left; overflow: hidden" class="table-page-search-submitButtons">
<a-col :lg="6">
<a-button type="primary" preIcon="ant-design:search-outlined" @click="searchQuery">查询</a-button>
<a-button type="primary" preIcon="ant-design:reload-outlined" @click="searchReset" style="margin-left: 8px">重置</a-button>
<a-button type="primary" preIcon="ant-design:export-outlined" @click="onExportXls" style="margin-left: 8px"> 导出</a-button>
</a-col>
</span>
</a-col>
</a-row>
</a-form>
</div>
<!--引用表格-->
<BasicTable @register="registerTable" :rowSelection="rowSelection">
<!--插槽:table标题-->
<template #tableTitle>
</template>
<!--操作栏-->
<template #action="{ record }">
<TableAction :actions="getTableAction(record)"/>
</template>
<template v-slot:bodyCell="{ column, record, index, text }">
</template>
<template #ccjg="{record}">
<a-button size="large" preIcon="ant-design:eye-outlined" style="border: 0px;" @click="openWindow(record)"></a-button>
</template>
</BasicTable>
<!-- 表单区域 -->
<LwKhclXqModal ref="registerModal" @success="handleSuccess"></LwKhclXqModal>
</div>
</template>
<script lang="ts" name="lwKhcl-lwKhcl" setup>
import {ref, reactive, defineProps, nextTick, defineExpose} from 'vue';
import { SearchOutlined } from '@ant-design/icons-vue';
import { BasicTable, useTable, TableAction } from '/@/components/Table';
import { useListPage } from '/@/hooks/system/useListPage';
import { columnsCj } from './../LwKhcl.data';
import { cjList, getCjExportUrl } from './../LwKhcl.api';
import { downloadFile } from '/@/utils/common/renderUtils';
import LwKhclXqModal from './LwKhclXqModal.vue'
import { useUserStore } from '/@/store/modules/user';
import JDictSelectTag from '/@/components/Form/src/jeecg/components/JDictSelectTag.vue';
const props = defineProps({
formDisabled: { type: Boolean, default: false },
formData: { type: Object, default: () => ({})},
formBpm: { type: Boolean, default: true }
});
const formRef = ref();
const queryParam = reactive<any>({
bynf: '',
ssyxmc: '',
ssxnzymc: '',
});
const toggleSearchStatus = ref<boolean>(false);
const registerModal = ref();
const userStore = useUserStore();
//table
const { prefixCls, tableContext, onExportXls } = useListPage({
tableProps: {
title: 'lw_khcl',
api: cjList,
columns: columnsCj,
canResize:false,
useSearchForm: false,
actionColumn: {
width: 120,
fixed: 'right',
},
beforeFetch: async (params) => {
return Object.assign(params, queryParam);
},
},
exportConfig: {
name: "论文考核材料成绩",
url: getCjExportUrl,
params: queryParam,
}
});
const [registerTable, { reload, collapseAll, updateTableDataRecord, findTableDataRecord, getDataSource }, { rowSelection, selectedRowKeys }] = tableContext;
const labelCol = reactive({
xs:24,
sm:4,
xl:6,
xxl:4
});
const wrapperCol = reactive({
xs: 24,
sm: 20,
});
/**
* 详情
*/
function handleDetail(record: Recordable) {
registerModal.value.disableSubmit = true;
registerModal.value.init(record);
}
/**
* 成功回调
*/
function handleSuccess() {
(selectedRowKeys.value = []) && reload();
}
/**
* 操作栏
*/
function getTableAction(record) {
return [
{
label: '详情',
onClick: handleDetail.bind(null, record),
},
];
}
/**
* 查询
*/
function searchQuery() {
reload();
}
/**
* 重置
*/
function searchReset() {
formRef.value.resetFields();
selectedRowKeys.value = [];
//
reload();
}
function openWindow(record){
console.log(record.ccjg);
window.open(record.ccjg,"_blank");
}
function init(record) {
nextTick(() => {
const tmpData = {};
Object.keys(queryParam).forEach((key) => {
if(record.hasOwnProperty(key)){
tmpData[key] = record[key]
}
})
//
Object.assign(queryParam, tmpData);
reload();
});
}
defineExpose({
init
});
</script>
<style lang="less" scoped>
.jeecg-basic-table-form-container {
padding: 0;
.table-page-search-submitButtons {
display: block;
margin-bottom: 24px;
white-space: nowrap;
}
.query-group-cust{
min-width: 100px !important;
}
.query-group-split-cust{
width: 30px;
display: inline-block;
text-align: center
}
.ant-form-item:not(.ant-form-item-with-help){
margin-bottom: 16px;
height: 32px;
}
:deep(.ant-picker),:deep(.ant-input-number){
width: 100%;
}
}
</style>

View File

@ -0,0 +1,50 @@
<template>
<j-modal :title="title" :width="width" :visible="visible" :okButtonProps="{ class: { 'jee-hidden': disableSubmit } }" @cancel="handleCancel" cancelText="关闭">
<LwKhclCjList ref="registerForm" :formDisabled="disableSubmit" :formBpm="false"></LwKhclCjList>
</j-modal>
</template>
<script lang="ts" setup>
import { ref, nextTick, defineExpose } from 'vue';
import LwKhclCjList from './LwKhclCjList.vue'
import JModal from '/@/components/Modal/src/JModal/JModal.vue';
const title = ref<string>('');
const width = ref<number>(1600);
const visible = ref<boolean>(false);
const disableSubmit = ref<boolean>(false);
const registerForm = ref();
const emit = defineEmits(['register', 'success']);
/**
* 编辑
* @param record
*/
function init(record) {
title.value = '论文考核材料详情';
visible.value = true;
nextTick(() => {
registerForm.value.init(record);
});
}
/**
* 取消按钮回调事件
*/
function handleCancel() {
visible.value = false;
}
defineExpose({
init,
disableSubmit,
});
</script>
<style lang="less">
/**隐藏样式-modal确定按钮 */
.jee-hidden {
display: none !important;
}
</style>
<style lang="less" scoped></style>

View File

@ -0,0 +1,299 @@
<template>
<div class="p-2">
<!--查询区域-->
<div class="jeecg-basic-table-form-container">
<a-form ref="formRef" @keyup.enter.native="searchQuery" :model="queryParam" :label-col="labelCol" :wrapper-col="wrapperCol">
<a-row :gutter="24">
<a-col :lg="6">
<a-form-item name="ssxnzymc">
<template #label><span title="专业">专业</span></template>
<a-input placeholder="请输入专业" v-model:value="queryParam.ssxnzymc" allow-clear ></a-input>
</a-form-item>
</a-col>
<a-col :lg="6">
<a-form-item name="xsxm">
<template #label><span title="学生姓名">学生姓名</span></template>
<a-input placeholder="请输入学生姓名" v-model:value="queryParam.xsxm" allow-clear ></a-input>
</a-form-item>
</a-col>
<a-col :lg="6">
<a-form-item name="ktbg">
<template #label><span title="开题报告">开题报告</span></template>
<!-- <a-input placeholder="请选择开题报告" v-model:value="queryParam.ktbg" allow-clear ></a-input>-->
<a-select placeholder="请选择开题报告" v-model:value="queryParam.ktbg">
<a-select-option value="">全部</a-select-option>
<a-select-option :value="1"></a-select-option>
<a-select-option :value="0"></a-select-option>
</a-select>
</a-form-item>
</a-col>
<a-col :lg="6">
<a-form-item name="zqjc">
<template #label><span title="中期检查">中期检查</span></template>
<!-- <a-input placeholder="请选择中期检查" v-model:value="queryParam.zqjc" allow-clear ></a-input>-->
<a-select placeholder="请选择中期检查" v-model:value="queryParam.zqjc">
<a-select-option value="">全部</a-select-option>
<a-select-option :value="1"></a-select-option>
<a-select-option :value="0"></a-select-option>
</a-select>
</a-form-item>
</a-col>
<a-col :lg="6">
<a-form-item name="lwzg">
<template #label><span title="论文终稿">论文终稿</span></template>
<!-- <a-input placeholder="请选择论文终稿" v-model:value="queryParam.lwzg" allow-clear ></a-input>-->
<a-select placeholder="请选择论文终稿" v-model:value="queryParam.lwzg">
<a-select-option value="">全部</a-select-option>
<a-select-option :value="1"></a-select-option>
<a-select-option :value="0"></a-select-option>
</a-select>
</a-form-item>
</a-col>
<a-col :xl="6" :lg="7" :md="8" :sm="24">
<span style="float: left; overflow: hidden" class="table-page-search-submitButtons">
<a-col :lg="6">
<a-button type="primary" preIcon="ant-design:search-outlined" @click="searchQuery">查询</a-button>
<a-button type="primary" preIcon="ant-design:reload-outlined" @click="searchReset" style="margin-left: 8px">重置</a-button>
<a-button type="primary" preIcon="ant-design:export-outlined" @click="onExportXls" style="margin-left: 8px"> 导出</a-button>
</a-col>
</span>
</a-col>
</a-row>
</a-form>
</div>
<!--引用表格-->
<BasicTable @register="registerTable" :rowSelection="rowSelection">
<!--插槽:table标题-->
<template #tableTitle>
</template>
<!--操作栏-->
<template #action="{ record }">
</template>
<template v-slot:bodyCell="{ column, record, index, text }">
</template>
<!-- 自定义插槽 -->
<template #ktbg_yl="{record}">
<a-button v-if="record.ktbg!=null&&record.ktbg!=''" size="large" preIcon="ant-design:eye-outlined" style="border: 0px;" @click="openWindow(record.ktbg)"></a-button>
</template>
<template #ktbg_xz="{record}">
<a-button v-if="record.ktbg!=null&&record.ktbg!=''" size="large" preIcon="ant-design:download-outlined" style="border: 0px;" @click="openWindowWithLoading(record.ktbg)"></a-button>
</template>
<template #ktbgshyj_yl="{record}">
<a-button v-if="record.ktbgshyj!=null&&record.ktbgshyj!=''" size="large" preIcon="ant-design:eye-outlined" style="border: 0px;" @click="openWindow(record.ktbgshyj)"></a-button>
</template>
<template #ktbgshyj_xz="{record}">
<a-button v-if="record.ktbgshyj!=null&&record.ktbgshyj!=''" size="large" preIcon="ant-design:download-outlined" style="border: 0px;" @click="openWindowWithLoading(record.ktbgshyj)"></a-button>
</template>
<template #zqjc_yl="{record}">
<a-button v-if="record.zqjc!=null&&record.zqjc!=''" size="large" preIcon="ant-design:eye-outlined" style="border: 0px;" @click="openWindow(record.zqjc)"></a-button>
</template>
<template #zqjc_xz="{record}">
<a-button v-if="record.zqjc!=null&&record.zqjc!=''" size="large" preIcon="ant-design:download-outlined" style="border: 0px;" @click="openWindowWithLoading(record.zqjc)"></a-button>
</template>
<template #lwzg_yl="{record}">
<a-button v-if="record.lwzg!=null&&record.lwzg!=''" size="large" preIcon="ant-design:eye-outlined" style="border: 0px;" @click="openWindow(record.lwzg)"></a-button>
</template>
<template #lwzg_xz="{record}">
<a-button v-if="record.lwzg!=null&&record.lwzg!=''" size="large" preIcon="ant-design:download-outlined" style="border: 0px;" @click="openWindowWithLoading(record.lwzg)"></a-button>
</template>
<template #jcbgdcl_yl="{record}">
<a-button v-if="record.jcbgdcl!=null&&record.jcbgdcl!=''" size="large" preIcon="ant-design:eye-outlined" style="border: 0px;" @click="openWindow(record.jcbgdcl)"></a-button>
</template>
<template #jcbgdcl_xz="{record}">
<a-button v-if="record.jcbgdcl!=null&&record.jcbgdcl!=''" size="large" preIcon="ant-design:download-outlined" style="border: 0px;" @click="openWindowWithLoading(record.jcbgdcl)"></a-button>
</template>
</BasicTable>
</div>
</template>
<script lang="ts" name="lwKhcl-lwKhcl" setup>
import {ref, reactive, defineProps, nextTick, defineExpose} from 'vue';
import { BasicTable, useTable, TableAction } from '/@/components/Table';
import { useListPage } from '/@/hooks/system/useListPage';
import { columnsXq } from './../LwKhcl.data';
import { xqList, getXqExportUrl } from './../LwKhcl.api';
import { downloadFile } from '/@/utils/common/renderUtils';
import { useUserStore } from '/@/store/modules/user';
import JDictSelectTag from '/@/components/Form/src/jeecg/components/JDictSelectTag.vue';
import { useMessage } from '/@/hooks/web/useMessage';
const spinning = ref<boolean>(false);
const { createMessage, createConfirm } = useMessage();
const props = defineProps({
formDisabled: { type: Boolean, default: false },
formData: { type: Object, default: () => ({})},
formBpm: { type: Boolean, default: true }
});
const formRef = ref();
const queryParam = reactive<any>({
xsxh: '',
});
const toggleSearchStatus = ref<boolean>(false);
const registerModal = ref();
const userStore = useUserStore();
//table
const { prefixCls, tableContext, onExportXls } = useListPage({
tableProps: {
title: 'lw_khcl',
api: xqList,
columns: columnsXq,
canResize:false,
useSearchForm: false,
actionColumn: {
width: 120,
fixed: 'right',
},
showActionColumn: false,
beforeFetch: async (params) => {
return Object.assign(params, queryParam);
},
},
exportConfig: {
name: "论文考核材料成绩",
url: getXqExportUrl,
params: queryParam,
}
});
const [registerTable, { reload, collapseAll, updateTableDataRecord, findTableDataRecord, getDataSource }, { rowSelection, selectedRowKeys }] = tableContext;
const labelCol = reactive({
xs:24,
sm:4,
xl:6,
xxl:4
});
const wrapperCol = reactive({
xs: 24,
sm: 20,
});
/**
* 详情
*/
function handleDetail(record: Recordable) {
registerModal.value.disableSubmit = true;
registerModal.value.edit(record);
}
/**
* 成功回调
*/
function handleSuccess() {
(selectedRowKeys.value = []) && reload();
}
/**
* 操作栏
*/
function getTableAction(record) {
return [
{
label: '详情',
onClick: handleDetail.bind(null, record),
},
];
}
/**
* 查询
*/
function searchQuery() {
reload();
}
/**
* 重置
*/
function searchReset() {
formRef.value.resetFields();
selectedRowKeys.value = [];
//
reload();
}
function openWindow(url){
console.log(url);
if(url!=null && url!=''){
window.open(url,"_blank");
}
}
/**
* 自定义下载事件带加载中
*/
function openWindowWithLoading(url){
if(url==null || url==''){
return;
}
let xhr = new XMLHttpRequest();
spinning.value = true;
xhr.open('GET',url,true);
// xhr.onprogress = function (e){
// let percent = Math.floor(e.loaded / e.total * 100);//
// console.log(percent);
// }
xhr.send();
xhr.responseType = "arraybuffer";
xhr.onreadystatechange = event =>{
console.log(xhr);
if(xhr.readyState == 4){
if(xhr.status == 200){
let fileName = url.substring(url.lastIndexOf("/")+1);
let blob = new Blob([xhr.response]);
const downLoadLink = document.createElement('a');
downLoadLink.download = fileName;
downLoadLink.href = URL.createObjectURL(blob);
downLoadLink.click();
}else if (xhr.status == 404){
createMessage.warning('没有找到可下载的资源!');
}
}
spinning.value = false;
}
}
function init(record) {
nextTick(() => {
const tmpData = {};
Object.keys(queryParam).forEach((key) => {
if(record.hasOwnProperty(key)){
tmpData[key] = record[key]
}
})
//
Object.assign(queryParam, tmpData);
reload();
});
}
defineExpose({
init
});
</script>
<style lang="less" scoped>
.jeecg-basic-table-form-container {
padding: 0;
.table-page-search-submitButtons {
display: block;
margin-bottom: 24px;
white-space: nowrap;
}
.query-group-cust{
min-width: 100px !important;
}
.query-group-split-cust{
width: 30px;
display: inline-block;
text-align: center
}
.ant-form-item:not(.ant-form-item-with-help){
margin-bottom: 16px;
height: 32px;
}
:deep(.ant-picker),:deep(.ant-input-number){
width: 100%;
}
}
</style>

View File

@ -0,0 +1,50 @@
<template>
<j-modal :title="title" :width="width" :visible="visible" :okButtonProps="{ class: { 'jee-hidden': disableSubmit } }" @cancel="handleCancel" cancelText="关闭">
<LwKhclXqList ref="registerForm" :formDisabled="disableSubmit" :formBpm="false"></LwKhclXqList>
</j-modal>
</template>
<script lang="ts" setup>
import { ref, nextTick, defineExpose } from 'vue';
import LwKhclXqList from './LwKhclXqList.vue'
import JModal from '/@/components/Modal/src/JModal/JModal.vue';
const title = ref<string>('');
const width = ref<number>(1600);
const visible = ref<boolean>(false);
const disableSubmit = ref<boolean>(false);
const registerForm = ref();
const emit = defineEmits(['register', 'success']);
/**
* 编辑
* @param record
*/
function init(record) {
title.value = '论文考核材料详情';
visible.value = true;
nextTick(() => {
registerForm.value.init(record);
});
}
/**
* 取消按钮回调事件
*/
function handleCancel() {
visible.value = false;
}
defineExpose({
init,
disableSubmit,
});
</script>
<style lang="less">
/**隐藏样式-modal确定按钮 */
.jee-hidden {
display: none !important;
}
</style>
<style lang="less" scoped></style>

View File

@ -0,0 +1,174 @@
<template>
<div class="p-2">
<!--查询区域-->
<div class="jeecg-basic-table-form-container">
<a-form ref="formRef" @keyup.enter.native="searchQuery" :model="queryParam" :label-col="labelCol" :wrapper-col="wrapperCol">
<a-row :gutter="24">
<a-col :lg="4">
<a-form-item name="bynf">
<template #label><span title="界别">界别</span></template>
<a-input placeholder="请输入界别" v-model:value="queryParam.bynf" allow-clear ></a-input>
</a-form-item>
</a-col>
<a-col :lg="4">
<a-form-item name="ssyxmc">
<template #label><span title="学院">学院</span></template>
<a-input placeholder="请输入学院" v-model:value="queryParam.ssyxmc" allow-clear ></a-input>
</a-form-item>
</a-col>
<a-col :lg="4">
<a-form-item name="ssxnzymc">
<template #label><span title="专业">专业</span></template>
<a-input placeholder="请输入专业" v-model:value="queryParam.ssxnzymc" allow-clear ></a-input>
</a-form-item>
</a-col>
<a-col :xl="6" :lg="7" :md="8" :sm="24">
<span style="float: left; overflow: hidden" class="table-page-search-submitButtons">
<a-col :lg="6">
<a-button type="primary" preIcon="ant-design:search-outlined" @click="searchQuery">查询</a-button>
<a-button type="primary" preIcon="ant-design:reload-outlined" @click="searchReset" style="margin-left: 8px">重置</a-button>
<a-button type="primary" preIcon="ant-design:export-outlined" @click="onExportXls" style="margin-left: 8px"> 导出</a-button>
</a-col>
</span>
</a-col>
</a-row>
</a-form>
</div>
<!--引用表格-->
<BasicTable @register="registerTable" :rowSelection="rowSelection">
<!--插槽:table标题-->
<template #tableTitle>
</template>
<!--操作栏-->
<template #action="{ record }">
<TableAction :actions="getTableAction(record)"/>
</template>
<template v-slot:bodyCell="{ column, record, index, text }">
</template>
</BasicTable>
<!-- 表单区域 -->
<LwKhclCjModal ref="registerModal"></LwKhclCjModal>
</div>
</template>
<script lang="ts" name="lwKhcl-lwKhcl" setup>
import { ref, reactive } from 'vue';
import { BasicTable, useTable, TableAction } from '/@/components/Table';
import { useListPage } from '/@/hooks/system/useListPage';
import { columns } from './LwKhcl.data';
import { list, getExportUrl } from './LwKhcl.api';
import { downloadFile } from '/@/utils/common/renderUtils';
import LwKhclCjModal from './components/LwKhclCjModal.vue'
import { useUserStore } from '/@/store/modules/user';
import JDictSelectTag from '/@/components/Form/src/jeecg/components/JDictSelectTag.vue';
const formRef = ref();
const queryParam = reactive<any>({});
const toggleSearchStatus = ref<boolean>(false);
const registerModal = ref();
const userStore = useUserStore();
//table
const { prefixCls, tableContext, onExportXls, onImportXls } = useListPage({
tableProps: {
title: 'lw_khcl',
api: list,
columns,
canResize:false,
useSearchForm: false,
actionColumn: {
width: 120,
fixed: 'right',
},
beforeFetch: async (params) => {
return Object.assign(params, queryParam);
},
},
exportConfig: {
name: "论文考核材料",
url: getExportUrl,
params: queryParam,
},
});
const [registerTable, { reload, collapseAll, updateTableDataRecord, findTableDataRecord, getDataSource }, { rowSelection, selectedRowKeys }] = tableContext;
const labelCol = reactive({
xs:24,
sm:4,
xl:6,
xxl:4
});
const wrapperCol = reactive({
xs: 24,
sm: 20,
});
/**
* 详情
*/
function handleDetail(record: Recordable) {
registerModal.value.disableSubmit = true;
registerModal.value.init(record);
}
/**
* 成功回调
*/
function handleSuccess() {
(selectedRowKeys.value = []) && reload();
}
/**
* 操作栏
*/
function getTableAction(record) {
return [
{
label: '查看',
onClick: handleDetail.bind(null, record),
}
];
}
/**
* 查询
*/
function searchQuery() {
reload();
}
/**
* 重置
*/
function searchReset() {
formRef.value.resetFields();
selectedRowKeys.value = [];
//
reload();
}
</script>
<style lang="less" scoped>
.jeecg-basic-table-form-container {
padding: 0;
.table-page-search-submitButtons {
display: block;
margin-bottom: 24px;
white-space: nowrap;
}
.query-group-cust{
min-width: 100px !important;
}
.query-group-split-cust{
width: 30px;
display: inline-block;
text-align: center
}
.ant-form-item:not(.ant-form-item-with-help){
margin-bottom: 16px;
height: 32px;
}
:deep(.ant-picker),:deep(.ant-input-number){
width: 100%;
}
}
</style>