fix some bugs

This commit is contained in:
g7hoo 2022-10-09 10:36:18 +08:00
parent d0f113513c
commit 5a08d8c1dd
53 changed files with 367 additions and 95 deletions

View File

@ -147,13 +147,6 @@ export default {
components: { AttrForm },
props: {
configs: {
/**
* TODO: 定义及使用方式应改用README.md文件记录
* type: 'dialog' | 'drawer' | 'page'
* fields: Array<string|object>
* - fields.object: { name, type: 'number'|'textarea'|'select'|'date'|.., required: boolean, validator: boolean(是否需要验证), [options]: any[], api: string(自动获取数据的接口一般为getcode接口)}
* operations: Array[object], 操作名和对应的接口地址还有permission(sys:dict:update)
*/
type: Object,
default: () => ({}) // 使
}
@ -533,7 +526,7 @@ export default {
}
break
case 'cancel':
this.visible = false
this.handleClose()
// add more..
}
},

View File

@ -1,36 +1,20 @@
<template>
<nav
class="aui-navbar"
:class="`aui-navbar--${$store.state.navbarLayoutType}`"
>
<nav class="aui-navbar" :class="`aui-navbar--${$store.state.navbarLayoutType}`">
<div class="aui-navbar__header">
<h1 class="aui-navbar__brand" @click="$router.push({ name: 'home' })">
<a class="aui-navbar__brand-lg" href="javascript:;">{{
$t('brand.lg')
}}</a>
<a class="aui-navbar__brand-mini" href="javascript:;">{{
$t('brand.mini')
}}</a>
<a class="aui-navbar__brand-lg" href="javascript:;">{{ $t('brand.lg') }}</a>
<a class="aui-navbar__brand-mini" href="javascript:;">{{ $t('brand.mini') }}</a>
</h1>
</div>
<div class="aui-navbar__body">
<el-menu class="aui-navbar__menu mr-auto" mode="horizontal">
<el-menu-item
index="1"
@click="$store.state.sidebarFold = !$store.state.sidebarFold"
>
<svg
class="icon-svg aui-navbar__icon-menu aui-navbar__icon-menu--switch"
aria-hidden="true"
>
<el-menu-item index="1" @click="$store.state.sidebarFold = !$store.state.sidebarFold">
<svg class="icon-svg aui-navbar__icon-menu aui-navbar__icon-menu--switch" aria-hidden="true">
<use xlink:href="#icon-outdent"></use>
</svg>
</el-menu-item>
<el-menu-item index="2" @click="refresh()">
<svg
class="icon-svg aui-navbar__icon-menu aui-navbar__icon-menu--refresh"
aria-hidden="true"
>
<svg class="icon-svg aui-navbar__icon-menu aui-navbar__icon-menu--refresh" aria-hidden="true">
<use xlink:href="#icon-sync"></use>
</svg>
</el-menu-item>
@ -47,11 +31,7 @@
</a>
</el-menu-item> -->
<el-menu-item index="3">
<el-dropdown
placement="bottom"
:show-timeout="0"
@command="handleCommand"
>
<el-dropdown placement="bottom" :show-timeout="0" @command="handleCommand">
<span class="el-dropdown-link">
<svg class="icon-svg aui-navbar__icon-menu" aria-hidden="true">
<use xlink:href="#icon-earth"></use>
@ -59,12 +39,8 @@
<!-- <i class="el-icon-arrow-down el-icon--right"></i> -->
</span>
<el-dropdown-menu slot="dropdown">
<el-dropdown-item :disabled="getLang() === 'zh-CN'" command="toCN"
>中文</el-dropdown-item
>
<el-dropdown-item :disabled="getLang() === 'en'" command="toEN"
>En</el-dropdown-item
>
<el-dropdown-item :disabled="getLang() === 'zh-CN'" command="toCN">中文</el-dropdown-item>
<el-dropdown-item :disabled="getLang() === 'en'" command="toEN">En</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
</el-menu-item>
@ -81,22 +57,15 @@
<i class="el-icon-arrow-down"></i>
</span>
<el-dropdown-menu slot="dropdown">
<el-dropdown-item @click.native="updatePasswordHandle()">{{
$t('updatePassword.title')
}}</el-dropdown-item>
<el-dropdown-item @click.native="logoutHandle()">{{
$t('logout')
}}</el-dropdown-item>
<el-dropdown-item @click.native="updatePasswordHandle()">{{ $t('updatePassword.title') }}</el-dropdown-item>
<el-dropdown-item @click.native="logoutHandle()">{{ $t('logout') }}</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
</el-menu-item>
</el-menu>
</div>
<!-- 弹窗, 修改密码 -->
<update-password
v-if="updatePasswordVisible"
ref="updatePassword"
></update-password>
<update-password v-if="updatePasswordVisible" ref="updatePassword"></update-password>
</nav>
</template>
<script>
@ -128,11 +97,11 @@ export default {
this.$root.$i18n.locale = 'zh-CN'
window.navigator.language = 'zh-cn'
break
case 'toEN':
console.log('root', this.$root.$i18n.locale)
this.$root.$i18n.locale = 'en'
location.reload()
window.navigator.language = 'en-US'
case 'toEN':
console.log('root', this.$root.$i18n.locale)
this.$root.$i18n.locale = 'en'
location.reload()
window.navigator.language = 'en-US'
break
}
},
@ -156,15 +125,11 @@ export default {
},
// 退
logoutHandle() {
this.$confirm(
this.$t('prompt.info', { handle: this.$t('logout') }),
this.$t('prompt.title'),
{
confirmButtonText: this.$t('confirm'),
cancelButtonText: this.$t('cancel'),
type: 'warning'
}
)
this.$confirm(this.$t('prompt.info', { handle: this.$t('logout') }), this.$t('prompt.title'), {
confirmButtonText: this.$t('confirm'),
cancelButtonText: this.$t('cancel'),
type: 'warning'
})
.then(() => {
this.$http
.post(this.$http.adornUrl('/logout'))

View File

@ -58,6 +58,12 @@ export default {
}
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
init () {
this.visible = true
this.$nextTick(() => {

View File

@ -56,6 +56,12 @@ export default {
}
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
init () {
this.visible = true
this.getDataList()

View File

@ -97,6 +97,12 @@ export default {
Log
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
//
pauseHandle (id) {
if (!id && this.dataListSelections.length <= 0) {

View File

@ -30,7 +30,14 @@
layout="total, sizes, prev, pager, next, jumper"
></el-pagination>
<!-- 弹窗, 新增 / 修改 -->
<add-or-update v-if="addOrUpdateVisible" ref="addOrUpdate" :configs="addOrUpdateConfigs" @refreshDataList="getDataList" @select-change="handleDialogSelectChange" />
<add-or-update
v-if="addOrUpdateVisible"
ref="addOrUpdate"
:configs="addOrUpdateConfigs"
@refreshDataList="getDataList"
@select-change="handleDialogSelectChange"
@destory-dialog="handleDestroyDialog"
/>
</div>
</template>
@ -297,6 +304,12 @@ export default {
this.getTypeList()
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
// 线
getPlList() {
this.$http({

View File

@ -77,6 +77,12 @@ export default {
this.getDataList()
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
//
getDataList() {
this.dataListLoading = true

View File

@ -29,7 +29,7 @@
>
</el-pagination>
<!-- 弹窗, 新增 / 修改 -->
<add-or-update v-if="addOrUpdateVisible" ref="addOrUpdate" :configs="addOrUpdateConfigs" @refreshDataList="getDataList" @destory-dialog="addOrUpdateVisible = false" />
<add-or-update v-if="addOrUpdateVisible" ref="addOrUpdate" :configs="addOrUpdateConfigs" @refreshDataList="getDataList" @destory-dialog="handleDestroyDialog" />
</div>
</template>
@ -128,6 +128,12 @@ export default {
this.getDataList()
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
//
getEqList() {
this.$http({

View File

@ -80,6 +80,12 @@ export default {
this.getDataList()
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
//
getDataList() {
this.dataListLoading = true

View File

@ -22,7 +22,7 @@
>
</el-pagination>
<!-- 弹窗, 新增 / 修改 -->
<add-or-update v-if="addOrUpdateVisible" ref="addOrUpdate" :configs="addOrUpdateConfigs" @refreshDataList="getDataList" @destory-dialog="addOrUpdateVisible = false" />
<add-or-update v-if="addOrUpdateVisible" ref="addOrUpdate" :configs="addOrUpdateConfigs" @refreshDataList="getDataList" @destory-dialog="handleDestroyDialog" />
</div>
</template>
@ -86,6 +86,12 @@ export default {
this.getDataList()
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
//
getDataList() {
this.addOrUpdateVisible = false

View File

@ -44,7 +44,7 @@
layout="total, sizes, prev, pager, next, jumper"
></el-pagination>
<!-- 弹窗, 新增 / 修改 -->
<add-or-update v-if="addOrUpdateVisible" ref="addOrUpdate" :configs="addOrUpdateConfigs" @refreshDataList="getDataList" @destory-dialog="addOrUpdateVisible = false" />
<add-or-update v-if="addOrUpdateVisible" ref="addOrUpdate" :configs="addOrUpdateConfigs" @refreshDataList="getDataList" @destory-dialog="handleDestroyDialog" />
</div>
</template>
@ -125,6 +125,12 @@ export default {
this.getDataList()
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
//
getDictData() {
this.initDictList(Object.entries(dictEntries).map(([_, item]) => item.value))

View File

@ -40,6 +40,12 @@ export default {
this.getDataList()
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
//
getDataList() {
this.dataListLoading = true

View File

@ -22,7 +22,7 @@
>
</el-pagination>
<!-- 弹窗, 新增 / 修改 -->
<add-or-update v-if="addOrUpdateVisible" ref="addOrUpdate" :configs="addOrUpdateConfigs" @refreshDataList="getDataList" @destory-dialog="addOrUpdateVisible = false" />
<add-or-update v-if="addOrUpdateVisible" ref="addOrUpdate" :configs="addOrUpdateConfigs" @refreshDataList="getDataList" @destory-dialog="handleDestroyDialog" />
</div>
</template>
@ -106,6 +106,12 @@ export default {
this.getDataList()
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
//handleOperations
handleOperations({ type, data: id }) {
switch (type) {

View File

@ -23,7 +23,7 @@
>
</el-pagination>
<!-- 弹窗, 新增 / 修改 -->
<add-or-update v-if="addOrUpdateVisible" ref="addOrUpdate" :configs="addOrUpdateConfigs" @refreshDataList="getDataList" @destory-dialog="addOrUpdateVisible = false" />
<add-or-update v-if="addOrUpdateVisible" ref="addOrUpdate" :configs="addOrUpdateConfigs" @refreshDataList="getDataList" @destory-dialog="handleDestroyDialog" />
</div>
</template>
@ -141,6 +141,12 @@ export default {
this.getDataList()
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
//
getEqList() {
this.$http({

View File

@ -79,6 +79,12 @@ export default {
this.getDataList()
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
//
getDataList() {
this.dataListLoading = true

View File

@ -85,6 +85,12 @@ export default {
this.getDataList()
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
//
getDataList() {
this.dataListLoading = true

View File

@ -81,6 +81,12 @@ export default {
this.getDataList()
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
//
getDataList() {
this.dataListLoading = true

View File

@ -22,7 +22,7 @@
>
</el-pagination>
<!-- 弹窗, 新增 / 修改 -->
<add-or-update v-if="addOrUpdateVisible" ref="addOrUpdate" :configs="addOrUpdateConfigs" @refreshDataList="getDataList" @destory-dialog="addOrUpdateVisible = false" />
<add-or-update v-if="addOrUpdateVisible" ref="addOrUpdate" :configs="addOrUpdateConfigs" @refreshDataList="getDataList" @destory-dialog="handleDestroyDialog" />
</div>
</template>
@ -106,6 +106,12 @@ export default {
this.getDataList()
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
//
getTreeEquipmentType() {
this.$http({

View File

@ -81,6 +81,12 @@ export default {
this.getDataList()
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
//
getDataList() {
this.dataListLoading = true

View File

@ -79,6 +79,12 @@ export default {
this.getDataList()
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
//
getDataList() {
this.dataListLoading = true

View File

@ -22,7 +22,7 @@
>
</el-pagination>
<!-- 弹窗, 新增 / 修改 -->
<add-or-update v-if="addOrUpdateVisible" ref="addOrUpdate" :configs="addOrUpdateConfigs" @refreshDataList="getDataList" @destory-dialog="addOrUpdateVisible = false" />
<add-or-update v-if="addOrUpdateVisible" ref="addOrUpdate" :configs="addOrUpdateConfigs" @refreshDataList="getDataList" @destory-dialog="handleDestroyDialog" />
</div>
</template>
@ -99,6 +99,12 @@ export default {
this.getDataList()
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
//
getDataList() {
this.addOrUpdateVisible = false

View File

@ -12,7 +12,15 @@
</el-form-item>
</el-form>
<base-table :page="pageIndex" :size="pageSize" :data="dataList" :table-head-configs="tableConfigs" :max-height="calcMaxHeight(8)" @operate-event="handleOperations" @refreshDataList="getDataList" />
<base-table
:page="pageIndex"
:size="pageSize"
:data="dataList"
:table-head-configs="tableConfigs"
:max-height="calcMaxHeight(8)"
@operate-event="handleOperations"
@refreshDataList="getDataList"
/>
<el-pagination
@size-change="sizeChangeHandle"
@ -25,7 +33,7 @@
></el-pagination>
<!-- 弹窗, 新增 / 修改 -->
<!-- <add-or-update v-if="addOrUpdateVisible" ref="addOrUpdate" @refreshDataList="getDataList"></add-or-update> -->
<base-dialog v-if="showbasedialog" ref="basedialog" :configs="addOrUpdateConfigs" @refreshDataList="getDataList" />
<base-dialog v-if="showbasedialog" ref="basedialog" :configs="addOrUpdateConfigs" @refreshDataList="getDataList" @destory-dialog="handleDestroyDialog" />
</div>
</template>
@ -171,7 +179,12 @@ export default {
this.getDataList()
},
methods: {
//
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.showbasedialog = false
}, /** after dialog animated */ 200);
},
addOrEdit(id) {
this.showbasedialog = true
this.$nextTick(() => {

View File

@ -22,7 +22,7 @@
>
</el-pagination>
<!-- 弹窗, 新增 / 修改 -->
<add-or-update v-if="addOrUpdateVisible" :configs="addOrUpdateConfigs" ref="addOrUpdate" @refreshDataList="getDataList" @destroy-dialog="addOrUpdateVisible = false" />
<add-or-update v-if="addOrUpdateVisible" :configs="addOrUpdateConfigs" ref="addOrUpdate" @refreshDataList="getDataList" @destory-dialog="handleDestroyDialog" />
</div>
</template>
@ -111,6 +111,12 @@ export default {
this.getDataList()
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible = false
}, /** after dialog animated */ 200)
},
//
getProductList() {
this.$http({

View File

@ -22,7 +22,7 @@
>
</el-pagination>
<!-- 弹窗, 新增 / 修改 -->
<add-or-update v-if="addOrUpdateVisible" ref="addOrUpdate" :configs="addOrUpdateConfigs" @refreshDataList="getDataList" @destory-dialog="addOrUpdateVisible = false" />
<add-or-update v-if="addOrUpdateVisible" ref="addOrUpdate" :configs="addOrUpdateConfigs" @refreshDataList="getDataList" @destory-dialog="handleDestroyDialog" />
</div>
</template>
@ -111,6 +111,12 @@ export default {
this.getDataList()
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
//
getFactoryList() {
this.$http.get(this.$http.adornUrl('/monitoring/factory/list')).then(({ data: res }) => {

View File

@ -72,6 +72,12 @@ export default {
this.getDataList()
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
//
getDataList() {
this.dataListLoading = true

View File

@ -22,7 +22,7 @@
>
</el-pagination>
<!-- 弹窗, 新增 / 修改 -->
<add-or-update v-if="addOrUpdateVisible" ref="addOrUpdate" :configs="addOrUpdateConfigs" @refreshDataList="getDataList" @destory-dialog="addOrUpdateVisible = false" />
<add-or-update v-if="addOrUpdateVisible" ref="addOrUpdate" :configs="addOrUpdateConfigs" @refreshDataList="getDataList" @destory-dialog="handleDestroyDialog" />
</div>
</template>
@ -53,8 +53,8 @@ const addOrUpdateConfigs = {
type: 'dialog',
infoUrl: '/monitoring/qualityInspectionDet',
fields: [
{ name: 'typeId', label: i18n.t('inspect.type'), type: 'select', options: [] },
{ name: 'content', label: i18n.t('inspect.det') },
{ name: 'typeId', label: i18n.t('inspect.type'), required: true, type: 'select', options: [] },
{ name: 'content', label: i18n.t('inspect.det'), required: true },
{ name: 'code', label: i18n.t('inspect.detcode'), api: '/monitoring/qualityInspectionDet/getCode' },
'remark'
],
@ -92,6 +92,12 @@ export default {
this.getDataList()
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
//
getInspectionTypeList() {
this.$http({

View File

@ -29,7 +29,7 @@
ref="addOrUpdate"
:configs="addOrUpdateConfigs"
@refreshDataList="getDataList"
@destory-dialog="addOrUpdateVisible = false"
@destory-dialog="handleDestroyDialog"
@select-change="handleSelectChange"
/>
</div>
@ -124,6 +124,12 @@ export default {
this.getProductLines()
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
// handle
async handleSelectChange({ name, id }) {
if (name === 'productionId') {

View File

@ -10,7 +10,15 @@
</el-form-item>
</el-form>
<base-table :page="pageIndex" :size="pageSize" :data="dataList" :table-head-configs="tableConfigs" :max-height="calcMaxHeight(8)" @operate-event="handleOperations" @refreshDataList="getDataList" />
<base-table
:page="pageIndex"
:size="pageSize"
:data="dataList"
:table-head-configs="tableConfigs"
:max-height="calcMaxHeight(8)"
@operate-event="handleOperations"
@refreshDataList="getDataList"
/>
<el-pagination
@size-change="sizeChangeHandle"
@current-change="currentChangeHandle"
@ -22,7 +30,7 @@
>
</el-pagination>
<!-- 弹窗, 新增 / 修改 -->
<add-or-update v-if="addOrUpdateVisible" ref="addOrUpdate" :configs="addOrUpdateConfigs" @refreshDataList="getDataList" @destory-dialog="addOrUpdateVisible = false" />
<add-or-update v-if="addOrUpdateVisible" ref="addOrUpdate" :configs="addOrUpdateConfigs" @refreshDataList="getDataList" @destory-dialog="handleDestroyDialog" />
</div>
</template>
@ -42,7 +50,7 @@ const tableConfigs = [
},
{ prop: 'createTime', name: i18n.t('createTime'), filter: timeFilter },
{ prop: 'name', name: i18n.t('inspect.typename') },
{ prop: 'code', name: i18n.t('inspect.typename') },
{ prop: 'code', name: i18n.t('inspect.typecode') },
{ prop: 'remark', name: i18n.t('remark') },
{ prop: 'operations', name: i18n.t('handle'), fixed: 'right', width: 180, subcomponent: TableOperateComponent, options: ['edit', 'delete'] }
]
@ -50,7 +58,11 @@ const tableConfigs = [
const addOrUpdateConfigs = {
type: 'dialog',
infoUrl: '/monitoring/qualityInspectionType',
fields: [{ name: 'name', label: i18n.t('inspect.type') }, { name: 'code', label: i18n.t('inspect.typename'), api: '/monitoring/qualityInspectionType/getCode' }, 'remark'],
fields: [
{ name: 'name', label: i18n.t('inspect.type'), required: true },
{ name: 'code', label: i18n.t('inspect.typecode'), api: '/monitoring/qualityInspectionType/getCode' },
'remark'
],
operations: [
{ name: 'cancel', showAlways: true },
{ name: 'save', url: '/monitoring/qualityInspectionType', permission: 'monitoring:qualityinspectiontype:save', showOnEdit: false },
@ -84,6 +96,12 @@ export default {
this.getDataList()
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible = false
}, /** after dialog animated */ 200)
},
//
getDataList() {
this.addOrUpdateVisible = false

View File

@ -23,7 +23,7 @@
>
</el-pagination>
<!-- 弹窗, 新增 / 修改 -->
<add-or-update v-if="addOrUpdateVisible" ref="addOrUpdate" :configs="addOrUpdateConfigs" @refreshDataList="getDataList" @destory-dialog="addOrUpdateVisible = false" />
<add-or-update v-if="addOrUpdateVisible" ref="addOrUpdate" :configs="addOrUpdateConfigs" @refreshDataList="getDataList" @destory-dialog="handleDestroyDialog" />
</div>
</template>
@ -83,6 +83,12 @@ export default {
this.getDataList()
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
handleOperations({ type, data: id }) {
switch (type) {
case 'edit':

View File

@ -24,7 +24,7 @@
>
</el-pagination>
<!-- 弹窗, 新增 / 修改 -->
<add-or-update v-if="addOrUpdateVisible" ref="addOrUpdate" :configs="addOrUpdateConfigs" @refreshDataList="getDataList" @destory-dialog="addOrUpdateVisible = false" />
<add-or-update v-if="addOrUpdateVisible" ref="addOrUpdate" :configs="addOrUpdateConfigs" @refreshDataList="getDataList" @destory-dialog="handleDestroyDialog" />
</div>
</template>
@ -55,6 +55,12 @@ const CategoryList = {
this.pickedId = this.injectData[this.injectData.head.prop]
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
handleChange(id) {
this.pickedId = id
this.$emit('emit-data', {
@ -112,6 +118,12 @@ export default {
},
computed: {},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
getAllCategories() {
axios.get(axios.adornUrl('/monitoring/reportSheetCategory/page')).then(({ data: res }) => {
if (res.data && res.data.list) {

View File

@ -106,7 +106,7 @@ export default {
}
}
},
methods: {
methods: {
init(id) {
this.dataForm.id = id || 0
this.visible = true

View File

@ -73,6 +73,12 @@ export default {
this.getDataList()
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
//
getDataList() {
this.dataListLoading = true

View File

@ -91,7 +91,7 @@ export default {
}
}
},
methods: {
methods: {
init(id) {
this.dataForm.id = id || 0
this.visible = true

View File

@ -67,6 +67,12 @@ export default {
this.getDataList()
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
//
getDataList() {
this.dataListLoading = true

View File

@ -78,6 +78,12 @@ export default {
this.getDataList()
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
//
getDataList() {
this.dataListLoading = true

View File

@ -75,6 +75,12 @@ export default {
this.getDataList()
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
//
getDataList() {
this.dataListLoading = true

View File

@ -22,7 +22,7 @@
>
</el-pagination>
<!-- 弹窗, 新增 / 修改 -->
<add-or-update v-if="addOrUpdateVisible" ref="addOrUpdate" @refreshDataList="getDataList" @destory-dialog="addOrUpdateVisible = false" />
<add-or-update v-if="addOrUpdateVisible" ref="addOrUpdate" @refreshDataList="getDataList" @destory-dialog="handleDestroyDialog" />
</div>
</template>
@ -96,6 +96,12 @@ export default {
this.getDataList()
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
// 线
getProductLine() {
this.$http.get(this.$http.adornUrl('/monitoring/productionLine/list')).then(({ data: res }) => {

View File

@ -68,6 +68,12 @@ export default {
this.getDataList()
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
//
getDataList() {
this.dataListLoading = true

View File

@ -123,7 +123,7 @@ export default {
mounted() {
this.getLineList()
},
methods: {
methods: {
init(id) {
this.dataForm = {
id: null,

View File

@ -152,6 +152,12 @@ export default {
}
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
init() {
this.visible = true
this.$nextTick(() => {

View File

@ -20,6 +20,12 @@ export default {
}
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
init() {
this.visible = true
// this.url = `${window.SITE_CONFIG['apiURL']}/sys/oss/upload?token=${Cookies.get('token')}`

View File

@ -64,6 +64,12 @@ export default {
Upload
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
//
configHandle() {
this.configVisible = true

View File

@ -65,6 +65,12 @@ export default {
}
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
init() {
this.visible = true
this.$nextTick(() => {

View File

@ -47,6 +47,12 @@ export default {
}
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
init() {
this.visible = true
this.$nextTick(() => {

View File

@ -77,6 +77,12 @@ export default {
this.getDataList()
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
// /
addOrUpdateHandle(id) {
this.addOrUpdateVisible = true

View File

@ -46,6 +46,12 @@ export default {
}
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
init() {
this.visible = true
this.$nextTick(() => {

View File

@ -87,6 +87,12 @@ export default {
IconsDialog
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
//
showIcons() {
this.displayIcon = true

View File

@ -54,6 +54,12 @@ export default {
}
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
//
infoHandle(info) {
this.$alert(info, this.$t('logError.errorInfo'), {

View File

@ -95,6 +95,12 @@ export default {
}
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
init() {
this.visible = true
this.$nextTick(() => {

View File

@ -41,6 +41,12 @@ export default {
}
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
init() {
this.visible = true
this.$nextTick(() => {

View File

@ -52,6 +52,12 @@ export default {
}
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
init() {
this.visible = true
this.$nextTick(() => {

View File

@ -111,6 +111,12 @@ export default {
}
},
methods: {
// destroy dialog
handleDestroyDialog() {
setTimeout(() => {
this.addOrUpdateVisible= false
}, /** after dialog animated */ 200);
},
init() {
this.visible = true
this.dataForm.deptId = ''

View File

@ -93,9 +93,9 @@ export default {
this.$root.$i18n.locale = 'zh-CN'
// location.reload()
break
case 'en':
this.$root.$i18n.locale = 'en'
location.reload()
case 'en':
this.$root.$i18n.locale = 'en'
location.reload()
break
}
},