|
|
@ -4,15 +4,15 @@ |
|
|
|
<Search :schema="Workstation.allSchemas.searchSchema" @search="setSearchParams" @reset="setSearchParams" /> |
|
|
|
</ContentWrap> |
|
|
|
|
|
|
|
<!-- 列表头部 --> |
|
|
|
<TableHead |
|
|
|
:HeadButttondata="HeadButttondata" |
|
|
|
@button-base-click="buttonBaseClick" |
|
|
|
:routeName="routeName" |
|
|
|
@updataTableColumns="updataTableColumns" |
|
|
|
@searchFormClick="searchFormClick" |
|
|
|
:allSchemas="Workstation.allSchemas" |
|
|
|
/> |
|
|
|
<!-- 列表头部 --> |
|
|
|
<TableHead |
|
|
|
:HeadButttondata="HeadButttondata" |
|
|
|
@button-base-click="buttonBaseClick" |
|
|
|
:routeName="routeName" |
|
|
|
@updataTableColumns="updataTableColumns" |
|
|
|
@searchFormClick="searchFormClick" |
|
|
|
:allSchemas="Workstation.allSchemas" |
|
|
|
/> |
|
|
|
|
|
|
|
<!-- 列表 --> |
|
|
|
<ContentWrap> |
|
|
@ -59,26 +59,34 @@ |
|
|
|
:apiPage="apiPage" |
|
|
|
:tabs="TabsList" |
|
|
|
@changeTabs="changeTabs" |
|
|
|
/> |
|
|
|
/> |
|
|
|
<!-- 导入 --> |
|
|
|
<ImportForm ref="importFormRef" url="/mes/workstation/import" :importTemplateData="importTemplateData" @success="importSuccess" /> |
|
|
|
</template> |
|
|
|
|
|
|
|
<script setup lang="ts"> |
|
|
|
import download from '@/utils/download' |
|
|
|
import {TabsList, Team, Workstation, WorkstationRules} from './workstation.data' |
|
|
|
import { |
|
|
|
Equipment, |
|
|
|
Process, |
|
|
|
Production, |
|
|
|
TabsList, |
|
|
|
Team, |
|
|
|
Workstation, |
|
|
|
WorkstationRules |
|
|
|
} from './workstation.data' |
|
|
|
import * as WorkstationApi from '@/api/mes/workstation' |
|
|
|
import * as defaultButtons from '@/utils/disposition/defaultButtons' |
|
|
|
import TableHead from '@/components/TableHead/src/TableHead.vue' |
|
|
|
import ImportForm from '@/components/ImportForm/src/ImportForm.vue' |
|
|
|
import { |
|
|
|
PurchasereceiptRecordDetail, |
|
|
|
PurchasereceiptRecordDetailRules, |
|
|
|
PurchasereceiptRecordMain |
|
|
|
} from "@/views/wms/purchasereceiptManage/purchasereceipt/purchasereceiptRecordMain/purchasereceiptRecordMain.data"; |
|
|
|
import {PurchasereceiptRequestTabsList} from "@/utils/disposition/tabsList"; |
|
|
|
import * as PurchasereceiptRecordDetailApi from "@/api/wms/purchasereceiptRecordDetail"; |
|
|
|
import {getEquipmentPage, getProcessPage, getProductionPage} from "@/api/mes/workstation"; |
|
|
|
import { |
|
|
|
getEquipmentPage, |
|
|
|
getProcessPage, |
|
|
|
getProductionPage, |
|
|
|
goalParams, |
|
|
|
params |
|
|
|
} from "@/api/mes/workstation"; |
|
|
|
defineOptions({ name: 'Workstation' }) |
|
|
|
|
|
|
|
const message = useMessage() // 消息弹窗 |
|
|
@ -188,11 +196,6 @@ const formsSuccess = async (formType,data) => { |
|
|
|
getList() |
|
|
|
} |
|
|
|
|
|
|
|
/** 绑定操作 */ |
|
|
|
const detailRef = ref() |
|
|
|
const openDetail = (row: any, titleName: any, titleValue: any) => { |
|
|
|
detailRef.value.openDetail(row, titleName, titleValue, 'basicWorkstation') |
|
|
|
} |
|
|
|
|
|
|
|
/** 删除按钮操作 */ |
|
|
|
const handleDelete = async (id: number) => { |
|
|
@ -252,31 +255,31 @@ onMounted(async () => { |
|
|
|
getList() |
|
|
|
importTemplateData.templateUrl = await WorkstationApi.importTemplate() |
|
|
|
}) |
|
|
|
/** 详情操作 */ |
|
|
|
const detailRef = ref() |
|
|
|
const openDetail = (row: any, titleName: any, titleValue: any) => { |
|
|
|
goalParams.workstationCode = row.code |
|
|
|
detailRef.value.openDetail(row, titleName, titleValue, 'basicWorkstation') |
|
|
|
} |
|
|
|
// 子包装数据 |
|
|
|
const teamRef = ref() |
|
|
|
const { tableObject: teamData, tableMethods: teamMethods } = useTable({ |
|
|
|
getListApi: WorkstationApi.getTeamPage |
|
|
|
}) |
|
|
|
const { getList:teamList } = teamMethods |
|
|
|
const detailAllSchemas = ref(Team.allSchemas) |
|
|
|
const apiPage = ref(WorkstationApi.getTeamPage) |
|
|
|
const tabeKey = ref("workstationDetail"); |
|
|
|
const tableKey = ref("workstationDetail"); |
|
|
|
// tabs 切换事件 |
|
|
|
const changeTabs = (data) =>{ |
|
|
|
tableKey.value = data.prop |
|
|
|
if(data.prop == 'Team'){ |
|
|
|
console.log(data) |
|
|
|
apiPage.value = WorkstationApi.getTeamPage |
|
|
|
detailAllSchemas.value = Team.allSchemas |
|
|
|
}else if(data.prop == 'Equipment'){ |
|
|
|
apiPage.value = WorkstationApi.getEquipmentPage |
|
|
|
detailAllSchemas.value = PurchasereceiptRecordDetail.allSchemas |
|
|
|
detailAllSchemas.value = Equipment.allSchemas |
|
|
|
}else if(data.prop == 'Process'){ |
|
|
|
apiPage.value = WorkstationApi.getProcessPage |
|
|
|
detailAllSchemas.value = PurchasereceiptRecordDetail.allSchemas |
|
|
|
detailAllSchemas.value = Process.allSchemas |
|
|
|
}else if(data.prop == 'Production'){ |
|
|
|
apiPage.value = WorkstationApi.getProductionPage |
|
|
|
detailAllSchemas.value = PurchasereceiptRecordDetail.allSchemas |
|
|
|
detailAllSchemas.value = Production.allSchemas |
|
|
|
} |
|
|
|
tabeKey.value = data.prop |
|
|
|
} |
|
|
|
</script> |
|
|
|