协会
This commit is contained in:
@@ -724,6 +724,26 @@
|
|||||||
</exclusion>
|
</exclusion>
|
||||||
</exclusions>
|
</exclusions>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
|
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.luhuiguo</groupId>
|
||||||
|
<artifactId>aspose-words</artifactId>
|
||||||
|
<version>23.1</version>
|
||||||
|
</dependency>
|
||||||
|
<!--xlsx或xls转pdf-->
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.luhuiguo</groupId>
|
||||||
|
<artifactId>aspose-cells</artifactId>
|
||||||
|
<version>23.1</version>
|
||||||
|
</dependency>
|
||||||
|
<!--ppt转pdf-->
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.luhuiguo</groupId>
|
||||||
|
<artifactId>aspose-slides</artifactId>
|
||||||
|
<version>23.1</version>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
</dependencies>
|
</dependencies>
|
||||||
<dependencyManagement>
|
<dependencyManagement>
|
||||||
<dependencies>
|
<dependencies>
|
||||||
|
|||||||
@@ -0,0 +1,98 @@
|
|||||||
|
package io.v.nutz.base.utils;
|
||||||
|
|
||||||
|
import cn.hutool.core.io.FileUtil;
|
||||||
|
import com.aspose.cells.PdfSaveOptions;
|
||||||
|
import com.aspose.cells.Workbook;
|
||||||
|
import com.aspose.words.Document;
|
||||||
|
import com.aspose.words.SaveFormat;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
|
||||||
|
import java.io.File;
|
||||||
|
import java.io.FileOutputStream;
|
||||||
|
import java.io.IOException;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 文档转换
|
||||||
|
*/
|
||||||
|
@Slf4j
|
||||||
|
public class OfficePlusUtil {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 转换
|
||||||
|
*
|
||||||
|
* @param sourcePath 源文件路径
|
||||||
|
* @param targetPath 目标文件路径
|
||||||
|
*/
|
||||||
|
public static void convert(String sourcePath, String targetPath) {
|
||||||
|
String suffix = FileUtil.getSuffix(sourcePath);
|
||||||
|
if (suffix.equals("doc") || suffix.equals("docx")) {
|
||||||
|
wordConvertPdf(sourcePath, targetPath);
|
||||||
|
} else if (suffix.equals("xls") || suffix.equals("xlsx")) {
|
||||||
|
excelConvertPdf(sourcePath, targetPath);
|
||||||
|
} else {
|
||||||
|
throw new RuntimeException("不支持的文档格式");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* excel转pdf
|
||||||
|
*
|
||||||
|
* @param sourcePath 源文件路径
|
||||||
|
* @param targetPath 目标文件路径
|
||||||
|
*/
|
||||||
|
public static void excelConvertPdf(String sourcePath, String targetPath) {
|
||||||
|
FileOutputStream fileOS = null;
|
||||||
|
try {
|
||||||
|
Workbook wb = new Workbook(sourcePath);
|
||||||
|
fileOS = new FileOutputStream(targetPath);
|
||||||
|
PdfSaveOptions pdfSaveOptions = new PdfSaveOptions();
|
||||||
|
pdfSaveOptions.setOnePagePerSheet(true);
|
||||||
|
// for (int i = 0; i < 3; i++) {
|
||||||
|
// wb.getWorksheets().get(i).getHorizontalPageBreaks().clear();
|
||||||
|
// wb.getWorksheets().get(i).getVerticalPageBreaks().clear();
|
||||||
|
// }
|
||||||
|
// for (int i = 1; i < wb.getWorksheets().getCount(); i++) {
|
||||||
|
// wb.getWorksheets().get(i).setVisible(false);
|
||||||
|
// }
|
||||||
|
wb.getWorksheets().get(0).setVisible(true);
|
||||||
|
wb.save(fileOS, pdfSaveOptions);
|
||||||
|
fileOS.flush();
|
||||||
|
} catch (Exception e) {
|
||||||
|
log.info("转换pdf报错", e);
|
||||||
|
} finally {
|
||||||
|
if (fileOS != null) {
|
||||||
|
try {
|
||||||
|
fileOS.close();
|
||||||
|
} catch (IOException e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* word转pdf
|
||||||
|
*
|
||||||
|
* @param sourcePath 源文件路径
|
||||||
|
* @param targetPath 目标文件路径
|
||||||
|
*/
|
||||||
|
public static void wordConvertPdf(String sourcePath, String targetPath) {
|
||||||
|
FileOutputStream os = null;
|
||||||
|
try {
|
||||||
|
File file = new File(targetPath);
|
||||||
|
os = new FileOutputStream(file);
|
||||||
|
Document doc = new Document(sourcePath);
|
||||||
|
doc.save(os, SaveFormat.PDF);
|
||||||
|
} catch (Exception e) {
|
||||||
|
log.info("转换pdf报错", e);
|
||||||
|
} finally {
|
||||||
|
try {
|
||||||
|
os.close();
|
||||||
|
} catch (IOException e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -2,8 +2,10 @@ package io.v.nutz.sys.controllers.platform.sys;
|
|||||||
|
|
||||||
import io.v.nutz.base.annontation.ViReturn;
|
import io.v.nutz.base.annontation.ViReturn;
|
||||||
import io.v.nutz.base.query.PageForm;
|
import io.v.nutz.base.query.PageForm;
|
||||||
|
import io.v.nutz.sys.services.SysFileService;
|
||||||
import io.v.nutz.sys.services.SysUserService;
|
import io.v.nutz.sys.services.SysUserService;
|
||||||
import lombok.extern.slf4j.Slf4j;
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.apache.shiro.authz.annotation.RequiresAuthentication;
|
||||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||||
import org.nutz.dao.Cnd;
|
import org.nutz.dao.Cnd;
|
||||||
import org.nutz.dao.Sqls;
|
import org.nutz.dao.Sqls;
|
||||||
@@ -13,6 +15,10 @@ import org.nutz.ioc.loader.annotation.IocBean;
|
|||||||
import org.nutz.mvc.annotation.At;
|
import org.nutz.mvc.annotation.At;
|
||||||
import org.nutz.mvc.annotation.Ok;
|
import org.nutz.mvc.annotation.Ok;
|
||||||
|
|
||||||
|
import javax.servlet.http.HttpServletRequest;
|
||||||
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
import java.io.IOException;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 文件管理
|
* 文件管理
|
||||||
*
|
*
|
||||||
@@ -26,6 +32,8 @@ public class SysFileController {
|
|||||||
|
|
||||||
@Inject
|
@Inject
|
||||||
private SysUserService sysUserService;
|
private SysUserService sysUserService;
|
||||||
|
@Inject
|
||||||
|
private SysFileService sysFileService;
|
||||||
|
|
||||||
@At("")
|
@At("")
|
||||||
@Ok("beetl:/platform/sys/file/index.html")
|
@Ok("beetl:/platform/sys/file/index.html")
|
||||||
@@ -51,4 +59,11 @@ public class SysFileController {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@At
|
||||||
|
@Ok("void")
|
||||||
|
@ViReturn
|
||||||
|
@RequiresAuthentication
|
||||||
|
public void convertPDF(String id, HttpServletRequest request, HttpServletResponse response) throws IOException {
|
||||||
|
sysFileService.convertPDF(id, request, response);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -0,0 +1,22 @@
|
|||||||
|
package io.v.nutz.sys.services;
|
||||||
|
|
||||||
|
import cn.wizzer.framework.base.service.BaseService;
|
||||||
|
import io.v.nutz.sys.models.Sys_file;
|
||||||
|
|
||||||
|
import javax.servlet.http.HttpServletRequest;
|
||||||
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
import java.io.IOException;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @version 1.0
|
||||||
|
* @Author zzr
|
||||||
|
* @name:SysFileService
|
||||||
|
* @Date 2024/12/17 11:40
|
||||||
|
* @注释
|
||||||
|
*/
|
||||||
|
public interface SysFileService extends BaseService<Sys_file> {
|
||||||
|
/**
|
||||||
|
* 转换为PDF
|
||||||
|
*/
|
||||||
|
void convertPDF(String id, HttpServletRequest request, HttpServletResponse response);
|
||||||
|
}
|
||||||
@@ -0,0 +1,93 @@
|
|||||||
|
package io.v.nutz.sys.services.impl;
|
||||||
|
|
||||||
|
import cn.hutool.core.io.FileUtil;
|
||||||
|
import cn.hutool.core.io.IoUtil;
|
||||||
|
import cn.hutool.core.util.CharsetUtil;
|
||||||
|
import cn.hutool.core.util.ObjectUtil;
|
||||||
|
import cn.hutool.core.util.URLUtil;
|
||||||
|
import cn.hutool.http.ContentType;
|
||||||
|
import cn.wizzer.framework.base.Result;
|
||||||
|
import cn.wizzer.framework.base.service.BaseServiceImpl;
|
||||||
|
import io.v.nutz.base.utils.OfficePlusUtil;
|
||||||
|
import io.v.nutz.sys.models.Sys_file;
|
||||||
|
import io.v.nutz.sys.services.SysFileService;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.nutz.boot.starter.ftp.FtpService;
|
||||||
|
import org.nutz.dao.Cnd;
|
||||||
|
import org.nutz.dao.Dao;
|
||||||
|
import org.nutz.dao.util.cri.SqlExpressionGroup;
|
||||||
|
import org.nutz.ioc.loader.annotation.Inject;
|
||||||
|
import org.nutz.ioc.loader.annotation.IocBean;
|
||||||
|
import org.nutz.json.Json;
|
||||||
|
|
||||||
|
import javax.servlet.http.HttpServletRequest;
|
||||||
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
import java.io.File;
|
||||||
|
import java.io.FileOutputStream;
|
||||||
|
import java.io.IOException;
|
||||||
|
import java.nio.file.Files;
|
||||||
|
import java.nio.file.Path;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @version 1.0
|
||||||
|
* @Author zzr
|
||||||
|
* @name:SysFileServiceImpl
|
||||||
|
* @Date 2024/12/17 11:40
|
||||||
|
* @注释
|
||||||
|
*/
|
||||||
|
@Slf4j
|
||||||
|
@IocBean(args = {"refer:dao"})
|
||||||
|
public class SysFileServiceImpl extends BaseServiceImpl<Sys_file> implements SysFileService {
|
||||||
|
|
||||||
|
@Inject
|
||||||
|
private FtpService ftpService;
|
||||||
|
|
||||||
|
public SysFileServiceImpl(Dao dao) {
|
||||||
|
super(dao);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void convertPDF(String id, HttpServletRequest request, HttpServletResponse response) {
|
||||||
|
try {
|
||||||
|
SqlExpressionGroup seg = new SqlExpressionGroup();
|
||||||
|
seg.or("id", "=", id);
|
||||||
|
seg.or("filepath", "=", id);
|
||||||
|
Sys_file sys_file = dao().fetch(Sys_file.class, Cnd.where(seg).desc("id"));
|
||||||
|
if (ObjectUtil.isEmpty(sys_file)) {
|
||||||
|
sendErrorResponse(response, "文件记录不存在");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
//文件扩展名
|
||||||
|
String extName = FileUtil.extName(sys_file.getFilename());
|
||||||
|
File localSourcePath = File.createTempFile("file_convert", "." + extName);
|
||||||
|
FileOutputStream localOutPutStream = new FileOutputStream(localSourcePath.getPath());
|
||||||
|
ftpService.download(sys_file.getFilepath(), localOutPutStream);
|
||||||
|
|
||||||
|
//要转换的pdf本地临时路径
|
||||||
|
File localPdfPath = File.createTempFile("file_convert", ".pdf");
|
||||||
|
OfficePlusUtil.convert(localSourcePath.getPath(), localPdfPath.getPath());
|
||||||
|
|
||||||
|
byte[] bytes = IoUtil.readBytes(FileUtil.getInputStream(localPdfPath));
|
||||||
|
response.setHeader("Content-Disposition", "attachment;filename=" + URLUtil.encode(sys_file.getFilename()));
|
||||||
|
response.addHeader("Content-Length", "" + bytes.length);
|
||||||
|
response.setHeader("Access-Control-Allow-Origin", "*");
|
||||||
|
response.setHeader("Access-Control-Expose-Headers", "Content-Disposition");
|
||||||
|
response.setContentType("application/octet-stream;charset=UTF-8");
|
||||||
|
IoUtil.write(response.getOutputStream(), true, bytes);
|
||||||
|
//删除临时文件
|
||||||
|
FileUtil.del(localPdfPath);
|
||||||
|
FileUtil.del(localSourcePath);
|
||||||
|
|
||||||
|
} catch (Exception e) {
|
||||||
|
log.error("文件转换异常", e);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
private void sendErrorResponse(HttpServletResponse response, String message) throws IOException {
|
||||||
|
response.setCharacterEncoding(CharsetUtil.UTF_8);
|
||||||
|
response.setContentType(ContentType.JSON.toString());
|
||||||
|
response.getWriter().write(Json.toJson(Result.error(message)));
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -63,8 +63,12 @@ const preview = async (filename, id) => {
|
|||||||
let viewer = new Viewer(image);
|
let viewer = new Viewer(image);
|
||||||
viewer.show();
|
viewer.show();
|
||||||
} else {
|
} else {
|
||||||
let pdfStreamUrl = encodeURIComponent(FILE_STREAM_PREVIEW_ADDRESS + '?id=' + id) //将路径转码
|
// let pdfStreamUrl = encodeURIComponent(FILE_STREAM_PREVIEW_ADDRESS + '?id=' + id) //将路径转码
|
||||||
window.open('/assets/platform/plugins/pdfJs/web/viewer.html?file=' + pdfStreamUrl, filename)
|
// window.open('/assets/platform/plugins/pdfJs/web/viewer.html?file=' + pdfStreamUrl, filename)
|
||||||
|
window.open(
|
||||||
|
"/assets/platform/plugins/pdfJs/web/viewer.html?file=" + encodeURIComponent("/platform/sys/file/convertPDF?id=" + id),
|
||||||
|
filename
|
||||||
|
)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -14,8 +14,12 @@ const preview = async (filename, id) => {
|
|||||||
let viewer = new Viewer(image);
|
let viewer = new Viewer(image);
|
||||||
viewer.show();
|
viewer.show();
|
||||||
} else {
|
} else {
|
||||||
let pdfStreamUrl = encodeURIComponent(FILE_STREAM_PREVIEW_ADDRESS + '?id=' + id) //将路径转码
|
// let pdfStreamUrl = encodeURIComponent(FILE_STREAM_PREVIEW_ADDRESS + '?id=' + id) //将路径转码
|
||||||
window.open('/assets/platform/plugins/pdfJs/web/viewer.html?file=' + pdfStreamUrl, filename)
|
// window.open('/assets/platform/plugins/pdfJs/web/viewer.html?file=' + pdfStreamUrl, filename)
|
||||||
|
window.open(
|
||||||
|
"/assets/platform/plugins/pdfJs/web/viewer.html?file=" + encodeURIComponent("/platform/sys/file/convertPDF?id=" + id),
|
||||||
|
filename
|
||||||
|
)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,674 @@
|
|||||||
|
<!--#
|
||||||
|
layout("/layouts/platform.html"){
|
||||||
|
#-->
|
||||||
|
|
||||||
|
<style>
|
||||||
|
|
||||||
|
.el-collapse-item__header {
|
||||||
|
padding: 35px;
|
||||||
|
display: -webkit-box;
|
||||||
|
display: -ms-flexbox;
|
||||||
|
display: flex;
|
||||||
|
-webkit-box-align: center;
|
||||||
|
-ms-flex-align: center;
|
||||||
|
align-items: center;
|
||||||
|
height: 80px;
|
||||||
|
line-height: 50px;
|
||||||
|
background-color: #fff;
|
||||||
|
color: #3ea1ec;
|
||||||
|
cursor: pointer;
|
||||||
|
border-bottom: 1px solid #ebeef5;
|
||||||
|
font-size: 15px;
|
||||||
|
font-weight: 500;
|
||||||
|
-webkit-transition: border-bottom-color .3s;
|
||||||
|
transition: border-bottom-color .3s;
|
||||||
|
outline: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
</style>
|
||||||
|
|
||||||
|
<div id="app" v-cloak>
|
||||||
|
<guava>
|
||||||
|
<template>
|
||||||
|
<el-card shadow="never">
|
||||||
|
|
||||||
|
<div slot="header" class="clearfix">
|
||||||
|
<span style="color: #409EFF;font-size: 18px"><h3>活动报销</h3></span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<el-form :model="formData" ref="form" :rules="formRules" label-width="120px">
|
||||||
|
|
||||||
|
<el-row :gutter="20">
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item prop="id" label="活动名称">
|
||||||
|
<el-select v-model="formData.id"
|
||||||
|
style="width: 100%;"
|
||||||
|
@change="activityChange(formData.id)"
|
||||||
|
filterable placeholder="请选择活动">
|
||||||
|
<el-option
|
||||||
|
v-for="item in activityOptions"
|
||||||
|
:key="item.id"
|
||||||
|
:label="item.activity_name"
|
||||||
|
:value="item.id">
|
||||||
|
</el-option>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="12">
|
||||||
|
<div style="margin-top: 10px">
|
||||||
|
<span style="color: red">选择活动后自动填充活动基本信息,选择右侧小箭头可展开或折叠</span>
|
||||||
|
</div>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
|
||||||
|
<el-row :gutter="20" v-if="formData.id != null && formData.id !== ''">
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item prop="id" label="实际参与人数">
|
||||||
|
<el-input-number v-model="formData.activity_number"
|
||||||
|
style="width: 100%"
|
||||||
|
placeholder="请输入实际参与人数"></el-input-number>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
|
||||||
|
<el-col :span="12">
|
||||||
|
<div style="padding: 4px 0 20px 0">
|
||||||
|
<el-button type="primary" size="small" @click="doExportActivityApply">
|
||||||
|
导出活动申请方案表
|
||||||
|
</el-button>
|
||||||
|
<el-button type="primary" size="small" style="margin-left: 10px"
|
||||||
|
@click="doExportReimbursementVoucher">导出报销凭证
|
||||||
|
</el-button>
|
||||||
|
<el-button type="primary" size="small" style="margin-left: 10px"
|
||||||
|
@click="doExportActivitySignUpUser">导出活动参加人员
|
||||||
|
</el-button>
|
||||||
|
</div>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
<el-collapse v-model="activeNames">
|
||||||
|
<el-collapse-item title="活动基本信息" name="1">
|
||||||
|
<el-row :gutter="20">
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item prop="user_name" label="申请人姓名">
|
||||||
|
<el-input readonly v-model="formData.user_name" type="text"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item prop="apply_time" label="申请时间">
|
||||||
|
<el-input readonly v-model="formData.apply_time" type="text"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item prop="mobile" label="联系方式">
|
||||||
|
<el-input readonly v-model="formData.mobile" type="text"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item prop="activity_type" label="活动主体类型">
|
||||||
|
{{ formData.activity_type == 40002 ? "分工会活动" : formData.activity_type ==
|
||||||
|
40003 ? "协会活动"
|
||||||
|
: "校工会活动"}}
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item prop="projectCode" label="项目编号">
|
||||||
|
<el-input readonly v-model="formData.projectCode"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item prop="fundsUnitName" label="申请(承办)单位"
|
||||||
|
v-if="formData.activity_type!=40003">
|
||||||
|
<el-input readonly v-model="formData.fundsUnitName" type="text"></el-input>
|
||||||
|
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item prop="clubId" label="申请协会"
|
||||||
|
v-else-if="formData.activity_type==40003">
|
||||||
|
<el-select placeholder="请选择申请协会"
|
||||||
|
disabled
|
||||||
|
style="width: 100%;" v-model="formData.clubId">
|
||||||
|
<el-option
|
||||||
|
:key="item.id"
|
||||||
|
:label="item.name+' ('+item.code+')'"
|
||||||
|
:value="item.id"
|
||||||
|
v-for="item in fundsUnitNameOption">
|
||||||
|
</el-option>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item label="活动计划时间" prop="plannedDate">
|
||||||
|
<el-date-picker
|
||||||
|
end-placeholder="结束日期"
|
||||||
|
range-separator="-"
|
||||||
|
start-placeholder="开始日期"
|
||||||
|
style="width: 100%"
|
||||||
|
disabled
|
||||||
|
type="daterange"
|
||||||
|
v-model="formData.plannedDate"
|
||||||
|
value-format="yyyy-MM-dd">
|
||||||
|
</el-date-picker>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
|
||||||
|
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item prop="address" label="活动地点">
|
||||||
|
<el-input v-model="formData.address" readonly type="text"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item prop="funds_money" label="预算总费用">
|
||||||
|
<el-input-number style="width: 100%" disabled v-model="formData.funds_money"
|
||||||
|
:precision="2"></el-input-number>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
|
||||||
|
<!--<el-col :span="12">
|
||||||
|
<el-form-item prop="payee_username" label="收款人">
|
||||||
|
<el-input v-model="formData.payee_username" readonly></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item label="支行名称" prop="activity_card_name">
|
||||||
|
<el-input readonly v-model="formData.activity_card_name"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item prop="activity_card_number" label="报销卡号">
|
||||||
|
<el-input readonly v-model="formData.activity_card_number"
|
||||||
|
type="number"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>-->
|
||||||
|
</el-row>
|
||||||
|
<!--<el-table :data="formData.goods" border size="mini" style="width: 100%">
|
||||||
|
|
||||||
|
<el-table-column sortable type="index" width="100" label="序号"
|
||||||
|
align="center" header-align="center">
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column prop="name" readonly label="物品名称" align="center"
|
||||||
|
header-align="center">
|
||||||
|
<template slot-scope="{row}">
|
||||||
|
<el-input maxlength="50" readonly placeholder="费用项目名称" v-model="row.name"
|
||||||
|
type="text"></el-input>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column prop="budgets" label="预算费用" align="center"
|
||||||
|
header-align="center">
|
||||||
|
<template slot-scope="{row}">
|
||||||
|
<el-input maxlength="50" readonly placeholder="预算费用" v-model="row.budgets"
|
||||||
|
type="number" @input="blur"></el-input>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
</el-table>-->
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
|
<el-divider content-position="left" class="dia"><span
|
||||||
|
style="color: #3ea1ec;">活动内容</span>
|
||||||
|
</el-divider>
|
||||||
|
<el-form-item prop="activity_content" class="is-required">
|
||||||
|
<text-editor v-model="formData.activity_content"></text-editor>
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
|
<el-divider content-position="left" class="dia"><span style="color: #3ea1ec;">附件</span>
|
||||||
|
</el-divider>
|
||||||
|
<el-row :gutter="40">
|
||||||
|
<el-col :span="24" class="mb25">
|
||||||
|
<el-form-item prop="files" label="附件">
|
||||||
|
<file-upload :view="true" :files.sync="formData.files" card></file-upload>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
</el-collapse-item>
|
||||||
|
</el-collapse>
|
||||||
|
|
||||||
|
<el-row :gutter="20" v-if="formData.id != null && formData.id !== ''">
|
||||||
|
<el-divider content-position="left" class="dia"><span
|
||||||
|
style="color: #3ea1ec;">活动费用预算及报销信息表</span></el-divider>
|
||||||
|
<el-form-item label-width="40px">
|
||||||
|
<span style="color: red">如有收款人请填写收款人、支行名称及报销卡号;如无收款人,请在备注栏中说明报销情况</span>
|
||||||
|
<el-table :data="formData.budgets" border max-height="500" size="mini" style="width: 100%">
|
||||||
|
<el-table-column label="序号" sortable fixed type="index" width="60"></el-table-column>
|
||||||
|
<el-table-column label="费用项目名称" fixed prop="name" width="200">
|
||||||
|
<template scope="{row,$index}">
|
||||||
|
<el-form-item label-width="0"
|
||||||
|
:prop="'budgets.'+$index+'.name'"
|
||||||
|
:rules="[{required:true,message:'必填',trigger:['change','blur']}]">
|
||||||
|
<el-input v-model="row.name" style="width: 100%" maxlength="50"
|
||||||
|
placeholder="请输入费用项目名称"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="预算费用" prop="budgetPrice" width="250">
|
||||||
|
<template scope="{row,$index}">
|
||||||
|
<el-form-item label-width="0"
|
||||||
|
:prop="'budgets.'+$index+'.budgetPrice'"
|
||||||
|
:rules="[{required:true,message:'必填',trigger:['change','blur']}]">
|
||||||
|
<el-input-number placeholder="预算费用" v-model="row.budgetPrice"
|
||||||
|
:precision="2" style="width: 100%"
|
||||||
|
:min="1"></el-input-number>
|
||||||
|
</el-form-item>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="实际费用" prop="actualPrice" width="250">
|
||||||
|
<template scope="{row,$index}">
|
||||||
|
<el-form-item label-width="0"
|
||||||
|
:prop="'budgets.'+$index+'.actualPrice'"
|
||||||
|
:rules="[{required:true,message:'必填',trigger:['change','blur']}]">
|
||||||
|
<el-input-number placeholder="请填写实际费用" v-model="row.actualPrice"
|
||||||
|
:precision="2" style="width: 100%"
|
||||||
|
:min="0"></el-input-number>
|
||||||
|
</el-form-item>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="收款人" prop="payeeId" width="200">
|
||||||
|
<template scope="{row,$index}">
|
||||||
|
<el-form-item label-width="0"
|
||||||
|
:prop="'budgets.'+$index+'.payeeId'">
|
||||||
|
<el-input v-model="row.username" maxlength="50"
|
||||||
|
@input="getCardNumberByPayeeId(row)"
|
||||||
|
placeholder="请输入收款人"></el-input>
|
||||||
|
<!--<el-select :loading="selectLoading" :remote-method="remoteMethod"
|
||||||
|
clearable
|
||||||
|
filterable
|
||||||
|
@change="getCardNumberByPayeeId(row)"
|
||||||
|
placeholder="请选择收款人"
|
||||||
|
remote
|
||||||
|
reserve-keyword
|
||||||
|
style="width: 100%"
|
||||||
|
v-model="row.payeeId">
|
||||||
|
<el-option
|
||||||
|
:key="item.id"
|
||||||
|
:label="item.username+'-'+item.loginname+'-'+item.unitname"
|
||||||
|
:value="item.id"
|
||||||
|
v-for="item in userList">
|
||||||
|
</el-option>
|
||||||
|
</el-select>-->
|
||||||
|
</el-form-item>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="支行名称" prop="bankName" width="300">
|
||||||
|
<template scope="{row,$index}">
|
||||||
|
<el-form-item label-width="0"
|
||||||
|
:prop="'budgets.'+$index+'.bankName'">
|
||||||
|
<el-input v-model="row.bankName" maxlength="80"
|
||||||
|
placeholder="请输入支行名称"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="报销卡号" prop="bankCardNum" width="250">
|
||||||
|
<template scope="{row,$index}">
|
||||||
|
<el-form-item label-width="0">
|
||||||
|
<el-input type="number" v-model="row.bankCardNum"
|
||||||
|
maxlength="50"
|
||||||
|
placeholder="请输入报销卡号"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="备注" prop="remark" width="400">
|
||||||
|
<template scope="{row,$index}">
|
||||||
|
<el-form-item label-width="0"
|
||||||
|
:prop="'budgets.'+$index+'.remark'">
|
||||||
|
<el-input v-model="row.remark" maxlength="200"
|
||||||
|
placeholder="请输入备注"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column fixed="right" header-align="center" label="操作" width="100">
|
||||||
|
<template slot="header" slot-scope="scope">
|
||||||
|
<el-button @click="formData.budgets.push({})" type="primary" size="mini">添加</el-button>
|
||||||
|
</template>
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<el-button :disabled="formData.budgets.length==1"
|
||||||
|
@click="formData.budgets.splice(scope.$index,1)"
|
||||||
|
size="mini"
|
||||||
|
icon="el-icon-delete"
|
||||||
|
type="danger"></el-button>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
</el-table>
|
||||||
|
</el-form-item>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
<el-divider content-position="left" class="dia"><span style="color: #3ea1ec;">其他报销附件</span>
|
||||||
|
</el-divider>
|
||||||
|
<el-row :gutter="40">
|
||||||
|
<el-col :span="12" class="mb25">
|
||||||
|
<el-form-item prop="billFiles" label="发票">
|
||||||
|
<file-upload :files.sync="formData.billFiles"
|
||||||
|
:max="100"
|
||||||
|
:type="['doc','docx','xls','xlsx','pdf','ppt','mp4', 'jpg', 'png', 'jpeg']"
|
||||||
|
card></file-upload>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="12" class="mb25">
|
||||||
|
<el-form-item prop="photoFiles" label="活动报道照片/总结/链接">
|
||||||
|
<file-upload :files.sync="formData.photoFiles"
|
||||||
|
:max="100"
|
||||||
|
:type="['doc','docx','xls','xlsx','pdf','ppt','mp4', 'jpg', 'png', 'jpeg']"
|
||||||
|
card></file-upload>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
<el-row :gutter="40">
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item prop="otherFiles" label="奖品/纪念品/服装/道具等活动人员名单">
|
||||||
|
<file-upload :files.sync="formData.otherFiles"
|
||||||
|
:max="100"
|
||||||
|
:type="['doc','docx','xls','xlsx','pdf','ppt','mp4', 'jpg', 'png', 'jpeg']"
|
||||||
|
card></file-upload>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
<!--<el-divider content-position="left" class="dia"><span style="color: #3ea1ec;">新闻稿件</span>
|
||||||
|
</el-divider>
|
||||||
|
<el-row :gutter="20">
|
||||||
|
<el-col :span="24">
|
||||||
|
<el-form-item prop="newsRemark" label="新闻稿件说明">
|
||||||
|
<el-input v-model="formData.newsRemark" type="textarea" rows="4"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :lg="24" :sm="24">
|
||||||
|
<el-form-item label="图片上传" prop="picFiles">
|
||||||
|
<file-upload :files.sync="formData.picFiles" card :max="10"
|
||||||
|
:type="['jpg', 'png', 'jpeg']">
|
||||||
|
<template #el-upload__tip>
|
||||||
|
</template>
|
||||||
|
</file-upload>
|
||||||
|
<div class="el-upload__tip">请上传jpg、png、jpeg格式的图片,最多不超过10张</div>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
|
||||||
|
<el-col :lg="24" :sm="24">
|
||||||
|
<el-form-item label="附件上传" prop="newsFiles">
|
||||||
|
<file-upload :files.sync="formData.newsFiles" card :max="10"
|
||||||
|
:type="['doc','docx','xls','xlsx','pdf','ppt','mp4', 'jpg', 'png', 'jpeg']">
|
||||||
|
<template #el-upload__tip>
|
||||||
|
</template>
|
||||||
|
</file-upload>
|
||||||
|
<div class="el-upload__tip">可上传照片、视频、文档等资料,视频只能上传MP4格式</div>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>-->
|
||||||
|
|
||||||
|
<el-divider content-position="left" class="dia"><span
|
||||||
|
style="color: #3ea1ec;">签  字</span>
|
||||||
|
</el-divider>
|
||||||
|
<el-form-item label="签字" prop="sign">
|
||||||
|
<sign prefix="medicalAid" :qz.sync="formData.sign"></sign>
|
||||||
|
</el-form-item>
|
||||||
|
</el-form>
|
||||||
|
|
||||||
|
<div style="float: right;margin: 20px 0">
|
||||||
|
<el-button type="primary" @click="doSave()">保 存</el-button>
|
||||||
|
<el-button type="primary" @click="doEdit()">提 交</el-button>
|
||||||
|
</div>
|
||||||
|
</el-card>
|
||||||
|
|
||||||
|
</template>
|
||||||
|
</guava>
|
||||||
|
|
||||||
|
|
||||||
|
<el-dialog
|
||||||
|
title="活动报销须知"
|
||||||
|
:visible.sync="dialogVisible"
|
||||||
|
width="40%">
|
||||||
|
|
||||||
|
<span style="line-height: 24px">
|
||||||
|
  1、智慧工会“基层活动”提交活动申请,审核通过后开展活动。活动结束后在系统中提交活动内容,导出报销凭据到工会财务处报销。<br/>
|
||||||
|
  2、活动报销所需材料如下:<br/>
|
||||||
|
    ①.活动方案(含预算),校工会主席签字;<br/>
|
||||||
|
    ②.活动新闻稿/照片;<br/>
|
||||||
|
    ③.如发放奖品/纪念品,需附领奖人签字名单;<br/>
|
||||||
|
    ④.如购买服装、道具等,需附领用人签字名单。<br/>
|
||||||
|
  3.发票。抬头为“中国药科大学工会”,纳税人识别号(81320000782716328E)。发票上应注明品名、数量、单价和金额,加附购物清单。电子发票打印件由经办人签名承诺“本人承诺只使用一次”。汇款给个人且发票金额大于1000元,需附付款记录。<br/>
|
||||||
|
  4.《中国药科大学报销凭证》。报销凭证应有附件,如所有参与人员名单、奖金物品发放签领单、用餐人员名单等。报销凭证须由经办人、证明人(基层工会主席)、负责人(校工会主席)签字。<br/>
|
||||||
|
  5.本年度基层工会的活动经费需在当年12月15日前使用,如有结余不累计到下一年度。<br/>
|
||||||
|
|
||||||
|
</span>
|
||||||
|
|
||||||
|
<span slot="footer" class="dialog-footer">
|
||||||
|
<el-button type="primary" @click="dialogVisible = false;">同意</el-button>
|
||||||
|
</span>
|
||||||
|
</el-dialog>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
/*function validateArrayItems(arr) {
|
||||||
|
/!*return arr.every(item => {
|
||||||
|
for (const key in item) {
|
||||||
|
if (!key=='remark' && (item[key] === null || item[key] === '')) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return true;
|
||||||
|
});*!/
|
||||||
|
}*/
|
||||||
|
const vue = new Vue({
|
||||||
|
el: '#app',
|
||||||
|
mixins: [initTableMixins],
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
fundsUnitNameOption: [],
|
||||||
|
selectLoading: false,
|
||||||
|
userList: [],
|
||||||
|
delNotesList: [],
|
||||||
|
tabLoading: false,
|
||||||
|
tableData: [],
|
||||||
|
projectType: [],
|
||||||
|
activityType: [],
|
||||||
|
formData: {
|
||||||
|
goods: []
|
||||||
|
},
|
||||||
|
formSign: {},
|
||||||
|
pageForm: {
|
||||||
|
searchName: "username",
|
||||||
|
year: new Date().getFullYear() + ""
|
||||||
|
},
|
||||||
|
formRules: {
|
||||||
|
id: [{required: true, message: '必填', trigger: ['blur', 'change']}],
|
||||||
|
activity_number: [{required: true, message: '必填', trigger: ['blur', 'change']}],
|
||||||
|
// billFiles: [{required: true, message: '必填', trigger: ['blur', 'change']}],
|
||||||
|
// photoFiles: [{required: true, message: '必填', trigger: ['blur', 'change']}],
|
||||||
|
},
|
||||||
|
activity: [],
|
||||||
|
activeNames: [],
|
||||||
|
activityOptions: [],
|
||||||
|
dialogVisible: false,
|
||||||
|
}
|
||||||
|
},
|
||||||
|
components: {
|
||||||
|
'search': httpVueLoader('/components/activityBx/ActivityBxSearch.vue'),
|
||||||
|
'file-upload': httpVueLoader('/components/plugins/FileUpload.vue'),
|
||||||
|
'activity-bx-info': httpVueLoader('/components/activityBx/ActivityBxInfo.vue?v=' + new Date().getTime()),
|
||||||
|
'sign': httpVueLoader('/components/sign/sign.vue?v=2.0.0')
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
async remoteMethod(query) {
|
||||||
|
if (query) {
|
||||||
|
this.selectLoading = true;
|
||||||
|
this.userList = await searchUser(query, '${@shiro.getPrincipalProperty("union").getId()}', null, null, null)
|
||||||
|
this.selectLoading = false;
|
||||||
|
}
|
||||||
|
},
|
||||||
|
async getCardNumberByPayeeId(row) {
|
||||||
|
// const user = this.userList.find(v => v.id === row.payeeId)
|
||||||
|
// row.loginName = user.loginname
|
||||||
|
// row.username = user.username
|
||||||
|
const resp = await $.get('/platform/jf/Funds/apply/getCardNumberByPayeeId', {username:row.username})
|
||||||
|
if (resp.code === 0) {
|
||||||
|
if (resp.data) {
|
||||||
|
debugger
|
||||||
|
this.$set(row, "bankCardNum", resp.data.bankCardNum)
|
||||||
|
this.$set(row, "bankName", resp.data.bankName)
|
||||||
|
// row.bankCardNum = resp.data.bankCardNum
|
||||||
|
// row.bankName = resp.data.bankName
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
//导出报销凭证
|
||||||
|
doExportReimbursementVoucher() {
|
||||||
|
window.open('/platform/jf/activity_bx/reimbursement/doExport?id=' + this.formData.id)
|
||||||
|
},
|
||||||
|
//导出活动申请表
|
||||||
|
doExportActivityApply() {
|
||||||
|
window.open('/platform/jf/activity_bx/reimbursementview/doExport?id=' + this.formData.id)
|
||||||
|
},
|
||||||
|
//导出活动参加人员
|
||||||
|
doExportActivitySignUpUser() {
|
||||||
|
window.open('/platform/jf/reimbursement/mine/exportActivityJoinUser?id=' + this.formData.id)
|
||||||
|
},
|
||||||
|
blur() {
|
||||||
|
let num = 0
|
||||||
|
this.formData.goods.forEach(v => {
|
||||||
|
num += parseFloat(v.price)
|
||||||
|
})
|
||||||
|
this.$set(this.formData, "activity_money", num)
|
||||||
|
},
|
||||||
|
delNotesItem(scope) {
|
||||||
|
this.delNotesList.push(scope.row.id)
|
||||||
|
this.formData.goods.splice(scope.$index, 1)
|
||||||
|
},
|
||||||
|
async activityChange(id) {
|
||||||
|
const {code, data} = await $.get('/platform/jf/reimbursement/apply/findOne', {id: id})
|
||||||
|
if (code === 0) {
|
||||||
|
data.plannedDate = [data.startPlannedDate, data.endPlannedDate]
|
||||||
|
this.formData.billFiles = []
|
||||||
|
this.formData.photoFiles = []
|
||||||
|
this.formData.otherFiles = []
|
||||||
|
this.formData.picFiles = []
|
||||||
|
this.formData.newsFiles = []
|
||||||
|
this.formData.files = []
|
||||||
|
this.formData.goods = []
|
||||||
|
this.formData = data
|
||||||
|
// this.formData.goods = data.Goods
|
||||||
|
if (data.files && data.files.length > 0) this.formData.files = JSON.parse(data.files)
|
||||||
|
if (data.billFiles && data.billFiles.length > 0) this.formData.billFiles = JSON.parse(data.billFiles)
|
||||||
|
if (data.photoFiles && data.photoFiles.length > 0) this.formData.photoFiles = JSON.parse(data.photoFiles)
|
||||||
|
if (data.otherFiles && data.otherFiles.length > 0) this.formData.otherFiles = JSON.parse(data.otherFiles)
|
||||||
|
if (data.picFiles && data.picFiles.length > 0) this.formData.picFiles = JSON.parse(data.picFiles)
|
||||||
|
if (data.newsFiles && data.newsFiles.length > 0) this.formData.newsFiles = JSON.parse(data.newsFiles)
|
||||||
|
if (data.budgets && data.budgets.length > 0) {
|
||||||
|
this.formData.budgets = JSON.parse(data.budgets)
|
||||||
|
this.formData.budgets.forEach(v => {
|
||||||
|
this.remoteMethod(v.loginName)
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
doSave() {
|
||||||
|
if (!this.formData.id) {
|
||||||
|
this.$message.warning("请选择活动后才能保存")
|
||||||
|
}
|
||||||
|
// 确定要保存吗?保存后可在【我的报销】页面选中设置按钮的【编辑】按钮进行修改或提交
|
||||||
|
this.$confirm('确定要保存吗?保存后可在【我的报销】页面选中设置按钮的【编辑】按钮进行修改或提交', '提示', {
|
||||||
|
confirmButtonText: '确定',
|
||||||
|
cancelButtonText: '取消',
|
||||||
|
type: 'warning'
|
||||||
|
}).then(async() => {
|
||||||
|
const loading = this.$loading({
|
||||||
|
lock: true,
|
||||||
|
text: '正在提交...',
|
||||||
|
spinner: 'el-icon-loading',
|
||||||
|
background: COVER_LAYER_COLOR
|
||||||
|
});
|
||||||
|
const resp = await $.post("/platform/jf/reimbursement/apply/doSave", {
|
||||||
|
activityBx: JSON.stringify(this.formData),
|
||||||
|
// sign: this.formData.sign,
|
||||||
|
})
|
||||||
|
loading.close()
|
||||||
|
if (resp.code === 0) {
|
||||||
|
this.pageData()
|
||||||
|
this.$message.success(resp.msg)
|
||||||
|
setTimeout(() => {
|
||||||
|
window.location.href = '/platform/jf/reimbursement/mine'
|
||||||
|
})
|
||||||
|
} else {
|
||||||
|
this.$message.error(resp.msg)
|
||||||
|
}
|
||||||
|
}).catch(() => {
|
||||||
|
})
|
||||||
|
},
|
||||||
|
doEdit() {
|
||||||
|
/* console.log(validateArrayItems(this.formData.budgets))
|
||||||
|
if (!validateArrayItems(this.formData.budgets)) {
|
||||||
|
this.$message.error('活动费用预算未填写完整,请检查')
|
||||||
|
return
|
||||||
|
}*/
|
||||||
|
|
||||||
|
this.$refs["form"].validate(async (valid) => {
|
||||||
|
if (valid) {
|
||||||
|
// 提交后将进入审核流程,无法修改申请内容,确定提交吗?
|
||||||
|
this.$confirm('提交后将进入审核流程,无法修改申请内容,确定提交吗?', '提示', {
|
||||||
|
confirmButtonText: '确定',
|
||||||
|
cancelButtonText: '取消',
|
||||||
|
type: 'warning'
|
||||||
|
}).then(async() => {
|
||||||
|
const loading = this.$loading({
|
||||||
|
lock: true,
|
||||||
|
text: '正在提交...',
|
||||||
|
spinner: 'el-icon-loading',
|
||||||
|
background: COVER_LAYER_COLOR
|
||||||
|
});
|
||||||
|
const resp = await $.post("/platform/jf/reimbursement/apply/doEdit", {
|
||||||
|
activityBx: JSON.stringify(this.formData),
|
||||||
|
sign: this.formData.sign,
|
||||||
|
})
|
||||||
|
loading.close()
|
||||||
|
if (resp.code === 0) {
|
||||||
|
this.$message.success(resp.msg)
|
||||||
|
setTimeout(() => {
|
||||||
|
window.location.href = '/platform/jf/reimbursement/mine'
|
||||||
|
}, 500)
|
||||||
|
} else {
|
||||||
|
this.$message.error(resp.msg)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
|
async init() {
|
||||||
|
this.delNotesList = []
|
||||||
|
this.projectType = await getActivityTwoLevelType("50000")
|
||||||
|
this.activityType = await getActivityTwoLevelType("40000")
|
||||||
|
},
|
||||||
|
async getActivityReimbursementByUser() {
|
||||||
|
const {code, data} = await $.get('/platform/jf/reimbursement/apply/getActivityReimbursementByUser');
|
||||||
|
if (code === 0) {
|
||||||
|
this.activityOptions = data
|
||||||
|
}
|
||||||
|
},
|
||||||
|
async getUserClub() {
|
||||||
|
const {data} = await $.get('/platform/jf/Funds/apply/getUserClub')
|
||||||
|
const a = await getClubs()
|
||||||
|
const aa = a.filter(v => {
|
||||||
|
return data.map(x => x.clubid).includes(v.id)
|
||||||
|
})
|
||||||
|
this.fundsUnitNameOption = aa
|
||||||
|
}
|
||||||
|
},
|
||||||
|
async created() {
|
||||||
|
this.init()
|
||||||
|
await this.getActivityReimbursementByUser()
|
||||||
|
const id = GetQueryString('id')
|
||||||
|
if (id != null && id !== '') {
|
||||||
|
this.formData.id = id
|
||||||
|
await this.activityChange(id);
|
||||||
|
}
|
||||||
|
this.dialogVisible = true
|
||||||
|
await this.getUserClub();
|
||||||
|
}
|
||||||
|
})
|
||||||
|
</script>
|
||||||
|
<!--#
|
||||||
|
}
|
||||||
|
#-->
|
||||||
@@ -0,0 +1,644 @@
|
|||||||
|
<!--#
|
||||||
|
layout("/layouts/platform.html"){
|
||||||
|
#-->
|
||||||
|
<style>
|
||||||
|
.top_block {
|
||||||
|
width: 100%;
|
||||||
|
padding: 20px 80px;
|
||||||
|
border-bottom: 10px solid rgb(240, 240, 240);
|
||||||
|
}
|
||||||
|
|
||||||
|
.tr {
|
||||||
|
text-align: right;
|
||||||
|
}
|
||||||
|
|
||||||
|
.tl {
|
||||||
|
text-align: left;
|
||||||
|
}
|
||||||
|
|
||||||
|
.top_title {
|
||||||
|
font-size: 14px;
|
||||||
|
color: #808492;
|
||||||
|
height: 30px;
|
||||||
|
line-height: 30px;
|
||||||
|
margin-bottom: 5px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.fs18 {
|
||||||
|
font-size: 18px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.fs26 {
|
||||||
|
font-size: 26px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.fs20 {
|
||||||
|
font-size: 20px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.title {
|
||||||
|
font-size: 18px;
|
||||||
|
height: 36px;
|
||||||
|
line-height: 36px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.none-data {
|
||||||
|
min-height: 300px;
|
||||||
|
background: url("/none.png") no-repeat center center;
|
||||||
|
background-size: 360px 260px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.none-data-title {
|
||||||
|
position: absolute;
|
||||||
|
display: block;
|
||||||
|
width: 100%;
|
||||||
|
text-align: center;
|
||||||
|
bottom: 20%;
|
||||||
|
left: 0;
|
||||||
|
color: rgb(160, 160, 160);
|
||||||
|
}
|
||||||
|
|
||||||
|
.item-title {
|
||||||
|
color: rgb(160, 160, 160);
|
||||||
|
}
|
||||||
|
|
||||||
|
.item-content {
|
||||||
|
color: rgb(100, 100, 100);
|
||||||
|
}
|
||||||
|
|
||||||
|
.mb20 {
|
||||||
|
margin-bottom: 20px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.top_num {
|
||||||
|
font-size: 26px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cut-off-line {
|
||||||
|
width: 1px;
|
||||||
|
height: 70%;
|
||||||
|
position: absolute;
|
||||||
|
right: 0;
|
||||||
|
top: 0;
|
||||||
|
bottom: 0;
|
||||||
|
margin: auto;
|
||||||
|
background-color: rgb(230, 230, 230);
|
||||||
|
}
|
||||||
|
|
||||||
|
.year input {
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.chartTitle {
|
||||||
|
font-size: 14px;
|
||||||
|
color: #808492;
|
||||||
|
margin-bottom: 20px;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
<div id="app" v-cloak>
|
||||||
|
<div class="p10">
|
||||||
|
<el-card shadow="never">
|
||||||
|
<div class="top_block" v-loading="top_block_loading">
|
||||||
|
<el-row gutter="60">
|
||||||
|
<div style="position: absolute;top: -35px;right: -8px">
|
||||||
|
<el-date-picker
|
||||||
|
class="year"
|
||||||
|
style="width: 120px;"
|
||||||
|
size="mini"
|
||||||
|
v-model="numForm.startYear"
|
||||||
|
type="year" :clearable="false"
|
||||||
|
value-format="yyyy"
|
||||||
|
@change="if(numForm.endYear){getNumData();}"
|
||||||
|
placeholder="选择年">
|
||||||
|
</el-date-picker>
|
||||||
|
-
|
||||||
|
<el-date-picker
|
||||||
|
class="year"
|
||||||
|
style="width: 120px;"
|
||||||
|
size="mini"
|
||||||
|
v-model="numForm.endYear"
|
||||||
|
type="year" :clearable="false"
|
||||||
|
value-format="yyyy"
|
||||||
|
@change="if(numForm.startYear){getNumData();}"
|
||||||
|
placeholder="选择年">
|
||||||
|
</el-date-picker>
|
||||||
|
</div>
|
||||||
|
<el-col :span="4" style="position: relative">
|
||||||
|
<div class="top_title">校工会活动总人数</div>
|
||||||
|
<div class="top_num">{{numData.schoolSignNum?numData.schoolSignNum:'0'}}</div>
|
||||||
|
<div class="cut-off-line"></div>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="4" style="position: relative">
|
||||||
|
<div class="top_title">分工会活动总人数</div>
|
||||||
|
<div class="top_num">{{numData.unionSignNum?numData.unionSignNum:'0'}}</div>
|
||||||
|
<div class="cut-off-line"></div>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="4" style="position: relative">
|
||||||
|
<div class="top_title">协会活动总人数</div>
|
||||||
|
<div class="top_num">{{numData.clubSignNum?numData.clubSignNum:'0'}}</div>
|
||||||
|
<div class="cut-off-line"></div>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="4" style="position: relative">
|
||||||
|
<div class="top_title">校工会活动经费(元)
|
||||||
|
<el-popover
|
||||||
|
placement="top-start"
|
||||||
|
title=""
|
||||||
|
width="200"
|
||||||
|
trigger="hover"
|
||||||
|
content="申请和报销的活动经费">
|
||||||
|
<i style="color: #409EFF" slot="reference" class="el-icon-question"></i>
|
||||||
|
</el-popover>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="top_num">{{numData.schoolActivityMoney?numData.schoolActivityMoney:'0'}}</div>
|
||||||
|
<div class="cut-off-line"></div>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="4" style="position: relative">
|
||||||
|
<div class="top_title">分工会活动经费(元)
|
||||||
|
<el-popover
|
||||||
|
placement="top-start"
|
||||||
|
title=""
|
||||||
|
width="200"
|
||||||
|
trigger="hover"
|
||||||
|
content="申请和报销的活动经费">
|
||||||
|
<i style="color: #409EFF" slot="reference" class="el-icon-question"></i>
|
||||||
|
</el-popover>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="top_num">{{numData.unionActivityMoney?numData.unionActivityMoney:'0'}}</div>
|
||||||
|
<div class="cut-off-line"></div>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="4">
|
||||||
|
<div class="top_title">社团活动经费(元)
|
||||||
|
<el-popover
|
||||||
|
placement="top-start"
|
||||||
|
title=""
|
||||||
|
width="200"
|
||||||
|
trigger="hover"
|
||||||
|
content="申请和报销的活动经费">
|
||||||
|
<i style="color: #409EFF" slot="reference" class="el-icon-question"></i>
|
||||||
|
</el-popover>
|
||||||
|
</div>
|
||||||
|
<div class="top_num">{{numData.clubActivityMoney?numData.clubActivityMoney:'0'}}</div>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<el-row style="padding: 30px 0;border-bottom: 10px solid rgb(240, 240, 240)">
|
||||||
|
<div style="position: absolute;top: 25px;right: 40px;z-index: 200">
|
||||||
|
<el-date-picker
|
||||||
|
class="year"
|
||||||
|
style="width: 120px;"
|
||||||
|
size="mini"
|
||||||
|
v-model="activityTypeForm.startYear"
|
||||||
|
type="year" :clearable="false"
|
||||||
|
value-format="yyyy"
|
||||||
|
@change="if(activityTypeForm.endYear){getActivityTypeChart();getActivityTypePieNum();}"
|
||||||
|
placeholder="选择年">
|
||||||
|
</el-date-picker>
|
||||||
|
-
|
||||||
|
<el-date-picker
|
||||||
|
class="year"
|
||||||
|
style="width: 120px;"
|
||||||
|
size="mini"
|
||||||
|
v-model="activityTypeForm.endYear"
|
||||||
|
type="year" :clearable="false"
|
||||||
|
value-format="yyyy"
|
||||||
|
@change="if(activityTypeForm.startYear){getActivityTypeChart();getActivityTypePieNum();}"
|
||||||
|
placeholder="选择年">
|
||||||
|
</el-date-picker>
|
||||||
|
</div>
|
||||||
|
<el-col :span="12" style="padding: 0 20px;"
|
||||||
|
v-loading="activity_type_loading">
|
||||||
|
<div class="chartTitle">活动类型</div>
|
||||||
|
<div id="activityTypeChart" style="width: 100%;height: 330px;"></div>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="12" style="padding: 0 20px;position: relative"
|
||||||
|
v-loading="activity_type_pie_loading">
|
||||||
|
<div class="chartTitle">活动类型占比</div>
|
||||||
|
<div id="activityTypePieChart" style="width: 100%;height: 330px;"></div>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
<el-row style="padding: 30px 0;border-bottom: 10px solid rgb(240, 240, 240)">
|
||||||
|
<div style="position: absolute;top: 25px;right: 40px;z-index: 2000">
|
||||||
|
<el-date-picker
|
||||||
|
class="year"
|
||||||
|
style="width: 120px;"
|
||||||
|
size="mini"
|
||||||
|
v-model="activityJfForm.startYear"
|
||||||
|
type="year" :clearable="false"
|
||||||
|
value-format="yyyy"
|
||||||
|
@change="if(activityJfForm.endYear){getActivityJfPieNum();getActivityJfChart();}"
|
||||||
|
placeholder="选择年">
|
||||||
|
</el-date-picker>
|
||||||
|
-
|
||||||
|
<el-date-picker
|
||||||
|
class="year"
|
||||||
|
style="width: 120px;"
|
||||||
|
size="mini"
|
||||||
|
v-model="activityJfForm.endYear"
|
||||||
|
type="year" :clearable="false"
|
||||||
|
value-format="yyyy"
|
||||||
|
@change="if(activityJfForm.startYear){getActivityJfPieNum();getActivityJfChart();}"
|
||||||
|
placeholder="选择年">
|
||||||
|
</el-date-picker>
|
||||||
|
</div>
|
||||||
|
<el-col :span="12" style="padding: 0 20px;"
|
||||||
|
v-loading="activity_jf_loading">
|
||||||
|
<div class="chartTitle">活动经费</div>
|
||||||
|
<div id="activityJfChart" style="width: 100%;height: 330px;"></div>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="12" style="padding: 0 20px;position: relative"
|
||||||
|
v-loading="activity_jf_pie_loading">
|
||||||
|
<div class="chartTitle">活动经费占比</div>
|
||||||
|
<div id="activityJfPieChart" style="width: 100%;height: 330px;"></div>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
|
||||||
|
<el-row style="padding: 30px 0;border-bottom: 10px solid rgb(240, 240, 240)">
|
||||||
|
<div style="position: absolute;top: 25px;right: 40px;z-index: 999">
|
||||||
|
<el-date-picker
|
||||||
|
class="year"
|
||||||
|
style="width: 120px;"
|
||||||
|
size="mini"
|
||||||
|
v-model="allUnionYear"
|
||||||
|
type="year" :clearable="false"
|
||||||
|
value-format="yyyy" @change="allUnionActivityAndJf"
|
||||||
|
placeholder="选择年">
|
||||||
|
</el-date-picker>
|
||||||
|
</div>
|
||||||
|
<el-col :span="24" style="padding: 0 20px"
|
||||||
|
v-loading="all_union_loading">
|
||||||
|
<div class="chartTitle" style="margin-bottom: 50px">{{allUnionYear}}年工会经费及活动情况
|
||||||
|
<el-tooltip class="item" effect="dark" :content="'点击切换为' + unionTip " placement="top">
|
||||||
|
<el-button type="text" icon="el-icon-sort" @click="doUnionSwitch"></el-button>
|
||||||
|
</el-tooltip>
|
||||||
|
</div>
|
||||||
|
<div id="allUnionChart" style="width: 100%;height: 300px;"></div>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
|
||||||
|
<el-row style="padding: 30px 0;border-bottom: 10px solid rgb(240, 240, 240)">
|
||||||
|
<div style="position: absolute;top: 25px;right: 40px;z-index: 999">
|
||||||
|
<el-date-picker
|
||||||
|
class="year"
|
||||||
|
style="width: 120px;"
|
||||||
|
size="mini"
|
||||||
|
v-model="allClubYear"
|
||||||
|
type="year" :clearable="false"
|
||||||
|
value-format="yyyy" @change="allClubActivityAndJf"
|
||||||
|
placeholder="选择年">
|
||||||
|
</el-date-picker>
|
||||||
|
</div>
|
||||||
|
<el-col :span="24" style="padding: 0 20px"
|
||||||
|
v-loading="all_club_loading">
|
||||||
|
<div class="chartTitle" style="margin-bottom: 50px">{{allClubYear}}年社团经费及活动情况
|
||||||
|
<el-tooltip class="item" effect="dark" :content="'点击切换为' + clubTip " placement="top">
|
||||||
|
<el-button type="text" icon="el-icon-sort" @click="doClubSwitch"></el-button>
|
||||||
|
</el-tooltip>
|
||||||
|
</div>
|
||||||
|
<div id="allClubChart" style="width: 100%;height: 300px;"></div>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
</el-card>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
const vue = new Vue({
|
||||||
|
el: '#app',
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
top_block_loading: false,
|
||||||
|
numForm: {
|
||||||
|
startYear: new Date().getFullYear() - 2 + '',
|
||||||
|
endYear: new Date().getFullYear() + '',
|
||||||
|
},
|
||||||
|
numData: {},
|
||||||
|
activity_type_loading: false,
|
||||||
|
activity_type_pie_loading: false,
|
||||||
|
activityTypePieChart: null,
|
||||||
|
activityTypeForm: {
|
||||||
|
startYear: new Date().getFullYear() - 2 + '',
|
||||||
|
endYear: new Date().getFullYear() + '',
|
||||||
|
},
|
||||||
|
activity_jf_loading: false,
|
||||||
|
activity_jf_pie_loading: false,
|
||||||
|
activityJfPieChart: null,
|
||||||
|
activityJfForm: {
|
||||||
|
startYear: new Date().getFullYear() - 2 + '',
|
||||||
|
endYear: new Date().getFullYear() + '',
|
||||||
|
},
|
||||||
|
|
||||||
|
all_union_loading: false,
|
||||||
|
unionTip:'分工会活动数',
|
||||||
|
allUnionYear: moment().format('YYYY'),
|
||||||
|
isUnionJf:true,
|
||||||
|
|
||||||
|
all_club_loading: false,
|
||||||
|
clubTip:'协会活动数',
|
||||||
|
allClubYear: moment().format('YYYY'),
|
||||||
|
isClubJf:true,
|
||||||
|
}
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
async getNumData() {
|
||||||
|
this.top_block_loading = true
|
||||||
|
const resp = await $.post("/platform/jf/reimbursement/board/getNumData", this.numForm)
|
||||||
|
if (resp.code === 0) {
|
||||||
|
this.numData = resp.data
|
||||||
|
}
|
||||||
|
this.top_block_loading = false
|
||||||
|
},
|
||||||
|
async getActivityTypeChart() {
|
||||||
|
this.activity_type_loading = true
|
||||||
|
const resp = await $.post("/platform/jf/reimbursement/board/getActivityTypeChart", this.activityTypeForm)
|
||||||
|
if (resp.code === 0) {
|
||||||
|
let {data} = resp
|
||||||
|
document.getElementById("activityTypeChart").innerHTML = ''
|
||||||
|
const config = {
|
||||||
|
isGroup: true,
|
||||||
|
"legend": {
|
||||||
|
"position": "top-right",
|
||||||
|
"flipPage": false
|
||||||
|
},
|
||||||
|
"autoFit": false,
|
||||||
|
"width": $('#activityTypeChart').width(),
|
||||||
|
"height": $('#activityTypeChart').height(),
|
||||||
|
"xField": "year",
|
||||||
|
"yField": "num",
|
||||||
|
"seriesField": "type",
|
||||||
|
}
|
||||||
|
|
||||||
|
const plot = new G2Plot.Column(document.getElementById("activityTypeChart"), {
|
||||||
|
data,
|
||||||
|
...config,
|
||||||
|
});
|
||||||
|
plot.render();
|
||||||
|
}
|
||||||
|
this.activity_type_loading = false
|
||||||
|
},
|
||||||
|
async getActivityTypePieNum() {
|
||||||
|
this.activity_type_pie_loading = true
|
||||||
|
// 销毁旧的图表实例(如果存在)
|
||||||
|
if (this.activityTypePieChart) {
|
||||||
|
this.activityTypePieChart.destroy();
|
||||||
|
}
|
||||||
|
const resp = await $.post("/platform/jf/reimbursement/board/getActivityTypePieNum", this.activityTypeForm)
|
||||||
|
if (resp.code === 0) {
|
||||||
|
let {data} = resp
|
||||||
|
const config = {
|
||||||
|
"legend": {
|
||||||
|
"flipPage": false
|
||||||
|
},
|
||||||
|
"label": {
|
||||||
|
"type": "spider",
|
||||||
|
"offset": 50
|
||||||
|
},
|
||||||
|
"width": $('#activityTypePieChart').width(),
|
||||||
|
"height": $('#activityTypePieChart').height(),
|
||||||
|
"forceFit": false,
|
||||||
|
"radius": 1,
|
||||||
|
"colorField": "type",
|
||||||
|
"angleField": "num",
|
||||||
|
meta: {
|
||||||
|
type: {
|
||||||
|
alias: '类别',
|
||||||
|
},
|
||||||
|
num: {
|
||||||
|
alias: '数量',
|
||||||
|
}
|
||||||
|
},
|
||||||
|
}
|
||||||
|
this.activityTypePieChart = new G2Plot.Pie(document.getElementById("activityTypePieChart"), {
|
||||||
|
data,
|
||||||
|
...config,
|
||||||
|
});
|
||||||
|
this.activityTypePieChart.render();
|
||||||
|
|
||||||
|
}
|
||||||
|
this.activity_type_pie_loading = false
|
||||||
|
},
|
||||||
|
async getActivityJfChart() {
|
||||||
|
this.activity_type_loading = true
|
||||||
|
const resp = await $.post("/platform/jf/reimbursement/board/getActivityJfChart", this.activityJfForm)
|
||||||
|
if (resp.code === 0) {
|
||||||
|
let {data} = resp
|
||||||
|
document.getElementById("activityJfChart").innerHTML = ''
|
||||||
|
const config = {
|
||||||
|
isGroup: true,
|
||||||
|
"legend": {
|
||||||
|
"position": "top-right",
|
||||||
|
"flipPage": false
|
||||||
|
},
|
||||||
|
"autoFit": false,
|
||||||
|
"width": $('#activityJfChart').width(),
|
||||||
|
"height": $('#activityJfChart').height(),
|
||||||
|
"xField": "year",
|
||||||
|
"yField": "num",
|
||||||
|
"seriesField": "type",
|
||||||
|
}
|
||||||
|
|
||||||
|
const plot = new G2Plot.Column(document.getElementById("activityJfChart"), {
|
||||||
|
data,
|
||||||
|
...config,
|
||||||
|
});
|
||||||
|
plot.render();
|
||||||
|
}
|
||||||
|
this.activity_type_loading = false
|
||||||
|
},
|
||||||
|
async getActivityJfPieNum() {
|
||||||
|
this.activity_jf_pie_loading = true
|
||||||
|
// 销毁旧的图表实例(如果存在)
|
||||||
|
if (this.activityJfPieChart) {
|
||||||
|
this.activityJfPieChart.destroy();
|
||||||
|
}
|
||||||
|
const resp = await $.post("/platform/jf/reimbursement/board/getActivityJfPieNum", this.activityJfForm)
|
||||||
|
if (resp.code === 0) {
|
||||||
|
let {data} = resp
|
||||||
|
const config = {
|
||||||
|
"legend": {
|
||||||
|
"flipPage": false
|
||||||
|
},
|
||||||
|
"label": {
|
||||||
|
"type": "spider",
|
||||||
|
"offset": 50
|
||||||
|
},
|
||||||
|
"width": $('#activityJfPieChart').width(),
|
||||||
|
"height": $('#activityJfPieChart').height(),
|
||||||
|
"forceFit": false,
|
||||||
|
"radius": 1,
|
||||||
|
"colorField": "type",
|
||||||
|
"angleField": "num",
|
||||||
|
meta: {
|
||||||
|
type: {
|
||||||
|
alias: '类别',
|
||||||
|
},
|
||||||
|
num: {
|
||||||
|
alias: '数量',
|
||||||
|
}
|
||||||
|
},
|
||||||
|
}
|
||||||
|
this.activityJfPieChart = new G2Plot.Pie(document.getElementById("activityJfPieChart"), {
|
||||||
|
data,
|
||||||
|
...config,
|
||||||
|
});
|
||||||
|
this.activityJfPieChart.render();
|
||||||
|
|
||||||
|
}
|
||||||
|
this.activity_jf_pie_loading = false
|
||||||
|
},
|
||||||
|
async doUnionSwitch(){
|
||||||
|
this.isUnionJf = !this.isUnionJf
|
||||||
|
this.unionTip = this.isUnionJf ? '分工会活动数' : '分工会经费详情'
|
||||||
|
await this.allUnionActivityAndJf();
|
||||||
|
},
|
||||||
|
async allUnionActivityAndJf() {
|
||||||
|
this.all_union_loading = true
|
||||||
|
const resp = await $.get("/platform/jf/reimbursement/board/allUnionActivityAndJf",{year:this.allUnionYear,isUnionJf:this.isUnionJf})
|
||||||
|
if (resp.code === 0) {
|
||||||
|
let {data} = resp
|
||||||
|
document.getElementById("allUnionChart").innerHTML = ''
|
||||||
|
const config = {
|
||||||
|
isStack: true,
|
||||||
|
"legend": {
|
||||||
|
"position": "top-right",
|
||||||
|
"flipPage": false
|
||||||
|
},
|
||||||
|
autoFit: true,
|
||||||
|
title: {
|
||||||
|
visible: true,
|
||||||
|
text: this.allUnionYear + '年工会经费及活动详情',
|
||||||
|
},
|
||||||
|
description: {
|
||||||
|
visible: true,
|
||||||
|
text: '单位(元)',
|
||||||
|
},
|
||||||
|
xField: 'unionname',
|
||||||
|
yField: 'money',
|
||||||
|
stackField: 'type',
|
||||||
|
color: ["#5B8FF9", "#5AD8A6"],
|
||||||
|
"xAxis": {
|
||||||
|
label: {
|
||||||
|
formatter: (v) => {
|
||||||
|
if (data.length > 30 && v.length > 3) {
|
||||||
|
return v.substr(0, 2) + '...'
|
||||||
|
} else if (data.length > 20 && v.length > 4) {
|
||||||
|
return v.substr(0, 3) + '...'
|
||||||
|
} else if (data.length > 10 && v.length > 6) {
|
||||||
|
return v.substr(0, 5) + '...'
|
||||||
|
}
|
||||||
|
return v
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"yAxis": {},
|
||||||
|
meta: {
|
||||||
|
unionname: {
|
||||||
|
alias: '工会',
|
||||||
|
},
|
||||||
|
money: {
|
||||||
|
alias: this.isUnionJf?'金额':'活动数',
|
||||||
|
}
|
||||||
|
},
|
||||||
|
connectedArea: {
|
||||||
|
visible: true,
|
||||||
|
triggerOn: false,
|
||||||
|
},
|
||||||
|
}
|
||||||
|
const plot = new G2Plot.Column(document.getElementById("allUnionChart"), {
|
||||||
|
data,
|
||||||
|
...config,
|
||||||
|
});
|
||||||
|
plot.render();
|
||||||
|
}
|
||||||
|
this.all_union_loading = false
|
||||||
|
},
|
||||||
|
async doClubSwitch(){
|
||||||
|
this.isClubJf = !this.isClubJf
|
||||||
|
this.clubTip = this.isClubJf ? '协会活动数' : '协会经费详情'
|
||||||
|
await this.allClubActivityAndJf();
|
||||||
|
},
|
||||||
|
async allClubActivityAndJf(){
|
||||||
|
this.all_club_loading = true
|
||||||
|
const resp = await $.get("/platform/jf/reimbursement/board/allClubActivityAndJf",{year:this.allClubYear,isClubJf:this.isClubJf})
|
||||||
|
if (resp.code === 0) {
|
||||||
|
let {data} = resp
|
||||||
|
document.getElementById("allClubChart").innerHTML = ''
|
||||||
|
const config = {
|
||||||
|
isStack: true,
|
||||||
|
"legend": {
|
||||||
|
"position": "top-right",
|
||||||
|
"flipPage": false
|
||||||
|
},
|
||||||
|
autoFit: true,
|
||||||
|
title: {
|
||||||
|
visible: true,
|
||||||
|
text: this.allClubYear + '年工会经费及活动详情',
|
||||||
|
},
|
||||||
|
description: {
|
||||||
|
visible: true,
|
||||||
|
text: '单位(元)',
|
||||||
|
},
|
||||||
|
xField: 'clubName',
|
||||||
|
yField: 'money',
|
||||||
|
stackField: 'type',
|
||||||
|
color: ["#5B8FF9", "#5AD8A6"],
|
||||||
|
"xAxis": {
|
||||||
|
label: {
|
||||||
|
formatter: (v) => {
|
||||||
|
if (data.length > 30 && v.length > 3) {
|
||||||
|
return v.substr(0, 2) + '...'
|
||||||
|
} else if (data.length > 20 && v.length > 4) {
|
||||||
|
return v.substr(0, 3) + '...'
|
||||||
|
} else if (data.length > 10 && v.length > 6) {
|
||||||
|
return v.substr(0, 5) + '...'
|
||||||
|
}
|
||||||
|
return v
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"yAxis": {},
|
||||||
|
meta: {
|
||||||
|
clubName: {
|
||||||
|
alias: '协会',
|
||||||
|
},
|
||||||
|
money: {
|
||||||
|
alias: this.isClubJf?'金额':'活动数',
|
||||||
|
}
|
||||||
|
},
|
||||||
|
connectedArea: {
|
||||||
|
visible: true,
|
||||||
|
triggerOn: false,
|
||||||
|
},
|
||||||
|
}
|
||||||
|
const plot = new G2Plot.Column(document.getElementById("allClubChart"), {
|
||||||
|
data,
|
||||||
|
...config,
|
||||||
|
});
|
||||||
|
plot.render();
|
||||||
|
}
|
||||||
|
this.all_club_loading = false
|
||||||
|
},
|
||||||
|
},
|
||||||
|
async created() {
|
||||||
|
await this.getNumData()
|
||||||
|
},
|
||||||
|
async mounted() {
|
||||||
|
await this.getActivityJfChart()
|
||||||
|
await this.getActivityTypeChart()
|
||||||
|
await this.getActivityTypePieNum()
|
||||||
|
await this.getActivityJfPieNum()
|
||||||
|
await this.allUnionActivityAndJf()
|
||||||
|
await this.allClubActivityAndJf()
|
||||||
|
},
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<!--#
|
||||||
|
}
|
||||||
|
#-->
|
||||||
@@ -0,0 +1,259 @@
|
|||||||
|
<!--#
|
||||||
|
layout("/layouts/platform.html"){
|
||||||
|
#-->
|
||||||
|
|
||||||
|
<div id="app" v-cloak>
|
||||||
|
<guava ref="guava">
|
||||||
|
<template>
|
||||||
|
<el-card shadow="never">
|
||||||
|
<div class="search">
|
||||||
|
<div class="search-item">
|
||||||
|
<div class="search-item-label">年份:</div>
|
||||||
|
<div class="search-item-option">
|
||||||
|
<el-date-picker
|
||||||
|
v-model="pageForm.year"
|
||||||
|
type="year"
|
||||||
|
value-format="yyyy" style="width: 100%"
|
||||||
|
@change="doSearch"
|
||||||
|
placeholder="选择年">
|
||||||
|
</el-date-picker>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="search-item">
|
||||||
|
<div class="search-item-label">姓名工号:</div>
|
||||||
|
<div class="search-item-option">
|
||||||
|
<el-input placeholder="请输入内容" v-model="pageForm.searchKeyword">
|
||||||
|
<el-select v-model="pageForm.searchName" slot="prepend" placeholder="查询类型"
|
||||||
|
style="width: 80px;">
|
||||||
|
<el-option label="工号" value="u.loginname"></el-option>
|
||||||
|
<el-option label="姓名" value="u.username"></el-option>
|
||||||
|
</el-select>
|
||||||
|
</el-input>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="search-item">
|
||||||
|
<div class="search-item-label">所属协会:</div>
|
||||||
|
<div class="search-item-option">
|
||||||
|
<el-select v-model="pageForm.clubId" placeholder="请选择协会"
|
||||||
|
@change="doSearch" clearable
|
||||||
|
filterable style="width: 100%">
|
||||||
|
<el-option
|
||||||
|
v-for="item in clubOptions"
|
||||||
|
:key="item.stid"
|
||||||
|
:label="item.name"
|
||||||
|
:value="item.stid">
|
||||||
|
</el-option>
|
||||||
|
</el-select>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="search-query">
|
||||||
|
<el-button type="primary" icon="el-icon-search" @click="doSearch">搜索
|
||||||
|
</el-button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</el-card>
|
||||||
|
|
||||||
|
<el-card shadow="never" class="mt10">
|
||||||
|
|
||||||
|
<table-tool label="审核列表" :app="this">
|
||||||
|
<template #func>
|
||||||
|
<el-radio-group v-model="pageForm.isAudit" @change="doSearch" size="small">
|
||||||
|
<el-radio-button :label="0">全部</el-radio-button>
|
||||||
|
<el-radio-button :label="1">已审核</el-radio-button>
|
||||||
|
<el-radio-button :label="2">未审核</el-radio-button>
|
||||||
|
</el-radio-group>
|
||||||
|
</template>
|
||||||
|
</table-tool>
|
||||||
|
|
||||||
|
<el-table :data="tableData" style="width: 100%" row-key="id" @sort-change="pageOrder"
|
||||||
|
v-loading="tabLoading">
|
||||||
|
<el-table-column align="center" header-align="center" label="序号" width="120px">
|
||||||
|
<template scope="scope">
|
||||||
|
<span>{{scope.$index+(pageForm.pageNumber - 1) * pageForm.pageSize + 1}} </span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
|
||||||
|
<el-table-column
|
||||||
|
align="center"
|
||||||
|
header-align="center"
|
||||||
|
v-for="column in tableColumns"
|
||||||
|
:label="column.label"
|
||||||
|
:prop="column.prop"
|
||||||
|
:width="column.width"
|
||||||
|
show-overflow-tooltip
|
||||||
|
:sortable="column.sortable">
|
||||||
|
<template v-if="column.prop=='activity_name'" scope="{row}">
|
||||||
|
<el-link type="primary" @click="openView(row)">
|
||||||
|
{{row.activity_name}}
|
||||||
|
</el-link>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template v-else-if="column.prop=='activity_type'" scope="{row}">
|
||||||
|
{{ row.activity_type == 40002 ? "分工会活动" : row.activity_type == 40003 ? "协会活动"
|
||||||
|
: "校工会活动"}}
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template v-else-if="column.prop=='absName'" scope="{row}">
|
||||||
|
{{row.absName}}
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template v-else-if="column.prop=='reimbursement_state_id'" scope="{row}">
|
||||||
|
<span :style="'color:'+row.state_color">{{row.state_name}}</span>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
</el-table-column>
|
||||||
|
|
||||||
|
<el-table-column align="center" header-align="center" label="操作" fixed="right"
|
||||||
|
width="220px">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<el-button @click="openView(scope.row)" size="mini">查看</el-button>
|
||||||
|
<el-button @click="openAudit(scope.row.id)"
|
||||||
|
v-if="scope.row.reimbursement_state_id == 1000"
|
||||||
|
size="mini" type="primary">审核</el-button>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
</el-table>
|
||||||
|
<!--#include("/layouts/pagination.html"){}#-->
|
||||||
|
</el-card>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template #edit>
|
||||||
|
<activity-bx-info ref="clubChairmanAudit" :handle="true" label="协会负责人审核(报销)" :panes="[7]">
|
||||||
|
<template #handle>
|
||||||
|
<el-form :model="formData" ref="auditForm" :rules="formRules" label-position="right"
|
||||||
|
style="padding: 20px 0"
|
||||||
|
label-width="120px">
|
||||||
|
<el-form-item label="审核信息 " label-width="135px" class="view-header"></el-form-item>
|
||||||
|
|
||||||
|
<el-row gutter="20">
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item prop="username" label="审核人">
|
||||||
|
<el-input v-model="formData.username"
|
||||||
|
disabled></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item prop="time" label="审核时间">
|
||||||
|
<el-input v-model="formData.time" disabled></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
<el-form-item prop="auditOpinion" label="审核意见">
|
||||||
|
<el-input type="textarea" v-model="formData.auditOpinion" rows="4" maxlength="500"
|
||||||
|
placeholder="请填写您的审核意见"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
|
<el-form-item prop="auditSign" label="签  字">
|
||||||
|
<sign prefix="medicalAid" :qz.sync="formData.auditSign"></sign>
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
|
</el-form>
|
||||||
|
|
||||||
|
<div style="float: right;margin: 20px 0">
|
||||||
|
<el-button type="danger" @click="doReview(false)">拒绝</el-button>
|
||||||
|
<el-button type="primary" @click="doReview(true)">通过</el-button>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
</activity-bx-info>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template #view>
|
||||||
|
<activity-bx-info ref="act_info"></activity-bx-info>
|
||||||
|
</template>
|
||||||
|
</guava>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
const vue = new Vue({
|
||||||
|
el: '#app',
|
||||||
|
mixins: [initTableMixins],
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
pageForm: {
|
||||||
|
year: moment().format('YYYY'),
|
||||||
|
searchName: 'u.username',
|
||||||
|
isAudit:2
|
||||||
|
},
|
||||||
|
tabLoading: false,
|
||||||
|
clubOptions: [],
|
||||||
|
tableColumns: [
|
||||||
|
{prop: 'activity_name', label: '活动名称', sortable: true},
|
||||||
|
{prop: 'user_name', label: '申请人姓名', sortable: true},
|
||||||
|
{prop: 'bxr_loginname', label: '申请人工号', sortable: true},
|
||||||
|
{prop: 'clubName', label: '所属协会', sortable: true},
|
||||||
|
{prop: 'activity_type', label: '活动主体类型', sortable: true},
|
||||||
|
{prop: 'absName', label: '活动项目类型', sortable: true},
|
||||||
|
{prop: 'reimbursement_apply_time', label: '申请时间', sortable: true},
|
||||||
|
{prop: 'reimbursement_state_id', label: '申请状态', sortable: true},
|
||||||
|
],
|
||||||
|
formRules:{
|
||||||
|
auditOpinion: [{required: true, message: '请填写意见', trigger: ['change', 'blur']}],
|
||||||
|
auditSign: [{required: true, message: '请签字', trigger: ['change', 'blur']}],
|
||||||
|
},
|
||||||
|
id:''
|
||||||
|
}
|
||||||
|
},
|
||||||
|
components: {
|
||||||
|
'guava': httpVueLoader('/components/plugins/Guava.vue'),
|
||||||
|
'activity-bx-info': httpVueLoader('/components/activityBx/ActivityBxInfo.vue?v=' + new Date().getTime()),
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
openView(row) {
|
||||||
|
this.$refs.act_info.getActInfo(row.id)
|
||||||
|
this.$refs.guava.view()
|
||||||
|
},
|
||||||
|
openAudit(id) {
|
||||||
|
this.id = id
|
||||||
|
this.formData = {
|
||||||
|
username: "${@shiro.getPrincipalProperty('username')}",
|
||||||
|
time: moment().format('YYYY-MM-DD'),
|
||||||
|
}
|
||||||
|
this.$refs.clubChairmanAudit.getActInfo(id)
|
||||||
|
this.$refs.guava.edit()
|
||||||
|
},
|
||||||
|
async doReview(row){
|
||||||
|
const valid = await this.$refs['auditForm'].validate()
|
||||||
|
if (!valid) return
|
||||||
|
if (this.formData.auditSign == null){
|
||||||
|
this.$message.warning("请扫码签字!")
|
||||||
|
return
|
||||||
|
}
|
||||||
|
this.formData.auditPass = row
|
||||||
|
// 确定要拒绝/通过吗?
|
||||||
|
this.$confirm('确定要' + (row ? '通过' : '拒绝') + '吗?', '提示', {
|
||||||
|
confirmButtonText: '确定',
|
||||||
|
cancelButtonText: '取消',
|
||||||
|
type: 'warning'
|
||||||
|
}).then(async () => {
|
||||||
|
const loading = this.$loading({
|
||||||
|
lock: true,
|
||||||
|
text: '正在提交...',
|
||||||
|
spinner: 'el-icon-loading',
|
||||||
|
background: COVER_LAYER_COLOR
|
||||||
|
});
|
||||||
|
const resp = await $.post(loc() + '/doAuditing', {
|
||||||
|
id:this.id,
|
||||||
|
audit:JSON.stringify(this.formData)
|
||||||
|
})
|
||||||
|
loading.close()
|
||||||
|
if (resp.code === 0) {
|
||||||
|
this.$refs.guava.index()
|
||||||
|
this.$message.success(resp.msg)
|
||||||
|
this.pageData()
|
||||||
|
} else {
|
||||||
|
this.$.message.error(resp.msg)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
},
|
||||||
|
async created() {
|
||||||
|
this.pageData()
|
||||||
|
this.clubOptions = await getClubsByRole()
|
||||||
|
}
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<!--#
|
||||||
|
}
|
||||||
|
#-->
|
||||||
@@ -0,0 +1,278 @@
|
|||||||
|
<!--#
|
||||||
|
layout("/layouts/platform.html"){
|
||||||
|
#-->
|
||||||
|
|
||||||
|
<div id="app" v-cloak>
|
||||||
|
<guava ref="guava">
|
||||||
|
<template>
|
||||||
|
<el-card shadow="never">
|
||||||
|
<div class="search">
|
||||||
|
<div class="search-item">
|
||||||
|
<div class="search-item-label">年份:</div>
|
||||||
|
<div class="search-item-option">
|
||||||
|
<el-date-picker
|
||||||
|
v-model="pageForm.year"
|
||||||
|
type="year"
|
||||||
|
value-format="yyyy" style="width: 100%"
|
||||||
|
@change="doSearch"
|
||||||
|
placeholder="选择年">
|
||||||
|
</el-date-picker>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="search-item">
|
||||||
|
<div class="search-item-label">姓名工号:</div>
|
||||||
|
<div class="search-item-option">
|
||||||
|
<el-input placeholder="请输入内容" v-model="pageForm.searchKeyword">
|
||||||
|
<el-select v-model="pageForm.searchName" slot="prepend" placeholder="查询类型"
|
||||||
|
style="width: 80px;">
|
||||||
|
<el-option label="工号" value="u.loginname"></el-option>
|
||||||
|
<el-option label="姓名" value="u.username"></el-option>
|
||||||
|
</el-select>
|
||||||
|
</el-input>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="search-item">
|
||||||
|
<div class="search-item-label">所属工会:</div>
|
||||||
|
<div class="search-item-option">
|
||||||
|
<el-select placeholder="所属工会" v-model="pageForm.unionId" style="width: 100%;"
|
||||||
|
clearable="true"
|
||||||
|
@change="flushUnits" @clear="flushUnits"
|
||||||
|
v-if="${@shiro.hasRole('sysadmin')||@shiro.hasRole('A06')||@shiro.hasRole('H03')}"
|
||||||
|
filterable="true">
|
||||||
|
<el-option v-for="item in unions" :label="item.unionname" :value="item.id"></el-option>
|
||||||
|
</el-select>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="search-item">
|
||||||
|
<div class="search-item-label">所属单位:</div>
|
||||||
|
<div class="search-item-option">
|
||||||
|
<el-select placeholder="所属单位" v-model="pageForm.unitId" style="width: 100%;"
|
||||||
|
clearable="true"
|
||||||
|
filterable="true">
|
||||||
|
<el-option v-for="item in units" :label="item.name" :value="item.id"></el-option>
|
||||||
|
</el-select>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="search-query">
|
||||||
|
<el-button type="primary" icon="el-icon-search" @click="doSearch">搜索
|
||||||
|
</el-button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</el-card>
|
||||||
|
|
||||||
|
<!--申请记录展示-->
|
||||||
|
<el-card shadow="never" class="mt10">
|
||||||
|
<el-table :data="tableData" style="width: 100%" row-key="id" @sort-change="pageOrder"
|
||||||
|
v-loading="tabLoading">
|
||||||
|
<el-table-column align="center" header-align="center" label="序号" width="120px">
|
||||||
|
<template scope="scope">
|
||||||
|
<span>{{scope.$index+(pageForm.pageNumber - 1) * pageForm.pageSize + 1}} </span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
|
||||||
|
<el-table-column label="活动名称" prop="activity_name" header-align="center"
|
||||||
|
align="center">
|
||||||
|
<template scope="scope">
|
||||||
|
<el-link type="primary" @click="openView(scope.row)">
|
||||||
|
{{scope.row.activity_name}}
|
||||||
|
</el-link>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
|
||||||
|
<el-table-column label="申请人姓名" prop="user_name" header-align="center"
|
||||||
|
align="center"></el-table-column>
|
||||||
|
|
||||||
|
<el-table-column label="工号" prop="bxr_loginname" header-align="center"
|
||||||
|
align="center"></el-table-column>
|
||||||
|
|
||||||
|
<el-table-column label="所属工会" prop="bxr_unionname" header-align="center" sortable
|
||||||
|
align="center"></el-table-column>
|
||||||
|
|
||||||
|
<el-table-column label="活动主体类型" prop="activity_type" header-align="center" align="center" sortable>
|
||||||
|
<template scope="{row}">
|
||||||
|
{{ row.activity_type == 40002 ? "分工会活动" : row.activity_type == 40003 ? "协会活动" :
|
||||||
|
"校工会活动"}}
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
|
||||||
|
<el-table-column label="申请类型" prop="apply_type" header-align="center" sortable
|
||||||
|
align="center">
|
||||||
|
<template scope="{row}">
|
||||||
|
{{ "报销申请" }}
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
|
||||||
|
<el-table-column label="申请时间" prop="reimbursement_apply_time" header-align="center" sortable
|
||||||
|
align="center"></el-table-column>
|
||||||
|
|
||||||
|
|
||||||
|
<!-- <el-table-column label="审核人" prop="shrname" header-align="center"
|
||||||
|
align="center">
|
||||||
|
<template slot-scope="{row:{shrname}}">
|
||||||
|
{{shrname?shrname:'暂无'}}
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
-->
|
||||||
|
<el-table-column align="center" prop="reimbursement_state_id" header-align="center" label="申请状态" sortable>
|
||||||
|
<template scope="scope">
|
||||||
|
<span :style="'color:'+scope.row.state_color">{{scope.row.state_name}}</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
|
||||||
|
<el-table-column align="center" header-align="center" label="操作" fixed="right"
|
||||||
|
width="120px">
|
||||||
|
<template slot-scope="{row}">
|
||||||
|
<el-dropdown @command="dropdownCommand">
|
||||||
|
<el-button plain size="mini">
|
||||||
|
<i class="ti-settings"></i>
|
||||||
|
<span class="ti-angle-down"></span>
|
||||||
|
</el-button>
|
||||||
|
<el-dropdown-menu slot="dropdown">
|
||||||
|
<el-dropdown-item :command="{type:'view',data:row}">
|
||||||
|
查看
|
||||||
|
</el-dropdown-item>
|
||||||
|
<el-dropdown-item v-if="[999,1005,1015,1025,1045].includes(row.reimbursement_state_id)"
|
||||||
|
:command="{type:'edit',data:row}">
|
||||||
|
编辑
|
||||||
|
</el-dropdown-item>
|
||||||
|
<el-dropdown-item v-if="${@shiro.hasRole('sysadmin')}"
|
||||||
|
:command="{type:'delete',data:row}">
|
||||||
|
删除
|
||||||
|
</el-dropdown-item>
|
||||||
|
<el-dropdown-item
|
||||||
|
v-if="[1020].includes(row.reimbursement_state_id)&&${!@shiro.hasRole('sysadmin')}"
|
||||||
|
:command="{type:'delete',data:row}">
|
||||||
|
删除
|
||||||
|
</el-dropdown-item>
|
||||||
|
<el-dropdown-item :command="{type:'exportWwj',data:row,apply_type:1}">
|
||||||
|
导出申请方案表
|
||||||
|
</el-dropdown-item>
|
||||||
|
<el-dropdown-item :command="{type:'exportWwj',data:row,apply_type:2}">
|
||||||
|
导出活动报销凭证
|
||||||
|
</el-dropdown-item>
|
||||||
|
<el-dropdown-item :command="{type:'exportJoinUser',data:row}">
|
||||||
|
导出活动参与人员
|
||||||
|
</el-dropdown-item>
|
||||||
|
<el-dropdown-item :command="{type:'exportFiles',data:row,exportType:'billFiles'}">
|
||||||
|
导出发票
|
||||||
|
</el-dropdown-item>
|
||||||
|
<el-dropdown-item :command="{type:'exportFiles',data:row,exportType:'photoFiles'}">
|
||||||
|
导出活动报道链接/总结/图片
|
||||||
|
</el-dropdown-item>
|
||||||
|
<el-dropdown-item :command="{type:'exportFiles',data:row,exportType:'otherFiles'}">
|
||||||
|
导出奖品/纪念品/服装/道具领用人名单
|
||||||
|
</el-dropdown-item>
|
||||||
|
<el-dropdown-item :command="{type:'exportFiles',data:row,exportType:'all'}">
|
||||||
|
导出全部附件
|
||||||
|
</el-dropdown-item>
|
||||||
|
</el-dropdown-menu>
|
||||||
|
</el-dropdown>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
</el-table>
|
||||||
|
<!--#include("/layouts/pagination.html"){}#-->
|
||||||
|
</el-card>
|
||||||
|
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template #view>
|
||||||
|
<activity-bx-info ref="act_info"></activity-bx-info>
|
||||||
|
</template>
|
||||||
|
</guava>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
const vue = new Vue({
|
||||||
|
el: '#app',
|
||||||
|
mixins: [initTableMixins],
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
pageForm:{
|
||||||
|
year: moment().format('YYYY'),
|
||||||
|
searchName:'u.username',
|
||||||
|
},
|
||||||
|
unions:[],
|
||||||
|
units:[],
|
||||||
|
tabLoading: false,
|
||||||
|
}
|
||||||
|
},
|
||||||
|
components: {
|
||||||
|
'guava': httpVueLoader('/components/plugins/Guava.vue'),
|
||||||
|
'activity-bx-info': httpVueLoader('/components/activityBx/ActivityBxInfo.vue?v=' + new Date().getTime()),
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
dropdownCommand(command) {
|
||||||
|
const {type, data, apply_type,exportType} = command
|
||||||
|
if (type === "view") {
|
||||||
|
this.openView(data)
|
||||||
|
} else if (type === "edit") {
|
||||||
|
this.openEdit(data)
|
||||||
|
} else if (type === "delete") {
|
||||||
|
this.doDelete(data)
|
||||||
|
} else if (type === "exportWwj") {
|
||||||
|
this.exportWwj(data, apply_type)
|
||||||
|
} else if (type === 'exportFiles'){
|
||||||
|
this.exportAllFiles(data,exportType);
|
||||||
|
} else if (type === 'exportJoinUser'){
|
||||||
|
this.exportJoinUser(data);
|
||||||
|
}
|
||||||
|
},
|
||||||
|
exportJoinUser(row){
|
||||||
|
window.open('/platform/jf/reimbursement/mine/exportActivityJoinUser?id=' + row.id)
|
||||||
|
},
|
||||||
|
exportAllFiles(row,exportType){
|
||||||
|
window.open('/platform/jf/reimbursement/mine/exportAllFiles?id=' + row.id + '&exportType=' + exportType)
|
||||||
|
},
|
||||||
|
openEdit(data){
|
||||||
|
location.href = '/platform/jf/reimbursement/apply?id=' + data.id
|
||||||
|
// window.open('/platform/jf/reimbursement/apply?id=' + data.id)
|
||||||
|
},
|
||||||
|
async doDelete(data){
|
||||||
|
const confirm = await this.$confirm('您确定要删除吗?', '提示', {
|
||||||
|
confirmButtonText: '确定',
|
||||||
|
cancelButtonText: '取消',
|
||||||
|
type: 'warning'
|
||||||
|
})
|
||||||
|
if (confirm === 'confirm') {
|
||||||
|
const resp = await $.post('/platform/jf/reimbursement/mine/doDelete', {id: data.id})
|
||||||
|
if (resp.code === 0) {
|
||||||
|
this.pageData();
|
||||||
|
this.$message.success(resp.msg)
|
||||||
|
} else {
|
||||||
|
this.$message.error(resp.msg)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
exportWwj(row, apply_type) {
|
||||||
|
if (apply_type == 2) {
|
||||||
|
window.location.href = "/platform/jf/activity_bx/reimbursement/doExport?id=" + row.id
|
||||||
|
} else if (apply_type == 1){
|
||||||
|
window.location.href = "/platform/jf/activity_bx/reimbursementview/doExport?id=" + row.id
|
||||||
|
}
|
||||||
|
},
|
||||||
|
openView(row) {
|
||||||
|
const {id} = row
|
||||||
|
this.$refs.act_info.getActInfo(id)
|
||||||
|
this.$refs.guava.view()
|
||||||
|
},
|
||||||
|
async flushUnits() {
|
||||||
|
this.$set(this.pageForm, "unitId", "")
|
||||||
|
if ("${@shiro.hasRole('sysadmin')||@shiro.hasRole('A06')||@shiro.hasRole('H03')}" === 'true') {
|
||||||
|
this.units = await getUnits(this.pageForm.unionId)
|
||||||
|
} else {
|
||||||
|
this.units = await getUnits("${@shiro.getPrincipalProperty('unit').getUnionid()}")
|
||||||
|
}
|
||||||
|
},
|
||||||
|
},
|
||||||
|
async created() {
|
||||||
|
this.pageData()
|
||||||
|
this.unions = await getUnions()
|
||||||
|
this.flushUnits()
|
||||||
|
}
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<!--#
|
||||||
|
}
|
||||||
|
#-->
|
||||||
@@ -0,0 +1,293 @@
|
|||||||
|
<!--#
|
||||||
|
layout("/layouts/platform.html"){
|
||||||
|
#-->
|
||||||
|
|
||||||
|
<div id="app" v-cloak>
|
||||||
|
<guava ref="guava">
|
||||||
|
<template>
|
||||||
|
<el-card shadow="never">
|
||||||
|
<div class="search">
|
||||||
|
<div class="search-item">
|
||||||
|
<div class="search-item-label">年份:</div>
|
||||||
|
<div class="search-item-option">
|
||||||
|
<el-date-picker
|
||||||
|
v-model="pageForm.year"
|
||||||
|
type="year"
|
||||||
|
value-format="yyyy" style="width: 100%"
|
||||||
|
@change="doSearch"
|
||||||
|
placeholder="选择年">
|
||||||
|
</el-date-picker>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="search-item">
|
||||||
|
<div class="search-item-label">姓名工号:</div>
|
||||||
|
<div class="search-item-option">
|
||||||
|
<el-input placeholder="请输入内容" v-model="pageForm.searchKeyword">
|
||||||
|
<el-select v-model="pageForm.searchName" slot="prepend" placeholder="查询类型"
|
||||||
|
style="width: 80px;">
|
||||||
|
<el-option label="工号" value="u.loginname"></el-option>
|
||||||
|
<el-option label="姓名" value="u.username"></el-option>
|
||||||
|
</el-select>
|
||||||
|
</el-input>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="search-item">
|
||||||
|
<div class="search-item-label">所属工会:</div>
|
||||||
|
<div class="search-item-option">
|
||||||
|
<el-select placeholder="所属工会" v-model="pageForm.unionId" style="width: 100%;"
|
||||||
|
clearable="true"
|
||||||
|
@change="flushUnits" @clear="flushUnits"
|
||||||
|
v-if="${@shiro.hasRole('sysadmin')||@shiro.hasRole('A06')||@shiro.hasRole('H03')}"
|
||||||
|
filterable="true">
|
||||||
|
<el-option v-for="item in unions" :label="item.unionname" :value="item.id"></el-option>
|
||||||
|
</el-select>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="search-item">
|
||||||
|
<div class="search-item-label">所属单位:</div>
|
||||||
|
<div class="search-item-option">
|
||||||
|
<el-select placeholder="所属单位" v-model="pageForm.unitId" style="width: 100%;"
|
||||||
|
clearable="true"
|
||||||
|
filterable="true">
|
||||||
|
<el-option v-for="item in units" :label="item.name" :value="item.id"></el-option>
|
||||||
|
</el-select>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="search-item">
|
||||||
|
<div class="search-item-label">所属协会:</div>
|
||||||
|
<div class="search-item-option">
|
||||||
|
<el-select v-model="pageForm.clubId" placeholder="请选择协会"
|
||||||
|
@change="doSearch" clearable
|
||||||
|
filterable style="width: 100%">
|
||||||
|
<el-option
|
||||||
|
v-for="item in clubOptions"
|
||||||
|
:key="item.stid"
|
||||||
|
:label="item.name"
|
||||||
|
:value="item.stid">
|
||||||
|
</el-option>
|
||||||
|
</el-select>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="search-query">
|
||||||
|
<el-button type="primary" icon="el-icon-search" @click="doSearch">搜索
|
||||||
|
</el-button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</el-card>
|
||||||
|
|
||||||
|
<el-card shadow="never" class="mt10">
|
||||||
|
|
||||||
|
<table-tool label="审核列表" :app="this">
|
||||||
|
<template #func>
|
||||||
|
<el-radio-group v-model="pageForm.isAudit" @change="doSearch" size="small">
|
||||||
|
<el-radio-button :label="0">全部</el-radio-button>
|
||||||
|
<el-radio-button :label="1">已审核</el-radio-button>
|
||||||
|
<el-radio-button :label="2">未审核</el-radio-button>
|
||||||
|
</el-radio-group>
|
||||||
|
</template>
|
||||||
|
</table-tool>
|
||||||
|
|
||||||
|
<el-table :data="tableData" style="width: 100%" row-key="id" @sort-change="pageOrder"
|
||||||
|
v-loading="tabLoading">
|
||||||
|
<el-table-column align="center" header-align="center" label="序号" width="120px">
|
||||||
|
<template scope="scope">
|
||||||
|
<span>{{scope.$index+(pageForm.pageNumber - 1) * pageForm.pageSize + 1}} </span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
|
||||||
|
<el-table-column
|
||||||
|
align="center"
|
||||||
|
header-align="center"
|
||||||
|
v-for="column in tableColumns"
|
||||||
|
:label="column.label"
|
||||||
|
:prop="column.prop"
|
||||||
|
:width="column.width"
|
||||||
|
show-overflow-tooltip
|
||||||
|
:sortable="column.sortable">
|
||||||
|
<template v-if="column.prop=='activity_name'" scope="{row}">
|
||||||
|
<el-link type="primary" @click="openView(row)">
|
||||||
|
{{row.activity_name}}
|
||||||
|
</el-link>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template v-else-if="column.prop=='activity_type'" scope="{row}">
|
||||||
|
{{ row.activity_type == 40002 ? "分工会活动" : row.activity_type == 40003 ? "协会活动"
|
||||||
|
: "校工会活动"}}
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template v-else-if="column.prop=='absName'" scope="{row}">
|
||||||
|
{{row.absName}}
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template v-else-if="column.prop=='reimbursement_state_id'" scope="{row}">
|
||||||
|
<span :style="'color:'+row.state_color">{{row.state_name}}</span>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
</el-table-column>
|
||||||
|
|
||||||
|
<el-table-column align="center" header-align="center" label="操作" fixed="right"
|
||||||
|
width="220px">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<el-button @click="openView(scope.row)" size="mini">查看</el-button>
|
||||||
|
<el-button @click="openAudit(scope.row.id)" size="mini"
|
||||||
|
v-if="scope.row.reimbursement_state_id == 1040"
|
||||||
|
type="primary">审核</el-button>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
</el-table>
|
||||||
|
<!--#include("/layouts/pagination.html"){}#-->
|
||||||
|
</el-card>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template #edit>
|
||||||
|
<activity-bx-info ref="schoolChairmanAudit" :handle="true" label="校工会主席审核(报销)" :panes="[7]">
|
||||||
|
<template #handle>
|
||||||
|
<el-form :model="formData" ref="auditForm" :rules="formRules" label-position="right"
|
||||||
|
style="padding: 20px 0"
|
||||||
|
label-width="120px">
|
||||||
|
<el-form-item label="审核信息 " label-width="135px" class="view-header"></el-form-item>
|
||||||
|
|
||||||
|
<el-row gutter="20">
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item prop="username" label="审核人">
|
||||||
|
<el-input v-model="formData.username"
|
||||||
|
disabled></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item prop="time" label="审核时间">
|
||||||
|
<el-input v-model="formData.time" disabled></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
<el-form-item prop="auditOpinion" label="审核意见">
|
||||||
|
<el-input type="textarea" v-model="formData.auditOpinion" rows="4" maxlength="500"
|
||||||
|
placeholder="请填写您的审核意见"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
|
<el-form-item prop="auditSign" label="签  字">
|
||||||
|
<sign prefix="medicalAid" :qz.sync="formData.auditSign"></sign>
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
|
</el-form>
|
||||||
|
|
||||||
|
<div style="float: right;margin: 20px 0">
|
||||||
|
<el-button type="danger" @click="doReview(false)">拒绝</el-button>
|
||||||
|
<el-button type="primary" @click="doReview(true)">通过</el-button>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
</activity-bx-info>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template #view>
|
||||||
|
<activity-bx-info ref="act_info"></activity-bx-info>
|
||||||
|
</template>
|
||||||
|
</guava>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
const vue = new Vue({
|
||||||
|
el: '#app',
|
||||||
|
mixins: [initTableMixins],
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
pageForm: {
|
||||||
|
year: moment().format('YYYY'),
|
||||||
|
searchName: 'u.username',
|
||||||
|
isAudit:2
|
||||||
|
},
|
||||||
|
tabLoading: false,
|
||||||
|
clubOptions: [],
|
||||||
|
unions:[],
|
||||||
|
units:[],
|
||||||
|
tableColumns: [
|
||||||
|
{prop: 'activity_name', label: '活动名称', sortable: true},
|
||||||
|
{prop: 'user_name', label: '申请人姓名', sortable: true},
|
||||||
|
{prop: 'bxr_loginname', label: '申请人工号', sortable: true},
|
||||||
|
{prop: 'unionname', label: '所属工会', sortable: true},
|
||||||
|
{prop: 'unitname', label: '所属单位', sortable: true},
|
||||||
|
{prop: 'clubName', label: '所属协会', sortable: true},
|
||||||
|
{prop: 'activity_type', label: '活动主体类型', sortable: true},
|
||||||
|
{prop: 'absName', label: '活动项目类型', sortable: true},
|
||||||
|
{prop: 'reimbursement_apply_time', label: '申请时间', sortable: true},
|
||||||
|
{prop: 'reimbursement_state_id', label: '申请状态', sortable: true},
|
||||||
|
],
|
||||||
|
formRules:{
|
||||||
|
auditOpinion: [{required: true, message: '请填写意见', trigger: ['change', 'blur']}],
|
||||||
|
auditSign: [{required: true, message: '请签字', trigger: ['change', 'blur']}],
|
||||||
|
},
|
||||||
|
id:''
|
||||||
|
}
|
||||||
|
},
|
||||||
|
components: {
|
||||||
|
'guava': httpVueLoader('/components/plugins/Guava.vue'),
|
||||||
|
'activity-bx-info': httpVueLoader('/components/activityBx/ActivityBxInfo.vue?v=' + new Date().getTime()),
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
openView(row) {
|
||||||
|
this.$refs.act_info.getActInfo(row.id)
|
||||||
|
this.$refs.guava.view()
|
||||||
|
},
|
||||||
|
openAudit(id) {
|
||||||
|
this.id = id
|
||||||
|
this.formData = {
|
||||||
|
username: "${@shiro.getPrincipalProperty('username')}",
|
||||||
|
time: moment().format('YYYY-MM-DD'),
|
||||||
|
}
|
||||||
|
this.$refs.schoolChairmanAudit.getActInfo(id)
|
||||||
|
this.$refs.guava.edit()
|
||||||
|
},
|
||||||
|
async doReview(row){
|
||||||
|
const valid = await this.$refs['auditForm'].validate()
|
||||||
|
if (!valid) return
|
||||||
|
if (this.formData.auditSign == null){
|
||||||
|
this.$message.warning("请扫码签字!")
|
||||||
|
return
|
||||||
|
}
|
||||||
|
this.formData.auditPass = row
|
||||||
|
// 确定要拒绝/通过吗?
|
||||||
|
this.$confirm('确定要' + (row ? '通过' : '拒绝') + '吗?', '提示', {
|
||||||
|
confirmButtonText: '确定',
|
||||||
|
cancelButtonText: '取消',
|
||||||
|
type: 'warning'
|
||||||
|
}).then(async () => {
|
||||||
|
const loading = this.$loading({
|
||||||
|
lock: true,
|
||||||
|
text: '正在提交...',
|
||||||
|
spinner: 'el-icon-loading',
|
||||||
|
background: COVER_LAYER_COLOR
|
||||||
|
});
|
||||||
|
const resp = await $.post(loc() + '/doAuditing', {
|
||||||
|
id:this.id,
|
||||||
|
audit:JSON.stringify(this.formData)
|
||||||
|
})
|
||||||
|
loading.close()
|
||||||
|
if (resp.code === 0) {
|
||||||
|
this.$refs.guava.index()
|
||||||
|
this.notifySuccess(resp.msg)
|
||||||
|
this.pageData()
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
|
async flushUnits() {
|
||||||
|
this.$set(this.pageForm, "unitId", "")
|
||||||
|
if ("${@shiro.hasRole('sysadmin')||@shiro.hasRole('A06')||@shiro.hasRole('H03')}" === 'true') {
|
||||||
|
this.units = await getUnits(this.pageForm.unionId)
|
||||||
|
} else {
|
||||||
|
this.units = await getUnits("${@shiro.getPrincipalProperty('unit').getUnionid()}")
|
||||||
|
}
|
||||||
|
},
|
||||||
|
},
|
||||||
|
async created() {
|
||||||
|
this.pageData()
|
||||||
|
this.clubOptions = await getClubsByRole()
|
||||||
|
this.unions = await getUnions()
|
||||||
|
this.flushUnits()
|
||||||
|
}
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<!--#
|
||||||
|
}
|
||||||
|
#-->
|
||||||
@@ -0,0 +1,293 @@
|
|||||||
|
<!--#
|
||||||
|
layout("/layouts/platform.html"){
|
||||||
|
#-->
|
||||||
|
|
||||||
|
<div id="app" v-cloak>
|
||||||
|
<guava ref="guava">
|
||||||
|
<template>
|
||||||
|
<el-card shadow="never">
|
||||||
|
<div class="search">
|
||||||
|
<div class="search-item">
|
||||||
|
<div class="search-item-label">年份:</div>
|
||||||
|
<div class="search-item-option">
|
||||||
|
<el-date-picker
|
||||||
|
v-model="pageForm.year"
|
||||||
|
type="year"
|
||||||
|
value-format="yyyy" style="width: 100%"
|
||||||
|
@change="doSearch"
|
||||||
|
placeholder="选择年">
|
||||||
|
</el-date-picker>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="search-item">
|
||||||
|
<div class="search-item-label">姓名工号:</div>
|
||||||
|
<div class="search-item-option">
|
||||||
|
<el-input placeholder="请输入内容" v-model="pageForm.searchKeyword">
|
||||||
|
<el-select v-model="pageForm.searchName" slot="prepend" placeholder="查询类型"
|
||||||
|
style="width: 80px;">
|
||||||
|
<el-option label="工号" value="u.loginname"></el-option>
|
||||||
|
<el-option label="姓名" value="u.username"></el-option>
|
||||||
|
</el-select>
|
||||||
|
</el-input>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="search-item">
|
||||||
|
<div class="search-item-label">所属工会:</div>
|
||||||
|
<div class="search-item-option">
|
||||||
|
<el-select placeholder="所属工会" v-model="pageForm.unionId" style="width: 100%;"
|
||||||
|
clearable="true"
|
||||||
|
@change="flushUnits" @clear="flushUnits"
|
||||||
|
v-if="${@shiro.hasRole('sysadmin')||@shiro.hasRole('A06')||@shiro.hasRole('H03')}"
|
||||||
|
filterable="true">
|
||||||
|
<el-option v-for="item in unions" :label="item.unionname" :value="item.id"></el-option>
|
||||||
|
</el-select>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="search-item">
|
||||||
|
<div class="search-item-label">所属单位:</div>
|
||||||
|
<div class="search-item-option">
|
||||||
|
<el-select placeholder="所属单位" v-model="pageForm.unitId" style="width: 100%;"
|
||||||
|
clearable="true"
|
||||||
|
filterable="true">
|
||||||
|
<el-option v-for="item in units" :label="item.name" :value="item.id"></el-option>
|
||||||
|
</el-select>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="search-item">
|
||||||
|
<div class="search-item-label">所属协会:</div>
|
||||||
|
<div class="search-item-option">
|
||||||
|
<el-select v-model="pageForm.clubId" placeholder="请选择协会"
|
||||||
|
@change="doSearch" clearable
|
||||||
|
filterable style="width: 100%">
|
||||||
|
<el-option
|
||||||
|
v-for="item in clubOptions"
|
||||||
|
:key="item.stid"
|
||||||
|
:label="item.name"
|
||||||
|
:value="item.stid">
|
||||||
|
</el-option>
|
||||||
|
</el-select>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="search-query">
|
||||||
|
<el-button type="primary" icon="el-icon-search" @click="doSearch">搜索
|
||||||
|
</el-button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</el-card>
|
||||||
|
|
||||||
|
<el-card shadow="never" class="mt10">
|
||||||
|
|
||||||
|
<table-tool label="审核列表" :app="this">
|
||||||
|
<template #func>
|
||||||
|
<el-radio-group v-model="pageForm.isAudit" @change="doSearch" size="small">
|
||||||
|
<el-radio-button :label="0">全部</el-radio-button>
|
||||||
|
<el-radio-button :label="1">已审核</el-radio-button>
|
||||||
|
<el-radio-button :label="2">未审核</el-radio-button>
|
||||||
|
</el-radio-group>
|
||||||
|
</template>
|
||||||
|
</table-tool>
|
||||||
|
|
||||||
|
<el-table :data="tableData" style="width: 100%" row-key="id" @sort-change="pageOrder"
|
||||||
|
v-loading="tabLoading">
|
||||||
|
<el-table-column align="center" header-align="center" label="序号" width="120px">
|
||||||
|
<template scope="scope">
|
||||||
|
<span>{{scope.$index+(pageForm.pageNumber - 1) * pageForm.pageSize + 1}} </span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
|
||||||
|
<el-table-column
|
||||||
|
align="center"
|
||||||
|
header-align="center"
|
||||||
|
v-for="column in tableColumns"
|
||||||
|
:label="column.label"
|
||||||
|
:prop="column.prop"
|
||||||
|
:width="column.width"
|
||||||
|
show-overflow-tooltip
|
||||||
|
:sortable="column.sortable">
|
||||||
|
<template v-if="column.prop=='activity_name'" scope="{row}">
|
||||||
|
<el-link type="primary" @click="openView(row)">
|
||||||
|
{{row.activity_name}}
|
||||||
|
</el-link>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template v-else-if="column.prop=='activity_type'" scope="{row}">
|
||||||
|
{{ row.activity_type == 40002 ? "分工会活动" : row.activity_type == 40003 ? "协会活动"
|
||||||
|
: "校工会活动"}}
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template v-else-if="column.prop=='absName'" scope="{row}">
|
||||||
|
{{row.absName}}
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template v-else-if="column.prop=='reimbursement_state_id'" scope="{row}">
|
||||||
|
<span :style="'color:'+row.state_color">{{row.state_name}}</span>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
</el-table-column>
|
||||||
|
|
||||||
|
<el-table-column align="center" header-align="center" label="操作" fixed="right"
|
||||||
|
width="220px">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<el-button @click="openView(scope.row)" size="mini">查看</el-button>
|
||||||
|
<el-button @click="openAudit(scope.row.id)" size="mini"
|
||||||
|
v-if="scope.row.reimbursement_state_id == 1020"
|
||||||
|
type="primary">审核</el-button>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
</el-table>
|
||||||
|
<!--#include("/layouts/pagination.html"){}#-->
|
||||||
|
</el-card>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template #edit>
|
||||||
|
<activity-bx-info ref="schoolDirectorAudit" :handle="true" label="校工会负责人审核(报销)" :panes="[9]">
|
||||||
|
<template #handle>
|
||||||
|
<el-form :model="formData" ref="auditForm" :rules="formRules" label-position="right"
|
||||||
|
style="padding: 20px 0"
|
||||||
|
label-width="120px">
|
||||||
|
<el-form-item label="审核信息 " label-width="135px" class="view-header"></el-form-item>
|
||||||
|
|
||||||
|
<el-row gutter="20">
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item prop="username" label="审核人">
|
||||||
|
<el-input v-model="formData.username"
|
||||||
|
disabled></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item prop="time" label="审核时间">
|
||||||
|
<el-input v-model="formData.time" disabled></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
<el-form-item prop="auditOpinion" label="审核意见">
|
||||||
|
<el-input type="textarea" v-model="formData.auditOpinion" rows="4" maxlength="500"
|
||||||
|
placeholder="请填写您的审核意见"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
|
<el-form-item prop="auditSign" label="签  字">
|
||||||
|
<sign prefix="medicalAid" :qz.sync="formData.auditSign"></sign>
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
|
</el-form>
|
||||||
|
|
||||||
|
<div style="float: right;margin: 20px 0">
|
||||||
|
<el-button type="danger" @click="doReview(false)">拒绝</el-button>
|
||||||
|
<el-button type="primary" @click="doReview(true)">通过</el-button>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
</activity-bx-info>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template #view>
|
||||||
|
<activity-bx-info ref="act_info"></activity-bx-info>
|
||||||
|
</template>
|
||||||
|
</guava>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
const vue = new Vue({
|
||||||
|
el: '#app',
|
||||||
|
mixins: [initTableMixins],
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
pageForm: {
|
||||||
|
year: moment().format('YYYY'),
|
||||||
|
searchName: 'u.username',
|
||||||
|
isAudit:2
|
||||||
|
},
|
||||||
|
tabLoading: false,
|
||||||
|
unions:[],
|
||||||
|
units:[],
|
||||||
|
clubOptions: [],
|
||||||
|
tableColumns: [
|
||||||
|
{prop: 'activity_name', label: '活动名称', sortable: true},
|
||||||
|
{prop: 'user_name', label: '申请人姓名', sortable: true},
|
||||||
|
{prop: 'bxr_loginname', label: '申请人工号', sortable: true},
|
||||||
|
{prop: 'unionname', label: '所属工会', sortable: true},
|
||||||
|
{prop: 'unitname', label: '所属单位', sortable: true},
|
||||||
|
{prop: 'clubName', label: '所属协会', sortable: true},
|
||||||
|
{prop: 'activity_type', label: '活动主体类型', sortable: true},
|
||||||
|
{prop: 'absName', label: '活动项目类型', sortable: true},
|
||||||
|
{prop: 'reimbursement_apply_time', label: '申请时间', sortable: true},
|
||||||
|
{prop: 'reimbursement_state_id', label: '申请状态', sortable: true},
|
||||||
|
],
|
||||||
|
formRules:{
|
||||||
|
auditOpinion: [{required: true, message: '请填写意见', trigger: ['change', 'blur']}],
|
||||||
|
auditSign: [{required: true, message: '请签字', trigger: ['change', 'blur']}],
|
||||||
|
},
|
||||||
|
id:'',
|
||||||
|
}
|
||||||
|
},
|
||||||
|
components: {
|
||||||
|
'guava': httpVueLoader('/components/plugins/Guava.vue'),
|
||||||
|
'activity-bx-info': httpVueLoader('/components/activityBx/ActivityBxInfo.vue?v=' + new Date().getTime()),
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
openView(row) {
|
||||||
|
this.$refs.act_info.getActInfo(row.id)
|
||||||
|
this.$refs.guava.view()
|
||||||
|
},
|
||||||
|
openAudit(id) {
|
||||||
|
this.id = id
|
||||||
|
this.formData = {
|
||||||
|
username: "${@shiro.getPrincipalProperty('username')}",
|
||||||
|
time: moment().format('YYYY-MM-DD'),
|
||||||
|
}
|
||||||
|
this.$refs.schoolDirectorAudit.getActInfo(id)
|
||||||
|
this.$refs.guava.edit()
|
||||||
|
},
|
||||||
|
async doReview(row){
|
||||||
|
const valid = await this.$refs['auditForm'].validate()
|
||||||
|
if (!valid) return
|
||||||
|
if (this.formData.auditSign == null){
|
||||||
|
this.$message.warning("请扫码签字!")
|
||||||
|
return
|
||||||
|
}
|
||||||
|
this.formData.auditPass = row
|
||||||
|
// 确定要拒绝/通过吗?
|
||||||
|
this.$confirm('确定要' + (row ? '通过' : '拒绝') + '吗?', '提示', {
|
||||||
|
confirmButtonText: '确定',
|
||||||
|
cancelButtonText: '取消',
|
||||||
|
type: 'warning'
|
||||||
|
}).then(async () => {
|
||||||
|
const loading = this.$loading({
|
||||||
|
lock: true,
|
||||||
|
text: '正在提交...',
|
||||||
|
spinner: 'el-icon-loading',
|
||||||
|
background: COVER_LAYER_COLOR
|
||||||
|
});
|
||||||
|
const resp = await $.post(loc() + '/doAuditing', {
|
||||||
|
id:this.id,
|
||||||
|
audit:JSON.stringify(this.formData)
|
||||||
|
})
|
||||||
|
loading.close()
|
||||||
|
if (resp.code === 0) {
|
||||||
|
this.$refs.guava.index()
|
||||||
|
this.notifySuccess(resp.msg)
|
||||||
|
this.pageData()
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
|
async flushUnits() {
|
||||||
|
this.$set(this.pageForm, "unitId", "")
|
||||||
|
if ("${@shiro.hasRole('sysadmin')||@shiro.hasRole('A06')||@shiro.hasRole('H03')}" === 'true') {
|
||||||
|
this.units = await getUnits(this.pageForm.unionId)
|
||||||
|
} else {
|
||||||
|
this.units = await getUnits("${@shiro.getPrincipalProperty('unit').getUnionid()}")
|
||||||
|
}
|
||||||
|
},
|
||||||
|
},
|
||||||
|
async created() {
|
||||||
|
this.pageData()
|
||||||
|
this.clubOptions = await getClubsByRole()
|
||||||
|
this.unions = await getUnions()
|
||||||
|
this.flushUnits()
|
||||||
|
}
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<!--#
|
||||||
|
}
|
||||||
|
#-->
|
||||||
@@ -0,0 +1,277 @@
|
|||||||
|
<!--#
|
||||||
|
layout("/layouts/platform.html"){
|
||||||
|
#-->
|
||||||
|
|
||||||
|
<div id="app" v-cloak>
|
||||||
|
<guava ref="guava">
|
||||||
|
<template>
|
||||||
|
<el-card shadow="never">
|
||||||
|
<div class="search">
|
||||||
|
<div class="search-item">
|
||||||
|
<div class="search-item-label">年份:</div>
|
||||||
|
<div class="search-item-option">
|
||||||
|
<el-date-picker
|
||||||
|
v-model="pageForm.year"
|
||||||
|
type="year"
|
||||||
|
value-format="yyyy" style="width: 100%"
|
||||||
|
@change="doSearch"
|
||||||
|
placeholder="选择年">
|
||||||
|
</el-date-picker>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="search-item">
|
||||||
|
<div class="search-item-label">姓名工号:</div>
|
||||||
|
<div class="search-item-option">
|
||||||
|
<el-input placeholder="请输入内容" v-model="pageForm.searchKeyword">
|
||||||
|
<el-select v-model="pageForm.searchName" slot="prepend" placeholder="查询类型"
|
||||||
|
style="width: 80px;">
|
||||||
|
<el-option label="工号" value="u.loginname"></el-option>
|
||||||
|
<el-option label="姓名" value="u.username"></el-option>
|
||||||
|
</el-select>
|
||||||
|
</el-input>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="search-item">
|
||||||
|
<div class="search-item-label">所属工会:</div>
|
||||||
|
<div class="search-item-option">
|
||||||
|
<el-select placeholder="所属工会" v-model="pageForm.unionId" style="width: 100%;"
|
||||||
|
clearable="true"
|
||||||
|
@change="flushUnits" @clear="flushUnits"
|
||||||
|
v-if="${@shiro.hasRole('sysadmin')||@shiro.hasRole('A06')||@shiro.hasRole('H03')}"
|
||||||
|
filterable="true">
|
||||||
|
<el-option v-for="item in unions" :label="item.unionname" :value="item.id"></el-option>
|
||||||
|
</el-select>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="search-item">
|
||||||
|
<div class="search-item-label">所属单位:</div>
|
||||||
|
<div class="search-item-option">
|
||||||
|
<el-select placeholder="所属单位" v-model="pageForm.unitId" style="width: 100%;"
|
||||||
|
clearable="true"
|
||||||
|
filterable="true">
|
||||||
|
<el-option v-for="item in units" :label="item.name" :value="item.id"></el-option>
|
||||||
|
</el-select>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="search-item">
|
||||||
|
<div class="search-item-label">所属协会:</div>
|
||||||
|
<div class="search-item-option">
|
||||||
|
<el-select placeholder="所属协会" v-model="pageForm.clubId" style="width: 100%;"
|
||||||
|
clearable="true"
|
||||||
|
filterable="true">
|
||||||
|
<el-option v-for="item in clubOptions" :label="item.name" :value="item.stid"></el-option>
|
||||||
|
</el-select>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="search-query">
|
||||||
|
<el-button type="primary" icon="el-icon-search" @click="doSearch">搜索
|
||||||
|
</el-button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</el-card>
|
||||||
|
|
||||||
|
<el-card shadow="never" class="mt10">
|
||||||
|
|
||||||
|
<table-tool label="审核列表" :app="this">
|
||||||
|
<template #func>
|
||||||
|
<el-radio-group v-model="pageForm.activityType" @change="doSearch" size="small">
|
||||||
|
<el-radio-button :label="0">全部({{ typeNum.all }})</el-radio-button>
|
||||||
|
<el-radio-button :label="40001">校工会报销({{ typeNum.school }})</el-radio-button>
|
||||||
|
<el-radio-button :label="40002">基层工会报销({{ typeNum.union }})</el-radio-button>
|
||||||
|
<el-radio-button :label="40003">协会报销({{ typeNum.club }})</el-radio-button>
|
||||||
|
</el-radio-group>
|
||||||
|
</template>
|
||||||
|
</table-tool>
|
||||||
|
|
||||||
|
<el-table :data="tableData" style="width: 100%" row-key="id" @sort-change="pageOrder"
|
||||||
|
v-loading="tabLoading">
|
||||||
|
<el-table-column align="center" header-align="center" label="序号" width="120px">
|
||||||
|
<template scope="scope">
|
||||||
|
<span>{{scope.$index+(pageForm.pageNumber - 1) * pageForm.pageSize + 1}} </span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
|
||||||
|
<el-table-column
|
||||||
|
align="center"
|
||||||
|
header-align="center"
|
||||||
|
v-for="column in tableColumns"
|
||||||
|
:label="column.label"
|
||||||
|
:prop="column.prop"
|
||||||
|
:width="column.width"
|
||||||
|
show-overflow-tooltip
|
||||||
|
:sortable="column.sortable">
|
||||||
|
<template v-if="column.prop=='activity_name'" scope="{row}">
|
||||||
|
<el-link type="primary" @click="openView(row)">
|
||||||
|
{{row.activity_name}}
|
||||||
|
</el-link>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template v-else-if="column.prop=='activity_type'" scope="{row}">
|
||||||
|
{{ row.activity_type == 40002 ? "分工会活动" : row.activity_type == 40003 ? "协会活动"
|
||||||
|
: "校工会活动"}}
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template v-else-if="column.prop=='absName'" scope="{row}">
|
||||||
|
{{row.absName}}
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template v-else-if="column.prop=='reimbursement_state_id'" scope="{row}">
|
||||||
|
<span :style="'color:'+row.state_color">{{row.state_name}}</span>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
</el-table-column>
|
||||||
|
|
||||||
|
<el-table-column align="center" header-align="center" label="操作" fixed="right"
|
||||||
|
width="120px">
|
||||||
|
<template slot-scope="{row}">
|
||||||
|
<el-dropdown @command="dropdownCommand">
|
||||||
|
<el-button plain size="mini">
|
||||||
|
<i class="ti-settings"></i>
|
||||||
|
<span class="ti-angle-down"></span>
|
||||||
|
</el-button>
|
||||||
|
<el-dropdown-menu slot="dropdown">
|
||||||
|
<el-dropdown-item :command="{type:'view',data:row}">
|
||||||
|
查看
|
||||||
|
</el-dropdown-item>
|
||||||
|
<el-dropdown-item :command="{type:'exportWwj',data:row,apply_type:1}">
|
||||||
|
导出申请方案表
|
||||||
|
</el-dropdown-item>
|
||||||
|
<el-dropdown-item :command="{type:'exportWwj',data:row,apply_type:2}">
|
||||||
|
导出活动报销凭证
|
||||||
|
</el-dropdown-item>
|
||||||
|
<el-dropdown-item :command="{type:'exportJoinUser',data:row}">
|
||||||
|
导出活动参与人员
|
||||||
|
</el-dropdown-item>
|
||||||
|
<el-dropdown-item :command="{type:'exportFiles',data:row,exportType:'billFiles'}">
|
||||||
|
导出发票
|
||||||
|
</el-dropdown-item>
|
||||||
|
<el-dropdown-item :command="{type:'exportFiles',data:row,exportType:'photoFiles'}">
|
||||||
|
导出活动报道链接/总结/图片
|
||||||
|
</el-dropdown-item>
|
||||||
|
<el-dropdown-item :command="{type:'exportFiles',data:row,exportType:'otherFiles'}">
|
||||||
|
导出奖品/纪念品/服装/道具领用人名单
|
||||||
|
</el-dropdown-item>
|
||||||
|
<el-dropdown-item :command="{type:'exportFiles',data:row,exportType:'all'}">
|
||||||
|
导出全部附件
|
||||||
|
</el-dropdown-item>
|
||||||
|
</el-dropdown-menu>
|
||||||
|
</el-dropdown>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
</el-table>
|
||||||
|
<!--#include("/layouts/pagination.html"){}#-->
|
||||||
|
</el-card>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template #view>
|
||||||
|
<activity-bx-info ref="act_info"></activity-bx-info>
|
||||||
|
</template>
|
||||||
|
</guava>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
const vue = new Vue({
|
||||||
|
el: '#app',
|
||||||
|
mixins: [initTableMixins],
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
pageForm: {
|
||||||
|
year: moment().format('YYYY'),
|
||||||
|
searchName: 'u.username',
|
||||||
|
activityType:0,
|
||||||
|
clubId:''
|
||||||
|
},
|
||||||
|
tabLoading: false,
|
||||||
|
clubOptions: [],
|
||||||
|
unions:[],
|
||||||
|
units:[],
|
||||||
|
tableColumns: [
|
||||||
|
{prop: 'activity_name', label: '活动名称', sortable: true},
|
||||||
|
{prop: 'user_name', label: '申请人姓名', sortable: true},
|
||||||
|
{prop: 'bxr_loginname', label: '申请人工号', sortable: true},
|
||||||
|
{prop: 'unionname', label: '所属工会', sortable: true},
|
||||||
|
{prop: 'unitname', label: '所属单位', sortable: true},
|
||||||
|
{prop: 'clubName', label: '所属协会', sortable: true},
|
||||||
|
{prop: 'activity_type', label: '活动主体类型', sortable: true},
|
||||||
|
{prop: 'absName', label: '活动项目类型', sortable: true},
|
||||||
|
{prop: 'reimbursement_apply_time', label: '申请时间', sortable: true},
|
||||||
|
{prop: 'reimbursement_state_id', label: '申请状态', sortable: true},
|
||||||
|
],
|
||||||
|
formRules:{
|
||||||
|
auditOpinion: [{required: true, message: '请填写意见', trigger: ['change', 'blur']}],
|
||||||
|
auditSign: [{required: true, message: '请签字', trigger: ['change', 'blur']}],
|
||||||
|
},
|
||||||
|
typeNum:{},
|
||||||
|
}
|
||||||
|
},
|
||||||
|
components: {
|
||||||
|
'guava': httpVueLoader('/components/plugins/Guava.vue'),
|
||||||
|
'activity-bx-info': httpVueLoader('/components/activityBx/ActivityBxInfo.vue?v=' + new Date().getTime()),
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
doSearch(){
|
||||||
|
this.getActivityTypeNum();
|
||||||
|
this.pageData()
|
||||||
|
},
|
||||||
|
openView(row) {
|
||||||
|
this.$refs.act_info.getActInfo(row.id)
|
||||||
|
this.$refs.guava.view()
|
||||||
|
},
|
||||||
|
dropdownCommand(command) {
|
||||||
|
const {type, data, apply_type,exportType} = command
|
||||||
|
if (type === "view") {
|
||||||
|
this.openView(data)
|
||||||
|
} else if (type === "edit") {
|
||||||
|
this.openEdit(data)
|
||||||
|
} else if (type === "delete") {
|
||||||
|
this.doDelete(data)
|
||||||
|
} else if (type === "exportWwj") {
|
||||||
|
this.exportWwj(data, apply_type)
|
||||||
|
} else if (type === 'exportFiles'){
|
||||||
|
this.exportAllFiles(data,exportType);
|
||||||
|
} else if (type === 'exportJoinUser'){
|
||||||
|
this.exportJoinUser(data);
|
||||||
|
}
|
||||||
|
},
|
||||||
|
exportJoinUser(row){
|
||||||
|
window.open('/platform/jf/reimbursement/mine/exportActivityJoinUser?id=' + row.id)
|
||||||
|
},
|
||||||
|
exportAllFiles(row,exportType){
|
||||||
|
window.open('/platform/jf/reimbursement/mine/exportAllFiles?id=' + row.id + '&exportType=' + exportType)
|
||||||
|
},
|
||||||
|
exportWwj(row, apply_type) {
|
||||||
|
if (apply_type == 2) {
|
||||||
|
window.location.href = "/platform/jf/activity_bx/reimbursement/doExport?id=" + row.id
|
||||||
|
} else if (apply_type == 1){
|
||||||
|
window.location.href = "/platform/jf/activity_bx/reimbursementview/doExport?id=" + row.id
|
||||||
|
}
|
||||||
|
},
|
||||||
|
async getActivityTypeNum(){
|
||||||
|
const resp = await $.get(loc() + '/getActivityTypeNum',{year:this.pageForm.year})
|
||||||
|
if (resp.code === 0){
|
||||||
|
this.typeNum = resp.data
|
||||||
|
}
|
||||||
|
},
|
||||||
|
async flushUnits() {
|
||||||
|
this.$set(this.pageForm, "unitId", "")
|
||||||
|
if ("${@shiro.hasRole('sysadmin')||@shiro.hasRole('A06')||@shiro.hasRole('H03')}" === 'true') {
|
||||||
|
this.units = await getUnits(this.pageForm.unionId)
|
||||||
|
} else {
|
||||||
|
this.units = await getUnits("${@shiro.getPrincipalProperty('unit').getUnionid()}")
|
||||||
|
}
|
||||||
|
},
|
||||||
|
},
|
||||||
|
async created() {
|
||||||
|
this.pageData()
|
||||||
|
this.clubOptions = await getClubs()
|
||||||
|
this.unions = await getUnions()
|
||||||
|
this.flushUnits()
|
||||||
|
await this.getActivityTypeNum()
|
||||||
|
}
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<!--#
|
||||||
|
}
|
||||||
|
#-->
|
||||||
@@ -0,0 +1,269 @@
|
|||||||
|
<!--#
|
||||||
|
layout("/layouts/platform.html"){
|
||||||
|
#-->
|
||||||
|
|
||||||
|
<div id="app" v-cloak>
|
||||||
|
<guava ref="guava">
|
||||||
|
<template>
|
||||||
|
<el-card shadow="never">
|
||||||
|
<div class="search">
|
||||||
|
<div class="search-item">
|
||||||
|
<div class="search-item-label">年份:</div>
|
||||||
|
<div class="search-item-option">
|
||||||
|
<el-date-picker
|
||||||
|
v-model="pageForm.year"
|
||||||
|
type="year"
|
||||||
|
value-format="yyyy" style="width: 100%"
|
||||||
|
@change="doSearch"
|
||||||
|
placeholder="选择年">
|
||||||
|
</el-date-picker>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="search-item">
|
||||||
|
<div class="search-item-label">姓名工号:</div>
|
||||||
|
<div class="search-item-option">
|
||||||
|
<el-input placeholder="请输入内容" v-model="pageForm.searchKeyword">
|
||||||
|
<el-select v-model="pageForm.searchName" slot="prepend" placeholder="查询类型"
|
||||||
|
style="width: 80px;">
|
||||||
|
<el-option label="工号" value="u.loginname"></el-option>
|
||||||
|
<el-option label="姓名" value="u.username"></el-option>
|
||||||
|
</el-select>
|
||||||
|
</el-input>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="search-item">
|
||||||
|
<div class="search-item-label">所属工会:</div>
|
||||||
|
<div class="search-item-option">
|
||||||
|
<el-select placeholder="所属工会" v-model="pageForm.unionId" style="width: 100%;"
|
||||||
|
clearable="true"
|
||||||
|
@change="flushUnits" @clear="flushUnits"
|
||||||
|
v-if="${@shiro.hasRole('sysadmin')||@shiro.hasRole('A06')||@shiro.hasRole('H03')}"
|
||||||
|
filterable="true">
|
||||||
|
<el-option v-for="item in unions" :label="item.unionname" :value="item.id"></el-option>
|
||||||
|
</el-select>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="search-item">
|
||||||
|
<div class="search-item-label">所属单位:</div>
|
||||||
|
<div class="search-item-option">
|
||||||
|
<el-select placeholder="所属单位" v-model="pageForm.unitId" style="width: 100%;"
|
||||||
|
clearable="true"
|
||||||
|
filterable="true">
|
||||||
|
<el-option v-for="item in units" :label="item.name" :value="item.id"></el-option>
|
||||||
|
</el-select>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="search-query">
|
||||||
|
<el-button type="primary" icon="el-icon-search" @click="doSearch">搜索
|
||||||
|
</el-button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</el-card>
|
||||||
|
|
||||||
|
<el-card shadow="never" class="mt10">
|
||||||
|
|
||||||
|
<table-tool label="审核列表" :app="this">
|
||||||
|
<template #func>
|
||||||
|
<el-radio-group v-model="pageForm.isAudit" @change="doSearch" size="small">
|
||||||
|
<el-radio-button :label="0">全部</el-radio-button>
|
||||||
|
<el-radio-button :label="1">已审核</el-radio-button>
|
||||||
|
<el-radio-button :label="2">未审核</el-radio-button>
|
||||||
|
</el-radio-group>
|
||||||
|
</template>
|
||||||
|
</table-tool>
|
||||||
|
|
||||||
|
<el-table :data="tableData" style="width: 100%" row-key="id" @sort-change="pageOrder"
|
||||||
|
v-loading="tabLoading">
|
||||||
|
<el-table-column align="center" header-align="center" label="序号" width="120px">
|
||||||
|
<template scope="scope">
|
||||||
|
<span>{{scope.$index+(pageForm.pageNumber - 1) * pageForm.pageSize + 1}} </span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
|
||||||
|
<el-table-column
|
||||||
|
align="center"
|
||||||
|
header-align="center"
|
||||||
|
v-for="column in tableColumns"
|
||||||
|
:label="column.label"
|
||||||
|
:prop="column.prop"
|
||||||
|
:width="column.width"
|
||||||
|
show-overflow-tooltip
|
||||||
|
:sortable="column.sortable">
|
||||||
|
<template v-if="column.prop=='activity_name'" scope="{row}">
|
||||||
|
<el-link type="primary" @click="openView(row)">
|
||||||
|
{{row.activity_name}}
|
||||||
|
</el-link>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template v-else-if="column.prop=='activity_type'" scope="{row}">
|
||||||
|
{{ row.activity_type == 40002 ? "分工会活动" : row.activity_type == 40003 ? "协会(协会)活动"
|
||||||
|
: "校工会活动"}}
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template v-else-if="column.prop=='absName'" scope="{row}">
|
||||||
|
{{row.absName}}({{row.projectTypeCode}})
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template v-else-if="column.prop=='reimbursement_state_id'" scope="{row}">
|
||||||
|
<span :style="'color:'+row.state_color">{{row.state_name}}</span>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
</el-table-column>
|
||||||
|
|
||||||
|
<el-table-column align="center" header-align="center" label="操作" fixed="right"
|
||||||
|
width="220px">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<el-button @click="openView(scope.row)" size="mini">查看</el-button>
|
||||||
|
<el-button @click="openAudit(scope.row.id)"
|
||||||
|
v-if="scope.row.reimbursement_state_id == 1010"
|
||||||
|
size="mini" type="primary">审核</el-button>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
</el-table>
|
||||||
|
<!--#include("/layouts/pagination.html"){}#-->
|
||||||
|
</el-card>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template #edit>
|
||||||
|
<activity-bx-info ref="unionChairmanAudit" :handle="true" label="基层工会主席审核" :panes="[8]">
|
||||||
|
<template #handle>
|
||||||
|
<el-form :model="formData" ref="auditForm" :rules="formRules" label-position="right"
|
||||||
|
style="padding: 20px 0"
|
||||||
|
label-width="120px">
|
||||||
|
<el-form-item label="审核信息 " label-width="135px" class="view-header"></el-form-item>
|
||||||
|
|
||||||
|
<el-row gutter="20">
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item prop="username" label="审核人">
|
||||||
|
<el-input v-model="formData.username"
|
||||||
|
disabled></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item prop="time" label="审核时间">
|
||||||
|
<el-input v-model="formData.time" disabled></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
<el-form-item prop="auditOpinion" label="审核意见">
|
||||||
|
<el-input type="textarea" v-model="formData.auditOpinion" rows="4" maxlength="500"
|
||||||
|
placeholder="请填写您的审核意见"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
|
<el-form-item prop="auditSign" label="签  字">
|
||||||
|
<sign prefix="medicalAid" :qz.sync="formData.auditSign"></sign>
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
|
</el-form>
|
||||||
|
|
||||||
|
<div style="float: right;margin: 20px 0">
|
||||||
|
<el-button type="danger" @click="doReview(false)">拒绝</el-button>
|
||||||
|
<el-button type="primary" @click="doReview(true)">通过</el-button>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
</activity-bx-info>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template #view>
|
||||||
|
<activity-bx-info ref="act_info"></activity-bx-info>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
</guava>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
const vue = new Vue({
|
||||||
|
el: '#app',
|
||||||
|
mixins: [initTableMixins],
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
pageForm:{
|
||||||
|
year: moment().format('YYYY'),
|
||||||
|
searchName:'u.username',
|
||||||
|
isAudit:2
|
||||||
|
},
|
||||||
|
tabLoading: false,
|
||||||
|
unions: [],
|
||||||
|
units:[],
|
||||||
|
tableColumns: [
|
||||||
|
{prop: 'activity_name', label: '活动名称', sortable: true},
|
||||||
|
{prop: 'user_name', label: '申请人姓名', sortable: true},
|
||||||
|
{prop: 'bxr_loginname', label: '申请人工号', sortable: true},
|
||||||
|
{prop: 'unionname', label: '所属工会', sortable: true},
|
||||||
|
{prop: 'unitname', label: '所属单位', sortable: true},
|
||||||
|
{prop: 'activity_type', label: '活动主体类型', sortable: true},
|
||||||
|
{prop: 'absName', label: '活动项目类型', sortable: true},
|
||||||
|
{prop: 'reimbursement_apply_time', label: '申请时间', sortable: true},
|
||||||
|
{prop: 'reimbursement_state_id', label: '申请状态', sortable: true},
|
||||||
|
],
|
||||||
|
formRules:{
|
||||||
|
auditOpinion: [{required: true, message: '请填写意见', trigger: ['change', 'blur']}],
|
||||||
|
auditSign: [{required: true, message: '请签字', trigger: ['change', 'blur']}],
|
||||||
|
},
|
||||||
|
id:''
|
||||||
|
}
|
||||||
|
},
|
||||||
|
components: {
|
||||||
|
'guava': httpVueLoader('/components/plugins/Guava.vue'),
|
||||||
|
'activity-bx-info': httpVueLoader('/components/activityBx/ActivityBxInfo.vue?v=' + new Date().getTime()),
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
openView(row) {
|
||||||
|
this.$refs.act_info.getActInfo(row.id)
|
||||||
|
this.$refs.guava.view()
|
||||||
|
},
|
||||||
|
openAudit(id) {
|
||||||
|
this.id = id
|
||||||
|
this.formData = {
|
||||||
|
username: "${@shiro.getPrincipalProperty('username')}",
|
||||||
|
time: moment().format('YYYY-MM-DD'),
|
||||||
|
}
|
||||||
|
this.$refs.unionChairmanAudit.getActInfo(id)
|
||||||
|
this.$refs.guava.edit()
|
||||||
|
},
|
||||||
|
async doReview(row){
|
||||||
|
const valid = await this.$refs['auditForm'].validate()
|
||||||
|
if (!valid) return
|
||||||
|
if (this.formData.auditSign == null){
|
||||||
|
this.$message.warning("请扫码签字!")
|
||||||
|
return
|
||||||
|
}
|
||||||
|
this.formData.auditPass = row
|
||||||
|
// 确定要拒绝/通过吗?
|
||||||
|
this.$confirm('确定要' + (row ? '通过' : '拒绝') + '吗?', '提示', {
|
||||||
|
confirmButtonText: '确定',
|
||||||
|
cancelButtonText: '取消',
|
||||||
|
type: 'warning'
|
||||||
|
}).then(async () => {
|
||||||
|
const resp = await $.post(loc() + '/doAuditing', {
|
||||||
|
id:this.id,
|
||||||
|
audit:JSON.stringify(this.formData)
|
||||||
|
})
|
||||||
|
if (resp.code === 0) {
|
||||||
|
this.$refs.guava.index()
|
||||||
|
this.notifySuccess(resp.msg)
|
||||||
|
this.pageData()
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
|
async flushUnits() {
|
||||||
|
this.$set(this.pageForm, "unitId", "")
|
||||||
|
if ("${@shiro.hasRole('sysadmin')||@shiro.hasRole('A06')||@shiro.hasRole('H03')}" === 'true') {
|
||||||
|
this.units = await getUnits(this.pageForm.unionId)
|
||||||
|
} else {
|
||||||
|
this.units = await getUnits("${@shiro.getPrincipalProperty('unit').getUnionid()}")
|
||||||
|
}
|
||||||
|
},
|
||||||
|
},
|
||||||
|
async created() {
|
||||||
|
this.pageData()
|
||||||
|
this.unions = await getUnions()
|
||||||
|
this.flushUnits()
|
||||||
|
}
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<!--#
|
||||||
|
}
|
||||||
|
#-->
|
||||||
@@ -524,8 +524,12 @@ layout("/layouts/platform.html"){
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
viewSubsidyProgramme() {
|
viewSubsidyProgramme() {
|
||||||
let pdfStreamUrl = encodeURIComponent(FILE_STREAM_PREVIEW_ADDRESS + '?id=cad5418aafd749b68c59946589dda6f0') //将路径转码
|
window.open(
|
||||||
this.subsidyProgrammeUrl = '/assets/platform/plugins/pdfJs/web/viewer.html?file=' + pdfStreamUrl
|
"/assets/platform/plugins/pdfJs/web/viewer.html?file=" + encodeURIComponent("/platform/sys/file/convertPDF?id=" + "cad5418aafd749b68c59946589dda6f0"),
|
||||||
|
"123"
|
||||||
|
)
|
||||||
|
// let pdfStreamUrl = encodeURIComponent(FILE_STREAM_PREVIEW_ADDRESS + '?id=cad5418aafd749b68c59946589dda6f0') //将路径转码
|
||||||
|
// this.subsidyProgrammeUrl = '/assets/platform/plugins/pdfJs/web/viewer.html?file=' + pdfStreamUrl
|
||||||
this.subsidyProgrammeDialogVisible = true
|
this.subsidyProgrammeDialogVisible = true
|
||||||
},
|
},
|
||||||
subsidyTypeChange(val) {
|
subsidyTypeChange(val) {
|
||||||
@@ -548,4 +552,4 @@ layout("/layouts/platform.html"){
|
|||||||
|
|
||||||
<!--#
|
<!--#
|
||||||
}
|
}
|
||||||
#-->
|
#-->
|
||||||
|
|||||||
@@ -128,8 +128,12 @@ layout("/layouts/platform.html"){
|
|||||||
showDoc(row) {
|
showDoc(row) {
|
||||||
if(row.replaceReport) {
|
if(row.replaceReport) {
|
||||||
const file = JSON.parse(row.replaceReport)
|
const file = JSON.parse(row.replaceReport)
|
||||||
let pdfStreamUrl = encodeURIComponent(FILE_STREAM_PREVIEW_ADDRESS + '?id=' + file[0].id) //将路径转码
|
window.open(
|
||||||
window.open('/assets/platform/plugins/pdfJs/web/viewer.html?file=' + pdfStreamUrl, file[0].filename)
|
"/assets/platform/plugins/pdfJs/web/viewer.html?file=" + encodeURIComponent("/platform/sys/file/convertPDF?id=" + file[0].id),
|
||||||
|
file[0].filename
|
||||||
|
)
|
||||||
|
// let pdfStreamUrl = encodeURIComponent(FILE_STREAM_PREVIEW_ADDRESS + '?id=' + file[0].id) //将路径转码
|
||||||
|
// window.open('/assets/platform/plugins/pdfJs/web/viewer.html?file=' + pdfStreamUrl, file[0].filename)
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
getFileName(row) {
|
getFileName(row) {
|
||||||
|
|||||||
@@ -136,8 +136,12 @@ layout("/layouts/platform.html"){
|
|||||||
showDoc(row) {
|
showDoc(row) {
|
||||||
if(row.afterRulesFile) {
|
if(row.afterRulesFile) {
|
||||||
const file = JSON.parse(row.afterRulesFile)
|
const file = JSON.parse(row.afterRulesFile)
|
||||||
let pdfStreamUrl = encodeURIComponent(FILE_STREAM_PREVIEW_ADDRESS + '?id=' + file[0].id) //将路径转码
|
window.open(
|
||||||
window.open('/assets/platform/plugins/pdfJs/web/viewer.html?file=' + pdfStreamUrl, file[0].filename)
|
"/assets/platform/plugins/pdfJs/web/viewer.html?file=" + encodeURIComponent("/platform/sys/file/convertPDF?id=" + file[0].id),
|
||||||
|
file[0].filename
|
||||||
|
)
|
||||||
|
// let pdfStreamUrl = encodeURIComponent(FILE_STREAM_PREVIEW_ADDRESS + '?id=' + file[0].id) //将路径转码
|
||||||
|
// window.open('/assets/platform/plugins/pdfJs/web/viewer.html?file=' + pdfStreamUrl, file[0].filename)
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
getFileName(row) {
|
getFileName(row) {
|
||||||
|
|||||||
@@ -144,8 +144,12 @@ layout("/layouts/platform.html"){
|
|||||||
showDoc(row) {
|
showDoc(row) {
|
||||||
if(row.afterRulesFile) {
|
if(row.afterRulesFile) {
|
||||||
const file = JSON.parse(row.afterRulesFile)
|
const file = JSON.parse(row.afterRulesFile)
|
||||||
let pdfStreamUrl = encodeURIComponent(FILE_STREAM_PREVIEW_ADDRESS + '?id=' + file[0].id) //将路径转码
|
window.open(
|
||||||
window.open('/assets/platform/plugins/pdfJs/web/viewer.html?file=' + pdfStreamUrl, file[0].filename)
|
"/assets/platform/plugins/pdfJs/web/viewer.html?file=" + encodeURIComponent("/platform/sys/file/convertPDF?id=" + file[0].id),
|
||||||
|
file[0].filename
|
||||||
|
)
|
||||||
|
// let pdfStreamUrl = encodeURIComponent(FILE_STREAM_PREVIEW_ADDRESS + '?id=' + file[0].id) //将路径转码
|
||||||
|
// window.open('/assets/platform/plugins/pdfJs/web/viewer.html?file=' + pdfStreamUrl, file[0].filename)
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
getFileName(row) {
|
getFileName(row) {
|
||||||
|
|||||||
@@ -221,6 +221,96 @@ layout("/layouts/platform.html"){
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div v-if="checkNode.level===2" style="padding:0 10px">
|
<div v-if="checkNode.level===2" style="padding:0 10px">
|
||||||
|
<el-card shadow="never">
|
||||||
|
<div class="btn-group tool-button mt5">
|
||||||
|
<el-input placeholder="请输入内容" clearable v-model="page2Form.searchKeyword"
|
||||||
|
@keyup.enter.native="doSearch">
|
||||||
|
<el-select v-model="page2Form.searchName" slot="prepend" placeholder="查询类型"
|
||||||
|
style="width: 120px;">
|
||||||
|
<el-option label="单位名称" value="name"></el-option>
|
||||||
|
<el-option label="单位代码" value="unitcode"></el-option>
|
||||||
|
</el-select>
|
||||||
|
</el-input>
|
||||||
|
</div>
|
||||||
|
<div class="btn-group tool-button mt5">
|
||||||
|
<el-button type="primary" icon="el-icon-search" @click="do2Search"></el-button>
|
||||||
|
</div>
|
||||||
|
</el-card>
|
||||||
|
|
||||||
|
<el-card shadow="never" class="mt10">
|
||||||
|
<el-table :data="table2Data" style="width: 100%" row-key="id"
|
||||||
|
key="level2Table"
|
||||||
|
@sort-change="(column)=>{page2Form.pageOrderName = column.prop;page2Form.pageOrderBy = column.order;page2Data()}"
|
||||||
|
ref="firstTable"
|
||||||
|
:height="firstTableHeight">
|
||||||
|
<el-table-column align="center" :key="1" header-align="center" label="序号" type="index">
|
||||||
|
<template scope="scope">
|
||||||
|
<span>{{scope.$index+(page2Form.pageNumber - 1) * page2Form.pageSize + 1}} </span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
|
||||||
|
<el-table-column align="center" header-align="center" label="单位名称"
|
||||||
|
prop="name"></el-table-column>
|
||||||
|
|
||||||
|
<el-table-column align="center" header-align="center" label="单位代码"
|
||||||
|
prop="unitcode"></el-table-column>
|
||||||
|
|
||||||
|
<el-table-column label="单位等级" header-align="center" prop="unitlevel"
|
||||||
|
:show-overflow-tooltip="true" align="center">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<el-button v-if="scope.row.unitlevel==1" size="mini" type="success" round
|
||||||
|
style=" vertical-align: middle;">1级
|
||||||
|
</el-button>
|
||||||
|
<el-button v-if="scope.row.unitlevel==2" size="mini" type="warning" round
|
||||||
|
style=" vertical-align: middle;">2级
|
||||||
|
</el-button>
|
||||||
|
<el-button v-if="scope.row.unitlevel==3" size="mini" type="danger" round
|
||||||
|
style=" vertical-align: middle;">3级
|
||||||
|
</el-button>
|
||||||
|
<el-button v-if="scope.row.unitlevel>3" size="mini" type="info" round
|
||||||
|
style=" vertical-align: middle;">{{scope.row.unitlevel}}级
|
||||||
|
</el-button>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
|
||||||
|
<el-table-column align="center" header-align="center" prop="operating" label="操作"
|
||||||
|
width="200px">
|
||||||
|
<template slot-scope="{row}">
|
||||||
|
<el-dropdown @command="dropdownCommand">
|
||||||
|
<el-button size="mini">
|
||||||
|
<i class="ti-settings"></i>
|
||||||
|
<span class="ti-angle-down"></span>
|
||||||
|
</el-button>
|
||||||
|
<el-dropdown-menu slot="dropdown">
|
||||||
|
<el-dropdown-item :command="{type:'edit',data:row}">
|
||||||
|
编辑
|
||||||
|
</el-dropdown-item>
|
||||||
|
|
||||||
|
<el-dropdown-item :command="{type:'delete',data:row}">
|
||||||
|
删除
|
||||||
|
</el-dropdown-item>
|
||||||
|
|
||||||
|
</el-dropdown-menu>
|
||||||
|
</el-dropdown>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
|
||||||
|
</el-table>
|
||||||
|
<el-row class="el-pagination-container">
|
||||||
|
<el-pagination
|
||||||
|
@size-change="(val)=>{page2Form.pageSize = val;page2Data()}"
|
||||||
|
@current-change="(val)=>{page2Form.pageNumber = val;page2Data()}"
|
||||||
|
:current-page="page2Form.pageNumber"
|
||||||
|
:page-sizes="[10, 20, 30, 50]"
|
||||||
|
:page-size="page2Form.pageSize"
|
||||||
|
layout="total, sizes, prev, pager, next"
|
||||||
|
:total="page2Form.totalCount">
|
||||||
|
</el-pagination>
|
||||||
|
</el-row>
|
||||||
|
</el-card>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div v-if="checkNode.level===3" style="padding:0 10px">
|
||||||
<el-card shadow="never">
|
<el-card shadow="never">
|
||||||
<div class="btn-group tool-button mt5">
|
<div class="btn-group tool-button mt5">
|
||||||
<el-input placeholder="请输入内容" clearable
|
<el-input placeholder="请输入内容" clearable
|
||||||
@@ -278,7 +368,7 @@ layout("/layouts/platform.html"){
|
|||||||
<el-card shadow="never" class="mt10">
|
<el-card shadow="never" class="mt10">
|
||||||
<el-tabs v-model="secondaryTabActiveName" type="card"
|
<el-tabs v-model="secondaryTabActiveName" type="card"
|
||||||
@tab-click="secondaryDataSearch()">
|
@tab-click="secondaryDataSearch()">
|
||||||
<el-tab-pane label="三级单位" name="thirdLevelUnit"></el-tab-pane>
|
<el-tab-pane label="下属单位" name="thirdLevelUnit"></el-tab-pane>
|
||||||
<el-tab-pane label="单位人员" name="unitPersonnel"></el-tab-pane>
|
<el-tab-pane label="单位人员" name="unitPersonnel"></el-tab-pane>
|
||||||
<el-tab-pane label="单位负责人" name="unitLeader"></el-tab-pane>
|
<el-tab-pane label="单位负责人" name="unitLeader"></el-tab-pane>
|
||||||
<el-tab-pane label="单位分管校领导" name="unitSchoolLeader"></el-tab-pane>
|
<el-tab-pane label="单位分管校领导" name="unitSchoolLeader"></el-tab-pane>
|
||||||
@@ -413,7 +503,7 @@ layout("/layouts/platform.html"){
|
|||||||
</el-card>
|
</el-card>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div v-if="checkNode.level===3" style="padding: 0 10px">
|
<div v-if="checkNode.level===4" style="padding: 0 10px">
|
||||||
<el-card shadow="never">
|
<el-card shadow="never">
|
||||||
<div class="btn-group tool-button mt5">
|
<div class="btn-group tool-button mt5">
|
||||||
<el-input placeholder="请输入内容" clearable
|
<el-input placeholder="请输入内容" clearable
|
||||||
@@ -700,8 +790,19 @@ layout("/layouts/platform.html"){
|
|||||||
|
|
||||||
otherRoleDialogVisible: false,
|
otherRoleDialogVisible: false,
|
||||||
transferLeftOtherRoleUsers: [],
|
transferLeftOtherRoleUsers: [],
|
||||||
otherUsers: []
|
otherUsers: [],
|
||||||
|
|
||||||
|
page2Form: {
|
||||||
|
searchName: "name",
|
||||||
|
searchKeyword: "",
|
||||||
|
pageNumber: 1,
|
||||||
|
pageSize: 10,
|
||||||
|
totalCount: 0,
|
||||||
|
pageOrderName: "",
|
||||||
|
pageOrderBy: ""
|
||||||
|
},
|
||||||
|
table2Data: [],
|
||||||
|
tab2Key: '',
|
||||||
|
|
||||||
// unitPublicUsers: [],
|
// unitPublicUsers: [],
|
||||||
// unitAdminUsers: [],
|
// unitAdminUsers: [],
|
||||||
@@ -855,8 +956,10 @@ layout("/layouts/platform.html"){
|
|||||||
if (node.level === 1) {
|
if (node.level === 1) {
|
||||||
this.doSearch()
|
this.doSearch()
|
||||||
} else if (node.level === 2) {
|
} else if (node.level === 2) {
|
||||||
this.secondaryDataSearch()
|
this.do2Search()
|
||||||
} else if (node.level === 3) {
|
} else if (node.level === 3) {
|
||||||
|
this.secondaryDataSearch()
|
||||||
|
} else if (node.level === 4) {
|
||||||
this.thirdPageData()
|
this.thirdPageData()
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@@ -953,6 +1056,11 @@ layout("/layouts/platform.html"){
|
|||||||
this.pageForm.pageNumber = 1
|
this.pageForm.pageNumber = 1
|
||||||
this.pageData()
|
this.pageData()
|
||||||
},
|
},
|
||||||
|
do2Search() {
|
||||||
|
this.tab2Key = new Date().getTime()
|
||||||
|
this.page2Form.pageNumber = 1
|
||||||
|
this.page2Data()
|
||||||
|
},
|
||||||
pageData() {//加载分页数据
|
pageData() {//加载分页数据
|
||||||
sublime.showLoadingbar();//显示loading
|
sublime.showLoadingbar();//显示loading
|
||||||
this.tabLoading = true
|
this.tabLoading = true
|
||||||
@@ -971,6 +1079,24 @@ layout("/layouts/platform.html"){
|
|||||||
}
|
}
|
||||||
}, "json");
|
}, "json");
|
||||||
},
|
},
|
||||||
|
page2Data() {//加载分页数据
|
||||||
|
sublime.showLoadingbar();//显示loading
|
||||||
|
this.tabLoading = true
|
||||||
|
this.page2Form.parentId = this.checkData.id
|
||||||
|
$.post(base + "/platform/sys/unit/pageData", this.page2Form, (data) => {
|
||||||
|
sublime.closeLoadingbar();//关闭loading
|
||||||
|
this.tabLoading = false
|
||||||
|
if (data.code == 0) {
|
||||||
|
this.table2Data = data.data.list;
|
||||||
|
this.page2Form.totalCount = data.data.totalCount;
|
||||||
|
} else {
|
||||||
|
this.$message({
|
||||||
|
message: data.msg,
|
||||||
|
type: 'error'
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}, "json");
|
||||||
|
},
|
||||||
async loadTree(flush) {
|
async loadTree(flush) {
|
||||||
this.treeLoading = true
|
this.treeLoading = true
|
||||||
const {code, data, msg} = await $.get("/platform/sys/unit/getUnitTreeData")
|
const {code, data, msg} = await $.get("/platform/sys/unit/getUnitTreeData")
|
||||||
|
|||||||
Reference in New Issue
Block a user