<!--
 * @Company: 沈阳信诚科技
 * @Email: html_venustar@163.com
 * @Author: Liuqiming
 * @Description: 生产信息录入
 * @LastEditors: Liuqiming
 * @LastEditTime: 2024-03-25 16:16:16
 * @Date: 2024-02-04 14:43:37
-->
<template>
  <div class="app-container Information">
    <el-tabs v-model="activeTab" @tab-change="handlerTabChange">
      <el-tab-pane label="加料信息" name="F" v-hasPermi="['chargingIn:information:query']">
        <!-- 加料信息 -->
        <div class="feeding" v-if="activeTab === 'F'">
          <els-table
            :btnList="feedBtnList"
            :columns="feedColumns"
            :tableData="feedTableData"
            :searchList="feedSearchList"
            @getTableData="getFeedTableData"
            :pageSet="feedPageSet"
            @addFeed="addFeed"
            @feedBatchDelete="feedBatchDelete"
            :option="{...tableOption, name:'feedingTable'}"
            :tableLoading="feedLoading"
            @handleSelectionChange="feedSelectionChange"
          ></els-table>
        </div>
      </el-tab-pane>
      <el-tab-pane label="质量信息" name="Q" v-hasPermi="['quality:information:query']">
        <!-- 质量信息 -->
        <div class="quality" v-if="activeTab === 'Q'">
          <els-table
            :btnList="qualityBtnList"
            :columns="qualityColumns"
            :tableData="qualityTableData"
            :searchList="qualitySearchList"
            @getTableData="getQualityTableData"
            :pageSet="qualityPageSet"
            @addQuality="addQuality"
            @qualityBatchDelete="qualityBatchDelete"
            :option="{...tableOption, name:'qualityTable'}"
            :tableLoading="qualityLoading"
            @handleSelectionChange="qualitySelectionChange"
          ></els-table>
        </div>
      </el-tab-pane>
      <el-tab-pane label="异常事件录入" name="A" v-hasPermi="['business:eventInformation:query']">
        <!-- 异常事件记录 -->
        <div class="abnormal" v-if="activeTab === 'A'">
          <els-table
            :btnList="abnormalBtnList"
            :columns="abnormalColumns"
            :tableData="abnormalTableData"
            :searchList="abnormalSearchList"
            @getTableData="getAbnormalTableData"
            :pageSet="abnormalPageSet"
            @addAbnormal="addAbnormal"
            @abnormalBatchDelete="abnormalBatchDelete"
            :option="{...tableOption, name:'abnormalTable'}"
            :tableLoading="abnormalLoading"
            @handleSelectionChange="abnormalSelectionChange"
          ></els-table>
        </div>
      </el-tab-pane>
    </el-tabs>
    <!-- 加料信息 -- 弹窗等其他元素 -->
    <el-dialog v-model="feedVisible" :title="feedDialogTitle" width="710" append-to-body destroy-on-close>
      <els-form
        :fieldList="feedFieldList"
        :formOption="formOption"
        :formLoading="feedFormLoading"
        :form="feedFormData"
        @ok="feedSubmit"
        @cancel="feedCancel"
        ref="feedForms"
        @formChange="feedFormChange"
      ></els-form>
    </el-dialog>
    <!-- 质量信息 -- 弹窗等其他元素 -->
    <el-dialog v-model="qualityVisible" :title="qualityDialogTitle" width="710" append-to-body destroy-on-close>
      <els-form
        :fieldList="qualityFieldList"
        :formOption="formOption"
        :formLoading="qualityFormLoading"
        :form="qualityFormData"
        @ok="qualitySubmit"
        @cancel="qualityCancel"
        ref="qualityForms"
        @formChange="qualityFormChange"
      ></els-form>
    </el-dialog>
    <!-- 异常事件记录 -- 弹窗等其他元素 -->
    <el-dialog v-model="abnormalVisible" :title="abnormalDialogTitle" width="710" append-to-body destroy-on-close>
      <els-form
        :fieldList="abnormalFieldList"
        :formOption="formOption"
        :formLoading="abnormalFormLoading"
        :form="abnormalFormData"
        @ok="abnormalSubmit"
        @cancel="abnormalCancel"
        ref="abnormalForms"
      ></els-form>
    </el-dialog>
  </div>
</template>

<script setup name="Information">
import { init } from './index.jsx'

import useUser from '@/store/modules/user'
import {
  // 加料信息接口
  chargingInAdd, getCastTimesNoList, materialInfoList, getChargingInList, chargingInEdit, chargingInRemove,
  // 质量信息接口
  qualityAddApi, qualityListApi, qualityEditApi, qualityRemoveApi, qualityCastingList,
  // 异常事件记录接口
  abnormalAddApi, abnormalListApi, abnormalEditApi, abnormalRemoveApi
} from '@A/produce/information'
import { nextTick } from 'vue';
import { formatDate } from '@U/index'

const { proxy } = getCurrentInstance();
// 获取加料类型字典数据
const { material_charging_type } = proxy.useDict("material_charging_type");
const { material_fill_charging_type } = proxy.useDict("material_fill_charging_type");
// 获取铸流号类型字典数据
const { material_casting_type } = proxy.useDict("material_casting_type");
// 质量等级类型
const { quality_level } = proxy.useDict("quality_level");
// 缺陷类型
const { defect_type } = proxy.useDict("defect_type");

const activeTab = ref('F')  // 选中的tab标签页
/** 加料信息 数据 */
const feedLoading = ref(false)
const feedFormLoading = ref(false)
const feedVisible = ref(false)
const feedFormData = ref({})
const feedSelectList = ref([])
const feedTableData = ref([])
const feedDialogSta = ref('A')
const feedDialogTitle = ref('加料录入')
const castTimesNoList = ref([])
const materialList = ref([])
const materialItem = ref({})
/** 质量信息 数据 */
const qualityLoading = ref(false)
const qualityFormLoading = ref(false)
const qualityVisible = ref(false)
const qualityFormData = ref({})
const qualitySelectList = ref([])
const qualityTableData = ref([])
const qualityDialogSta = ref('A')
const qualityDialogTitle = ref('质量信息录入')
const prdNoList = ref([])
/** 异常事件记录 数据 */
const abnormalLoading = ref(false)
const abnormalFormLoading = ref(false)
const abnormalVisible = ref(false)
const abnormalFormData = ref({})
const abnormalSelectList = ref([])
const abnormalTableData = ref([])
const abnormalDialogSta = ref('A')
const abnormalDialogTitle = ref('异常事件记录')
// tab页切换事件
const handlerTabChange = (val) => {
  if (val === 'F') {
    getFeedList({ pageSize:10, pageNum:1 })
  } else if (val === 'Q') {
    getQualityTableList({ pageSize:10, pageNum:1 })
    // 质量信息铸坯编号
    qualityCastingList().then(res => {
      prdNoList.value = res.data.map(item => {
        return { label: item.castTimesNo, value: item.castTimesNo }
      })
    }).catch(err => console.log(err))
  } else {
    getAbnormalTableList({ pageSize:10, pageNum:1 })
  }
}
/** 加料信息 方法 */
// 获取浇次列表
const getCastingList = () => {
   // 获取浇次数据
  getCastTimesNoList().then(res => {
    castTimesNoList.value = res.data.map(item => {
      return { label: item.castTimesNo, value: item.castTimesNo }
    })
  }).catch(err => console.log(err))
}
// 加料信息表格数据获取
const getFeedList = (searchVal) => {
  feedLoading.value = true
  // 获取表格数据
  getChargingInList(searchVal).then(res => {
    feedTableData.value = res.rows
    feedPageSet.value.total = res.total
    feedLoading.value = false
  }).catch(err => {console.log(err)})
}
// 查询及重置翻页等回调方法
const getFeedTableData = (searchVal) => {
  getFeedList(searchVal)
}
// 加料信息 -- 多选框选中
const feedSelectionChange = (row) => {
  feedSelectList.value = row
  // if (feedSelectList.value.length > 0 && feedBtnList.value.length === 1){
  //   feedBtnList.value = [
  //     { label: '加料录入', type: 'primary', icon:'Plus', met: 'addFeed' },
  //     { label: '批量删除', type: 'danger', icon:'Delete', met: 'feedBatchDelete' },
  //   ]
  // } else if (feedSelectList.value.length === 0 && feedBtnList.value.length === 2) {
  //   feedBtnList.value = [{ label: '加料录入', type: 'primary', icon:'Plus', met: 'addFeed' }]
  // }
}
// 加料信息 -- 批量删除
const feedBatchDelete = () => {
  // console.log('批量删除', feedSelectList.value)
  if (feedSelectList.value.length <= 0) {
    proxy.$modal.msgWarning('请先选择数据项！')
    return
  }
  proxy.$modal.confirm("是否确认删除选中的数据项？").then(() => {
    let ids = feedSelectList.value.map(item => item.id).join(',')
    feedLoading.value = true
    chargingInRemove(ids).then(res => {
      proxy.$modal.msgSuccess(res.msg)
      getFeedTableData({ pageSize:10, pageNum:1 })
    }).catch(err => {console.log(err)})
  }).catch(() => {});
}
// 加料信息 -- 行项目删除
const feedDelete = (row) => {
  proxy.$modal.confirm("是否确认删除当前数据项？").then(() => {
    feedLoading.value = true
    chargingInRemove(row.id).then(res => {
      proxy.$modal.msgSuccess(res.msg)
      getFeedTableData({ pageSize:10, pageNum:1 })
    }).catch(err => {console.log(err)})
  }).catch(()=>{})
}
// 加料信息 -- 行项目修改
const feedEdit = (row) => {
  // console.log(row, '行项目修改')
  feedFormData.value = row
  feedVisible.value = true
  feedFormLoading.value = true
  feedDialogSta.value = 'E'
  feedDialogTitle.value = '修改加料信息'
  getFormList('E', row)
}
// 加料信息 -- 加料录入
const feedForms = ref(null)
const addFeed = async () => {
  feedVisible.value = true
  feedFormLoading.value = true
  feedDialogSta.value = 'A'
  feedDialogTitle.value = '加料录入'
  getFormList('A')
}
// 处理新增及回显的下拉框数据获取
const getFormList = async (sta, row) => {
  // 获取物料 并默认选择第一项
  await materialInfoList({}).then(res => {
    materialList.value = res.data.map(item => {
      return { label: item.materialCode, value: item.materialCode, ...item }
    })
    if (sta === 'A') {
      feedForms.value.setValue('materialCode', materialList.value[0].value)
      feedForms.value.setValue('brand', materialList.value[0].brand)
      feedForms.value.setValue('manufacturer', materialList.value[0].manufacturer)
      feedForms.value.setValue('materialName', materialList.value[0].materialName)
    }
  }).catch(err => console.log(err))
  if (sta === 'A') {
    // 默认渲染当前用户为记录员
    feedForms.value.setValue('operatorId', useUser().$state.id)
    feedForms.value.setValue('operator', useUser().$state.nickName)
    // 浇次 默认选择第一项
    feedForms.value.setValue('castTimesNo', castTimesNoList?.value[0]?.value)
    feedForms.value.setValue('chargingType', material_fill_charging_type.value[0].value)
    feedForms.value.setValue('chargingTypeName', material_fill_charging_type.value[0].label)
  }
  feedFormChange({ field:'chargingType', val: row && row.chargingType ? row.chargingType : material_fill_charging_type.value[0].value })
  feedFormLoading.value = false
}
// 加料信息 -- 加料录入弹窗提交
const feedSubmit = (row) => {
  feedFormLoading.value = true
  if (feedDialogSta.value === 'A') {
    chargingInAdd(row.value).then(res => {
      proxy.$modal.msgSuccess(res.msg)
      feedCancel()
      feedFormLoading.value = false
      getFeedTableData({ pageSize:10, pageNum:1 })
    }).catch(err => console.log(err))
  } else {
    let form = row.value
    Object.defineProperty(form, 'createTime', { enumerable: false })
    Object.defineProperty(form, 'updateTime', { enumerable: false })
    chargingInEdit(form).then(res => {
      proxy.$modal.msgSuccess(res.msg)
      feedCancel()
      feedFormLoading.value = false
      getFeedTableData({ pageSize:10, pageNum:1 })
    }).catch(err => console.log(err))
  }
}
// 加料信息 -- 加料录入弹窗取消
const feedCancel = (row) => {
  feedVisible.value = false
  feedFormData.value = {}
}
// 加料信息 -- form表单事件侦听器 根据加料类型判断铸流号是否展示
const feedFormChange = (row) => {
  // console.log(row)
  if (row.field === 'chargingType') {
    if (row.val === 'MHA') {
      feedForms.value.hidden('prdStrandNo', false)
    } else {
      feedForms.value.hidden('prdStrandNo', true)
    }
  } else if (row.field === 'materialCode') {
    // materialItem.value =
  }
}
/** 质量信息 方法 */
// 获取质量信息列表
const getQualityTableList = (val) => {
  qualityLoading.value = true
  qualityListApi(val).then(res => {
    qualityTableData.value = res.rows
    qualityPageSet.value.total = res.total
    qualityLoading.value = false
  }).catch(err => console.log(err))
}
// 查询重置翻页等公共方法
const getQualityTableData = (searchVal) => {
  getQualityTableList(searchVal)
}
// 质量信息 -- 多选框选中
const qualitySelectionChange = (row) => {
  qualitySelectList.value = row
  // if (qualitySelectList.value.length > 0 && qualityBtnList.value.length === 1){
  //   qualityBtnList.value = [
  //     { label: '质量信息录入', type: 'primary', icon:'Plus', met: 'addQuality' },
  //     { label: '批量删除', type: 'danger', icon:'Delete', met: 'qualityBatchDelete' }
  //   ]
  // } else if (qualitySelectList.value.length === 0 && qualityBtnList.value.length === 2) {
  //   qualityBtnList.value = [{ label: '质量信息录入', type: 'primary', icon:'Plus', met: 'addQuality' }]
  // }
}
// 质量信息 -- 批量删除
const qualityBatchDelete = () => {
  // console.log('批量删除', qualitySelectList.value)
  if (qualitySelectList.value.length <= 0) {
    proxy.$modal.msgWarning('请先选择数据项！')
    return
  }
  proxy.$modal.confirm("是否确认删除选中的数据项？").then(() => {
    let ids = qualitySelectList.value.map(item => item.id).join(',')
    qualityLoading.value = true
    qualityRemoveApi(ids).then(res => {
      proxy.$modal.msgSuccess(res.msg)
      getQualityTableList({ pageSize:10, pageNum:1 })
    }).catch(err => {console.log(err)})
  }).catch(() => {});
}
// 质量信息 -- 行项目删除
const qualityDelete = (row) => {
  // console.log(row, '行项目删除')
  proxy.$modal.confirm("是否确认删除当前数据项？").then(() => {
    qualityLoading.value = true
    qualityRemoveApi(row.id).then(res => {
      proxy.$modal.msgSuccess(res.msg)
      getQualityTableList({ pageSize:10, pageNum:1 })
    }).catch(err => {console.log(err)})
  }).catch(()=>{})
}
// 质量信息 -- 行项目修改
const qualityEdit = (row) => {
  qualityVisible.value = true
  qualityDialogSta.value = 'E'
  qualityDialogTitle.value = '修改质量信息'
  qualityFormData.value = row
  qualityFormLoading.value = true
  nextTick(()=>{
    getQualityForms(row)
  })
  // console.log(row, '行项目修改')
}
// 质量信息 -- 行项目查看
const qualityView = (row) => {
  // console.log(row, '行项目查看')
  qualityVisible.value = true
  qualityDialogSta.value = 'V'
  qualityDialogTitle.value = '查看质量信息'
  let data = {}
  Object.keys(row).forEach(item =>{
    data[item] = row[item] && row[item] !== '' ? row[item] : ' '
  })
  qualityFormData.value = data
  qualityFormLoading.value = true
  nextTick(()=>{
    getQualityForms(row)
  })
}
// 质量信息 -- 质量信息录入
const qualityForms = ref(null)
const addQuality = () => {
  qualityVisible.value = true
  qualityDialogSta.value = 'A'
  qualityDialogTitle.value = '质量信息录入'
  qualityFormLoading.value = true
  nextTick(()=>{
    getQualityForms()
  })
}
// 处理新增及回显的下拉框数据获取
const getQualityForms = (row) => {
  if (qualityDialogSta.value === 'V') {
    qualityForms.value.isView(true)
    qualityFieldList.value.forEach(item => {
      qualityForms.value.disabled(item.field, true)
    })
    qualityFormChange({ field:'defectType', val: row.defectType })
  } else {
    if (qualityDialogSta.value === 'A') {
      qualityForms.value.isView(false)
      qualityForms.value.setValue('operatorId', useUser().$state.id)
      qualityForms.value.setValue('operator', useUser().$state.nickName)
    }
    qualityFormChange({ field:'defectType', val: row && row.defectType ? row.defectType : '' })
    qualityFieldList.value.forEach(item => {
      if (item.field !== 'operator') {
        qualityForms.value.disabled(item.field, false)
      }
    })
    qualityForms.value.isView(false)
  }
  qualityFormLoading.value = false
}
// 质量信息 -- 质量信息弹窗提交
const qualitySubmit = (row) => {
  // console.log(row.value, '质量信息弹窗提交')
  qualityFormLoading.value = true
  if (qualityDialogSta.value === 'A') {
    qualityAddApi(row.value).then(res => {
      proxy.$modal.msgSuccess(res.msg)
      qualityCancel()
      qualityFormLoading.value = false
      getQualityTableList({ pageSize:10, pageNum:1 })
    }).catch(err => console.log(err))
  } else {
    let form = row.value
    Object.defineProperty(form, 'createTime', { enumerable: false })
    Object.defineProperty(form, 'updateTime', { enumerable: false })
    qualityEditApi(form).then(res => {
      proxy.$modal.msgSuccess(res.msg)
      qualityCancel()
      qualityFormLoading.value = false
      getQualityTableList({ pageSize:10, pageNum:1 })
    }).catch(err => console.log(err))
  }
}
// 质量信息 -- 质量信息弹窗取消
const qualityCancel = (row) => {
  qualityVisible.value = false
  qualityFormData.value = {}
}
//  判断缺陷是否展示
const qualityFormChange = (row) => {
  // console.log(row, 'row')
  if (row.field === 'defectType') {
    if (row.val === 'none') {
      qualityForms.value.hidden('defectLength', true)
      qualityForms.value.hidden('defectDepth', true)
      qualityForms.value.hidden('defectWidth', true)
      qualityForms.value.hidden('defectLocation', true)
      qualityForms.value.hidden('defectDesc', true)
      qualityForms.value.hidden('imgInfos', true)
    } else {
      qualityForms.value.hidden('defectLength', false)
      qualityForms.value.hidden('defectDepth', false)
      qualityForms.value.hidden('defectWidth', false)
      qualityForms.value.hidden('defectLocation', false)
      qualityForms.value.hidden('defectDesc', false)
      qualityForms.value.hidden('imgInfos', false)
    }
  }
}
/** 异常事件记录 方法 */
// 获取异常事件记录列表
const getAbnormalTableList = (val) => {
  abnormalLoading.value = true
  abnormalListApi(val).then(res => {
    abnormalTableData.value = res.rows
    abnormalPageSet.value.total = res.total
    abnormalLoading.value = false
  }).catch(err => console.log(err))
}
const getAbnormalTableData = (searchVal) => {
  getAbnormalTableList(searchVal)
}
// 异常事件记录 -- 多选框选中
const abnormalSelectionChange = (row) => {
  abnormalSelectList.value = row
  // if (abnormalSelectList.value.length > 0 && abnormalBtnList.value.length === 1){
  //   abnormalBtnList.value = [
  //     { label: '异常事件录入', type: 'primary', icon:'Plus', met: 'addAbnormal' },
  //     { label: '批量删除', type: 'danger', icon:'Delete', met: 'abnormalBatchDelete' }
  //   ]
  // } else if (abnormalSelectList.value.length === 0 && abnormalBtnList.value.length === 2) {
  //   abnormalBtnList.value = [{ label: '异常事件录入', type: 'primary', icon:'Plus', met: 'addAbnormal' }]
  // }
}
// 异常事件记录 -- 批量删除
const abnormalBatchDelete = () => {
  // console.log('批量删除', abnormalSelectList.value)
  if (abnormalSelectList.value.length <= 0) {
    proxy.$modal.msgWarning('请先选择数据项！')
    return
  }
  proxy.$modal.confirm("是否确认删除选中的数据项？").then(() => {
    let ids = abnormalSelectList.value.map(item => item.id).join(',')
    abnormalLoading.value = true
    abnormalRemoveApi(ids).then(res => {
      proxy.$modal.msgSuccess(res.msg)
      getAbnormalTableList({ pageSize:10, pageNum:1 })
    }).catch(err => {console.log(err)})
  }).catch(() => {});
}
// 异常事件记录 -- 行项目删除
const abnormalDelete = (row) => {
  console.log(row, '行项目删除')
  proxy.$modal.confirm("是否确认删除当前数据项？").then(() => {
    abnormalLoading.value = true
    abnormalRemoveApi(row.id).then(res => {
      proxy.$modal.msgSuccess(res.msg)
      getAbnormalTableList({ pageSize:10, pageNum:1 })
    }).catch(err => {console.log(err)})
  }).catch(()=>{})
}
// 异常事件记录 -- 行项目修改
const abnormalEdit = (row) => {
  // console.log(row, '行项目修改')
  abnormalVisible.value = true
  abnormalDialogSta.value = 'E'
  abnormalDialogTitle.value = '修改异常事件记录'
  abnormalFormData.value = row
  abnormalFormLoading.value = true
  nextTick(()=>{
    addAbnormalFrom()
  })
}
// 异常事件记录 -- 行项目查看
const abnormalView = (row) => {
  // console.log(row, '行项目查看')
  abnormalVisible.value = true
  abnormalDialogSta.value = 'V'
  abnormalDialogTitle.value = '查看异常事件记录'
  let data = {}
  Object.keys(row).forEach(item =>{
    data[item] = row[item] && row[item] !== '' ? row[item] : ' '
  })
  abnormalFormData.value = data
  abnormalFormLoading.value = true
  nextTick(()=>{
    addAbnormalFrom()
  })
}
// 异常事件记录 -- 弹窗
const abnormalForms = ref(null)
const addAbnormal = () => {
  abnormalVisible.value = true
  abnormalDialogSta.value = 'A'
  abnormalDialogTitle.value = '异常事件记录'
  abnormalFormLoading.value = true
  nextTick(()=>{
    addAbnormalFrom()
  })
}
const addAbnormalFrom = () => {
  if (abnormalDialogSta.value === 'V') {
    abnormalForms.value.isView(true)
    abnormalFieldList.value.forEach(item => {
      abnormalForms.value.disabled(item.field, true)
    })
  } else {
    if (abnormalDialogSta.value === 'A') {
      abnormalForms.value.setValue('operatorId', useUser().$state.id)
      abnormalForms.value.setValue('operator', useUser().$state.nickName)
      abnormalForms.value.setValue('abnormalEventTime', formatDate(new Date().getTime()))
      abnormalForms.value.setValue('castTimesNo', castTimesNoList.value[0].value)
    }
    abnormalForms.value.isView(false)
    abnormalFieldList.value.forEach(item => {
      if (item.field !== 'operator') {
        abnormalForms.value.disabled(item.field, false)
      }
    })
  }
  abnormalFormLoading.value = false
}
// 异常事件记录 -- 异常事件记录弹窗提交
const abnormalSubmit = (row) => {
  // console.log(row, '异常事件记录弹窗提交')
  abnormalFormLoading.value = true
  if (abnormalDialogSta.value === 'A') {
    abnormalAddApi(row.value).then(res => {
      proxy.$modal.msgSuccess(res.msg)
      abnormalCancel()
      abnormalFormLoading.value = false
      getAbnormalTableList({ pageSize:10, pageNum:1 })
    }).catch(err => console.log(err))
  } else {
    let form = row.value
    Object.defineProperty(form, 'createTime', { enumerable: false })
    Object.defineProperty(form, 'updateTime', { enumerable: false })
    abnormalEditApi(form).then(res => {
      proxy.$modal.msgSuccess(res.msg)
      abnormalCancel()
      abnormalFormLoading.value = false
      getAbnormalTableList({ pageSize:10, pageNum:1 })
    }).catch(err => console.log(err))
  }
}
// 质异常事件记录 -- 加料录入弹窗取消
const abnormalCancel = (row) => {
  abnormalVisible.value = false
  abnormalFormData.value = {}
}
getCastingList()
getFeedList({ pageSize:10, pageNum:1 })
const {
  feedSearchList,
  feedBtnList,
  feedColumns,
  feedPageSet,
  feedFieldList,
  qualitySearchList,
  qualityBtnList,
  qualityColumns,
  qualityPageSet,
  qualityFieldList,
  abnormalSearchList,
  abnormalBtnList,
  abnormalColumns,
  abnormalPageSet,
  abnormalFieldList,
  tableOption,
  formOption
} = init({
  feedDelete,
  feedEdit,
  material_charging_type,
  material_fill_charging_type,
  material_casting_type,
  qualityView,
  qualityEdit,
  qualityDelete,
  abnormalView,
  abnormalEdit,
  abnormalDelete,
  castTimesNoList,
  materialList,
  materialItem,
  quality_level,
  defect_type,
  prdNoList,
})
</script>

<style lang="scss" scoped>
</style>
