first commit

This commit is contained in:
2026-09-09 09:14:28 +08:00
commit 5343198112
5199 changed files with 1052895 additions and 0 deletions
@@ -0,0 +1,392 @@
<!--#
layout("/layouts/platform.html"){
#-->
<style>
</style>
<div id="app" class="platform" v-cloak>
<guava ref="guava">
<el-card shadow="never">
<div class="search">
<div class="search-item">
<div class="search-item-label">&emsp;&emsp;度:</div>
<div class="search-item-option">
<el-date-picker
placeholder="选择年"
style="width: 150px"
style="width: 100%"
type="year" v-model="pageForm.year"
value-format="yyyy">
</el-date-picker>
</div>
</div>
<div class="search-item">
<div class="search-item-label">&emsp13;&emsp13;人:</div>
<div class="search-item-option">
<el-input @keyup.enter.native="doSearch" clearable placeholder="请输入内容"
v-model="pageForm.searchKeyword">
<el-select placeholder="查询类型" slot="prepend" style="width: 100px;"
v-model="pageForm.searchName">
<el-option label="姓名" value="rei.userName"></el-option>
<el-option label="工号" value="rei.loginName"></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 @change="flushUnits" @clear="flushUnits" clearable="true"
filterable="true"
placeholder="所属工会" style="width: 100%;"
v-model="pageForm.unionId">
<el-option :label="item.unionname" :value="item.id" v-for="item in unions"></el-option>
</el-select>
</div>
</div>
<div class="search-item">
<div class="search-item-label">所属单位:</div>
<div class="search-item-option">
<el-select clearable="true" filterable="true" placeholder="所属单位"
style="width: 100%;"
v-model="pageForm.unitId">
<el-option :label="item.name" :value="item.id" v-for="item in units"></el-option>
</el-select>
</div>
</div>
<div class="search-item">
<div class="search-item-label">报销项目:</div>
<div class="search-item-option">
<el-select clearable style="width: 100%" v-model="pageForm.reiItemId">
<el-option value="ww" label="慰问"></el-option>
<el-option value="fyhd" label="活动"></el-option>
<el-option value="fyjj" label="建家"></el-option>
<el-option value="fyrc" label="日常"></el-option>
<el-option value="zflw" label="劳务"></el-option>
<el-option value="zfzj" label="专家"></el-option>
</el-select>
</div>
</div>
<div class="search-query">
<el-button @click="doSearch" icon="el-icon-search" type="primary">搜索</el-button>
</div>
</div>
</el-card>
<el-card class="mt10" shadow="never">
<table-tool :app="this" label="报销列表">
<template #func>
<div class="pull-right offscreen-right mt5">
<el-radio-group @change="doSearch" size="medium" v-model="pageForm.isAudit">
<el-radio-button :label="true">已审核</el-radio-button>
<el-radio-button :label="false">未审核</el-radio-button>
</el-radio-group>
</div>
</template>
</table-tool>
<el-row class="el-table-container">
<el-table :data="tableData" @sort-change="pageOrder" row-key="id" style="width: 100%"
v-loading="tabLoading">
<el-table-column :index="indexMethod" align="center" header-align="center" label="序号"
type="index"
width="80px"></el-table-column>
<el-table-column
:label="column.label"
:prop="column.prop"
:sortable="column.sortable"
align="center"
header-align="center"
v-for="column in tableColumns">
<template scope="{row}" v-if="column.prop==='stateId'">
<span :style="'color:'+row.stateColor">{{row.stateName}}</span>
</template>
<template scope="{row}" v-else-if="column.prop==='unitName'">
{{isDisPlayCode?''+row.unitcode+'':null}}{{row.unitName}}
</template>
<template scope="{row}" v-else-if="column.prop==='unionname'">
{{isDisPlayCode?''+row.unioncode+'':null}}{{row.unionname}}
</template>
<template scope="{row}" v-else-if="column.prop=='reimbursementItemSort'">
{{row.reimbursementItemSort==='fy'?'费用报销':'支付报销'}}
</template>
<template scope="{row}" v-else-if="column.prop=='description'">
<span>{{row.activity_name!=null?'活动名称:'+row.activity_name:'被慰问人:'+row.be_username}}</span>
</template>
</el-table-column>
<el-table-column align="center" fixed="right" header-align="center" label="操作" width="150px">
<template scope="{row}">
<el-dropdown @command="dropdownCommand">
<el-button :loading="row.loading" 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:'doRecall',data:row}" :disabled="row.State<=3043">
撤回
</el-dropdown-item>
<el-dropdown-item :command="{type:'Review',data:row}"
:disabled="row.State!=3043">
审核
</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
</template>
</el-table-column>
</el-table>
</el-row>
<!--#include("/layouts/pagination.html"){}#-->
</el-card>
<template #edit>
<reimbursement-new ref="rei_info2" handle label="审核">
<template #handle>
<el-form :model="formData" ref="form" :rules="formRules" label-position="right"
style="padding: 20px 0"
label-width="120px">
<el-form-item label="审核信息&emsp;" 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="auditTime" label="审核时间">
<el-input v-model="formData.auditTime" 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>
<div style="float: right;margin: 20px 0">
<el-button type="danger" @click="doReview(1)">
</el-button>
<el-button type="warning" @click="doReview(2)">退回
</el-button>
<el-button type="success" @click="doReview(3)">
</el-button>
</div>
</template>
</reimbursement-new>
</template>
<template #view>
<!--<activity-bx-info ref="act_info" v-show="reimbursementItemId!=4"></activity-bx-info>
<info ref="info" v-show="reimbursementItemId==4"></info>-->
<reimbursement-new ref="rei_info"></reimbursement-new>
</template>
</guava>
</div>
<script>
const vue = new Vue({
el: '#app',
mixins: [initTableMixins],
data() {
return {
ReimbursementIsSign: false,
reimbursementItemId: "",
unions: [],
units: [],
tabLoading: false,
userOptions: [],
formData: {},
tableData: [],
typeOptions: [],
pageForm: {
searchName: "rei.userName",
isAudit: false,
year: new Date().getFullYear() + ""
},
formRules: {
/* auditOpinion: [{required: true, message: '必填', trigger: ['blur', 'change']}],
opinion: [{required: true, message: '必填', trigger: ['blur', 'change']}],*/
},
tableColumns: [
{prop: 'userName', label: '经办人'},
{prop: 'unionName', label: '所在工会'},
{prop: 'unitName', label: '所在单位', sortable: true},
{prop: 'mobile', label: '联系方式'},
{prop: 'reimbursementItemSort', label: '报销类别', sortable: true},
{prop: 'reimbursementItemName', label: '报销项目', sortable: true},
{prop: 'applyTime', label: '申请时间', sortable: true},
{prop: 'stateId', label: '申请状态'},
{prop: 'description', label: '备注'},
],
subDis: false,
subLoading1: false,
subLoading2: false,
subLoading3: false,
}
},
components: {
'guava': httpVueLoader('/components/plugins/Guava.vue'),
'file-upload': httpVueLoader('/components/plugins/FileUpload.vue'),
'sign': httpVueLoader('/components/sign/sign.vue?v=2.0.0'),
'info': httpVueLoader('/components/condolence/Info.vue'),
'activity-bx-info': httpVueLoader('/components/activityBx/ActivityBxInfo.vue'),
'reimbursement-new': httpVueLoader('/components/reimbursement/reimbursementNew.vue'),
},
methods: {
dropdownCommand(command) {
const {type, data} = command
if (type == 'view') {
this.openView(data)
} else if (type == 'doRecall') {
this.doRecall(data)
} else if (type == 'Review') {
this.openReview(data)
}
},
async doRecall(row) {
const confirm = await this.$confirm('您确定要撤回吗?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning',
});
if ("confirm" === confirm) {
const loading = this.$loading({
lock: true,
text: '正在提交...',
spinner: 'el-icon-loading',
background: COVER_LAYER_COLOR
});
const resp = await $.post(loc() + "/doRecall", {
id: row.id
});
if (resp.code === 0) {
this.doSearch()
this.notifySuccess(resp.msg)
} else {
this.notifyWarning(resp.msg)
}
loading.close()
}
},
async doReview(flag) {
const confirm = await this.$confirm('您确定要审核吗?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning',
});
if ("confirm" === confirm) {//确认后再执行
const loading = this.$loading({
lock: true,
text: '正在提交...',
spinner: 'el-icon-loading',
background: COVER_LAYER_COLOR
});
const resp = await $.post(loc() + "/doSubmit", {
id: this.formData.id,
flag: flag,
auditOpinion: this.formData.auditOpinion
});
if (resp.code === 0) {
this.doSearch()
this.notifySuccess(resp.msg)
this.$refs.guava.index()
} else {
this.notifyWarning(resp.msg)
}
loading.close()
}
},
openReview(row) {
this.formData = {
id: row.id,
username: "${@shiro.getPrincipalProperty('username')}",
auditTime: moment().format('YYYY-MM-DD')
}
this.$refs.rei_info2.getInfo(row.id)
this.$refs.guava.edit()
if (this.$refs['form']) {
this.$refs['form'].resetFields()
}
},
openView(row) {
/* const {reimbursementId, reimbursementItemId} = row
this.reimbursementItemId = reimbursementItemId
if (reimbursementItemId != 4) {
this.$refs.act_info.getActInfo(reimbursementId)
} else {
this.$refs.info.getInfo(reimbursementId)
}*/
this.$refs.rei_info.getInfo(row.id)
this.$refs.guava.view()
},
async getTypeOptions() {
const {code, data} = await $.get("/platform/condolence/type/getAll")
if (code == 0) {
this.typeOptions = data
}
},
async flushUnits() {
this.$set(this.pageForm, "unitId", "")
this.units = await getUnits(this.pageForm.unionId)
},
},
async created() {
this.pageData();
this.getTypeOptions()
if ("${@shiro.hasRole('sysadmin')}" === 'true') {
this.unions = await getUnionList(null)
} else {
this.unions = await getUnionList("${@shiro.getPrincipalProperty('unit').getUnionid()}")
this.pageForm.unionId = this.unions[0].id
}
this.flushUnits()
const aa = await getDictState("ReimbursementIsSign")
this.ReimbursementIsSign = aa.disabled
}
})
</script>
<!--#
}
#-->
@@ -0,0 +1,437 @@
<!--#
layout("/layouts/platform.html"){
#-->
<div class="platform" id="app" v-cloak>
<guava ref="guava">
<template>
<el-card shadow="never">
<div class="search">
<div class="search-item">
<div class="search-item-label">&emsp;&emsp;度:</div>
<div class="search-item-option">
<el-date-picker
@change="doSearch"
placeholder="选择年"
style="width: 100%"
type="year" v-model="pageForm.year"
value-format="yyyy">
</el-date-picker>
</div>
</div>
<div class="search-item">
<div class="search-item-label">工会名称:</div>
<div class="search-item-option">
<el-select @change="flushUnits" @clear="flushUnits" clearable filterable
placeholder="请选择工会" style="width: 100%" v-model="pageForm.unionId">
<el-option
:key="item.id"
:label="item.unionname"
:value="item.id"
v-for="item in unionList">
</el-option>
</el-select>
</div>
</div>
<div class="search-item">
<div class="search-item-label">单位名称:</div>
<div class="search-item-option">
<el-select @change="doSearch" clearable="true" filterable="true"
placeholder="所属单位"
style="width: 100%;"
v-model="pageForm.unitId">
<el-option :label="item.name" :value="item.id" v-for="item in unitList"></el-option>
</el-select>
</div>
</div>
<div class="search-item">
<div class="search-item-label">报销项目:</div>
<div class="search-item-option">
<el-select @change="doSearch" clearable
style="width: 100%" v-model="pageForm.reiItemId">
<el-option value="ww" label="慰问"></el-option>
<el-option value="fyhd" label="活动"></el-option>
<el-option value="fyjj" label="建家"></el-option>
<el-option value="fyrc" label="日常"></el-option>
<el-option value="zflw" label="劳务"></el-option>
<el-option value="zfzj" label="专家"></el-option>
</el-select>
</div>
</div>
</div>
</el-card>
<el-card class="mt10" shadow="never">
<table-tool :app="this" label="报销列表">
<template #func>
<!--<el-button :disabled="selectRows.length!==1" @click="printPdf" size="mini" type="primary">打印
</el-button>-->
</template>
</table-tool>
<el-table :data="tableData" :size="tableSize" @selection-change="(val)=>{this.selectRows = val}"
@sort-change="pageOrder"
class="vi-table" row-key="id" style="width: 100%;margin-bottom: 20px"
v-loading="tableLoading">
<!-- <el-table-column align="center" header-align="center" type="selection"></el-table-column>-->
<el-table-column :index="indexMethod" align="center" header-align="center" label="序号" type="index"
width="80px"></el-table-column>
<el-table-column
:label="column.label"
:prop="column.prop"
:sortable="column.sortable"
align="center"
header-align="center"
show-overflow-tooltip
v-for="column in tableColumns">
<template scope="{row}" v-if="column.prop=='shrname'">
{{row.shrname!=null?row.shrname:'暂无'}}
</template>
<template scope="{row}" v-else-if="column.prop=='stateId'">
<span :style="'color:'+row.stateColor">{{row.stateName}}</span>
</template>
<template scope="{row}" v-else-if="column.prop=='reimbursementItemSort'">
{{row.reimbursementItemSort==='fy'?'费用报销':'支付报销'}}
</template>
<template scope="{row}" v-else-if="column.prop=='description'">
<span>{{row.activity_name!=null?'活动名称:'+row.activity_name:'被慰问人:'+row.be_username}}</span>
</template>
<template scope="{row}" v-else-if="column.prop==='unitname'">
{{isDisPlayCode?''+row.unitcode+'':null}}{{row.unitName}}
</template>
<template scope="{row}" v-else-if="column.prop==='unionname'">
{{isDisPlayCode?''+row.unioncode+'':null}}{{row.unionName}}
</template>
</el-table-column>
<el-table-column align="center" header-align="center" label="操作" prop="userOnline" width="150px">
<template scope="{row}">
<el-dropdown @command="dropdownCommand">
<el-button :loading="row.loading" size="mini">
<i class="ti-settings"></i>
<span class="ti-angle-down"></span>
</el-button>
<el-dropdown-menu slot="dropdown">
<!-- <el-dropdown-item :disabled="row.stateId!=3040"
:command="{type:'submit',data:row}">
提交
</el-dropdown-item>-->
<el-dropdown-item :command="{type:'view',data:row}">
查看
</el-dropdown-item>
<el-dropdown-item
:command="{type:'edit',data:row}"
:disabled="row.State>3043">
修改
</el-dropdown-item>
<el-dropdown-item
:disabled="row.State<3100"
:command="{type:'delete',data:row}">
删除
</el-dropdown-item>
<el-dropdown-item
:disabled="row.State<3100"
:command="{type:'export',data:row}">
导出报销表
</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
</template>
</el-table-column>
</el-table>
<!--#include("/layouts/pagination.html"){}#-->
</el-card>
</template>
<template #view>
<reimbursement-new ref="rei_info"></reimbursement-new>
<!--<activity-bx-info ref="act_info" v-show="reimbursementItemId!=4"></activity-bx-info>
<info ref="info" v-show="reimbursementItemId==4"></info>-->
</template>
</guava>
</div>
<script>
const vue = new Vue({
el: '#app',
mixins: [initTableMixins],
data() {
return {
selectRows: [],
typeOptions: [],
reimbursementItemId: "",
unionList: [],
unitList: [],
formData: {
hospital_time: []
},
pageForm: {
year: new Date().getFullYear() + ''
},
tableColumns: [
{prop: 'loginName', label: '经办人工号', sortable: true},
{prop: 'userName', label: '姓名', sortable: true},
{prop: 'unionName', label: '所属工会', sortable: true},
{prop: 'unitName', label: '所属单位', sortable: true},
{prop: 'applyTime', label: '申请时间', sortable: true},
{prop: 'reimbursementItemSort', label: '报销类别', sortable: true},
{prop: 'reimbursementItemName', label: '报销项目', sortable: true},
{prop: 'description', label: '备注'},
{prop: 'stateId', label: '申请状态', sortable: true}
],
formRules: {
activity_number: [{required: false, message: '必填', trigger: ['blur', 'change']}],
venue: [{required: true, message: '必填', trigger: ['blur', 'change']}],
activity_money: [{required: true, message: '必填', trigger: ['blur', 'change']}],
activity_card_number: [{required: true, message: '必填', trigger: ['blur', 'change']}],
activity_time: [{required: false, message: '必填', trigger: ['blur', 'change']}],
}
}
},
components: {
'guava': httpVueLoader('/components/plugins/Guava.vue'),
'file-upload': httpVueLoader('/components/plugins/FileUpload.vue'),
'sign': httpVueLoader('/components/sign/sign.vue?v=2.0.0'),
'info': httpVueLoader('/components/condolence/Info.vue'),
'activity-bx-info': httpVueLoader('/components/activityBx/ActivityBxInfo.vue'),
'reimbursement-new': httpVueLoader('/components/reimbursement/reimbursementNew.vue'),
},
methods: {
printPdf() {
// const id = this.selectRows[0].reimbursementId
/* const {reimbursementItemId, reimbursementId} = this.selectRows[0]
let newWindow = null
if (reimbursementItemId != 4) {
newWindow = window.open("/platform/reimbursement/Summary/ActExport?id=" + reimbursementId + "&Print=true")
// window.location.href = "/platform/reimbursement/Summary/ActExport?id=" + reimbursementId + "&Print=true"
} else {
newWindow = window.open("/platform/reimbursement/Summary/ConExport?id=" + reimbursementId + "&Print=true")
// window.location.href = "/platform/reimbursement/Summary/ConExport?id=" + reimbursementId + "&Print=true"
}*/
window.open("/platform/reimbursement/Summary/reiExport?id=" + this.selectRows[0].id + "&Print=true")
},
dropdownCommand(command) {
const {type, data} = command
if (type == 'view') {
this.openView(data)
} else if (type == 'submit') {
this.doSubmit(data)
} else if (type == 'edit') {
this.openEdit(data)
} else if (type == 'delete') {
this.doDelete(data)
} else if (type == 'export') {
this.export(data)
}
},
export(data) {
// const {reimbursementItemId, reimbursementId} = data
window.open("/platform/reimbursement/Summary/reiExport?id=" + data.id + "&Print=false")
/* if (reimbursementItemId != 4) {
window.location.href = "/platform/reimbursement/Summary/ActExport?id=" + reimbursementId + "&Print=false"
} else {
window.location.href = "/platform/reimbursement/Summary/ConExport?id=" + reimbursementId + "&Print=false"
}*/
},
doSubmit(row) {
const {reimbursementId} = row
this.$confirm('确定要提交吗?提交后將不能刪除', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning',
callback: async (a, b) => {
if ("confirm" == a) {//确认后再执行
this.$set(row, "delLoading", true)
const resp = await $.post(loc() + "/doSubmit", {id: reimbursementId});
requestLaterMsgFun(vue, resp, async () => {
this.pageData()
}, () => {
}, () => {
this.$set(row, "delLoading", false)
})
}
}
});
},
doDelete(row) {
const {id} = row
this.$confirm('确定要删除吗?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning',
callback: async (a, b) => {
if ("confirm" == a) {//确认后再执行
this.$set(row, "delLoading", true)
const resp = await $.post(loc() + "/doDelete", {id: id});
requestLaterMsgFun(vue, resp, async () => {
this.pageData()
}, () => {
}, () => {
this.$set(row, "delLoading", false)
})
}
}
});
},
openView(row) {
/* const {reimbursementId, reimbursementItemId} = row
this.reimbursementItemId = reimbursementItemId
if (reimbursementItemId != 4) {
this.$refs.act_info.getActInfo(reimbursementId)
} else {
this.$refs.info.getInfo(reimbursementId)
}*/
this.$refs.rei_info.getInfo(row.id)
this.$refs.guava.view()
},
openEdit(row) {
window.location.href = "/platform/reimbursement/applyNew?id=" + row.id
/* const {bxId, reimbursementId, reimbursementItemId} = row
this.reimbursementItemId = reimbursementItemId
this.formData = {}
this.$set(row, "editLoading", true)
if (reimbursementItemId != 4) {
this.actOpenEdit(row, bxId)
} else {
this.conOpenEdit(row, reimbursementId)
}
this.$refs.guava.edit()*/
},
async conOpenEdit(row, id) {
const resp = await $.get("/platform/fw/condolence/info/findOne", {id})
requestLaterFun(resp, async (v) => {
condolence.toFormData(v)
v.bankUserName = row.bankUserName
v.bankCardNumber = row.bankCardNumber
v.bankOfDeposit = row.bankOfDeposit
this.formData = v
this.$set(this.formData, 'hospital_stay', [v.starting_time, v.end_time])
this.$set(this.formData, 'hospital_time', [v.starting_time, v.end_time])
this.formData.sign = v.manager_sign
await this.userChange(v.be_user)
})
},
async getUserData(userId) {
const {data} = await $.get("/platform/fw/condolence/apply/getUserData", {userId})
return data
},
async userChange(be_user) {
const userData = await this.getUserData(be_user);
this.$set(this.formData, 'sex', userData.sex)
this.$set(this.formData, 'birthday', userData.birthday)
this.$set(this.formData, 'idcard', userData.idcard)
},
async actOpenEdit(row, id) {
const resp = await $.get(loc() + "/findOne", {id})
requestLaterFun(resp, async (v) => {
v.bankUserName = row.bankUserName
v.bankCardNumber = row.bankCardNumber
v.bankOfDeposit = row.bankOfDeposit
this.formData = v
this.formData.files = JSON.parse(v.files)
})
},
doEdit() {
this.$refs["form"].validate(async (valid) => {
if (valid) {
let resp = ""
const loading = this.$loading({
lock: true,
text: '正在提交...',
spinner: 'el-icon-loading',
background: COVER_LAYER_COLOR
});
const formData = clone(this.formData)
if (this.reimbursementItemId == 4) {
formData.files = JSON.stringify(formData.files)
if (formData.hospital_stay) {
formData.hospital_stay_1 = formData.hospital_time[0]
formData.hospital_stay_2 = formData.hospital_time[1]
}
resp = await $.post("/platform/fw/condolence/info/doEdit", {
data: JSON.stringify(formData),
sign: this.formData.sign,
hospital_stay_1: formData.hospital_stay_1,
hospital_stay_2: formData.hospital_stay_2,
bankCardNumber: formData.bankCardNumber,
bankOfDeposit: formData.bankOfDeposit
})
} else {
resp = await $.post(loc() + "/doEdit", {data: JSON.stringify(formData)})
}
closeLoadingFunc(loading, resp, async () => {
this.pageData()
this.$refs.guava.index()
}, (data, msg) => {
this.$message.error(msg);
})
}
})
},
async typeChange(id) {
const {data, code, msg} = await $.get("/platform/condolence/type/findOne", {id})
if (data) {
this.$set(this.formData, "money", data.money)
this.$set(this.formData, "way", data.way)
}
},
async getTypeOptions() {
const {code, data} = await $.get("/platform/condolence/type/getAll")
if (code == 0) {
this.typeOptions = data
}
},
async flushUnits() {
this.$set(this.pageForm, "unitId", "")
if ("${@shiro.hasRole('sysadmin')||@shiro.hasRole('A06')||@shiro.hasRole('H03')}" === 'true') {
this.unitList = await getUnits(this.pageForm.unionId)
} else {
this.unitList = await getUnits("${@shiro.getPrincipalProperty('unit').getUnionid()}")
}
this.doSearch()
},
},
async created() {
this.unionList = await getUnionList("${@shiro.getPrincipalProperty('union').getId()}")
this.getTypeOptions()
this.flushUnits()
this.pageData()
}
})
</script>
<!--#
}
#-->
@@ -0,0 +1,345 @@
<!--#
layout("/layouts/platform.html"){
#-->
<div class="platform" id="app" v-cloak>
<guava padding="0% 5%" ref="guava">
<template>
<el-card shadow="never">
<search>
<search-item label="年&emsp;&emsp;度:">
<el-date-picker
placeholder="选择年"
style="width: 150px"
style="width: 100%"
type="year" v-model="pageForm.year"
value-format="yyyy">
</el-date-picker>
</search-item>
<search-item label="所属工会:">
<el-select @change="flushUnits" @clear="flushUnits" clearable="true"
filterable="true"
placeholder="所属工会" style="width: 100%;"
v-model="pageForm.unionId">
<el-option :label="item.unionname" :value="item.id" v-for="item in unions"></el-option>
</el-select>
</search-item>
<search-item label="所属单位:">
<el-select clearable="true" filterable="true" placeholder="所属单位"
style="width: 100%;"
v-model="pageForm.unitId">
<el-option :label="item.name" :value="item.id" v-for="item in units"></el-option>
</el-select>
</search-item>
<template v-if="searchMore">
<search-item label="报销项目">
<el-select clearable style="width: 100%" v-model="pageForm.reiItemId">
<el-option :value="4" label="慰问"></el-option>
<el-option :value="1" label="文体活动"></el-option>
<el-option :value="2" label="日常活动"></el-option>
<el-option :value="3" label="其它活动"></el-option>
</el-select>
</search-item>
</template>
<div class="search-query">
<el-button @click="doSearch" icon="el-icon-search" type="primary">搜索</el-button>
<more v-model="searchMore"></more>
</div>
</search>
</el-card>
<el-card class="mt10" shadow="never">
<table-tool :app="this" label="报销列表">
<template #func>
<div class="pull-right offscreen-right mt5">
<el-radio-group @change="doSearch" size="medium" v-model="pageForm.isAudit">
<el-radio-button :label="true">已审核</el-radio-button>
<el-radio-button :label="false">未审核</el-radio-button>
</el-radio-group>
</div>
</template>
</table-tool>
<el-row class="el-table-container">
<el-table :data="tableData" @sort-change="pageOrder" row-key="id" style="width: 100%"
v-loading="tabLoading">
<el-table-column :index="indexMethod" align="center" header-align="center" label="序号"
type="index"
width="80px"></el-table-column>
<el-table-column
:label="column.label"
:prop="column.prop"
:sortable="column.sortable"
align="center"
header-align="center"
v-for="column in tableColumns">
<template scope="{row}" v-if="column.prop=='stateId'">
<span :style="'color:'+row.stateColor">{{row.stateName}}</span>
</template>
</el-table-column>
<el-table-column align="center" fixed="right" header-align="center" label="操作" width="150px">
<template scope="{row}">
<el-dropdown @command="dropdownCommand">
<el-button :loading="row.loading" 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:'Review',data:row}"
:disabled="row.State!=3090">
审核
</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
</template>
</el-table-column>
</el-table>
</el-row>
<!--#include("/layouts/pagination.html"){}#-->
</el-card>
</template>
<template #edit>
<activity-bx-info handle label="常务副主席审核" ref="act_info2" v-show="reimbursementItemId!=4">
<template #handle>
<el-form :model="formData" :rules="formRules" label-position="right" label-width="120px"
ref="form"
style="padding: 20px 0">
<el-form-item class="view-header" label="审核信息&emsp;" label-width="135px">
</el-form-item>
<el-row gutter="20">
<el-col :span="12">
<el-form-item label="审核人员" prop="username">
<el-input disabled
v-model="formData.username"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="审核时间" prop="time">
<el-input disabled v-model="formData.time"></el-input>
</el-form-item>
</el-col>
</el-row>
<el-form-item label="审核意见" prop="auditOpinion">
<el-input maxlength="500" placeholder="请填写您的审核意见" rows="4" type="textarea"
v-model="formData.auditOpinion"></el-input>
</el-form-item>
<el-form-item label="签&emsp;&emsp;字" prop="auditSign" v-if="!ReimbursementIsSign">
<sign :qz.sync="formData.auditSign" prefix="condolence"></sign>
</el-form-item>
</el-form>
<div style="float: right;margin: 20px 0">
<el-button :disabled="subDis" :loading="subLoading1" @click="doReview(false)" type="danger">
</el-button>
<el-button :disabled="subDis" :loading="subLoading2" @click="doReview(true)" type="success">
</el-button>
</div>
</template>
</activity-bx-info>
<info handle label="常务副主席审核" ref="info2" v-show="reimbursementItemId==4">
<template #handle>
<el-form :model="formData" :rules="formRules" label-position="right" label-width="120px"
ref="form"
style="padding: 20px 0">
<el-form-item class="view-header" label="审核信息&emsp;" label-width="135px">
</el-form-item>
<el-row gutter="20">
<el-col :span="12">
<el-form-item label="审核人员" prop="username">
<el-input disabled
v-model="formData.username"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="审核时间" prop="time">
<el-input disabled v-model="formData.time"></el-input>
</el-form-item>
</el-col>
</el-row>
<el-form-item label="审核意见" prop="opinion">
<el-input maxlength="500" placeholder="请填写您的审核意见" rows="4" type="textarea"
v-model="formData.opinion"></el-input>
</el-form-item>
<el-form-item label="签&emsp;&emsp;字" prop="sign" v-if="!ReimbursementIsSign">
<sign :qz.sync="formData.sign" prefix="condolence"></sign>
</el-form-item>
</el-form>
<div style="float: right;margin: 20px 0">
<el-button :disabled="subDis" :loading="subLoading1" @click="doReview(false)" type="danger">
</el-button>
<el-button :disabled="subDis" :loading="subLoading2" @click="doReview(true)" type="success">
</el-button>
</div>
</template>
</info>
</template>
<template #view>
<activity-bx-info ref="act_info" v-show="reimbursementItemId!=4"></activity-bx-info>
<info ref="info" v-show="reimbursementItemId==4"></info>
</template>
</guava>
</div>
<script>
const vue = new Vue({
el: '#app',
mixins: [initTableMixins],
data() {
return {
ReimbursementIsSign: false,
reimbursementItemId: "",
unions: [],
units: [],
tabLoading: false,
userOptions: [],
formData: {},
tableData: [],
typeOptions: [],
pageForm: {
isAudit: false,
year: new Date().getFullYear() + ""
},
formRules: {
/*auditOpinion: [{required: true, message: '必填', trigger: ['blur', 'change']}],
opinion: [{required: true, message: '必填', trigger: ['blur', 'change']}],*/
},
tableColumns: [
{prop: 'userName', label: '经办人'},
{prop: 'unionname', label: '所在工会'},
{prop: 'unitName', label: '所在单位', sortable: true},
{prop: 'mobile', label: '联系方式'},
{prop: 'reimbursementItemName', label: '报销项目', sortable: true},
{prop: 'applyTime', label: '申请时间', sortable: true},
{prop: 'stateId', label: '申请状态'},
],
subDis: false,
subLoading1: false,
subLoading2: false,
subLoading3: false,
}
},
components: {
'guava': httpVueLoader('/components/plugins/Guava.vue'),
'file-upload': httpVueLoader('/components/plugins/FileUpload.vue'),
'sign': httpVueLoader('/components/sign/sign.vue?v=2.0.0'),
'info': httpVueLoader('/components/condolence/Info.vue'),
'activity-bx-info': httpVueLoader('/components/activityBx/ActivityBxInfo.vue'),
},
methods: {
dropdownCommand(command) {
const {type, data} = command
if (type == 'view') {
this.openView(data)
} else if (type == 'Review') {
this.openReview(data)
}
},
openView(row) {
const {reimbursementId, reimbursementItemId} = row
this.reimbursementItemId = reimbursementItemId
if (reimbursementItemId != 4) {
this.$refs.act_info.getActInfo(reimbursementId)
} else {
this.$refs.info.getInfo(reimbursementId)
}
this.$refs.guava.view()
},
openReview(row) {
const {reimbursementId, reimbursementItemId} = row
this.reimbursementItemId = reimbursementItemId
this.formData = {
id: reimbursementId,
username: "${@shiro.getPrincipalProperty('username')}",
time: moment().format('YYYY-MM-DD'),
reimbursementItemId: reimbursementItemId,
}
this.subLoading1 = false
this.subLoading2 = false
this.subLoading3 = false
if (reimbursementItemId != 4) {
this.$refs.act_info2.getActInfo(reimbursementId)
} else {
this.$refs.info2.getInfo(reimbursementId)
}
this.$refs.guava.edit()
if (this.$refs['form']) {
this.$refs['form'].resetFields()
}
},
doReview(flag) {
this.$refs["form"].validate(async (valid) => {
const conMoney = this.$refs.info2.viewData.money
const actMoney = this.$refs.act_info2.viewData.activity_money
this.formData.money = this.formData.reimbursementItemId != 4 ? actMoney : conMoney
if (valid) {
this.formData.flag = flag
this.subDis = true
flag ? this.subLoading2 = true : this.subLoading1 = true
const resp = await $.post(loc() + "/doReview", this.formData)
requestLaterMsgFun(vue, resp, null, null, (v) => {
this.subDis = false
this.subLoading1 = false
this.subLoading2 = false
this.pageData()
this.$refs.guava.index()
})
}
})
},
async flushUnits() {
this.$set(this.pageForm, "unitId", "")
this.units = await getUnits(this.pageForm.unionId)
},
},
async created() {
this.pageData();
this.unions = await getUnionList()
this.flushUnits()
const aa = await getDictState("ReimbursementIsSign")
this.ReimbursementIsSign = aa.disabled
}
})
</script>
<!--#
}
#-->
@@ -0,0 +1,286 @@
<!--#
layout("/layouts/platform.html"){
#-->
<style>
</style>
<div id="app" class="platform" v-cloak>
<guava ref="guava">
<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 type="daterange" style="width: 100%" range-separator="——"
v-model="pageForm.reimbursementDate"
value-format="yyyy-MM-dd" format="yyyy-MM-dd" start-placeholder="开始日期"
end-placeholder="结束日期"></el-date-picker>
</div>
</div>
<div class="search-item">
<div class="search-item-label">&emsp13;&emsp13;人:</div>
<div class="search-item-option">
<el-input @keyup.enter.native="doSearch" clearable placeholder="请输入内容"
v-model="pageForm.searchKeyword">
<el-select placeholder="查询类型" slot="prepend" style="width: 100px;"
v-model="pageForm.searchName">
<el-option label="姓名" value="rei.userName"></el-option>
<el-option label="工号" value="rei.loginName"></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 @change="flushUnits" @clear="flushUnits" clearable="true"
filterable="true"
placeholder="所属工会" style="width: 100%;"
v-model="pageForm.unionId">
<el-option :label="item.unionname" :value="item.id" v-for="item in unions"></el-option>
</el-select>
</div>
</div>
<div class="search-item">
<div class="search-item-label">所属单位:</div>
<div class="search-item-option">
<el-select clearable="true" filterable="true" placeholder="所属单位"
style="width: 100%;"
v-model="pageForm.unitId">
<el-option :label="item.name" :value="item.id" v-for="item in units"></el-option>
</el-select>
</div>
</div>
<div class="search-item">
<div class="search-item-label">报销项目:</div>
<div class="search-item-option">
<el-select clearable style="width: 100%" v-model="pageForm.reiItemId">
<el-option value="ww" label="慰问"></el-option>
<el-option value="fyhd" label="活动"></el-option>
<el-option value="fyjj" label="建家"></el-option>
<el-option value="fyrc" label="日常"></el-option>
<el-option value="zflw" label="劳务"></el-option>
<el-option value="zfzj" label="专家"></el-option>
</el-select>
</div>
</div>
<div class="search-query">
<el-button @click="doSearch" icon="el-icon-search" type="primary">搜索</el-button>
</div>
</div>
</el-card>
<el-card class="mt10" shadow="never">
<table-tool :app="this" label="报销列表">
<template #func>
<el-button @click="doExportUserExcel" size="mini" type="primary">导出汇总名单
</el-button>
</template>
</table-tool>
<el-row class="el-table-container">
<el-table :data="tableData" @sort-change="pageOrder" row-key="id" style="width: 100%"
v-loading="tabLoading">
<el-table-column :index="indexMethod" align="center" header-align="center" label="序号"
type="index"
width="80px"></el-table-column>
<el-table-column
:label="column.label"
:prop="column.prop"
:sortable="column.sortable"
align="center"
header-align="center"
v-for="column in tableColumns"
show-overflow-tooltip>
<template scope="{row}" v-if="column.prop=='stateId'">
<span :style="'color:'+row.stateColor">{{row.stateName}}</span>
</template>
<template scope="{row}" v-else-if="column.prop=='reimbursementItemSort'">
{{row.reimbursementItemSort==='fy'?'费用报销':'支付报销'}}
</template>
<template scope="{row}" v-else-if="column.prop=='description'">
<span>{{row.activity_name!=null?'活动名称:'+row.activity_name:'被慰问人:'+row.be_username}}</span>
</template>
<template scope="{row}" v-else-if="column.prop=='money'">
<span>{{row.money}}元</span>
</template>
</el-table-column>
<el-table-column align="center" fixed="right" header-align="center" label="操作" width="150px">
<template scope="{row}">
<el-button @click="openView(row)" size="mini" type="primary">查看</el-button>
<!-- <el-dropdown @command="dropdownCommand">
<el-button :loading="row.loading" 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>
&lt;!&ndash;<el-dropdown-item
:command="{type:'export',data:row}">
打印
</el-dropdown-item>&ndash;&gt;
</el-dropdown-menu>
</el-dropdown>-->
</template>
</el-table-column>
</el-table>
</el-row>
<!--#include("/layouts/pagination.html"){}#-->
</el-card>
<template #view>
<!-- <activity-bx-info ref="act_info" v-show="reimbursementItemId!=4"></activity-bx-info>
<info ref="info" v-show="reimbursementItemId==4"></info>-->
<reimbursement-new ref="rei_info"></reimbursement-new>
</template>
</guava>
</div>
<script>
const vue = new Vue({
el: '#app',
mixins: [initTableMixins],
data() {
return {
reimbursementItemId: "",
unions: [],
units: [],
tabLoading: false,
userOptions: [],
formData: {},
tableData: [],
typeOptions: [],
pageForm: {
reimbursementDate: [],
searchName: "rei.userName",
searchKeyword: '',
unionId: '',
unitId: '',
reiItemId: '',
isAudit: false,
},
formRules: {
auditOpinion: [{required: true, message: '必填', trigger: ['blur', 'change']}],
opinion: [{required: true, message: '必填', trigger: ['blur', 'change']}],
},
tableColumns: [
{prop: 'loginName', label: '经办人工号', sortable: true},
{prop: 'userName', label: '姓名', sortable: true},
{prop: 'unionName', label: '所属工会', sortable: true},
{prop: 'unitName', label: '所属单位', sortable: true},
{prop: 'applyTime', label: '申请时间', sortable: true},
{prop: 'reimbursementItemSort', label: '报销类别', sortable: true},
{prop: 'reimbursementItemName', label: '报销项目', sortable: true},
{prop: 'description', label: '备注'},
{prop: 'money', label: '金额'},
{prop: 'stateId', label: '申请状态', sortable: true}
],
subDis: false,
subLoading1: false,
subLoading2: false,
subLoading3: false,
}
},
components: {
'guava': httpVueLoader('/components/plugins/Guava.vue'),
'file-upload': httpVueLoader('/components/plugins/FileUpload.vue'),
'sign': httpVueLoader('/components/sign/sign.vue?v=2.0.0'),
'info': httpVueLoader('/components/condolence/Info.vue'),
'activity-bx-info': httpVueLoader('/components/activityBx/ActivityBxInfo.vue'),
'reimbursement-new': httpVueLoader('/components/reimbursement/reimbursementNew.vue'),
},
methods: {
doExportUserExcel() {
const {searchKeyword, searchName, unionId, unitId, reiItemId, reimbursementDate} = this.pageForm
let reiDate = reimbursementDate
if (reiDate === null) {
reiDate = []
}
window.open(loc() + "/doExportUserExcel?searchKeyword=" + searchKeyword + "&searchName=" + searchName + "&unionId=" + unionId + "&unitId" + unitId + "&reiItemId=" + reiItemId + "&reimbursementDate=" + JSON.stringify(reiDate))
},
dropdownCommand(command) {
const {type, data} = command
if (type == 'view') {
this.openView(data)
} else if (type == 'export') {
this.export(data)
}
},
export(data) {
const {reimbursementItemId, reimbursementId} = data
if (reimbursementItemId != 4) {
window.open("/platform/reimbursement/Summary/ActExport?id=" + reimbursementId + "&Print=true")
// window.location.href = "/platform/reimbursement/Summary/ActExport?id=" + reimbursementId + "&Print=true"
} else {
window.open("/platform/reimbursement/Summary/ConExport?id=" + reimbursementId + "&Print=true")
// window.location.href = "/platform/reimbursement/Summary/ConExport?id=" + reimbursementId + "&Print=true"
}
},
openView(row) {
/* const {reimbursementId, reimbursementItemId} = row
this.reimbursementItemId = reimbursementItemId
if (reimbursementItemId != 4) {
this.$refs.act_info.getActInfo(reimbursementId)
} else {
this.$refs.info.getInfo(reimbursementId)
}*/
this.$refs.rei_info.getInfo(row.id)
this.$refs.guava.view()
},
async flushUnits() {
this.$set(this.pageForm, "unitId", "")
this.units = await getUnits(this.pageForm.unionId)
this.doSearch()
},
pageData() {//加载分页数据
sublime.showLoadingbar();//显示loading
this.tabLoading = true
const pageForm = clone(this.pageForm)
if (pageForm.reimbursementDate && pageForm.reimbursementDate.length > 0) {
pageForm.reimbursementDate = JSON.stringify(pageForm.reimbursementDate)
}
$.post(loc() + "/pageData", pageForm, (data) => {
sublime.closeLoadingbar();//关闭loading
this.tabLoading = false
if (data.code == 0) {
this.tableData = data.data.list;
this.pageForm.totalCount = data.data.totalCount;
} else {
this.$message.error(data.msg);
}
}, "json");
},
},
async created() {
this.pageData();
if ("${@shiro.hasRole('sysadmin')||@shiro.hasRole('wyh02')||@shiro.hasRole('wyh03')||@shiro.hasRole('xghkj')}" === 'true') {
this.unions = await getUnionList()
} else {
this.unions = await getUnionList("${@shiro.getPrincipalProperty('unit').getUnionid()}")
this.pageForm.unionId = this.unions[0].id
}
this.flushUnits()
}
})
</script>
<!--#
}
#-->
@@ -0,0 +1,345 @@
<!--#
layout("/layouts/platform.html"){
#-->
<div class="platform" id="app" v-cloak>
<guava padding="0% 5%" ref="guava">
<template>
<el-card shadow="never">
<search>
<search-item label="年&emsp;&emsp;度:">
<el-date-picker
placeholder="选择年"
style="width: 150px"
style="width: 100%"
type="year" v-model="pageForm.year"
value-format="yyyy">
</el-date-picker>
</search-item>
<search-item label="所属工会:">
<el-select @change="flushUnits" @clear="flushUnits" clearable="true"
filterable="true"
placeholder="所属工会" style="width: 100%;"
v-model="pageForm.unionId">
<el-option :label="item.unionname" :value="item.id" v-for="item in unions"></el-option>
</el-select>
</search-item>
<search-item label="所属单位:">
<el-select clearable="true" filterable="true" placeholder="所属单位"
style="width: 100%;"
v-model="pageForm.unitId">
<el-option :label="item.name" :value="item.id" v-for="item in units"></el-option>
</el-select>
</search-item>
<template v-if="searchMore">
<search-item label="报销项目">
<el-select clearable style="width: 100%" v-model="pageForm.reiItemId">
<el-option :value="4" label="慰问"></el-option>
<el-option :value="1" label="文体活动"></el-option>
<el-option :value="2" label="日常活动"></el-option>
<el-option :value="3" label="其它活动"></el-option>
</el-select>
</search-item>
</template>
<div class="search-query">
<el-button @click="doSearch" icon="el-icon-search" type="primary">搜索</el-button>
<more v-model="searchMore"></more>
</div>
</search>
</el-card>
<el-card class="mt10" shadow="never">
<table-tool :app="this" label="报销列表">
<template #func>
<div class="pull-right offscreen-right mt5">
<el-radio-group @change="doSearch" size="medium" v-model="pageForm.isAudit">
<el-radio-button :label="true">已审核</el-radio-button>
<el-radio-button :label="false">未审核</el-radio-button>
</el-radio-group>
</div>
</template>
</table-tool>
<el-row class="el-table-container">
<el-table :data="tableData" @sort-change="pageOrder" row-key="id" style="width: 100%"
v-loading="tabLoading">
<el-table-column :index="indexMethod" align="center" header-align="center" label="序号"
type="index"
width="80px"></el-table-column>
<el-table-column
:label="column.label"
:prop="column.prop"
:sortable="column.sortable"
align="center"
header-align="center"
v-for="column in tableColumns">
<template scope="{row}" v-if="column.prop=='stateId'">
<span :style="'color:'+row.stateColor">{{row.stateName}}</span>
</template>
</el-table-column>
<el-table-column align="center" fixed="right" header-align="center" label="操作" width="150px">
<template scope="{row}">
<el-dropdown @command="dropdownCommand">
<el-button :loading="row.loading" 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:'Review',data:row}"
:disabled="row.State!=3080">
审核
</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
</template>
</el-table-column>
</el-table>
</el-row>
<!--#include("/layouts/pagination.html"){}#-->
</el-card>
</template>
<template #edit>
<activity-bx-info handle label="分管副主席审核" ref="act_info2" v-show="reimbursementItemId!=4">
<template #handle>
<el-form :model="formData" :rules="formRules" label-position="right" label-width="120px"
ref="form"
style="padding: 20px 0">
<el-form-item class="view-header" label="审核信息&emsp;" label-width="135px">
</el-form-item>
<el-row gutter="20">
<el-col :span="12">
<el-form-item label="审核人员" prop="username">
<el-input disabled
v-model="formData.username"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="审核时间" prop="time">
<el-input disabled v-model="formData.time"></el-input>
</el-form-item>
</el-col>
</el-row>
<el-form-item label="签&emsp;&emsp;字" prop="auditSign" v-if="!ReimbursementIsSign">
<sign :qz.sync="formData.auditSign" prefix="condolence"></sign>
</el-form-item>
<el-form-item label="审核意见" prop="auditOpinion">
<el-input maxlength="500" placeholder="请填写您的审核意见" rows="4" type="textarea"
v-model="formData.auditOpinion"></el-input>
</el-form-item>
</el-form>
<div style="float: right;margin: 20px 0">
<el-button :disabled="subDis" :loading="subLoading1" @click="doReview(false)" type="danger">
</el-button>
<el-button :disabled="subDis" :loading="subLoading2" @click="doReview(true)" type="success">
</el-button>
</div>
</template>
</activity-bx-info>
<info handle label="分管副主席审核" ref="info2" v-show="reimbursementItemId==4">
<template #handle>
<el-form :model="formData" :rules="formRules" label-position="right" label-width="120px"
ref="form"
style="padding: 20px 0">
<el-form-item class="view-header" label="审核信息&emsp;" label-width="135px">
</el-form-item>
<el-row gutter="20">
<el-col :span="12">
<el-form-item label="审核人员" prop="username">
<el-input disabled
v-model="formData.username"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="审核时间" prop="time">
<el-input disabled v-model="formData.time"></el-input>
</el-form-item>
</el-col>
</el-row>
<el-form-item label="审核意见" prop="opinion">
<el-input maxlength="500" placeholder="请填写您的审核意见" rows="4" type="textarea"
v-model="formData.opinion"></el-input>
</el-form-item>
<el-form-item label="签&emsp;&emsp;字" prop="sign" v-if="!ReimbursementIsSign">
<sign :qz.sync="formData.sign" prefix="condolence"></sign>
</el-form-item>
</el-form>
<div style="float: right;margin: 20px 0">
<el-button :disabled="subDis" :loading="subLoading1" @click="doReview(false)" type="danger">
</el-button>
<el-button :disabled="subDis" :loading="subLoading2" @click="doReview(true)" type="success">
</el-button>
</div>
</template>
</info>
</template>
<template #view>
<activity-bx-info ref="act_info" v-show="reimbursementItemId!=4"></activity-bx-info>
<info ref="info" v-show="reimbursementItemId==4"></info>
</template>
</guava>
</div>
<script>
const vue = new Vue({
el: '#app',
mixins: [initTableMixins],
data() {
return {
ReimbursementIsSign: false,
reimbursementItemId: "",
unions: [],
units: [],
tabLoading: false,
userOptions: [],
formData: {},
tableData: [],
typeOptions: [],
pageForm: {
isAudit: false,
year: new Date().getFullYear() + ""
},
formRules: {
/* auditOpinion: [{required: true, message: '必填', trigger: ['blur', 'change']}],
opinion: [{required: true, message: '必填', trigger: ['blur', 'change']}],*/
},
tableColumns: [
{prop: 'userName', label: '经办人'},
{prop: 'unionname', label: '所在工会'},
{prop: 'unitName', label: '所在单位', sortable: true},
{prop: 'mobile', label: '联系方式'},
{prop: 'reimbursementItemName', label: '报销项目', sortable: true},
{prop: 'applyTime', label: '申请时间', sortable: true},
{prop: 'stateId', label: '申请状态'},
],
subDis: false,
subLoading1: false,
subLoading2: false,
subLoading3: false,
}
},
components: {
'guava': httpVueLoader('/components/plugins/Guava.vue'),
'file-upload': httpVueLoader('/components/plugins/FileUpload.vue'),
'sign': httpVueLoader('/components/sign/sign.vue?v=2.0.0'),
'info': httpVueLoader('/components/condolence/Info.vue'),
'activity-bx-info': httpVueLoader('/components/activityBx/ActivityBxInfo.vue'),
},
methods: {
dropdownCommand(command) {
const {type, data} = command
if (type == 'view') {
this.openView(data)
} else if (type == 'Review') {
this.openReview(data)
}
},
openView(row) {
const {reimbursementId, reimbursementItemId} = row
this.reimbursementItemId = reimbursementItemId
if (reimbursementItemId != 4) {
this.$refs.act_info.getActInfo(reimbursementId)
} else {
this.$refs.info.getInfo(reimbursementId)
}
this.$refs.guava.view()
},
openReview(row) {
const {reimbursementId, reimbursementItemId} = row
this.reimbursementItemId = reimbursementItemId
this.formData = {
id: reimbursementId,
username: "${@shiro.getPrincipalProperty('username')}",
time: moment().format('YYYY-MM-DD'),
reimbursementItemId: reimbursementItemId,
}
this.subLoading1 = false
this.subLoading2 = false
this.subLoading3 = false
if (reimbursementItemId != 4) {
this.$refs.act_info2.getActInfo(reimbursementId)
} else {
this.$refs.info2.getInfo(reimbursementId)
}
this.$refs.guava.edit()
if (this.$refs['form']) {
this.$refs['form'].resetFields()
}
},
doReview(flag) {
this.$refs["form"].validate(async (valid) => {
const conMoney = this.$refs.info2.viewData.money
const actMoney = this.$refs.act_info2.viewData.activity_money
this.formData.money = this.formData.reimbursementItemId != 4 ? actMoney : conMoney
if (valid) {
this.formData.flag = flag
this.subDis = true
flag ? this.subLoading2 = true : this.subLoading1 = true
const resp = await $.post(loc() + "/doReview", this.formData)
requestLaterMsgFun(vue, resp, null, null, (v) => {
this.subDis = false
this.subLoading1 = false
this.subLoading2 = false
this.pageData()
this.$refs.guava.index()
})
}
})
},
async flushUnits() {
this.$set(this.pageForm, "unitId", "")
this.units = await getUnits(this.pageForm.unionId)
},
},
async created() {
this.pageData();
this.unions = await getUnionList()
this.flushUnits()
const aa = await getDictState("ReimbursementIsSign")
this.ReimbursementIsSign = aa.disabled
}
})
</script>
<!--#
}
#-->
@@ -0,0 +1,221 @@
<!--#
layout("/layouts/platform.html"){
#-->
<style>
.el-input-number input {
text-align: left !important;
}
</style>
<div id="app" v-cloak>
<guava>
<el-card shadow="never">
<template #header>
<h3 style="color: rgb(24, 103, 176);" v-if="formData.reimbursementItemId==1">文体活动申请</h3>
<h3 style="color: rgb(24, 103, 176);" v-if="formData.reimbursementItemId==2">日常活动申请</h3>
<h3 style="color: rgb(24, 103, 176);" v-if="formData.reimbursementItemId==3">人员经费申请</h3>
<h3 style="color: rgb(24, 103, 176);" v-if="formData.reimbursementItemId==4">慰问申请</h3>
<h3 style="color: rgb(24, 103, 176);" v-if="formData.reimbursementItemId==5">困难帮扶申请</h3>
</template>
<div>
<el-form label-width="100px">
<el-form-item class="view-header" label="填写申请信息&emsp;" label-width="135px">
</el-form-item>
</el-form>
<el-form :model="formData" label-position="right" label-suffix=""
label-width="120px">
<el-row gutter="60">
<el-col :span="8">
<el-form-item label="经办人" prop="userName">
<el-input disabled type="text" v-model="formData.userName"></el-input>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="工号" prop="loginName">
<el-input disabled type="text" v-model="formData.loginName"></el-input>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="联系方式" prop="mobile">
<el-input disabled type="text" v-model="formData.mobile"></el-input>
</el-form-item>
</el-col>
<el-col :span="24">
<el-form-item label="报销项目" prop="reimbursementItemId">
<el-radio-group @change="reimbursementItemChange"
v-model="formData.reimbursementItemId">
<el-radio :label="item.key" border v-for="item in reimbursementItem">{{item.name}}
</el-radio>
</el-radio-group>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="支付方式" prop="paymentMethodId">
<el-radio-group @change="paymentMethodChange" v-model="formData.paymentMethodId">
<el-radio :label="item.key" border v-for="item in paymentMethod">{{item.name}}
</el-radio>
</el-radio-group>
</el-form-item>
</el-col>
<el-col :span="12" v-if="formData.paymentMethodId==3">
<el-form-item label="户名" prop="payerId">
<el-select
:remote-method="userRemoteMethod"
@change="userChange"
clearable
filterable
placeholder="请输入姓名或工号查找"
remote
reserve-keyword
style="width: 100%"
v-model="formData.payerId">
<el-option
:key="item.id"
:label="item.username+''+item.loginname+''"
:value="item.id"
v-for="item in userOptions">
</el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="12" v-if="formData.paymentMethodId!=3">
<el-form-item label="户名" prop="bankUserName">
<el-input type="text" placeholder="请输入户名" v-model="formData.bankUserName"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="账号" prop="bankCardNumber">
<el-input type="text" placeholder="请输入账号" v-model="formData.bankCardNumber"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="开户行" prop="bankOfDeposit">
<el-input type="text" placeholder="请输入开户行" v-model="formData.bankOfDeposit"></el-input>
</el-form-item>
</el-col>
</el-row>
</el-form>
<template>
<style-activity :judgment_h02="judgmentH02" :judgment_union="judgmentUnion"
:judgment_unit="judgmentUnit"
:z.sync="styleActivityData"
v-show="formData.reimbursementItemId!=4"></style-activity>
<condolence :x.sync="condolenceData" v-show="formData.reimbursementItemId==4"></condolence>
</template>
</div>
</el-card>
</guava>
</div>
<script>
const vue = new Vue({
el: '#app',
data() {
return {
judgmentUnit: "${@shiro.hasRole('sysadmin')||@shiro.hasRole('H04')||@shiro.hasRole('gh12')}" === 'true',
judgmentUnion: "${@shiro.hasRole('sysadmin')||@shiro.hasRole('A06')||@shiro.hasRole('xghhdwy')}" === 'true',
judgmentH02: "${@shiro.hasRole('H02')}" === 'true',
formData: {
reimbursementItemId: 4
},
reimbursementItem: [
{key: 4, name: '慰问'},
{key: 1, name: '文体活动'},
// {key: 2, name: '日常活动'},
{key: 3, name: '人员经费'},
],
userOptions: [],
paymentMethod: [
{key: 1, name: '对公支付'},
// {key: 2, name: '校内支付'},
{key: 3, name: '个人垫付'},
],
condolenceData: {},
styleActivityData: {},
difficultyData: {apply_mode: 1, jtfc: [], jtcc: [], jtcys: []},
userId: "${@shiro.getPrincipalProperty('id')}"
}
},
components: {
'style-activity': httpVueLoader('/components/reimbursement/StyleActivity.vue?v=2.0.0'),
'condolence': httpVueLoader('/components/reimbursement/Condolence.vue?v=' + moment(new Date()).unix()),
'difficulty': httpVueLoader('/components/reimbursement/Difficulty.vue?v=' + moment(new Date()).unix()),
},
methods: {
paymentMethodChange(val) {
this.formData.paymentMethodId = val
const paymentMethodName = this.paymentMethod.find(v => v.key == val)
this.formData.paymentMethodName = paymentMethodName.name
},
async userChange() {
},
async userRemoteMethod(query) {
if (query) {
const {data} = await $.get("/platform/fw/condolence/apply/queryUser", {query})
this.userOptions = data
}
},
flush() {
this.formData = {
userId: "${@shiro.getPrincipalProperty('id')}",
userName: "${@shiro.getPrincipalProperty('username')}",
loginName: "${@shiro.getPrincipalProperty('loginname')}",
unitName: "${@shiro.getPrincipalProperty('unit').getName()}",
mobile: "${@shiro.getPrincipalProperty('mobile')}",
applyTime: moment().format('YYYY-MM-DD'),
reimbursementItemId: 4,
reimbursementItemName: "慰问",
paymentMethodId: 1,
paymentMethodName: '对公支付',
}
},
reimbursementItemChange(val) {
this.formData.reimbursementItemId = val
const reimbursementItem = this.reimbursementItem.find(v => v.key == val)
this.formData.reimbursementItemName = reimbursementItem.name
this.styleActivityData=this.formData
}
},
watch: {
'condolenceData': {
deep: true,
handler(s) {
this.condolenceData = Object.assign(this.formData, s)
}
},
'styleActivityData': {
deep: true,
handler(s) {
this.styleActivityData = Object.assign(this.formData, s)
}
},
'difficultyData': {
deep: true,
handler(s) {
this.formData = Object.assign(this.formData, s)
}
}
},
async created() {
this.flush()
}
})
</script>
<!--#
}
#-->
@@ -0,0 +1,638 @@
<!--#
layout("/layouts/platform.html"){
#-->
<div id="app" v-cloak>
<guava>
<el-card shadow="never">
<el-form :model="formData" label-position="right" label-suffix=""
label-width="110px" :rules="rules" ref="addForm">
<el-row gutter="60">
<el-col :span="12">
<el-form-item label="报销类别" prop="reimbursementItemSort">
<el-radio-group v-model="formData.reimbursementItemSort"
@change="reimbursementItemSortChange">
<el-radio label="fy" border>费用报销</el-radio>
<el-radio label="zf" border>领款凭证</el-radio>
</el-radio-group>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="经费余额" prop="balance">
<el-input type="text" v-model="balance" readonly></el-input>
</el-form-item>
</el-col>
<el-col :span="24">
<el-form-item label="报销项目" prop="reimbursementItemId">
<el-radio-group v-model="formData.reimbursementItemId" @change="reimbursementItemChange">
<el-radio :label="item.key" border
v-for="item in reimbursementItem.filter(v=>v.type==formData.reimbursementItemSort)">
{{item.name}}
</el-radio>
</el-radio-group>
</el-form-item>
</el-col>
<el-col :span="24">
<el-form-item label="支付方式" prop="paymentMethodId">
<el-radio-group v-model="formData.paymentMethodId" @change="paymentMethodChange">
<el-radio :label="item.key" border v-for="item in paymentMethod">{{item.name}}
</el-radio>
</el-radio-group>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="经办人" prop="userName">
<el-input readonly type="text" v-model="formData.userName"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="工号" prop="loginName">
<el-input readonly type="text" v-model="formData.loginName"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="联系方式" prop="mobile">
<el-input type="text" v-model="formData.mobile" placeholder="请填写联系方式"></el-input>
</el-form-item>
</el-col>
<template v-if="formData.paymentMethodId=='zz'">
<el-col :span="12">
<el-form-item label="户名" prop="user_id">
<!-- <el-input type="text" placeholder="请输入户名" v-model="formData.bankUserName"></el-input>-->
<el-select v-model="formData.user_id"
style="width: 100%"
@change="userChangeHm"
filterable
remote
clearable
reserve-keyword
placeholder="请输入工号或姓名查询"
:remote-method="remoteMethod">
<el-option
v-for="item in userList"
:key="item.id"
:label="item.username+'-'+item.loginname+'-'+item.unitname"
:value="item.id">
</el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="账号" prop="bankCardNumber">
<el-input type="text" placeholder="请输入账号" v-model="formData.bankCardNumber"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="开户行" prop="bankOfDeposit">
<el-input type="text" placeholder="请输入开户行" v-model="formData.bankOfDeposit"></el-input>
</el-form-item>
</el-col>
</template>
</el-row>
<el-row gutter="60" v-if="formData.reimbursementItemId==='fyww'||formData.reimbursementItemId==='zfww'">
<el-col :span="12">
<el-form-item label="慰问对象" prop="be_user">
<el-select
v-model="formData.be_user"
:remote-method="userRemoteMethod"
clearable
filterable
placeholder="请输入姓名或工号查找"
remote
reserve-keyword
style="width: 100%"
@change="userChange">
<el-option
v-for="item in userOptions"
:key="item.id"
:label="item.username+''+item.loginname+''"
:value="item.id">
</el-option>
</el-select>
</el-form-item>
</el-col>
<!--<el-col :span="12">
<el-form-item label="性&emsp;&emsp;别" prop="sex">
<el-input v-model="formData.sex" readonly maxlength="30" placeholder="输入慰问对象查询"
type="text"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="生&emsp;&emsp;日" prop="birthday">
<el-input v-model="formData.birthday" readonly maxlength="30" placeholder="输入慰问对象查询"
type="text"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="身份证号" prop="idCard">
<el-input v-model="formData.idCard" maxlength="30" placeholder="输入慰问对象查询"
type="text"></el-input>
</el-form-item>
</el-col>-->
<el-col :span="12">
<el-form-item label="联系方式" prop="conMobile">
<el-input v-model="formData.conMobile" maxlength="30" placeholder="请输入慰问对象联系方式"
type="text"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="慰问类型" prop="type">
<el-select v-model="formData.type" style="width: 100%" @change="typeChange"
placeholder="请选择慰问类型">
<el-option v-for="item in typeOptions2" :label="item.name+' ('+item.code+')'"
:value="item.id"></el-option>
</el-select>
</el-form-item>
</el-col>
<template v-if="formData.typeCode === 'D'">
<el-col :span="12">
<el-form-item label="住院病由">
<el-input v-model="formData.hospital_by" placeholder="请填写住院病由"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="住院时间">
<el-date-picker
v-model="formData.hospital_time"
end-placeholder="结束日期"
range-separator="-"
start-placeholder="开始日期"
style="width: 100%"
type="daterange"
value-format="yyyy-MM-dd" placeholder="请选择住院时间">
</el-date-picker>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="入住医院" prop="the_hospital">
<el-input v-model="formData.the_hospital" placeholder="请填写入住医院"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="当年次数">
<el-input v-model="formData.hospital_yearNum" placeholder="填写当年次数"></el-input>
</el-form-item>
</el-col>
</template>
<el-col :span="12">
<el-form-item label="慰问金额" prop="money">
<el-input v-model="formData.money" :controls="false"
:max="1000000000" :min="0" controls-position="right"
placeholder="请填写慰问金额"
precision="2"
type="number"
style="width: 100%"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="附件张数" prop="files_num">
<el-input-number v-model="formData.files_num" :controls="false"
:max="1000000000" :min="0" controls-position="right"
placeholder="请填写附件张数"
style="width: 100%"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="慰问时间" prop="occur_time">
<el-date-picker
v-model="formData.occur_time"
clearable
placeholder="慰问时间"
style="width: 100%"
type="date"
value-format="yyyy-MM-dd">
</el-date-picker>
</el-form-item>
</el-col>
<template v-if="formData.typeCode==='E'">
<el-col :span="12">
<el-form-item label="去逝时间" prop="dead_time">
<el-date-picker
v-model="formData.dead_time"
clearable
placeholder="去逝时间"
style="width: 100%"
type="date"
value-format="yyyy-MM-dd">
</el-date-picker>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="与被慰问人关系" prop="dead_gx">
<el-select v-model="formData.dead_gx" style="width: 100%" placeholder="请选择与被慰问人关系">
<el-option label="配偶" value="配偶"></el-option>
<el-option label="父亲" value="父亲"></el-option>
<el-option label="母亲" value="母亲"></el-option>
<el-option label="子女" value="子女"></el-option>
</el-select>
</el-form-item>
</el-col>
</template>
<template v-if="formData.typeCode==='A'">
<el-col :span="12">
<el-form-item label="结婚时间" prop="marry_time">
<el-date-picker
v-model="formData.marry_time"
clearable
placeholder="结婚时间"
style="width: 100%"
type="date"
value-format="yyyy-MM-dd">
</el-date-picker>
</el-form-item>
</el-col>
</template>
<template v-if="formData.typeCode==='B'">
<el-col :span="12">
<el-form-item label="生育时间" prop="birth_time">
<el-date-picker
v-model="formData.birth_time"
clearable
placeholder="生育时间"
style="width: 100%"
type="date"
value-format="yyyy-MM-dd">
</el-date-picker>
</el-form-item>
</el-col>
</template>
</el-row>
<el-row v-else gutter="60">
<el-col :span="12">
<el-form-item label="活动名称" prop="activity_name">
<el-input type="text" v-model="formData.activity_name" placeholder="请输入活动名称"></el-input>
</el-form-item>
</el-col>
<el-col v-if="formData.reimbursementItemId=='fyhd'" :span="12">
<el-form-item label="活动类型" prop="activity_type">
<el-select v-model="formData.activity_type" placeholder="请选择活动类型" style="width: 100%">
<el-option label="分工会活动" value="1"></el-option>
<el-option label="校工会活动" value="2"></el-option>
<el-option label="协会(社团)活动" value="3"></el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="活动人数" prop="activity_number" v-if="formData.reimbursementItemId=='fyhd'">
<el-input v-model="formData.activity_number" placeholder="请输入活动人数" type="number"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="活动地点" prop="venue">
<el-input v-model="formData.venue" placeholder="请输入活动地点" type="text"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="报销金额" prop="money">
<el-input v-model="formData.money" placeholder="输入报销金额"
type="number"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="活动时间" prop="activity_time">
<el-date-picker v-model="formData.activity_time"
placeholder="活动时间"
style="width: 100%" type="date"
value-format="yyyy-MM-dd">
</el-date-picker>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="附件张数" v-if="formData.reimbursementItemId=='fyhd'" prop="files_num">
<el-input-number v-model="formData.files_num" :controls="false"
:max="1000000000" :min="0" controls-position="right"
placeholder="请填写附件张数"
style="width: 100%"></el-input-number>
</el-form-item>
</el-col>
</el-row>
<!-- <el-col :span="24">
<el-form-item label="参加随行人员" prop="personnel">
<el-input v-model="formData.personnel" :autosize="{ minRows: 4, maxRows: 8}" maxlength="500"
placeholder="请填写参加随行人员" type="textarea"></el-input>
</el-form-item>
</el-col>-->
<el-col :span="24" v-if="formData.reimbursementItemId==='fyww'||formData.reimbursementItemId==='zfww'">
<el-form-item label="慰问原因" prop="cause">
<el-input v-model="formData.cause" :autosize="{ minRows: 4, maxRows: 8}" maxlength="500"
placeholder="请填写慰问原因" type="textarea"></el-input>
</el-form-item>
</el-col>
<el-col :span="24">
<el-form-item label="备注" prop="remark">
<el-input v-model="formData.remark" :autosize="{ minRows: 4, maxRows: 8}" maxlength="500"
placeholder="需要填写: 发票编号、开具方、金额" type="textarea"></el-input>
</el-form-item>
</el-col>
<el-col :span="24">
<el-divider content-position="left" class="dia"><span style="color: #3ea1ec;">购置物品及价格</span>
</el-divider>
<el-form-item label="">
<el-button style="float: right;margin-bottom: 10px" icon="el-icon-plus" size="mini"
@click="formData.goods.push({name:'',price:''})">
添加
</el-button>
<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" label="摘要" align="center"
header-align="center">
<template slot-scope="{row}">
<el-input maxlength="50" placeholder="摘要" v-model="row.name"
type="text"></el-input>
</template>
</el-table-column>
<el-table-column prop="price" label="金额" align="center"
header-align="center">
<template slot-scope="{row}">
<el-input maxlength="50" placeholder="金额" v-model="row.price"
type="number" @input="blur"></el-input>
</template>
</el-table-column>
<el-table-column label="操作" fixed="right" align="center" header-align="center"
width="80px"
fixed="right">
<template slot-scope="scope">
<el-button type="danger" icon="el-icon-delete" circle
:disabled="formData.goods.length==0"
@click="delNotesItem(scope)"></el-button>
</template>
</el-table-column>
</el-table>
</el-form-item>
</el-col>
<el-col :span="24">
<el-form-item label="附件" prop="files">
<file-upload card :files.sync="formData.files"></file-upload>
</el-form-item>
</el-col>
</el-form>
<div style="float: right;margin: 20px 0">
<el-button type="primary" @click="doAdd()">确 定</el-button>
</div>
</el-card>
</guava>
</div>
<script>
const vue = new Vue({
el: '#app',
mixins: [initTableMixins],
data() {
return {
userList: [],
oldMoney: 0,
delNotesList: [],
balance: 0,
formData: {goods: []},
ReimbursementIsSign: false,
typeOptions: [],
typeOptions2: [],
userOptions: [],
reimbursementItem: [
{key: "fyww", name: '慰问', type: "fy"},
{key: "fyhd", name: '活动', type: "fy"},
{key: "fyjj", name: '建家', type: "fy"},
{key: "fyrc", name: '日常', type: "fy"},
{key: "zfww", name: '慰问', type: "zf"},
{key: "zfzj", name: '专家', type: "zf"},
{key: "zflw", name: '劳务', type: "zf"},
],
paymentMethod: [
{key: "zz", name: '转账'},
{key: "xj", name: '现金'},
],
rules: {
be_user: [{required: true, message: '必填', trigger: ['change', 'blur']}],
reimbursementItemSort: [{required: true, message: '请选择报销类别', trigger: ['change', 'blur']}],
reimbursementItemId: [{required: true, message: '请选择报销项目', trigger: ['change', 'blur']}],
paymentMethodId: [{required: true, message: '请输入支付方式', trigger: ['change', 'blur']}],
mobile: [{required: true, message: '请输入联系方式', trigger: ['change', 'blur']}],
conMobile: [{required: true, message: '请输入慰问人联系方式', trigger: ['change', 'blur']}],
type: [{required: true, message: '请选择慰问类型', trigger: ['change', 'blur']}],
occur_time: [{required: true, message: '请输入慰问时间', trigger: ['change', 'blur']}],
money: [{required: true, message: '请输入慰问金额', trigger: ['change', 'blur']}],
personnel: [{required: true, message: '请填写参加随行人员', trigger: ['change', 'blur']}],
cause: [{required: true, message: '请填写支付内容', trigger: ['change', 'blur']}],
remark: [{required: false, message: '必填', trigger: ['change', 'blur']}],
files_num: [{required: true, message: '必填', trigger: ['change', 'blur']}],
bankUserName: [{required: true, message: '必填', trigger: ['change', 'blur']}],
user_id: [{required: true, message: '必填', trigger: ['change', 'blur']}],
bankCardNumber: [{required: true, message: '必填', trigger: ['change', 'blur']}],
bankOfDeposit: [{required: true, message: '必填', trigger: ['change', 'blur']}],
activity_name: [{required: true, message: '必填', trigger: ['change', 'blur']}],
},
}
},
methods: {
userChangeHm(val) {
if (!val) {
this.$set(this.formData, 'bankUserName', null)
this.$set(this.formData, 'bankCardNumber', null)
this.$set(this.formData, 'bankOfDeposit', null)
return
}
const user = this.userList.find(v => v.id === val)
this.$set(this.formData, 'bankUserName', user.username)
this.$set(this.formData, 'bankCardNumber', user.bank_number)
this.$set(this.formData, 'bankOfDeposit', user.bank_number ? bankCardAttribution(user.bank_number).bankName : '')
},
async remoteMethod(query) {
const arr = await searchUser(query, null, null, null, null)
this.userList = arr
},
blur() {
let num = 0
this.formData.goods.forEach(v => {
num += parseFloat(v.price)
})
if (num > this.oldMoney && (this.formData.reimbursementItemId === "fyww" || this.formData.reimbursementItemId === "zfww")) {
this.notifyWarning("您的金额超过报销金额(" + this.oldMoney + "")
this.$set(this.formData, "money", this.oldMoney)
return
}
this.$set(this.formData, "money", num ? num : 0)
},
delNotesItem(scope) {
this.delNotesList.push(scope.row.id)
this.formData.goods.splice(scope.$index, 1)
},
doAdd() {
this.$refs["addForm"].validate(async (valid) => {
if (valid) {
if (this.balance < this.formData.money) {
this.notifyWarning("余额不足,请联系校工会")
return
}
const loading = this.$loading({
lock: true,
text: '正在提交...',
spinner: 'el-icon-loading',
background: COVER_LAYER_COLOR
});
const data = this.formData
data.starting_time = data.hospital_time ? data.hospital_time[0] : ''
data.end_time = data.hospital_time ? data.hospital_time[1] : ''
const resp = await $.post(loc() + (this.formData.id ? "/doEdit" : "/doAdd"), {
data: JSON.stringify(data)
})
if (resp.code === 0) {
this.notifySuccess(resp.msg)
window.location.href = '/activity/reimbursement/list'
} else {
this.notifyWarning(resp.msg)
loading.close()
}
}
}
)
},
reimbursementItemSortChange(val) {
this.$set(this.formData, "type", null)
this.$set(this.formData, "money", null)
this.$set(this.formData, "way", null)
this.$set(this.formData, "typeName", null)
this.$set(this.formData, "typeCode", null)
const type = this.typeOptions
if (val === 'fy') {
this.typeOptions2 = type.filter(v => v.way === '慰问品 (C)')
} else {
this.typeOptions2 = type.filter(v => v.way === '慰问金 (A)')
}
},
paymentMethodChange(val) {
const paymentMethodName = this.paymentMethod.find(v => v.key == val)
this.$set(this.formData, "paymentMethodName", paymentMethodName.name)
},
reimbursementItemChange(val) {
const reimbursementItem = this.reimbursementItem.find(v => v.key == val)
this.$set(this.formData, "reimbursementItemName", reimbursementItem.name)
if (this.$refs["addForm"])
this.$refs["addForm"].clearValidate();
},
async initData() {
this.$set(this.formData, "reimbursementItemSort", "fy")
this.$set(this.formData, "userName", "${@shiro.getPrincipalProperty('username')}")
this.$set(this.formData, "loginName", "${@shiro.getPrincipalProperty('loginname')}")
this.$set(this.formData, "unitName", "${@shiro.getPrincipalProperty('unit').getName()}")
this.$set(this.formData, "unionName", "${@shiro.getPrincipalProperty('union').getUnionname()}")
this.$set(this.formData, "mobile", "${@shiro.getPrincipalProperty('mobile')}")
this.$set(this.formData, "reimbursementItemId", "fyww")
await this.getTypeOptions()
this.reimbursementItemSortChange(this.formData.reimbursementItemSort)
this.reimbursementItemChange(this.formData.reimbursementItemId)
await this.getBalance()
},
async getBalance() {
const {data} = await $.get(loc() + "/getBalance")
this.balance = data
},
async userRemoteMethod(query) {
if (query) {
const {data} = await $.get("/platform/fw/condolence/apply/queryUser", {query})
this.userOptions = data
}
},
async getTypeOptions() {
const {code, data} = await $.get("/platform/condolence/type/getAll")
if (code == 0) {
this.typeOptions = data
}
},
async typeChange(id) {
const {data, code, msg} = await $.get("/platform/condolence/type/findOne", {id})
if (data) {
this.$set(this, "oldMoney", data.money)
this.$set(this.formData, "money", data.money)
this.$set(this.formData, "way", data.way)
this.$set(this.formData, "typeName", data.name)
this.$set(this.formData, "typeCode", data.code)
}
},
async getUserData(userId) {
const {data} = await $.get("/platform/fw/condolence/apply/getUserData", {userId})
return data
},
async userChange() {
const userData = await this.getUserData(this.formData.be_user);
this.$set(this.formData, 'sex', userData.sex)
this.$set(this.formData, 'birthday', userData.birthday)
this.$set(this.formData, 'idcard', userData.idcard)
this.$set(this.formData, 'conMobile', userData.mobile)
this.$set(this.formData, 'job_title', userData.jobtitle)
},
async findData(id) {
const refs = await $.get(loc() + "/findOne", {id})
this.formData = refs.data
const userData = await this.getUserData(this.formData.be_user);
this.userOptions.push(userData)
await this.userChange()
}
},
async created() {
this.initData()
const id = getQueryVariable("id")
if (id) await this.findData(id)
}
})
</script>
<!--#
}
#-->
@@ -0,0 +1,382 @@
<!--#
layout("/layouts/platform.html"){
#-->
<style>
input[type="file"] {
display: none
}
.el-input-number input {
text-align: left !important;
}
.el-input-number__decrease, .el-input-number__increase {
display: none;
}
</style>
<div class="platform" id="app" v-cloak>
<guava padding="0% 5%" ref="guava">
<template>
<el-card shadow="never">
<search>
<search-item label="年&emsp;&emsp;度:">
<el-date-picker
placeholder="选择年"
style="width: 150px"
style="width: 100%"
type="year" v-model="pageForm.year"
value-format="yyyy">
</el-date-picker>
</search-item>
<search-item label="所属工会:">
<el-select @change="flushUnits" @clear="flushUnits" clearable="true"
filterable="true"
placeholder="所属工会" style="width: 100%;"
v-model="pageForm.unionId">
<el-option :label="item.unionname" :value="item.id" v-for="item in unions"></el-option>
</el-select>
</search-item>
<search-item label="所属单位:">
<el-select clearable="true" filterable="true" placeholder="所属单位"
style="width: 100%;"
v-model="pageForm.unitId">
<el-option :label="item.name" :value="item.id" v-for="item in units"></el-option>
</el-select>
</search-item>
<template v-if="searchMore">
<search-item label="报销项目">
<el-select clearable style="width: 100%" v-model="pageForm.reiItemId">
<el-option :value="4" label="慰问"></el-option>
<el-option :value="1" label="文体活动"></el-option>
<el-option :value="2" label="日常活动"></el-option>
<el-option :value="3" label="其它活动"></el-option>
</el-select>
</search-item>
</template>
<div class="search-query">
<el-button @click="doSearch" icon="el-icon-search" type="primary">搜索</el-button>
<more v-model="searchMore"></more>
</div>
</search>
</el-card>
<el-card class="mt10" shadow="never">
<table-tool :app="this" label="报销列表">
<template #func>
<div class="pull-right offscreen-right mt5">
<el-radio-group @change="doSearch" size="medium" v-model="pageForm.isAudit">
<el-radio-button :label="true">已审核</el-radio-button>
<el-radio-button :label="false">未审核</el-radio-button>
</el-radio-group>
</div>
</template>
</table-tool>
<el-row class="el-table-container">
<el-table :data="tableData" @sort-change="pageOrder" row-key="id" style="width: 100%"
v-loading="tabLoading">
<el-table-column :index="indexMethod" align="center" header-align="center" label="序号"
type="index"
width="80px"></el-table-column>
<el-table-column
:label="column.label"
:prop="column.prop"
:sortable="column.sortable"
align="center"
header-align="center"
v-for="column in tableColumns">
<template scope="{row}" v-if="column.prop==='stateId'">
<span :style="'color:'+row.stateColor">{{row.stateName}}</span>
</template>
<template scope="{row}" v-else-if="column.prop==='unitName'">
{{isDisPlayCode?''+row.unitcode+'':null}}{{row.unitName}}
</template>
<template scope="{row}" v-else-if="column.prop==='unionname'">
{{isDisPlayCode?''+row.unioncode+'':null}}{{row.unionname}}
</template>
<template scope="{row}" v-else-if="column.prop=='description'">
<span>{{row.activity_name!=null?'活动名称:'+row.activity_name:'被慰问人:'+row.be_username}}</span>
</template>
</el-table-column>
<el-table-column align="center" fixed="right" header-align="center" label="操作" width="150px">
<template scope="{row}">
<el-dropdown @command="dropdownCommand">
<el-button :loading="row.loading" 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:'Review',data:row}"
:disabled="row.State!=3050">
审核
</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
</template>
</el-table-column>
</el-table>
</el-row>
<!--#include("/layouts/pagination.html"){}#-->
</el-card>
</template>
<template #edit>
<activity-bx-info handle label="分工会审核" ref="act_info2" v-show="reimbursementItemId!=4">
<template #handle>
<el-form :model="formData" :rules="formRules" label-position="right" label-width="120px"
ref="form"
style="padding: 20px 0">
<el-form-item class="view-header" label="审核信息&emsp;" label-width="135px">
</el-form-item>
<el-row gutter="20">
<el-col :span="12">
<el-form-item label="审核人员" prop="username">
<el-input disabled
v-model="formData.username"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="审核时间" prop="time">
<el-input disabled v-model="formData.time"></el-input>
</el-form-item>
</el-col>
</el-row>
<el-form-item label="审核意见" prop="auditOpinion">
<el-input maxlength="500" placeholder="请填写您的审核意见" rows="4" type="textarea"
v-model="formData.auditOpinion"></el-input>
</el-form-item>
<el-form-item label="签&emsp;&emsp;字" prop="auditSign" v-if="!ReimbursementIsSign">
<sign :qz.sync="formData.auditSign" prefix="condolence"></sign>
</el-form-item>
</el-form>
<div style="float: right;margin: 20px 0">
<el-button :disabled="subDis" :loading="subLoading1" @click="doReview(false)" type="danger">
</el-button>
<el-button :disabled="subDis" :loading="subLoading2" @click="doReview(true)" type="success">
</el-button>
</div>
</template>
</activity-bx-info>
<info handle label="分工会审核" ref="info2" v-show="reimbursementItemId==4">
<template #handle>
<el-form :model="formData" :rules="formRules" label-position="right" label-width="120px"
ref="form"
style="padding: 20px 0">
<el-form-item class="view-header" label="审核信息&emsp;" label-width="135px">
</el-form-item>
<el-row gutter="20">
<el-col :span="12">
<el-form-item label="审核人员" prop="username">
<el-input disabled
v-model="formData.username"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="审核时间" prop="time">
<el-input disabled v-model="formData.time"></el-input>
</el-form-item>
</el-col>
</el-row>
<el-form-item label="审核意见" prop="auditOpinion">
<el-input maxlength="500" placeholder="请填写您的审核意见" rows="4" type="textarea"
v-model="formData.opinion"></el-input>
</el-form-item>
<el-form-item label="签&emsp;&emsp;字" prop="sign" v-if="!ReimbursementIsSign">
<sign :qz.sync="formData.sign" prefix="condolence"></sign>
</el-form-item>
</el-form>
<div style="float: right;margin: 20px 0">
<el-button :disabled="subDis" :loading="subLoading1" @click="doReview(false)" type="danger">
</el-button>
<el-button :disabled="subDis" :loading="subLoading2" @click="doReview(true)" type="success">
</el-button>
</div>
</template>
</info>
</template>
<template #view>
<activity-bx-info ref="act_info" v-show="reimbursementItemId!=4"></activity-bx-info>
<info ref="info" v-show="reimbursementItemId==4"></info>
</template>
</guava>
</div>
<script>
const vue = new Vue({
el: '#app',
mixins: [initTableMixins],
data() {
return {
ReimbursementIsSign: false,
reimbursementItemId: "",
unions: [],
units: [],
tabLoading: false,
userOptions: [],
formData: {},
tableData: [],
typeOptions: [],
pageForm: {
isAudit: false,
year: new Date().getFullYear() + ""
},
formRules: {
/* auditOpinion: [{required: true, message: '必填', trigger: ['blur', 'change']}],
opinion: [{required: true, message: '必填', trigger: ['blur', 'change']}],*/
},
tableColumns: [
{prop: 'userName', label: '经办人'},
{prop: 'unionname', label: '所在工会'},
{prop: 'unitName', label: '所在单位', sortable: true},
{prop: 'mobile', label: '联系方式'},
{prop: 'reimbursementItemName', label: '报销项目', sortable: true},
{prop: 'applyTime', label: '申请时间', sortable: true},
{prop: 'stateId', label: '申请状态'},
{prop: 'description', label: '备注'},
],
subDis: false,
subLoading1: false,
subLoading2: false,
subLoading3: false,
}
},
components: {
'guava': httpVueLoader('/components/plugins/Guava.vue'),
'file-upload': httpVueLoader('/components/plugins/FileUpload.vue'),
'sign': httpVueLoader('/components/sign/sign.vue?v=2.0.0'),
'info': httpVueLoader('/components/condolence/Info.vue'),
'activity-bx-info': httpVueLoader('/components/activityBx/ActivityBxInfo.vue'),
},
methods: {
dropdownCommand(command) {
const {type, data} = command
if (type == 'view') {
this.openView(data)
} else if (type == 'Review') {
this.openReview(data)
}
},
doReview(flag) {
this.$refs["form"].validate(async (valid) => {
const conMoney = this.$refs.info2.viewData.money
const actMoney = this.$refs.act_info2.viewData.activity_money
this.formData.money = this.formData.reimbursementItemId != 4 ? actMoney : conMoney
if (valid) {
this.formData.flag = flag
this.subDis = true
flag ? this.subLoading2 = true : this.subLoading1 = true
const resp = await $.post(loc() + "/doReview", this.formData)
requestLaterMsgFun(vue, resp, null, null, (v) => {
this.subDis = false
this.subLoading1 = false
this.subLoading2 = false
this.pageData()
this.$refs.guava.index()
})
}
})
},
openReview(row) {
const {reimbursementId, reimbursementItemId} = row
this.reimbursementItemId = reimbursementItemId
this.formData = {
id: reimbursementId,
username: "${@shiro.getPrincipalProperty('username')}",
time: moment().format('YYYY-MM-DD'),
reimbursementItemId: reimbursementItemId,
}
this.subLoading1 = false
this.subLoading2 = false
this.subLoading3 = false
if (reimbursementItemId != 4) {
this.$refs.act_info2.getActInfo(reimbursementId)
} else {
this.$refs.info2.getInfo(reimbursementId)
}
this.$refs.guava.edit()
if (this.$refs['form']) {
this.$refs['form'].resetFields()
}
},
openView(row) {
const {reimbursementId, reimbursementItemId} = row
this.reimbursementItemId = reimbursementItemId
if (reimbursementItemId != 4) {
this.$refs.act_info.getActInfo(reimbursementId)
} else {
this.$refs.info.getInfo(reimbursementId)
}
this.$refs.guava.view()
},
async getTypeOptions() {
const {code, data} = await $.get("/platform/condolence/type/getAll")
if (code == 0) {
this.typeOptions = data
}
},
async flushUnits() {
this.$set(this.pageForm, "unitId", "")
this.units = await getUnits(this.pageForm.unionId)
},
},
async created() {
this.pageData();
this.getTypeOptions()
if ("${@shiro.hasRole('sysadmin')}" === 'true') {
this.unions = await getUnionList(null)
} else {
this.unions = await getUnionList("${@shiro.getPrincipalProperty('unit').getUnionid()}")
this.pageForm.unionId = this.unions[0].id
}
this.flushUnits()
const aa = await getDictState("ReimbursementIsSign")
this.ReimbursementIsSign = aa.disabled
}
})
</script>
<!--#
}
#-->
@@ -0,0 +1,357 @@
<!--#
layout("/layouts/platform.html"){
#-->
<div class="platform" id="app" v-cloak>
<guava padding="0% 5%" ref="guava">
<template>
<el-card shadow="never">
<search>
<search-item label="年&emsp;&emsp;度:">
<el-date-picker
placeholder="选择年"
style="width: 150px"
style="width: 100%"
type="year" v-model="pageForm.year"
value-format="yyyy">
</el-date-picker>
</search-item>
<search-item label="所属工会:">
<el-select @change="flushUnits" @clear="flushUnits" clearable="true"
filterable="true"
placeholder="所属工会" style="width: 100%;"
v-model="pageForm.unionId">
<el-option :label="item.unionname" :value="item.id" v-for="item in unions"></el-option>
</el-select>
</search-item>
<search-item label="所属单位:">
<el-select clearable="true" filterable="true" placeholder="所属单位"
style="width: 100%;"
v-model="pageForm.unitId">
<el-option :label="item.name" :value="item.id" v-for="item in units"></el-option>
</el-select>
</search-item>
<template v-if="searchMore">
<search-item label="报销项目">
<el-select clearable style="width: 100%" v-model="pageForm.reiItemId">
<el-option :value="4" label="慰问"></el-option>
<el-option :value="1" label="文体活动"></el-option>
<el-option :value="2" label="日常活动"></el-option>
<el-option :value="3" label="其它活动"></el-option>
</el-select>
</search-item>
</template>
<div class="search-query">
<el-button @click="doSearch" icon="el-icon-search" type="primary">搜索</el-button>
<more v-model="searchMore"></more>
</div>
</search>
</el-card>
<el-card class="mt10" shadow="never">
<table-tool :app="this" label="报销列表">
<template #func>
<div class="pull-right offscreen-right mt5">
<el-radio-group @change="doSearch" size="medium" v-model="pageForm.isAudit">
<el-radio-button :label="true">已审核</el-radio-button>
<el-radio-button :label="false">未审核</el-radio-button>
</el-radio-group>
</div>
</template>
</table-tool>
<el-row class="el-table-container">
<el-table :data="tableData" @sort-change="pageOrder" row-key="id" style="width: 100%"
v-loading="tabLoading">
<el-table-column :index="indexMethod" align="center" header-align="center" label="序号"
type="index"
width="80px"></el-table-column>
<el-table-column
:label="column.label"
:prop="column.prop"
:sortable="column.sortable"
align="center"
header-align="center"
v-for="column in tableColumns">
<template scope="{row}" v-if="column.prop=='stateId'">
<span :style="'color:'+row.stateColor">{{row.stateName}}</span>
</template>
</el-table-column>
<el-table-column align="center" fixed="right" header-align="center" label="操作" width="150px">
<template scope="{row}">
<el-dropdown @command="dropdownCommand">
<el-button :loading="row.loading" 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:'Review',data:row}"
:disabled="row.State!=3070">
审核
</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
</template>
</el-table-column>
</el-table>
</el-row>
<!--#include("/layouts/pagination.html"){}#-->
</el-card>
</template>
<template #edit>
<activity-bx-info handle label="财务审核" ref="act_info2" v-show="reimbursementItemId!=4">
<template #handle>
<el-form :model="formData" :rules="formRules" label-position="right" label-width="120px"
ref="form"
style="padding: 20px 0">
<el-form-item class="view-header" label="审核信息&emsp;" label-width="135px">
</el-form-item>
<el-row gutter="20">
<el-col :span="12">
<el-form-item label="审核人员" prop="username">
<el-input disabled
v-model="formData.username"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="审核时间" prop="time">
<el-input disabled v-model="formData.time"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="报销金额" prop="activity_money">
<el-input v-model="formData.activity_money"></el-input>
</el-form-item>
</el-col>
</el-row>
<el-form-item label="审核意见" prop="auditOpinion">
<el-input maxlength="500" placeholder="请填写您的审核意见" rows="4" type="textarea"
v-model="formData.auditOpinion"></el-input>
</el-form-item>
<el-form-item label="签&emsp;&emsp;字" prop="auditSign" v-if="!ReimbursementIsSign">
<sign :qz.sync="formData.auditSign" prefix="condolence"></sign>
</el-form-item>
</el-form>
<div style="float: right;margin: 20px 0">
<el-button :disabled="subDis" :loading="subLoading1" @click="doReview(false)" type="danger">
</el-button>
<el-button :disabled="subDis" :loading="subLoading2" @click="doReview(true)" type="success">
</el-button>
</div>
</template>
</activity-bx-info>
<info handle label="财务审核" ref="info2" v-show="reimbursementItemId==4">
<template #handle>
<el-form :model="formData" :rules="formRules" label-position="right" label-width="120px"
ref="form"
style="padding: 20px 0">
<el-form-item class="view-header" label="审核信息&emsp;" label-width="135px">
</el-form-item>
<el-row gutter="20">
<el-col :span="12">
<el-form-item label="审核人员" prop="username">
<el-input disabled
v-model="formData.username"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="审核时间" prop="time">
<el-input disabled v-model="formData.time"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="报销金额" prop="money">
<el-input v-model="formData.money"></el-input>
</el-form-item>
</el-col>
</el-row>
<el-form-item label="审核意见" prop="opinion">
<el-input maxlength="500" placeholder="请填写您的审核意见" rows="4" type="textarea"
v-model="formData.opinion"></el-input>
</el-form-item>
<el-form-item label="签&emsp;&emsp;字" prop="sign" v-if="!ReimbursementIsSign">
<sign :qz.sync="formData.sign" prefix="condolence"></sign>
</el-form-item>
</el-form>
<div style="float: right;margin: 20px 0">
<el-button :disabled="subDis" :loading="subLoading1" @click="doReview(false)" type="danger">
</el-button>
<el-button :disabled="subDis" :loading="subLoading2" @click="doReview(true)" type="success">
</el-button>
</div>
</template>
</info>
</template>
<template #view>
<activity-bx-info ref="act_info" v-show="reimbursementItemId!=4"></activity-bx-info>
<info ref="info" v-show="reimbursementItemId==4"></info>
</template>
</guava>
</div>
<script>
const vue = new Vue({
el: '#app',
mixins: [initTableMixins],
data() {
return {
ReimbursementIsSign: false,
reimbursementItemId: "",
unions: [],
units: [],
tabLoading: false,
userOptions: [],
formData: {},
tableData: [],
typeOptions: [],
pageForm: {
isAudit: false,
year: new Date().getFullYear() + ""
},
formRules: {
/* auditOpinion: [{required: true, message: '必填', trigger: ['blur', 'change']}],
opinion: [{required: true, message: '必填', trigger: ['blur', 'change']}],*/
},
tableColumns: [
{prop: 'userName', label: '经办人'},
{prop: 'unionname', label: '所在工会'},
{prop: 'unitName', label: '所在单位', sortable: true},
{prop: 'mobile', label: '联系方式'},
{prop: 'reimbursementItemName', label: '报销项目', sortable: true},
{prop: 'applyTime', label: '申请时间', sortable: true},
{prop: 'stateId', label: '申请状态'},
],
subDis: false,
subLoading1: false,
subLoading2: false,
subLoading3: false,
}
},
components: {
'guava': httpVueLoader('/components/plugins/Guava.vue'),
'file-upload': httpVueLoader('/components/plugins/FileUpload.vue'),
'sign': httpVueLoader('/components/sign/sign.vue?v=2.0.0'),
'info': httpVueLoader('/components/condolence/Info.vue'),
'activity-bx-info': httpVueLoader('/components/activityBx/ActivityBxInfo.vue'),
},
methods: {
dropdownCommand(command) {
const {type, data} = command
if (type == 'view') {
this.openView(data)
} else if (type == 'Review') {
this.openReview(data)
}
},
openView(row) {
const {reimbursementId, reimbursementItemId} = row
this.reimbursementItemId = reimbursementItemId
if (reimbursementItemId != 4) {
this.$refs.act_info.getActInfo(reimbursementId)
} else {
this.$refs.info.getInfo(reimbursementId)
}
this.$refs.guava.view()
},
openReview(row) {
const {reimbursementId, reimbursementItemId, activity_money, money} = row
this.reimbursementItemId = reimbursementItemId
this.formData = {
id: reimbursementId,
username: "${@shiro.getPrincipalProperty('username')}",
time: moment().format('YYYY-MM-DD'),
reimbursementItemId: reimbursementItemId,
activity_money: activity_money,
money: money
}
this.subLoading1 = false
this.subLoading2 = false
this.subLoading3 = false
if (reimbursementItemId != 4) {
this.$refs.act_info2.getActInfo(reimbursementId)
} else {
this.$refs.info2.getInfo(reimbursementId)
}
this.$refs.guava.edit()
if (this.$refs['form']) {
this.$refs['form'].resetFields()
}
},
doReview(flag) {
this.$refs["form"].validate(async (valid) => {
this.formData.money = this.formData.reimbursementItemId != 4 ? this.formData.activity_money : this.formData.money
if (valid) {
console.log(1)
this.formData.flag = flag
this.subDis = true
flag ? this.subLoading2 = true : this.subLoading1 = true
const resp = await $.post(loc() + "/doReview", this.formData)
requestLaterMsgFun(vue, resp, null, null, (v) => {
this.subDis = false
this.subLoading1 = false
this.subLoading2 = false
this.pageData()
this.$refs.guava.index()
})
}
})
},
async flushUnits() {
this.$set(this.pageForm, "unitId", "")
this.units = await getUnits(this.pageForm.unionId)
},
},
async created() {
this.pageData();
this.unions = await getUnionList()
this.flushUnits()
const aa = await getDictState("ReimbursementIsSign")
this.ReimbursementIsSign = aa.disabled
}
})
</script>
<!--#
}
#-->
@@ -0,0 +1,3 @@
const judgmentUnit = "${@shiro.hasRole('sysadmin')||@shiro.hasRole('H04')||@shiro.hasRole('gh12')}" === 'true'
const judgmentUnion = "${@shiro.hasRole('sysadmin')||@shiro.hasRole('A06')||@shiro.hasRole('xghhdwy')}" === 'true'
const judgmentH02 = "${@shiro.hasRole('H02')}" === 'true'
@@ -0,0 +1,351 @@
<!--#
layout("/layouts/platform.html"){
#-->
<div class="platform" id="app" v-cloak>
<guava padding="0% 5%" ref="guava">
<template>
<el-card shadow="never">
<search>
<search-item label="年&emsp;&emsp;度:">
<el-date-picker
placeholder="选择年"
style="width: 150px"
style="width: 100%"
type="year" v-model="pageForm.year"
value-format="yyyy">
</el-date-picker>
</search-item>
<search-item label="所属工会:">
<el-select @change="flushUnits" @clear="flushUnits" clearable="true"
filterable="true"
placeholder="所属工会" style="width: 100%;"
v-model="pageForm.unionId">
<el-option :label="item.unionname" :value="item.id" v-for="item in unions"></el-option>
</el-select>
</search-item>
<search-item label="所属单位:">
<el-select clearable="true" filterable="true" placeholder="所属单位"
style="width: 100%;"
v-model="pageForm.unitId">
<el-option :label="item.name" :value="item.id" v-for="item in units"></el-option>
</el-select>
</search-item>
<template v-if="searchMore">
<search-item label="报销项目">
<el-select clearable style="width: 100%" v-model="pageForm.reiItemId">
<el-option :value="4" label="慰问"></el-option>
<el-option :value="1" label="文体活动"></el-option>
<el-option :value="2" label="日常活动"></el-option>
<el-option :value="3" label="其它活动"></el-option>
</el-select>
</search-item>
</template>
<div class="search-query">
<el-button @click="doSearch" icon="el-icon-search" type="primary">搜索</el-button>
<more v-model="searchMore"></more>
</div>
</search>
</el-card>
<el-card class="mt10" shadow="never">
<table-tool :app="this" label="报销列表">
<template #func>
<div class="pull-right offscreen-right mt5">
<el-radio-group @change="doSearch" size="medium" v-model="pageForm.isAudit">
<el-radio-button :label="true">已审核</el-radio-button>
<el-radio-button :label="false">未审核</el-radio-button>
</el-radio-group>
</div>
</template>
</table-tool>
<el-row class="el-table-container">
<el-table :data="tableData" @sort-change="pageOrder" row-key="id" style="width: 100%"
v-loading="tabLoading">
<el-table-column :index="indexMethod" align="center" header-align="center" label="序号"
type="index"
width="80px"></el-table-column>
<el-table-column
:label="column.label"
:prop="column.prop"
:sortable="column.sortable"
align="center"
header-align="center"
v-for="column in tableColumns">
<template scope="{row}" v-if="column.prop=='stateId'">
<span :style="'color:'+row.stateColor">{{row.stateName}}</span>
</template>
</el-table-column>
<el-table-column align="center" fixed="right" header-align="center" label="操作" width="150px">
<template scope="{row}">
<el-dropdown @command="dropdownCommand">
<el-button :loading="row.loading" 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:'Review',data:row}"
:disabled="row.State!=3060">
审核
</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
</template>
</el-table-column>
</el-table>
</el-row>
<!--#include("/layouts/pagination.html"){}#-->
</el-card>
</template>
<template #edit>
<activity-bx-info handle label="书记审核" ref="act_info2" v-show="reimbursementItemId!=4">
<template #handle>
<el-form :model="formData" :rules="formRules" label-position="right" label-width="120px"
ref="form"
style="padding: 20px 0">
<el-form-item class="view-header" label="审核信息&emsp;" label-width="135px">
</el-form-item>
<el-row gutter="20">
<el-col :span="12">
<el-form-item label="审核人员" prop="username">
<el-input disabled
v-model="formData.username"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="审核时间" prop="time">
<el-input disabled v-model="formData.time"></el-input>
</el-form-item>
</el-col>
</el-row>
<el-form-item label="审核意见" prop="auditOpinion">
<el-input maxlength="500" placeholder="请填写您的审核意见" rows="4" type="textarea"
v-model="formData.auditOpinion"></el-input>
</el-form-item>
<el-form-item label="签&emsp;&emsp;字" prop="auditSign" v-if="!ReimbursementIsSign">
<sign :qz.sync="formData.auditSign" prefix="condolence"></sign>
</el-form-item>
</el-form>
<div style="float: right;margin: 20px 0">
<el-button :disabled="subDis" :loading="subLoading1" @click="doReview(false)" type="danger">
</el-button>
<el-button :disabled="subDis" :loading="subLoading2" @click="doReview(true)" type="success">
</el-button>
</div>
</template>
</activity-bx-info>
<info handle label="书记审核" ref="info2" v-show="reimbursementItemId==4">
<template #handle>
<el-form :model="formData" :rules="formRules" label-position="right" label-width="120px"
ref="form"
style="padding: 20px 0">
<el-form-item class="view-header" label="审核信息&emsp;" label-width="135px">
</el-form-item>
<el-row gutter="20">
<el-col :span="12">
<el-form-item label="审核人员" prop="username">
<el-input disabled
v-model="formData.username"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="审核时间" prop="time">
<el-input disabled v-model="formData.time"></el-input>
</el-form-item>
</el-col>
</el-row>
<el-form-item label="审核意见" prop="opinion">
<el-input maxlength="500" placeholder="请填写您的审核意见" rows="4" type="textarea"
v-model="formData.opinion"></el-input>
</el-form-item>
<el-form-item label="签&emsp;&emsp;字" prop="sign">
<sign :qz.sync="formData.sign" prefix="condolence"></sign>
</el-form-item>
</el-form>
<div style="float: right;margin: 20px 0">
<el-button :disabled="subDis" :loading="subLoading1" @click="doReview(false)" type="danger">
</el-button>
<el-button :disabled="subDis" :loading="subLoading2" @click="doReview(true)" type="success">
</el-button>
</div>
</template>
</info>
</template>
<template #view>
<activity-bx-info ref="act_info" v-show="reimbursementItemId!=4"></activity-bx-info>
<info ref="info" v-show="reimbursementItemId==4"></info>
</template>
</guava>
</div>
<script>
const vue = new Vue({
el: '#app',
mixins: [initTableMixins],
data() {
return {
ReimbursementIsSign: false,
reimbursementItemId: "",
unions: [],
units: [],
tabLoading: false,
userOptions: [],
formData: {},
tableData: [],
typeOptions: [],
pageForm: {
isAudit: false,
year: new Date().getFullYear() + ""
},
formRules: {
/* auditOpinion: [{required: true, message: '必填', trigger: ['blur', 'change']}],
opinion: [{required: true, message: '必填', trigger: ['blur', 'change']}],*/
},
tableColumns: [
{prop: 'userName', label: '经办人'},
{prop: 'unionname', label: '所在工会'},
{prop: 'unitName', label: '所在单位', sortable: true},
{prop: 'mobile', label: '联系方式'},
{prop: 'reimbursementItemName', label: '报销项目', sortable: true},
{prop: 'applyTime', label: '申请时间', sortable: true},
{prop: 'stateId', label: '申请状态'},
],
subDis: false,
subLoading1: false,
subLoading2: false,
subLoading3: false,
}
},
components: {
'guava': httpVueLoader('/components/plugins/Guava.vue'),
'file-upload': httpVueLoader('/components/plugins/FileUpload.vue'),
'sign': httpVueLoader('/components/sign/sign.vue?v=2.0.0'),
'info': httpVueLoader('/components/condolence/Info.vue'),
'activity-bx-info': httpVueLoader('/components/activityBx/ActivityBxInfo.vue'),
},
methods: {
dropdownCommand(command) {
const {type, data} = command
if (type == 'view') {
this.openView(data)
} else if (type == 'Review') {
this.openReview(data)
}
},
openView(row) {
const {reimbursementId, reimbursementItemId} = row
this.reimbursementItemId = reimbursementItemId
if (reimbursementItemId != 4) {
this.$refs.act_info.getActInfo(reimbursementId)
} else {
this.$refs.info.getInfo(reimbursementId)
}
this.$refs.guava.view()
},
openReview(row) {
const {reimbursementId, reimbursementItemId} = row
this.reimbursementItemId = reimbursementItemId
this.formData = {
id: reimbursementId,
username: "${@shiro.getPrincipalProperty('username')}",
time: moment().format('YYYY-MM-DD'),
reimbursementItemId: reimbursementItemId,
}
this.subLoading1 = false
this.subLoading2 = false
this.subLoading3 = false
if (reimbursementItemId != 4) {
this.$refs.act_info2.getActInfo(reimbursementId)
} else {
this.$refs.info2.getInfo(reimbursementId)
}
this.$refs.guava.edit()
if (this.$refs['form']) {
this.$refs['form'].resetFields()
}
},
doReview(flag) {
this.$refs["form"].validate(async (valid) => {
const conMoney = this.$refs.info2.viewData.money
const actMoney = this.$refs.act_info2.viewData.activity_money
this.formData.money = this.formData.reimbursementItemId != 4 ? actMoney : conMoney
if (valid) {
this.formData.flag = flag
this.subDis = true
flag ? this.subLoading2 = true : this.subLoading1 = true
const resp = await $.post(loc() + "/doReview", this.formData)
requestLaterMsgFun(vue, resp, null, null, (v) => {
this.subDis = false
this.subLoading1 = false
this.subLoading2 = false
this.pageData()
this.$refs.guava.index()
})
}
})
},
async flushUnits() {
this.$set(this.pageForm, "unitId", "")
this.units = await getUnits(this.pageForm.unionId)
},
},
async created() {
this.pageData();
if ("${@shiro.hasRole('sysadmin')}" === 'true') {
this.unions = await getUnionList()
} else {
this.unions = await getUnionList("${@shiro.getPrincipalProperty('unit').getUnionid()}")
this.pageForm.unionId = this.unions[0].id
}
this.flushUnits()
const aa = await getDictState("ReimbursementIsSign")
this.ReimbursementIsSign = aa.disabled
}
})
</script>
<!--#
}
#-->