|
@@ -1,7 +1,644 @@
|
|
|
<template>
|
|
|
- testsss
|
|
|
- </template>
|
|
|
-
|
|
|
- <script>
|
|
|
-
|
|
|
- </script>
|
|
|
+ <div class="mainStyle">
|
|
|
+ <div style="height:65%">
|
|
|
+ <div class="pannel-header">
|
|
|
+ <div class="pannel-title">
|
|
|
+ <div class="pannel-split">
|
|
|
+ </div>用户档案信息
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ <div class="filteroption">
|
|
|
+ <div style="display:flex;align-items:center;">
|
|
|
+ <span class="span_item">所属公司:</span>
|
|
|
+ <el-cascader ref="casCompany" placeholder="请选择公司" size="small" custom-style="display: inline-block"
|
|
|
+ :options="companyOptions" :value="companyId" :props="{ checkStrictly: true }" clearable
|
|
|
+ @change="onCompanyChange" />
|
|
|
+ <span style="margin-left:8px;">所属片区:</span>
|
|
|
+ <el-select v-model="mrAreaValue" size="small" clearable multiple collapse-tags filterable placeholder="全部"
|
|
|
+ default-first-option @change="onMrAreaChange">
|
|
|
+ <el-option v-for="item in mrAreaOptions" :key="item.code" :label="item.name" :value="item.code" />
|
|
|
+ </el-select>
|
|
|
+ <span style="margin-left:8px;">所属抄表册:</span>
|
|
|
+ <el-select v-model="mrBookValue" size="small" clearable multiple collapse-tags filterable placeholder="全部"
|
|
|
+ default-first-option @change="onMrBookChange">
|
|
|
+ <el-option v-for="item in mrBookOptions" :key="item.code" :label="item.name" :value="item.code" />
|
|
|
+ </el-select>
|
|
|
+ <el-input v-model="keywords" size="small" style="width:200px;margin-left: 8px;margin-right: 8px;"
|
|
|
+ placeholder="输入关键字进行查询" />
|
|
|
+ <el-button type="primary" icon="el-icon-search" @click="buildReportQuery()" size="small">搜索</el-button>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ <div class="tableheight_customer">
|
|
|
+ <TableItem :table-data="customerListData" :column="column_customer" :for-id="true" :pagination="true"
|
|
|
+ :pagesize="pageInfoCustomer.size" :currentpage="pageInfoCustomer.current" :border="true" :multiple="false"
|
|
|
+ :total="pageInfoCustomer.tableTotal" :fixed="true" :isdelete="false" :is-select="false" :stripe="true"
|
|
|
+ @handleCurrentChange="onCustomerHandleCurrentChange" @rowClick="onCustomerRowClick"
|
|
|
+ @handleSizeChange="onCustomerHandleSizeChange" />
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ <div style="height:35%;padding-top:20px">
|
|
|
+ <div class="pannel-header">
|
|
|
+ <div class="pannel-title">
|
|
|
+ <div class="pannel-split">
|
|
|
+ </div>水表档案信息
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ <div class="btn-tool-bar">
|
|
|
+ <el-button class="search" style="margin-left: 10px" type="success" icon="el-icon-circle-plus" size="small"
|
|
|
+ @click="reportClick()">添加</el-button>
|
|
|
+ <el-button class="search" style="margin-left: 10px" type="warning" icon="el-icon-edit" size="small"
|
|
|
+ :disabled="multipleSelection.length !== 1" @click="editClick()">修改</el-button>
|
|
|
+ <el-button class="search" style="margin-left: 10px" type="danger" icon="el-icon-delete" size="small"
|
|
|
+ :disabled="multipleSelection.length == 0" @click="deleteClick()">删除</el-button>
|
|
|
+ </div>
|
|
|
+ <div class="tableheight_meter">
|
|
|
+ <TableItem :table-data="meterListData" :column="column_meter" :for-id="true" :pagination="true"
|
|
|
+ :pagesize="pageInfoMeter.size" :currentpage="pageInfoMeter.current" :border="true" :multiple="false"
|
|
|
+ :total="pageInfoMeter.tableTotal" :fixed="true" :isdelete="false" :is-select="false" :stripe="true"
|
|
|
+ @handleCurrentChange="handleCurrentChange" @handleSelectionChange="handleSelectionChange"
|
|
|
+ @handleSizeChange="handleSizeChange" @rowDblclick="showBuild" @detail="showBuild" />
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ <el-dialog :visible.sync="reportDialog" title="新增" width="800px" top="10vh">
|
|
|
+ <MeterDialog :report-form="reportForm" :is-look="false" />
|
|
|
+ <template slot="footer">
|
|
|
+ <el-button size="small" @click="cancelReport()">取消</el-button>
|
|
|
+ <el-button type="primary" size="small" @click="confirmBuildReport()">确定</el-button>
|
|
|
+ </template>
|
|
|
+ </el-dialog>
|
|
|
+ <el-dialog :visible.sync="dialogDetail" title="查看" width="800px" top="10vh">
|
|
|
+ <MeterDialog :report-form="detailData" :is-look="true" />
|
|
|
+ <template slot="footer">
|
|
|
+ <el-button size="small" @click="dialogDetail = false">取消</el-button>
|
|
|
+ <el-button type="primary" size="small" @click="dialogDetail = false">确定</el-button>
|
|
|
+ </template>
|
|
|
+ </el-dialog>
|
|
|
+ <el-dialog :visible.sync="editDialog" title="修改" width="800px" top="10vh">
|
|
|
+ <MeterDialog :report-form="editData" :is-look="false" />
|
|
|
+ <template slot="footer">
|
|
|
+ <el-button size="small" @click="cancelEdit">取消</el-button>
|
|
|
+ <el-button type="primary" size="small" @click="editItem">确定</el-button>
|
|
|
+ </template>
|
|
|
+ </el-dialog>
|
|
|
+ </div>
|
|
|
+</template>
|
|
|
+<script>
|
|
|
+import TableItem from '@/components/TableAuto'
|
|
|
+import MeterDialog from './meterForm'
|
|
|
+import { getCompanyTree } from '@/api/base'
|
|
|
+import { getMrArea, getMrBook } from '@/api/mis/common/base'
|
|
|
+import { queryCustomerList, queryMeterList } from '@/api/mis/meterInfo/meterActionApi'
|
|
|
+export default {
|
|
|
+ name: 'MeterList',
|
|
|
+ components: { TableItem, MeterDialog },
|
|
|
+ props: ['data'],
|
|
|
+ data() {
|
|
|
+ return {
|
|
|
+ mrAreaValue: [],
|
|
|
+ mrBookValue: [],
|
|
|
+ multipleSelection: [], // 表格选中数据
|
|
|
+ pageInfoCustomer: { current: 1, size: 20, tableTotal: 1 }, //用户档案分页数据
|
|
|
+ pageInfoMeter: { current: 1, size: 20, tableTotal: 1 }, //水表档案分页数据
|
|
|
+ column_customer: [
|
|
|
+ {
|
|
|
+ label: '所属片区',
|
|
|
+ prop: 'dmaLevleName',
|
|
|
+ align: 'center',
|
|
|
+ sortable: true
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: '所属抄表册',
|
|
|
+ prop: 'leakAssessmentName',
|
|
|
+ align: 'center',
|
|
|
+ sortable: true
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: '用户编号',
|
|
|
+ prop: 'customerNo',
|
|
|
+ align: 'center',
|
|
|
+ sortable: true
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: '原用户号',
|
|
|
+ prop: 'customerNoOld',
|
|
|
+ align: 'center',
|
|
|
+ sortable: true
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: '用户姓名',
|
|
|
+ prop: 'customerName',
|
|
|
+ align: 'center',
|
|
|
+ sortable: true
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: '用户地址',
|
|
|
+ prop: 'customerAddress',
|
|
|
+ align: 'center',
|
|
|
+ sortable: true
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: '联系电话',
|
|
|
+ prop: 'customerPhone',
|
|
|
+ align: 'center',
|
|
|
+ sortable: true
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: '申请日期',
|
|
|
+ prop: 'applyDatetime',
|
|
|
+ align: 'center',
|
|
|
+ sortable: true
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: '建档日期',
|
|
|
+ prop: 'createdDatetime',
|
|
|
+ align: 'center',
|
|
|
+ sortable: true
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: '用户状态',
|
|
|
+ prop: 'customerState',
|
|
|
+ align: 'center',
|
|
|
+ sortable: true
|
|
|
+ }
|
|
|
+ ],
|
|
|
+ column_meter: [
|
|
|
+ {
|
|
|
+ label: '用户编号',
|
|
|
+ prop: 'customerNo',
|
|
|
+ align: 'center',
|
|
|
+ sortable: true
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: '抄表卡号',
|
|
|
+ prop: 'meterCardNo',
|
|
|
+ align: 'center',
|
|
|
+ sortable: true
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: '抄表卡ID',
|
|
|
+ prop: 'meterCardId',
|
|
|
+ align: 'center',
|
|
|
+ sortable: true
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: '水表类别',
|
|
|
+ prop: 'meterType',
|
|
|
+ align: 'center',
|
|
|
+ sortable: true
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: '水表厂家',
|
|
|
+ prop: 'meterFactory',
|
|
|
+ align: 'center',
|
|
|
+ sortable: true
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: '水表型号',
|
|
|
+ prop: 'meterModel',
|
|
|
+ align: 'center',
|
|
|
+ sortable: true
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: '水表出厂日期',
|
|
|
+ prop: 'meterFactoryDatetime',
|
|
|
+ align: 'center',
|
|
|
+ sortable: true
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: '水表编号',
|
|
|
+ prop: 'meterNo',
|
|
|
+ align: 'center',
|
|
|
+ sortable: true
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: '水价',
|
|
|
+ prop: 'priceCode',
|
|
|
+ align: 'center',
|
|
|
+ sortable: true
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: '计费状态',
|
|
|
+ prop: 'meterState',
|
|
|
+ align: 'center',
|
|
|
+ sortable: true
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: '开卡标志',
|
|
|
+ prop: 'icState',
|
|
|
+ align: 'center',
|
|
|
+ sortable: true
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: '开卡日期',
|
|
|
+ prop: 'icActivateDatetime',
|
|
|
+ align: 'center',
|
|
|
+ sortable: true
|
|
|
+ }
|
|
|
+ ],
|
|
|
+ buildAry: {}, // 详情组件参数
|
|
|
+ keywords: '',//关键字搜索
|
|
|
+ customerListData: [], // table表格数据(用户档案列表)
|
|
|
+ meterListData: [], // table表格数据(水表档案列表)
|
|
|
+ reportDialog: false, // 上报弹窗
|
|
|
+ editDialog: false, // 编辑弹窗
|
|
|
+ reportForm: {
|
|
|
+ dmaLevle: undefined,
|
|
|
+ leakAssessment: undefined,
|
|
|
+ leakDown: undefined,
|
|
|
+ leakUp: undefined
|
|
|
+ },
|
|
|
+ dialogDetail: false, // 控制详情页面的显示
|
|
|
+ // 详情数据
|
|
|
+ detailData: {},
|
|
|
+ editData: null,
|
|
|
+ companyOptions: [], //公司列表
|
|
|
+ mrAreaOptions: [], //所属片区
|
|
|
+ mrBookOptions: [] //所属抄表册
|
|
|
+ }
|
|
|
+ },
|
|
|
+ watch: {
|
|
|
+ reportDialog(newVal, oldVal) {
|
|
|
+ // console.log('上报Dialog:' + newVal ? '打开' : '关闭')
|
|
|
+ if (!newVal) {
|
|
|
+ this.clearPageInfo()
|
|
|
+ }
|
|
|
+ }
|
|
|
+ },
|
|
|
+ created() {
|
|
|
+ this.getCompanyTreeInfo()
|
|
|
+ },
|
|
|
+ mounted() {
|
|
|
+ this.getData()
|
|
|
+ },
|
|
|
+ destroyed() {
|
|
|
+ },
|
|
|
+ methods: {
|
|
|
+ /* --------------------- 界面操作 ----------------*/
|
|
|
+ /**
|
|
|
+ * @description 清除页面相关数据 => Map、表单数据
|
|
|
+ */
|
|
|
+ clearPageInfo() {
|
|
|
+ // 表单数据
|
|
|
+ for (var key in this.reportForm) {
|
|
|
+ // console.log("key值:"+key)
|
|
|
+ this.reportForm[key] = undefined
|
|
|
+ }
|
|
|
+ },
|
|
|
+
|
|
|
+ /* --------------------- 用户档案分页查询 ---------------*/
|
|
|
+ /**
|
|
|
+ * @description 分页每页条数
|
|
|
+ */
|
|
|
+ onCustomerHandleSizeChange(pageSize) {
|
|
|
+ this.pageInfoCustomer.size = pageSize
|
|
|
+ this.getData()
|
|
|
+ },
|
|
|
+ /**
|
|
|
+ * @description 改变当前页
|
|
|
+ */
|
|
|
+ onCustomerHandleCurrentChange(currentPage) {
|
|
|
+ this.pageInfoCustomer.current = currentPage
|
|
|
+ this.getData()
|
|
|
+ },
|
|
|
+ onCustomerRowClick(row) {
|
|
|
+ this.multipleSelection = row
|
|
|
+ loadMeterListInfo(row.customerNo)
|
|
|
+ },
|
|
|
+ /* --------------------- API请求 ----------------*/
|
|
|
+
|
|
|
+ /**
|
|
|
+ * @description 查询应急事件列表
|
|
|
+ */
|
|
|
+ buildReportQuery() {
|
|
|
+ this.pageInfoCustomer.current = 1
|
|
|
+ this.getData()
|
|
|
+ },
|
|
|
+ editClick() {
|
|
|
+ this.editDialog = true
|
|
|
+ this.editData = this.multipleSelection[0]
|
|
|
+ },
|
|
|
+ cancelEdit() {
|
|
|
+ this.editDialog = false
|
|
|
+ this.getData()
|
|
|
+ },
|
|
|
+ deleteClick() {
|
|
|
+ this.$confirm('此操作将删除所选记录, 是否继续?', '提示', {
|
|
|
+ confirmButtonText: '确定',
|
|
|
+ cancelButtonText: '取消',
|
|
|
+ type: 'warning'
|
|
|
+ }).then(() => {
|
|
|
+ this.deleteItem()
|
|
|
+ }).catch(() => {
|
|
|
+ this.$message({
|
|
|
+ type: 'info',
|
|
|
+ message: '已取消删除'
|
|
|
+ })
|
|
|
+ })
|
|
|
+ },
|
|
|
+ /**
|
|
|
+ * @description 查询应急事件列表
|
|
|
+ */
|
|
|
+ getData() {
|
|
|
+ const params = {
|
|
|
+ companyBranch: this.companyId || undefined,//公司
|
|
|
+ mrArea: this.mrAreaValue[0] || undefined,//所属片区
|
|
|
+ mrBook: this.mrBookValue[0] || undefined,//抄表册
|
|
|
+ keyword: this.keywords,//关键字搜索
|
|
|
+ current: this.pageInfoCustomer.current,//当前页
|
|
|
+ size: this.pageInfoCustomer.size,//页码数量
|
|
|
+ total: this.pageInfoCustomer.tableTotal//总条数
|
|
|
+ }
|
|
|
+
|
|
|
+ // // 追加分页参数
|
|
|
+ // const query = this.pageInfoCustomer
|
|
|
+ // Object.assign(query, this.queryParams)
|
|
|
+
|
|
|
+ this.customerListData = []
|
|
|
+ queryCustomerList(params).then((res) => {
|
|
|
+ if (res.code !== 1) {
|
|
|
+ this.$message.error('用户档案信息获取出错!')
|
|
|
+ return
|
|
|
+ }
|
|
|
+ // 数据总数
|
|
|
+ this.pageInfoCustomer.tableTotal = res.result.total
|
|
|
+ this.customerListData = res.result.records
|
|
|
+
|
|
|
+ //获取第一条水表信息
|
|
|
+ loadMeterListInfo(res.result.records[0].customerNo)
|
|
|
+ })
|
|
|
+ },
|
|
|
+ //加载水表信息列表
|
|
|
+ loadMeterListInfo(customerNo) {
|
|
|
+ const meterParams = {
|
|
|
+ customerNo: customerNo,//用户编号
|
|
|
+ current: this.pageInfoMeter.current,//当前页
|
|
|
+ size: this.pageInfoMeter.size,//页码数量
|
|
|
+ total: this.pageInfoMeter.tableTotal//总条数
|
|
|
+ }
|
|
|
+ this.meterListData = []
|
|
|
+ queryMeterList(meterParams).then((rs) => {
|
|
|
+ if (rs.code !== 1) {
|
|
|
+ this.$message.error("水表档案信息获取出错!")
|
|
|
+ return
|
|
|
+ }
|
|
|
+ // 数据总数
|
|
|
+ this.pageInfoMeter.tableTotal = rs.result.total
|
|
|
+ this.meterListData = rs.result.records
|
|
|
+ })
|
|
|
+ },
|
|
|
+ /**
|
|
|
+ * @description 应急事件上报
|
|
|
+ */
|
|
|
+ reportClick() {
|
|
|
+ // this.$message.info('请点击地图获取坐标')
|
|
|
+ const that = this
|
|
|
+ that.reportDialog = true // 显示弹窗
|
|
|
+ },
|
|
|
+ /**
|
|
|
+ * @description 工地信息上报,提交数据库
|
|
|
+ */
|
|
|
+ confirmBuildReport() {
|
|
|
+ var that = this
|
|
|
+ Number(this.reportForm.assessStandard)
|
|
|
+ addLeakAssess(this.reportForm).then(res => {
|
|
|
+ if (res.code == 1) {
|
|
|
+ that.$message.success('新增成功')
|
|
|
+ this.reportDialog = false
|
|
|
+ that.buildReportQuery()
|
|
|
+ } else {
|
|
|
+ that.$message(res.message)
|
|
|
+ }
|
|
|
+ })
|
|
|
+ },
|
|
|
+ editItem() {
|
|
|
+ var that = this
|
|
|
+ // 校验
|
|
|
+ editLeakAssess(this.editData).then(res => {
|
|
|
+ if (res.code == 1) {
|
|
|
+ that.$message.success('修改成功')
|
|
|
+ this.editDialog = false
|
|
|
+ that.buildReportQuery()
|
|
|
+ } else {
|
|
|
+ that.$message(res.message)
|
|
|
+ }
|
|
|
+ })
|
|
|
+ },
|
|
|
+ deleteItem() {
|
|
|
+ var ids = this.multipleSelection.map(item => {
|
|
|
+ return item.id
|
|
|
+ })
|
|
|
+ deleteLeakAssess({ ids: ids.join() }).then(res => {
|
|
|
+ if (res.code == 1) {
|
|
|
+ this.$message.success('删除成功')
|
|
|
+ this.buildReportQuery()
|
|
|
+ } else {
|
|
|
+ this.$message(res.message)
|
|
|
+ }
|
|
|
+ })
|
|
|
+ },
|
|
|
+ /**
|
|
|
+ * @description 取消上报
|
|
|
+ */
|
|
|
+ cancelReport() {
|
|
|
+ this.reportDialog = false // 关闭上报弹窗
|
|
|
+ this.clearPageInfo()
|
|
|
+ },
|
|
|
+
|
|
|
+ /**
|
|
|
+ * @description 判断字符串是否为空
|
|
|
+ */
|
|
|
+ strIsNull(strVal) {
|
|
|
+ strVal = strVal || ''
|
|
|
+ return typeof strVal == 'undefined' || strVal == null || strVal == ''
|
|
|
+ },
|
|
|
+
|
|
|
+ /**
|
|
|
+ * @description 查看事件详情
|
|
|
+ */
|
|
|
+ showBuild(data) {
|
|
|
+ this.detailData = data
|
|
|
+ this.dialogDetail = true
|
|
|
+ },
|
|
|
+ // 获取单位信息
|
|
|
+ getCompanyTreeInfo() {
|
|
|
+ const that = this
|
|
|
+ getCompanyTree({}).then(res => {
|
|
|
+ if (res.code === 1) {
|
|
|
+ // 递归操作
|
|
|
+ const resultData = res.result
|
|
|
+ var treeArr = []
|
|
|
+ that.companyOptions = []
|
|
|
+ that.recursiveData('1', resultData, treeArr)
|
|
|
+ that.treeData = treeArr
|
|
|
+ // 所属公司
|
|
|
+ that.companyOptionData(treeArr, that.companyOptions)
|
|
|
+ }
|
|
|
+ })
|
|
|
+ },
|
|
|
+ recursiveData(typestr, tdata, resData) {
|
|
|
+ const that = this
|
|
|
+ if (Array.isArray(tdata) && tdata.length > 0) {
|
|
|
+ tdata.forEach(function (v, i) {
|
|
|
+ // console.log('内页:' + JSON.stringify(v))
|
|
|
+ resData[i] = {}
|
|
|
+ if (typestr === '1') {
|
|
|
+ resData[i].id = 'gs_' + v.id
|
|
|
+ resData[i].icon = 'el-icon-s-home'
|
|
|
+ resData[i].companyId = v.id
|
|
|
+ resData[i].companyName = v.companyName
|
|
|
+ resData[i].parentId = v.parentId
|
|
|
+ resData[i].coding = v.coding
|
|
|
+ resData[i].address = v.address
|
|
|
+ resData[i].phone = v.phone
|
|
|
+ resData[i].abbreviation = v.abbreviation
|
|
|
+ resData[i].code = v.code
|
|
|
+ resData[i].type = typestr
|
|
|
+ }
|
|
|
+
|
|
|
+ var arr = []
|
|
|
+ if (Array.isArray(v.subCompany) && v.subCompany.length > 0) {
|
|
|
+ if (v.subCompany.length > 0) {
|
|
|
+ //分公司
|
|
|
+ that.recursiveData('1', v.subCompany, arr)
|
|
|
+ }
|
|
|
+ }
|
|
|
+ resData[i].children = arr
|
|
|
+ })
|
|
|
+ }
|
|
|
+ },
|
|
|
+ /**
|
|
|
+ * @description 公司下拉选项
|
|
|
+ */
|
|
|
+ companyOptionData(tdata, resData) {
|
|
|
+ const that = this
|
|
|
+ if (Array.isArray(tdata) && tdata.length > 0) {
|
|
|
+ tdata.forEach(function (v, i) {
|
|
|
+ if (v.type === '1') {
|
|
|
+ resData[i] = {}
|
|
|
+ resData[i].value = v.companyId
|
|
|
+ resData[i].label = v.companyName
|
|
|
+
|
|
|
+ var arr = []
|
|
|
+ if (v.children.length > 0) {
|
|
|
+ that.companyOptionData(v.children, arr)
|
|
|
+ if (Array.isArray(arr) && arr.length > 0) {
|
|
|
+ resData[i].children = arr
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ })
|
|
|
+ }
|
|
|
+ },
|
|
|
+ /**
|
|
|
+ * @description 公司下拉
|
|
|
+ */
|
|
|
+ onCompanyChange(value) {
|
|
|
+ let cid = this.$refs["casCompany"].getCheckedNodes()[0].value;
|
|
|
+ this.companyId = cid;
|
|
|
+ this.getMrAreaInfo(cid);
|
|
|
+ },
|
|
|
+ /**
|
|
|
+ * 所属片区
|
|
|
+ * @param {*} cid 公司编码ID
|
|
|
+ */
|
|
|
+ getMrAreaInfo(cid) {
|
|
|
+ getMrArea({ companyBranch: cid }).then(res => {
|
|
|
+ if (res.code === 1) {
|
|
|
+ const resultData = res.result
|
|
|
+ this.mrAreaOptions = resultData.records
|
|
|
+ }
|
|
|
+ })
|
|
|
+ },
|
|
|
+ onMrAreaChange(value) {
|
|
|
+ this.mrAreaValue = value
|
|
|
+ this.getMrBookInfo(value[0])
|
|
|
+ },
|
|
|
+ /**
|
|
|
+ * 所属抄表册
|
|
|
+ * @param {*} mrAreaCode 抄表片区编码
|
|
|
+ */
|
|
|
+ getMrBookInfo(mrAreaCode) {
|
|
|
+ getMrBook({ mrArea: mrAreaCode }).then(res => {
|
|
|
+ if (res.code === 1) {
|
|
|
+ const resultData = res.result
|
|
|
+ this.mrBookOptions = resultData.records
|
|
|
+ }
|
|
|
+ })
|
|
|
+ },
|
|
|
+ onMrBookChange(value) {
|
|
|
+ this.mrBookValue = value
|
|
|
+ }
|
|
|
+ }
|
|
|
+}
|
|
|
+</script>
|
|
|
+
|
|
|
+<style lang='scss' scoped>
|
|
|
+.mainStyle {
|
|
|
+ height: 100%;
|
|
|
+ width: 100%;
|
|
|
+ padding: 5px;
|
|
|
+
|
|
|
+ .filteroption {
|
|
|
+ width: 100%;
|
|
|
+ height: 40px;
|
|
|
+ font-size: 14px;
|
|
|
+ display: flex;
|
|
|
+ align-items: center;
|
|
|
+ justify-content: space-between;
|
|
|
+ border: 1px solid rgb(221, 221, 221);
|
|
|
+ padding: 20px 5px;
|
|
|
+ }
|
|
|
+
|
|
|
+ .tableheight_customer {
|
|
|
+ margin-top: 5px;
|
|
|
+ height: calc(100% - 65px);
|
|
|
+ }
|
|
|
+
|
|
|
+ .tableheight_meter {
|
|
|
+ margin-top: 5px;
|
|
|
+ height: calc(100% - 80px);
|
|
|
+ }
|
|
|
+
|
|
|
+}
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+// input::-webkit-outer-spin-button,
|
|
|
+// input::-webkit-inner-spin-button {
|
|
|
+// -webkit-appearance: none !important;
|
|
|
+// }
|
|
|
+
|
|
|
+// input[type="number"] {
|
|
|
+// -moz-appearance: textfield;
|
|
|
+// }
|
|
|
+
|
|
|
+.btn-tool-bar {
|
|
|
+ height: 45px;
|
|
|
+ line-height: 40px;
|
|
|
+ border: 1px solid #ddd;
|
|
|
+}
|
|
|
+
|
|
|
+.pannel-header {
|
|
|
+ border-color: #ddd;
|
|
|
+ padding: 5px;
|
|
|
+ border-width: 1px;
|
|
|
+ border-style: solid;
|
|
|
+ border-bottom: 0px;
|
|
|
+ padding-bottom: 5px;
|
|
|
+}
|
|
|
+
|
|
|
+.pannel-title {
|
|
|
+ font-weight: bold;
|
|
|
+ color: #777;
|
|
|
+ height: 25px;
|
|
|
+ line-height: 25px;
|
|
|
+}
|
|
|
+
|
|
|
+.pannel-split {
|
|
|
+ width: 4px;
|
|
|
+ height: 25px;
|
|
|
+ background: linear-gradient(0deg, #0991F1, #5B76F9);
|
|
|
+ float: left;
|
|
|
+ margin-right: 5px;
|
|
|
+}
|
|
|
+</style>
|