[add] 工作组、分标委在研项目页面
This commit is contained in:
@@ -325,6 +325,12 @@ export default {
|
||||
*/
|
||||
toUnderStudyProject(record) {
|
||||
console.log('在研项目', record)
|
||||
this.$router.push({
|
||||
path: '/projectManagement/CommitteeMaintenance/UnderStudyProject',
|
||||
query: {
|
||||
title: record.name
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,170 @@
|
||||
<template>
|
||||
<div>
|
||||
<page-header-title :is-level-one="false" :level-two-title="$route.query.title"></page-header-title>
|
||||
<a-card :bordered="false">
|
||||
<!-- 查询区域-start -->
|
||||
<div class="table-page-search-wrapper">
|
||||
<a-form layout="inline" @keyup.enter.native="searchQuery">
|
||||
<a-row>
|
||||
<a-col :xl="6" :lg="7" :md="8" :sm="24">
|
||||
<a-form-item label="项目名称" :labelCol="labelCol" :wrapperCol="wrapperCol">
|
||||
<a-input placeholder="请输入项目名称" v-model="queryParam.companyName" :maxLength='50'></a-input>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :xl="6" :lg="7" :md="8" :sm="24">
|
||||
<span class="table-page-search-submitButtons">
|
||||
<a-button type="primary" icon="search" @click="searchQuery" v-has="'company:search'">查询</a-button>
|
||||
<a-button icon="reload" @click="searchReset" class="reset-button">重置</a-button>
|
||||
</span>
|
||||
</a-col>
|
||||
</a-row>
|
||||
</a-form>
|
||||
</div>
|
||||
<!-- 查询区域-end-->
|
||||
|
||||
<!-- table表格区域-->
|
||||
<div>
|
||||
<a-table
|
||||
ref="table"
|
||||
size="middle"
|
||||
bordered
|
||||
rowKey="id"
|
||||
:columns="columns"
|
||||
:scroll="{x: 1600}"
|
||||
:dataSource="dataSource"
|
||||
:pagination="ipagination"
|
||||
:loading="loading"
|
||||
:rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}"
|
||||
@change="handleTableChange"
|
||||
class="j-table-force-nowrap">
|
||||
|
||||
<template slot="text" slot-scope="text">
|
||||
<j-ellipsis :value="text" :length="18"></j-ellipsis>
|
||||
</template>
|
||||
|
||||
<!-- 立项文件-->
|
||||
<span slot="project-approval" class="action-span-cell" slot-scope="text, record">
|
||||
<a @click="viewProjectApproval(record)">查看</a>
|
||||
</span>
|
||||
|
||||
<!-- 征求意见-->
|
||||
<span slot="advice" class="action-span-cell" slot-scope="text, record">
|
||||
<a @click="viewAdvice(record)">查看</a>
|
||||
</span>
|
||||
|
||||
<!-- 送审材料-->
|
||||
<span slot="review-material" class="action-span-cell" slot-scope="text, record">
|
||||
<a @click="viewReviewMaterial(record)">查看</a>
|
||||
</span>
|
||||
|
||||
</a-table>
|
||||
</div>
|
||||
</a-card>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import PageHeaderTitle from '../../components/layouts/PageHeaderTitle'
|
||||
import { JeroListMixin } from '../../mixins/JeroListMixin'
|
||||
|
||||
export default {
|
||||
name: 'CommitteeUnderStudyProject',
|
||||
components: { PageHeaderTitle },
|
||||
mixins: [JeroListMixin],
|
||||
data() {
|
||||
return {
|
||||
labelCol: {
|
||||
xs: { span: 24 },
|
||||
sm: { span: 5 }
|
||||
},
|
||||
wrapperCol: {
|
||||
xs: { span: 24 },
|
||||
sm: { span: 10 }
|
||||
},
|
||||
columns: [
|
||||
{
|
||||
title: '序号',
|
||||
dataIndex: '',
|
||||
key: 'rowIndex',
|
||||
width: 60,
|
||||
align: 'center',
|
||||
customRender: function (t, r, index) {
|
||||
return parseInt(index) + 1
|
||||
}
|
||||
}, {
|
||||
title: '项目名称',
|
||||
align: 'center',
|
||||
dataIndex: 'companyName',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
}, {
|
||||
title: '计划号',
|
||||
align: 'center',
|
||||
dataIndex: 'dutyCode',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
}, {
|
||||
title: '起草单位',
|
||||
align: 'center',
|
||||
dataIndex: 'companyAddress',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
}, {
|
||||
title: '项目进度',
|
||||
align: 'center',
|
||||
dataIndex: 'companyPhone',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
}, {
|
||||
title: '立项文件',
|
||||
align: 'center',
|
||||
width: 100,
|
||||
fixed: 'right',
|
||||
dataIndex: 'status_dictText',
|
||||
scopedSlots: { customRender: 'project-approval' }
|
||||
}, {
|
||||
title: '征求意见',
|
||||
align: 'center',
|
||||
width: 100,
|
||||
fixed: 'right',
|
||||
dataIndex: 'createTime',
|
||||
scopedSlots: { customRender: 'advice' }
|
||||
}, {
|
||||
title: '送审材料',
|
||||
align: 'center',
|
||||
width: 100,
|
||||
fixed: 'right',
|
||||
dataIndex: 'bankAccountName',
|
||||
scopedSlots: { customRender: 'review-material' }
|
||||
}
|
||||
],
|
||||
url: {
|
||||
list: '',
|
||||
}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
/**
|
||||
* 查看立项文件
|
||||
* @param record
|
||||
*/
|
||||
viewProjectApproval(record) {
|
||||
console.log('查看立项文件', record)
|
||||
},
|
||||
/**
|
||||
* 查看征求意见
|
||||
* @param record
|
||||
*/
|
||||
viewAdvice(record) {
|
||||
console.log('查看征求意见', record)
|
||||
},
|
||||
/**
|
||||
* 查看送审材料
|
||||
* @param record
|
||||
*/
|
||||
viewReviewMaterial(record) {
|
||||
console.log('查看送审材料', record)
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped lang="less">
|
||||
@import '~@assets/less/common.less';
|
||||
</style>
|
||||
@@ -92,6 +92,7 @@
|
||||
</template>
|
||||
|
||||
<span slot="action" class="action-span-cell" slot-scope="text, record">
|
||||
<a @click="goUnderStudyProject(record)" v-has="'workingGroupProject:underStudyProject'">在研项目</a>
|
||||
<a @click="goFilesMaintenance(record)" v-has="'workingGroupProject:fileMaintenance'">其他分发资料</a>
|
||||
<a @click="goConferenceMaintenance(record)" v-has="'workingGroupProject:meetingMaintenance'">工作组会议</a>
|
||||
<a @click="copyWorkGroup(record.id)" v-has="'workingGroupProject:copy'"
|
||||
@@ -170,7 +171,7 @@ export default {
|
||||
dataIndex: 'action',
|
||||
align: 'center',
|
||||
fixed: 'right',
|
||||
width: 420,
|
||||
width: 280,
|
||||
scopedSlots: { customRender: 'action' }
|
||||
}
|
||||
],
|
||||
@@ -308,6 +309,18 @@ export default {
|
||||
year: new Date().getFullYear().toString()
|
||||
}
|
||||
this.loadData(1)
|
||||
},
|
||||
/**
|
||||
* 在研项目
|
||||
* @param record
|
||||
*/
|
||||
goUnderStudyProject(record) {
|
||||
this.$router.push({
|
||||
path: '/projectManagement/WorkingGroupProjectManagement/UnderStudyProject',
|
||||
query: {
|
||||
title: record.workingGroupProject
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,129 @@
|
||||
<template>
|
||||
<div>
|
||||
<page-header-title :is-level-one="false" :level-two-title="$route.query.title"></page-header-title>
|
||||
<a-card :bordered="false">
|
||||
<!-- 查询区域-start -->
|
||||
<div class="table-page-search-wrapper">
|
||||
<a-form layout="inline" @keyup.enter.native="searchQuery">
|
||||
<a-row>
|
||||
<a-col :xl="6" :lg="7" :md="8" :sm="24">
|
||||
<a-form-item label="项目名称" :labelCol="labelCol" :wrapperCol="wrapperCol">
|
||||
<a-input placeholder="请输入项目名称" v-model="queryParam.companyName" :maxLength='50'></a-input>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :xl="6" :lg="7" :md="8" :sm="24">
|
||||
<span class="table-page-search-submitButtons">
|
||||
<a-button type="primary" icon="search" @click="searchQuery" v-has="'company:search'">查询</a-button>
|
||||
<a-button icon="reload" @click="searchReset" class="reset-button">重置</a-button>
|
||||
</span>
|
||||
</a-col>
|
||||
</a-row>
|
||||
</a-form>
|
||||
</div>
|
||||
<!-- 查询区域-end-->
|
||||
|
||||
<!-- 操作按钮区域-->
|
||||
<div class="table-operator">
|
||||
<a-button type="primary" icon="plus" @click="handleAdd">新增</a-button>
|
||||
<a-button type="danger" icon="delete" @click="batchDel">批量删除</a-button>
|
||||
</div>
|
||||
<!-- 操作按钮区域-end-->
|
||||
|
||||
<!-- table表格区域-->
|
||||
<div>
|
||||
<a-table
|
||||
ref="table"
|
||||
size="middle"
|
||||
bordered
|
||||
rowKey="id"
|
||||
:columns="columns"
|
||||
:scroll="{x: 1000}"
|
||||
:dataSource="dataSource"
|
||||
:pagination="ipagination"
|
||||
:loading="loading"
|
||||
:rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}"
|
||||
@change="handleTableChange"
|
||||
class="j-table-force-nowrap">
|
||||
|
||||
<template slot="text" slot-scope="text">
|
||||
<j-ellipsis :value="text" :length="18"></j-ellipsis>
|
||||
</template>
|
||||
|
||||
<span slot="action" class="action-span-cell" slot-scope="text, record">
|
||||
<a @click="handleEdit(record)">编辑</a>
|
||||
<a @click="handleDelete(record.id)">删除</a>
|
||||
</span>
|
||||
</a-table>
|
||||
</div>
|
||||
</a-card>
|
||||
|
||||
<working-group-under-study-project-modal ref="modalForm" @ok="modalFormOk"></working-group-under-study-project-modal>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import PageHeaderTitle from '../../components/layouts/PageHeaderTitle'
|
||||
import { JeroListMixin } from '../../mixins/JeroListMixin'
|
||||
import WorkingGroupUnderStudyProjectModal from './modules/WorkingGroupUnderStudyProjectModal'
|
||||
|
||||
export default {
|
||||
name: 'WorkingGroupUnderStudyProject',
|
||||
components: { PageHeaderTitle, WorkingGroupUnderStudyProjectModal },
|
||||
mixins: [JeroListMixin],
|
||||
data() {
|
||||
return {
|
||||
labelCol: {
|
||||
xs: { span: 24 },
|
||||
sm: { span: 5 }
|
||||
},
|
||||
wrapperCol: {
|
||||
xs: { span: 24 },
|
||||
sm: { span: 10 }
|
||||
},
|
||||
columns: [
|
||||
{
|
||||
title: '序号',
|
||||
dataIndex: '',
|
||||
key: 'rowIndex',
|
||||
width: 60,
|
||||
align: 'center',
|
||||
customRender: function (t, r, index) {
|
||||
return parseInt(index) + 1
|
||||
}
|
||||
}, {
|
||||
title: '项目名称',
|
||||
align: 'center',
|
||||
dataIndex: 'companyName',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
}, {
|
||||
title: '主要起草单位',
|
||||
align: 'center',
|
||||
dataIndex: 'companyAddress',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
}, {
|
||||
title: '项目进度',
|
||||
align: 'center',
|
||||
dataIndex: 'companyPhone',
|
||||
scopedSlots: { customRender: 'text' }
|
||||
}, {
|
||||
title: '操作',
|
||||
align: 'center',
|
||||
width: 180,
|
||||
fixed: 'right',
|
||||
dataIndex: 'bankAccountName',
|
||||
scopedSlots: { customRender: 'action' }
|
||||
}
|
||||
],
|
||||
url: {
|
||||
list: '',
|
||||
delete: '',
|
||||
deleteBatch: ''
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped lang="less">
|
||||
@import '~@assets/less/common.less';
|
||||
</style>
|
||||
@@ -0,0 +1,163 @@
|
||||
<template>
|
||||
<j-modal
|
||||
:title="title"
|
||||
:width="width"
|
||||
:visible="visible"
|
||||
:confirmLoading="confirmLoading"
|
||||
switchFullscreen
|
||||
@ok="handleOk"
|
||||
@cancel="handleCancel"
|
||||
cancelText="关闭">
|
||||
<a-spin :spinning="confirmLoading">
|
||||
<a-form :form="form">
|
||||
<a-row>
|
||||
<a-col>
|
||||
<a-form-item label="项目名称" :labelCol="remarksLabelCol" :wrapperCol="remarksWrapperCol">
|
||||
<a-input placeholder="请输入项目名称"
|
||||
v-decorator="['companyName',validatorRules.companyName]"
|
||||
:maxLength='50'
|
||||
@change="e => {e.target.value = (e.target.value + '').trim()}"></a-input>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-row>
|
||||
<a-col :xl="12" :sm="24">
|
||||
<a-form-item label="主要起草单位" :labelCol="labelCol" :wrapperCol="wrapperCol">
|
||||
<a-input placeholder="请输入主要起草单位"
|
||||
v-decorator="['dutyCode', validatorRules.dutyCode]"
|
||||
:maxLength='18'
|
||||
@change="e => {e.target.value = (e.target.value + '').trim()}"></a-input>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :xl="12" :sm="24">
|
||||
<a-form-item label="项目进度" :labelCol="labelCol" :wrapperCol="wrapperCol">
|
||||
<a-input placeholder="请输入项目进度"
|
||||
v-decorator="['dutyCode', validatorRules.dutyCode]"
|
||||
:maxLength='18'
|
||||
@change="e => {e.target.value = (e.target.value + '').trim()}"></a-input>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-row>
|
||||
<a-col :xl="12" :sm="24">
|
||||
<a-form-item label="过程文件" :labelCol="labelCol" :wrapperCol="wrapperCol">
|
||||
<j-upload file-type="all"
|
||||
file-type-error-message="请上传文件"
|
||||
:multiple="true"
|
||||
:number="10"
|
||||
:return-id="true"
|
||||
v-decorator="['fileIds', validatorRules.fileIds]"
|
||||
:trigger-change="true"></j-upload>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
</a-form>
|
||||
</a-spin>
|
||||
</j-modal>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import pick from 'lodash.pick'
|
||||
import { postAction } from '../../../api/manage'
|
||||
import JUpload from '../../../components/jero/JUpload'
|
||||
|
||||
export default {
|
||||
name: 'WorkingGroupUnderStudyProjectModal',
|
||||
components: { JUpload },
|
||||
data() {
|
||||
return {
|
||||
title: '操作',
|
||||
width: 800,
|
||||
visible: false,
|
||||
confirmLoading: false,
|
||||
form: this.$form.createForm(this),
|
||||
model: {},
|
||||
labelCol: {
|
||||
xs: { span: 24 },
|
||||
sm: { span: 6 }
|
||||
},
|
||||
wrapperCol: {
|
||||
xs: { span: 24 },
|
||||
sm: { span: 18 }
|
||||
},
|
||||
remarksLabelCol: {
|
||||
xs: { span: 24 },
|
||||
sm: { span: 3 }
|
||||
},
|
||||
remarksWrapperCol: {
|
||||
xs: { span: 24 },
|
||||
sm: { span: 21 }
|
||||
},
|
||||
validatorRules: {
|
||||
companyName: {
|
||||
rules: [{ required: true, validator: this.checkCompanyName }],
|
||||
validateTrigger: 'blur'
|
||||
}
|
||||
},
|
||||
url: {
|
||||
add: '',
|
||||
edit: ''
|
||||
}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
add() {
|
||||
this.edit({})
|
||||
},
|
||||
edit(record) {
|
||||
this.form.resetFields()
|
||||
this.model = Object.assign({}, record)
|
||||
this.visible = true
|
||||
this.$nextTick(() => {
|
||||
this.form.setFieldsValue(pick(this.model))
|
||||
})
|
||||
},
|
||||
close() {
|
||||
this.$emit('close')
|
||||
this.visible = false
|
||||
},
|
||||
handleOk() {
|
||||
if (this.confirmLoading) {
|
||||
return
|
||||
}
|
||||
this.confirmLoading = true
|
||||
const that = this
|
||||
// 触发表单验证
|
||||
this.form.validateFields((err, values) => {
|
||||
if (!err) {
|
||||
let httpurl = ''
|
||||
if (!this.model.id) {
|
||||
httpurl += this.url.add
|
||||
} else {
|
||||
httpurl += this.url.edit
|
||||
}
|
||||
const formData = Object.assign(this.model, values)
|
||||
console.log('表单提交数据', formData)
|
||||
postAction(httpurl, formData).then((res) => {
|
||||
if (res.success) {
|
||||
that.$message.success(res.message)
|
||||
that.$emit('ok')
|
||||
that.close()
|
||||
} else {
|
||||
that.$message.warning(res.message)
|
||||
}
|
||||
}).finally(() => {
|
||||
setTimeout(() => {
|
||||
this.confirmLoading = false
|
||||
}, 1000)
|
||||
})
|
||||
} else {
|
||||
this.confirmLoading = false
|
||||
}
|
||||
})
|
||||
},
|
||||
handleCancel() {
|
||||
this.close()
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
|
||||
</style>
|
||||
Reference in New Issue
Block a user