Blame view

src/views/sqcx/jtfc/jtfc.vue 3.12 KB
jiaozeping@pashanhoo.com committed
1 2
<template>
  <div class="from-clues">
jiaozeping@pashanhoo.com committed
3
    <!-- 家庭房产 -->
jiaozeping@pashanhoo.com committed
4
    <div class="from-clues-header">
任超 committed
5
      <el-form :model="queryForm" @submit.native.prevent ref="queryForm" label-width="70px">
jiaozeping@pashanhoo.com committed
6 7
        <el-row>
          <el-col :span="5">
liangyifan committed
8
            <el-form-item label="查询编号">
任超 committed
9
              <el-input placeholder="请输入查询编号" @clear="queryClick()" v-model="queryForm.cxbh" clearable class="width100">
任超 committed
10
              </el-input>
liangyifan committed
11 12 13 14
            </el-form-item>
          </el-col>
          <el-col :span="5">
            <el-form-item label="申请人">
任超 committed
15
              <el-input placeholder="请输入申请人" @clear="queryClick()" v-model="queryForm.sqr" clearable class="width100">
任超 committed
16
              </el-input>
liangyifan committed
17 18
            </el-form-item>
          </el-col>
任超 committed
19
          <el-col :span="11" class="flex">
20
            <el-form-item label="查询时间">
21
              <el-date-picker v-model="queryForm.sqr" type="date" placeholder="开始日期" value-format="yyyy-MM-dd" clearable>
22
              </el-date-picker>
23
              <el-date-picker v-model="queryForm.sqr" type="date" placeholder="结束日期" value-format="yyyy-MM-dd" clearable>
24 25 26
              </el-date-picker>
            </el-form-item>
          </el-col>
任超 committed
27
          <el-col :span="3" class="btnColRight">
28
            <el-button type="primary" native-type="submit" @click="handleSearch">查询</el-button>
任超 committed
29
            <el-button type="primary" @click="handleAdd">新增</el-button>
jiaozeping@pashanhoo.com committed
30 31 32 33 34
          </el-col>
        </el-row>
      </el-form>
    </div>
    <!-- 表格 -->
任超 committed
35
    <div class="from-clues-content">
任超 committed
36
      <lb-table :page-size="pageData.size" class="loadingtext" :current-page.sync="pageData.current"
任超 committed
37 38
        :total="tableData.total" @size-change="handleSizeChange" @p-current-change="handleCurrentChange"
        :column="tableData.columns" :data="tableData.data">
jiaozeping@pashanhoo.com committed
39 40 41 42 43
      </lb-table>
    </div>
  </div>
</template>
<script>
1  
jiaozeping@pashanhoo.com committed
44 45
import table from "@/utils/mixin/table";
import { datas, sendThis } from "./jtfcdata";
蔡俊立 committed
46
import { getSqcxPage } from "@/api/sqcx";
jiaozeping@pashanhoo.com committed
47 48 49
export default {
  name: "jtfc",
  mixins: [table],
任超 committed
50
  mounted () {
jiaozeping@pashanhoo.com committed
51
    sendThis(this);
田浩浩 committed
52
    this.queryClick();
jiaozeping@pashanhoo.com committed
53
  },
任超 committed
54
  data () {
jiaozeping@pashanhoo.com committed
55
    return {
田浩浩 committed
56
      sqcxBsm: "",
jiaozeping@pashanhoo.com committed
57
      queryForm: {
任超 committed
58
        cxbh: "",
jiaozeping@pashanhoo.com committed
59
        sqr: "",
蔡俊立 committed
60
        cxlx: '1'
jiaozeping@pashanhoo.com committed
61 62 63
      },
      tableData: {
        columns: datas.columns(),
jiaozeping@pashanhoo.com committed
64
        data: [],
jiaozeping@pashanhoo.com committed
65 66 67 68 69
      },
    };
  },
  methods: {
    // 初始化数据
任超 committed
70
    queryClick () {
任超 committed
71
      this.$startLoading();
蔡俊立 committed
72
      getSqcxPage({ ...this.queryForm, ...this.pageData }).then((res) => {
jiaozeping@pashanhoo.com committed
73 74 75 76 77 78
        this.$endLoading();
        if (res.code === 200) {
          let { records, total } = res.result;
          this.tableData.data = records;
          this.tableData.total = total;
        }
1  
jiaozeping@pashanhoo.com committed
79
      });
任超 committed
80
    },
任超 committed
81
    handleSort (name, sort) {
jiaozeping@pashanhoo.com committed
82
      console.log(name, sort);
1  
jiaozeping@pashanhoo.com committed
83
    },
任超 committed
84
    handleAdd () {
85 86 87
      this.$popupDialog("家庭房产查询", "sqcx/jtfc/components/addjtfc", {
        sqcxBsm: ''
      })
jiaozeping@pashanhoo.com committed
88
    },
任超 committed
89
    handleViewClick (row) {
90 91 92 93 94 95
      this.$popupDialog("家庭房产查询", "sqcx/jtfc/components/addjtfc", {
        sqcxBsm: row.bsmSqcx
      })
    }
  }
}
jiaozeping@pashanhoo.com committed
96 97 98 99
</script>
<style scoped lang="scss">
@import "~@/styles/public.scss";
</style>