Compare commits

...

2 Commits

14 changed files with 745 additions and 202 deletions

View File

@ -8,7 +8,7 @@
}" }"
> >
<!-- 有的不支持canvas-id属性必须用id属性 --> <!-- 有的不支持canvas-id属性必须用id属性 -->
<canvas <canvas v-if="canvasId"
class="canvas-bg" class="canvas-bg"
:canvas-id="canvasId" :canvas-id="canvasId"
:id="canvasId" :id="canvasId"
@ -17,7 +17,7 @@
height: widthPx + 'px' height: widthPx + 'px'
}" }"
></canvas> ></canvas>
<canvas <canvas v-if="elId"
class="canvas" class="canvas"
:canvas-id="elId" :canvas-id="elId"
:id="elId" :id="elId"

107
components/city/city.css Normal file
View File

@ -0,0 +1,107 @@
.lotus-address-picker {
font-size: 26rpx;
padding-top: 30rpx;
overflow: hidden;
text-overflow: ellipsis;
display: -webkit-box;
-webkit-line-clamp: 1;
-webkit-box-orient: vertical;
line-height: normal;
padding-right: 30rpx;
box-sizing: border-box;
}
.lotus-address-picker-box {
/*display: -webkit-box;
display: -webkit-flex;*/
display: flex;
align-items: center;
justify-content: center;
justify-content: flex-start;
padding-top: 10rpx;
padding-bottom: 10rpx;
}
.lotus-address-picker-box-item {
height: 600upx;
overflow-y: auto;
width: 33.333%;
padding-left: 20rpx;
padding-right: 20rpx;
box-sizing: border-box;
}
.lotus-address-picker2 {
color: #03affb;
position: relative;
}
.lotus-address-picker2:after {
content: '';
position: absolute;
right: 0;
top: 65%;
transform: translateY(-35%) rotate(-45deg);
width: 20rpx;
height: 10rpx;
border-left-width: 4rpx;
border-bottom-width: 4rpx;
border-left-style: solid;
border-bottom-style: solid;
border-left-color: #03affb;
border-bottom-color: #03affb;
}
.lotus-address-mask {
position: fixed;
left: 0;
top: 0;
width: 100%;
height: 100%;
z-index: 999;
background: rgba(0, 0, 0, 0.5);
}
.lotus-address-box {
background: #fff;
position: absolute;
left: 0;
bottom: 0;
width: 100%;
height: auto;
}
.lotus-address-action {
font-size: 30rpx;
/*display: -webkit-box;
display: -webkit-flex;*/
display: flex;
align-items: center;
justify-content: center;
justify-content: space-between;
padding: 25rpx 30rpx;
position: relative;
}
.lotus-address-action:after {
content: " ";
position: absolute;
left: 0;
top: 0;
right: 0;
height: 1px;
border-top: 1px solid #eee;
color: #eee;
transform-origin: 0 0;
transform: scaleY(0.5);
}
.lotus-address-action:before {
content: " ";
position: absolute;
left: 0;
bottom: 0;
right: 0;
height: 1px;
border-bottom: 1px solid #eee;
color: #eee;
transform-origin: 0 100%;
transform: scaleY(0.5);
}
.lotus-address-action-cancel {
color: #969696;
}
.lotus-address-action-affirm {
color: #03affb;
}

1
components/city/city.js Normal file

File diff suppressed because one or more lines are too long

233
components/city/city.vue Normal file
View File

@ -0,0 +1,233 @@
<template>
<!--地址picker-->
<view :status="checkStatus" v-if="lotusAddressData.visible" class="lotus-address-mask">
<view :class="lotusAddressData.visible?'lotus-address-box':'lotus-address-box lotus-address-box-out'">
<view class="lotus-address-action">
<text @tap="cancelPicker" class="lotus-address-action-cancel">取消</text>
<text @tap="chosedVal" class="lotus-address-action-affirm">确认</text>
</view>
<view class="lotus-address-picker-box">
<!---->
<scroll-view scroll-y :scroll-into-view="'pid'+pChoseIndex" class="lotus-address-picker-box-item">
<view @tap="clickPicker(0,pIndex,pItem);" :id="'pid'+pIndex" :class="pIndex === pChoseIndex?'lotus-address-picker lotus-address-picker2':'lotus-address-picker'" v-for="(pItem,pIndex) in province" :key="pIndex">{{pItem}}</view>
</scroll-view>
<!---->
<scroll-view scroll-y :scroll-into-view="'cid'+cChoseIndex" class="lotus-address-picker-box-item">
<view @tap="clickPicker(1,cIndex,cItem);" :id="'cid'+cIndex" :class="cIndex === cChoseIndex?'lotus-address-picker lotus-address-picker2':'lotus-address-picker'" v-for="(cItem,cIndex) in city" :key="cIndex">{{cItem}}</view>
</scroll-view>
<!---->
<scroll-view scroll-y :scroll-into-view="'tid'+tChoseIndex" class="lotus-address-picker-box-item">
<view @tap="clickPicker(2,tIndex,tItem);" :id="'tid'+tIndex" :class="tIndex === tChoseIndex?'lotus-address-picker lotus-address-picker2':'lotus-address-picker'" v-for="(tItem,tIndex) in town" :key="tIndex">{{tItem}}</view>
</scroll-view>
<!--区END-->
</view>
</view>
</view>
<!--地址picker END-->
</template>
<script>
import {lotusAddressJson} from "./city.js";
export default {
props:['lotusAddressData'],
data() {
return {
visible: false,
province:[],
city:[],
town:[],
provinceName:'',
cityName:'',
townName:'',
type:0,//01
pChoseIndex:-1,
cChoseIndex:-1,
tChoseIndex:-1
};
},
methods:{
//
cancelPicker(){
const provinceCode = this.getTarId(this.provinceName);
const cityCode = this.getTarId(this.cityName);
const townCode = this.getTarId(this.townName);
this.visible = false;
this.$emit("choseVal",{
province:this.provinceName,
provinceCode,
city:this.cityName,
cityCode,
town:this.townName,
townCode,
isChose:0,
visible:false
});
},
//
chosedVal() {
this.type = 1;
const provinceCode = this.getTarId(this.provinceName);
const cityCode = this.getTarId(this.cityName);
const townCode = this.getTarId(this.townName);
this.visible = false;
let isChose = 0;
// isChose = 1
if((this.provinceName&&this.cityName)||(this.provinceName&&this.cityName&&this.townName)){
isChose = 1;
}
this.$emit("choseVal",{
province:this.provinceName,
provinceCode,
city:this.cityName,
cityCode,
town:this.townName,
townCode,
isChose,
visible:false
});
},
//value
getTarId(name,type){
let id = 0;
lotusAddressJson.map((item,index)=>{
if(item.name === name){
id = item.value;
}
});
return id;
},
//
getCityArr(parentId){
let city = [];
lotusAddressJson.map((item,index)=>{
if(item.parent === parentId){
city.push(item.name);
}
});
return city;
},
//
getTownArr(parentId){
let town = [];
lotusAddressJson.map((item,index)=>{
if(index>34&&item.parent === parentId){
town.push(item.name);
}
});
return town;
},
//
initFn(){
if(!this.province.length){
lotusAddressJson.map((item,index)=>{
if(index<=34){
this.province.push(item.name);
}
});
}
//
const p = this._props.lotusAddressData.provinceName;
const c = this._props.lotusAddressData.cityName;
const t = this._props.lotusAddressData.townName;
//
if(p){
this.pChoseIndex = this.getTarIndex(this.province,p);
}
//
if(p&&c){
const pid = this.getTarId(p);
this.city = this.getCityArr(pid);
this.cChoseIndex = this.getTarIndex(this.city,c);
}
//
if(p&&c&&t){
const cid= this.getTarId(c);
this.town = this.getTownArr(cid);
this.tChoseIndex = this.getTarIndex(this.town,t);
}
//
if(!p&&!c&&!t){
this.pChoseIndex = -1;
this.cChoseIndex = -1;
this.tChoseIndex = -1;
this.city = [];
this.town = [];
}
},
//
getChosedData(){
const pid = this.getTarId(this.provinceName,'province');
this.city = this.getCityArr(pid);
const cid= this.getTarId(this.cityName,'city');
this.town = this.getTownArr(cid);
//index
if(this.provinceName){
this.pChoseIndex = this.getTarIndex(this.province,this.provinceName);
}
if(this.cityName){
this.cChoseIndex = this.getTarIndex(this.city,this.cityName);
}
if(this.townName){
this.tChoseIndex = this.getTarIndex(this.town,this.townName);
}
},
//
clickPicker(type,index,name){
//
if(type === 0){
this.pChoseIndex = index;
this.provinceName = name;
this.cChoseIndex = -1;
this.tChoseIndex = -1;
this.cityName = '';
this.townName = '';
}
//
if(type ===1){
this.cChoseIndex = index;
this.cityName = name;
this.tChoseIndex = -1;
this.townName = '';
}
//
if(type === 2){
this.tChoseIndex = index;
this.townName = name;
}
//
this.getChosedData();
},
//index
getTarIndex(arr,tarName){
let cIndex = 0;
arr.map((item,index)=>{
if(item === tarName){
cIndex = index;
}
});
return cIndex;
}
},
computed:{
checkStatus(){
let t = null;
const _this = this;
if(!_this.visible){
_this.visible = _this._props.lotusAddressData.visible;
//
_this.provinceName = _this._props.lotusAddressData.provinceName;
_this.cityName = _this._props.lotusAddressData.cityName;
_this.townName = _this._props.lotusAddressData.townName;
//
_this.initFn();
t = _this.visible;
}
return t;
}
}
}
</script>
<style lang="less">
@import "./city.css";
</style>

View File

@ -356,14 +356,14 @@ moreColor:显示更多的颜色
} }
.loopItemBaseShow { .loopItemBaseShow {
position: absolute;
top: 0; top: 0;
left: 0; left: 0;
width: 100%; width: 100%;
height: 100%; // height: 100%;
overflow: hidden; overflow: hidden;
font-size: 28rpx; font-size: 28rpx;
text-align: left; text-align: left;
position: absolute;
white-space: nowrap; white-space: nowrap;
align-items: center; align-items: center;
text-overflow: ellipsis; text-overflow: ellipsis;

View File

@ -69,6 +69,16 @@ const tools = {
// return false // return false
return !reg_tel.test(phone); return !reg_tel.test(phone);
}, },
// 电子邮箱验证
isEmail(email){
let reg_email = /^\w+([-+.]\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*$/;
return !reg_email.test(email);
},
// 身份证验证
isIdentity(identity) {
let reg_identity = /(^\d{15}$)|(^\d{18}$)|(^\d{17}(\d|X|x)$)/;
return !reg_identity.test(identity);
},
// 手机号中间四位用"****"带替 // 手机号中间四位用"****"带替
hideMPhone(phone){ hideMPhone(phone){
return `${phone.substr(0, 3)}****${phone.substr(7)}` return `${phone.substr(0, 3)}****${phone.substr(7)}`

View File

@ -105,7 +105,16 @@
] ]
} }
}, },
onLoad() {
this.checkFeedback();
},
methods: { methods: {
//
checkFeedback(){
this.$requst.get('/universal/api.feedback/feedback_type',{page:1,list_rows:20}).then(res=>{
})
},
opinionType(index) { opinionType(index) {
for (var i = 0; i < this.typeData.length; i++) { for (var i = 0; i < this.typeData.length; i++) {
this.typeData[i].state = false this.typeData[i].state = false

View File

@ -1,14 +1,11 @@
<template> <template>
<view class="content" :style="{paddingTop: statusHeight+25 + 'px'}"> <view class="content" :style="{paddingTop: statusHeight + 'px'}">
<statusNav navBarTitle="项目列表" :ifReturn="false"></statusNav> <statusNav navBarTitle="项目列表" :ifReturn="false"></statusNav>
<container-subgroup-two> <container-subgroup-two>
<view slot="content" style="margin: -100rpx -30rpx 0rpx; "> <view slot="content" style="margin: -100rpx -30rpx;">
<view class="project-list-input">
<view class="project-list-input" :style="{top: statusHeight + 'px'}">
<input type="text" class="int" value="" placeholder="请输入关键字" /> <input type="text" class="int" value="" placeholder="请输入关键字" />
<view class="xian"> <view class="xian"></view>
</view>
<image class="search" src="../../static/iocn/ss.png" mode="aspectFill" lazy-load></image> <image class="search" src="../../static/iocn/ss.png" mode="aspectFill" lazy-load></image>
</view> </view>
<view class="screen bbot mar-sx20"> <view class="screen bbot mar-sx20">
@ -79,7 +76,6 @@
format: true format: true
}) })
return { return {
statusBarHeight:uni.getSystemInfoSync().statusBarHeight+40,
date: currentDate, date: currentDate,
array: ['类型', '类型', '类型', '类型'], array: ['类型', '类型', '类型', '类型'],
index: 0, index: 0,
@ -128,8 +124,6 @@
height: 114rpx; height: 114rpx;
position: relative; position: relative;
padding: 20rpx 16rpx; padding: 20rpx 16rpx;
position: fixed;
z-index: 2;
box-sizing: border-box; box-sizing: border-box;
background-color: #FFFFFF background-color: #FFFFFF
} }

View File

@ -4,7 +4,15 @@
<!-- <view slot="leftContent"><i class="icon icon-return fon40" :style="{color:newColor}"></i></view> --> <!-- <view slot="leftContent"><i class="icon icon-return fon40" :style="{color:newColor}"></i></view> -->
<view slot="leftContent" style="width: 30rpx;"></view> <view slot="leftContent" style="width: 30rpx;"></view>
<view slot="centerContent"><view :style="{color:newColor}">个人中心</view></view> <view slot="centerContent"><view :style="{color:newColor}">个人中心</view></view>
<view slot="rightContent" @tap="goSetUp"><i class="icon icon-sandian fon40" :style="{color:newColor}"></i></view> <!-- #ifdef APP-PLUS -->
<view slot="rightContent" @tap="goSetUp"><i class="icon icon-sandian fon40" :style="{color:newColor}"></i></view>
<!-- #endif -->
<!-- #ifdef H5 -->
<view slot="rightContent" @tap="goSetUp"><i class="icon icon-sandian fon40" :style="{color:newColor}"></i></view>
<!-- #endif -->
<!-- #ifdef MP-WEIXIN -->
<view slot="rightContent" style="width: 30rpx;"></view>
<!-- #endif -->
</status-nav-slot> </status-nav-slot>
<view class="posir" style="background: url(/static/public/icon-my-logo.png) no-repeat;background-size: 100% auto;" :style="{paddingTop: newHeight + 'px'}"> <view class="posir" style="background: url(/static/public/icon-my-logo.png) no-repeat;background-size: 100% auto;" :style="{paddingTop: newHeight + 'px'}">
<!-- <image src="/static/public/icon-my-logo.png" class="width100" mode="widthFix" lazy-load></image> --> <!-- <image src="/static/public/icon-my-logo.png" class="width100" mode="widthFix" lazy-load></image> -->
@ -38,7 +46,7 @@
<arprogress :percent="item.num" <arprogress :percent="item.num"
:inactiveColor="['#c6e6f5','#f4dfc6','#c8d7f5'][index]" :inactiveColor="['#c6e6f5','#f4dfc6','#c8d7f5'][index]"
:activeColor="['#00a2e9','#e87c00','#0b56ec'][index]" :activeColor="['#00a2e9','#e87c00','#0b56ec'][index]"
:borderWidth="7.8" :borderWidth="7.8"
:width="120" :width="120"
:duration="500" :duration="500"
bgColor="transparent"><text :style="{color: ['#00a2e9','#e87c00','#0b56ec'][index]}">{{item.num}}%</text></arprogress> bgColor="transparent"><text :style="{color: ['#00a2e9','#e87c00','#0b56ec'][index]}">{{item.num}}%</text></arprogress>

View File

@ -1,5 +1,5 @@
<template> <template>
<view class="pad-x160"> <view class="pad-x50">
<status-nav-slot> <status-nav-slot>
<view slot="leftContent" @tap="goMessage" style="width: 70px;"> <view slot="leftContent" @tap="goMessage" style="width: 70px;">
<view class="home-message-box posir disac"> <view class="home-message-box posir disac">
@ -10,201 +10,214 @@
<view slot="centerContent" class="disjcac"> <view slot="centerContent" class="disjcac">
<image style="width: 156rpx;height: 38rpx;" src="/static/public/icom-home-logo.png" mode="widthFix"></image> <image style="width: 156rpx;height: 38rpx;" src="/static/public/icom-home-logo.png" mode="widthFix"></image>
</view> </view>
<!-- #ifdef APP-PLUS -->
<view slot="rightContent" class="disac" @tap="callEv"> <view slot="rightContent" class="disac" @tap="callEv">
<image class="mar-y10" style="width: 26rpx;height: 26rpx;" src="/static/public/icon-home-phone.png" mode=""></image> <image class="mar-y10" style="width: 26rpx;height: 26rpx;" src="/static/public/icon-home-phone.png" mode=""></image>
<view class="fon26 col3">拨打电话</view> <view class="fon26 col3">拨打电话</view>
</view> </view>
<!-- #endif -->
<!-- #ifdef H5 -->
<view slot="rightContent" class="disac" @tap="callEv">
<image class="mar-y10" style="width: 26rpx;height: 26rpx;" src="/static/public/icon-home-phone.png" mode=""></image>
<view class="fon26 col3">拨打电话</view>
</view>
<!-- #endif -->
<!-- #ifdef MP-WEIXIN -->
<view slot="rightContent" @tap="goMessage" style="width: 70px;"></view>
<!-- #endif -->
</status-nav-slot> </status-nav-slot>
<!-- <view :style="{paddingTop: statusHeight +'px'}"> --> <!-- <view :style="{paddingTop: statusHeight +'px'}"> -->
<!-- banner图 --> <!-- banner图 -->
<image class="width100" src="/static/public/icon-home-banner.png" mode="widthFix"></image> <container-subgroup-two>
<view class="pad-zy20"> <view slot="content" style="margin: 0 -30rpx;">
<!-- 项目总数实时故障公告 --> <image class="width100" src="/static/public/icon-home-banner.png" mode="widthFix"></image>
<view class="project-notice-box"> <view class="pad-zy20">
<view class="disjcac pad-sx20 bbot"> <!-- 项目总数实时故障公告 -->
<view class="disjcac fc width50"> <view class="project-notice-box">
<view class="fon26 col9">项目总数</view> <view class="disjcac pad-sx20 bbot">
<view class="fon60 bold">126</view> <view class="disjcac fc width50">
</view> <view class="fon26 col9">项目总数</view>
<view class="bleft" style="height: 90rpx;"></view> <view class="fon60 bold">126</view>
<view class="disjcac fc width50">
<view class="fon26 col9">实时故障</view>
<view class="fon60 bold">116</view>
</view>
</view>
<view class="disac pad-s30 pad-x10">
<image class="mar-zy20" style="width: 64rpx;height: 27rpx;" src="/static/public/icon-home-notice.png" mode=""></image>
<view class="fon24 color6 mar-y20 width100 bleft pad-z20">
<lwNotice @dangGao="goNoticeDetail" :list="noticeList" :backgroundColor="'#FFFFFF'"></lwNotice>
</view>
<!-- <view class="clips1 col3 fon24 pad-z20 bleft">2021年11月06日公司团建维修服务暂停一天</view> -->
</view>
</view>
<!-- 客户可见 -->
<view v-if="role==2 || role==1">
<!-- 故障报修 -->
<view class="home-fun-box">
<view class="fun-title col3 fon28 disac bold">故障报修</view>
<view class="disac mar-s30">
<view @tap="goFaultRepair(index)" class="disjcac fc width25" v-for="(item,index) in repairList" :key="index">
<image :style="{width: [58,58,50][index]+'rpx',height:[53,56,58][index] + 'rpx'}" style="width: 58rpx;height: 53rpx;" :src="item.imgsrc" mode="widthFix"></image>
<view class="fon24 col3 mar-s10">{{item.title}}</view>
</view>
</view>
</view>
<!-- 数据查询 -->
<view class="home-fun-box" v-if="role==1">
<view class="fun-title col3 fon28 disac bold">数据查询</view>
<view class="disac mar-s30">
<view @tap="dataQueryEv(index)" class="disjcac fc width25" v-for="(item,index) in dataQueryList" :key="index">
<view class="posir">
<image :style="{width: [58,58,58][index]+'rpx',height:[46,56,50][index] + 'rpx'}" style="width: 58rpx;height: 53rpx;" :src="item.imgsrc" mode="widthFix"></image>
<view class="engineer-num" v-if="item.num!=0">{{item.num}}</view>
</view> </view>
<view class="fon24 col3 mar-s10">{{item.title}}</view> <view class="bleft" style="height: 90rpx;"></view>
</view> <view class="disjcac fc width50">
</view> <view class="fon26 col9">实时故障</view>
</view> <view class="fon60 bold">116</view>
<!-- 增值服务 --> </view>
<view class="home-fun-box"> </view>
<view class="fun-title col3 fon28 disac bold">增值服务</view> <view class="disac pad-s30 pad-x10">
<view class="disac mar-s30"> <image class="mar-zy20" style="width: 64rpx;height: 27rpx;" src="/static/public/icon-home-notice.png" mode=""></image>
<view @tap="goIncrement(index)" class="disjcac fc width25" v-for="(item,index) in incrementList" :key="index"> <view class="fon24 color6 mar-y20 width100 bleft pad-z20">
<image :style="{width: [57,52,58,51][index]+'rpx',height:[56,56,50,56][index] + 'rpx'}" style="width: 58rpx;height: 53rpx;" :src="item.imgsrc" mode="widthFix"></image> <lwNotice @dangGao="goNoticeDetail" :list="noticeList" :backgroundColor="'#FFFFFF'"></lwNotice>
<view class="fon24 col3 mar-s10">{{item.title}}</view>
</view>
</view>
</view>
</view>
<!-- 工程师可见 -->
<view v-if="role==4 || role==3">
<!-- 项目维修 -->
<view class="home-fun-box" v-if="role==4">
<view class="fun-title col3 fon28 disac bold">项目维修</view>
<view class="disac mar-s30">
<view class="disjcac fc width25" v-for="(item,index) in projectRepairList" :key="index">
<view class="posir">
<image :style="{width: [53,52,51][index]+'rpx',height:[58,58,58][index] + 'rpx'}" style="width: 58rpx;height: 53rpx;" :src="item.imgsrc" mode="widthFix"></image>
<view class="engineer-num" v-if="item.num!=0">{{item.num}}</view>
</view> </view>
<view class="fon24 col3 mar-s10">{{item.title}}</view>
</view> </view>
</view> </view>
</view> <!-- 客户可见 -->
<view v-if="role==3"> <view v-if="role==2 || role==1">
<!-- 待办工单 --> <!-- 故障报修 -->
<view class="home-fun-box"> <view class="home-fun-box">
<view class="fun-title col3 fon28 disac bold">待办工单</view> <view class="fun-title col3 fon28 disac bold">故障报修</view>
<view class="disac mar-s30"> <view class="disac mar-s30">
<view class="disjcac fc width25" v-for="(item,index) in stayWorkOrderList" :key="index"> <view @tap="goFaultRepair(index)" class="disjcac fc width25" v-for="(item,index) in repairList" :key="index">
<view class="posir"> <image :style="{width: [58,58,50][index]+'rpx',height:[53,56,58][index] + 'rpx'}" style="width: 58rpx;height: 53rpx;" :src="item.imgsrc" mode="widthFix"></image>
<image :style="{width: [53,48,51,58][index]+'rpx',height:[58,58,58,53][index] + 'rpx'}" style="width: 58rpx;height: 53rpx;" :src="item.imgsrc" mode="widthFix"></image> <view class="fon24 col3 mar-s10">{{item.title}}</view>
<view class="engineer-num" v-if="item.num!=0">{{item.num}}</view> </view>
</view>
</view>
<!-- 数据查询 -->
<view class="home-fun-box" v-if="role==1">
<view class="fun-title col3 fon28 disac bold">数据查询</view>
<view class="disac mar-s30">
<view @tap="dataQueryEv(index)" class="disjcac fc width25" v-for="(item,index) in dataQueryList" :key="index">
<view class="posir">
<image :style="{width: [58,58,58][index]+'rpx',height:[46,56,50][index] + 'rpx'}" style="width: 58rpx;height: 53rpx;" :src="item.imgsrc" mode="widthFix"></image>
<view class="engineer-num" v-if="item.num!=0">{{item.num}}</view>
</view>
<view class="fon24 col3 mar-s10">{{item.title}}</view>
</view>
</view>
</view>
<!-- 增值服务 -->
<view class="home-fun-box">
<view class="fun-title col3 fon28 disac bold">增值服务</view>
<view class="disac mar-s30">
<view @tap="goIncrement(index)" class="disjcac fc width25" v-for="(item,index) in incrementList" :key="index">
<image :style="{width: [57,52,58,51][index]+'rpx',height:[56,56,50,56][index] + 'rpx'}" style="width: 58rpx;height: 53rpx;" :src="item.imgsrc" mode="widthFix"></image>
<view class="fon24 col3 mar-s10">{{item.title}}</view>
</view> </view>
<view class="fon24 col3 mar-s10">{{item.title}}</view>
</view> </view>
</view> </view>
</view> </view>
<!-- 待办事件 --> <!-- 工程师可见 -->
<view class="home-fun-box"> <view v-if="role==4 || role==3">
<view class="fun-title col3 fon28 disac bold">待办事件</view> <!-- 项目维修 -->
<view class="disac mar-s30"> <view class="home-fun-box" v-if="role==4">
<view class="disjcac fc width25" v-for="(item,index) in stayEventList" :key="index"> <view class="fun-title col3 fon28 disac bold">项目维修</view>
<view class="posir"> <view class="disac mar-s30">
<image :style="{width: [58,58,50][index]+'rpx',height:[58,54,58][index] + 'rpx'}" style="width: 58rpx;height: 53rpx;" :src="item.imgsrc" mode="widthFix"></image> <view class="disjcac fc width25" v-for="(item,index) in projectRepairList" :key="index">
<view class="engineer-num" v-if="item.num!=0">{{item.num}}</view> <view class="posir">
<image :style="{width: [53,52,51][index]+'rpx',height:[58,58,58][index] + 'rpx'}" style="width: 58rpx;height: 53rpx;" :src="item.imgsrc" mode="widthFix"></image>
<view class="engineer-num" v-if="item.num!=0">{{item.num}}</view>
</view>
<view class="fon24 col3 mar-s10">{{item.title}}</view>
</view> </view>
</view>
</view>
<view v-if="role==3">
<!-- 待办工单 -->
<view class="home-fun-box">
<view class="fun-title col3 fon28 disac bold">待办工单</view>
<view class="disac mar-s30">
<view class="disjcac fc width25" v-for="(item,index) in stayWorkOrderList" :key="index">
<view class="posir">
<image :style="{width: [53,48,51,58][index]+'rpx',height:[58,58,58,53][index] + 'rpx'}" style="width: 58rpx;height: 53rpx;" :src="item.imgsrc" mode="widthFix"></image>
<view class="engineer-num" v-if="item.num!=0">{{item.num}}</view>
</view>
<view class="fon24 col3 mar-s10">{{item.title}}</view>
</view>
</view>
</view>
<!-- 待办事件 -->
<view class="home-fun-box">
<view class="fun-title col3 fon28 disac bold">待办事件</view>
<view class="disac mar-s30">
<view class="disjcac fc width25" v-for="(item,index) in stayEventList" :key="index">
<view class="posir">
<image :style="{width: [58,58,50][index]+'rpx',height:[58,54,58][index] + 'rpx'}" style="width: 58rpx;height: 53rpx;" :src="item.imgsrc" mode="widthFix"></image>
<view class="engineer-num" v-if="item.num!=0">{{item.num}}</view>
</view>
<view class="fon24 col3 mar-s10">{{item.title}}</view>
</view>
</view>
</view>
</view>
<!-- 工单数据 -->
<view class="home-fun-box">
<view class="fun-title col3 fon28 disac bold">工单数据</view>
<view class="disac mar-s30">
<view class="disjcac fc width25" @click="goWorkOrder(index)" v-for="(item,index) in workOrderList" :key="index">
<view class="posir">
<image :style="{width: [59,56,58,58][index]+'rpx',height:[49,58,58,60][index] + 'rpx'}" style="width: 58rpx;height: 53rpx;" :src="item.imgsrc" mode="widthFix"></image>
<view class="engineer-num" v-if="item.num!=0">{{item.num}}</view>
</view>
<view class="fon24 col3 mar-s10">{{item.title}}</view>
</view>
</view>
</view>
<!-- 数据查询 -->
<view class="home-fun-box" v-if="role==3">
<view class="fun-title col3 fon28 disac bold">数据查询</view>
<view class="disac mar-s30">
<view @tap="dataQueryEv(index)" class="disjcac fc width25" v-for="(item,index) in dataQueryList" :key="index">
<view class="posir">
<image :style="{width: [58,58,58][index]+'rpx',height:[46,56,50][index] + 'rpx'}" style="width: 58rpx;height: 53rpx;" :src="item.imgsrc" mode="widthFix"></image>
<view class="engineer-num" v-if="item.num!=0">{{item.num}}</view>
</view>
<view class="fon24 col3 mar-s10">{{item.title}}</view>
</view>
</view>
</view>
<!-- 结算情况 -->
<view class="home-fun-box" v-if="role==4">
<view class="fun-title col3 fon28 disac bold">结算情况</view>
<view class="disac mar-s30">
<view class="disjcac fc width25" v-for="(item,index) in settlementList" :key="index">
<view class="posir">
<image :style="{width: [58,50,58][index]+'rpx',height:[54,58,58][index] + 'rpx'}" style="width: 58rpx;height: 53rpx;" :src="item.imgsrc" mode="widthFix"></image>
<view class="engineer-num" v-if="item.num!=0">{{item.num}}</view>
</view>
<view class="fon24 col3 mar-s10">{{item.title}}</view>
</view>
</view>
</view>
</view>
<!-- 其他 -->
<view class="home-fun-box">
<view class="fun-title col3 fon28 disac bold">其他</view>
<view class="disac mar-s30">
<view @tap="otherEv(index)" class="disjcac fc width25" v-for="(item,index) in otherList" :key="index">
<image :style="{width: [58,49,58][index]+'rpx',height:[51,58,55][index] + 'rpx'}" style="width: 58rpx;height: 53rpx;" :src="item.imgsrc" mode="widthFix"></image>
<view class="fon24 col3 mar-s10">{{item.title}}</view> <view class="fon24 col3 mar-s10">{{item.title}}</view>
</view> </view>
</view> </view>
</view> </view>
</view> </view>
<!-- 工单数据 --> <!-- 解决方案 -->
<view class="home-fun-box"> <view class="home-solution mar-x20 pad30">
<view class="fun-title col3 fon28 disac bold">工单数据</view> <view class="disjbac" @tap="goPlant(0)">
<view class="disac mar-s30"> <view>
<view class="disjcac fc width25" @click="goWorkOrder(index)" v-for="(item,index) in workOrderList" :key="index"> <view class="fon30 bold" style="color: #00a2e9;">畅想智能-场景化设计</view>
<view class="posir"> <view class="fon34 bold col3 mar-s10">解决方案<text class="col9 mar-z10">Solution</text></view>
<image :style="{width: [59,56,58,58][index]+'rpx',height:[49,58,58,60][index] + 'rpx'}" style="width: 58rpx;height: 53rpx;" :src="item.imgsrc" mode="widthFix"></image> </view>
<view class="engineer-num" v-if="item.num!=0">{{item.num}}</view> <image style="width: 50rpx;height: 50rpx;" src="/static/public/icon-home-solution.png" mode=""></image>
</view>
<view class="mar-s30">
<scroll-view scroll-x>
<view :class="solutionList.length == 4 ? 'disjbac' : 'disac'">
<view @tap="goDetail(0,item.id)" class="posir flexs" v-for="(item,index) in solutionList" :key="index" style="width: 23%;height: 214rpx;" :style="{marginRight: solutionList.length != 4 ? '20rpx' : ''}">
<image style="width: 100%;height: 214rpx;" class="radius10 " :src="item.imgsrc" mode="widthFix"></image>
<view class="posia solution-title clips1">{{item.title}}</view>
</view>
</view> </view>
<view class="fon24 col3 mar-s10">{{item.title}}</view> </scroll-view>
</view>
</view> </view>
</view> </view>
<!-- 数据查询 --> <!-- 常见故障 -->
<view class="home-fun-box" v-if="role==3"> <view class="bacf mar-zy20 pad-sx30 pad-zy10 radius10">
<view class="fun-title col3 fon28 disac bold">数据查询</view> <view class="fon34 bold col3" @tap="goPlant(1)"><text class="col9 mar-z10">Common faults</text></view>
<view class="disac mar-s30"> <view @tap="goDetail(1,item.id)" class="pad-sx20 bbot disjb" v-for="(item,index) in faultsList" :key="index">
<view @tap="dataQueryEv(index)" class="disjcac fc width25" v-for="(item,index) in dataQueryList" :key="index"> <view class="fon28 line-h38 disjb fc" style="min-height: 160rpx;">
<view class="posir"> <view>
<image :style="{width: [58,58,58][index]+'rpx',height:[46,56,50][index] + 'rpx'}" style="width: 58rpx;height: 53rpx;" :src="item.imgsrc" mode="widthFix"></image> <view class="col3 clips1">{{item.title}}</view>
<view class="engineer-num" v-if="item.num!=0">{{item.num}}</view> <view class="fon22 col6 clips3 mar-sx10">{{item.content}}</view>
</view> </view>
<view class="fon24 col3 mar-s10">{{item.title}}</view> <view class="col9">{{item.views}}人看过</view>
</view>
</view>
</view>
<!-- 结算情况 -->
<view class="home-fun-box" v-if="role==4">
<view class="fun-title col3 fon28 disac bold">结算情况</view>
<view class="disac mar-s30">
<view class="disjcac fc width25" v-for="(item,index) in settlementList" :key="index">
<view class="posir">
<image :style="{width: [58,50,58][index]+'rpx',height:[54,58,58][index] + 'rpx'}" style="width: 58rpx;height: 53rpx;" :src="item.imgsrc" mode="widthFix"></image>
<view class="engineer-num" v-if="item.num!=0">{{item.num}}</view>
</view>
<view class="fon24 col3 mar-s10">{{item.title}}</view>
</view> </view>
<image class="flexs mar-z20" :src="item.imgsrc" style="width: 280rpx;height: 160rpx;" mode="aspectFill" lazy-load></image>
</view> </view>
</view> </view>
</view> </view>
<!-- 其他 --> </container-subgroup-two>
<view class="home-fun-box">
<view class="fun-title col3 fon28 disac bold">其他</view>
<view class="disac mar-s30">
<view @tap="otherEv(index)" class="disjcac fc width25" v-for="(item,index) in otherList" :key="index">
<image :style="{width: [58,49,58][index]+'rpx',height:[51,58,55][index] + 'rpx'}" style="width: 58rpx;height: 53rpx;" :src="item.imgsrc" mode="widthFix"></image>
<view class="fon24 col3 mar-s10">{{item.title}}</view>
</view>
</view>
</view>
</view>
<!-- 解决方案 -->
<view class="home-solution mar-x20 pad30">
<view class="disjbac" @tap="goPlant(0)">
<view>
<view class="fon30 bold" style="color: #00a2e9;">畅想智能-场景化设计</view>
<view class="fon34 bold col3 mar-s10">解决方案<text class="col9 mar-z10">Solution</text></view>
</view>
<image style="width: 50rpx;height: 50rpx;" src="/static/public/icon-home-solution.png" mode=""></image>
</view>
<view class="mar-s30">
<scroll-view scroll-x>
<view :class="solutionList.length == 4 ? 'disjbac' : 'disac'">
<view @tap="goDetail(0,item.id)" class="posir flexs" v-for="(item,index) in solutionList" :key="index" style="width: 23%;height: 214rpx;" :style="{marginRight: solutionList.length != 4 ? '20rpx' : ''}">
<image style="width: 100%;height: 214rpx;" class="radius10 " :src="item.imgsrc" mode="widthFix"></image>
<view class="posia solution-title clips1">{{item.title}}</view>
</view>
</view>
</scroll-view>
</view>
</view>
<!-- 常见故障 -->
<view class="bacf mar-zy20 pad-sx30 pad-zy10 radius10">
<view class="fon34 bold col3" @tap="goPlant(1)"><text class="col9 mar-z10">Common faults</text></view>
<view @tap="goDetail(1,item.id)" class="pad-sx20 bbot disjb" v-for="(item,index) in faultsList" :key="index">
<view class="fon28 line-h38 disjb fc" style="min-height: 160rpx;">
<view>
<view class="col3 clips1">{{item.title}}</view>
<view class="fon22 col6 clips3 mar-sx10">{{item.content}}</view>
</view>
<view class="col9">{{item.views}}人看过</view>
</view>
<image class="flexs mar-z20" :src="item.imgsrc" style="width: 280rpx;height: 160rpx;" mode="aspectFill" lazy-load></image>
</view>
</view>
<!-- 底部tab --> <!-- 底部tab -->
<foot-tab></foot-tab> <foot-tab></foot-tab>
</view> </view>
@ -217,12 +230,14 @@
// //
import lwNotice from '@/components/lw-notice/lw-notice.vue'; import lwNotice from '@/components/lw-notice/lw-notice.vue';
import footTabOne from '@/components/foot-tabs/foot-tab-one.vue'; import footTabOne from '@/components/foot-tabs/foot-tab-one.vue';
import containerSubgroupTwo from '@/components/containers/container-subgroup-two.vue';
export default { export default {
components:{ components:{
pitera, pitera,
statusNavSlot, statusNavSlot,
lwNotice, lwNotice,
'foot-tab' :footTabOne 'foot-tab' :footTabOne,
containerSubgroupTwo
}, },
data() { data() {
return { return {

View File

@ -6,17 +6,17 @@
<view class="mar-s20 mar-zy10" style="box-shadow: 0rpx 0rpx 20rpx rgba(0,0,0,.3);"> <view class="mar-s20 mar-zy10" style="box-shadow: 0rpx 0rpx 20rpx rgba(0,0,0,.3);">
<view class="bacf" style="padding: 4rpx;border-radius: 30rpx;"> <view class="bacf" style="padding: 4rpx;border-radius: 30rpx;">
<view class="electronic-head disjcac fc"> <view class="electronic-head disjcac fc">
<image src="/static/public/icon-electronic-logo.png" mode="widthFix" lazy-load style="width: 347rpx;height: 85rpx;"></image> <image :src="userImg" mode="widthFix" lazy-load style="width: 347rpx;height: 85rpx;"></image>
<view class="colf fon52 mar-sx30" style="letter-spacing: 6rpx;">IDCW-0000</view> <view class="colf fon52 mar-sx30" style="letter-spacing: 6rpx;">ID{{userId}}</view>
<image class="mar-s20" src="/static/deleteImg/flying-img06.png" mode="aspectFill" style="width: 258rpx;height: 258rpx;border-radius: 100%;margin-bottom: -130rpx;border: 6rpx solid #edf1ff;background-color: #edf1ff;"></image> <image class="mar-s20" src="/static/deleteImg/flying-img06.png" mode="aspectFill" style="width: 258rpx;height: 258rpx;border-radius: 100%;margin-bottom: -130rpx;border: 6rpx solid #edf1ff;background-color: #edf1ff;"></image>
</view> </view>
<view class="pad-s140 mar-s30 disjcac fc"> <view class="pad-s140 mar-s30 disjcac fc">
<view class="col3 fon68">姓名</view> <view class="col3 fon68">{{userName}}</view>
<view class="fon32 col6 mar-sx30">市场部门 | 技术支持</view> <view class="fon32 col6 mar-sx30">{{userContent}}</view>
<view class="fon22 col3 tcenter line-h36" style="margin: 60rpx 0 60rpx 0;"> <view class="fon22 col3 tcenter line-h36" style="margin: 60rpx 0 60rpx 0;">
<view>+86 123 4567 8910</view> <view>+86 {{userPhone}}</view>
<view>12345678910qwer@890.com</view> <view>{{userEmail}}</view>
<view>WWW.12345678910.com</view> <view>{{website}}</view>
</view> </view>
</view> </view>
</view> </view>
@ -30,7 +30,13 @@
export default { export default {
data() { data() {
return { return {
userImg:'/static/public/icon-electronic-logo.png',
userId:'CW-0000',
userName:'姓名',
userContent:'市场部门 | 技术支持',
userPhone:'123 4567 8910',
userEmail:'12345678910qwer@890.com',
website:'WWW.12345678910.com'
} }
}, },
methods: { methods: {

View File

@ -76,7 +76,7 @@
</view> </view>
</view> </view>
</view> </view>
<view class="person-btn">提交保</view> <view class="person-btn" @tap="sumbmitData"></view>
</view> </view>
</container-subgroup-two> </container-subgroup-two>
</view> </view>
@ -98,9 +98,69 @@
e_mail:'', // e_mail:'', //
id_card_no:'', // id_card_no:'', //
imgList:[], imgList:[],
flag:true
} }
}, },
methods: { methods: {
//
sumbmitData(){
if(this.checkEmpty()){
if(this.flag) {
this.flag = false;
let params = {
a:this.nickname,
b:this.full_name,
c:this.genderNum,
d:this.contact_number,
e:this.e_mail,
f:this.id_card_no,
g:this.imgList[0] || '',
h:this.imgList[1] || '',
i:this.imgList[2] || '',
k:this.imgList[3] || ''
}
console.log(params,119);
// this.$requst.post('',params).then(res=>{
// if(res.code){
uni.navigateBack({delta:1})
// }
// })
} else {
this.$toolAll.tools.showToast('请勿重复提交');
}
}
},
//
checkEmpty(){
let result = false;
if(uni.getStorageSync('type_id')==4) {
//
if(!this.nickname) {
this.$toolAll.tools.showToast('请输入我的昵称');
} else if(!this.full_name) {
this.$toolAll.tools.showToast('请输入姓名');
} else if(this.$toolAll.tools.isPhone(this.contact_number)) {
this.$toolAll.tools.showToast('请正确输入联系电话');
} else if(this.$toolAll.tools.isEmail(this.e_mail)) {
this.$toolAll.tools.showToast('请正确输入电子邮箱');
} else if(this.$toolAll.tools.isIdentity(this.id_card_no)) {
this.$toolAll.tools.showToast('请正确输入身份证号码');
} else if(!this.imgList[0]) {
this.$toolAll.tools.showToast('请上传身份证正反面');
} else if(!this.imgList[1]) {
this.$toolAll.tools.showToast('请上传意外险材料');
} else if(!this.imgList[2]) {
this.$toolAll.tools.showToast('请上传合作协议');
} else if(!this.imgList[3]) {
this.$toolAll.tools.showToast('请上传技能证书');
} else {
result = true;
}
} else {
result = true;
}
return result;
},
// //
chooseGender(index){ chooseGender(index){
this.genderNum = index; this.genderNum = index;
@ -119,12 +179,12 @@
from:tempImg[0] from:tempImg[0]
} }
console.log(params,104); console.log(params,104);
// uploadImg(params).then(res=>{ uploadImg(params).then(res=>{
// console.log(res); console.log(res);
// }) })
// this.$requst.upload('file/upload/image',{file:tempImg[i]}).then(res=>{ // this.$requst.upload('file/upload/image',{file:tempImg[i]}).then(res=>{
// if(this.imgArr.length!=9){ // if(this.imgArr.length!=9){
// this.imgArr.push(this.$http + res.data.src); // // this.imgArr.push(this.$http + res.data.src);
// } // }
// if(num==tempImg.length){ // if(num==tempImg.length){
// this.$toolAll.tools.showToast('(*^^*)') // this.$toolAll.tools.showToast('(*^^*)')

View File

@ -17,15 +17,16 @@
</view> </view>
<view class="bbot disac pad-sx30 pad-zy30"> <view class="bbot disac pad-sx30 pad-zy30">
<view class="mar-y30 flexs disjbac" :style="{width: eareWidth + 'px'}"> <view><text style="color: red;">*</text></view></view> <view class="mar-y30 flexs disjbac" :style="{width: eareWidth + 'px'}"> <view><text style="color: red;">*</text></view></view>
<view class="disjbac width100" @tap="chooseRegion"> <!-- <view class="disjbac width100" @tap="chooseRegion"> -->
<view>湖南省株洲市芦淞区</view> <view class="disjbac width100" @tap="openPicker">
<view>{{region}}</view>
<i class="icon icon-next col9" style="font-size: 30rpx;"></i> <i class="icon icon-next col9" style="font-size: 30rpx;"></i>
</view> </view>
</view> </view>
<view class="bbot disac pad-sx30 pad-zy30"> <view class="bbot disac pad-sx30 pad-zy30">
<view class="mar-y30 flexs">详细地址 <text style="color: red;">*</text></view> <view class="mar-y30 flexs">详细地址 <text style="color: red;">*</text></view>
<view class="disac"> <view class="disac">
<input class="fon28" type="text" placeholder="请输入详细地址" placeholder-style="font-size:28rpx;"/> <input class="fon28" type="text" v-model="detailed_address" placeholder="请输入详细地址" placeholder-style="font-size:28rpx;"/>
</view> </view>
</view> </view>
<view class="bbot disac pad-sx30 pad-zy30"> <view class="bbot disac pad-sx30 pad-zy30">
@ -43,12 +44,18 @@
</view> </view>
</container-subgroup> </container-subgroup>
<!-- 提交保存 --> <!-- 提交保存 -->
<view class="person-btn" style="margin-top: -60rpx;">提交保存</view> <view class="person-btn" @tap="submitData" style="margin-top: -60rpx;">提交保存</view>
<city @choseVal="choseValue" :lotusAddressData="lotusAddressData"></city>
</view> </view>
</template> </template>
<script> <script>
import city from '@/components/city/city.vue';
// import city from '@/components/city/city.js';
export default { export default {
components:{
city
},
data() { data() {
return { return {
personnelStatus:['工作状态','休息状态'], personnelStatus:['工作状态','休息状态'],
@ -57,8 +64,20 @@
hoursNum:0, hoursNum:0,
serviceRange:['30KM','80KM','1500KM','其他','其他','其他','其他'], serviceRange:['30KM','80KM','1500KM','其他','其他','其他','其他'],
rangeNum:0, rangeNum:0,
lotusAddressData:{
visible:false,
provinceName:'',
cityName:'',
townName:'',
},
region:'湖南省株洲市芦淞区',
newProvice:'',
newCity:'',
newDistrict:'',
detailed_address:'',
remarkText:'', remarkText:'',
eareWidth:'' eareWidth:'',
flag:true
} }
}, },
onReady() { onReady() {
@ -68,6 +87,40 @@
}).exec() }).exec()
}, },
methods: { methods: {
//
submitData(){
if(this.checkEmpty()) {
if(this.flag) {
this.flag = false;
let params = {
a:this.personnelStatus[this.statusNum],
b:this.workingHours[this.hoursNum],
c:this.region,
d:this.detailed_address,
f:this.serviceRange[this.rangeNum],
g:this.remarkText
}
console.log(params,87);
// this.$requst.post().then(res=>{
// if(res.code) {
// uni.navigateBack({delta:1})
// }
// })
}
}
},
//
checkEmpty(){
let result = false;
if(!this.region) {
this.$toolAll.tools.showToast('请选择地区');
} else if(!this.detailed_address){
this.$toolAll.tools.showToast('请输入详细地址');
} else {
result = true;
}
return result;
},
// //
chooseRegion(){ chooseRegion(){
uni.getLocation({ uni.getLocation({
@ -95,6 +148,53 @@
} }
}); });
}, },
getDistrict() {
let ya = this
uni.getLocation({
success:(res)=> {
uni.request({
url: `https://apis.map.qq.com/ws/geocoder/v1/?location=${res.latitude},${res.longitude}&key=B2ABZ-SIDKS-WD2O3-6CJ2U-CDZOT-U3FKF`,
header: {
'Content-Type':'application/json'
},
success:function(res) {
// console.log('',res)
ya.newProvice = res.data.result.address_component.province
ya.newCity = res.data.result.address_component.city
ya.newDistrict = res.data.result.address_component.district
}
})
},
})
},
//picker
openPicker() {
this.lotusAddressData.visible = true;
this.lotusAddressData.provinceName = this.newProvice;
this.lotusAddressData.cityName = this.newCity;
this.lotusAddressData.townName = this.newDistrict;
},
//
choseValue(res){
//rescode
// console.log(res);
this.lotusAddressData.visible = res.visible;//visibletruefalse
//res.isChose = 1 res.isChose = 0;
if(res.isChose){
this.lotusAddressData.provinceName = res.province;//
this.lotusAddressData.cityName = res.city;//
this.lotusAddressData.townName = res.town;//
this.region = `${res.province}${res.city}${res.town}`; //region
this.regionObj = {
province:res.province,
provinceCode:res.provinceCode,
city:res.city,
cityCode:res.cityCode,
town:res.town,
townCode:res.townCode
}
}
},
// //
chooseStatus(index,num){ chooseStatus(index,num){
switch (num){ switch (num){

Binary file not shown.

Before

Width:  |  Height:  |  Size: 87 KiB

After

Width:  |  Height:  |  Size: 94 KiB