This commit is contained in:
helloDy
2024-04-11 16:49:48 +08:00
parent 2592551e66
commit 63a753d7d6
32 changed files with 284 additions and 219 deletions

View File

@@ -138,7 +138,7 @@ export default {
color: 'primary',
},
{
type: 'separate',
type: this.$auth.hasPermi('base:core-customer:create') ? 'separate' : '',
},
{
type: this.$auth.hasPermi('base:core-customer:create') ? 'button' : '',

View File

@@ -110,7 +110,7 @@ export default {
color: 'primary',
},
{
type: 'separate',
type: this.$auth.hasPermi('base:core-department:create') ? 'separate' : '',
},
{
type: this.$auth.hasPermi('base:core-department:create') ? 'button' : '',

View File

@@ -156,11 +156,11 @@ export default {
prop: 'createTime',
label: '添加时间',
fixed: true,
width: 180,
minWidth: 180,
filter: (val) => moment(val).format('yyyy-MM-DD HH:mm:ss'),
},
{ prop: 'name', label: '设备名称', width: 180, showOverflowtooltip: true },
{ width: 250, prop: 'code', label: '设备编码' },
{ prop: 'name', label: '设备名称', minWidth: 180, showOverflowtooltip: true },
{ minWidth: 250, prop: 'code', label: '设备编码' },
{ prop: 'equipmentTypeName', label: '设备类型' },
{ prop: 'enName', label: '英文名称' },
{ prop: 'abbr', label: '缩写' },
@@ -211,7 +211,7 @@ export default {
color: 'primary',
},
{
type: 'separate',
type: (this.$auth.hasPermi('base:core-equipment:export') || this.$auth.hasPermi('base:core-equipment:create')) ? 'separate' : '',
},
{
type: this.$auth.hasPermi('base:core-equipment:export')

View File

@@ -126,7 +126,8 @@ export default {
color: 'primary',
},
{
type: 'separate',
type: this.$auth.hasPermi('base:core-equipment-bind-section:create')
? 'separate' : '',
},
{
type: this.$auth.hasPermi('base:core-equipment-bind-section:create')

View File

@@ -90,7 +90,7 @@ export default {
prop: 'createTime',
label: '添加时间',
fixed: true,
width: 180,
minWidth: 180,
filter: (val) => moment(val).format('yyyy-MM-DD HH:mm:ss'),
},
{ prop: 'name', label: '类型名称' },
@@ -111,7 +111,8 @@ export default {
color: 'primary',
},
{
type: 'separate',
type: this.$auth.hasPermi('base:core-equipment-type:create')
? 'separate' : '',
},
{
type: this.$auth.hasPermi('base:core-equipment-type:create')

View File

@@ -137,7 +137,7 @@ export default {
color: 'primary',
},
{
type: 'separate',
type: this.$auth.hasPermi('base:core-hot-material-check:create') ? 'separate' : '',
},
{
type: this.$auth.hasPermi('base:core-hot-material-check:create') ? 'button' : '',

View File

@@ -110,7 +110,7 @@ export default {
color: 'primary',
},
{
type: 'separate',
type: this.$auth.hasPermi('base:core-major:create') ? 'separate' : '',
},
{
type: this.$auth.hasPermi('base:core-major:create') ? 'button' : '',

View File

@@ -14,7 +14,7 @@
<method-btn
v-if="tableBtn.length"
slot="handleBtn"
:width="120"
:Width="120"
label="操作"
:method-list="tableBtn"
@clickBtn="handleClick" />
@@ -48,45 +48,45 @@ const tableProps = [
prop: 'createTime',
label: '添加时间',
filter: parseTime,
width: 150,
minWidth: 150,
showOverflowtooltip: true
},
{
prop: 'name',
label: '产品名称',
width: 150,
minWidth: 150,
showOverflowtooltip: true
},
{
prop: 'code',
label: '产品编码',
width: 190,
minWidth: 190,
showOverflowtooltip: true
},
{
prop: 'productType',
label: '产品类型',
filter: publicFormatter('product_type'),
width: 180,
minWidth: 180,
showOverflowtooltip: true
},
{
prop: 'specifications',
label: '规格',
width: 150,
minWidth: 150,
showOverflowtooltip: true
},
{
prop: 'unit',
label: '单位',
filter: publicFormatter('unit_dict'),
width: 90,
minWidth: 90,
showOverflowtooltip: true
},
{
prop: 'remark',
label: '备注',
width: 120,
minWidth: 120,
showOverflowtooltip: true
},
];
@@ -141,7 +141,7 @@ export default {
color: 'primary',
},
{
type: 'separate',
type: this.$auth.hasPermi('base:core-product:create') ? 'separate' : '',
},
{
type: this.$auth.hasPermi('base:core-product:create') ? 'button' : '',

View File

@@ -14,7 +14,7 @@
<method-btn
v-if="tableBtn.length"
slot="handleBtn"
:width="120"
:minWidth="120"
label="操作"
:method-list="tableBtn"
@clickBtn="handleClick" />
@@ -30,7 +30,7 @@
@cancel="handleCancel"
@confirm="handleConfirm"
:before-close="handleCancel"
width="50%">
minWidth="50%">
<add-or-update
ref="addOrUpdate"
@refreshDataList="successSubmit"></add-or-update>
@@ -56,39 +56,39 @@ const tableProps = [
prop: 'createTime',
label: '添加时间',
filter: parseTime,
width: 150,
minWidth: 150,
showOverflowtooltip: true
},
{
prop: 'factoryName',
label: '工厂',
width: 150,
minWidth: 150,
showOverflowtooltip: true
},
{
prop: 'roomNameDict',
label: '车间名称',
filter: publicFormatter('workshop'),
width: 120,
minWidth: 120,
showOverflowtooltip: true
},
{
prop: 'name',
label: '产线名称',
width: 120,
minWidth: 120,
showOverflowtooltip: true
},
{
prop: 'code',
label: '产线编码',
width: 150,
minWidth: 150,
showOverflowtooltip: true
},
{
prop: 'enabled',
label: '当前状态',
filter: codeFilter('lineStatus'),
width: 120,
minWidth: 120,
showOverflowtooltip: true
},
// {
@@ -98,13 +98,13 @@ const tableProps = [
{
prop: 'description',
label: '描述',
width: 120,
minWidth: 120,
showOverflowtooltip: true
},
{
prop: 'remark',
label: '备注',
width: 120,
minWidth: 120,
showOverflowtooltip: true
}
];
@@ -147,7 +147,7 @@ export default {
color: 'primary',
},
{
type: 'separate',
type: this.$auth.hasPermi('base:core-production-line:create') ? 'separate' : '',
},
{
type: this.$auth.hasPermi('base:core-production-line:create') ? 'button' : '',

View File

@@ -132,7 +132,7 @@ export default {
color: 'primary',
},
{
type: 'separate',
type: this.$auth.hasPermi('base:core-supplier:create') ? 'separate' : '',
},
{
type: this.$auth.hasPermi('base:core-supplier:create') ? 'button' : '',

View File

@@ -2,7 +2,7 @@
* @Author: zwq
* @Date: 2021-11-18 14:16:25
* @LastEditors: DY
* @LastEditTime: 2024-04-08 14:27:29
* @LastEditTime: 2024-04-10 16:16:31
* @Description:
-->
<template>
@@ -201,24 +201,26 @@
@pagination="getList" /> -->
</div>
<div class="card" style="padding-bottom: 16px;">
<div class="boxTitle">
<span class="blueTitle"></span>
<span>预计用料信息</span>
<div v-if="this.$auth.hasPermiAnd(['base:material-product-bom-det:query', 'extend:process-flow:query'])">
<div class="card" style="padding-bottom: 16px;">
<div class="boxTitle">
<span class="blueTitle"></span>
<span>预计用料信息</span>
</div>
<base-table
:table-props="tableProps1"
:page="listQuery1.pageNo"
:limit="listQuery1.pageSize"
:table-data="materialList"
:max-height="tableH" />
<!-- <pagination
v-show="listQuery1.total > 0"
:total="listQuery1.total"
:page.sync="listQuery1.pageNo"
:limit.sync="listQuery1.pageSize"
:page-sizes="[5, 10, 15]"
@pagination="getList" /> -->
</div>
<base-table
:table-props="tableProps1"
:page="listQuery1.pageNo"
:limit="listQuery1.pageSize"
:table-data="materialList"
:max-height="tableH" />
<!-- <pagination
v-show="listQuery1.total > 0"
:total="listQuery1.total"
:page.sync="listQuery1.pageNo"
:limit.sync="listQuery1.pageSize"
:page-sizes="[5, 10, 15]"
@pagination="getList" /> -->
</div>
<!-- <div class="drawer-body__footer">
@@ -461,7 +463,7 @@ export default {
});
// 获取预使用原料列表
console.log('111我看看', this.dataForm.materialMethod)
if (this.dataForm.id) {
if (this.dataForm.id && this.$auth.hasPermiAnd(['base:material-product-bom-det:query', 'extend:process-flow:query'])) {
if (this.dataForm.materialMethod === 1) {
// 产品
getlistByProductId({

View File

@@ -157,92 +157,105 @@ export default {
// showTip: '预使用原料信息'
// }
// : undefined,
{
type: 'active',
btnName: '激活',
showParam: {
type: '|',
data: [
{
name: 'status',
type: 'equal',
value: 1
},
{
name: 'status',
type: 'equal',
value: 3
}
]
this.$auth.hasPermi(`base:core-work-order:update`)
? {
type: 'active',
btnName: '激活',
showParam: {
type: '|',
data: [
{
name: 'status',
type: 'equal',
value: 1
},
{
name: 'status',
type: 'equal',
value: 3
}
]
}
}
},
{
type: 'pause',
btnName: '暂停',
showParam: {
type: '|',
data: [
{
name: 'status',
type: 'equal',
value: 2
}
]
: undefined,
this.$auth.hasPermi(`base:core-work-order:update`)
? {
type: 'pause',
btnName: '暂停',
showParam: {
type: '|',
data: [
{
name: 'status',
type: 'equal',
value: 2
}
]
}
}
},
{
type: 'nullify',
btnName: '作废',
showParam: {
type: '|',
data: [
{
name: 'status',
type: 'equal',
value: 1
}
]
: undefined,
this.$auth.hasPermi(`base:core-work-order:update`)
? {
type: 'nullify',
btnName: '作废',
showParam: {
type: '|',
data: [
{
name: 'status',
type: 'equal',
value: 1
}
]
}
}
},
{
type: 'finish',
btnName: '完成',
showParam: {
type: '|',
data: [
{
name: 'status',
type: 'equal',
value: 2
},
{
name: 'status',
type: 'equal',
value: 3
}
]
: undefined,
this.$auth.hasPermi(`base:core-work-order:update`)
? {
type: 'finish',
btnName: '完成',
showParam: {
type: '|',
data: [
{
name: 'status',
type: 'equal',
value: 2
},
{
name: 'status',
type: 'equal',
value: 3
}
]
}
}
},
{
type: 'stop',
btnName: '终止',
showParam: {
type: '|',
data: [
{
name: 'status',
type: 'equal',
value: 2
},
{
name: 'status',
type: 'equal',
value: 3
}
]
: undefined,
this.$auth.hasPermi(`base:core-work-order:update`)
? {
type: 'stop',
btnName: '终止',
showParam: {
type: '|',
data: [
{
name: 'status',
type: 'equal',
value: 2
},
{
name: 'status',
type: 'equal',
value: 3
}
]
}
}
},
this.$auth.hasPermi(`base:core-work-order:detail`)
: undefined,
this.$auth.hasPermiAnd([
'base:core-work-order:query',
'base:order:query'
])
? {
type: 'detail',
btnName: '查看详情',

View File

@@ -163,7 +163,7 @@ export default {
color: 'primary',
},
{
type: 'separate',
type: this.$auth.hasPermi('base:core-worker:create') ? 'separate' : '',
},
{
type: this.$auth.hasPermi('base:core-worker:create') ? 'button' : '',

View File

@@ -52,8 +52,7 @@ const tableProps = [
{
prop: 'createTime',
label: '添加时间',
filter: parseTime,
filter: parseTime
},
{
prop: 'code',
@@ -116,7 +115,7 @@ export default {
color: 'primary',
},
{
type: 'separate',
type: this.$auth.hasPermi('base:core-workshop-section:create') ? 'separate' : '',
},
{
type: this.$auth.hasPermi('base:core-workshop-section:create') ? 'button' : '',

View File

@@ -2,7 +2,7 @@
* @Author: zwq
* @Date: 2021-11-18 14:16:25
* @LastEditors: DY
* @LastEditTime: 2024-03-21 15:21:32
* @LastEditTime: 2024-04-11 16:22:19
* @Description:
-->
<template>
@@ -121,15 +121,15 @@
</el-row>
</el-form>
</div>
<div class="attr-list" v-if="idAttrShow">
<div class="attr-list" v-if="idAttrShow && this.$auth.hasPermi('base:material-attr:query')">
<small-title
style="margin: 16px 0; padding-left: 8px"
:no-padding="true">
物料属性
</small-title>
<div v-if="!isdetail" class="action_btn">
<div v-if="!isdetail && this.$auth.hasPermi('base:material-attr:create')" class="action_btn">
<template>
<span style="display: inline-block;">
<el-button type="text" @click="addNew()" icon="el-icon-plus">新增</el-button>
@@ -182,16 +182,23 @@ import { parseTime } from '../../core/mixins/code-filter';
import attrAdd from './attr-add';
import { getDictDatas } from "@/utils/dict";
const tableBtn = [
{
type: 'edit',
btnName: '编辑',
},
{
type: 'delete',
btnName: '删除',
},
];
// const tableBtn = [
// this.$auth.hasPermiAnd([
// 'base:material-attr:create',
// 'base:material-attr:update'
// ]) ?
// {
// type: 'edit',
// btnName: '编辑',
// }
// : undefined,
// this.$auth.hasPermi('base:material-attr:delete') ?
// {
// type: 'delete',
// btnName: '删除',
// }
// : undefined,
// ];
const tableProps = [
{
prop: 'createTime',
@@ -213,7 +220,23 @@ export default {
components: { SmallTitle, attrAdd },
data() {
return {
tableBtn,
tableBtn: [
this.$auth.hasPermiAnd([
'base:material-attr:create',
'base:material-attr:update'
]) ?
{
type: 'edit',
btnName: '编辑',
}
: undefined,
this.$auth.hasPermi('base:material-attr:delete') ?
{
type: 'delete',
btnName: '删除',
}
: undefined,
],
tableProps,
addOrUpdateVisible: false,
urlOptions: {

View File

@@ -134,7 +134,7 @@ export default {
color: 'primary',
},
{
type: 'separate',
type: this.$auth.hasPermi('base:material:create') ? 'separate' : '',
},
{
type: this.$auth.hasPermi('base:material:create') ? 'button' : '',

View File

@@ -2,7 +2,7 @@
* @Author: zwq
* @Date: 2021-11-18 14:16:25
* @LastEditors: DY
* @LastEditTime: 2024-03-21 14:39:52
* @LastEditTime: 2024-04-11 16:44:41
* @Description:
-->
<template>
@@ -56,14 +56,14 @@
</el-row>
</el-form>
</div>
<div class="attr-list" v-if="idAttrShow">
<div class="attr-list" v-if="idAttrShow && this.$auth.hasPermiAnd(['base:material-product-bom:query', 'base:material-product-bom-det:query'])">
<small-title
style="margin: 16px 0; padding-left: 8px"
:no-padding="true">
BOM明细
</small-title>
<div v-if="!isdetail" class="action_btn">
<div v-if="!isdetail && this.$auth.hasPermi('base:material-product-bom:create')" class="action_btn">
<template>
<span style="display: inline-block;">
<el-button type="text" @click="addNew()" icon="el-icon-plus">添加</el-button>
@@ -116,16 +116,16 @@ import { parseTime } from '../../core/mixins/code-filter';
import attrAdd from './attr-add';
import { publicFormatter } from '@/utils/dict';
const tableBtn = [
{
type: 'edit',
btnName: '编辑',
},
{
type: 'delete',
btnName: '删除',
},
];
// const tableBtn = [
// {
// type: 'edit',
// btnName: '编辑',
// },
// {
// type: 'delete',
// btnName: '删除',
// },
// ];
const tableProps = [
{
prop: 'createTime',
@@ -160,7 +160,24 @@ export default {
components: { SmallTitle, attrAdd },
data() {
return {
tableBtn,
tableBtn: [
this.$auth.hasPermiAnd([
'base:material-product-bom:update',
'base:material-product-bom-det:create',
'base:material-product-bom-det:update'
]) ?
{
type: 'edit',
btnName: '编辑',
}
: undefined,
this.$auth.hasPermi('base:material-product-bom:delete') ?
{
type: 'delete',
btnName: '删除',
}
: undefined,
],
tableProps,
addOrUpdateVisible: false,
urlOptions: {

View File

@@ -110,7 +110,7 @@ export default {
color: 'primary',
},
{
type: 'separate',
type: this.$auth.hasPermi('base:material:create') ? 'separate' : '',
},
{
type: this.$auth.hasPermi('base:material:create') ? 'button' : '',