first commit
This commit is contained in:
@@ -0,0 +1,139 @@
|
||||
<!--#
|
||||
layout("/layouts/platform.html"){
|
||||
#-->
|
||||
|
||||
<div id="app" v-cloak>
|
||||
<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
|
||||
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-input clearable
|
||||
placeholder="可输入会议名称、地点进行查询"
|
||||
v-model="pageForm.searchKeyword"></el-input>
|
||||
</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>
|
||||
</template>
|
||||
</table-tool>
|
||||
<el-table :data="tableData" :size="tableSize" @sort-change="pageOrder"
|
||||
align="center" header-align="center">
|
||||
<el-table-column align="center" header-align="center" label="序号" type="index" width="80">
|
||||
<template scope="scope">
|
||||
<span>{{ scope.$index + (pageForm.pageNumber - 1) * pageForm.pageSize + 1 }} </span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
:label="column.label"
|
||||
:prop="column.prop"
|
||||
:sortable="column.sortable"
|
||||
:width="column.width"
|
||||
align="center"
|
||||
header-align="center"
|
||||
show-overflow-tooltip
|
||||
v-for="column in tableColumns"
|
||||
>
|
||||
<template scope="{row}" v-if="column.prop=='isCanLeave'">
|
||||
<span class="text-muted" v-if="row.isCanLeave==null">未设置</span>
|
||||
<span class="text-success" v-if="row.isCanLeave==true">能</span>
|
||||
<span class="text-danger" v-if="row.isCanLeave==false">否</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
|
||||
<el-table-column label="操作" width="300px">
|
||||
<template scope="{row}">
|
||||
<el-button @click="openView(row)" size="mini">查看</el-button>
|
||||
<el-button @click="openEdit(row)" size="mini" type="primary">编辑</el-button>
|
||||
<el-button @click="doDelete(row.id)" size="mini" type="danger">删除</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
|
||||
</el-table>
|
||||
</el-card>
|
||||
</guava>
|
||||
</div>
|
||||
|
||||
<script>
|
||||
<!--# include("/platform/meeting/includeJs/meetingUtil.js"){} #-->
|
||||
const meetUtil = new meetingUtil()
|
||||
window['vue'] = new Vue({
|
||||
el: '#app',
|
||||
mixins: [initTableMixins],
|
||||
data() {
|
||||
return {
|
||||
hold: false,
|
||||
tableColumns: [
|
||||
{prop: 'meetingName', label: '会议名称', sortable: true},
|
||||
{prop: 'meetingTypeName', label: '会议类型', sortable: true},
|
||||
{prop: 'startTime', label: '会议时间', sortable: true},
|
||||
/*{prop: 'endTime', label: '结束时间', sortable: true},*/
|
||||
{prop: 'location', label: '会议地点', sortable: true},
|
||||
{prop: 'isCanLeave', label: '能否请假', sortable: true},
|
||||
],
|
||||
pageForm: {
|
||||
year: new Date().getFullYear().toString()
|
||||
},
|
||||
meetingTypeList: []
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
|
||||
openView(row) {
|
||||
const {id, notifyId, hold} = row
|
||||
window.location.href = '/platform/meeting/manage/createMeeting?notifyId=' + notifyId + "&hold=" + true + "&id=" + id
|
||||
},
|
||||
openEdit(row) {
|
||||
const {id, notifyId, hold} = row
|
||||
window.location.href = '/platform/meeting/manage/createMeeting?notifyId=' + notifyId + "&hold=" + false + "&id=" + id
|
||||
},
|
||||
async doDelete(id) {
|
||||
try {
|
||||
const confirm = await this.$confirm('您确定要删除吗?', '提示', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
})
|
||||
if (confirm === 'confirm') {
|
||||
const resp = await $.post(loc() + '/doDelete', {id})
|
||||
if (resp.code === 0) {
|
||||
this.notifySuccess(resp.msg)
|
||||
this.doSearch()
|
||||
}
|
||||
}
|
||||
} catch (e) {
|
||||
console.log(e)
|
||||
}
|
||||
|
||||
}
|
||||
},
|
||||
async created() {
|
||||
this.meetingTypeList = await meetUtil.getAllMeetingType()
|
||||
this.pageData()
|
||||
}
|
||||
})
|
||||
</script>
|
||||
|
||||
|
||||
<!--#
|
||||
}
|
||||
#-->
|
||||
Reference in New Issue
Block a user