From 547d4aa1b698a162ee48d71c3598c872a8649203 Mon Sep 17 00:00:00 2001 From: Renpc-kilig <308442850@qq.com> Date: Mon, 8 Jan 2024 17:28:29 +0800 Subject: [PATCH] =?UTF-8?q?=E6=88=BF=E5=B1=8B=E9=A1=B5=E9=9D=A2=E6=A0=B7?= =?UTF-8?q?=E5=BC=8F=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../templates/house/list-myself.html | 1566 ++++++++++------- src/main/resources/templates/house/list.html | 9 +- 2 files changed, 968 insertions(+), 607 deletions(-) diff --git a/src/main/resources/templates/house/list-myself.html b/src/main/resources/templates/house/list-myself.html index c70a45a..c52bae5 100644 --- a/src/main/resources/templates/house/list-myself.html +++ b/src/main/resources/templates/house/list-myself.html @@ -5,37 +5,193 @@ - + @@ -75,43 +231,41 @@
-
-
-
- -
+
+
+
-
-
- -
+
+
+
+
-
-
- -
+
+
+
+
+
- + - - +
@@ -120,10 +274,12 @@ - -
@@ -140,7 +296,7 @@ base: 'assets/layuiadmin/' }).extend({ index: 'lib/index' - }).use(['index', 'table', 'laydate', 'common', 'select'], function() { + }).use(['index', 'table', 'laydate', 'common', 'select'], function () { var $ = layui.$; var $win = $(window); var table = layui.table; @@ -151,11 +307,11 @@ var select = layui.select; var tableUrl = 'api/house/listpage?myself={myself}'; - $(document).on('click', '#excel', function() { + $(document).on('click', '#excel', function () { excel(); }); - function excel(){ + function excel() { var street = selectedRelation.street; var community = selectedRelation.community; var residentialId = selectedRelation.housingEstate; @@ -165,7 +321,6 @@ var isRental = $('#isRental').val(); - top.dialog.msg('确定要导出数据吗?', { time: 0, btn: [top.dataMessage.button.yes, top.dataMessage.button.no], @@ -179,7 +334,7 @@ }); } - var event = function() { + var event = function () { $(document).on('click', '#treeBody ul li', function () { var $lis = $('#treeBody ul li'); $lis.filter('.active').removeClass('active'); @@ -223,7 +378,7 @@ buildingUnitNum: '', } - var initStreetSelect = function() { + var initStreetSelect = function () { select.dataDynamic({ url: 'api/residential/getStreetList', name: 'streetId', @@ -233,9 +388,9 @@ where: {}, selectedValue: '', optionDatasetKeyArray: [], - onSelect: function(data, option) { + onSelect: function (data, option) { selectedRelation.street = data.value; - if(data.value) { + if (data.value) { $('#streetName').val(option.innerHTML); } else { $('#streetName').val(''); @@ -247,10 +402,10 @@ }) } - var initCommunitySelect = function() { + var initCommunitySelect = function () { selectedRelation.community = ''; var $communityBox = $('#communityBox'); - if(!selectedRelation.street) { + if (!selectedRelation.street) { $communityBox.hide(); return; } @@ -264,9 +419,9 @@ where: {areaId: selectedRelation.street}, selectedValue: '', optionDatasetKeyArray: [], - onSelect: function(data, option) { + onSelect: function (data, option) { selectedRelation.community = data.value; - if(data.value) { + if (data.value) { $('#communityName').val(option.innerHTML); } else { $('#communityName').val(''); @@ -279,10 +434,10 @@ }) } - var initHousingEstateSelect = function() { + var initHousingEstateSelect = function () { selectedRelation.housingEstate = ''; var $housingEstateBox = $('#housingEstateBox'); - if(!selectedRelation.community) { + if (!selectedRelation.community) { $housingEstateBox.hide(); return; } @@ -296,9 +451,9 @@ where: {street: selectedRelation.street, community: selectedRelation.community}, selectedValue: '', optionDatasetKeyArray: [], - onSelect: function(data, option) { + onSelect: function (data, option) { selectedRelation.housingEstate = data.value; - if(data.value) { + if (data.value) { $('#housingEstateName').val(option.innerHTML); } else { $('#housingEstateName').val(''); @@ -311,7 +466,7 @@ }) } - var initBuilding = function() { + var initBuilding = function () { selectedRelation.buildingId = ''; top.restAjax.get(top.restAjax.path('api/building/listpage', []), { page: buildingPager.currentPage, @@ -319,35 +474,35 @@ street: selectedRelation.street, community: selectedRelation.community, residentialId: selectedRelation.housingEstate - }, null, function(code, data) { + }, null, function (code, data) { buildingPager.currentPage = data.page; buildingPager.datas = data.rows; buildingPager.total = data.total; - buildingPager.totalPage = buildingPager.total % buildingPager.rows === 0? buildingPager.total / buildingPager.rows : Math.floor(buildingPager.total / buildingPager.rows) + 1; + buildingPager.totalPage = buildingPager.total % buildingPager.rows === 0 ? buildingPager.total / buildingPager.rows : Math.floor(buildingPager.total / buildingPager.rows) + 1; renderBuilding(); - }, function(code, data) { + }, function (code, data) { top.dialog.msg(data.msg); }) } - var renderBuilding = function() { - var renderBuildingLise = function() { + var renderBuilding = function () { + var renderBuildingLise = function () { var lis = ''; - $.each(buildingPager.datas, function(index, item) { + $.each(buildingPager.datas, function (index, item) { lis += `
  • ${item.name}
  • `; }); var $treeBody = $('#treeBody'); $treeBody.empty(); - if(lis) { + if (lis) { $treeBody.append(`楼/排列表
      ${lis}
    `); } else { $treeBody.append('
    暂无数据
    ') } } - var renderPageBtn = function() { + var renderPageBtn = function () { var $buildingPageBtnGroup = $('#buildingPageBtnGroup'); - if(buildingPager.totalPage > 1) { + if (buildingPager.totalPage > 1) { $buildingPageBtnGroup.show(); } else { $buildingPageBtnGroup.hide(); @@ -358,7 +513,7 @@ renderPageBtn(); } - var newInitTableResidential = function(url) { + var newInitTableResidential = function (url) { table.render({ elem: '#dataTable', id: 'dataTable', @@ -374,297 +529,337 @@ }, cols: [ [ - {type:'checkbox', fixed: 'left'}, - {field:'rowNum', width:80, title: '序号', fixed: 'left', align:'center', templet: '{{d.LAY_INDEX}}'}, - {field: 'communityName', width: 180, title: '社区名称', align:'center', - templet: function(row) { + {type: 'checkbox', fixed: 'left'}, + { + field: 'rowNum', + width: 80, + title: '序号', + fixed: 'left', + align: 'center', + templet: '{{d.LAY_INDEX}}' + }, + { + field: 'communityName', width: 180, title: '社区名称', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'residentialName', width: 180, title: '小区名称', align:'center', - templet: function(row) { + { + field: 'residentialName', width: 180, title: '小区名称', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'buildingName', width: 180, title: '楼/排名称', align:'center', - templet: function(row) { + { + field: 'buildingName', width: 180, title: '楼/排名称', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'affiliationUnit', width: 180, title: '所在单元/列', align:'center', - templet: function(row) { + { + field: 'affiliationUnit', width: 180, title: '所在单元/列', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'affiliationFloors', width: 180, title: '所在层/院', align:'center', - templet: function(row) { + { + field: 'affiliationFloors', width: 180, title: '所在层/院', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'houseNum', width: 180, title: '门牌号', align:'center', - templet: function(row) { + { + field: 'houseNum', width: 180, title: '门牌号', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'categoryName', width: 180, title: '房屋类别', align:'center', - templet: function(row) { + { + field: 'categoryName', width: 180, title: '房屋类别', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'natureName', width: 180, title: '房屋性质', align:'center', - templet: function(row) { + { + field: 'natureName', width: 180, title: '房屋性质', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'typeName', width: 180, title: '房屋种类', align:'center', - templet: function(row) { + { + field: 'typeName', width: 180, title: '房屋种类', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'structureName', width: 180, title: '房屋结构', align:'center', - templet: function(row) { + { + field: 'structureName', width: 180, title: '房屋结构', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'buildingPurposeName', width: 180, title: '建筑用途', align:'center', - templet: function(row) { + { + field: 'buildingPurposeName', width: 180, title: '建筑用途', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'roomNum', width: 180, title: '房间数量', align:'center', - templet: function(row) { + { + field: 'roomNum', width: 180, title: '房间数量', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'roomArea', width: 180, title: '房屋面积', align:'center', - templet: function(row) { + { + field: 'roomArea', width: 180, title: '房屋面积', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'roomUseName', width: 180, title: '房屋用途', align:'center', - templet: function(row) { + { + field: 'roomUseName', width: 180, title: '房屋用途', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'dangerName', width: 180, title: '隐患类型', align:'center', - templet: function(row) { + { + field: 'dangerName', width: 180, title: '隐患类型', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'certificateNum', width: 180, title: '产权证号', align:'center', - templet: function(row) { + { + field: 'certificateNum', width: 180, title: '产权证号', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'registrationDate', width: 180, title: '登记日期', align:'center', - templet: function(row) { + { + field: 'registrationDate', width: 180, title: '登记日期', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'affiliatedUnit', width: 180, title: '所属单位', align:'center', - templet: function(row) { + { + field: 'affiliatedUnit', width: 180, title: '所属单位', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'isRental', width: 180, title: '是否出租屋', align:'center', - templet: function(row) { + { + field: 'isRental', width: 180, title: '是否出租屋', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'isVacant', width: 180, title: '是否空置房', align:'center', - templet: function(row) { + { + field: 'isVacant', width: 180, title: '是否空置房', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'lodgeTypeName', width: 180, title: '租住类型', align:'center', - templet: function(row) { + { + field: 'lodgeTypeName', width: 180, title: '租住类型', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'rentalPurposes', width: 180, title: '出租用途', align:'center', - templet: function(row) { + { + field: 'rentalPurposes', width: 180, title: '出租用途', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'homeowner', width: 180, title: '房主名称', align:'center', - templet: function(row) { + { + field: 'homeowner', width: 180, title: '房主名称', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'documentName', width: 180, title: '证件种类', align:'center', - templet: function(row) { + { + field: 'documentName', width: 180, title: '证件种类', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'documentNum', width: 180, title: '证件号码', align:'center', - templet: function(row) { + { + field: 'documentNum', width: 180, title: '证件号码', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'phone', width: 180, title: '联系电话', align:'center', - templet: function(row) { + { + field: 'phone', width: 180, title: '联系电话', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'custodian', width: 180, title: '托管人姓名', align:'center', - templet: function(row) { + { + field: 'custodian', width: 180, title: '托管人姓名', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'custodianDocumentName', width: 180, title: '证件种类', align:'center', - templet: function(row) { + { + field: 'custodianDocumentName', width: 180, title: '证件种类', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'custodianDocumentNum', width: 180, title: '证件号码', align:'center', - templet: function(row) { + { + field: 'custodianDocumentNum', width: 180, title: '证件号码', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'custodianPhone', width: 180, title: '联系电话', align:'center', - templet: function(row) { + { + field: 'custodianPhone', width: 180, title: '联系电话', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'relationshipHomeowner', width: 180, title: '与房主关系', align:'center', - templet: function(row) { + { + field: 'relationshipHomeowner', width: 180, title: '与房主关系', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'houseStatus', fixed: 'right', width: 150, title: '入住人员', align:'center', - templet: function(row) { - var rowData = '入住人员';; + { + field: 'houseStatus', fixed: 'right', width: 150, title: '入住人员', align: 'center', + templet: function (row) { + var rowData = '入住人员'; + ; return rowData; } } ] ], page: true, - parseData: function(data) { + parseData: function (data) { return { 'code': 0, 'msg': '', @@ -675,7 +870,7 @@ }); } - var newInitTableStreet = function(url) { + var newInitTableStreet = function (url) { table.render({ elem: '#dataTable', id: 'dataTable', @@ -691,297 +886,337 @@ }, cols: [ [ - {type:'checkbox', fixed: 'left'}, - {field:'rowNum', width:80, title: '序号', fixed: 'left', align:'center', templet: '{{d.LAY_INDEX}}'}, - {field: 'communityName', width: 180, title: '社区名称', align:'center', - templet: function(row) { + {type: 'checkbox', fixed: 'left'}, + { + field: 'rowNum', + width: 80, + title: '序号', + fixed: 'left', + align: 'center', + templet: '{{d.LAY_INDEX}}' + }, + { + field: 'communityName', width: 180, title: '社区名称', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'residentialName', width: 180, title: '小区名称', align:'center', - templet: function(row) { + { + field: 'residentialName', width: 180, title: '小区名称', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'buildingName', width: 180, title: '楼/排名称', align:'center', - templet: function(row) { + { + field: 'buildingName', width: 180, title: '楼/排名称', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'affiliationUnit', width: 180, title: '所在单元/列', align:'center', - templet: function(row) { + { + field: 'affiliationUnit', width: 180, title: '所在单元/列', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'affiliationFloors', width: 180, title: '所在层/院', align:'center', - templet: function(row) { + { + field: 'affiliationFloors', width: 180, title: '所在层/院', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'houseNum', width: 180, title: '门牌号', align:'center', - templet: function(row) { + { + field: 'houseNum', width: 180, title: '门牌号', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'categoryName', width: 180, title: '房屋类别', align:'center', - templet: function(row) { + { + field: 'categoryName', width: 180, title: '房屋类别', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'natureName', width: 180, title: '房屋性质', align:'center', - templet: function(row) { + { + field: 'natureName', width: 180, title: '房屋性质', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'typeName', width: 180, title: '房屋种类', align:'center', - templet: function(row) { + { + field: 'typeName', width: 180, title: '房屋种类', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'structureName', width: 180, title: '房屋结构', align:'center', - templet: function(row) { + { + field: 'structureName', width: 180, title: '房屋结构', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'buildingPurposeName', width: 180, title: '建筑用途', align:'center', - templet: function(row) { + { + field: 'buildingPurposeName', width: 180, title: '建筑用途', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'roomNum', width: 180, title: '房间数量', align:'center', - templet: function(row) { + { + field: 'roomNum', width: 180, title: '房间数量', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'roomArea', width: 180, title: '房屋面积', align:'center', - templet: function(row) { + { + field: 'roomArea', width: 180, title: '房屋面积', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'roomUseName', width: 180, title: '房屋用途', align:'center', - templet: function(row) { + { + field: 'roomUseName', width: 180, title: '房屋用途', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'dangerName', width: 180, title: '隐患类型', align:'center', - templet: function(row) { + { + field: 'dangerName', width: 180, title: '隐患类型', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'certificateNum', width: 180, title: '产权证号', align:'center', - templet: function(row) { + { + field: 'certificateNum', width: 180, title: '产权证号', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'registrationDate', width: 180, title: '登记日期', align:'center', - templet: function(row) { + { + field: 'registrationDate', width: 180, title: '登记日期', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'affiliatedUnit', width: 180, title: '所属单位', align:'center', - templet: function(row) { + { + field: 'affiliatedUnit', width: 180, title: '所属单位', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'isRental', width: 180, title: '是否出租屋', align:'center', - templet: function(row) { + { + field: 'isRental', width: 180, title: '是否出租屋', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'isVacant', width: 180, title: '是否空置房', align:'center', - templet: function(row) { + { + field: 'isVacant', width: 180, title: '是否空置房', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'lodgeTypeName', width: 180, title: '租住类型', align:'center', - templet: function(row) { + { + field: 'lodgeTypeName', width: 180, title: '租住类型', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'rentalPurposes', width: 180, title: '出租用途', align:'center', - templet: function(row) { + { + field: 'rentalPurposes', width: 180, title: '出租用途', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'homeowner', width: 180, title: '房主名称', align:'center', - templet: function(row) { + { + field: 'homeowner', width: 180, title: '房主名称', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'documentName', width: 180, title: '证件种类', align:'center', - templet: function(row) { + { + field: 'documentName', width: 180, title: '证件种类', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'documentNum', width: 180, title: '证件号码', align:'center', - templet: function(row) { + { + field: 'documentNum', width: 180, title: '证件号码', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'phone', width: 180, title: '联系电话', align:'center', - templet: function(row) { + { + field: 'phone', width: 180, title: '联系电话', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'custodian', width: 180, title: '托管人姓名', align:'center', - templet: function(row) { + { + field: 'custodian', width: 180, title: '托管人姓名', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'custodianDocumentName', width: 180, title: '证件种类', align:'center', - templet: function(row) { + { + field: 'custodianDocumentName', width: 180, title: '证件种类', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'custodianDocumentNum', width: 180, title: '证件号码', align:'center', - templet: function(row) { + { + field: 'custodianDocumentNum', width: 180, title: '证件号码', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'custodianPhone', width: 180, title: '联系电话', align:'center', - templet: function(row) { + { + field: 'custodianPhone', width: 180, title: '联系电话', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'relationshipHomeowner', width: 180, title: '与房主关系', align:'center', - templet: function(row) { + { + field: 'relationshipHomeowner', width: 180, title: '与房主关系', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'houseStatus', fixed: 'right', width: 150, title: '入住人员', align:'center', - templet: function(row) { - var rowData = '入住人员';; + { + field: 'houseStatus', fixed: 'right', width: 150, title: '入住人员', align: 'center', + templet: function (row) { + var rowData = '入住人员'; + ; return rowData; } } ] ], page: true, - parseData: function(data) { + parseData: function (data) { return { 'code': 0, 'msg': '', @@ -992,7 +1227,7 @@ }); } - var newInitTableCommunity = function(url) { + var newInitTableCommunity = function (url) { table.render({ elem: '#dataTable', id: 'dataTable', @@ -1008,297 +1243,337 @@ }, cols: [ [ - {type:'checkbox', fixed: 'left'}, - {field:'rowNum', width:80, title: '序号', fixed: 'left', align:'center', templet: '{{d.LAY_INDEX}}'}, - {field: 'communityName', width: 180, title: '社区名称', align:'center', - templet: function(row) { + {type: 'checkbox', fixed: 'left'}, + { + field: 'rowNum', + width: 80, + title: '序号', + fixed: 'left', + align: 'center', + templet: '{{d.LAY_INDEX}}' + }, + { + field: 'communityName', width: 180, title: '社区名称', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'residentialName', width: 180, title: '小区名称', align:'center', - templet: function(row) { + { + field: 'residentialName', width: 180, title: '小区名称', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'buildingName', width: 180, title: '楼/排名称', align:'center', - templet: function(row) { + { + field: 'buildingName', width: 180, title: '楼/排名称', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'affiliationUnit', width: 180, title: '所在单元/列', align:'center', - templet: function(row) { + { + field: 'affiliationUnit', width: 180, title: '所在单元/列', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'affiliationFloors', width: 180, title: '所在层/院', align:'center', - templet: function(row) { + { + field: 'affiliationFloors', width: 180, title: '所在层/院', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'houseNum', width: 180, title: '门牌号', align:'center', - templet: function(row) { + { + field: 'houseNum', width: 180, title: '门牌号', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'categoryName', width: 180, title: '房屋类别', align:'center', - templet: function(row) { + { + field: 'categoryName', width: 180, title: '房屋类别', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'natureName', width: 180, title: '房屋性质', align:'center', - templet: function(row) { + { + field: 'natureName', width: 180, title: '房屋性质', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'typeName', width: 180, title: '房屋种类', align:'center', - templet: function(row) { + { + field: 'typeName', width: 180, title: '房屋种类', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'structureName', width: 180, title: '房屋结构', align:'center', - templet: function(row) { + { + field: 'structureName', width: 180, title: '房屋结构', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'buildingPurposeName', width: 180, title: '建筑用途', align:'center', - templet: function(row) { + { + field: 'buildingPurposeName', width: 180, title: '建筑用途', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'roomNum', width: 180, title: '房间数量', align:'center', - templet: function(row) { + { + field: 'roomNum', width: 180, title: '房间数量', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'roomArea', width: 180, title: '房屋面积', align:'center', - templet: function(row) { + { + field: 'roomArea', width: 180, title: '房屋面积', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'roomUseName', width: 180, title: '房屋用途', align:'center', - templet: function(row) { + { + field: 'roomUseName', width: 180, title: '房屋用途', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'dangerName', width: 180, title: '隐患类型', align:'center', - templet: function(row) { + { + field: 'dangerName', width: 180, title: '隐患类型', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'certificateNum', width: 180, title: '产权证号', align:'center', - templet: function(row) { + { + field: 'certificateNum', width: 180, title: '产权证号', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'registrationDate', width: 180, title: '登记日期', align:'center', - templet: function(row) { + { + field: 'registrationDate', width: 180, title: '登记日期', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'affiliatedUnit', width: 180, title: '所属单位', align:'center', - templet: function(row) { + { + field: 'affiliatedUnit', width: 180, title: '所属单位', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'isRental', width: 180, title: '是否出租屋', align:'center', - templet: function(row) { + { + field: 'isRental', width: 180, title: '是否出租屋', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'isVacant', width: 180, title: '是否空置房', align:'center', - templet: function(row) { + { + field: 'isVacant', width: 180, title: '是否空置房', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'lodgeTypeName', width: 180, title: '租住类型', align:'center', - templet: function(row) { + { + field: 'lodgeTypeName', width: 180, title: '租住类型', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'rentalPurposes', width: 180, title: '出租用途', align:'center', - templet: function(row) { + { + field: 'rentalPurposes', width: 180, title: '出租用途', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'homeowner', width: 180, title: '房主名称', align:'center', - templet: function(row) { + { + field: 'homeowner', width: 180, title: '房主名称', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'documentName', width: 180, title: '证件种类', align:'center', - templet: function(row) { + { + field: 'documentName', width: 180, title: '证件种类', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'documentNum', width: 180, title: '证件号码', align:'center', - templet: function(row) { + { + field: 'documentNum', width: 180, title: '证件号码', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'phone', width: 180, title: '联系电话', align:'center', - templet: function(row) { + { + field: 'phone', width: 180, title: '联系电话', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'custodian', width: 180, title: '托管人姓名', align:'center', - templet: function(row) { + { + field: 'custodian', width: 180, title: '托管人姓名', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'custodianDocumentName', width: 180, title: '证件种类', align:'center', - templet: function(row) { + { + field: 'custodianDocumentName', width: 180, title: '证件种类', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'custodianDocumentNum', width: 180, title: '证件号码', align:'center', - templet: function(row) { + { + field: 'custodianDocumentNum', width: 180, title: '证件号码', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'custodianPhone', width: 180, title: '联系电话', align:'center', - templet: function(row) { + { + field: 'custodianPhone', width: 180, title: '联系电话', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'relationshipHomeowner', width: 180, title: '与房主关系', align:'center', - templet: function(row) { + { + field: 'relationshipHomeowner', width: 180, title: '与房主关系', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'houseStatus', fixed: 'right', width: 150, title: '入住人员', align:'center', - templet: function(row) { - var rowData = '入住人员';; + { + field: 'houseStatus', fixed: 'right', width: 150, title: '入住人员', align: 'center', + templet: function (row) { + var rowData = '入住人员'; + ; return rowData; } } ] ], page: true, - parseData: function(data) { + parseData: function (data) { return { 'code': 0, 'msg': '', @@ -1309,7 +1584,7 @@ }); } - var newInitTableBuilding = function(url) { + var newInitTableBuilding = function (url) { table.render({ elem: '#dataTable', id: 'dataTable', @@ -1325,297 +1600,337 @@ }, cols: [ [ - {type:'checkbox', fixed: 'left'}, - {field:'rowNum', width:80, title: '序号', fixed: 'left', align:'center', templet: '{{d.LAY_INDEX}}'}, - {field: 'communityName', width: 180, title: '社区名称', align:'center', - templet: function(row) { + {type: 'checkbox', fixed: 'left'}, + { + field: 'rowNum', + width: 80, + title: '序号', + fixed: 'left', + align: 'center', + templet: '{{d.LAY_INDEX}}' + }, + { + field: 'communityName', width: 180, title: '社区名称', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'residentialName', width: 180, title: '小区名称', align:'center', - templet: function(row) { + { + field: 'residentialName', width: 180, title: '小区名称', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'buildingName', width: 180, title: '楼/排名称', align:'center', - templet: function(row) { + { + field: 'buildingName', width: 180, title: '楼/排名称', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'affiliationUnit', width: 180, title: '所在单元/列', align:'center', - templet: function(row) { + { + field: 'affiliationUnit', width: 180, title: '所在单元/列', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'affiliationFloors', width: 180, title: '所在层/院', align:'center', - templet: function(row) { + { + field: 'affiliationFloors', width: 180, title: '所在层/院', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'houseNum', width: 180, title: '门牌号', align:'center', - templet: function(row) { + { + field: 'houseNum', width: 180, title: '门牌号', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'categoryName', width: 180, title: '房屋类别', align:'center', - templet: function(row) { + { + field: 'categoryName', width: 180, title: '房屋类别', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'natureName', width: 180, title: '房屋性质', align:'center', - templet: function(row) { + { + field: 'natureName', width: 180, title: '房屋性质', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'typeName', width: 180, title: '房屋种类', align:'center', - templet: function(row) { + { + field: 'typeName', width: 180, title: '房屋种类', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'structureName', width: 180, title: '房屋结构', align:'center', - templet: function(row) { + { + field: 'structureName', width: 180, title: '房屋结构', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'buildingPurposeName', width: 180, title: '建筑用途', align:'center', - templet: function(row) { + { + field: 'buildingPurposeName', width: 180, title: '建筑用途', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'roomNum', width: 180, title: '房间数量', align:'center', - templet: function(row) { + { + field: 'roomNum', width: 180, title: '房间数量', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'roomArea', width: 180, title: '房屋面积', align:'center', - templet: function(row) { + { + field: 'roomArea', width: 180, title: '房屋面积', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'roomUseName', width: 180, title: '房屋用途', align:'center', - templet: function(row) { + { + field: 'roomUseName', width: 180, title: '房屋用途', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'dangerName', width: 180, title: '隐患类型', align:'center', - templet: function(row) { + { + field: 'dangerName', width: 180, title: '隐患类型', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'certificateNum', width: 180, title: '产权证号', align:'center', - templet: function(row) { + { + field: 'certificateNum', width: 180, title: '产权证号', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'registrationDate', width: 180, title: '登记日期', align:'center', - templet: function(row) { + { + field: 'registrationDate', width: 180, title: '登记日期', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'affiliatedUnit', width: 180, title: '所属单位', align:'center', - templet: function(row) { + { + field: 'affiliatedUnit', width: 180, title: '所属单位', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'isRental', width: 180, title: '是否出租屋', align:'center', - templet: function(row) { + { + field: 'isRental', width: 180, title: '是否出租屋', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'isVacant', width: 180, title: '是否空置房', align:'center', - templet: function(row) { + { + field: 'isVacant', width: 180, title: '是否空置房', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'lodgeTypeName', width: 180, title: '租住类型', align:'center', - templet: function(row) { + { + field: 'lodgeTypeName', width: 180, title: '租住类型', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'rentalPurposes', width: 180, title: '出租用途', align:'center', - templet: function(row) { + { + field: 'rentalPurposes', width: 180, title: '出租用途', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'homeowner', width: 180, title: '房主名称', align:'center', - templet: function(row) { + { + field: 'homeowner', width: 180, title: '房主名称', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'documentName', width: 180, title: '证件种类', align:'center', - templet: function(row) { + { + field: 'documentName', width: 180, title: '证件种类', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'documentNum', width: 180, title: '证件号码', align:'center', - templet: function(row) { + { + field: 'documentNum', width: 180, title: '证件号码', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'phone', width: 180, title: '联系电话', align:'center', - templet: function(row) { + { + field: 'phone', width: 180, title: '联系电话', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'custodian', width: 180, title: '托管人姓名', align:'center', - templet: function(row) { + { + field: 'custodian', width: 180, title: '托管人姓名', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'custodianDocumentName', width: 180, title: '证件种类', align:'center', - templet: function(row) { + { + field: 'custodianDocumentName', width: 180, title: '证件种类', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'custodianDocumentNum', width: 180, title: '证件号码', align:'center', - templet: function(row) { + { + field: 'custodianDocumentNum', width: 180, title: '证件号码', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'custodianPhone', width: 180, title: '联系电话', align:'center', - templet: function(row) { + { + field: 'custodianPhone', width: 180, title: '联系电话', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'relationshipHomeowner', width: 180, title: '与房主关系', align:'center', - templet: function(row) { + { + field: 'relationshipHomeowner', width: 180, title: '与房主关系', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'houseStatus', fixed: 'right', width: 150, title: '入住人员', align:'center', - templet: function(row) { - var rowData = '入住人员';; + { + field: 'houseStatus', fixed: 'right', width: 150, title: '入住人员', align: 'center', + templet: function (row) { + var rowData = '入住人员'; + ; return rowData; } } ] ], page: true, - parseData: function(data) { + parseData: function (data) { return { 'code': 0, 'msg': '', @@ -1643,297 +1958,337 @@ }, cols: [ [ - {type:'checkbox', fixed: 'left'}, - {field:'rowNum', width:80, title: '序号', fixed: 'left', align:'center', templet: '{{d.LAY_INDEX}}'}, - {field: 'communityName', width: 180, title: '社区名称', align:'center', - templet: function(row) { + {type: 'checkbox', fixed: 'left'}, + { + field: 'rowNum', + width: 80, + title: '序号', + fixed: 'left', + align: 'center', + templet: '{{d.LAY_INDEX}}' + }, + { + field: 'communityName', width: 180, title: '社区名称', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'residentialName', width: 180, title: '小区名称', align:'center', - templet: function(row) { + { + field: 'residentialName', width: 180, title: '小区名称', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'buildingName', width: 180, title: '楼/排名称', align:'center', - templet: function(row) { + { + field: 'buildingName', width: 180, title: '楼/排名称', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'affiliationUnit', width: 180, title: '所在单元/列', align:'center', - templet: function(row) { + { + field: 'affiliationUnit', width: 180, title: '所在单元/列', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'affiliationFloors', width: 180, title: '所在层/院', align:'center', - templet: function(row) { + { + field: 'affiliationFloors', width: 180, title: '所在层/院', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'houseNum', width: 180, title: '门牌号', align:'center', - templet: function(row) { + { + field: 'houseNum', width: 180, title: '门牌号', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'categoryName', width: 180, title: '房屋类别', align:'center', - templet: function(row) { + { + field: 'categoryName', width: 180, title: '房屋类别', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'natureName', width: 180, title: '房屋性质', align:'center', - templet: function(row) { + { + field: 'natureName', width: 180, title: '房屋性质', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'typeName', width: 180, title: '房屋种类', align:'center', - templet: function(row) { + { + field: 'typeName', width: 180, title: '房屋种类', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'structureName', width: 180, title: '房屋结构', align:'center', - templet: function(row) { + { + field: 'structureName', width: 180, title: '房屋结构', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'buildingPurposeName', width: 180, title: '建筑用途', align:'center', - templet: function(row) { + { + field: 'buildingPurposeName', width: 180, title: '建筑用途', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'roomNum', width: 180, title: '房间数量', align:'center', - templet: function(row) { + { + field: 'roomNum', width: 180, title: '房间数量', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'roomArea', width: 180, title: '房屋面积', align:'center', - templet: function(row) { + { + field: 'roomArea', width: 180, title: '房屋面积', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'roomUseName', width: 180, title: '房屋用途', align:'center', - templet: function(row) { + { + field: 'roomUseName', width: 180, title: '房屋用途', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'dangerName', width: 180, title: '隐患类型', align:'center', - templet: function(row) { + { + field: 'dangerName', width: 180, title: '隐患类型', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'certificateNum', width: 180, title: '产权证号', align:'center', - templet: function(row) { + { + field: 'certificateNum', width: 180, title: '产权证号', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'registrationDate', width: 180, title: '登记日期', align:'center', - templet: function(row) { + { + field: 'registrationDate', width: 180, title: '登记日期', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'affiliatedUnit', width: 180, title: '所属单位', align:'center', - templet: function(row) { + { + field: 'affiliatedUnit', width: 180, title: '所属单位', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'isRental', width: 180, title: '是否出租屋', align:'center', - templet: function(row) { + { + field: 'isRental', width: 180, title: '是否出租屋', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'isVacant', width: 180, title: '是否空置房', align:'center', - templet: function(row) { + { + field: 'isVacant', width: 180, title: '是否空置房', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'lodgeTypeName', width: 180, title: '租住类型', align:'center', - templet: function(row) { + { + field: 'lodgeTypeName', width: 180, title: '租住类型', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'rentalPurposes', width: 180, title: '出租用途', align:'center', - templet: function(row) { + { + field: 'rentalPurposes', width: 180, title: '出租用途', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'homeowner', width: 180, title: '房主名称', align:'center', - templet: function(row) { + { + field: 'homeowner', width: 180, title: '房主名称', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'documentName', width: 180, title: '证件种类', align:'center', - templet: function(row) { + { + field: 'documentName', width: 180, title: '证件种类', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'documentNum', width: 180, title: '证件号码', align:'center', - templet: function(row) { + { + field: 'documentNum', width: 180, title: '证件号码', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'phone', width: 180, title: '联系电话', align:'center', - templet: function(row) { + { + field: 'phone', width: 180, title: '联系电话', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'custodian', width: 180, title: '托管人姓名', align:'center', - templet: function(row) { + { + field: 'custodian', width: 180, title: '托管人姓名', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'custodianDocumentName', width: 180, title: '证件种类', align:'center', - templet: function(row) { + { + field: 'custodianDocumentName', width: 180, title: '证件种类', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'custodianDocumentNum', width: 180, title: '证件号码', align:'center', - templet: function(row) { + { + field: 'custodianDocumentNum', width: 180, title: '证件号码', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'custodianPhone', width: 180, title: '联系电话', align:'center', - templet: function(row) { + { + field: 'custodianPhone', width: 180, title: '联系电话', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'relationshipHomeowner', width: 180, title: '与房主关系', align:'center', - templet: function(row) { + { + field: 'relationshipHomeowner', width: 180, title: '与房主关系', align: 'center', + templet: function (row) { var rowData = row[this.field]; - if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') { + if (typeof (rowData) === 'undefined' || rowData == null || rowData == '') { return '-'; } return rowData; } }, - {field: 'houseStatus', fixed: 'right', width: 150, title: '入住人员', align:'center', - templet: function(row) { - var rowData = '入住人员';; + { + field: 'houseStatus', fixed: 'right', width: 150, title: '入住人员', align: 'center', + templet: function (row) { + var rowData = '入住人员'; + ; return rowData; } } ] ], page: true, - parseData: function(data) { + parseData: function (data) { return { 'code': 0, 'msg': '', @@ -1951,16 +2306,16 @@ title: "房屋人员列表", width: '80%', height: '90%', - onClose: function() { + onClose: function () { reloadTable(); } }); } //监听行单击事件 - table.on('tool(dataTable)', function(obj){ + table.on('tool(dataTable)', function (obj) { var data = obj.data; - if('rentalHis' == obj.event) { + if ('rentalHis' == obj.event) { rentalHis(data); } }); @@ -1978,6 +2333,7 @@ }, }); } + // 初始化日期 function initDate() { // 日期选择 @@ -1990,6 +2346,7 @@ format: 'yyyy-MM-dd' }); } + // 删除 function removeData(ids) { top.dialog.msg(top.dataMessage.delete, { @@ -2012,25 +2369,26 @@ } }); } + initTable(); initDate(); // 事件 - 页面变化 - $win.on('resize', function() { + $win.on('resize', function () { clearTimeout(resizeTimeout); - resizeTimeout = setTimeout(function() { + resizeTimeout = setTimeout(function () { reloadTable(); }, 500); }); // 事件 - 搜索 - $(document).on('click', '#search', function() { + $(document).on('click', '#search', function () { reloadTable(1); }); // 事件 - 增删改 - table.on('toolbar(dataTable)', function(obj) { + table.on('toolbar(dataTable)', function (obj) { var layEvent = obj.event; var checkStatus = table.checkStatus('dataTable'); var checkDatas = checkStatus.data; - if(layEvent === 'saveEvent') { + if (layEvent === 'saveEvent') { layer.open({ type: 2, title: false, @@ -2040,14 +2398,14 @@ shadeClose: true, anim: 2, content: top.restAjax.path('route/house/save', []), - end: function() { + end: function () { reloadTable(); } }); - } else if(layEvent === 'updateEvent') { - if(checkDatas.length === 0) { + } else if (layEvent === 'updateEvent') { + if (checkDatas.length === 0) { top.dialog.msg(top.dataMessage.table.selectEdit); - } else if(checkDatas.length > 1) { + } else if (checkDatas.length > 1) { top.dialog.msg(top.dataMessage.table.selectOneEdit); } else { layer.open({ @@ -2059,18 +2417,18 @@ shadeClose: true, anim: 2, content: top.restAjax.path('route/house/update?houseId={houseId}', [checkDatas[0].houseId]), - end: function() { + end: function () { reloadTable(); } }); } - } else if(layEvent === 'removeEvent') { - if(checkDatas.length === 0) { + } else if (layEvent === 'removeEvent') { + if (checkDatas.length === 0) { top.dialog.msg(top.dataMessage.table.selectDelete); } else { var ids = ''; - for(var i = 0, item; item = checkDatas[i++];) { - if(i > 1) { + for (var i = 0, item; item = checkDatas[i++];) { + if (i > 1) { ids += '_'; } ids += item['houseId']; @@ -2080,7 +2438,7 @@ } }); - var init = function(){ + var init = function () { initStreetSelect(); initCommunitySelect(); event(); diff --git a/src/main/resources/templates/house/list.html b/src/main/resources/templates/house/list.html index e44888a..db57f80 100644 --- a/src/main/resources/templates/house/list.html +++ b/src/main/resources/templates/house/list.html @@ -36,7 +36,7 @@ } .layui-form-pane .layui-form-selected .layui-edge { - margin-top: 2px; + margin-top: 8px; } .layui-form-pane .layui-form-select dl { @@ -187,6 +187,11 @@ #contentBody .center .main .floor .unit .house .info .option { display: none; } + + .layui-form-select .layui-input { + height: 30px; + margin-top: 7px; + } @@ -226,7 +231,6 @@
    -