MrShi
2025-02-07 7de835dea145fe8229f5f0100e2a90094e6d5b22
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
<template>
    <TableLayout :permissions="['business:ywroom:query']">
        <!-- 搜索表单 -->
        <el-form ref="searchForm" slot="search-form" :model="searchForm" label-width="120px" inline>
            <el-form-item label="盘点单名称" prop="roomNum">
                <el-input v-model="searchForm.roomNum" placeholder="请输入盘点单名称" @keypress.enter.native="search"></el-input>
            </el-form-item>
            <el-form-item label="状态" prop="buildingId">
                <el-select v-model="searchForm.buildingId" placeholder="请选择楼宇" clearable>
                    <el-option v-for="item in buildList" :key="item.id" :label="item.name" :value="item.id"></el-option>
                </el-select>
            </el-form-item>
            <section>
                <el-button type="primary" @click="search">搜索</el-button>
                <el-button @click="reset">重置</el-button>
            </section>
        </el-form>
        <!-- 表格和分页 -->
        <template v-slot:table-wrap>
            <ul class="toolbar">
                <li><el-button type="primary" @click="$refs.newInventory.open('新建盘点单')">添加</el-button></li>
                <li><el-button type="primary" @click="$refs.inventoryDetails.open('盘点详细')">详情</el-button></li>
            </ul>
            <el-table v-loading="isWorking.search" :data="tableData.list" stripe>
                <el-table-column prop="projectName" label="盘点单名称" min-width="100px"></el-table-column>
                <el-table-column prop="buildingName" label="盘点仓库" min-width="70px"></el-table-column>
                <el-table-column prop="floorName" label="盘点员" min-width="60px"></el-table-column>
                <el-table-column prop="roomNum" label="盘点日期" min-width="60px"></el-table-column>
                <el-table-column prop="rentArea" label="创建人" min-width="80px"></el-table-column>
                <el-table-column prop="feeArea" label="创建时间" min-width="80px"></el-table-column>
                <el-table-column prop="feeArea" label="盘点状态" min-width="80px"></el-table-column>
                <el-table-column label="操作">
                    <template slot-scope="{row}">
                        <el-button type="text" @click="$refs.inventoryDetails.open('盘点详细')">查看详情</el-button>
                        <el-button type="text">取消</el-button>
                        <el-button type="text">删除</el-button>
                    </template>
                </el-table-column>
            </el-table>
            <pagination @size-change="handleSizeChange" @current-change="handlePageChange" :pagination="tableData.pagination">
            </pagination>
            <newInventory ref="newInventory" />
            <inventoryDetails ref="inventoryDetails" />
        </template>
    </TableLayout>
</template>
 
<script>
  import BaseTable from '@/components/base/BaseTable'
  import TableLayout from '@/layouts/TableLayout'
  import Pagination from '@/components/common/Pagination'
  import newInventory from './components/newInventory'
  import inventoryDetails from './components/inventoryDetails'
  export default {
    name: 'inventoryCount',
    extends: BaseTable,
    components: { TableLayout, Pagination, newInventory, inventoryDetails },
    data() {
      return {
        // 搜索
        searchForm: {
          id: '',
          creator: '',
          createDate: '',
          editor: '',
          editDate: '',
          isdeleted: '',
          name: '',
          remark: '',
          status: '',
          sortnum: '',
          imgurl: '',
          code: '',
          roomNum: '',
          isInvestment: '',
          area: '',
          feeArea: '',
          rentArea: '',
          floor: '',
          projectId: '',
          buildingId: ''
        },
        projectList: [],
        buildList: [],
 
        filters: {}
      }
    },
    created() {
      this.config({
        module: '运维房源信息表',
        api: '/project/ywRoom',
        'field.id': 'id',
        'field.main': 'id'
      })
    },
    methods: {
 
    }
  }
</script>