From ca75cd5e9b582087f32b61894c465b5ad1b20b10 Mon Sep 17 00:00:00 2001 From: java110 <928255095@qq.com> Date: Sat, 12 Sep 2020 19:29:33 +0800 Subject: [PATCH] =?UTF-8?q?=E6=8F=90=E4=BA=A4=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../addRentingConfig/addRentingConfig.js | 4 -- .../rentingAuditManage.html | 4 +- .../rentingAuditManage/rentingAuditManage.js | 60 +++++++++++++++++-- .../rentingPoolManage/rentingPoolManage.html | 12 ++-- .../rentingPoolManage/rentingPoolManage.js | 3 +- 5 files changed, 65 insertions(+), 18 deletions(-) diff --git a/public/components/admin/addRentingConfig/addRentingConfig.js b/public/components/admin/addRentingConfig/addRentingConfig.js index d2168e714..fc4e8b22a 100644 --- a/public/components/admin/addRentingConfig/addRentingConfig.js +++ b/public/components/admin/addRentingConfig/addRentingConfig.js @@ -128,10 +128,6 @@ errInfo: "格式错误" }, ], - - - - }); }, saveRentingConfigInfo: function () { diff --git a/public/pages/admin/rentingAuditManage/rentingAuditManage.html b/public/pages/admin/rentingAuditManage/rentingAuditManage.html index 376e212d4..bd0803244 100644 --- a/public/pages/admin/rentingAuditManage/rentingAuditManage.html +++ b/public/pages/admin/rentingAuditManage/rentingAuditManage.html @@ -16,7 +16,7 @@ - + @@ -29,7 +29,7 @@ - + diff --git a/public/pages/admin/rentingAuditManage/rentingAuditManage.js b/public/pages/admin/rentingAuditManage/rentingAuditManage.js index 06cd96083..5da8e0b0a 100644 --- a/public/pages/admin/rentingAuditManage/rentingAuditManage.js +++ b/public/pages/admin/rentingAuditManage/rentingAuditManage.js @@ -16,8 +16,7 @@ rentingTitle: '', paymentType: '', ownerName: '', - state:'0' - + state: '0' } } }, @@ -29,9 +28,9 @@ vc.on('rentingPoolManage', 'listRentingPool', function (_param) { vc.component._listRentingPools(DEFAULT_PAGE, DEFAULT_ROWS); }); - vc.on('rentingAuditManage','audit',function(_auditInfo){ - - }) + vc.on('rentingAuditManage', 'audit', function (_auditInfo) { + $that._auditRenting(_auditInfo); + }); vc.on('pagination', 'page_event', function (_currentPage) { vc.component._listRentingPools(_currentPage, DEFAULT_ROWS); }); @@ -63,7 +62,8 @@ } ); }, - _openAuditModal: function () { + _openAuditModal: function (_renting) { + $that.rentingPoolManageInfo.rentingId = _renting.rentingId; vc.emit('audit', 'openAuditModal', {}); }, _openEditRentingPoolModel: function (_rentingPool) { @@ -82,6 +82,54 @@ } else { vc.component.rentingPoolManageInfo.moreCondition = true; } + }, + _auditRenting: function (_auditInfo) { + let _user = vc.getData('/nav/getUserInfo'); + + let _userRole = 4; // 运营团队 + + if (_user.storeTypeCd == '800900000002') { + _userRole = 3; + } + + let _state = "2002"; + + if (_auditInfo.state == '1200') { + _state = "3003";//代理商审核失败 + } + + let _audtiInfo = { + userRole: _userRole, + state: _state, + context: _auditInfo.remark, + rentingId: $that.rentingPoolManageInfo.rentingId + } + + //发送get请求 + vc.http.apiPost( + '/renting/auditRenting', + JSON.stringify(_audtiInfo), + { + emulateJSON: true + }, + function (json, res) { + //vm.menus = vm.refreshMenuActive(JSON.parse(json),0); + let _json = JSON.parse(json); + if (_json.code == 0) { + //关闭model + $('#addRentingConfigModel').modal('hide'); + $that._listRentingPools(DEFAULT_PAGE, DEFAULT_ROWS); + return; + } + vc.message(_json.msg); + + }, + function (errInfo, error) { + console.log('请求失败处理'); + + vc.message(errInfo); + + }); } diff --git a/public/pages/admin/rentingPoolManage/rentingPoolManage.html b/public/pages/admin/rentingPoolManage/rentingPoolManage.html index 6f4fa6ad0..d2ff0eddb 100644 --- a/public/pages/admin/rentingPoolManage/rentingPoolManage.html +++ b/public/pages/admin/rentingPoolManage/rentingPoolManage.html @@ -58,7 +58,7 @@
租房ID房屋 出租标题 租金 预付类型
{{rentingPool.rentingId}}{{rentingPool.roomName}} {{rentingPool.rentingTitle}} {{rentingPool.price}} {{rentingPool.paymentType}}
- + @@ -66,6 +66,7 @@ + @@ -73,14 +74,15 @@ - + - - - + + + +
租房ID房屋 出租标题 租金 预付类型出租配置 业主名称 业主电话状态 操作
{{rentingPool.rentingId}}{{rentingPool.roomName}} {{rentingPool.rentingTitle}} {{rentingPool.price}}{{rentingPool.paymentType}}{{rentingPool.checkInDate}}{{rentingPool.rentingConfigId}}{{rentingPool.paymentTypeName}}{{rentingPool.checkIn == '1001'?'立即入住':'预约入住'}}{{rentingPool.rentingType=='3344'?'整租':'合租'}} {{rentingPool.ownerName}} {{rentingPool.ownerTel}}{{rentingPool.stateName}}