开发法规月报页面
This commit is contained in:
@@ -970,7 +970,12 @@ module.exports = {
|
||||
monthlyTitleTemplate:'Monthly title template',
|
||||
monthlyIntegrationAndExport:'Monthly integration and export',
|
||||
addContent:'Add content',
|
||||
editContent:'Edit content',
|
||||
viewContent:'View content',
|
||||
fillInTheMonth:'Fill in the month',
|
||||
monthSelection:'Month selection',
|
||||
bringInStandardInformation:'Bring in standard information',
|
||||
contentTemplate:'Content template',
|
||||
moveUp:'Move up',
|
||||
moveDown:'Move down',
|
||||
// 上报库
|
||||
|
||||
@@ -975,7 +975,12 @@ module.exports = {
|
||||
monthlyTitleTemplate:'月报标题模板',
|
||||
monthlyIntegrationAndExport:'月报整合导出',
|
||||
addContent:'新增内容',
|
||||
editContent:'编辑内容',
|
||||
viewContent:'查看内容',
|
||||
monthSelection:'月份选择',
|
||||
fillInTheMonth:'填写月份',
|
||||
contentTemplate:'内容模板',
|
||||
bringInStandardInformation:'带入标准信息',
|
||||
moveUp:'上移',
|
||||
moveDown:'下移',
|
||||
// 上报库
|
||||
|
||||
+11
-4
@@ -71,17 +71,20 @@
|
||||
</div>
|
||||
</div>
|
||||
<fillTable ref="fillTableRef"/>
|
||||
<fillAdd ref="fillAddRef" @fillAddForm="fillAddForm"/>
|
||||
</a-card>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { getAction, postAction, downloadFile } from '@/api/manage'
|
||||
import fillTable from './modules/fillTable'
|
||||
import fillAdd from './modules/fillAdd'
|
||||
|
||||
export default {
|
||||
name: 'RegulationMonthlyFill',
|
||||
components: {
|
||||
fillTable
|
||||
fillTable,
|
||||
fillAdd
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
@@ -175,6 +178,10 @@
|
||||
this.pageSize = pageSize
|
||||
this.getList()
|
||||
},
|
||||
fillAddForm() {
|
||||
this.pageNo = 1
|
||||
this.getList()
|
||||
},
|
||||
getList() {
|
||||
|
||||
},
|
||||
@@ -185,13 +192,13 @@
|
||||
|
||||
},
|
||||
addContentClick() {
|
||||
|
||||
this.$refs.fillAddRef.add()
|
||||
},
|
||||
viewClick(row) {
|
||||
|
||||
this.$refs.fillAddRef.view(JSON.parse(JSON.stringify(row)))
|
||||
},
|
||||
edit(row) {
|
||||
|
||||
this.$refs.fillAddRef.edit(JSON.parse(JSON.stringify(row)))
|
||||
},
|
||||
//删除
|
||||
deleteLib(val) {
|
||||
|
||||
@@ -0,0 +1,245 @@
|
||||
<template>
|
||||
<div>
|
||||
<a-drawer
|
||||
:title="title"
|
||||
:maskClosable="false"
|
||||
:width="800"
|
||||
placement="right"
|
||||
:closable="true"
|
||||
@close="handleCancel"
|
||||
:visible="visible"
|
||||
style="height: 100%;overflow: auto;padding-bottom: 53px;">
|
||||
<a-spin :spinning="confirmLoading">
|
||||
<a-form-model :model="formInline" class="formAdd" :rules="rules" ref="ruleForm">
|
||||
<a-row :gutter="24">
|
||||
<a-col :span="12">
|
||||
<div class="box-title-text">
|
||||
<div class="title-text">
|
||||
<span class="title-text-text"
|
||||
:title="$t('fillInTheMonth')">{{$t('fillInTheMonth')}}</span>
|
||||
</div>
|
||||
<a-form-model-item class="itemModel">
|
||||
<a-month-picker class="box-input"
|
||||
v-model="formInline.fillInTheMonth"
|
||||
:placeholder="$t('fillInTheMonth')"/>
|
||||
</a-form-model-item>
|
||||
</div>
|
||||
</a-col>
|
||||
<a-col :span="12" style="text-align: right">
|
||||
<div style="text-align: right">
|
||||
<a-button class="button-text" type="primary">{{$t('bringInStandardInformation')}}</a-button>
|
||||
</div>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-row :gutter="24">
|
||||
<a-col :span="12">
|
||||
<div class="box-title-text">
|
||||
<div class="title-text">
|
||||
<span class="title-text-text"
|
||||
:title="$t('chapterContents')">{{$t('chapterContents')}}</span>
|
||||
</div>
|
||||
<a-form-model-item class="itemModel">
|
||||
<a-select :placeholder="$t('PleaseSelect')+$t('chapterContents')"
|
||||
:disabled="disabled"
|
||||
class="box-input"
|
||||
:getPopupContainer="triggerNode=> triggerNode.parentNode"
|
||||
allowClear
|
||||
v-model="formInline.chapterContents">
|
||||
<a-select-option v-for="(item, key) in chapterContentsList"
|
||||
:key="key"
|
||||
:value="item.value">
|
||||
<span style="display: inline-block;width: 100%" :title=" item.name ">
|
||||
{{ item.name }}
|
||||
</span>
|
||||
</a-select-option>
|
||||
</a-select>
|
||||
</a-form-model-item>
|
||||
</div>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<div class="box-title-text">
|
||||
<div class="title-text">
|
||||
<span class="title-text-text"
|
||||
:title="$t('contentTemplate')">{{$t('contentTemplate')}}</span>
|
||||
</div>
|
||||
<a-form-model-item class="itemModel">
|
||||
<a-select :placeholder="$t('PleaseSelect')+$t('contentTemplate')"
|
||||
:disabled="disabled"
|
||||
class="box-input"
|
||||
:getPopupContainer="triggerNode=> triggerNode.parentNode"
|
||||
allowClear
|
||||
v-model="formInline.chapterContents">
|
||||
<a-select-option v-for="(item, key) in contentTemplateList"
|
||||
:key="key"
|
||||
:value="item.value">
|
||||
<span style="display: inline-block;width: 100%" :title=" item.name ">
|
||||
{{ item.name }}
|
||||
</span>
|
||||
</a-select-option>
|
||||
</a-select>
|
||||
</a-form-model-item>
|
||||
</div>
|
||||
</a-col>
|
||||
</a-row>
|
||||
</a-form-model>
|
||||
</a-spin>
|
||||
<div class="drawer-bootom-button">
|
||||
<a-button style="margin-right: .8rem" @click="handleCancel">{{$t('cancel')}}</a-button>
|
||||
<a-button @click="handleSubmit" type="primary" :loading="confirmLoading">{{$t('submit')}}</a-button>
|
||||
</div>
|
||||
</a-drawer>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
name: 'fillAdd',
|
||||
data() {
|
||||
return {
|
||||
rules: {
|
||||
name: [
|
||||
{
|
||||
required: true,
|
||||
message: this.$t('VirtualListName') + this.$t('cannotEmpty'),
|
||||
trigger: 'blur'
|
||||
},
|
||||
{
|
||||
max: 100,
|
||||
message: this.$t('VirtualListName') + this.$t('cannotExceed') + 100 + this.$t('Characters'),
|
||||
trigger: 'blur'
|
||||
}
|
||||
],
|
||||
useExplain: [
|
||||
{
|
||||
required: true,
|
||||
message: this.$t('instructionForUse') + this.$t('cannotEmpty'),
|
||||
trigger: 'blur'
|
||||
},
|
||||
{
|
||||
max: 500,
|
||||
message: this.$t('instructionForUse') + this.$t('cannotExceed') + 500 + this.$t('Characters'),
|
||||
trigger: 'blur'
|
||||
}
|
||||
]
|
||||
},
|
||||
visible: false,
|
||||
formInline: {},
|
||||
confirmLoading: false,
|
||||
title: '',
|
||||
disabled: false,
|
||||
chapterContentsList: [],
|
||||
contentTemplateList: []
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
},
|
||||
methods: {
|
||||
add() {
|
||||
this.title = this.$t('addContent')
|
||||
this.visible = true
|
||||
this.disabled = false
|
||||
this.$nextTick(() => {
|
||||
this.formInline = {}
|
||||
this.$refs.ruleForm.clearValidate()
|
||||
})
|
||||
},
|
||||
edit(row) {
|
||||
this.title = this.$t('editContent')
|
||||
this.visible = true
|
||||
this.disabled = false
|
||||
this.$nextTick(() => {
|
||||
this.formInline = row
|
||||
this.$refs.ruleForm.clearValidate()
|
||||
})
|
||||
},
|
||||
view(row) {
|
||||
this.title = this.$t('viewContent')
|
||||
this.visible = true
|
||||
this.disabled = true
|
||||
this.$nextTick(() => {
|
||||
this.formInline = row
|
||||
this.$refs.ruleForm.clearValidate()
|
||||
})
|
||||
},
|
||||
handleCancel() {
|
||||
this.visible = false
|
||||
},
|
||||
handleSubmit() {
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
|
||||
.box-title-text {
|
||||
line-height: 1.4;
|
||||
display: flex;
|
||||
}
|
||||
|
||||
.title-text {
|
||||
width: 114px;
|
||||
text-align: right;
|
||||
display: inline-block;
|
||||
font-weight: 500;
|
||||
font-size: 14px;
|
||||
margin-right: 16px;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
height: 42px;
|
||||
line-height: 42px;
|
||||
}
|
||||
|
||||
.box-input {
|
||||
display: inline-block;
|
||||
height: 38px;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.itemModel {
|
||||
width: calc(100% - 130px);
|
||||
display: inline-block;
|
||||
margin-top: 2px;
|
||||
}
|
||||
|
||||
.title-text-text {
|
||||
margin-top: 9px;
|
||||
}
|
||||
|
||||
.formAdd {
|
||||
margin-bottom: 40px;
|
||||
}
|
||||
|
||||
.Required {
|
||||
color: red;
|
||||
margin-right: 4px;
|
||||
}
|
||||
|
||||
.title-text-text {
|
||||
margin-top: 9px;
|
||||
}
|
||||
|
||||
.formAdd {
|
||||
margin-bottom: 40px;
|
||||
}
|
||||
|
||||
.drawer-bootom-button {
|
||||
position: absolute;
|
||||
bottom: 0;
|
||||
z-index: 100;
|
||||
width: 100%;
|
||||
border-top: 1px solid #e8e8e8;
|
||||
padding: 10px 16px;
|
||||
text-align: right;
|
||||
left: 0;
|
||||
background: #fff;
|
||||
border-radius: 0 0 2px 2px;
|
||||
}
|
||||
|
||||
.button-text {
|
||||
height: 38px;
|
||||
margin-top: 4px;
|
||||
}
|
||||
</style>
|
||||
Reference in New Issue
Block a user