master
chen 2022-07-27 18:05:21 +08:00
parent fa45a3be71
commit 781c4dfdc7
4 changed files with 28 additions and 11 deletions

View File

@ -243,7 +243,12 @@
// const socket = io('http://7and5.cn:2120', {
// transports: [ 'websocket']
// });
const socket = io('http://7and5.cn:2120', {
// const socket = io('http://7and5.cn:2120', {
// query: {},
// transports: [ 'websocket', 'polling' ],
// timeout: 5000,
// });
var socket = io("ws://7and5.cn:2120",{
query: {},
transports: [ 'websocket', 'polling' ],
timeout: 5000,
@ -314,7 +319,7 @@
],
//
stayWorkOrderList:[
{imgsrc:'/static/public/icon-home-stayImplement.png',title:'待受理',num:0,id:0},
// {imgsrc:'/static/public/icon-home-stayImplement.png',title:'',num:0,id:0},
{imgsrc:'/static/public/icon-home-stayAssign.png',title:'待指派',num:0,id:1},
{imgsrc:'/static/public/icon-home-stayRepair.png',title:'待维保',num:0,id:3},
{imgsrc:'/static/public/icon-home-returnVisit.png',title:'待回访',num:0,id:8},
@ -413,9 +418,21 @@
change(){
this.uid++;
socket.io.disconnect();
this.connectEv();
},
connectEv(){
socket.on('connecting', function() {
console.log("正在连接");
});
socket.on('reconnect', function() {
console.log("重新连接到服务器");
});
socket.on('connect_failed', function() {
console.log("连接失败");
});
socket.on('reconnecting', function() {
console.log("正在重连");
});
},
// uniapp
openSettings() {
@ -451,9 +468,9 @@
//
case 3:
//
this.stayWorkOrderList[1].num = homeObj.pending_designate_count;
this.stayWorkOrderList[2].num = homeObj.pending_repair_count;
this.stayWorkOrderList[3].num = homeObj.pending_return_visit_count;
this.stayWorkOrderList[0].num = homeObj.pending_designate_count;
this.stayWorkOrderList[1].num = homeObj.pending_repair_count;
this.stayWorkOrderList[2].num = homeObj.pending_return_visit_count;
//
this.stayEventList[0].num = homeObj.approval_count;
this.stayEventList[1].num = homeObj.pending_payment_count;

View File

@ -6,7 +6,7 @@
<view class="opinion-type">意见类型</view>
<view class="opinion-type-content">
<view class="li" @click="opinionType(index)" :class="typeNum==index ? 'on':''"
v-for="(item,index) in typeData">{{item.title}}</view>
v-for="(item,index) in typeData" :key="index">{{item.title}}</view>
</view>
<view class="feedback-input">
<input type="text" v-model="opinion" class="inputCss" placeholder="请填写您的意见或建议内容"

View File

@ -9,7 +9,7 @@
<view class="xian"></view>
</view>
<view class="peopleManagement-content pad-x50">
<view class="li" v-for="(item,index) in dataList">
<view class="li" v-for="(item,index) in dataList" :key="index">
<view class="head">
<view class="name">
<view class="" v-if="order_id" @click="listStateFun(item)">
@ -30,8 +30,8 @@
<view class="code">
<view class="">编号: {{item.number}}</view>
<view class="iconCon">
<view v-for="(item1,index) in 5">
<image class="icon" v-if="index < item.starlevel*1" src="../../static/iocn/6.png" mode="aspectFill" ></image>
<view v-for="(item1,index1) in 5" :key="index1">
<image class="icon" v-if="index1 < item.rate" src="../../static/iocn/6.png" mode="aspectFill" ></image>
<image class="icon" v-else src="../../static/iocn/7.png" mode="aspectFill" ></image>
</view>
</view>

View File

@ -50,7 +50,7 @@
<image class="img flexs" src="../../static/iocn/im.png" mode="scaleToFill" lazy-load></image>
<view class="text scal09" style="margin-left: -26rpx;">{{item.address}}</view>
</view>
<view class="date scal09 flexs">{{item.joint_starting_times}}</view>
<view class="date scal09 flexs" v-if="item.joint_starting_times">{{item.joint_starting_times.slice(0,10)}}</view>
</view>
<view v-if="item.warranty_time==1" class="icon iconBera"></view>
<view v-else class="icon iconBer">质保到期</view>