Commit cefaedc8 authored by Morson's avatar Morson

Merge branch 'master' of https://git.banshouhui.com/lijundan/self-support

# Conflicts:
#	src/App.vue
parents d928c052 7754cfaa
......@@ -56,13 +56,13 @@
.txt{
color:#333;
padding:10rpx 30rpx;
margin: 5rpx;
margin: 10rpx;
background: #F4F5F7;
border-radius: 10rpx;
display: flex;
flex-wrap: wrap;
line-height: 50rpx;
max-width: 48%;
max-width: 46%;
align-items: center;
&.active{
background-color: #2272FF;
......
<!-- ******************* 输入框 ******************* -->
<template>
<view>
<view :style="{'width': fieldsWidth}">
<u-input :type="type" class="input-item" v-model="dataValue" @input="valueChange" :placeholder="placeholder" :placeholder-style="placeholderStyle"
:custom-style="customStyle" :clearable="false" :border="border" border-color="#ECECEC"/>
</view>
......@@ -17,10 +17,10 @@
type: String,
default: '请输入'
},
width: { // 例如:454rpx
type: String,
default: '100%'
}
// width: { // 例如:454rpx
// type: String,
// default: '100%'
// }
},
data() {
return {}
......@@ -36,6 +36,9 @@
return 'text'
}
},
fieldsWidth() {
return this.item.fieldsWidth ? (this.item.fieldsWidth + 'rpx') : '100%'
},
placeholderStyle() {
return 'color:#999999;font-size:26rpx'
},
......@@ -45,7 +48,6 @@
'border-radius': '12rpx',
'color': '#333333',
'padding-left': this.textarea ? '0rpx' : '20rpx',
'width': this.width,
'font-size':'26rpx',
'height': '76rpx'
}
......@@ -57,7 +59,7 @@
return this.type == 'textarea'
},
backgroundColor() {
return this.textarea ? '#FFFFFF' : '#F4F5F7'
return this.textarea ? 'transparent' : '#F4F5F7'
}
},
watch: {},
......
......@@ -38,13 +38,13 @@
.txt{
color:#333;
padding:10rpx 30rpx;
margin: 5rpx;
margin: 10rpx;
background: #F4F5F7;
border-radius: 10rpx;
display: flex;
flex-wrap: wrap;
line-height: 50rpx;
max-width: 48%;
max-width: 46%;
align-items: center;
&.active{
background-color: #2272FF;
......
<!-- ******************* 单级/多级 选择 ******************* -->
<template>
<view class="picker-box">
<view class="u-flex u-row-between" @click="openPicker">
<view class="txt u-flex-1">{{text||''}}</view>
<u-icon name="arrow-right" color="#666" size="28"></u-icon>
<view class="u-flex u-row-between text-view" @click="openPicker">
<view class="txt u-flex-1 text-title">{{text||''}}</view>
<u-icon class="input-icon" color="#2272FF" :name="showPicker ? 'arrow-up' : 'arrow-down'"></u-icon>
</view>
<u-picker v-model="showPicker" range-key="label" @columnchange="columnchange" :mode="isNotMulti?'selector':'multiSelector'" @confirm="pickerConfirm" :range="settings"></u-picker>
<!-- :default-selector='[0, 1]' -->
......@@ -154,5 +154,15 @@
}
</script>
<style lang="scss" scoped>
.text-view {
background-color: #F4F5F7;
border-radius: 12rpx;
padding-left: 20rpx;
padding-right: 20rpx;
height: 76rpx;
.text-title {
font-size: 26rpx;
color: #333333;
}
}
</style>
......@@ -15,11 +15,11 @@
<u-form :model="form" ref="uForm">
<template v-for="(groupItem, groupIndex) in (list.length>0?list[tabIndex].items:[])">
<view class="class-item" :key="groupIndex">
<view class="title">{{groupItem.name}}</view>
<view class="title" v-if="groupItem.name !== '基本信息'">{{groupItem.name}}</view>
<view class="class-bd">
<u-form-item v-for="(item,itemIndex) in groupItem.items" :key="itemIndex"
label-position="top" :prop="item.fieldsName" :border-bottom="false">
<view class="label" v-if="typeToComponentType(item.fieldsType)!=='location'">
<view :class="[{'label-bold': groupItem.name === '基本信息'}, 'label']" v-if="typeToComponentType(item.fieldsType)!=='location'">
<image class="item-image" :src="mixingImage" v-if="item.required"></image>
{{item.fieldsTitle}}
</view>
......@@ -77,7 +77,7 @@
</u-form>
</scroll-view>
</view>
<view class="btn-wrap flex-xc btn-bottom">
<view :class="['btn-wrap', 'flex-xc', {'btn-bottom': tabIndex > 0}]">
<u-button class="btn-submit" @click="saveComplete"
type="primary" shape="circle" :custom-style="customStyle" :hover-class="submitStatus ? '' : 'none'">
暂存
......@@ -253,7 +253,7 @@
self.$u.api.getCompleteConfigAndData(self.orderId).then((res) => {
if (res.code == 200) {
self.list = res.data.config
self.form = res.data.value
self.form = res.data.value || {}
} else {
console.log(res.message, "获取订单完工项目失败!");
}
......@@ -400,6 +400,7 @@
}else{
this.$set(this.form,innerItem.fieldsName,data.value)
}
console.log(this.form)
},
nextStep() {
if (this.tabIndex < this.list.length - 1) {
......@@ -423,6 +424,7 @@
case 'number':
case 'decimal':
case 'double':
case 'integer':
formType = 'input'
break
case 'multiinput':
......@@ -597,9 +599,13 @@
.label {
color: #333;
font-size: 28rpx;
line-height: 40rpx;
line-height: 40rpx;
padding-bottom: 20rpx;
}
.label-bold {
font-size: 32rpx;
font-weight: bold;
}
.required {
padding-right: 10rpx;
font-size: 28rpx;
......@@ -633,17 +639,19 @@
.u-search-box {
padding: 18rpx 30rpx;
}
.order-tabs {
margin-top: 20rpx;
margin-bottom: 32rpx;
}
.u-menu-wrap {
flex: 1;
flex: 1;
height: 100%;
display: flex;
overflow: hidden;
border-radius: 12rpx 12rpx 0 0;
}
.u-search-inner {
......@@ -699,7 +707,8 @@
}
.right-box {
background-color: rgb(250, 250, 250);
// background-color: rgb(250, 250, 250);
background-color: #FFFFFF;
}
.page-view {
......@@ -707,7 +716,7 @@
}
.class-item:last-child {
min-height: 100vh;
max-height: 100vh;
}
.item-title {
......
......@@ -52,7 +52,6 @@
<text>x{{ order.orderProductCount }}</text>
</view>
<view class="order-cell between-cell">
<text>充电桩信息:</text>
<text class="cell-title">充电桩信息:</text>
<text>{{ order.serviceContent }}</text>
</view>
......@@ -89,7 +88,7 @@
</view>
</view>
</view>
<view v-if="orderRecords.length > showLenght">
<view v-if="orderRecords && orderRecords.length > showLenght">
<view v-if="readMoreRecord" @click="readMoreRecord = false" class="read-more-toggle">
<u-icon name="arrow-down"></u-icon>
<text class="read-more-text">查看更多</text>
......@@ -128,6 +127,8 @@
separator-color="#FFFFFF"
separator-size="20"
:ref="'uCountDown'"
show-days
height="20"
:show-days="threeDays()"
:show-minutes="!threeDays()"
:show-seconds="!threeDays()"
......@@ -217,7 +218,7 @@
appointmentDatetimeRange:'',
appointmentDatetime:'',
signDistance:3000,
num:0
num:0,
}
},
onLoad(option) {
......@@ -253,7 +254,7 @@
return btnClass
},
shwoOrderRecords() {
if (this.readMoreRecord) {
if (this.readMoreRecord && this.orderRecords && this.orderRecords.length>0) {
return this.orderRecords.slice(0, 5)
} else {
return this.orderRecords
......@@ -317,10 +318,10 @@
console.log("image",img)
this.takeStatus = false
// 获取返回的图片 ,如果返回的图片存在则直接异常签约,成功后跳转到去完工页面,
if(img && img.length>0){ // 拍照完成
if(img){ // 拍照完成
this.isErrorSign = true
this.errorSignUrl = process.uniEnv.qn_base_url +img[img.length-1].key
this.errorSignUrl = process.uniEnv.qn_asset_url +img[img.length-1].key
this.handleBtn()
}else{
this.$refs.uToast.show({
......@@ -340,6 +341,7 @@
self.order = res.data
this.getCurrentBtn()
if(self.order.isFirstOrder){
this.visibale = true
}
} else {
console.log(res.message, "获取订单详情失败!");
......@@ -390,7 +392,6 @@
let res = await this.$u.api.workerCalendar(params)
if(res && res.code == 200) {
self.dateList = res.data
self.dateList[1].timeRange[0]='appointment_range_8'
}
},
......@@ -407,9 +408,9 @@
}
},
dateChange(data){
this.loadTimerange()
// 点击日期选择
console.log(data,'dateChange')
this.loadCalendar()
let self = this
self.appointmentDatetime = data.item.day
self.timeList.map((item, index) => {
......@@ -613,21 +614,21 @@
if(!currentOverTime){
return 0
}
return Math.round(Math.abs(currentOverTime - new Date().getTime()) / 1000)
return Math.round(Math.abs(this.order.currentOverTime - new Date().getTime()) / 1000);
},
timeOutChange(currentOverTime){
let self = this
var nowTime = new Date(); // 当前时间
if(nowTime.getTime() > currentOverTime*1000){
if(nowTime.getTime() > currentOverTime){
this.btnClass='timeOut-btn'
self.$refs['uCountDown'].seconds += 2
}
},
handleClick(){
this.visibale = false
// 去完工
uni.navigateTo({
url: 'pages/photo/list'
// 交互规范
uni.switchTab({
url: 'pages/learn/index'
})
},
threeDays() {
......
......@@ -94,10 +94,11 @@
this._freshing = false;
this.getLocation();
// this.getOrderCount();
this.getOrderList(0);
// this.getOrderList(0);
},
onShow() {
this.getOrderCount()
this.getOrderList(this.currentIndex);
},
computed: {
subList() {
......@@ -250,13 +251,12 @@
// 获取订单数量
getOrderCount() {
// 加载订单列表
this.$u.api.listOrderCount().then((res) => {
var self = this; // 加载订单列表
self.$u.api.listOrderCount().then((res) => {
if (res.code == 200) {
console.log("===", res.data)
if (res.data) {
var count = 0
this.list.forEach(item => {
self.list.forEach(item => {
if (item.name === '待预约') {
item.total = res.data.toAppointmentCount
} else if (item.name === '待签到') {
......@@ -290,11 +290,28 @@
})
},
handleClick(item) {
if(item.orderStatus===86 || item.orderStatus===88){
this.filish(item)
return
}
console.log('click cell')
this.viewOderItem(item.orderId)
},
filish(item){
// 去完工
uni.navigateTo({
url: 'pages/order/complete?orderId='+item.orderId
+ "&categoryId=" + item.categoryId
+ "&orderServiceType=" + item.orderServiceType
+ "&inGuaranteePeriod=" + item.inGuaranteePeriod
})
},
handleAction(item) {
console.log('click button')
if(item.orderStatus===86 || item.orderStatus===88){
this.filish(item)
return
}
this.viewOderItem(item.orderId)
},
handleClickSearch() {
......
......@@ -82,17 +82,12 @@
if (e && e.brandId) {
this.brandId = e.brandId
}
uni.setNavigationBarTitle({
title: "郭小清"
});
// if (e && e.brand) {
// this.brand = e.brand!==undefined?e.brand:"郭小清"
// uni.setNavigationBarTitle({
// title: this.brand
// });
// }
if (e && e.brand) {
this.brand = decodeURIComponent(e.brand)
uni.setNavigationBarTitle({
title: this.brand
});
}
if (e && e.orderId) {
this.orderId = e.orderId
......@@ -240,7 +235,7 @@
// 点击图片
handleClickImage(item, index) {
uni.previewImage({
urls: item.imageList,
urls: item.orderImages,
current: index
})
},
......@@ -267,7 +262,14 @@
})
},
take(item,ikey) {
this.currentItemDate = item
this.currentItemDate = item
const photo = getApp().globalData.photo
photo.currentItem = item
photo.itemIndex = ikey
const len = item.orderImages.length
photo.currentItemLength = len > 9 ? 10 : len
uni.hideTabBar()
this.takeStatus = true
},
......@@ -275,11 +277,11 @@
console.log(img)
if(img !==undefined ){
// step1 添加图片
this.currentItemDate.images.push(img)
this.currentItemDate.orderImages.push(process.uniEnv.qn_asset_url+img[img.length-1].key)
// step2 保存图片
var data={
type : this.currentItemDate.type,
images : this.currentItemDate.images,
images : Array.from(this.currentItemDate.orderImages),
fieldsName:this.currentItemDate.fieldName
}
this.$u.api.saveImage(data,this.orderId).then((res) => {
......@@ -293,8 +295,8 @@
this.takeStatus = false
},
getWatermark(){
var data={}
this.$u.api.getWatermark(data,this.orderId).then((res) => {
var data={partnerCompanyId:this.systemId}
this.$u.api.getWatermark(data).then((res) => {
if (res.code == 200) {
console.log("===", res.data)
this.userWatermark = res.data
......
src/static/photo/arrow.png

3.61 KB | W: | H:

src/static/photo/arrow.png

666 Bytes | W: | H:

src/static/photo/arrow.png
src/static/photo/arrow.png
src/static/photo/arrow.png
src/static/photo/arrow.png
  • 2-up
  • Swipe
  • Onion skin
src/static/photo/continue.png

5.61 KB | W: | H:

src/static/photo/continue.png

1.99 KB | W: | H:

src/static/photo/continue.png
src/static/photo/continue.png
src/static/photo/continue.png
src/static/photo/continue.png
  • 2-up
  • Swipe
  • Onion skin
src/static/photo/finish.png

5.31 KB | W: | H:

src/static/photo/finish.png

1.81 KB | W: | H:

src/static/photo/finish.png
src/static/photo/finish.png
src/static/photo/finish.png
src/static/photo/finish.png
  • 2-up
  • Swipe
  • Onion skin
src/static/photo/icon-back.png

2.46 KB | W: | H:

src/static/photo/icon-back.png

972 Bytes | W: | H:

src/static/photo/icon-back.png
src/static/photo/icon-back.png
src/static/photo/icon-back.png
src/static/photo/icon-back.png
  • 2-up
  • Swipe
  • Onion skin
src/static/photo/icon-close.png

2.54 KB | W: | H:

src/static/photo/icon-close.png

974 Bytes | W: | H:

src/static/photo/icon-close.png
src/static/photo/icon-close.png
src/static/photo/icon-close.png
src/static/photo/icon-close.png
  • 2-up
  • Swipe
  • Onion skin
src/static/photo/icon-light-auto.png

2.03 KB | W: | H:

src/static/photo/icon-light-auto.png

915 Bytes | W: | H:

src/static/photo/icon-light-auto.png
src/static/photo/icon-light-auto.png
src/static/photo/icon-light-auto.png
src/static/photo/icon-light-auto.png
  • 2-up
  • Swipe
  • Onion skin
src/static/photo/icon-light-off.png

2.46 KB | W: | H:

src/static/photo/icon-light-off.png

1.06 KB | W: | H:

src/static/photo/icon-light-off.png
src/static/photo/icon-light-off.png
src/static/photo/icon-light-off.png
src/static/photo/icon-light-off.png
  • 2-up
  • Swipe
  • Onion skin
src/static/photo/icon-light-on.png

1.42 KB | W: | H:

src/static/photo/icon-light-on.png

686 Bytes | W: | H:

src/static/photo/icon-light-on.png
src/static/photo/icon-light-on.png
src/static/photo/icon-light-on.png
src/static/photo/icon-light-on.png
  • 2-up
  • Swipe
  • Onion skin
src/static/photo/icon-light.png

1.58 KB | W: | H:

src/static/photo/icon-light.png

830 Bytes | W: | H:

src/static/photo/icon-light.png
src/static/photo/icon-light.png
src/static/photo/icon-light.png
src/static/photo/icon-light.png
  • 2-up
  • Swipe
  • Onion skin
src/static/photo/icon-setting.png

1.61 KB | W: | H:

src/static/photo/icon-setting.png

795 Bytes | W: | H:

src/static/photo/icon-setting.png
src/static/photo/icon-setting.png
src/static/photo/icon-setting.png
src/static/photo/icon-setting.png
  • 2-up
  • Swipe
  • Onion skin
src/static/photo/icon-standard.png

13.8 KB | W: | H:

src/static/photo/icon-standard.png

6.17 KB | W: | H:

src/static/photo/icon-standard.png
src/static/photo/icon-standard.png
src/static/photo/icon-standard.png
src/static/photo/icon-standard.png
  • 2-up
  • Swipe
  • Onion skin
src/static/photo/icon-switch.png

1.46 KB | W: | H:

src/static/photo/icon-switch.png

752 Bytes | W: | H:

src/static/photo/icon-switch.png
src/static/photo/icon-switch.png
src/static/photo/icon-switch.png
src/static/photo/icon-switch.png
  • 2-up
  • Swipe
  • Onion skin
src/static/photo/icon-take.png

6.18 KB | W: | H:

src/static/photo/icon-take.png

1.59 KB | W: | H:

src/static/photo/icon-take.png
src/static/photo/icon-take.png
src/static/photo/icon-take.png
src/static/photo/icon-take.png
  • 2-up
  • Swipe
  • Onion skin
src/static/photo/shadow-bg.png

13 KB | W: | H:

src/static/photo/shadow-bg.png

2.2 KB | W: | H:

src/static/photo/shadow-bg.png
src/static/photo/shadow-bg.png
src/static/photo/shadow-bg.png
src/static/photo/shadow-bg.png
  • 2-up
  • Swipe
  • Onion skin
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment