Browse Source

【EQI】前端开发

web
安虹睿 4 days ago
parent
commit
3a265eb2ef
  1. 18
      Web/src/api/common/index.js
  2. 10
      Web/src/api/system/taskConifgureApi.js
  3. 161
      Web/src/components/ediTtablePage/index.vue
  4. 42
      Web/src/components/elTable/index.vue
  5. 336
      Web/src/components/elTable/index_norule.vue
  6. 353
      Web/src/components/elTable/index_rulr.vue
  7. 10
      Web/src/components/tablePage/index.vue
  8. 2
      Web/src/layout/components/Sidebar/index.vue
  9. 2
      Web/src/styles/variables.module.scss
  10. 70
      Web/src/utils/common/apiTableColumns.js
  11. 14
      Web/src/utils/common/enumList.js
  12. 4
      Web/src/utils/request.js
  13. 14
      Web/src/views/logisticsPlan/supplierConMmrp/index.vue
  14. 6
      Web/src/views/logisticsPlan/supplierInvData/index.vue
  15. 6
      Web/src/views/logisticsPlan/supplierMrpDate/index.vue
  16. 6
      Web/src/views/logisticsPlan/supplierMrpMonth/index.vue
  17. 6
      Web/src/views/logisticsPlan/supplierMrpState/index.vue
  18. 6
      Web/src/views/logisticsPlan/supplierMrpWarning/index.vue
  19. 6
      Web/src/views/logisticsPlan/supplierPo/index.vue
  20. 6
      Web/src/views/logisticsPlan/supplierProHschedul/index.vue
  21. 2
      Web/src/views/logisticsPlan/supplierProPlaning/index.vue
  22. 6
      Web/src/views/logisticsPlan/supplierProTschedul/index.vue
  23. 6
      Web/src/views/logisticsPlan/supplierReturn/index.vue
  24. 6
      Web/src/views/logisticsPlan/supplierSaWeek/index.vue
  25. 6
      Web/src/views/logisticsPlan/supplierSinvData/index.vue
  26. 6
      Web/src/views/productionQuality/supplierBom/index.vue
  27. 6
      Web/src/views/productionQuality/supplierEmployee/index.vue
  28. 6
      Web/src/views/productionQuality/supplierInfo/index.vue
  29. 6
      Web/src/views/productionQuality/supplierProAttachmentData/index.vue
  30. 6
      Web/src/views/productionQuality/supplierProCps/index.vue
  31. 6
      Web/src/views/productionQuality/supplierProData/index.vue
  32. 6
      Web/src/views/productionQuality/supplierProFirstPassyield/index.vue
  33. 6
      Web/src/views/productionQuality/supplierProFlaw/index.vue
  34. 6
      Web/src/views/productionQuality/supplierProMaterialStock/index.vue
  35. 6
      Web/src/views/productionQuality/supplierProProcess/index.vue
  36. 6
      Web/src/views/productionQuality/supplierProProcessEquipment/index.vue
  37. 6
      Web/src/views/productionQuality/supplierProScheduling/index.vue
  38. 6
      Web/src/views/productionQuality/upplierProMaterialData/index.vue
  39. 6
      Web/src/views/productionQuality/upplierProStationFirstPassyield/index.vue
  40. 68
      Web/src/views/system/taskConifgure/index.vue
  41. 6
      Web/src/views/task/taskSub/index.vue

18
Web/src/api/common/index.js

@ -95,4 +95,20 @@ export function getCommonDetailById(urlName,id) {
}) })
} }
// getCommonInfoById // 手动传出(批量)
export function postCommonConfirmMany(urlName,data) {
return request({
url: `/api/${urlName}/confirm`,
method: 'post',
data
})
}
// 保存页面(批量)
export function postCommonUpdateMany(urlName,data) {
return request({
url: `/api/${urlName}/batchupdate`,
method: 'post',
data
})
}

10
Web/src/api/system/taskConifgureApi.js

@ -0,0 +1,10 @@
import request from '@/utils/request'
// 是否自动执行
export function getSetisautoByUid(params) {
return request({
url: `/api/taskconifgure/setisauto`,
method: 'get',
params:params
})
}

161
Web/src/components/ediTtablePage/index.vue

@ -74,7 +74,7 @@
</el-card> </el-card>
<!-- 头部详情 --> <!-- 头部详情 -->
<el-card v-loading="state.detailLoading" class="headerInfo-container" v-if="!props.hideHeaderInfo"> <el-card v-loading="state.detailLoading" class="headerInfo-container" v-if="!props.hideHeaderInfo">
<el-descriptions :border="true" :column="6" v-if="state.headerInfoData && state.headerInfoData.length > 0"> <el-descriptions :title="`当前页【第${getIndexById()}行】数据信息`" :border="true" :column="6" v-if="state.headerInfoData && state.headerInfoData.length > 0">
<el-descriptions-item <el-descriptions-item
v-for="(item,index) in state.headerInfoData" v-for="(item,index) in state.headerInfoData"
:key="index" :key="index"
@ -87,6 +87,7 @@
<!-- 列表 --> <!-- 列表 -->
<el-card class="paged-table-container"> <el-card class="paged-table-container">
<elTable <elTable
ref="table_Ref"
:columnWidth="props.columnWidth" :columnWidth="props.columnWidth"
:columnHeaderAlign="props.columnHeaderAlign" :columnHeaderAlign="props.columnHeaderAlign"
:columnAlign="props.columnAlign" :columnAlign="props.columnAlign"
@ -105,7 +106,11 @@
@editItemClearHandle="(item,scope)=>{getItemDetail(item.type,scope.row,'clear')}" @editItemClearHandle="(item,scope)=>{getItemDetail(item.type,scope.row,'clear')}"
:getEditItemDisabled="getEditItemDisabled" :getEditItemDisabled="getEditItemDisabled"
:selectableDisabled="selectableDisabled" :selectableDisabled="selectableDisabled"
:tableRowClassName="tableRowClassName"
:showTableIndex="props.showTableIndex"
></elTable> ></elTable>
<!-- :tableFormRules="state.tableFormRulesData" -->
<elPager <elPager
v-loading="state.pageLoading" v-loading="state.pageLoading"
@ -145,8 +150,10 @@
postCommonCreate, postCommonCreate,
putCommonUpdate, putCommonUpdate,
deleteCommonApi, deleteCommonApi,
getCommonCustominvoke , getCommonCustominvoke,
getCommonDetailById getCommonDetailById,
postCommonConfirmMany,
postCommonUpdateMany
} from '@/api/common/index' } from '@/api/common/index'
import { ElMessageBox, ElMessage,ElTable, ElTableColumn } from 'element-plus' import { ElMessageBox, ElMessage,ElTable, ElTableColumn } from 'element-plus'
import elTable from '@/components/elTable/index.vue' import elTable from '@/components/elTable/index.vue'
@ -177,7 +184,7 @@
custominvoke:{icon:'Position',auth:':custominvoke',label:'手动开关',type:'primary'}, custominvoke:{icon:'Position',auth:':custominvoke',label:'手动开关',type:'primary'},
outputMany:{icon:'Position',auth:':outputMany',label:'手动传出',type:'primary'}, outputMany:{icon:'Position',auth:':outputMany',label:'手动传出',type:'primary'},
}, },
searchRightBtn:[{icon:'Check',auth:':pageSave',label:'保存页面',type:'warning'}], searchRightBtn:[{name:'pageSave',icon:'Check',auth:':pageSave',label:'保存页面',type:'warning'}],
tableData:[], tableData:[],
// table // table
sortFilter:{ sortFilter:{
@ -198,6 +205,8 @@
stage_tableData:[], stage_tableData:[],
// //
stage_indexs:[], stage_indexs:[],
//tabel
tableFormRulesData:null,
}) })
const props = defineProps({ const props = defineProps({
@ -226,6 +235,11 @@
type: Boolean, type: Boolean,
default: false default: false
}, },
//
showTableIndex:{
type: Boolean,
default: true
},
// //
leftOperation:{ leftOperation:{
type: Object, type: Object,
@ -290,6 +304,11 @@
type: Object, type: Object,
default: null default: null
}, },
// table
tableFormRules:{
type: Object,
default: null
},
// //
hideHeaderInfo:{ hideHeaderInfo:{
type: Boolean, type: Boolean,
@ -301,6 +320,7 @@
type: Object, type: Object,
default: [ default: [
{prop:'readState',ruleValue:true}, {prop:'readState',ruleValue:true},
// {prop:'releaseEdition',ruleValue:'2024121901'},
] ]
}, },
}) })
@ -503,6 +523,9 @@
// //
function getTableData(page) { function getTableData(page) {
state.stage_indexs = [] state.stage_indexs = []
state.currentDetailId = null
state.headerInfoData = []
state.tableSelectList = []
if(props.apiType == 'detailApi'){ if(props.apiType == 'detailApi'){
state.loading = true state.loading = true
if(!page)page = state.pager.page if(!page)page = state.pager.page
@ -586,25 +609,65 @@
} }
// //
else if (btn == 'outputMany'){ else if (btn == 'outputMany'){
let _idEditData = checkPageEditList()
if(_idEditData && _idEditData.length > 0){
return ElMessage.warning('当前有未保存修改项,请先保存页面')
}
if(!state.tableSelectList || state.tableSelectList.length <= 0 ){ if(!state.tableSelectList || state.tableSelectList.length <= 0 ){
return ElMessage.warning('未选中任何数据') return ElMessage.warning('未选中任何数据')
} }
// todo: ElMessageBox.confirm('是否确定手动传出?', '提示', {
console.log(state.tableSelectList) confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
state.loading = true
postCommonConfirmMany(props.apiName,state.tableSelectList)
.then(res=>{
ElMessage.success('操作成功!')
getTableData(1)
})
.finally(()=>{state.loading = false})
})
} }
} }
const table_Ref = ref(null)
// //
function searchRightBtnHandle(btn){ function searchRightBtnHandle(btn){
let _idEditData = checkPageEditList() //
if(!_idEditData || _idEditData.length <= 0)return ElMessage.warning('暂无数据修改') if(btn.name == 'pageSave'){
ElMessageBox.confirm('是否确定提交更改?', '提示', { table_Ref.value.tableForm_Ref.validate((valid)=>{
confirmButtonText: '确定', if(valid){
cancelButtonText: '取消', let _idEditData = checkPageEditList()
type: 'warning' if(!_idEditData || _idEditData.length <= 0)return ElMessage.warning('暂无数据修改')
}).then(() => { //
// todo: // [feedbackResults]=1[ventureType],[ventureSpecific]
console.log(613,_idEditData) let _indexs = []
}) _idEditData.forEach(item=>{
if(item.feedbackResults == '1' && (!item.ventureType || !item.ventureSpecific || item.ventureSpecifi == '')){
_indexs.push(getIndexById(item.id))
}
})
if(_indexs && _indexs.length > 0){
return ElMessage.error(`修改数据中【第${_indexs}行】数据中,【反馈结果】为异常,但【风险类型】或【具体风险】为空,请修改后重新提交!`)
}
ElMessageBox.confirm('是否确定提交更改?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
state.loading = true
postCommonUpdateMany(props.apiName,_idEditData)
.then(res=>{
ElMessage.success('操作成功!')
getTableData(1)
})
.finally(()=>{state.loading = false})
})
}
})
}
} }
// //
@ -662,15 +725,18 @@
return _name return _name
} }
// //
function getEditItemDisabled(item,row,index){ function getIndexById(id){
let _auth = auths.hasPermission(props.apiName+':pageSave') let _id = id || state.currentDetailId
if(item.disabled || !_auth){ for(let i=0;i<state.stage_tableData.length;i++){
return true if(state.stage_tableData[i].id == _id){
} return i + 1
if(state.tableSelectList && state.tableSelectList.length > 0){ }
return true
} }
}
//
function checkDisableByRowRule(row){
let hasDisable = false let hasDisable = false
for(let i = 0;i<props.editDisabledConfig.length;i++){ for(let i = 0;i<props.editDisabledConfig.length;i++){
if(row[props.editDisabledConfig[i].prop] == props.editDisabledConfig[i].ruleValue){ if(row[props.editDisabledConfig[i].prop] == props.editDisabledConfig[i].ruleValue){
@ -681,17 +747,34 @@
return hasDisable return hasDisable
} }
//
function getEditItemDisabled(item,row,index){
//
let _auth = auths.hasPermission(props.apiName+':pageSave')
if(item.disabled || !_auth){
return true
}
//
if(state.tableSelectList && state.tableSelectList.length > 0){
return true
}
//
return checkDisableByRowRule(row)
}
// table // table
function selectableDisabled(row,index){ function selectableDisabled(row,index){
//
let _auth = auths.hasPermission(props.apiName+':outputMany') let _auth = auths.hasPermission(props.apiName+':outputMany')
if(!_auth)return false //
let _idEditData = checkPageEditList() let _idEditData = checkPageEditList()
return !_idEditData || _idEditData.length <= 0 // ()
let checkRow = checkDisableByRowRule(row)
return _auth && (!_idEditData || _idEditData.length <= 0) && !checkRow
} }
// Focus // Focus todo:
function getItemDetail(type,row,eventType) { function getItemDetail(type,row,eventType) {
state.tableSelectList = []
// id // id
if(row.id == state.currentDetailId){return} if(row.id == state.currentDetailId){return}
let _focuseExt = ['input','numberInput'] let _focuseExt = ['input','numberInput']
@ -761,7 +844,29 @@
} }
} }
//
function tableRowClassName(data){
if(data.row.id == state.currentDetailId){return 'current-select-tableRow'}
else{return 'normal-tableRow'}
}
// apiTableColumnstable
// todo:feedbackResults,measures
function getTableFormRules(){
if(props.tableFormRules) {
state.tableFormRulesData = props.tableFormRules
}else{
state.tableFormRulesData = {}
apiTableColumns[props.apiName].forEach(item=>{
if(item.required){
state.tableFormRulesData[item.prop] = [{ required: true, message: '必填项', trigger: 'change' }]
}
})
}
}
onMounted(() => { onMounted(() => {
// getTableFormRules()
getTableData() getTableData()
}) })

42
Web/src/components/elTable/index.vue

@ -6,7 +6,8 @@
:border="true" :border="true"
@sort-change="sortChange" @sort-change="sortChange"
@selection-change="tableSelectionHandle" @selection-change="tableSelectionHandle"
:row-class-name="'setDisabledStyle'" :row-class-name="props.tableRowClassName"
:cell-class-name="props.tableCellClassName"
> >
<!-- 多选框 --> <!-- 多选框 -->
<el-table-column <el-table-column
@ -16,6 +17,8 @@
width="55" width="55"
:selectable="selectableDisabled" :selectable="selectableDisabled"
/> />
<!-- 序号 -->
<el-table-column v-if="props.showTableIndex" :fixed="'left'" type="index" width="50" />
<!-- 左侧操作列 --> <!-- 左侧操作列 -->
<el-table-column <el-table-column
v-if="props.leftOperation && props.leftOperation.length > 0" v-if="props.leftOperation && props.leftOperation.length > 0"
@ -91,9 +94,9 @@
v-else-if="item.type == 'datetimeInput'" v-else-if="item.type == 'datetimeInput'"
v-model="scope.row[item.prop]" v-model="scope.row[item.prop]"
style="width:100%" style="width:100%"
type="datetime" :type="item.inputType || 'datetime'"
format="YYYY-MM-DD HH:mm:ss" :format="item.format || 'YYYY-MM-DD HH:mm:ss'"
value-format="YYYY-MM-DD HH:mm:ss" :value-format="item.valueFormat || 'YYYY-MM-DD HH:mm:ss'"
:clearable="!item.noClear" :clearable="!item.noClear"
:disabled="getEditItemDisabled(item,scope.row,scope)" :disabled="getEditItemDisabled(item,scope.row,scope)"
@focus="(event)=>{editItemFocusHandle(item,scope,event)}" @focus="(event)=>{editItemFocusHandle(item,scope,event)}"
@ -152,6 +155,11 @@
type: Boolean, type: Boolean,
default: false default: false
}, },
//
showTableIndex:{
type: Boolean,
default: false
},
// //
leftOperation:{ leftOperation:{
type: Object, type: Object,
@ -206,7 +214,17 @@
selectableDisabled:{ selectableDisabled:{
type: [Function,Boolean], type: [Function,Boolean],
default: true default: true
} },
// class
tableRowClassName:{
type: Function,
default: null
},
// class
tableCellClassName:{
type: Function,
default: null
},
}) })
const emits = defineEmits([ const emits = defineEmits([
@ -302,5 +320,17 @@
</script> </script>
<style></style> <style scope lang="scss">
.current-select-tableRow{
background:#e1f3d8 !important;
td{
background:#e1f3d8 !important;
}
}
.normal-tableRow{
td{
background:#fff;
}
}
</style>

336
Web/src/components/elTable/index_norule.vue

@ -0,0 +1,336 @@
<template>
<el-table
ref="tableRef"
row-key="id"
:data="props.tableData"
:border="true"
@sort-change="sortChange"
@selection-change="tableSelectionHandle"
:row-class-name="props.tableRowClassName"
:cell-class-name="props.tableCellClassName"
>
<!-- 多选框 -->
<el-table-column
v-if="props.multipleTable"
type="selection"
:fixed="'left'"
width="55"
:selectable="selectableDisabled"
/>
<!-- 序号 -->
<el-table-column v-if="props.showTableIndex" :fixed="'left'" type="index" width="50" />
<!-- 左侧操作列 -->
<el-table-column
v-if="props.leftOperation && props.leftOperation.length > 0"
:fixed="'left'"
:width="props.leftOperationColumnWidth"
label="操作"
:align="'center'">
<template #default="scope">
<el-button
v-for="(btn,index) in props.leftOperation"
:key="index"
:type="btn.type"
:link="btn.link"
@click="leftOperationHadel(btn,scope)"
>{{btn.label}}</el-button>
</template>
</el-table-column>
<!-- 数据列 -->
<el-table-column
v-for="(item, index) in props.tableColumns"
:key="index"
:label="item.title"
:prop="item.prop"
:sortable="item.sortable || 'custom'"
:fixed="item.fixed"
:width="item.width || props.columnWidth"
:align="item.align || props.columnAlign"
:header-align="item.headerAlign || props.columnHeaderAlign">
<template #default="scope">
<!-- 时间格式 -->
<span v-if="item.type == 'datetime'"> {{ formatTableDate(scope.row[item.prop]) }} </span>
<!-- 标签格式 -->
<el-tag
v-else-if="item.type == 'tagFilter'"
:type="formatTableTagFilter('type',scope.row,item)"
>
{{ formatTableTagFilter('label',scope.row,item) }}
</el-tag>
<!-- 字典 -->
<span v-else-if="item.type == 'filter'">{{ formatTableTagFilter('label',scope.row,item) }}</span>
<!-- 可编辑文本 -->
<el-input
v-else-if="item.type == 'input'"
v-model="scope.row[item.prop]"
:placeholder="item.label"
:disabled="getEditItemDisabled(item,scope.row,scope)"
:clearable="!item.noClear"
@focus="(event)=>{editItemFocusHandle(item,scope,event)}"
@change="editItemChangeHandle(item,scope,arguments)"
@clear="editItemClearHandle(item,scope)"
/>
<!-- 可编辑字典选择 -->
<el-select
v-else-if="item.type == 'filterSelect'"
v-model="scope.row[item.prop]"
:filterable="!item.noSearch"
placeholder="请选择"
:disabled="getEditItemDisabled(item,scope.row,scope)"
:clearable="!item.noClear"
@focus="(event)=>{editItemFocusHandle(item,scope,event)}"
@change="editItemChangeHandle(item,scope,arguments)"
@clear="editItemClearHandle(item,scope)">
<el-option
v-for="(op,op_index) in item.options"
:key="op_index"
:label="op.label"
:value="op.value"
/>
</el-select>
<!-- 可编辑时间 -->
<el-date-picker
v-else-if="item.type == 'datetimeInput'"
v-model="scope.row[item.prop]"
style="width:100%"
:type="item.inputType || 'datetime'"
:format="item.format || 'YYYY-MM-DD HH:mm:ss'"
:value-format="item.valueFormat || 'YYYY-MM-DD HH:mm:ss'"
:clearable="!item.noClear"
:disabled="getEditItemDisabled(item,scope.row,scope)"
@focus="(event)=>{editItemFocusHandle(item,scope,event)}"
@change="editItemChangeHandle(item,scope,arguments)"
@clear="editItemClearHandle(item,scope)"
/>
<!-- 可编辑数字 -->
<el-input-number
v-else-if="item.type == 'numberInput'"
v-model="scope.row[item.prop]"
:min="item.min"
:max="item.max"
:disabled="getEditItemDisabled(item,scope.row,scope)"
@focus="(event)=>{editItemFocusHandle(item,scope,event)}"
@change="editItemChangeHandle(item,scope,arguments)"
/>
<!-- 正常直接显示 -->
<span v-else> {{ scope.row[item.prop] }} </span>
</template>
</el-table-column>
<!-- 右侧操作列 -->
<el-table-column
v-if="props.rightOperation && props.rightOperation.length > 0"
v-auth-any="getShowRightOpera()"
:fixed="'right'"
:width="props.rightOperationColumnWidth"
:align="'center'"
label="操作">
<template #default="scope">
<el-button
v-for="(btn,index) in props.rightOperation"
v-show="typeof btn.hide == 'function' ? !btn.hide(scope.row,scope) : !btn.hide"
:key="index"
:type="btn.type"
:link="btn.link"
@click="rightOperationHadel(btn,scope)"
v-auth="btn.auth"
>{{btn.label}}</el-button>
</template>
</el-table-column>
</el-table>
</template>
<script setup>
defineOptions({ name: 'elTable' })
import { reactive, ref, onMounted } from 'vue'
import { ElMessageBox, ElMessage,ElTable, ElTableColumn } from 'element-plus'
import { formatTimeStrToStr } from "@/utils/formatTime";
const state = reactive({})
const props = defineProps({
//
multipleTable:{
type: Boolean,
default: false
},
//
showTableIndex:{
type: Boolean,
default: false
},
//
leftOperation:{
type: Object,
default: null
},
//
leftOperationColumnWidth:{
type: Number,
default: 120
},
//
rightOperation:{
type: Object,
default: null
},
//
rightOperationColumnWidth:{
type: Number,
default: 150
},
// table
tableData: {
type: Object,
default: []
},
// table
tableColumns: {
type: Object,
default: []
},
//
columnWidth:{
type: Number,
default: null
},
//
columnHeaderAlign:{
type: String,
default: 'center'
},
//
columnAlign:{
type: String,
default: 'center'
},
//
getEditItemDisabled:{
type: [Function,Boolean],
default: false
},
// table
selectableDisabled:{
type: [Function,Boolean],
default: true
},
// class
tableRowClassName:{
type: Function,
default: null
},
// class
tableCellClassName:{
type: Function,
default: null
},
})
const emits = defineEmits([
'sortChange',
'leftOperationHadel',
'rightOperationHadel',
'tableSelectionHandle',
'editItemFocusHandle',
'editItemChangeHandle',
'editItemClearHandle',
])
//
function tableSelectionHandle (val){
emits('tableSelectionHandle',val)
}
//
function formatTableDate(time) {
let _time = '-'
if (time) { _time = formatTimeStrToStr(time) }
return _time
}
// TagFilter
function formatTableTagFilter(type,row,item){
let _op = item.options.filter(op=>op.value == row[item.prop])
if(!_op || _op.length <=0 || !_op[0][type]){
if(type=='type'){return 'info'}
else{return '--'}
}else{
return _op[0][type]
}
}
//
function sortChange(data) {
emits('sortChange',data)
}
//
function leftOperationHadel(btn,scope) {
emits('leftOperationHadel',btn,scope)
}
//
function getShowRightOpera(){
let _arr = []
props.rightOperation.forEach(item=>{_arr.push(item.auth)})
return _arr
}
//
function getEditItemDisabled(item,row,scope){
if(typeof props.getEditItemDisabled == 'boolean'){
return props.getEditItemDisabled
}else{
return props.getEditItemDisabled(item,row,scope.$index)
}
}
// table
function selectableDisabled(row,index){
if(typeof props.selectableDisabled == 'function'){
return props.selectableDisabled(row,index)
}else{
return props.selectableDisabled
}
}
// Focus
function editItemFocusHandle(item,scope,event) {
emits('editItemFocusHandle',item,scope,event)
}
// change
function editItemChangeHandle(item,scope,data) {
emits('editItemChangeHandle',item,scope,data)
}
// clear
function editItemClearHandle(item,scope) {
emits('editItemClearHandle',item,scope)
}
//
function rightOperationHadel(btn,scope) {
emits('rightOperationHadel',btn,scope)
}
onMounted(() => {})
</script>
<style scope lang="scss">
.current-select-tableRow{
background:#e1f3d8 !important;
td{
background:#e1f3d8 !important;
}
}
.normal-tableRow{
td{
background:#fff;
}
}
</style>

353
Web/src/components/elTable/index_rulr.vue

@ -0,0 +1,353 @@
<template>
<el-form style="height:calc(100% - 45px)" :model="props" :rules="props.tableFormRules" ref="tableForm_Ref">
<el-table
style="height:100%"
row-key="id"
:data="props.tableData"
:border="true"
@sort-change="sortChange"
@selection-change="tableSelectionHandle"
:row-class-name="props.tableRowClassName"
:cell-class-name="props.tableCellClassName"
>
<!-- 多选框 -->
<el-table-column
v-if="props.multipleTable"
type="selection"
:fixed="'left'"
width="55"
:selectable="selectableDisabled"
/>
<!-- 序号 -->
<el-table-column v-if="props.showTableIndex" :fixed="'left'" type="index" width="50" />
<!-- 左侧操作列 -->
<el-table-column
v-if="props.leftOperation && props.leftOperation.length > 0"
:fixed="'left'"
:width="props.leftOperationColumnWidth"
label="操作"
:align="'center'">
<template #default="scope">
<el-button
v-for="(btn,index) in props.leftOperation"
:key="index"
:type="btn.type"
:link="btn.link"
@click="leftOperationHadel(btn,scope)"
>{{btn.label}}</el-button>
</template>
</el-table-column>
<!-- 数据列 -->
<el-table-column
v-for="(item, index) in props.tableColumns"
:key="index"
:label="item.title"
:prop="item.prop"
:sortable="item.sortable || 'custom'"
:fixed="item.fixed"
:width="item.width || props.columnWidth"
:align="item.align || props.columnAlign"
:header-align="item.headerAlign || props.columnHeaderAlign">
<template #default="scope">
<!-- `tableData[${scope.$index}][${item.prop}]` -->
<el-form-item
:prop="'tableData.'+ scope.$index + '.' + item.prop"
:rules="props.tableFormRules[item.prop]"
>
<!-- 时间格式 -->
<span v-if="item.type == 'datetime'"> {{ formatTableDate(scope.row[item.prop]) }} </span>
<!-- 标签格式 -->
<el-tag
v-else-if="item.type == 'tagFilter'"
:type="formatTableTagFilter('type',scope.row,item)"
>
{{ formatTableTagFilter('label',scope.row,item) }}
</el-tag>
<!-- 字典 -->
<span v-else-if="item.type == 'filter'">{{ formatTableTagFilter('label',scope.row,item) }}</span>
<!-- 可编辑文本 -->
<el-input
v-else-if="item.type == 'input'"
v-model="scope.row[item.prop]"
:placeholder="item.label"
:disabled="getEditItemDisabled(item,scope.row,scope)"
:clearable="!item.noClear"
@focus="(event)=>{editItemFocusHandle(item,scope,event)}"
@change="editItemChangeHandle(item,scope,arguments)"
@clear="editItemClearHandle(item,scope)"
/>
<!-- 可编辑字典选择 -->
<el-select
v-else-if="item.type == 'filterSelect'"
v-model="scope.row[item.prop]"
:filterable="!item.noSearch"
placeholder="请选择"
:disabled="getEditItemDisabled(item,scope.row,scope)"
:clearable="!item.noClear"
@focus="(event)=>{editItemFocusHandle(item,scope,event)}"
@change="editItemChangeHandle(item,scope,arguments)"
@clear="editItemClearHandle(item,scope)">
<el-option
v-for="(op,op_index) in item.options"
:key="op_index"
:label="op.label"
:value="op.value"
/>
</el-select>
<!-- 可编辑时间 -->
<el-date-picker
v-else-if="item.type == 'datetimeInput'"
v-model="scope.row[item.prop]"
style="width:100%"
:type="item.inputType || 'datetime'"
:format="item.format || 'YYYY-MM-DD HH:mm:ss'"
:value-format="item.valueFormat || 'YYYY-MM-DD HH:mm:ss'"
:clearable="!item.noClear"
:disabled="getEditItemDisabled(item,scope.row,scope)"
@focus="(event)=>{editItemFocusHandle(item,scope,event)}"
@change="editItemChangeHandle(item,scope,arguments)"
@clear="editItemClearHandle(item,scope)"
/>
<!-- 可编辑数字 -->
<el-input-number
v-else-if="item.type == 'numberInput'"
v-model="scope.row[item.prop]"
:min="item.min"
:max="item.max"
:disabled="getEditItemDisabled(item,scope.row,scope)"
@focus="(event)=>{editItemFocusHandle(item,scope,event)}"
@change="editItemChangeHandle(item,scope,arguments)"
/>
<!-- 正常直接显示 -->
<span v-else> {{ scope.row[item.prop] }} </span>
</el-form-item>
</template>
</el-table-column>
<!-- 右侧操作列 -->
<el-table-column
v-if="props.rightOperation && props.rightOperation.length > 0"
v-auth-any="getShowRightOpera()"
:fixed="'right'"
:width="props.rightOperationColumnWidth"
:align="'center'"
label="操作">
<template #default="scope">
<el-button
v-for="(btn,index) in props.rightOperation"
v-show="typeof btn.hide == 'function' ? !btn.hide(scope.row,scope) : !btn.hide"
:key="index"
:type="btn.type"
:link="btn.link"
@click="rightOperationHadel(btn,scope)"
v-auth="btn.auth"
>{{btn.label}}</el-button>
</template>
</el-table-column>
</el-table>
</el-form>
</template>
<script setup>
defineOptions({ name: 'elTable' })
import { reactive, ref, onMounted,defineExpose } from 'vue'
import { ElMessageBox, ElMessage,ElTable, ElTableColumn } from 'element-plus'
import { formatTimeStrToStr } from "@/utils/formatTime";
const state = reactive({})
const props = defineProps({
//
multipleTable:{
type: Boolean,
default: false
},
//
showTableIndex:{
type: Boolean,
default: false
},
//
leftOperation:{
type: Object,
default: null
},
//
leftOperationColumnWidth:{
type: Number,
default: 120
},
//
rightOperation:{
type: Object,
default: null
},
//
rightOperationColumnWidth:{
type: Number,
default: 150
},
// table
tableData: {
type: Object,
default: []
},
// table
tableColumns: {
type: Object,
default: []
},
//
columnWidth:{
type: Number,
default: null
},
//
columnHeaderAlign:{
type: String,
default: 'center'
},
//
columnAlign:{
type: String,
default: 'center'
},
// tablerules
tableFormRules: {
type: Object,
default: null
},
//
getEditItemDisabled:{
type: [Function,Boolean],
default: false
},
// table
selectableDisabled:{
type: [Function,Boolean],
default: true
},
// class
tableRowClassName:{
type: Function,
default: null
},
// class
tableCellClassName:{
type: Function,
default: null
},
})
const emits = defineEmits([
'sortChange',
'leftOperationHadel',
'rightOperationHadel',
'tableSelectionHandle',
'editItemFocusHandle',
'editItemChangeHandle',
'editItemClearHandle',
])
//
function tableSelectionHandle (val){
emits('tableSelectionHandle',val)
}
//
function formatTableDate(time) {
let _time = '-'
if (time) { _time = formatTimeStrToStr(time) }
return _time
}
// TagFilter
function formatTableTagFilter(type,row,item){
let _op = item.options.filter(op=>op.value == row[item.prop])
if(!_op || _op.length <=0 || !_op[0][type]){
if(type=='type'){return 'info'}
else{return '--'}
}else{
return _op[0][type]
}
}
//
function sortChange(data) {
emits('sortChange',data)
}
//
function leftOperationHadel(btn,scope) {
emits('leftOperationHadel',btn,scope)
}
//
function getShowRightOpera(){
let _arr = []
props.rightOperation.forEach(item=>{_arr.push(item.auth)})
return _arr
}
//
function getEditItemDisabled(item,row,scope){
if(typeof props.getEditItemDisabled == 'boolean'){
return props.getEditItemDisabled
}else{
return props.getEditItemDisabled(item,row,scope.$index)
}
}
// table
function selectableDisabled(row,index){
if(typeof props.selectableDisabled == 'function'){
return props.selectableDisabled(row,index)
}else{
return props.selectableDisabled
}
}
// Focus
function editItemFocusHandle(item,scope,event) {
emits('editItemFocusHandle',item,scope,event)
}
// change
function editItemChangeHandle(item,scope,data) {
emits('editItemChangeHandle',item,scope,data)
}
// clear
function editItemClearHandle(item,scope) {
emits('editItemClearHandle',item,scope)
}
//
function rightOperationHadel(btn,scope) {
emits('rightOperationHadel',btn,scope)
}
const tableForm_Ref = ref(null)
defineExpose({
tableForm_Ref,
});
onMounted(() => {})
</script>
<style scope lang="scss">
.current-select-tableRow{
background:#e1f3d8 !important;
td{
background:#e1f3d8 !important;
}
}
.normal-tableRow{
td{
background:#fff;
}
}
</style>

10
Web/src/components/tablePage/index.vue

@ -106,7 +106,7 @@
defineOptions({ name: 'tablePage' }) defineOptions({ name: 'tablePage' })
import store from '@/stores' import store from '@/stores'
import apiTableColumns from '@/utils/common/apiTableColumns' import apiTableColumns from '@/utils/common/apiTableColumns'
import { reactive, ref, onMounted,computed } from 'vue' import { reactive, ref, onMounted,computed,defineExpose } from 'vue'
import { import {
getCommonPaged, getCommonPaged,
getCommonDeatailPaged, getCommonDeatailPaged,
@ -323,7 +323,6 @@
ElMessage.success('操作成功!') ElMessage.success('操作成功!')
getTableData(1); getTableData(1);
}) })
.catch(err=>{ElMessage.error('操作失败!')})
.finally(()=>{state.loading = false}) .finally(()=>{state.loading = false})
}) })
} }
@ -381,10 +380,12 @@
// //
function getPageParams(){ function getPageParams(){
let _filters = [] let _filters = []
console.log(383,props.searchFilter)
if(props.hideSearch){ if(props.hideSearch){
_filters = props.searchFilter _filters = props.searchFilter
}else{ }else{
for(let i in props.searchFilter){ for(let i in props.searchFilter){
console.log(388,i)
let _item = props.searchOptions.filter(item=>item.prop == i) let _item = props.searchOptions.filter(item=>item.prop == i)
let _type = (_item && _item.length > 0) ? _item[0].type : null let _type = (_item && _item.length > 0) ? _item[0].type : null
if(props.searchFilter[i] || props.searchFilter[i] == 0){ if(props.searchFilter[i] || props.searchFilter[i] == 0){
@ -566,4 +567,9 @@
onMounted(() => { onMounted(() => {
getTableData() getTableData()
}) })
defineExpose({
state,
getTableData
});
</script> </script>

2
Web/src/layout/components/Sidebar/index.vue

@ -113,7 +113,7 @@ div.el-scrollbar__view {
} }
.aside-container:not(.collapsed) { .aside-container:not(.collapsed) {
width: 210px; /* 默认宽度 */ width: 260px; /* 默认宽度 */
} }
.el-menu{ .el-menu{

2
Web/src/styles/variables.module.scss

@ -15,7 +15,7 @@ $menuHover_dark: #1e1e1e;
$subMenuBg_dark: #3c3c3c; $subMenuBg_dark: #3c3c3c;
$subMenuHover_dark: #1e1e1e; $subMenuHover_dark: #1e1e1e;
$sideBarWidth: 210px; $sideBarWidth: 260px;
// the :export directive is the magic sauce for webpack // the :export directive is the magic sauce for webpack
// https://www.bluematador.com/blog/how-to-share-variables-between-js-and-sass // https://www.bluematador.com/blog/how-to-share-variables-between-js-and-sass

70
Web/src/utils/common/apiTableColumns.js

@ -10,7 +10,7 @@ const apiTableColumns = {
{prop:'corn',title:'corn'}, {prop:'corn',title:'corn'},
{prop:'writeState',title:'writeState',type:'tagFilter',options:EnumList.whetherBoolean}, {prop:'writeState',title:'writeState',type:'tagFilter',options:EnumList.whetherBoolean},
{prop:'readState',title:'readState',type:'tagFilter',options:EnumList.whetherBoolean}, {prop:'readState',title:'readState',type:'tagFilter',options:EnumList.whetherBoolean},
{prop:'isAuto',title:'isAuto',type:'tagFilter',options:EnumList.whetherBoolean}, {prop:'isAuto',title:'是否自动执行',type:'tagFilter',options:EnumList.whetherBoolean},
{prop:'remark',title:'remark',align:'left',width:300}, {prop:'remark',title:'remark',align:'left',width:300},
{prop:'creationTime',title:'创建时间',width:180,type:'datetime',noEdit:true}, {prop:'creationTime',title:'创建时间',width:180,type:'datetime',noEdit:true},
{prop:'module',title:'module'}, {prop:'module',title:'module'},
@ -57,7 +57,7 @@ const apiTableColumns = {
{prop:'quantity6',title:'数量6'}, {prop:'quantity6',title:'数量6'},
{prop:'plant',title:'工厂'}, {prop:'plant',title:'工厂'},
{prop:'createByUser',title:'创建人'}, {prop:'createByUser',title:'创建人'},
{prop:'createTime',title:'创建时间',width:180}, {prop:'creationTime',title:'创建时间',width:180},
{prop:'updateByUser',title:'修改人'}, {prop:'updateByUser',title:'修改人'},
{prop:'updateTime',title:'修改时间',width:180}, {prop:'updateTime',title:'修改时间',width:180},
{prop:'isDelete',title:'是否删除',type:'tagFilter',options:EnumList.whether}, {prop:'isDelete',title:'是否删除',type:'tagFilter',options:EnumList.whether},
@ -85,7 +85,7 @@ const apiTableColumns = {
{prop:'quantityDemand12',title:'需求数量12',width:130}, {prop:'quantityDemand12',title:'需求数量12',width:130},
{prop:'isUpdate',title:'是否更新',type:'tagFilter',options:EnumList.whether}, {prop:'isUpdate',title:'是否更新',type:'tagFilter',options:EnumList.whether},
{prop:'createByUser',title:'创建人'}, {prop:'createByUser',title:'创建人'},
{prop:'createTime',title:'创建时间',width:180}, {prop:'creationTime',title:'创建时间',width:180},
{prop:'updateByUser',title:'修改人'}, {prop:'updateByUser',title:'修改人'},
{prop:'updateTime',title:'修改时间',width:180}, {prop:'updateTime',title:'修改时间',width:180},
{prop:'isDelete',title:'是否删除',type:'tagFilter',options:EnumList.whether}, {prop:'isDelete',title:'是否删除',type:'tagFilter',options:EnumList.whether},
@ -93,17 +93,14 @@ const apiTableColumns = {
], ],
// M+6月物料需求计划风险确认 // M+6月物料需求计划风险确认
cherysupplierconmmrp:[ cherysupplierconmmrp:[
{prop:'supplierCode',title:'供应商代码',type:'input',required:true}, {prop:'supplierCode',title:'供应商代码',width:150,align:'left'},
{prop:'releaseEdition',title:'需求发布版次',width:150,type:'input',required:true}, {prop:'releaseEdition',title:'需求发布版次',width:150},
{prop:'materialCode',title:'零件号',type:'input',required:true}, {prop:'materialCode',title:'零件号'},
{prop:'plantId',title:'工厂代码',type:'input',required:true}, {prop:'plantId',title:'工厂代码',width:120},
{prop:'feedbackResults',title:'反馈结果',type:'filterSelect',options:EnumList.feedbackResults,required:true}, {prop:'feedbackResults',title:'反馈结果',type:'filterSelect',options:EnumList.feedbackResults,required:true},
// todo:当反馈结果=1时,此字段必输
{prop:'ventureType',title:'风险类型',type:'filterSelect',options:EnumList.ventureType}, {prop:'ventureType',title:'风险类型',type:'filterSelect',options:EnumList.ventureType},
// todo:当反馈结果=1时,此字段必输
{prop:'ventureSpecific',title:'具体风险',type:'input'}, {prop:'ventureSpecific',title:'具体风险',type:'input'},
{prop:'measures',title:'应对措施',type:'input'}, {prop:'measures',title:'应对措施',type:'input'},
{prop:'startMonth',title:'起始月份',type:'datetimeInput',required:true},
{prop:'quantityMeet1',title:'满足数量1',type:'numberInput',required:true}, {prop:'quantityMeet1',title:'满足数量1',type:'numberInput',required:true},
{prop:'quantityMeet2',title:'满足数量2',type:'numberInput',required:true}, {prop:'quantityMeet2',title:'满足数量2',type:'numberInput',required:true},
{prop:'quantityMeet3',title:'满足数量3',type:'numberInput',required:true}, {prop:'quantityMeet3',title:'满足数量3',type:'numberInput',required:true},
@ -116,6 +113,8 @@ const apiTableColumns = {
{prop:'quantityMeet10',title:'满足数量10',type:'numberInput'}, {prop:'quantityMeet10',title:'满足数量10',type:'numberInput'},
{prop:'quantityMeet11',title:'满足数量11',type:'numberInput'}, {prop:'quantityMeet11',title:'满足数量11',type:'numberInput'},
{prop:'quantityMeet12',title:'满足数量12',type:'numberInput'}, {prop:'quantityMeet12',title:'满足数量12',type:'numberInput'},
{prop:'startMonth',title:'起始月份'},
{prop:'creationTime',title:'创建时间',width:180},
], ],
// M+6月物料需求计划风险确认-明细 // M+6月物料需求计划风险确认-明细
cherysupplierconmmrpDetail:[ cherysupplierconmmrpDetail:[
@ -191,7 +190,7 @@ const apiTableColumns = {
{prop:'quantityDemand31',title:'需求数量31',width:130}, {prop:'quantityDemand31',title:'需求数量31',width:130},
{prop:'is_update',title:'是否更新',type:'tagFilter',options:EnumList.whether}, {prop:'is_update',title:'是否更新',type:'tagFilter',options:EnumList.whether},
{prop:'createByUser',title:'创建人'}, {prop:'createByUser',title:'创建人'},
{prop:'createTime',title:'创建时间',width:180}, {prop:'creationTime',title:'创建时间',width:180},
{prop:'updateByUser',title:'修改人'}, {prop:'updateByUser',title:'修改人'},
{prop:'updateTime',title:'修改时间',width:180}, {prop:'updateTime',title:'修改时间',width:180},
{prop:'isDelete',title:'是否删除',type:'tagFilter',options:EnumList.whether}, {prop:'isDelete',title:'是否删除',type:'tagFilter',options:EnumList.whether},
@ -208,7 +207,7 @@ const apiTableColumns = {
{prop:'quantityDemand',title:'需求数量'}, {prop:'quantityDemand',title:'需求数量'},
{prop:'dateReceived',title:'交货日期',width:180}, {prop:'dateReceived',title:'交货日期',width:180},
{prop:'createByUser',title:'创建人'}, {prop:'createByUser',title:'创建人'},
{prop:'createTime',title:'创建时间',width:180}, {prop:'creationTime',title:'创建时间',width:180},
{prop:'updateByUser',title:'修改人'}, {prop:'updateByUser',title:'修改人'},
{prop:'updateTime',title:'修改时间',width:180}, {prop:'updateTime',title:'修改时间',width:180},
{prop:'isDelete',title:'是否删除',type:'tagFilter',options:EnumList.whether}, {prop:'isDelete',title:'是否删除',type:'tagFilter',options:EnumList.whether},
@ -219,29 +218,41 @@ const apiTableColumns = {
{prop:'purchaseOrder',title:'采购订单号',width:120}, {prop:'purchaseOrder',title:'采购订单号',width:120},
{prop:'serialNumber',title:'行项目号'}, {prop:'serialNumber',title:'行项目号'},
{prop:'plantId',title:'工厂代码'}, {prop:'plantId',title:'工厂代码'},
{prop:'plantName',title:'工厂名称'}, {prop:'plantName',title:'工厂名称',width:160},
{prop:'voucherDate',title:'凭证日期',width:180}, {prop:'voucherDate',title:'凭证日期',width:180},
{prop:'purchaser',title:'需方联系人'}, {prop:'purchaser',title:'需方联系人'},
{prop:'supplier',title:'供方联系人'}, {prop:'supplier',title:'供方联系人'},
{prop:'materialCode',title:'物料编码'}, {prop:'materialCode',title:'物料编码',width:180},
{prop:'materialDescription',title:'物料描述'}, {prop:'materialDescription',title:'物料描述',width:180},
{prop:'quantityDemand',title:'需求数量'}, {prop:'quantityDemand',title:'需求数量'},
{prop:'materialUnit',title:'物料单位'}, {prop:'materialUnit',title:'物料单位'},
{prop:'deliveryDate',title:'交货日期',width:180}, {prop:'deliveryDate',title:'交货日期',width:180},
{prop:'deliveryPlace',title:'交货地点'}, {prop:'deliveryPlace',title:'交货地点'},
{prop:'quantityDelivery',title:'到货数量'}, {prop:'quantityDelivery',title:'到货数量'},
{prop:'note',title:'备注'}, {prop:'note',title:'备注',width:200},
{prop:'itemType',title:'项目类别文本',width:150}, {prop:'itemType',title:'项目类别文本',width:150},
{prop:'tradeTerms',title:'国际贸易条件',width:150}, {prop:'tradeTerms',title:'国际贸易条件',width:150},
{prop:'country',title:'出口国家'}, {prop:'country',title:'出口国家'},
{prop:'batch',title:'批次'}, {prop:'batch',title:'批次'},
{prop:'createByUser',title:'创建人'}, {prop:'createByUser',title:'创建人'},
{prop:'createTime',title:'创建时间',width:180}, {prop:'creationTime',title:'创建时间',width:180},
{prop:'updateByUser',title:'修改人'}, {prop:'updateByUser',title:'修改人'},
{prop:'updateTime',title:'修改时间',width:180}, {prop:'updateTime',title:'修改时间',width:180},
{prop:'isDelete',title:'是否删除',type:'tagFilter',options:EnumList.whether}, {prop:'isDelete',title:'是否删除',type:'tagFilter',options:EnumList.whether},
{prop:'version',title:'版本号'}, {prop:'version',title:'版本号'},
], ],
// 采购订单风险确认
cherysupplierconpo:[
{prop:'supplierCode',title:'供应商代码'},
{prop:'purchaseOrder',title:'采购订单号',type:'input',required:true,width:120},
{prop:'serialNumber',title:'行项目号',type:'input',required:true},
{prop:'quantityMeet',title:'满足数量',type:'numberInput',required:true},
{prop:'feedbackResults',title:'反馈结果',type:'filterSelect',options:EnumList.feedbackResults,required:true},
{prop:'ventureType',title:'风险类型',type:'filterSelect',options:EnumList.ventureType},
{prop:'ventureSpecific',title:'具体风险',type:'input'},
{prop:'measures',title:'应对措施',type:'input'},
{prop:'creationTime',title:'创建时间',width:180},
],
// 过焊装未过总装 // 过焊装未过总装
cherysupplierporhschedul:[ cherysupplierporhschedul:[
{prop:'models',title:'车型'}, {prop:'models',title:'车型'},
@ -253,7 +264,7 @@ const apiTableColumns = {
{prop:'productionType',title:'报工类型'}, {prop:'productionType',title:'报工类型'},
{prop:'onLineTime',title:'上线日期时间',width:180}, {prop:'onLineTime',title:'上线日期时间',width:180},
{prop:'createByUser',title:'创建人'}, {prop:'createByUser',title:'创建人'},
{prop:'createTime',title:'创建时间',width:180}, {prop:'creationTime',title:'创建时间',width:180},
{prop:'updateByUser',title:'修改人'}, {prop:'updateByUser',title:'修改人'},
{prop:'updateTime',title:'修改时间',width:180}, {prop:'updateTime',title:'修改时间',width:180},
{prop:'isDelete',title:'是否删除',type:'tagFilter',options:EnumList.whether}, {prop:'isDelete',title:'是否删除',type:'tagFilter',options:EnumList.whether},
@ -271,7 +282,7 @@ const apiTableColumns = {
{prop:'finalWorkshop',title:'总装车间'}, {prop:'finalWorkshop',title:'总装车间'},
{prop:'finalOnLineTime',title:'总装上线日期时间',width:180}, {prop:'finalOnLineTime',title:'总装上线日期时间',width:180},
{prop:'createByUser',title:'创建人'}, {prop:'createByUser',title:'创建人'},
{prop:'createTime',title:'创建时间',width:180}, {prop:'creationTime',title:'创建时间',width:180},
{prop:'updateByUser',title:'修改人'}, {prop:'updateByUser',title:'修改人'},
{prop:'updateTime',title:'修改时间',width:180}, {prop:'updateTime',title:'修改时间',width:180},
{prop:'isDelete',title:'是否删除',type:'tagFilter',options:EnumList.whether}, {prop:'isDelete',title:'是否删除',type:'tagFilter',options:EnumList.whether},
@ -295,7 +306,7 @@ const apiTableColumns = {
{prop:'judge',title:'判定人'}, {prop:'judge',title:'判定人'},
{prop:'returnReason',title:'退货原因'}, {prop:'returnReason',title:'退货原因'},
{prop:'createByUser',title:'创建人'}, {prop:'createByUser',title:'创建人'},
{prop:'createTime',title:'创建时间',width:180}, {prop:'creationTime',title:'创建时间',width:180},
{prop:'updateByUser',title:'修改人'}, {prop:'updateByUser',title:'修改人'},
{prop:'updateTime',title:'修改时间',width:180}, {prop:'updateTime',title:'修改时间',width:180},
{prop:'isDelete',title:'是否删除',type:'tagFilter',options:EnumList.whether}, {prop:'isDelete',title:'是否删除',type:'tagFilter',options:EnumList.whether},
@ -311,7 +322,7 @@ const apiTableColumns = {
{prop:'stockState',title:'库存状态'}, {prop:'stockState',title:'库存状态'},
{prop:'dataUpdateTime',title:'更新时间',width:180}, {prop:'dataUpdateTime',title:'更新时间',width:180},
{prop:'createByUser',title:'创建人'}, {prop:'createByUser',title:'创建人'},
{prop:'createTime',title:'创建时间',width:180}, {prop:'creationTime',title:'创建时间',width:180},
{prop:'updateByUser',title:'修改人'}, {prop:'updateByUser',title:'修改人'},
{prop:'updateTime',title:'修改时间',width:180}, {prop:'updateTime',title:'修改时间',width:180},
{prop:'isDelete',title:'是否删除',type:'tagFilter',options:EnumList.whether}, {prop:'isDelete',title:'是否删除',type:'tagFilter',options:EnumList.whether},
@ -357,7 +368,7 @@ const apiTableColumns = {
{prop:'summaryQuantityReceive',title:'集货件已收货数量'}, {prop:'summaryQuantityReceive',title:'集货件已收货数量'},
{prop:'summaryQuantityInTransit',title:'集货件已在途数量'}, {prop:'summaryQuantityInTransit',title:'集货件已在途数量'},
{prop:'createByUser',title:'创建人'}, {prop:'createByUser',title:'创建人'},
{prop:'createTime',title:'创建时间',width:180}, {prop:'creationTime',title:'创建时间',width:180},
{prop:'updateByUser',title:'修改人'}, {prop:'updateByUser',title:'修改人'},
{prop:'updateTime',title:'修改时间',width:180}, {prop:'updateTime',title:'修改时间',width:180},
{prop:'isDelete',title:'是否删除',type:'tagFilter',options:EnumList.whether}, {prop:'isDelete',title:'是否删除',type:'tagFilter',options:EnumList.whether},
@ -377,7 +388,7 @@ const apiTableColumns = {
{prop:'inventoryGap',title:'库存GAP'}, {prop:'inventoryGap',title:'库存GAP'},
{prop:'inventoryGap',title:'库存GAP'}, {prop:'inventoryGap',title:'库存GAP'},
{prop:'createByUser',title:'创建人'}, {prop:'createByUser',title:'创建人'},
{prop:'createTime',title:'创建时间',width:180}, {prop:'creationTime',title:'创建时间',width:180},
{prop:'updateByUser',title:'修改人'}, {prop:'updateByUser',title:'修改人'},
{prop:'updateTime',title:'修改时间',width:180}, {prop:'updateTime',title:'修改时间',width:180},
{prop:'isDelete',title:'是否删除',type:'tagFilter',options:EnumList.whether}, {prop:'isDelete',title:'是否删除',type:'tagFilter',options:EnumList.whether},
@ -417,6 +428,7 @@ const apiTableColumns = {
{prop:'vendorFieldDesc',title:'控制项描述'}, {prop:'vendorFieldDesc',title:'控制项描述'},
{prop:'vendorFieldCode',title:'控制项代码',required:true}, {prop:'vendorFieldCode',title:'控制项代码',required:true},
{prop:'deadLine',title:'库存有效日期',type:'datetime',width:180,required:true}, {prop:'deadLine',title:'库存有效日期',type:'datetime',width:180,required:true},
{prop:'creationTime',title:'创建时间',width:180},
], ],
// 排产数据 // 排产数据
cherysupplierproscheduling:[ cherysupplierproscheduling:[
@ -439,6 +451,7 @@ const apiTableColumns = {
{prop:'planEndTime',title:'计划结束时间',width:180}, {prop:'planEndTime',title:'计划结束时间',width:180},
{prop:'actualBeginTime',title:'实际开始时间',width:180}, {prop:'actualBeginTime',title:'实际开始时间',width:180},
{prop:'actualEndTime',title:'实际结束时间',width:180}, {prop:'actualEndTime',title:'实际结束时间',width:180},
{prop:'creationTime',title:'创建时间',width:180},
], ],
// 供应商基础信息 // 供应商基础信息
cherysupplierinfo:[ cherysupplierinfo:[
@ -460,6 +473,7 @@ const apiTableColumns = {
{prop:'vendorProductName',title:'供应商总成零件名称',width:180,required:true}, {prop:'vendorProductName',title:'供应商总成零件名称',width:180,required:true},
{prop:'cheryProductNo',title:'奇瑞零件号',required:true}, {prop:'cheryProductNo',title:'奇瑞零件号',required:true},
{prop:'cheryProductName',title:'奇瑞零件名称',width:180,required:true}, {prop:'cheryProductName',title:'奇瑞零件名称',width:180,required:true},
{prop:'creationTime',title:'创建时间',width:180},
], ],
// 人员资质信息 // 人员资质信息
cherysupplieremployee:[ cherysupplieremployee:[
@ -482,6 +496,7 @@ const apiTableColumns = {
{prop:'qualificationLevel',title:'资质等级',required:true}, {prop:'qualificationLevel',title:'资质等级',required:true},
{prop:'checkInTime',title:'资质获取时间',width:180,type:'datetime',required:true}, {prop:'checkInTime',title:'资质获取时间',width:180,type:'datetime',required:true},
{prop:'checkOutTime',title:'资质失去时间',width:180,type:'datetime',required:true}, {prop:'checkOutTime',title:'资质失去时间',width:180,type:'datetime',required:true},
{prop:'creationTime',title:'创建时间',width:180},
], ],
// BOM主数据 // BOM主数据
cherysupplierbom:[ cherysupplierbom:[
@ -502,6 +517,7 @@ const apiTableColumns = {
{prop:'subMaterialUnit',title:'子件单位'}, {prop:'subMaterialUnit',title:'子件单位'},
{prop:'subMaterialQuota',title:'子件用量',type:'number'}, {prop:'subMaterialQuota',title:'子件用量',type:'number'},
{prop:'dataUpdateTime',title:'BOM变更时间',width:180,type:'datetime'}, {prop:'dataUpdateTime',title:'BOM变更时间',width:180,type:'datetime'},
{prop:'creationTime',title:'创建时间',width:180},
], ],
// 过程控制项质量数据 // 过程控制项质量数据
cherysupplierprocps:[ cherysupplierprocps:[
@ -553,6 +569,7 @@ const apiTableColumns = {
{prop:'checkMode',title:'检测方式',type:'filter',options:EnumList.checkMode,required:true}, {prop:'checkMode',title:'检测方式',type:'filter',options:EnumList.checkMode,required:true},
{prop:'deviceCode',title:'检测设备编号',required:true}, {prop:'deviceCode',title:'检测设备编号',required:true},
{prop:'deviceName',title:'检测设备名称',required:true}, {prop:'deviceName',title:'检测设备名称',required:true},
{prop:'creationTime',title:'创建时间',width:180},
], ],
// 生产过程数据 // 生产过程数据
cherysupplierprodata:[ cherysupplierprodata:[
@ -600,6 +617,7 @@ const apiTableColumns = {
{prop:'parentSoftwareRevision',title:'父件软件版本号',width:180}, {prop:'parentSoftwareRevision',title:'父件软件版本号',width:180},
{prop:'childHardwareRevision',title:'子件硬件版本号',width:180}, {prop:'childHardwareRevision',title:'子件硬件版本号',width:180},
{prop:'childSoftwareRevision',title:'子件软件版本号',width:180}, {prop:'childSoftwareRevision',title:'子件软件版本号',width:180},
{prop:'creationTime',title:'创建时间',width:180},
], ],
// 产品一次合格率 // 产品一次合格率
cherysupplierprofirstpassyield:[ cherysupplierprofirstpassyield:[
@ -625,6 +643,7 @@ const apiTableColumns = {
{prop:'workShift',title:'班次',type:'filter',options:EnumList.workShift,required:true}, {prop:'workShift',title:'班次',type:'filter',options:EnumList.workShift,required:true},
{prop:'statisticalTime',title:'生产日期',width:180,type:'datetime',required:true}, {prop:'statisticalTime',title:'生产日期',width:180,type:'datetime',required:true},
{prop:'dateTime',title:'值统计时间',width:180,type:'datetime',required:true}, {prop:'dateTime',title:'值统计时间',width:180,type:'datetime',required:true},
{prop:'creationTime',title:'创建时间',width:180},
], ],
// 工位一次合格率 // 工位一次合格率
cherysupplierprostationfirstpassyield:[ cherysupplierprostationfirstpassyield:[
@ -652,6 +671,7 @@ const apiTableColumns = {
{prop:'workShift',title:'班次',type:'filter',options:EnumList.workShift,required:true}, {prop:'workShift',title:'班次',type:'filter',options:EnumList.workShift,required:true},
{prop:'statisticalTime',title:'生产日期',width:180,type:'datetime',required:true}, {prop:'statisticalTime',title:'生产日期',width:180,type:'datetime',required:true},
{prop:'dateTime',title:'值统计时间',width:180,type:'datetime',required:true}, {prop:'dateTime',title:'值统计时间',width:180,type:'datetime',required:true},
{prop:'creationTime',title:'创建时间',width:180},
], ],
// 缺陷业务数据 // 缺陷业务数据
cherysupplierproflaw:[ cherysupplierproflaw:[
@ -682,6 +702,7 @@ const apiTableColumns = {
{prop:'defectsDesc',title:'缺陷描述',required:true}, {prop:'defectsDesc',title:'缺陷描述',required:true},
{prop:'defectsLevel',title:'缺陷等级',type:'filter',options:EnumList.defectsLevel,required:true}, {prop:'defectsLevel',title:'缺陷等级',type:'filter',options:EnumList.defectsLevel,required:true},
{prop:'statisticalTime',title:'缺陷录入时间',width:180,type:'datetime',required:true}, {prop:'statisticalTime',title:'缺陷录入时间',width:180,type:'datetime',required:true},
{prop:'creationTime',title:'创建时间',width:180},
], ],
// 物料主数据 // 物料主数据
cherysupplierpromaterialdata:[ cherysupplierpromaterialdata:[
@ -705,6 +726,7 @@ const apiTableColumns = {
{prop:'mpnCode',title:'芯片MPN标识码',width:180}, {prop:'mpnCode',title:'芯片MPN标识码',width:180},
{prop:'mpnName',title:'芯片MPN标识名称',width:180}, {prop:'mpnName',title:'芯片MPN标识名称',width:180},
{prop:'validDays',title:'物料有效期(天)',width:180}, {prop:'validDays',title:'物料有效期(天)',width:180},
{prop:'creationTime',title:'创建时间',width:180},
], ],
// 附件类数据 // 附件类数据
cherysupplierproattachmentdata:[ cherysupplierproattachmentdata:[
@ -725,6 +747,7 @@ const apiTableColumns = {
{prop:'cheryProductNo',title:'奇瑞零件号',required:true}, {prop:'cheryProductNo',title:'奇瑞零件号',required:true},
{prop:'cheryProductName',title:'奇瑞零件名称',width:180,required:true}, {prop:'cheryProductName',title:'奇瑞零件名称',width:180,required:true},
{prop:'vendorProductSn',title:'供应商总成SN码',width:180}, {prop:'vendorProductSn',title:'供应商总成SN码',width:180},
{prop:'creationTime',title:'创建时间',width:180},
], ],
// 工艺装备 // 工艺装备
cherysupplierproprocessequipment:[ cherysupplierproprocessequipment:[
@ -758,6 +781,7 @@ const apiTableColumns = {
{prop:'wearThreshold',title:'磨损阈值',required:true}, {prop:'wearThreshold',title:'磨损阈值',required:true},
{prop:'detectionRange',title:'检测范围',required:true}, {prop:'detectionRange',title:'检测范围',required:true},
{prop:'unitType',title:'检测单位',required:true}, {prop:'unitType',title:'检测单位',required:true},
{prop:'creationTime',title:'创建时间',width:180},
], ],
// 工艺 // 工艺
cherysupplierproprocess:[ cherysupplierproprocess:[

14
Web/src/utils/common/enumList.js

@ -44,16 +44,16 @@ const EnumList = {
], ],
// 反馈结果 // 反馈结果
feedbackResults:[ feedbackResults:[
{label:'异常',value:1}, {label:'异常',value:'1'},
{label:'无异常',value:0}, {label:'无异常',value:'0'},
], ],
// 风险类型 // 风险类型
ventureType:[ ventureType:[
{label:'生产节拍不足',value:1}, {label:'生产节拍不足',value:'1'},
{label:'人员不足',value:2}, {label:'人员不足',value:'2'},
{label:'原材料不足',value:3}, {label:'原材料不足',value:'3'},
{label:'设备异常',value:4}, {label:'设备异常',value:'4'},
{label:'其他',value:5}, {label:'其他',value:'5'},
], ],
// 批次的最终判定结果 // 批次的最终判定结果
checkResult:[ checkResult:[

4
Web/src/utils/request.js

@ -63,11 +63,11 @@ service.interceptors.response.use(
if (res.code != 1 && res.code != 200) { if (res.code != 1 && res.code != 200) {
//报错 //报错
ElMessage({ ElMessage({
message: res.message || 'Error', message: res.message || res.Message || 'Error',
type: 'error', type: 'error',
duration: 5 * 1000 duration: 5 * 1000
}) })
return Promise.reject(new Error(res.message || 'Error')) return Promise.reject(new Error(res.message || res.Message || 'Error'))
} else { } else {
return res return res
} }

14
Web/src/views/logisticsPlan/supplierConMmrp/index.vue

@ -7,7 +7,7 @@
:rightOperation="state.rightOperation" :rightOperation="state.rightOperation"
:detailColumName="'cherysupplierconmmrpDetail'" :detailColumName="'cherysupplierconmmrpDetail'"
:searchButtons="['search','export','outputMany']" :searchButtons="['search','export','outputMany']"
:multipleTable="true" :multipleTable="state.auths.hasPermission(state.apiName+':outputMany')"
></ediTtablePage> ></ediTtablePage>
</template> </template>
@ -15,16 +15,24 @@
<script setup> <script setup>
// M+6 // M+6
defineOptions({ name: 'supplierConMmrp' }) defineOptions({ name: 'supplierConMmrp' })
import store from '@/stores'
import { reactive, ref, onMounted } from 'vue' import { reactive, ref, onMounted } from 'vue'
import ediTtablePage from '@/components/ediTtablePage/index.vue' import ediTtablePage from '@/components/ediTtablePage/index.vue'
const state = reactive({ const state = reactive({
apiName:'cherysupplierconmmrp', apiName:'cherysupplierconmmrp',
searchFilter: { searchFilter: {
supplierCode: null supplierCode: null,
creationTime: null
}, },
searchOptions:[ searchOptions:[
{type:'input',prop:'supplierCode',label:'供应商代码'} {type:'input',prop:'supplierCode',label:'供应商代码'},
{type:'datetimerange',prop:'creationTime',label:'创建时间'},
], ],
auths:store.permissionStore(),
// :tableFormRules="state.tableFormRules"
// tableFormRules:{
// plantId:[{ required: true, message: '', trigger: 'change' },]
// }
}) })
</script> </script>

6
Web/src/views/logisticsPlan/supplierInvData/index.vue

@ -15,10 +15,12 @@ import tablePage from '@/components/tablePage/index.vue'
const state = reactive({ const state = reactive({
apiName:'supplierinvdata', apiName:'supplierinvdata',
searchFilter: { searchFilter: {
plantId: null plantId: null,
creationTime:null
}, },
searchOptions:[ searchOptions:[
{type:'input',prop:'plantId',label:'工厂代码'} {type:'input',prop:'plantId',label:'工厂代码'},
{type:'datetimerange',prop:'creationTime',label:'创建时间'},
], ],
}) })
</script> </script>

6
Web/src/views/logisticsPlan/supplierMrpDate/index.vue

@ -15,10 +15,12 @@ import tablePage from '@/components/tablePage/index.vue'
const state = reactive({ const state = reactive({
apiName:'cherysuppliermrpdata', apiName:'cherysuppliermrpdata',
searchFilter: { searchFilter: {
materialCode: null materialCode: null,
creationTime: null
}, },
searchOptions:[ searchOptions:[
{type:'input',prop:'materialCode',label:'零件号'} {type:'input',prop:'materialCode',label:'零件号'},
{type:'datetimerange',prop:'creationTime',label:'创建时间'},
], ],
}) })
</script> </script>

6
Web/src/views/logisticsPlan/supplierMrpMonth/index.vue

@ -15,10 +15,12 @@ import tablePage from '@/components/tablePage/index.vue'
const state = reactive({ const state = reactive({
apiName:'cherysuppliermrpmonth', apiName:'cherysuppliermrpmonth',
searchFilter: { searchFilter: {
materialCode: null materialCode: null,
creationTime:null
}, },
searchOptions:[ searchOptions:[
{type:'input',prop:'materialCode',label:'零件号'} {type:'input',prop:'materialCode',label:'零件号'},
{type:'datetimerange',prop:'creationTime',label:'创建时间'},
], ],
}) })
</script> </script>

6
Web/src/views/logisticsPlan/supplierMrpState/index.vue

@ -15,10 +15,12 @@ import tablePage from '@/components/tablePage/index.vue'
const state = reactive({ const state = reactive({
apiName:'cherysuppliermrp', apiName:'cherysuppliermrp',
searchFilter: { searchFilter: {
plantId: null plantId: null,
creationTime:null
}, },
searchOptions:[ searchOptions:[
{type:'input',prop:'plantId',label:'工厂代码'} {type:'input',prop:'plantId',label:'工厂代码'},
{type:'datetimerange',prop:'creationTime',label:'创建时间'},
], ],
}) })
</script> </script>

6
Web/src/views/logisticsPlan/supplierMrpWarning/index.vue

@ -15,10 +15,12 @@ import tablePage from '@/components/tablePage/index.vue'
const state = reactive({ const state = reactive({
apiName:'cherysuppliermrpwarning', apiName:'cherysuppliermrpwarning',
searchFilter: { searchFilter: {
plantId: null plantId: null,
creationTime:null
}, },
searchOptions:[ searchOptions:[
{type:'input',prop:'plantId',label:'工厂代码'} {type:'input',prop:'plantId',label:'工厂代码'},
{type:'datetimerange',prop:'creationTime',label:'创建时间'},
], ],
}) })
</script> </script>

6
Web/src/views/logisticsPlan/supplierPo/index.vue

@ -15,10 +15,12 @@ import tablePage from '@/components/tablePage/index.vue'
const state = reactive({ const state = reactive({
apiName:'cherysupplierpo', apiName:'cherysupplierpo',
searchFilter: { searchFilter: {
purchaseOrder: null purchaseOrder: null,
creationTime: null
}, },
searchOptions:[ searchOptions:[
{type:'input',prop:'purchaseOrder',label:'采购订单号'} {type:'input',prop:'purchaseOrder',label:'采购订单号'},
{type:'datetimerange',prop:'creationTime',label:'创建时间'},
], ],
}) })
</script> </script>

6
Web/src/views/logisticsPlan/supplierProHschedul/index.vue

@ -15,10 +15,12 @@ import tablePage from '@/components/tablePage/index.vue'
const state = reactive({ const state = reactive({
apiName:'cherysupplierporhschedul', apiName:'cherysupplierporhschedul',
searchFilter: { searchFilter: {
productionLineId: null productionLineId: null,
creationTime: null
}, },
searchOptions:[ searchOptions:[
{type:'input',prop:'productionLineId',label:'产线代码'} {type:'input',prop:'productionLineId',label:'产线代码'},
{type:'datetimerange',prop:'creationTime',label:'创建时间'},
], ],
}) })
</script> </script>

2
Web/src/views/logisticsPlan/supplierProPlaning/index.vue

@ -16,9 +16,11 @@ const state = reactive({
apiName:'supplierproplaning', apiName:'supplierproplaning',
searchFilter: { searchFilter: {
materialCode: null, materialCode: null,
creationTime:null,
}, },
searchOptions:[ searchOptions:[
{type:'input',prop:'materialCode',label:'物料号'}, {type:'input',prop:'materialCode',label:'物料号'},
{type:'datetimerange',prop:'creationTime',label:'创建时间'},
], ],
}) })
</script> </script>

6
Web/src/views/logisticsPlan/supplierProTschedul/index.vue

@ -15,10 +15,12 @@ import tablePage from '@/components/tablePage/index.vue'
const state = reactive({ const state = reactive({
apiName:'cherysupplierprotschedul', apiName:'cherysupplierprotschedul',
searchFilter: { searchFilter: {
productionLineId: null productionLineId: null,
creationTime:null
}, },
searchOptions:[ searchOptions:[
{type:'input',prop:'productionLineId',label:'产线代码'} {type:'input',prop:'productionLineId',label:'产线代码'},
{type:'datetimerange',prop:'creationTime',label:'创建时间'},
], ],
}) })
</script> </script>

6
Web/src/views/logisticsPlan/supplierReturn/index.vue

@ -15,10 +15,12 @@ import tablePage from '@/components/tablePage/index.vue'
const state = reactive({ const state = reactive({
apiName:'cherysupplierreturn', apiName:'cherysupplierreturn',
searchFilter: { searchFilter: {
returnNumber: null returnNumber: null,
creationTime: null
}, },
searchOptions:[ searchOptions:[
{type:'input',prop:'returnNumber',label:'退货单号'} {type:'input',prop:'returnNumber',label:'退货单号'},
{type:'datetimerange',prop:'creationTime',label:'创建时间'},
], ],
}) })
</script> </script>

6
Web/src/views/logisticsPlan/supplierSaWeek/index.vue

@ -15,10 +15,12 @@ import tablePage from '@/components/tablePage/index.vue'
const state = reactive({ const state = reactive({
apiName:'cherysuppliersaweek', apiName:'cherysuppliersaweek',
searchFilter: { searchFilter: {
scheduleAgreement: null scheduleAgreement: null,
creationTime: null
}, },
searchOptions:[ searchOptions:[
{type:'input',prop:'scheduleAgreement',label:'计划协议号'} {type:'input',prop:'scheduleAgreement',label:'计划协议号'},
{type:'datetimerange',prop:'creationTime',label:'创建时间'},
], ],
}) })
</script> </script>

6
Web/src/views/logisticsPlan/supplierSinvData/index.vue

@ -17,10 +17,12 @@ import tablePage from '@/components/tablePage/index.vue'
const state = reactive({ const state = reactive({
apiName:'cherysuppliersinvdata', apiName:'cherysuppliersinvdata',
searchFilter: { searchFilter: {
supplierCode: null supplierCode: null,
creationTime:null
}, },
searchOptions:[ searchOptions:[
{type:'input',prop:'supplierCode',label:'供应商代码'} {type:'input',prop:'supplierCode',label:'供应商代码'},
{type:'datetimerange',prop:'creationTime',label:'创建时间'},
], ],
rightOperation:'apiUpdate', rightOperation:'apiUpdate',
}) })

6
Web/src/views/productionQuality/supplierBom/index.vue

@ -18,10 +18,12 @@ import tablePage from '@/components/tablePage/index.vue'
const state = reactive({ const state = reactive({
apiName:'cherysupplierbom', apiName:'cherysupplierbom',
searchFilter: { searchFilter: {
supplierCode: null supplierCode: null,
creationTime:null
}, },
searchOptions:[ searchOptions:[
{type:'input',prop:'supplierCode',label:'供应商代码'} {type:'input',prop:'supplierCode',label:'供应商代码'},
{type:'datetimerange',prop:'creationTime',label:'创建时间'},
], ],
}) })
</script> </script>

6
Web/src/views/productionQuality/supplierEmployee/index.vue

@ -18,10 +18,12 @@ import tablePage from '@/components/tablePage/index.vue'
const state = reactive({ const state = reactive({
apiName:'cherysupplieremployee', apiName:'cherysupplieremployee',
searchFilter: { searchFilter: {
supplierCode: null supplierCode: null,
creationTime:null
}, },
searchOptions:[ searchOptions:[
{type:'input',prop:'supplierCode',label:'供应商代码'} {type:'input',prop:'supplierCode',label:'供应商代码'},
{type:'datetimerange',prop:'creationTime',label:'创建时间'},
], ],
rightOperation:'apiUpdate,apiDelete', rightOperation:'apiUpdate,apiDelete',
}) })

6
Web/src/views/productionQuality/supplierInfo/index.vue

@ -18,10 +18,12 @@ import tablePage from '@/components/tablePage/index.vue'
const state = reactive({ const state = reactive({
apiName:'cherysupplierinfo', apiName:'cherysupplierinfo',
searchFilter: { searchFilter: {
supplierCode: null supplierCode: null,
creationTime:null
}, },
searchOptions:[ searchOptions:[
{type:'input',prop:'supplierCode',label:'供应商代码'} {type:'input',prop:'supplierCode',label:'供应商代码'},
{type:'datetimerange',prop:'creationTime',label:'创建时间'},
], ],
rightOperation:'apiUpdate,apiDelete', rightOperation:'apiUpdate,apiDelete',
}) })

6
Web/src/views/productionQuality/supplierProAttachmentData/index.vue

@ -18,10 +18,12 @@ import tablePage from '@/components/tablePage/index.vue'
const state = reactive({ const state = reactive({
apiName:'cherysupplierproattachmentdata', apiName:'cherysupplierproattachmentdata',
searchFilter: { searchFilter: {
supplierCode: null supplierCode: null,
creationTime:null
}, },
searchOptions:[ searchOptions:[
{type:'input',prop:'supplierCode',label:'供应商代码'} {type:'input',prop:'supplierCode',label:'供应商代码'},
{type:'datetimerange',prop:'creationTime',label:'创建时间'},
], ],
rightOperation:'apiUpdate,apiDelete', rightOperation:'apiUpdate,apiDelete',
}) })

6
Web/src/views/productionQuality/supplierProCps/index.vue

@ -18,10 +18,12 @@ import tablePage from '@/components/tablePage/index.vue'
const state = reactive({ const state = reactive({
apiName:'cherysupplierprocps', apiName:'cherysupplierprocps',
searchFilter: { searchFilter: {
supplierCode: null supplierCode: null,
creationTime:null
}, },
searchOptions:[ searchOptions:[
{type:'input',prop:'supplierCode',label:'供应商代码'} {type:'input',prop:'supplierCode',label:'供应商代码'},
{type:'datetimerange',prop:'creationTime',label:'创建时间'},
], ],
rightOperation:'apiUpdate', rightOperation:'apiUpdate',
}) })

6
Web/src/views/productionQuality/supplierProData/index.vue

@ -18,10 +18,12 @@ import tablePage from '@/components/tablePage/index.vue'
const state = reactive({ const state = reactive({
apiName:'cherysupplierprodata', apiName:'cherysupplierprodata',
searchFilter: { searchFilter: {
supplierCode: null supplierCode: null,
creationTime:null
}, },
searchOptions:[ searchOptions:[
{type:'input',prop:'supplierCode',label:'供应商代码'} {type:'input',prop:'supplierCode',label:'供应商代码'},
{type:'datetimerange',prop:'creationTime',label:'创建时间'},
], ],
rightOperation:'apiUpdate', rightOperation:'apiUpdate',
}) })

6
Web/src/views/productionQuality/supplierProFirstPassyield/index.vue

@ -18,10 +18,12 @@ import tablePage from '@/components/tablePage/index.vue'
const state = reactive({ const state = reactive({
apiName:'cherysupplierprofirstpassyield', apiName:'cherysupplierprofirstpassyield',
searchFilter: { searchFilter: {
cheryProductNo: null cheryProductNo: null,
creationTime:null
}, },
searchOptions:[ searchOptions:[
{type:'input',prop:'cheryProductNo',label:'奇瑞零件号'} {type:'input',prop:'cheryProductNo',label:'奇瑞零件号'},
{type:'datetimerange',prop:'creationTime',label:'创建时间'},
], ],
rightOperation:'apiUpdate', rightOperation:'apiUpdate',
}) })

6
Web/src/views/productionQuality/supplierProFlaw/index.vue

@ -18,10 +18,12 @@ import tablePage from '@/components/tablePage/index.vue'
const state = reactive({ const state = reactive({
apiName:'cherysupplierproflaw', apiName:'cherysupplierproflaw',
searchFilter: { searchFilter: {
supplierCode: null supplierCode: null,
creationTime:null
}, },
searchOptions:[ searchOptions:[
{type:'input',prop:'supplierCode',label:'供应商代码'} {type:'input',prop:'supplierCode',label:'供应商代码'},
{type:'datetimerange',prop:'creationTime',label:'创建时间'},
], ],
rightOperation:'apiUpdate', rightOperation:'apiUpdate',
}) })

6
Web/src/views/productionQuality/supplierProMaterialStock/index.vue

@ -18,10 +18,12 @@ import tablePage from '@/components/tablePage/index.vue'
const state = reactive({ const state = reactive({
apiName:'supplierpromaterialstock', apiName:'supplierpromaterialstock',
searchFilter: { searchFilter: {
supplierCode: null supplierCode: null,
creationTime:null
}, },
searchOptions:[ searchOptions:[
{type:'input',prop:'supplierCode',label:'供应商代码'} {type:'input',prop:'supplierCode',label:'供应商代码'},
{type:'datetimerange',prop:'creationTime',label:'创建时间'},
], ],
rightOperation:'apiUpdate', rightOperation:'apiUpdate',
}) })

6
Web/src/views/productionQuality/supplierProProcess/index.vue

@ -18,10 +18,12 @@ import tablePage from '@/components/tablePage/index.vue'
const state = reactive({ const state = reactive({
apiName:'cherysupplierproprocess', apiName:'cherysupplierproprocess',
searchFilter: { searchFilter: {
techCode: null techCode: null,
creationTime:null
}, },
searchOptions:[ searchOptions:[
{type:'input',prop:'techCode',label:'工艺编码'} {type:'input',prop:'techCode',label:'工艺编码'},
{type:'datetimerange',prop:'creationTime',label:'创建时间'},
], ],
}) })
</script> </script>

6
Web/src/views/productionQuality/supplierProProcessEquipment/index.vue

@ -18,10 +18,12 @@ import tablePage from '@/components/tablePage/index.vue'
const state = reactive({ const state = reactive({
apiName:'cherysupplierproprocessequipment', apiName:'cherysupplierproprocessequipment',
searchFilter: { searchFilter: {
deviceCode: null deviceCode: null,
creationTime:null
}, },
searchOptions:[ searchOptions:[
{type:'input',prop:'deviceCode',label:'工艺装备编码'} {type:'input',prop:'deviceCode',label:'工艺装备编码'},
{type:'datetimerange',prop:'creationTime',label:'创建时间'},
], ],
rightOperation:'apiUpdate,apiDelete', rightOperation:'apiUpdate,apiDelete',
}) })

6
Web/src/views/productionQuality/supplierProScheduling/index.vue

@ -15,10 +15,12 @@ import tablePage from '@/components/tablePage/index.vue'
const state = reactive({ const state = reactive({
apiName:'cherysupplierproscheduling', apiName:'cherysupplierproscheduling',
searchFilter: { searchFilter: {
plantId: null plantId: null,
creationTime:null
}, },
searchOptions:[ searchOptions:[
{type:'input',prop:'plantId',label:'工厂代码'} {type:'input',prop:'plantId',label:'工厂代码'},
{type:'datetimerange',prop:'creationTime',label:'创建时间'},
], ],
}) })
</script> </script>

6
Web/src/views/productionQuality/upplierProMaterialData/index.vue

@ -17,10 +17,12 @@ import tablePage from '@/components/tablePage/index.vue'
const state = reactive({ const state = reactive({
apiName:'cherysupplierpromaterialdata', apiName:'cherysupplierpromaterialdata',
searchFilter: { searchFilter: {
cheryProductNo: null cheryProductNo: null,
creationTime:null
}, },
searchOptions:[ searchOptions:[
{type:'input',prop:'cheryProductNo',label:'奇瑞零件号'} {type:'input',prop:'cheryProductNo',label:'奇瑞零件号'},
{type:'datetimerange',prop:'creationTime',label:'创建时间'},
], ],
rightOperation:'apiUpdate', rightOperation:'apiUpdate',
}) })

6
Web/src/views/productionQuality/upplierProStationFirstPassyield/index.vue

@ -18,10 +18,12 @@ import tablePage from '@/components/tablePage/index.vue'
const state = reactive({ const state = reactive({
apiName:'cherysupplierprostationfirstpassyield', apiName:'cherysupplierprostationfirstpassyield',
searchFilter: { searchFilter: {
stationId: null stationId: null,
creationTime:null
}, },
searchOptions:[ searchOptions:[
{type:'input',prop:'stationId',label:'工位代码'} {type:'input',prop:'stationId',label:'工位代码'},
{type:'datetimerange',prop:'creationTime',label:'创建时间'},
], ],
rightOperation:'apiUpdate', rightOperation:'apiUpdate',
}) })

68
Web/src/views/system/taskConifgure/index.vue

@ -1,28 +1,37 @@
<template> <template>
<tablePage <tablePage
ref="tablePageRef"
:columnWidth="150" :columnWidth="150"
:apiName="state.apiName" :apiName="state.apiName"
:searchOptions="state.searchOptions" :searchOptions="state.searchOptions"
:searchFilter="state.searchFilter" :searchFilter="state.searchFilter"
:rightOperation="state.rightOperation" :rightOperation="state.rightOperation"
:showApiRightOperation="state.showApiRightOperation"
:apiEditFormRules="state.apiEditFormRules" :apiEditFormRules="state.apiEditFormRules"
@rightOperationHadel="rightOperationHadel"
></tablePage> ></tablePage>
</template> </template>
<script setup> <script setup>
defineOptions({ name: 'taskConifgure' }) defineOptions({ name: 'taskConifgure' })
import { reactive, ref, onMounted } from 'vue' import { reactive, ref, onMounted,nextTick } from 'vue'
import tablePage from '@/components/tablePage/index.vue' import tablePage from '@/components/tablePage/index.vue'
import { getSetisautoByUid } from '@/api/system/taskConifgureApi'
import { ElMessageBox,ElMessage } from 'element-plus'
const state = reactive({ const state = reactive({
apiName:'taskconifgure', apiName:'taskconifgure',
searchFilter: { searchFilter: {
tableName: null tableName: null,
creationTime:null,
}, },
searchOptions:[ searchOptions:[
{type:'input',prop:'tableName',label:'表名'} {type:'input',prop:'tableName',label:'表名'},
{type:'datetimerange',prop:'creationTime',label:'创建时间'},
], ],
rightOperation:'apiUpdate', rightOperation:[],
showApiRightOperation:['apiUpdate'],
apiEditFormRules:{ apiEditFormRules:{
tableName: [{ required: true, message: '必填项', trigger: 'blur' }], tableName: [{ required: true, message: '必填项', trigger: 'blur' }],
taskName: [{ required: true, message: '必填项', trigger: 'blur' }], taskName: [{ required: true, message: '必填项', trigger: 'blur' }],
@ -31,4 +40,55 @@ const state = reactive({
corn: [{ required: true, message: '必填项', trigger: 'blur' }], corn: [{ required: true, message: '必填项', trigger: 'blur' }],
} }
}) })
state.rightOperation = [
{
label:'启动',
name:'setisautoOk',
link:true,
type:'success',
auth:state.apiName+':setisautoOk',
hide:(row,scope) => {return row.isAuto}
},
{
label:'关闭',
name:'setisautoNo',
link:true,
type:'danger',
auth:state.apiName+':setisautoNo',
hide:(row,scope) => {return !row.isAuto}
},
]
const tablePageRef = ref(null)
// -/
function changeSetisautoHttp(row,btn){
ElMessageBox.confirm(`是否确定${btn}`, '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
tablePageRef.value.state.loading = true
getSetisautoByUid({uid:row.uId,isauto:!row.isAuto})
.then(res=>{
ElMessage.success('操作成功!')
tablePageRef.value.getTableData()
})
.finally(()=>{tablePageRef.value.state.loading = false})
})
}
//
function rightOperationHadel(btn,scope){
// -
if(btn.name == 'setisautoOk'){
changeSetisautoHttp(scope.row,btn.label)
}
// -
if(btn.name == 'setisautoNo'){
changeSetisautoHttp(scope.row,btn.label)
}
}
</script> </script>

6
Web/src/views/task/taskSub/index.vue

@ -42,10 +42,12 @@
const state = reactive({ const state = reactive({
apiName:'tasksub', apiName:'tasksub',
searchFilter: { searchFilter: {
taskName: null taskName: null,
creationTime:null,
}, },
searchOptions:[ searchOptions:[
{type:'input',prop:'taskName',label:'任务名称'} {type:'input',prop:'taskName',label:'任务名称'},
{type:'datetimerange',prop:'creationTime',label:'创建时间'},
], ],
leftOperation:[ leftOperation:[
{label:'查看详情',name:'showInfo',link:true,type:'primary'} {label:'查看详情',name:'showInfo',link:true,type:'primary'}

Loading…
Cancel
Save