zuozhengqing
2024-04-10 96aea12d4cbbda5d51fd8e85fdfb871c1f20a7fc
src/views/systemSetting/workshopManage/index.vue
@@ -1,7 +1,7 @@
<template>
  <div class="silkStandardSetting-container">
    <div class="filter-card">
      <CommonSearch :show-add="false" :amount-view="false" placeholder="请输入关键词" @searchClick="onFilterSearch">
      <CommonSearch ref="searchRef" :show-add="false" :amount-view="false" placeholder="请输入关键词" @searchClick="onFilterSearch">
        <template slot="leftButton">
          <el-button size="small" type="primary" @click="addBtnClick" >新增</el-button>
          <el-button size="small" type="primary" @click="refreshClick">刷新</el-button>
@@ -10,7 +10,7 @@
      </CommonSearch>
    </div>
    <div class="body-card">
      <div>
      <div class="list-view">
        <TableCommonView
          :table-list="tableList"
          @selTableCol="selTableCol"
@@ -28,6 +28,9 @@
            </el-table-column>
          </template>
        </TableCommonView>
      </div>
      <div class="btn-pager">
        <PagerView class="page" :pager-options="pagerOptions" v-on="pagerEvents" />
      </div>
    </div>
    <AddWorkshop 
@@ -47,11 +50,12 @@
import { getWorkshopManageList,deleteWorkshopManage } from "@/api/systemSetting/workshopManage"
import TableCommonView from '@/components/makepager/TableCommonView.vue'
import AddWorkshop from '@/views/systemSetting/workshopManage/components/addWorkshop.vue'
import pageMixin from "@/components/makepager/pager/mixin/pageMixin"
export default {
  name: "workshopManage",
  props: {},
  components: { TableCommonView,AddWorkshop,AddDataDictionaries },
  mixins: [],
  mixins: [pageMixin],
  computed: {},
  data() {
    return {
@@ -69,8 +73,6 @@
      // 类型
      workList: [],
      getDataParams: {
        page: 1,
        pageSize: 10,
        keyWord: '',
      },
      editConfig:{
@@ -88,7 +90,6 @@
  },
  methods: {
    setTable() {
      console.log(this.tableColumn,"看看")
      // top 明细单列表
      this.tableList = {
        selectIndex: true,
@@ -126,13 +127,12 @@
    },
    // 搜索
    onFilterSearch(searchText) {
      console.log(searchText,"是啥")
      this.getDataParams.keyWord=searchText,
      this.getData()
    },
    // 新增
    addBtnClick() {
      this.editConfig.infomitton=[]
      this.editConfig.infomitton={}
      this.editConfig.dialogTitle="新增"
      this.editConfig.visible=true
    },
@@ -141,14 +141,19 @@
    },
    // 刷新
    refreshClick() {},
    refreshClick() {
      this.getDataParams.keyWord = ""
      this.pagerOptions.currPage = 1
      this.pagerOptions.pageSize = 15
      this.$refs.searchRef.searchInput=""
      this.getData()
    },
    // 打印
    printClick() {},
    // 删除
    delBtnClick(){},
    // 组别
    handleShow(item){
      console.log(item,"item")
    handleShow(){
      this.$refs.bomTypeDialog.editDialogVisible = true;
    },
    handleGetBomKindDictList() {
@@ -157,7 +162,7 @@
      // });
    },
    handleConfirmSave(data) {
      console.log(data,"data")
      console.log(data)
      // postSaveBomKindDict({ data: data }).then((res) => {
      //   if (res.code == 200) {
      //     this.$message({
@@ -173,10 +178,11 @@
    async getData() {
      await getWorkshopManageList({
        keyWord: this.getDataParams.keyWord,
        page: this.getDataParams.page,
        pageSize: this.getDataParams.pageSize,
        page: this.pagerOptions.currPage,
        pageSize: this.pagerOptions.pageSize
      }).then((res) => {
        this.tableList.tableInfomation = res.data
        this.pagerOptions.totalCount = res.total
      })
    },
    getStatusCarFlag(val) {
@@ -187,10 +193,10 @@
      }
    },
    handleClick(row,type){
      console.log(row,"row")
      if(type==="查看"){
        this.editConfig.infomitton=row
        this.editConfig.infomitton.workshopId=row.ID
        this.editConfig.infomitton.workshopNumber=Number(this.editConfig.infomitton.workshopNumber)
        this.editConfig.dialogTitle=type
        this.editConfig.visible=true
      }else if(type==="修改"){
@@ -256,5 +262,16 @@
    }
  }
}
.list-view {
  height: calc(100% - 60px);
  overflow: hidden;
}
.btn-pager {
  display: flex;
  margin-top: 10px;
  .page {
    margin-left: auto;
  }
}
</style>