feat(dailyApplication): 移除日常申请模块

This commit is contained in:
woody 2025-05-14 19:52:25 +08:00
parent f928104906
commit a6efada35b
3 changed files with 1 additions and 1032 deletions

View File

@ -186,20 +186,7 @@ export const constantRoutes = [
meta: { title: '订单业务' },
hidden: true
},
{
path: 'dailyApplication',
name: 'DailyApplication',
component: () => import('@/views/information/business/dailyApplication/index'),
meta: { title: '日常申请' },
hidden: true
},
{
path: 'dailyZxqc',
name: 'DailyZxqc',
component: () => import('@/views/information/business/dailyApplication/dailyZxqc'),
meta: { title: '日常申请' },
hidden: true
},
{
path: 'shyw',
name: 'ReviewBusiness',

View File

@ -1,497 +0,0 @@
<template>
<div class="page">
<topBar
v-if="topList.length > 0"
:topList="topList"
:moren="moren"
></topBar>
<div class="main">
<div class="thetable">
<div class="fontTitle">{{ '在线签呈' }}</div>
<div class="titleflex">
<div>{{ '编号' }} :</div>
<div>
<el-radio-group v-model="allData.signType">
<el-radio
:label="ctem.value"
v-for="ctem in checkList"
:key="ctem.value"
>{{ ctem.label }}</el-radio
>
</el-radio-group>
</div>
</div>
<el-form
ref="form"
:model="allData.signData"
:rules="rules"
label-width="auto"
>
<table id="tfhover" class="tftable" border="1">
<tr>
<td colspan="1" width="190px" align="center">
{{ '发起部门' }} :
</td>
<td colspan="1" v-if="allData.signData" width="435px">
{{ allData.signData.deptName }}
</td>
<td colspan="1" width="140px" align="center">
{{ '发起人' }} :
</td>
<td colspan="1" v-if="allData.signData">
{{ allData.signData.userName }}
</td>
</tr>
<tr>
<td colspan="1" align="center">{{ '主旨' }} :</td>
<td colspan="1">
<el-form-item label="" prop="approvalBusinessVal">
<el-input
v-model="allData.signData.approvalBusinessVal"
></el-input>
</el-form-item>
</td>
<td colspan="1" align="center">{{ '日期' }} :</td>
<td colspan="1">{{ allData.signData.creationTime }}</td>
</tr>
<!-- // -->
<tr>
<td colspan="1" align="center">{{ '审批流程' }}</td>
<td colspan="3">
<div class="disflex">
<span
v-for="(ctem, cndex) in allData.signData.detailList"
style="margin: 0 5px 5px 0"
>
<el-select
v-model="ctem.pkApprover"
filterable
size="mini"
@change="getApprover"
:placeholder="'请选择'"
>
<el-option
v-for="item in approbalList"
:key="item.userId"
:label="item.nickName + '(' + item.deptName + ')'"
:value="item.userId"
>
</el-option>
</el-select>
</span>
<span style="margin: 0 5px 5px 0">
<i
class="el-icon-remove-outline"
v-show="allData.signData.detailList.length > 0"
@click.stop="delData"
style="font-size: 18px; margin-right: 5px"
></i>
<i
class="el-icon-circle-plus-outline"
style="font-size: 18px"
@click.stop="addData"
></i>
</span>
</div>
</td>
</tr>
<tr>
<td colspan="1" align="center">{{ '抄送人' }}</td>
<td colspan="3">
<div class="disflex">
<span
v-for="(ctem, cndex) in allData.signData.sendList"
style="margin: 0 5px 5px 0"
>
<el-select
v-model="ctem.pkSend"
filterable
size="mini"
@change="getApprover"
:placeholder="'请选择'"
>
<el-option
v-for="item in userAllList"
:key="item.userId"
:label="item.nickName + '(' + item.deptName + ')'"
:value="item.userId"
>
</el-option>
</el-select>
</span>
<span style="margin: 0 5px 5px 0">
<i
class="el-icon-remove-outline"
@click.stop="delData1"
v-show="allData.signData.sendList.length > 0"
style="font-size: 18px; margin-right: 5px"
></i>
<i
class="el-icon-circle-plus-outline"
style="font-size: 18px"
@click.stop="addData1"
></i>
</span>
</div>
</td>
</tr>
<tr>
<td style="height: 190px" align="center">{{ '情况说明' }}</td>
<td colspan="3" style="padding: 0">
<el-form-item label="" prop="remark">
<el-input
type="textarea"
:rows="6"
:placeholder="'请输入'"
v-model="allData.signData.remark"
>
</el-input>
</el-form-item>
</td>
</tr>
<tr>
<td style="height: 190px" align="center">
{{ '附件' }}
</td>
<td colspan="3" style="padding: 0">
<div style="height: 100%; padding: 10px 20px">
<el-upload
class="upload-demo"
:action="uploadImgUrl"
:on-preview="handlePreview"
:on-success="handleUploadSuccess"
:on-remove="removeFile"
multiple
:headers="headers"
:file-list="fileList"
>
<el-button size="small" type="primary">{{
'点击上传'
}}</el-button>
</el-upload>
</div>
</td>
</tr>
</table>
</el-form>
</div>
</div>
<div class="footer">
<div style="margin: 0 auto">
<el-button class="thebtn" @click="cancelCz">
{{ '取消' }}</el-button
>
<el-button type="primary" class="thebtn" @click="saveDate(0)">
{{ '确认' }}</el-button
>
<el-button type="warning" class="thebtn" @click="saveDate(1)"
>暂存</el-button
>
</div>
</div>
</div>
</template>
<script>
import topBar from "@/components/topBar";
import * as man from "@/api/manage";
import onlineSign from "@/views/dashboard/onlineSign.json";
import { getToken } from "@/utils/auth";
export default {
name: "Zxqc",
components: {
topBar,
},
data() {
return {
uploadImgUrl: process.env.VUE_APP_BASE_API + "/system/upload", //
headers: {
Authorization: getToken(),
},
onlineSign,
moren: "dailyZxqc",
topList: [
{
name: '在线签呈',
path: "dailyZxqc",
},
],
checkList: [],
allData: {
remark: "",
signType: 1,
fileList: [],
signData: {
detailList: [],
sendList: [],
},
},
fileList: [],
//
approbalList: [],
userAllList: [],
toRemark: false,
approvalCode: "",
pkId: "",
rules: {
approvalBusinessVal: [
{ required: true, message: "请输入", trigger: "blur" },
],
remark: [{ required: true, message: "请输入", trigger: "blur" }],
},
};
},
mounted() {
this.approvalCode = this.$route.query.id;
this.toRemark = this.$route.query.toRemark || false;
this.getSignData([0]);
if (this.approvalCode) {
this.getDetails();
}
},
methods: {
getDetails() {
man.approvalDetails(this.approvalCode).then((res) => {
res.data.detailList.forEach((item,index) => {
item.pkApprover = res.data.detailIdList[index];
});
if(res.data.filePathList){
res.data.filePathList.forEach((item) => {
this.fileList.push({
name: item,
url: item,
});
});
}
this.allData.signData = res.data;
this.pkId = res.data.pkId;
});
},
getSignData(arr) {
man.signData(arr).then((res) => {
this.allData.signData = res.data[0];
//
this.$set(this.allData, "signType", 1);
this.$set(this.allData, "remark", "");
this.$set(this.allData, "fileList", []);
this.$forceUpdate();
this.getApprove();
this.getSignType();
});
},
getApprove() {
//
man.usualApprovalUser().then((res) => {
this.approbalList = res.data;
});
man.userAll().then((res) => {
this.userAllList = res.data;
});
},
getSignType() {
man.signType().then((res) => {
this.checkList = res.data;
});
},
saveDate(index) {
this.$refs["form"].validate((valid) => {
if (valid) {
//
this.allData.userIdList = this.allData.signData.detailList.map(
(item) => {
return item.pkApprover;
}
);
this.allData.userIdList = this.allData.userIdList.filter(
(item) => item
);
//
this.allData.sendIdList = this.allData.signData.sendList.map(
(item) => {
return item.pkSend;
}
);
this.allData.sendIdList = this.allData.sendIdList.filter(
(item) => item
);
this.allData.fileList = this.fileList.map((item) => {
return item.url;
});
if (this.allData.userIdList.length == 0) {
this.$message({
type: "warning",
message: "请选择审批流程",
});
return false;
}
let obj = {
userIdList: this.allData.userIdList,
approvalBusinessVal: this.allData.signData.approvalBusinessVal,
signType: this.allData.signType,
remark: this.allData.signData.remark,
fileList: this.allData.fileList,
sendIdList: this.allData.sendIdList,
};
if (this.toRemark) {
} else {
if (this.pkId) {
obj = Object.assign({}, obj, { pkId: this.pkId });
}
}
let url;
if (index == 0) {
url = man.submitCustom;
} else {
url = man.stagingCustom;
}
url(obj).then((res) => {
if (res.code == 200) {
this.$message({
message: res.msg,
type: "success",
});
this.cancelCz();
}
});
}
});
},
cancelCz() {
this.$router.go(-1);
},
//
getApprover() {
this.$nextTick(() => {
this.$forceUpdate();
});
},
//
addData() {
let arr = JSON.parse(JSON.stringify(this.allData.signData.detailList));
arr.push({
pkApprover: "",
});
this.$set(this.allData.signData, "detailList", arr);
this.$forceUpdate();
},
//
delData() {
this.allData.signData.detailList.pop();
this.$forceUpdate();
},
//
addData1() {
let arr = JSON.parse(JSON.stringify(this.allData.signData.sendList));
arr.push({
pkSend: "",
});
this.$set(this.allData.signData, "sendList", arr);
this.$forceUpdate();
},
//
delData1() {
this.allData.signData.sendList.pop();
this.$forceUpdate();
},
handleUploadSuccess(res) {
if (res.code == 200) {
this.fileList.push(res.data);
} else {
this.$message({
type: "error",
message: '上传失败',
});
}
},
handlePreview(res) {
window.open(res.url);
},
removeFile(file, fileList) {
this.fileList.forEach((item, index) => {
if (file.uid == item.uid) {
this.fileList.splice(index, 1);
}
});
},
},
};
</script>
<style lang="scss" scoped>
::v-deep .el-table thead {
color: #000000;
}
.page {
padding: 20px;
background: #f9f9f9;
font-size: 14px;
.main {
// margin-top: 20px;
background: #ffffff;
border-radius: 8px;
box-shadow: 0px 2px 20px 0px rgba(238, 238, 238, 0.5);
display: flex;
margin: 0 auto;
width: 100%;
padding: 20px;
flex-direction: column;
}
.thetable {
margin: 0 auto;
margin-bottom: 20px;
.fontTitle {
font-weight: bold;
font-size: 24px;
text-align: center;
}
.titleflex {
display: flex;
margin-top: 10px;
margin-bottom: 10px;
justify-content: space-between;
}
}
.tftable {
font-size: 14px;
border-collapse: collapse;
border-radius: 10px;
width: 1060px;
border: 1px solid #cccccc;
.spbox {
display: flex;
align-items: center;
justify-content: flex-end;
}
th {
font-size: 14px;
// padding: 20px;
}
tr td {
font-size: 14px;
padding: 20px;
height: 60px;
}
}
.footer {
display: flex;
justify-content: center;
align-items: center;
padding: 15px 0;
.thebtn {
width: 120px;
height: 38px;
}
}
}
//
.disflex {
display: flex;
align-items: center;
flex-wrap: wrap;
}
::v-deep .el-upload-list__item:hover {
background-color: #f5f7fa !important;
}
</style>

View File

@ -1,521 +0,0 @@
<!--
* @Descripttion:
* @version:
* @Author: kBank
* @Date: 2023-03-21 17:14:47
-->
<!--
* @Descripttion:
* @version:
* @Author: kBank
* @Date: 2022-10-24 10:45:39
-->
<template>
<div class="page">
<topBar
v-if="topList.length > 0"
:topList="topList"
:moren="moren"
></topBar>
<div class="main">
<div class="form_all">
<el-form ref="select" :model="select" label-width="auto">
<el-row :gutter="10">
<el-col :span="4">
<el-form-item label="签呈标题">
<el-input
clearable
v-model="select.approvalBusinessVal"
:placeholder="'请输入'"
></el-input>
</el-form-item>
</el-col>
<el-col :span="4">
<el-form-item :label="'签呈状态'">
<el-select clearable v-model="select.approveStatus">
<el-option
v-for="item in approveStatusList"
:key="item.value"
:label="item.label"
:value="item.value"
></el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item :label="'创建日期'">
<el-date-picker
v-model="select.creationTime"
value-format="yyyy-MM-dd"
type="daterange"
:range-separator="'至'"
:start-placeholder="'开始日期'"
:end-placeholder="'结束日期'"
>
</el-date-picker>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item :label="'终审日期'">
<el-date-picker
v-model="select.endTime"
value-format="yyyy-MM-dd"
type="daterange"
:range-separator="'至'"
:start-placeholder="'开始日期'"
:end-placeholder="'结束日期'"
>
</el-date-picker>
</el-form-item>
</el-col>
<el-col :span="4">
<el-button type="primary" @click="getDataList">
{{ '搜索' }}</el-button
>
<el-button type="primary" class="resetBtn" @click="reset">
{{ '重置' }}</el-button
>
</el-col>
</el-row>
</el-form>
</div>
<div class="main_a">
<div class="mainbtn">
<el-button
size="small"
v-hasButtons="['DailyZxqc']"
@click="toZxqc"
type="primary"
>发起签呈</el-button
>
<el-button
size="small"
v-hasButtons="['DailyExport']"
@click="handleExport"
class="exportBtn"
>
{{ '导出' }}</el-button
>
</div>
</div>
<el-table
:data="tableData1"
style="width: 100%"
height="100%"
:header-cell-style="{ background: '#EEEEEE' }"
:row-class-name="tableRowClassName"
>
<el-table-column
align="center"
prop="approvalBusinessVal"
label="签呈标题"
>
</el-table-column>
<el-table-column align="center" prop="remark" label="情况说明">
</el-table-column>
<el-table-column
align="center"
:min-width="200"
prop="parentClassifyName"
:label="'签呈进度'"
>
<template slot-scope="scope">
<div class="bz_a">
<div
class="bz_i"
v-for="(item, index) in scope.row.detailList"
:key="index"
>
<div :class="item.useTime == undefined ? 'qiu' : 'quan'"></div>
<div
:class="
scope.row.detailList[index + 1].useTime == undefined
? 'gun1'
: 'gun'
"
v-if="index != scope.row.detailList.length - 1"
></div>
<div class="zhi">
<div>{{ item.nickName }}</div>
<div>({{ item.deptName }})</div>
</div>
</div>
</div>
</template>
</el-table-column>
<el-table-column
align="center"
prop="approveStatusVal"
:label="'签呈状态'"
>
</el-table-column>
<el-table-column
align="center"
prop="creationTime"
:label="'创建日期'"
>
</el-table-column>
<el-table-column align="center" prop="endTime" :label="'终审日期'">
</el-table-column>
<el-table-column
align="center"
prop="time"
:label="'操作'"
fixed="right"
>
<template slot-scope="scope">
<div style="display: flex; justify-content: center">
<el-button
v-if="scope.row.approveStatus == 4"
@click="toRemark(scope.row.approvalCode)"
type="text"
v-hasButtons="['DailySee']"
size="small"
>
重启
</el-button>
<el-button
v-if="scope.row.approveStatus == 4"
@click="toDestroy(scope.row.pkId)"
type="text"
v-hasButtons="['DailySee']"
size="small"
>
作废
</el-button>
<el-button
v-if="scope.row.approveStatus == 0"
@click="toFixed(scope.row.approvalCode)"
type="text"
v-hasButtons="['DailySee']"
size="small"
>
修改
</el-button>
<el-button
v-if="scope.row.approveStatus == 2"
@click="toBack(scope.row.pkId)"
type="text"
v-hasButtons="['DailySee']"
size="small"
>
撤回
</el-button>
<el-button
@click="toSee(scope.row.approvalCode, 1)"
type="text"
v-hasButtons="['DailySee']"
size="small"
>
{{ '查看签呈' }}
</el-button>
<!-- <el-button @click="toFixed(scope.row.approvalCode,1)"
type="text"
v-hasButtons="['DailyPrint']"
size="small">
{{'打印'}}
</el-button> -->
</div>
</template>
</el-table-column>
</el-table>
<pagination
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getDataList"
/>
</div>
</div>
</template>
<script>
import { mapGetters } from "vuex";
import * as api from "@/api/manage.js";
import topBar from "@/components/topBar";
export default {
name: "Dashboard",
components: {
topBar,
},
computed: {
...mapGetters(["name"]),
},
data() {
return {
queryParams: {
pageNum: 1,
pageSize: 50,
},
total: 0,
tableData: [],
tableData1: [],
tabActive: 0,
select: {},
moren: "dailyApplication",
topList: [
{
name: "日常申请",
path: "dailyApplication",
},
],
ywsqList: [],
sourceList: [],
approveStatusList: [],
};
},
mounted() {
//
this.getDataList();
this.getApprovalStatus();
},
methods: {
reset() {
this.select = {};
this.getDataList();
},
toZxqc() {
this.$router.push({
path: "dailyZxqc",
});
},
getApprovalStatus() {
api.approvalStatus().then((res) => {
this.approveStatusList = res.data;
});
},
getDataList() {
api
.customList(Object.assign({}, this.queryParams, this.select))
.then((res) => {
this.tableData1 = res.rows;
this.total = res.total;
});
},
//
toRemark(id){
this.$router.push({
path: "dailyZxqc",
query: {
id: id,
toRemark:true
},
});
},
//
toDestroy(pkId){
this.$confirm("确认作废该签呈?", '警告', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: "warning",
}).then((_) => {
api
.cancelCustom({
pkId,
})
.then((res) => {
//
this.getDataList();
});
});
},
//
toBack(pkId) {
this.$confirm("确认撤回该签呈?", '警告', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: "warning",
}).then((_) => {
api
.revokeCustom({
pkId,
})
.then((res) => {
//
this.getDataList();
});
});
},
//
toFixed(id) {
this.$router.push({
path: "dailyZxqc",
query: {
id: id,
},
});
},
//
toSee(id, index) {
this.$router.push({
path: "/manageDetails",
query: {
id: id,
index: index,
isPrint: true,
},
});
},
/** 导出按钮操作 */
handleExport() {
this.$confirm('是否确认导出所有数据项?', '警告', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: "warning",
}).then((_) => {
this.download(
"/system/manage/approval-business/custom-export",
Object.assign({}, this.queryParams, this.select),
`日常申请${new Date().getTime()}.xlsx`
);
});
},
tableRowClassName({ row, rowIndex }) {
if (rowIndex % 2 == 1) {
return "warning-row";
} else if (rowIndex % 2 == 0) {
return "success-row";
}
return "";
},
},
};
</script>
<style lang="scss" scoped>
.page {
padding: 20px;
background: #f9f9f9;
font-size: 14px;
}
.main {
display: flex;
flex-direction: column;
background: #ffffff;
border-radius: 8px;
box-shadow: 0px 2px 20px 0px rgba(238, 238, 238, 0.5);
}
.form_all {
padding: 0px 20px 0 10px;
// margin-bottom: 20px;
background: #fff;
border-radius: 8px;
}
.topbox {
align-items: center;
padding: 0px 0 3px 0;
display: flex;
// background: skyblue;
.levelList_i {
margin-left: 20px;
position: relative;
cursor: pointer;
padding: 0 5px;
width: 88px;
height: 34px;
border-radius: 17px;
border: 1px solid #cccccc;
font-size: 14px;
font-family: MicrosoftYaHei;
text-align: center;
line-height: 34px;
}
.act {
color: #ffffff;
background: #08143f;
}
.act1 {
border-bottom: 3px solid #1890ff !important;
}
.cha {
font-size: 16px;
color: #606266;
position: absolute;
top: 10px;
}
.li {
width: 40px;
margin: 0 auto;
border-bottom: 3px solid transparent;
}
}
.main_a {
display: flex;
padding: 0px 20px 0px 0px;
justify-content: space-between;
align-items: center;
background: #fff;
border-radius: 8px;
}
.bz_a {
display: flex;
// justify-content: center;
// padding-left: 80px;
// padding:0px 0 45px 80px;
padding: 35px 0;
// padding-left: 30px;
display: flex;
justify-content: center;
.bz_i {
display: flex;
// flex-direction: column;
align-items: center;
position: relative;
// padding: 20px 0;
.quan {
width: 14px;
height: 14px;
border: 2px solid #1678ff;
border-radius: 50%;
}
.qiu {
width: 14px;
height: 14px;
background: #ccc;
border-radius: 50%;
}
.gun {
width: 60px;
height: 2px;
background: #1678ff;
}
.gun1 {
width: 60px;
height: 2px;
background: #ccc;
}
.time {
position: absolute;
top: -20px;
left: -80px;
// transform: translateX(-120%);
font-size: 10px;
font-family: PingFang SC-Regular, PingFang SC;
font-weight: 400;
color: #999999;
width: 50px;
white-space: nowrap;
}
.zhi {
line-height: 14px;
font-size: 8px;
font-family: PingFang SC-Regular, PingFang SC;
font-weight: 400;
color: #999999;
position: absolute;
left: 3px;
// right: 0;
transform: translateX(-45%);
bottom: -30px;
white-space: nowrap;
}
}
.bz_i:last-child {
// width: 100px;
}
}
::v-deep .el-date-editor--daterange {
width: 100%;
}
</style>