Commit c4f55c0c authored by 李苏's avatar 李苏 💬

新增

parent ff24e321
const proPlugins = ['dynamic-import-node','transform-remove-console']; const proPlugins = ['dynamic-import-node'];
if (process.env.NODE_ENV === 'production') { if (process.env.NODE_ENV === 'production') {
// proPlugins.push('transform-remove-console'); proPlugins.push('transform-remove-console');
} }
module.exports = { module.exports = {
presets: [ presets: [
......
<template> <template>
<section class="app-main"> <section class="app-main">
<transition name="fade-transform" mode="out-in"> <transition name="fade-transform" mode="out-in">
<!-- <keep-alive :include="cachedViews"> <keep-alive :include="cachedViews">
<router-view :key="key" /> <router-view :key="key" />
</keep-alive> --> </keep-alive>
<router-view :key="key" /> <router-view :key="key" />
</transition> </transition>
</section> </section>
......
<template> <template>
<RelDialog :type='type' :editApp='editApp' :app='app' :buttonApp='buttonApp'> <RelDialog :type='type' :editApp='editApp' :app='app' :buttonApp='buttonApp'>
<!-- 填写表单内容,slot=form必写--> <!-- 填写表单内容,slot=form必写-->
<el-form slot="form" ref="form" :model="form" label-width="80px" :rules="rules"> <el-form slot="form" ref="form" :model="form" label-width="80px" :rules="rules">
<el-row :gutter="20"> <el-row :gutter="20">
<el-col :span="12"> <el-col :span="24">
<el-form-item label="序号" ref="appid" prop="appid"> <el-form-item label=">名称" ref="name" prop="name">
<el-input :readonly="readonly" v-model="form.appid"></el-input> <el-date-picker style="width: 100%;" :readonly="readonly" type="date"
</el-form-item> v-model="form.name" placeholder="选择日期">
</el-col> </el-date-picker>
<el-col :span="12"> </el-form-item>
<el-form-item label="标准名称" ref="name" prop="name"> </el-col>
<el-input :readonly="readonly" v-model="form.name"></el-input> </el-row>
</el-form-item> <el-row :gutter="20">
</el-col> <el-col :span="24">
</el-row> <el-form-item label=">序号" ref="xh" prop="xh">
<el-row :gutter="20"> <el-date-picker style="width: 100%;" :readonly="readonly" type="date"
<el-col :span="24"> v-model="form.xh" placeholder="选择日期">
<el-form-item label="备注"> </el-date-picker>
<el-input type="textarea" :readonly="readonly" v-model="form.bz"></el-input> </el-form-item>
</el-form-item> </el-col>
</el-col> </el-row>
</el-row> <el-row :gutter="20">
</el-form> <el-col :span="24">
<!-- 按钮重写, --> <el-form-item label=">备注" ref="bz" prop="bz">
<!-- <div slot="reFooter"> <el-date-picker style="width: 100%;" :readonly="readonly" type="date"
<span slot="footer"> v-model="form.bz" placeholder="选择日期">
重写按钮写在这里,根据需要重写 slot(reFooter,foorer) 节点样式 重写方法需要在此页重新定义 </el-date-picker>
</span> </el-form-item>
</div> --> </el-col>
</RelDialog> </el-row>
<el-row :gutter="20">
<el-col :span="24">
<el-form-item label=">系统版本" ref="sysversion" prop="sysversion">
<el-date-picker style="width: 100%;" :readonly="readonly" type="date"
v-model="form.sysversion" placeholder="选择日期">
</el-date-picker>
</el-form-item>
</el-col>
</el-row>
</el-form>
</RelDialog>
</template> </template>
<script> <script>
import {editMixin} from 'common' import {editMixin} from 'common'
export default { export default {
mixins: [editMixin], mixins: [editMixin],
/* 存放index页面传递的额外参数*/ /* 存放index页面传递的额外参数*/
mounted() { mounted() {
console.log(this.$router)
this.systemType = JSON.parse(JSON.stringify(this.app.systemType))
},
/* 组件名称*/
name: 'appVersionEdit',
/* 传递props模式一样必填,用于index,button,REdialog之间的组件通信*/
data() {
return {
/* 额外初始化,根据需求*/
systemType: [],
/* 当前表单初始值,默认由RelDialog查询indexQuery赋值,copy时不赋值id,初始化时所有query的值都会赋值给form*/
form: {
appid: '',
name: '',
version: "",
url: "",
bz: ''
}, },
/* form提交时的规则,具体规则参考官网*/ /* 组件名称*/
rules: { name: "aqgl/jcsjBzzywdmlEdit",
appid: [{ /* 传递props模式一样必填,用于index,button,REdialog之间的组件通信*/
required: true,
trigger: 'blur' data() {
}, ], return {
name: [{
required: true, /* 额外初始化,根据需求*/
trigger: 'blur' systemType: [],
}, ],
type: [{ bmList: [],
required: true,
trigger: 'change' /* 当前表单初始值,默认由RelDialog查询indexQuery赋值,copy时不赋值id,初始化时所有query的值都会赋值给form*/
}, ], form: {
version: [{ id:'',
required: true,
trigger: 'blur' name:'',
}, ],
url: [{ xh:'',
required: true,
trigger: 'blur' bz:'',
}, ],
} whrid:'',
}
},
methods: {
/* 重写方法,this.app来调用index页面定义的api*/
whr:'',
whsj:new Date().getTime(),
cjrid:'',
cjr:'',
cjsj:new Date().getTime(),
sysversion:'',
},
/* form提交时的规则,具体规则参考官网*/
rules: {
roleid: [{
required: true,
trigger: 'blur'
}, ],
rolename: [{
required: true,
trigger: 'blur'
}, ]
}
}
},
methods: {
}
} }
}
</script> </script>
<style scoped lang="scss"> <style scoped lang="scss">
......
<template> <template>
<div class="min_full" style="calc(60vh - 42px)"> <div class="min_full">
<!-- 按钮操作--> <!-- 查询条件-->
<el-row class="tool-bar"> <div class="search" v-condition>
<PrintButton :app='app'></PrintButton> <SearchButton :app='app'></SearchButton>
<ViewButton ref="view" :app='app'></ViewButton> <el-row :gutter="20" class="search-row-1">
<AddButton ref="add" :app='app'></AddButton> <el-col :span="12" class="search-col">
<CopyButton ref="copy" :app='app'></CopyButton> <div class="search-item">
<EditButton ref="edit" :app='app'></EditButton> <span class="search-span">名称:</span>
<FieldButton :app='app'></FieldButton> <el-input v-model="queryParams.info"></el-input>
<ExcelButton :app='app'></ExcelButton> </div>
<AttachFileButton :app='app' ></AttachFileButton> </el-col>
</el-row> </el-row>
<!-- 表格--> </div>
<div class="tablePagers"> <!-- 按钮操作-->
<TablePager @getData='getData' :ref="'TablePager'" :app='app' :query='query' @selectItem='selectItem' <el-row class="tool-bar">
@getRow='getRow'> <PrintButton :app='app'></PrintButton>
<!-- 自定义列 slot="tabCustom",格式参照elementUi,自定义事件用this.$refs['TablePager']调用/或者v-slot通信/--> <ViewButton ref="view" :app='app'></ViewButton>
</TablePager> <AddButton ref="add" :app='app'></AddButton>
</div> <CopyButton ref="copy" :app='app'></CopyButton>
</div> <EditButton ref="edit" :app='app'></EditButton>
<AttachFileButton :app='app' ></AttachFileButton>
<FieldButton :app='app'></FieldButton>
<ExcelButton :app='app'></ExcelButton>
<!-- 额外按钮-->
<!-- 表头设置 -->
<!-- 权限-->
</el-row>
<!-- 表格-->
<div class="tablePagers">
<TablePager @getData='getData' :ref="'TablePager'" :app='app' :query='query' @selectItem='selectItem'
@getRow='getRow'>
</TablePager>
</div>
</div>
</template> </template>
<script> <script>
/* 引入需要的接口*/ /* 引入需要的接口*/
import { import {
QueryAppversion, doQuery,
QueryApptype, doAdd,
AddAppversion, doUpdate,
DelAppversion, doDelete,
UpdateAppversion doExport
} from "common/src/api/system/dmgSystem.js"; } from '@/api/basicData/operationDcManagement.js';
/* edit页面*/ /* edit页面*/
import Edit from './lessEdit' import Edit from './lessEdit'
import {tableMixin} from 'common' import {
export default { tableMixin
mixins: [tableMixin], } from 'common'
name: 'appVersion', export default {
/* 初始额外赋值*/ mixins: [tableMixin],
async mounted() { name: 'aqgl/jcsjBzzywd',
await this.$asRun(
[QueryApptype(), /* 初始额外赋值*/
res => { async mounted() {
var data = res['data']['records'];
let typeMap = [] },
for (var i in data) { data() {
typeMap[data[i].id] = data[i].name return {
} /*需要的额外参数 */
this.systemType = data showDialog: false,
this.typeMap = typeMap DialogName: '',
} type: '',
] DialogTitle: '',
) /* 基础url*/
}, baseUrl: '/aqgl/jcsj/bzzywd',
data() { /* 查询参数*/
return { queryParams: {
/*需要的额外参数 */ info: ''
typeMap: [], },
systemType: [], /* 表格标题对应参数*/
baseUrl: 'kzzx/appversion', tableTitle: [
/* 查询参数*/ {label: "管理项目", prop: "glxm", fieldType: "ftString",width:300},
queryParams: {}, {label: "管理标准", prop: "glbz", fieldType: "ftString",width:300},
/* 表格标题对应参数*/ {label: "发布日期", prop: "fbrq", fieldType: "ftDateTime"},
tableTitle: [ {label: "实施日期", prop: "ssrq", fieldType: "ftDateTime"},
{ {label: "发布部门", prop: "bmid", fieldType: "ftString",width:192},
prop: 'name', {label: "异常处理方法", prop: "yccl", fieldType: "ftString",width:300},
label: '管理项目', {label: "目录", prop: "mlid", fieldType: "ftString",width:192},
width: '120' {label: "附件数", prop: "attachcount", fieldType: "int"},
}, {label: "备注", prop: "bz", fieldType: "ftString",width:300},
{ {label: "维护人", prop: "whr", fieldType: "ftString"},
prop: 'name', {label: "维护时间", prop: "whsj", fieldType: "ftDateTime"},
label: '标准', {label: "创建人", prop: "cjr", fieldType: "ftString"},
width: '120' {label: "创建时间", prop: "cjsj", fieldType: "ftDateTime"},
}, ]
{ }
prop: 'whsj', },
label: '发布时间', methods: {
...this.$common('ftDateTime')
}, /* 基础查询*/
{ query: doQuery,
prop: 'whsj', /* 基础增*/
label: '实施时间', apiAdd: doAdd,
...this.$common('ftDateTime') /* 基础更新*/
}, apiUpdate: doUpdate,
{ /* 删除操作*/
prop: 'name', apiDelete: doDelete,
label: '异常项处理方法', /* 初始化赋值操作*/
width: '120' init() {
},
{ }
prop: 'bz', },
label: '备注', components: {
width: '120' Edit,
}, }
]
}
}, }
methods: {
/* 基础查询*/
query: QueryAppversion,
/* 基础增*/
apiAdd: AddAppversion,
/* 基础更新*/
apiUpdate: UpdateAppversion,
/* 删除操作*/
apiDelete: DelAppversion,
/* 初始化赋值操作*/
},
/* 注册组件*/
components: {
Edit
}
}
</script> </script>
<style scoped> <style scoped>
......
<template> <template>
<div class="min_full" style=" height: 40%"> <div class="min_full">
<!-- 查询条件--> <!-- 查询条件-->
<div class="search" v-condition> <div class="search" v-condition>
<SearchButton :app='app'></SearchButton> <SearchButton :app='app'></SearchButton>
<el-row :gutter="20" class="search-row-1"> <el-row :gutter="20" class="search-row-1">
<el-col :span="6" class="search-col"> <el-col :span="12" class="search-col">
<div class="search-item"> <div class="search-item">
<span class="search-span">标准名称:</span> <span class="search-span">名称:</span>
<el-input></el-input> <el-input v-model="queryParams.info"></el-input>
</div> </div>
</el-col> </el-col>
</el-row>
</div>
<!-- 按钮操作-->
<el-row class="tool-bar">
<PrintButton :app='app'></PrintButton>
<ViewButton ref="view" :app='app'></ViewButton>
<AddButton ref="add" :app='app'></AddButton>
<CopyButton ref="copy" :app='app'></CopyButton>
<EditButton ref="edit" :app='app'></EditButton>
<AttachFileButton :app='app' ></AttachFileButton>
<FieldButton :app='app'></FieldButton>
<ExcelButton :app='app'></ExcelButton>
<!-- 额外按钮-->
<!-- 表头设置 -->
</el-row> <!-- 权限-->
</div> </el-row>
<!-- 按钮操作--> <!-- 表格-->
<el-row class="tool-bar"> <div class="tablePagers">
<PrintButton :app='app'></PrintButton> <TablePager @getData='getData' :ref="'TablePager'" :app='app' :query='query' @selectItem='selectItem'
<ViewButton ref="view" :app='app'></ViewButton> @getRow='getRow'>
<AddButton ref="add" :app='app'></AddButton> </TablePager>
<CopyButton ref="copy" :app='app'></CopyButton> </div>
<EditButton ref="edit" :app='app'></EditButton> </div>
<FieldButton :app='app'></FieldButton>
<ExcelButton :app='app'></ExcelButton>
</el-row>
<!-- 表格-->
<div class="tablePagers">
<TablePager @getData='getData' :ref="'TablePager'" :app='app' :query='query' @selectItem='selectItem'
@getRow='getRow'>
<!-- 自定义列 slot="tabCustom",格式参照elementUi,自定义事件用this.$refs['TablePager']调用/或者v-slot通信/-->
</TablePager>
</div>
</div>
</template> </template>
<script> <script>
/* 引入需要的接口*/ /* 引入需要的接口*/
import { import {
QueryAppversion, doQuery,
QueryApptype, doAdd,
AddAppversion, doUpdate,
DelAppversion, doDelete,
UpdateAppversion doExport
} from "common/src/api/system/dmgSystem.js"; } from '@/api/basicData/operationDcManagement.js';
/* edit页面*/ /* edit页面*/
import Edit from './edit' import Edit from './edit'
import {tableMixin} from 'common' import {
export default { tableMixin
mixins: [tableMixin], } from 'common'
name: 'appVersion', export default {
/* 初始额外赋值*/ mixins: [tableMixin],
async mounted() { name: 'aqgl/jcsjBzzywdml',
await this.$asRun( props:{
[QueryApptype(), vMain:{
res => { type:Object,
var data = res['data']['records']; default:function(){
let typeMap = [] return {}
for (var i in data) {
typeMap[data[i].id] = data[i].name
} }
this.systemType = data
this.typeMap = typeMap
}
]
)
this.$refs['TablePager'].pageQuery()
},
data() {
return {
/*需要的额外参数 */
typeMap: [],
systemType: [],
baseUrl: 'kzzx/appversion',
/* 查询参数*/
queryParams: {},
/* 表格标题对应参数*/
tableTitle: [
{
prop: 'xh',
label: '序号',
width: '80'
},
{
prop: 'name',
label: '目录名称',
width: '200'
},
{
prop: 'bz',
label: '备注',
width: '300'
}
]
}
},
methods: {
/* 基础查询*/
query: QueryAppversion,
/* 基础增*/
apiAdd: AddAppversion,
/* 基础更新*/
apiUpdate: UpdateAppversion,
/* 删除操作*/
apiDelete: DelAppversion,
/* 初始化赋值操作*/
/* 点击主表事件*/
getRow: function(e) {
this.rowItem = e
let lessIndex=this.vMain.$refs.lessIndex
lessIndex.queryParams.mlid=this.rowItem.id
lessIndex.$refs['TablePager'].pageQuery()
} }
}, },
/* 注册组件*/ /* 初始额外赋值*/
components: { async mounted() {
Edit this.$refs['TablePager'].pageQuery()
} },
} data() {
return {
/*需要的额外参数 */
showDialog: false,
DialogName: '',
type: '',
DialogTitle: '',
/* 基础url*/
baseUrl: '/aqgl/jcsj/bzzywdml',
/* 查询参数*/
queryParams: {
info: ''
},
/* 表格标题对应参数*/
tableTitle: [
{label: "名称", prop: "name", fieldType: "ftString",width:300},
{label: "序号", prop: "xh", fieldType: "int"},
{label: "备注", prop: "bz", fieldType: "ftString",width:300},
{label: "维护人", prop: "whr", fieldType: "ftString"},
{label: "维护时间", prop: "whsj", fieldType: "ftDateTime"},
{label: "创建人", prop: "cjr", fieldType: "ftString"},
{label: "创建时间", prop: "cjsj", fieldType: "ftDateTime"},
]
}
},
methods: {
/* 基础查询*/
query: doQuery,
/* 基础增*/
apiAdd: doAdd,
/* 基础更新*/
apiUpdate: doUpdate,
/* 删除操作*/
apiDelete: doDelete,
/* 点击主表事件*/
getRow: function(e) {
this.rowItem = e
let lessIndex=this.vMain.$refs.lessIndex
lessIndex.queryParams.mlid=this.rowItem.id
lessIndex.$refs['TablePager'].pageQuery()
},
/* 初始化赋值操作*/
init() {
}
},
components: {
Edit,
}
}
</script> </script>
<style scoped> <style scoped>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment