From 7c5fbf48ba9e5e3e1f61579de3ac7c6e2ef85910 Mon Sep 17 00:00:00 2001 From: java110 <928255095@qq.com> Date: Mon, 24 May 2021 07:03:35 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96=E5=BA=95=E9=98=BF=E5=A6=88?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../property/questionValue/questionValue.html | 43 +++++++++++++ .../property/questionValue/questionValue.js | 60 +++++++++++++++++++ .../questionAnswerTitleManage.html | 5 ++ .../questionAnswerTitleManage.js | 3 + 4 files changed, 111 insertions(+) create mode 100644 public/components/property/questionValue/questionValue.html create mode 100644 public/components/property/questionValue/questionValue.js diff --git a/public/components/property/questionValue/questionValue.html b/public/components/property/questionValue/questionValue.html new file mode 100644 index 000000000..5e8fb45c4 --- /dev/null +++ b/public/components/property/questionValue/questionValue.html @@ -0,0 +1,43 @@ + \ No newline at end of file diff --git a/public/components/property/questionValue/questionValue.js b/public/components/property/questionValue/questionValue.js new file mode 100644 index 000000000..fd169df90 --- /dev/null +++ b/public/components/property/questionValue/questionValue.js @@ -0,0 +1,60 @@ +(function(vc){ + vc.extends({ + data:{ + questionValueInfo:{ + values:[], + titleId:'', + objType:'', + objId:'' + } + }, + _initMethod:function(){ + + }, + _initEvent:function(){ + vc.on('questionValue','openQuestionValueModel',function(_param){ + $that.questionValueInfo.titleId = _param.titleId; + $that.questionValueInfo.objType = _param.objType; + $that.questionValueInfo.objId = _param.objId; + $('#questionValueModel').modal('show'); + vc.component._loadAllValueInfo(1,10); + }); + vc.on('questionValue','paginationPlus', 'page_event', function (_currentPage) { + vc.component._loadAllValueInfo(_currentPage, 15,vc.component.questionValueInfo._currentRoomNum); + }); + }, + methods:{ + _loadAllValueInfo:function(_page,_row,_roomNum){ + + var param = { + params:{ + page:_page, + row:_row, + + } + }; + + //发送get请求 + vc.http.get('questionValue', + 'listRoom', + param, + function(json){ + var _roomInfo = JSON.parse(json); + vc.component.questionValueInfo.values = _roomInfo.rooms; + vc.emit('questionValue','paginationPlus', 'init', { + total: _roomInfo.records, + currentPage: _page + }); + },function(){ + console.log('请求失败处理'); + } + ); + }, + questionValues:function(){ + vc.component._loadAllRoomInfo(1,15,vc.component.questionValueInfo._currentRoomNum); + }, + + } + + }); +})(window.vc); \ No newline at end of file diff --git a/public/pages/property/questionAnswerTitleManage/questionAnswerTitleManage.html b/public/pages/property/questionAnswerTitleManage/questionAnswerTitleManage.html index 9a54ce0a9..3e0312f38 100755 --- a/public/pages/property/questionAnswerTitleManage/questionAnswerTitleManage.html +++ b/public/pages/property/questionAnswerTitleManage/questionAnswerTitleManage.html @@ -79,6 +79,10 @@ {{questionAnswerTitle.qaTitle}} {{questionAnswerTitle.seq}} +
+ +
@@ -111,5 +115,6 @@ +
\ No newline at end of file diff --git a/public/pages/property/questionAnswerTitleManage/questionAnswerTitleManage.js b/public/pages/property/questionAnswerTitleManage/questionAnswerTitleManage.js index 2cba0ae44..fcbcc51f2 100755 --- a/public/pages/property/questionAnswerTitleManage/questionAnswerTitleManage.js +++ b/public/pages/property/questionAnswerTitleManage/questionAnswerTitleManage.js @@ -101,6 +101,9 @@ }else{ return '简答'; } + }, + _openQuestionValueModel:function(_questionAnswerTitle){ + vc.emit('questionValue','openQuestionValueModel',_questionAnswerTitle); }