Blame view

src/views/system/sqywgz/sqywgz.vue 2.99 KB
1 2 3 4 5
<template>
  <div class="from-clues">
    <!-- 表单部分 -->
    <div class="from-clues-header">
      <el-form :model="queryForm" ref="queryForm">
任超 committed
6
        <el-row :gutter="20">
7 8
          <el-col :span="6">
            <el-form-item label="权利类型">
任超 committed
9
              <el-select v-model="queryForm.qllx" filterable class="width100" clearable placeholder="请选择权利类型">
任超 committed
10
                <el-option v-for="item in qllxs" :key="item.value" :label="item.label" :value="item.value">
11 12 13 14 15 16
                </el-option>
              </el-select>
            </el-form-item>
          </el-col>
          <el-col :span="6">
            <el-form-item label="登记业务编码">
任超 committed
17
              <el-input placeholder="请输入登记业务编码" v-model="queryForm.djywbm" clearable>
18 19 20
              </el-input>
            </el-form-item>
          </el-col>
任超 committed
21
          <el-col :span="12" class="btnCol">
22
            <el-form-item>
任超 committed
23
              <el-button type="primary" icon="el-icon-search" @click="queryClick()">查询</el-button>
24 25 26 27 28 29 30
            </el-form-item>
          </el-col>
        </el-row>
      </el-form>
    </div>
    <!-- 表格 -->
    <div class="from-clues-content">
31 32 33
      <lb-table :page-size="pageData.pageSize" :current-page.sync="pageData.currentPage" :total="tableData.total"
        @size-change="handleSizeChange" @p-current-change="handleCurrentChange" :column="tableData.columns"
        :data="tableData.data">
34 35
      </lb-table>
    </div>
36
    <editDialog v-model="isDialog" :detailList="detailList" :bsmSqyw="bsmSqyw" />
37 38 39
  </div>
</template>
<script>
任超 committed
40
import table from "@/utils/mixin/table"
任超 committed
41
import editDialog from "./components/editDialog.vue"
任超 committed
42
import { datas, sendThis } from "./sqywgzdata"
任超 committed
43
import { getSysSqdjywBysearch, getDjlxInfo } from "@/api/system.js"
44 45
export default {
  name: "djbcx",
任超 committed
46 47 48
  components: {
    editDialog
  },
49
  mixins: [table],
任超 committed
50
  mounted () {
51 52
    sendThis(this);
  },
任超 committed
53
  data () {
54
    return {
任超 committed
55
      isDialog: false,
56 57
      queryForm: {
        qllx: "",
58
        djywbm: "",
59
      },
60
      qllxs: datas.qllxs(),
61
      tableData: {
任超 committed
62
        total: 0,
63
        columns: datas.columns(),
任超 committed
64
        data: []
任超 committed
65
      },
66 67
      detailList: [],
      bsmSqyw: ''
任超 committed
68
    }
69 70
  },
  methods: {
71
    //查询
任超 committed
72
    queryClick () {
73 74
      this.fetchData();
    },
75
    // 初始化数据
任超 committed
76 77 78 79
    fetchData () {
      getSysSqdjywBysearch({ ...this.queryForm, ...this.pageData }).then(res => {
        if (res.code === 200) {
          let { total, records } = res.result
任超 committed
80 81
          this.tableData.total = total ? total : 0
          this.tableData.data = records ? records : []
任超 committed
82 83
        }
      })
84
    },
85
    //编辑
任超 committed
86
    editClick (row) {
87 88 89 90 91 92
      if (row.nodecode === 'B50') {
        this.detailList = []
        this.bsmSqyw = row.bsmSqyw
        this.isDialog = true
      } else {
        getDjlxInfo(row.bsmSqyw).then(res => {
任超 committed
93 94
          let { result } = res
          this.detailList = result ? result : []
95 96 97
          this.isDialog = true
        })
      }
98
    }
99 100 101 102 103 104
  },
};
</script>
<style scoped lang="scss">
@import "~@/styles/public.scss";
</style>