This commit is contained in:
shilixia 2021-08-23 16:02:46 +08:00
parent ac58f5d97c
commit 4efefba09f
2 changed files with 34 additions and 10 deletions

View File

@ -119,7 +119,7 @@ export const asyncRoutes = [
path: 'records', path: 'records',
name: 'Records', name: 'Records',
component: () => import('@/views/ability/records.vue'), component: () => import('@/views/ability/records.vue'),
meta: { title: '资质能力报送任务', perms: ['records_view'] } meta: { title: '资质能力报送任务', perms: ['record_view'] }
}, },
] ]

View File

@ -48,8 +48,8 @@
<el-table <el-table
style="margin-top:4px" style="margin-top:4px"
:data="TableList" :data="TableList.results"
border border
fit fit
stripe stripe
highlight-current-row highlight-current-row
@ -57,11 +57,11 @@
> >
<el-table-column type="index" width="50" /> <el-table-column type="index" width="50" />
<el-table-column align="center" label="上报说明"> <el-table-column align="center" label="上报说明">
<template slot-scope="scope"> <template slot-scope="scope" v-if="scope.row.noteb">
{{ scope.row.noteb }} {{ scope.row.noteb }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="报送文件"> <el-table-column label="报送文件">
<template slot-scope="scope" v-if="scope.row.files"> <template slot-scope="scope" v-if="scope.row.files">
<div v-for="item in scope.row.files_" v-bind:key="item.id"> <div v-for="item in scope.row.files_" v-bind:key="item.id">
@ -71,6 +71,15 @@
</div> </div>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column
label="报送单位"
sortable="custom"
prop="belong_dept__sort"
>
<template slot-scope="scope" v-if="scope.row.belong_dept">{{
scope.row.belong_dept_.name
}}</template>
</el-table-column>
<el-table-column <el-table-column
align="center" align="center"
label="操作" label="操作"
@ -110,6 +119,13 @@
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
<pagination
v-show="TableList.count > 0"
:total="TableList.count"
:page.sync="listQuery.page"
:limit.sync="listQuery.page_size"
@pagination="getrecordlist"
/>
</el-card> </el-card>
</el-col> </el-col>
</el-row> </el-row>
@ -184,13 +200,14 @@ import { getRecordList, createRecord, updateRecord,
deleteRecord, } from "@/api/record"; deleteRecord, } from "@/api/record";
import { getContentList } from "@/api/content"; import { getContentList } from "@/api/content";
import checkPermission from "@/utils/permission"; import checkPermission from "@/utils/permission";
import Pagination from "@/components/Pagination";
import { upUrl, upHeaders } from "@/api/file"; import { upUrl, upHeaders } from "@/api/file";
const defaultContent = { const defaultContent = {
noteb:"", noteb:"",
files:[], files:[],
}; };
export default { export default {
components: { }, components: {Pagination },
data() { data() {
return { return {
@ -202,7 +219,10 @@ export default {
fileList: [], fileList: [],
recordTable:defaultContent, recordTable:defaultContent,
TableList: [], TableList: [],
listQuery: {
page: 1,
page_size: 20,
},
listLoading: true, listLoading: true,
dialogType: "new", dialogType: "new",
@ -233,7 +253,8 @@ export default {
}, },
getrecordlist(){ getrecordlist(){
getRecordList({pageoff:true,can_doself: true}).then((response) => { this.listQuery.can_doself= true;
getRecordList(this.listQuery).then((response) => {
if (response.data) { if (response.data) {
this.TableList = response.data; this.TableList = response.data;
} }
@ -241,8 +262,11 @@ export default {
}, },
//点击材料清大弹出该清单下对应报送任务 //点击材料清大弹出该清单下对应报送任务
recorclickRow(row) { recorclickRow(row) {
this.content=row.id; this.listQuery.can_doself= true;
getRecordList({pageoff:true,can_doself: true,content:this.content}).then((response) => { this.listQuery.content= row.id;
this.content = row.id;
getRecordList(this.listQuery).then((response) => {
if (response.data) { if (response.data) {
this.TableList = response.data; this.TableList = response.data;
} }