修复状态不对问题

This commit is contained in:
java110 2021-03-26 12:23:27 +08:00
parent 4e469f47a2
commit f01d8d42af
6 changed files with 99 additions and 91 deletions

8
app.js
View File

@ -36,11 +36,11 @@ let opts = {
//app.use('/callComponent',proxy('http://api.demo.winqi.cn:8012',opts));
//app.use('/callComponent',proxy('http://api.demo.winqi.cn:8012',opts));
//app.use('/app',proxy('http://api.demo.winqi.cn:8012',opts));
app.use('/callComponent',proxy('http://api.demo.winqi.cn:8012',opts));
app.use('/app',proxy('http://api.demo.winqi.cn:8012',opts));
app.use('/callComponent',proxy('http://127.0.0.1:8012',opts));
app.use('/app',proxy('http://127.0.0.1:8012',opts));
//app.use('/callComponent',proxy('http://127.0.0.1:8012',opts));
//app.use('/app',proxy('http://127.0.0.1:8012',opts));
//app.use('/callComponent',proxy('http://192.168.1.16:8012',opts));
//app.use('/app',proxy('http://192.168.1.16:8012',opts));

View File

@ -53,8 +53,8 @@
<div class="col-sm-3" v-if="complaintManageInfo.moreCondition == true">
<select class="custom-select" v-model="complaintManageInfo.conditions.state">
<option selected value="">请选择投诉状态</option>
<option value="1100">派单</option>
<option value="1200">结单</option>
<option value="10001">处理中</option>
<option value="10002">处理完成</option>
</select></div>
<div class="col-sm-1">
</div>

View File

@ -47,9 +47,9 @@
<div class="col-sm-4" v-if="myRepairDispatchInfo.moreCondition == true">
<select class="custom-select" v-model="myRepairDispatchInfo.conditions.state">
<option selected value="">请选择报修状态</option>
<option value="1000">未派单</option>
<option value="1100">处理中</option>
<option value="1200">处理完成</option>
<option v-for="(item,index) in myRepairDispatchInfo.states" :value="item.statusCd">
{{item.name}}
</option>
</select>
</div>
</div>

View File

@ -1,132 +1,136 @@
/**
入驻小区
**/
(function(vc){
(function (vc) {
var DEFAULT_PAGE = 1;
var DEFAULT_ROWS = 10;
vc.extends({
data:{
myRepairDispatchInfo:{
ownerRepairs:[],
total:0,
records:1,
moreCondition:false,
repairName:'',
currentRepairId:'',
conditions:{
pageFlag:'myRepairDispatch',
repairId:'',
repairName:'',
tel:'',
repairType:'',
roomId:'',
roomName:'',
ownerId:'',
state:''
data: {
myRepairDispatchInfo: {
ownerRepairs: [],
total: 0,
records: 1,
moreCondition: false,
repairName: '',
currentRepairId: '',
states: [],
conditions: {
pageFlag: 'myRepairDispatch',
repairId: '',
repairName: '',
tel: '',
repairType: '',
roomId: '',
roomName: '',
ownerId: '',
state: ''
}
}
},
_initMethod:function(){
_initMethod: function () {
vc.getDict('r_repair_pool', "state", function (_data) {
vc.component.myRepairDispatchInfo.states = _data;
});
vc.component._listOwnerRepairs(DEFAULT_PAGE, DEFAULT_ROWS);
},
_initEvent:function(){
vc.on('myRepairDispatch','listOwnerRepair',function(_param){
vc.component._listOwnerRepairs(DEFAULT_PAGE, DEFAULT_ROWS);
_initEvent: function () {
vc.on('myRepairDispatch', 'listOwnerRepair', function (_param) {
vc.component._listOwnerRepairs(DEFAULT_PAGE, DEFAULT_ROWS);
});
vc.on('pagination','page_event',function(_currentPage){
vc.component._listOwnerRepairs(_currentPage,DEFAULT_ROWS);
vc.on('pagination', 'page_event', function (_currentPage) {
vc.component._listOwnerRepairs(_currentPage, DEFAULT_ROWS);
});
vc.on('myRepairDispatch','notifyData',function(_param){
vc.on('myRepairDispatch', 'notifyData', function (_param) {
vc.component._closeRepairDispatchOrder(_param);
});
},
methods:{
methods: {
_listOwnerRepairs:function(_page, _rows){
_listOwnerRepairs: function (_page, _rows) {
vc.component.myRepairDispatchInfo.conditions.page = _page;
vc.component.myRepairDispatchInfo.conditions.row = _rows;
vc.component.myRepairDispatchInfo.conditions.communityId = vc.getCurrentCommunity().communityId;
var param = {
params:vc.component.myRepairDispatchInfo.conditions
};
params: vc.component.myRepairDispatchInfo.conditions
};
//发送get请求
vc.http.apiGet('ownerRepair.listStaffFinishRepairs',
param,
function(json,res){
var _myRepairDispatchInfo=JSON.parse(json);
vc.component.myRepairDispatchInfo.total = _myRepairDispatchInfo.total;
vc.component.myRepairDispatchInfo.records = _myRepairDispatchInfo.records;
vc.component.myRepairDispatchInfo.ownerRepairs = _myRepairDispatchInfo.data;
vc.emit('pagination','init',{
total:vc.component.myRepairDispatchInfo.records,
currentPage:_page
});
},function(errInfo,error){
console.log('请求失败处理');
}
);
//发送get请求
vc.http.apiGet('ownerRepair.listStaffFinishRepairs',
param,
function (json, res) {
var _myRepairDispatchInfo = JSON.parse(json);
vc.component.myRepairDispatchInfo.total = _myRepairDispatchInfo.total;
vc.component.myRepairDispatchInfo.records = _myRepairDispatchInfo.records;
vc.component.myRepairDispatchInfo.ownerRepairs = _myRepairDispatchInfo.data;
vc.emit('pagination', 'init', {
total: vc.component.myRepairDispatchInfo.records,
currentPage: _page
});
}, function (errInfo, error) {
console.log('请求失败处理');
}
);
},
_openDealRepair:function(_ownerRepair){
_openDealRepair: function (_ownerRepair) {
vc.component.myRepairDispatchInfo.currentRepairId = _ownerRepair.repairId;
vc.emit('closeOrder','openCloseOrderModal',{});
vc.emit('closeOrder', 'openCloseOrderModal', {});
},
_moreCondition:function(){
if(vc.component.myRepairDispatchInfo.moreCondition){
_moreCondition: function () {
if (vc.component.myRepairDispatchInfo.moreCondition) {
vc.component.myRepairDispatchInfo.moreCondition = false;
}else{
} else {
vc.component.myRepairDispatchInfo.moreCondition = true;
}
},
_openRepairDetail: function (_repairPool) {
vc.jumpToPage('/admin.html#/pages/property/ownerRepairDetail?repairId=' + _repairPool.repairId)
},
_closeRepairDispatchOrder:function(_orderInfo){
_closeRepairDispatchOrder: function (_orderInfo) {
var _repairDispatchParam = {
repairId:vc.component.myRepairDispatchInfo.currentRepairId,
context:_orderInfo.remark,
communityId:vc.getCurrentCommunity().communityId
repairId: vc.component.myRepairDispatchInfo.currentRepairId,
context: _orderInfo.remark,
communityId: vc.getCurrentCommunity().communityId
};
if(_orderInfo.state == '1100'){
if (_orderInfo.state == '1100') {
_repairDispatchParam.state = '10002';
}else{
} else {
_repairDispatchParam.state = '10003';
}
vc.http.post(
'myRepairDispatch',
'closeOrder',
JSON.stringify(_repairDispatchParam),
{
emulateJSON:true
vc.http.post(
'myRepairDispatch',
'closeOrder',
JSON.stringify(_repairDispatchParam),
{
emulateJSON: true
},
function(json,res){
//vm.menus = vm.refreshMenuActive(JSON.parse(json),0);
if(res.status == 200){
//关闭model
vc.component._listOwnerRepairs(DEFAULT_PAGE, DEFAULT_ROWS);
return ;
}
vc.toast(json);
function (json, res) {
//vm.menus = vm.refreshMenuActive(JSON.parse(json),0);
if (res.status == 200) {
//关闭model
vc.component._listOwnerRepairs(DEFAULT_PAGE, DEFAULT_ROWS);
return;
}
vc.toast(json);
},
function(errInfo,error){
console.log('请求失败处理');
function (errInfo, error) {
console.log('请求失败处理');
vc.toast(errInfo);
vc.toast(errInfo);
});
},
_openDispatchRepairDetail:function(_ownerRepair){
vc.emit('ownerRepairDetail','openOwnerRepairDetailModal',_ownerRepair);
_openDispatchRepairDetail: function (_ownerRepair) {
vc.emit('ownerRepairDetail', 'openOwnerRepairDetailModal', _ownerRepair);
},
_queryMyRepairDispatchMethod:function(){
_queryMyRepairDispatchMethod: function () {
vc.component._listOwnerRepairs(DEFAULT_PAGE, DEFAULT_ROWS);
}
}
});
})(window.vc);

View File

@ -49,9 +49,9 @@
<div class="col-sm-4" v-if="repairDispatchManageInfo.moreCondition == true">
<select class="custom-select" v-model="repairDispatchManageInfo.conditions.state">
<option selected value="">请选择报修状态</option>
<option value="1000">未派单</option>
<option value="1100">处理中</option>
<option value="1200">处理完成</option>
<option v-for="(item,index) in repairDispatchManageInfo.states" :value="item.statusCd">
{{item.name}}
</option>
</select>
</div>
</div>

View File

@ -12,6 +12,7 @@
records: 1,
moreCondition: false,
repairName: '',
states: [],
conditions: {
repairId: '',
repairName: '',
@ -25,6 +26,9 @@
}
},
_initMethod: function () {
vc.getDict('r_repair_pool', "state", function (_data) {
vc.component.repairDispatchManageInfo.states = _data;
});
vc.component._listOwnerRepairs(DEFAULT_PAGE, DEFAULT_ROWS);
//vc.component._validateParam();
},