first commit
This commit is contained in:
@@ -0,0 +1,270 @@
|
||||
<!--#
|
||||
layout("/layouts/platform.html"){
|
||||
#-->
|
||||
<!--
|
||||
校工会主席审核
|
||||
-->
|
||||
|
||||
<div id="app" v-cloak>
|
||||
|
||||
<guava ref="guava">
|
||||
<template>
|
||||
<search :page_form.sync="pageForm" @search="doSearch" :has_sh="true">
|
||||
<template #column>
|
||||
<div class="btn-group tool-button mt5">
|
||||
<el-select placeholder="所属工会" v-model="pageForm.unionId" style="width: 100%;"
|
||||
clearable="true"
|
||||
@change="flushUnits" @clear="flushUnits"
|
||||
|
||||
v-if="${@shiro.hasRole('sysadmin')||@shiro.hasRole('A06')||@shiro.hasRole('H03')}"
|
||||
|
||||
filterable="true">
|
||||
<el-option v-for="item in unions" :label="item.unionname" :value="item.id"></el-option>
|
||||
</el-select>
|
||||
</div>
|
||||
|
||||
<div class="btn-group tool-button mt5">
|
||||
<el-select placeholder="所属单位" v-model="pageForm.unitId" style="width: 100%;"
|
||||
clearable="true"
|
||||
filterable="true">
|
||||
<el-option v-for="item in units" :label="item.name" :value="item.id"></el-option>
|
||||
</el-select>
|
||||
</div>
|
||||
|
||||
|
||||
</template>
|
||||
</search>
|
||||
|
||||
<el-row class="el-table-container">
|
||||
<el-table :data="tableData" style="width: 100%" row-key="id" @sort-change="pageOrder"
|
||||
v-loading="tabLoading">
|
||||
<el-table-column align="center" header-align="center" label="序号" width="120px">
|
||||
<template scope="scope">
|
||||
<span>{{scope.$index+(pageForm.pageNumber - 1) * pageForm.pageSize + 1}} </span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
|
||||
<el-table-column label="申请人姓名" prop="user_name" header-align="center"
|
||||
align="center"></el-table-column>
|
||||
|
||||
<el-table-column label="工号" prop="bxr_loginname" header-align="center"
|
||||
align="center"></el-table-column>
|
||||
|
||||
<el-table-column label="所属工会" prop="bxr_unionname" header-align="center" sortable
|
||||
align="center"></el-table-column>
|
||||
<el-table-column label="所属单位" prop="bxr_unitname" header-align="center" sortable
|
||||
align="center"></el-table-column>
|
||||
|
||||
<el-table-column label="活动名称" prop="activity_name" show-overflow-tooltip header-align="center"
|
||||
align="center">
|
||||
<template scope="scope">
|
||||
<el-link type="primary" @click="openView(scope.row)">
|
||||
{{scope.row.activity_name}}
|
||||
</el-link>
|
||||
</template>
|
||||
</el-table-column>
|
||||
|
||||
|
||||
<el-table-column label="活动类型" prop="activity_type" header-align="center" align="center" sortable>
|
||||
<template scope="{row}">
|
||||
<span v-if="row.activity_type==1">基层工会活动</span>
|
||||
<span v-if="row.activity_type==2">校工会活动</span>
|
||||
<span v-if="row.activity_type==3">协会(社团)活动</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
|
||||
<el-table-column label="申请时间" prop="apply_time" header-align="center" sortable
|
||||
align="center"></el-table-column>
|
||||
|
||||
<el-table-column align="center" prop="state_id" header-align="center" label="申请状态" sortable>
|
||||
<template scope="scope">
|
||||
<span :style="'color:'+scope.row.state_color">{{scope.row.state_name}}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
|
||||
|
||||
|
||||
<!--下拉操作按钮-->
|
||||
<el-table-column align="center" header-align="center" label="操作" fixed="right"
|
||||
width="120px">
|
||||
<template slot-scope="{row}">
|
||||
<el-dropdown @command="dropdownCommand">
|
||||
<el-button plain size="mini">
|
||||
<i class="ti-settings"></i>
|
||||
<span class="ti-angle-down"></span>
|
||||
</el-button>
|
||||
<el-dropdown-menu slot="dropdown">
|
||||
<el-dropdown-item :command="{type:'view',data:row}">
|
||||
查看
|
||||
</el-dropdown-item>
|
||||
<el-dropdown-item v-if="[1040].includes(row.state_id)"
|
||||
:command="{type:'primary',data:row}">
|
||||
审核
|
||||
</el-dropdown-item>
|
||||
|
||||
</el-dropdown-menu>
|
||||
</el-dropdown>
|
||||
</template>
|
||||
</el-table-column>
|
||||
|
||||
|
||||
</el-table>
|
||||
</el-row>
|
||||
|
||||
<!--#include("/layouts/pagination.html"){}#-->
|
||||
</template>
|
||||
|
||||
|
||||
<template #edit>
|
||||
<activity-bx-info ref="act_info2" :handle="true" label="校工会主席审核" :panes="[2,3,4,5]">
|
||||
<template #handle>
|
||||
<el-form :model="formData" ref="form" :rules="formRules" label-position="right"
|
||||
style="padding: 20px 0"
|
||||
label-width="120px">
|
||||
<el-form-item label="审核信息 " label-width="135px" class="view-header">
|
||||
</el-form-item>
|
||||
|
||||
<el-row gutter="20">
|
||||
<el-col :span="12">
|
||||
<el-form-item prop="username" label="审核人">
|
||||
<el-input v-model="formData.username"
|
||||
disabled></el-input>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item prop="time" label="审核时间">
|
||||
<el-input v-model="formData.time" disabled></el-input>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
|
||||
<el-form-item prop="idea" label="审核意见">
|
||||
<el-input type="textarea" v-model="formData.idea" rows="4" maxlength="500"
|
||||
placeholder="请填写您的审核意见"></el-input>
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item prop="sign" label="签  字">
|
||||
<sign prefix="medicalAid" :qz.sync="formData.sign"></sign>
|
||||
</el-form-item>
|
||||
|
||||
</el-form>
|
||||
|
||||
<div style="float: right;margin: 20px 0">
|
||||
<el-button type="danger" @click="doReview(false)" :disabled="subDis" :loading="subLoading1">拒
|
||||
绝
|
||||
</el-button>
|
||||
<el-button type="success" @click="doReview(true)" :disabled="subDis" :loading="subLoading2">通
|
||||
过
|
||||
</el-button>
|
||||
</div>
|
||||
</template>
|
||||
</activity-bx-info>
|
||||
</template>
|
||||
|
||||
|
||||
<template #view>
|
||||
<activity-bx-info ref="act_info"></activity-bx-info>
|
||||
</template>
|
||||
|
||||
</guava>
|
||||
</div>
|
||||
|
||||
<script>
|
||||
const vue = new Vue({
|
||||
el: '#app',
|
||||
data() {
|
||||
return {
|
||||
unions: [],
|
||||
units: [],
|
||||
tabLoading: false,
|
||||
tableData: [],
|
||||
formData: {},
|
||||
subDis: false,
|
||||
subLoading1: false,
|
||||
subLoading2: false,
|
||||
pageForm: {
|
||||
isAudit: 1,
|
||||
...getPageForm(),
|
||||
searchName: "username",
|
||||
year: new Date().getFullYear() + ""
|
||||
},
|
||||
formRules: {
|
||||
idea: [{required: true, message: '请填写意见', trigger: ['blur', 'change']}],
|
||||
},
|
||||
}
|
||||
},
|
||||
components: {
|
||||
'search': httpVueLoader('/components/activityBx/ActivityBxSearch.vue'),
|
||||
'guava': httpVueLoader('/components/plugins/Guava.vue'),
|
||||
'activity-bx-info': httpVueLoader('/components/activityBx/ActivityBxInfo.vue'),
|
||||
'sign': httpVueLoader('/components/sign/sign.vue?v=2.0.0')
|
||||
},
|
||||
methods: {
|
||||
//下拉菜单操作
|
||||
dropdownCommand(command) {
|
||||
const {type, data} = command
|
||||
if (type == 'view') {
|
||||
this.openView(data)
|
||||
} else if (type == 'primary') {
|
||||
this.openReview(data)
|
||||
}
|
||||
},
|
||||
|
||||
async doReview(flag) {
|
||||
this.$refs["form"].validate(async (valid) => {
|
||||
if (valid) {
|
||||
this.formData.flag = flag
|
||||
this.subDis = true
|
||||
flag ? this.subLoading2 = true : this.subLoading1 = true
|
||||
const resp = await $.post(location.href + "/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 openReview(row) {
|
||||
const {id} = row
|
||||
this.$set(row, "reviewLoading", true)
|
||||
this.formData = {
|
||||
id,
|
||||
username: "${@shiro.getPrincipalProperty('username')}",
|
||||
time: moment().format('YYYY-MM-DD'),
|
||||
sign: '',
|
||||
}
|
||||
this.$set(row, "reviewLoading", false)
|
||||
this.$refs.act_info2.getActInfo(id)
|
||||
this.$refs.guava.edit()
|
||||
},
|
||||
openView(row) {
|
||||
const {id} = row
|
||||
this.$refs.act_info.getActInfo(id)
|
||||
this.$refs.guava.view()
|
||||
},
|
||||
async flushUnits() {
|
||||
this.$set(this.pageForm, "unitId", "")
|
||||
if ("${@shiro.hasRole('sysadmin')||@shiro.hasRole('A06')||@shiro.hasRole('H03')}" === 'true') {
|
||||
this.units = await getUnits(this.pageForm.unionId)
|
||||
} else {
|
||||
this.units = await getUnits("${@shiro.getPrincipalProperty('unit').getUnionid()}")
|
||||
}
|
||||
},
|
||||
...pageSomeThing
|
||||
},
|
||||
async created() {
|
||||
this.pageData();
|
||||
this.unions = await getUnions()
|
||||
this.flushUnits()
|
||||
}
|
||||
})
|
||||
|
||||
|
||||
</script>
|
||||
<!--#
|
||||
}
|
||||
#-->
|
||||
Reference in New Issue
Block a user