Commit b04d2daf by 张立顺

chore: migrate legacy master snapshot

Source: git@192.168.3.233:micro-customization-system/car-service-worker.git
Source-Commit: 7942e83b789752f959f8f3a55a9f45c69cf7f6cc
1 parent 33f9762e
Showing 959 changed files with 4862 additions and 0 deletions
# Windows
[Dd]esktop.ini
Thumbs.db
$RECYCLE.BIN/
# macOS
.DS_Store
.fseventsd
.Spotlight-V100
.TemporaryItems
.Trashes
.svn
# Node.js
node_modules/
miniprogram_npm/
/* pages/profile/profile.wxss */
.profile {
color: #333;
font-weight: 400;
}
.profile-cells {
margin: 0;
background-color: #FFFFFF;
}
.profile-cells::after {
display: block;
content: '';
border-bottom: 1px solid #D9D9D9;
}
.profile .p_tb_27 {
padding: 27rpx;
}
.profile .my_list_left {
position: relative;
margin-right: 20rpx;
}
.profile .left_img {
width: 44rpx;
height: 44rpx;
display: block;
}
.profile .list_txt {
font-size: 32rpx;
}
.profile switch {
zoom: 0.7;
}
.avatar {
width: 128rpx;
height: 128rpx;
vertical-align: middle;
border-radius: 8px;
}
.name {
font-size: 32rpx;
font-weight: bold;
margin-bottom: 9rpx;
}
.storeID {
display: inline-block;
line-height: 58rpx;
background-color: #eee;
border-radius: 30rpx;
padding: 0 30rpx;
margin-bottom: 20rpx;
}
.phone {
height: 28rpx;
}
.weui-badge {
padding: 0;
}
.weui-badge_dot {
width: 20rpx;
height: 20rpx;
}
.logout {
text-align: center;
/*color: #3da5f5;*/
margin-bottom: 73rpx;
}
/* 重置样式 */
.weui-cell {
/*padding: 56rpx 23rpx 46rpx;*/
}
.weui-cells {
margin-top: 20rpx;
font-size: 32rpx;
}
.profile .developHover {
background-color: #D9D9D9;
}
.profile .btn_blue_hover {
background-color: #e9f5fe;
}
/* 意见反馈 */
.button {
width: 100%;
background: white;
border: none;
text-align: left;
padding: 0 0;
margin: 0px;
line-height: 1.6;
border-radius: 0;
font-size: 32rpx;
}
.button::after {
border: none;
border-radius: 0;
}
.text_center{
text-align: center;
}
.user_info{
display: flex;
flex-direction: column;
align-items: space-around;
width: calc(100% - 128rpx - 50rpx);
font-size: 30rpx;
margin-left: 20rpx;
}
.belong{
width: 100%;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
.work_status_img{
width: 22px;
height: 22px;
vertical-align: middle;
margin-right: 5px;
}
.work_status_text{
vertical-align: middle;
}
.modalTitle {
color: #FF4821;
margin-top: 20rpx;
font-weight: bold;
font-size: 34rpx;
}
.modalCell {
margin: 20rpx 48rpx;
}
.user_photo{
position: relative;
font-size: 0;
}
.user_badge{
position: absolute;
bottom: 0;
right: 0;
width: 14px;
height: 14px;
background-size: 14px 14px;
background-image: url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABwAAAAcCAYAAAByDd+UAAACRUlEQVRIS8WWv28SYRjHP8+BGlMHdXBok9Y4mOgAh62TVWNcHbCrk3Fycm1aoQRS2tk/wcRVGRy1/qBOBgsdbGocjIkMdWRS4B7zXjlCKdxxkJy3vs/zfO593u/zQxjhS+U12RbSotxWYRplBkGBuih1FT7ElNJOVmpB4cTPwC5o2oEiypWgQO65sGfBSjUjpWH2A4HzmzrbavJClcWRQH1GImzHT/Cgsiw/+/2PAe2i3tAWLxUujAPzfAQOJM5SdUU+9cY5AjQwp81blFOTwLq+wh8rxt1eaBfopvEvnye92YAUHsRPct1LbxeYLGh53DcLyoZ501pGbh7qCnDVqLwKcpzk3BLuG/W6wERBv44sfR+qCL+BM6qcPmYm7O1m5KrY62o7bXYm+XvjawnPzy7yqLHNXFP5PiieFSMldkFzjrI2CdDA0k95mBNx5tf1WrNNZWA8ISfJvG4p3BkX2AuzN/SitnivytygeALvDHBf4fI4wDCwjkK/SSKvDfPQQ4BloIzwGOVcr01YWKfXNnyBcVj4kpVKMq8phTfAeU8g3psFpfHIRYSGb0oFntWy8sQ4eVBLeD0W7DCn+6OIpriblVVjv7Chl+4t88OoMdTNOtcUYUsSBV1DyQWIpgt1O1OAGofGMmURovCLSxkypU1m/aTv9+MxsEO1NjPjEKZUmQpdRl5r+y/N21VhlOPJACMfwG5qo1wxPBFEukR50EjXxF65R7YI99eYaQ44pFW5BcwoTHfGTR34JcJHLErVVakG1ec/rYE+gBKOLyIAAAAASUVORK5CYII=');
}
\ No newline at end of file \ No newline at end of file
const restapi = require('../../../utils/restapi.js');
import WxValidate from '../../../utils/WxValidate.js';
var app = getApp();
const util = require('../../../utils/util.js')
Page({
/**
* 页面的初始数据
*/
data: {
id: null,
pickerShow: false,
receiveAddressId: '',
deviceType: '',
deviceName: '',
deviceIcon: '',
deviceAmount: '',
remark: '',
isEditMode: false,
receiverName: '',
phone: '',
cityName: '',
address: '',
},
orderNumInput(e){
this.setData({
deviceAmount: e.detail.value
})
},
remarkInput(e){
this.setData({
remark: e.detail.value
})
},
initValidate(){
const rules = {
deviceType: {
required: true
},
receiverName: {
required: true
},
deviceAmount: {
required: true,
min: 1,
max: 10000
}
}
const messages = {
deviceType: {
required: '请选择设备'
},
receiverName: {
required: '请选择收货地址'
},
deviceAmount: {
required: '请输入订货数量',
min: '订货数量不能少于1',
max: '订货数量不能大于10000'
}
}
this.WxValidate = new WxValidate(rules, messages)
},
orderSure(){
this.initValidate();
const data = this.data;
const params = {
deviceType: data.deviceType,
deviceAmount: data.deviceAmount,
remark: data.remark,
receiverName: data.receiverName
}
if(data.receiveAddressId){
params.receiveAddressId = data.receiveAddressId;
}
if (!this.WxValidate.checkForm(params)) {
const error = this.WxValidate.errorList[0]
app.toast(error.msg, '', 'none')
return false
}
delete params.receiverName;
if(this.data.isEditMode){
params.id = this.data.id;
restapi.updateOrderById(params, res=>{
if(res.code == 200){
app.showToast('编辑成功')
const page = getCurrentPages();
const prevPage = page[page.length - 2];
setTimeout(()=>{
wx.navigateBack({
success(){
prevPage.handlePullDownRefresh()
}
})
}, 1000)
}
})
}else{
params.terminalType = 3;
restapi.addOrder(params, res=>{
if(res.code == 200){
app.showToast('订货成功')
wx.redirectTo({
url: '../orderList/orderList'
})
}
})
}
},
changeDeviceType(){
this.setData({
pickerShow: true
})
},
deviceChange(e){
this.setData({
deviceType: e.detail.split(',')[0],
deviceName: e.detail.split(',')[1],
deviceIcon: util.getDeviceIcon(e.detail.split(',')[0]),
})
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
if('id' in options){
wx.setNavigationBarTitle({
title: '编辑订货单'
});
restapi.getOrderDetailById({id: options.id}, res=>{
if(res.code == 200){
const data = res.data;
let cityObj = data.sysArea;
let cityName = cityObj.areaName;
let ids = [cityObj.id]
while(cityObj.children){
cityObj = cityObj.children[0];
cityName += cityObj.areaName;
}
this.setData({
deviceType: data.deviceType,
deviceName: data.deviceName,
deviceAmount: data.deviceAmount,
remark: data.remark,
deviceIcon: util.getDeviceIcon(data.deviceType),
receiveAddressId: data.receiveAddressId,
receiverName: data.receiverName,
phone: data.phone,
cityName,
address: data.address
});
}
})
this.setData({
id: options.id,
isEditMode: true
});
}else{
wx.setNavigationBarTitle({
title: '新增订货单'
});
}
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady: function () {
},
/**
* 生命周期函数--监听页面显示
*/
onShow: function () {
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide: function () {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload: function () {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh: function () {
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom: function () {
},
/**
* 用户点击右上角分享
*/
onShareAppMessage: function () {
}
})
\ No newline at end of file \ No newline at end of file
// packageReceipt/pages/qa/qa.js
Page({
/**
* 页面的初始数据
*/
data: {
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady: function () {
},
/**
* 生命周期函数--监听页面显示
*/
onShow: function () {
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide: function () {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload: function () {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh: function () {
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom: function () {
},
/**
* 用户点击右上角分享
*/
onShareAppMessage: function () {
}
})
\ No newline at end of file \ No newline at end of file
<view class="register_pic" >
<button class="auth_btn" open-type="getUserInfo" bindgetuserinfo="getUserInfo" wx:if="{{!avatar}}">
<image class="user_img_default" src="../../images/user_img_default.png"></image>
<image class="camera_icon" src="../../images/camera.png"></image>
</button>
<image wx:else class="user_img" src="{{avatar}}"></image>
</view>
<view class="register_info">
<view class="weui-cells">
<view class="weui-cell">
<view class="weui-cell__hd">
<view class="weui-label">姓名</view>
</view>
<view class="weui-cell__bd">
<input class="weui-input" placeholder="请输入姓名" value="{{username}}" maxlength="15" bindinput="usernameInput"/>
</view>
</view>
<view class="weui-cell">
<view class="weui-cell__hd">
<view class="weui-label">手机号</view>
</view>
<view class="weui-cell__bd">
<button class="phone_btn" open-type="getPhoneNumber" bindgetphonenumber="getPhoneNumber" hidden="{{phone}}">
<input class="weui-input" value="{{phone}}" placeholder="请授权手机号" disabled/>
</button>
<input class="weui-input" value="{{phone}}" placeholder="请授权手机号" disabled hidden="{{!phone}}"/>
</view>
</view>
<view class="weui-cell">
<view class="weui-cell__hd">
<view class="weui-label">归属服务商</view>
</view>
<view class="weui-cell__bd weui-cell__ft_in-access" bindtap="toProviderDetail">
<view class="info_form_content">{{providerName}}</view>
</view>
</view>
</view>
<view class="btn_mg">
<view class="comfirm_tip">点击确认注册表示你已同意<text class="service_agree" bindtap="toAgree">《包活干平台服务协议》</text></view>
<button class="btn{{submitDisabled?' disabled':''}}" bindtap="comfirmRegister">确认注册</button>
</view>
</view>
<mp-toptips msg="{{error}}" type="error" show="{{error}}"></mp-toptips>
/* 分组选择 */
.wrapper {
position: relative;
z-index: 1900;
}
.hidden {
display: none !important;
}
.fl-fixed {
position: fixed;
top: 0;
left: 0;
height: 100%;
background-color: #F3F5F7;
}
.fl-container {
/* transition: margin-top 1s; */
}
.fl-item-letter {
padding: 15px 15px 10px;
line-height: 1;
border-bottom: 1rpx solid #e5e5e5;
font-size: 14px;
color: #999;
}
.fl-content-item {
position: relative;
display: flex;
align-items: center;
font-size: 18px;
color: #333;
background-color: #fff;
padding: 0 15px;
}
.fl-item-icon {
flex-basis: auto;
width: 20px;
height: 20px;
padding-right: 5px;
background-color: skyblue;
}
.fl-item .fl-content-item:last-child .fl-item-desc {
border-bottom: none;
}
.fl-item-desc {
flex: 1;
padding: 10px 0;
border-bottom: 1px solid #e5e5e5;
}
.side-bar {
position: fixed;
font-size: 12px;
top: 0;
right: 0;
width: 10%;
color: #007AFF;
text-align: center;
background: #fff;
z-index: 99999;
}
.side-bar text {
display: block;
width: 100%;
height: 48rpx;
white-space: nowrap;
overflow: hidden;
background: #fff;
}
/* search bar */
input {
display:block;
height:28px;
text-overflow:clip;
overflow:hidden;
white-space:nowrap;
font-family:UICTFontTextStyleBody;
min-height:28px;
}
.weui-search-bar{
position:relative;
padding:8px 10px;
display:-webkit-box;
display:-webkit-flex;
display:flex;
height: 50px;
font-size: 16px;
box-sizing:border-box;
background-color:#EFEFF4;
}
.weui-search-bar:before{
content:" ";
position:absolute;
left:0;
top:0;
right:0;
height:1px;
border-top:1px solid #D7D6DC;
color:#D7D6DC;
-webkit-transform-origin:0 0;
transform-origin:0 0;
-webkit-transform:scaleY(0.5);
transform:scaleY(0.5);
}
.weui-search-bar:after{
content:" ";
position:absolute;
left:0;
bottom:0;
right:0;
height:1px;
border-bottom:1px solid #D7D6DC;
color:#D7D6DC;
-webkit-transform-origin:0 100%;
transform-origin:0 100%;
-webkit-transform:scaleY(0.5);
transform:scaleY(0.5);
}
.weui-search-bar.weui-search-bar_focusing .weui-search-bar__cancel-btn{
display:block;
}
.weui-search-bar.weui-search-bar_focusing .weui-search-bar__label{
display:none;
}
.weui-search-bar__form{
position:relative;
-webkit-box-flex:1;
-webkit-flex:auto;
flex:auto;
background-color:#EFEFF4;
}
.weui-search-bar__form:after{
content:'';
position:absolute;
left:0;
top:0;
width:200%;
height:200%;
-webkit-transform:scale(0.5);
transform:scale(0.5);
-webkit-transform-origin:0 0;
transform-origin:0 0;
border-radius:10px;
border:1px solid #E6E6EA;
box-sizing:border-box;
background:#FFFFFF;
}
.weui-search-bar__box{
position:relative;
padding-left:30px;
padding-right:30px;
height:100%;
width:100%;
box-sizing:border-box;
z-index:1;
}
.weui-icon-search_in-box {
position:absolute;
left:10px;
top:10px;
}
.weui-search-bar__box .weui-search-bar__input{
padding:4px 0;
width:100%;
height:28px;
border:0;
font-size:14px;
line-height:28px;
box-sizing:content-box;
background:transparent;
}
.weui-search-bar__input {
height:28px;
line-height:28px;
font-size:14px;
}
.weui-search-bar__box .weui-search-bar__input:focus{
outline:none;
}
.weui-search-bar__box .weui-icon-search{
position:absolute;
left:10px;
top:0;
line-height:28px;
}
.weui-search-bar__box .weui-icon-clear{
position:absolute;
top:0;
right:0;
padding:8px 10px;
line-height:28px;
}
.weui-search-bar__label{
position:absolute;
top:1px;
right:1px;
bottom:1px;
left:1px;
z-index:2;
padding: 5px;
border-radius:3px;
text-align:center;
color:#808080;
background:#FFFFFF;
}
.weui-search-bar__label span{
display:inline-block;
font-size:14px;
vertical-align:middle;
}
.weui-search-bar__label .weui-icon-search{
margin-right:5px;
}
.weui-search-bar__label .weui-search-bar__text{
display: inline-block;
}
.weui-search-bar__cancel-btn{
display:none;
padding:2px 15px 0 5px;
line-height:32px;
color:#137DEC;
white-space:nowrap;
}
.tips{
position: fixed;
top: 50%;
left: 50%;
text-align: center;
line-height: 140rpx;
transform: translate(-70rpx,-70rpx);
width: 140rpx;
height: 140rpx;
border-radius: 50%;
color: #fff;
background: rgba(153,153,153,0.7);
z-index: 9999;
font-size: 60rpx;
font-weight: bold;
}
/* .weui-search-bar__input:not(:valid) ~ .weui-icon-clear{
display:none;
} */
/* input[type="search"]::-webkit-search-decoration,
input[type="search"]::-webkit-search-cancel-button,
input[type="search"]::-webkit-search-results-button,
input[type="search"]::-webkit-search-results-decoration{
display:none;
} */
.active{
background: #F8F8F8;
}
\ No newline at end of file \ No newline at end of file
// pages/login/login.js
import WxValidate from '../../../utils/WxValidate.js'
const restapi = require('../../../utils/restapi.js')
var app = getApp()
Page({
/**
* 页面的初始数据
*/
data: {
openSet: false,
isView: false,
focus: false,
username: '',
password: '',
// username: '18574749274',
// username: '18873336682',
// username: '15017908843',
// username: '18688885555',
// username: '15527303703',
// username: '18576673306',
facilitatorMsg: {},
isAgree: false,
loginGuideHidden: false
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
if (options.code) {
app.globalData.userCode.publicCode = options.code
}
if (!restapi.getSessionId()) {
// 验证是否登录
restapi.checkLogin(res => {
console.log(res)
if (res.data.isLogin) {
wx.switchTab({
url: "/packageReceipt/pages/receipt/receipt"
})
} else {
wx.setNavigationBarTitle({
title: '登录'
})
}
})
} else {
if (app.globalData.loginStatus) {
wx.switchTab({
url: "/packageReceipt/pages/receipt/receipt"
})
}
}
},
/* 注册模块 */
register() {
var _this = this
var msgNeed = ['name', 'orgName', 'phoneNumber', 'serviceId']
wx.scanCode({
// 扫码成功
success: (res) => {
restapi.getServiceById({
serviceId: res.result
}, res => {
app.globalData.err(res, () => {
_this.setData({
facilitatorMsg: res.data
})
let isAllExist = msgNeed.every(item => _this.data.facilitatorMsg.hasOwnProperty(item))
if (isAllExist) {
let queryBean = JSON.stringify(res.data)
wx.navigateTo({
url: '../register/registerBind/registerBind?queryBean=' + queryBean,
})
} else {
app.toast('该服务商二维码无效,请与服务商确认后重试', '', 'none')
}
})
})
},
// 扫码失败
fail: () => {
app.toast('扫码失败', '', 'none')
}
})
},
// 验证-初始化
initValidate() {
let rules = {}
let validateMsg = {}
// 加上技能 - 验证
rules.username = {
required: true,
rangelength: [1, 50],
noEmoji: true
}
validateMsg.username = {
required: '请输入账号',
rangelength: '请输入50个以内的字符',
noEmoji: '账号不能输入表情'
}
rules.password = {
required: true,
rangelength: [6, 50]
}
validateMsg.password = {
required: '请输入密码',
rangelength: '请输入6-50位密码'
}
this.WxValidate = new WxValidate(rules, validateMsg)
},
/* 登录模块 */
login() {
this.initValidate()
const _this = this
// 验证
const params = {
username: this.data.username,
password: this.data.password
} //校验表单
if (!this.WxValidate.checkForm(params)) {
const error = this.WxValidate.errorList[0]
app.toast(error.msg, '', 'none')
return false
}
if(!this.data.isAgree){
app.toast('请阅读并勾选服务协议', '', 'none')
return false;
}
restapi.login({
username: this.data.username,
password: this.data.password,
terminalType: 3
}, res => {
console.log(res)
app.globalData.isBindWechat = res.data.isMiniAuth
wx.setStorageSync(restapi.bhgSessionId, res.data.JSESSIONID)
/*if(app.globalData.userCode.publicCode){
restapi.getWechatOpenId({publicCode: app.globalData.userCode.publicCode}, res => {})
}*/
restapi.getUserById(null, res => {
if (res.code == 200) {
let userInfo = {
phoneNumber: res.data.phoneNumber,
userId: res.data.id
}
console.log(userInfo)
wx.setStorageSync('userInfo', userInfo)
}
})
/*if (app.globalData.isBindWechat) {
wx.reLaunch({
url: '../../../packageReceipt/pages/receipt/receipt',
})
} else {
wx.login({
success(res) {
app.globalData.userCode.miniCode = res.code;
_this.choose()
}
})
}*/
wx.login({
success(res) {
app.globalData.userCode.miniCode = res.code;
_this.choose()
}
});
});
},
/* 密码是否可见 */
pswShowOrHide() {
this.setData({
isView: !this.data.isView,
focus: true
})
},
// 改变input值
changeValue(e) {
let target = e.currentTarget.dataset.target
this.setData({
[target]: e.detail.value
})
},
// 清空input值
clearValue(e) {
let target = e.currentTarget.dataset.target
this.setData({
[target]: ''
})
},
forgetPassword() {
wx.navigateTo({
url: '../changePassword/changePassword',
})
},
/**
* 拒绝或者允许
*/
choose(e) {
/*let bool = e.target.dataset.value
// 0是拒绝 1是允许
if (bool == 0) {
delete app.globalData.userCode.miniCode
} else {
app.globalData.isBindWechat = true
}*/
app.globalData.isBindWechat = true
restapi.getWechatOpenId(app.globalData.userCode, res => {
console.log(res)
if(res.code == 2020) {
app.globalData.isBindWechat = false
app.showToast(res.message)
wx.login({
success(res) {
app.globalData.userCode.miniCode = res.code
console.log(res.code)
}
})
} else {
app.globalData.isPublicAuth = true;
wx.switchTab({
url: "/packageReceipt/pages/receipt/receipt"
})
}
})
},
toggleIsAgree(e){
this.setData({
isAgree: !this.data.isAgree
})
},
closeLoginGuide(){
this.setData({
loginGuideHidden: true
})
},
toAgree(){
wx.navigateTo({
url: '/pages/agree/agree'
})
},
})
\ No newline at end of file \ No newline at end of file
// bidOrder/pages/agree/agree.js
Page({
/**
* 页面的初始数据
*/
data: {
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady: function () {
},
/**
* 生命周期函数--监听页面显示
*/
onShow: function () {
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide: function () {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload: function () {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh: function () {
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom: function () {
},
/**
* 用户点击右上角分享
*/
onShareAppMessage: function () {
}
})
\ No newline at end of file \ No newline at end of file
/* packagePersonal/pages/idCard/idCard.wxss */
page{
background: #fafafa;
}
.id_card{
/*margin: 30rpx;*/
}
.id_card_info{
padding: 30rpx;
}
.id_card_title{
font-size: 30rpx;
}
.id_card_des{
color: #666;
margin: 5rpx 0;
font-size: 26rpx;
}
.id_card_upload{
background: #fff;
overflow: hidden;
padding: 30rpx;
}
.weui-uploader__input-box{
width: 100%;
height: 52vw;
margin: 0;
background-color: #efefef;
border: 1px dashed #ccc;
}
.weui-uploader__input{
background: transparent;
}
.img_wrap{
position: absolute;
width: 100%;
height: 100%;
z-index: 500;
overflow: hidden;
text-align: center;
background-color: #fff;
}
.img_wrap>image{
width: 100%;
height: 100%;
}
.weui-uploader__input-box:last-child{
margin-top: 30rpx;
}
.img_des{
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
margin-top: 40px;
color: #a3a3a3;
}
\ No newline at end of file \ No newline at end of file
.va_list_item{
display: flex;
background-color: #fff;
border-bottom: 2rpx solid #efefef;
padding: 10px 15px;
}
.va_list_item_info{
flex: 1;
text-align: right;
}
.va_list_item_status{
color: #666;
margin-bottom: 5px;
}
.va_list_item_price{
color: #000;
font-size: 18px;
}
\ No newline at end of file \ No newline at end of file
/* components/mainList/mainList.wxss */
@import "../../weui.wxss";
.mainlist_item{
color: #5b5b5b;
font-size: 28rpx;
background-color: #fff;
margin-bottom: 20rpx;
overflow-x: hidden;
}
.mli_top{
padding: 20rpx 40rpx;
border-bottom: 2rpx solid #efefef;
position: relative;
}
.mli_top-sn{
margin-left: 20rpx;
line-height: 60rpx;
}
.mli_btn{
display: inline-block;
color: #3DA5F5;
background-color: #DCE5FE;
padding: 4rpx 16rpx;
border-radius: 4rpx;
line-height: 52rpx;
}
.mli_btn.mli_btn_off{
color: #13BFD0;
background-color: #DCF9FE;
}
.mli_btn.mli_btn_check{
color: #3BBC94;
background-color: #DCFEE2;
}
.mli-icon{
width: 132rpx;
height: 132rpx;
}
.mli-device-info{
flex-direction: column;
justify-content: space-between;
margin-left: 10rpx;
flex: 1;
}
.mli-device-info .devicetype{
font-size: 32rpx;
}
.mli-device-info .ordertime{
color: #8C8D99;
}
.mli-label{
width: 5em;
}
.cancel-mark-icon{
position: absolute;
width: 172rpx;
height: 130rpx;
top: 50%;
right: -30rpx;
}
.mli-device{
margin: 0rpx 40rpx;
padding: 30rpx 0rpx;
border-bottom: 2rpx solid #efefef;
}
.mli-info{
padding: 20rpx 40rpx;
border-bottom: 2rpx solid #efefef;
}
.mli_bottom{
padding: 20rpx 40rpx;
text-align: right;
}
.mli-ctrl-btn{
display: inline-block;
width: 156rpx;
height: 68rpx;
line-height: 68rpx;
color: #3DA5F5;
border: 2rpx solid #3DA5F5;
border-radius: 36rpx;
margin: 0 10rpx;
text-align: center;
}
.mli-info-item{
margin-bottom: 10rpx;
}
.od_ctrl_btn{
box-sizing: border-box;
display: inline-block;
width: 25%;
color: #3DA5F5;
text-align: center;
}
.od_ctrl_btn>view{
border: 1px solid #3DA5F5;
border-radius: 18px;
margin: 4px 5px;
padding: 4px 0;
}
.od_ctrl_btn.od_ctrl_btn_disabled>view{
color: #ccc;
border-color: #ccc;
}
.icon_delete{
width: 36rpx;
height: 36rpx;
border-left: 1px solid #eee;
padding-left: 30rpx;
}
.mli_btn.mli_btn_bid{
color: #fff;
background-color: rgba(58, 153, 255, .7);
}
.mli-des{
word-break: break-all;
}
\ No newline at end of file \ No newline at end of file
<view class="op_card">
<view class="dt_item" wx:for="{{items}}" wx:key="{{item.id}}">
<view class="dt_item_line">【{{item.user.name}}】 {{item.relItem.type}}</view>
<block wx:for="{{item.relItem.group}}" wx:for-item="labelItem" wx:key="{{index}}">
<view class="dt_item_line" hidden="{{labelItem.allowEmpty&&!item[labelItem.prop[0]]}}">
<text class="op_label">{{labelItem.label}}: </text>
<text class="op_value" wx:for="{{labelItem.prop}}" wx:for-item="propItem" wx:key="{{index}}">{{item[propItem]}}</text>
</view>
</block>
<view class="dt_item_time">{{item.updateTime}}</view>
</view>
<view wx:if="{{!isInit}}">正在加载中...</view>
<view wx:if="{{items.length===0&&isInit}}">数据为空</view>
</view>
<!-- <view class="container">
<view class="cube">
<view class="plane-front"></view>
<view class="plane-back"></view>
<view class="plane-left"></view>
<view class="plane-right"></view>
<view class="plane-top"></view>
<view class="plane-bottom"></view>
</view>
</view> -->
\ No newline at end of file \ No newline at end of file
/* components/cityPicker/cityPicker.wxss */
\ No newline at end of file \ No newline at end of file
page{
background: #fff;
padding-bottom: 60px;
}
.od_page{
background-color: #fff;
}
.od_page_top{
height: 20px;
background-size: 100% 20px;
background-image:url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAu4AAABSCAYAAAALilHtAAAQZElEQVR4Xu3d3ZMc1XnH8e/Ts9IKJCIRBEG8iBc5REkkcCESIycGLyApduDK2JeBQBXlSsoXqfIfoD/AVblwxeVSlQm+teEKYkcSIAs7Fo4RZZAcK4TlZXkRQSKIWAva1U4/qdO7S8Ah1tvs7vTsd7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49TQAEFFFBAAQUUUECB3grcuzs3lhAP3P0/uwxxMEYS3toAAAAASUVORK5CYII=');
background-repeat: none;
}
.od_page_top:before{
}
.od_page_title{
color: #333;
font-size: 24px;
text-align: center;
padding-top: 10px;
}
.od_icon{
width: 46px;
height: 42px;
}
.od_item_gp{
padding: 15px 0;
margin: 0 15px;
border-bottom: 1px solid #EFEFEF;
}
.od_item{
display: flex;
margin: 5px 0;
}
.od_item_label{
color: #999;
min-width: 100px;
}
.od_item_content{
flex: 1;
color: #191919;
word-break: break-word;
}
.od_item_photo_content{
margin-right: -8px;
padding-top: 5px;
font-size: 0;
}
.install_image{
width: calc((100vw - 130px - 2*8px)/3);
height: calc((100vw - 130px - 2*8px)/3);
margin-right: 8px;
margin-bottom: 8px;
}
.phone{
color: #3DA5F5;
}
.od_ctrl{
box-sizing: border-box;
position: fixed;
width: 100%;
left: 0;
bottom: 0;
border-top: 2px solid #efefef;
padding: 10px;
background-color: #fff;
z-index: 1000;
text-align: right;
}
.od_ctrl_btn{
box-sizing: border-box;
display: inline-block;
width: 25%;
color: #3DA5F5;
text-align: center;
}
.od_ctrl_btn>view{
border: 1px solid #3DA5F5;
border-radius: 18px;
margin: 4px 5px;
padding: 4px 0;
}
.od_ctrl_btn.od_ctrl_btn_disabled>view{
color: #ccc;
border-color: #ccc;
}
.tag_item{
display: inline-block;
color: #5EB9FF;
padding: 2px 8px;
margin: 6px 0 6px 6px;
border-radius: 14px;
border:1px solid #5EB9FF;
}
.price{
color: #5EB9FF;
}
.devicelist_item{
padding-bottom: 10rpx;
margin-bottom: 10rpx;
border-bottom: 1px solid #eee;
}
.devicelist_item:last-child{
padding-bottom: 0;
margin-bottom: 0;
border-bottom: none;
}
.devicelist_item_sn{
}
\ No newline at end of file \ No newline at end of file
{
"navigationBarTitleText": "选择物流公司",
"usingComponents": {}
}
\ No newline at end of file \ No newline at end of file
{
"navigationBarTitleText": "扫描银行卡",
"usingComponents": {}
}
\ No newline at end of file \ No newline at end of file
/*订单类型*/
const ORDER_TYPE = {
'1': '安装单',
'INSTALL': 1,
'2': '拆除单',
'TAKEOFF': 2,
'3': '检修单',
'REPAIR': 3,
'4': '竞价单',
'BID': 4,
'6': '车务单',
'VEHICLE': 6,
}
/*订单菜单状态*/
const ORDER_MENU_STATUS = {
'0': '待接单',
'RECEIPT': '0',
'1': '已完成',
'COMPLETE': '1',
'2': '待完成',
'TOCOMPLETE': '2'
}
/*订单状态*/
const ORDER_STATUS = {
'1': '已下单',
'2': '已派单',
'3': '服务商拒单',
'4': '已派单',
'5': '技工拒单',
'6': '已接单',
'7': '已预约',
'8': '已完成',
'110': '重新指派技工',
'115': '修改安装地址',
'120': '重新预约',
'125': '已上门',
}
const ORDER_IS_CANCELlED = 0; //订单已取消
const ORDER_ISNOT_CANCELlED = 1;
const USER_VERIFY_STATUS = {
'sys_user_status_checking': '认证中',
'VERIFYING': 'sys_user_status_checking',
'sys_user_status_uncheck': '未认证',
'UNVERIFY': 'sys_user_status_uncheck',
'sys_user_status_pass_check': '已认证',
'DONEVERIFY': 'sys_user_status_pass_check',
}
const VERIFY_ACCOUNT_STATUS = {
'10': '待确认',
'20': '待运营审核',
'30':'待财务打款',
'40': '财务已打款'
}
const NEED_LOCATE_SERVICECODE = ['001','002', '003', '004', '005', '006', '007','DSC1000','DSC0100','DSC0010','DSC1010','DSC0200','DSC1100','DSC1110','DSC0210']
const DSC_INSTALL_LOCATION = {
'sys_order_service_item_other_dasouche': ['其他'],
'sys_order_service_item_tiny_dasouche': ['5、雨刷电机下方',
'6、后视镜镜片后方左右',
'7、上横梁夹层内侧左右',
'8、C柱夹层内侧左右',
'9、后尾灯内侧',
'10、后排座椅靠背头枕内',
'11、后围板夹层',
'12、后排座椅靠背',
'14、副驾座椅靠背',
'15、顶棚前方夹层',
'18、空调蒸发箱后侧'
],
'sys_order_service_item_wireline_dasouche': ['1、大灯后',
'2、发动机舱右侧',
'3、导航后',
'4、仪表盘后',
'13、副驾后门边压条',
'16、副驾前门边压条',
'17、副驾驶杂物箱后'
],
'sys_order_service_item_wireless_dasouche': ['5、雨刷电机下方',
'6、后视镜镜片后方左右',
'7、上横梁夹层内侧左右',
'8、C柱夹层内侧左右',
'9、后尾灯内侧',
'10、后排座椅靠背头枕内',
'11、后围板夹层',
'12、后排座椅靠背',
'14、副驾座椅靠背',
'15、顶棚前方夹层',
'18、空调蒸发箱后侧'
],
'default': ['后备箱保险盒', '副驾驶保险盒', '主驾驶保险盒', '后排真皮椅座下部', '主驾驶侧-仪表台外侧饰板内部', '副驾驶仪表台底部侧面', '后备箱盖内部', '副驾驶储物盒内部', '后备箱刹车灯附近', '手套箱', '其他'],
}
const AUDIT_STATUS = {
1: '待审核',
2: '已退回',
3: '正常通过',
4: '退回通过',
}
module.exports = {
ORDER_TYPE,
ORDER_STATUS,
ORDER_MENU_STATUS,
ORDER_IS_CANCELlED,
ORDER_ISNOT_CANCELlED,
USER_VERIFY_STATUS,
VERIFY_ACCOUNT_STATUS,
NEED_LOCATE_SERVICECODE,
DSC_INSTALL_LOCATION,
AUDIT_STATUS
}
\ No newline at end of file \ No newline at end of file
{
"usingComponents": {},
"navigationBarTitleText": "订单明细"
}
\ No newline at end of file \ No newline at end of file
<!--pages/active/activeList/activeList.wxml-->
<view class="activeList list">
<form bindsubmit="comfirmBind">
<view class="title">设备</view>
<view class="list_cells">
<view class="list_cell">
<view class="required">*</view>
<view class="list_cell_bd">{{activeForm[0].label}}</view>
<input class="list_r" name="{{activeForm[0].name}}" placeholder-class="placeholder" placeholder="请输入设备SN">{{deviceInfo.value}}</input>
</view>
<view class="list_cell">
<view class="required">*</view>
<view class="list_cell_bd">{{activeForm[1].label}}</view>
<view class="list_r">
<picker name="{{activeForm[1].name}}" class="weui-cell__ft_in-access" bindchange="changeInstallLocation" value="{{installLocation[posIdx]}}" range="{{installLocation}}">
<input disabled="true" placeholder-class="placeholder" placeholder="{{item.placeholder}}" value="{{installLocation[posIdx]}}"></input>
</picker>
</view>
</view>
<view wx:if="{{installLocation[posIdx] == '其他'}}" class="list_cell">
<view class="required">*</view>
<view class="list_cell_bd"></view>
<view class="list_r">
<input name="otherLocaltion" placeholder-class="placeholder" placeholder="请输入安装位置"></input>
</view>
</view>
</view>
<view wx:if="{{userInput.orderType == '1'}}" class="title">车辆信息</view>
<view wx:if="{{userInput.orderType == '1'}}" class="list_cells">
<view class="list_cell">
<view class="required">*</view>
<view class="list_cell_bd">{{activeForm[2].label}}</view>
<input disabled="{{userInput.vinNo ? true : false}}" class="list_r" bindblur="" maxlength="17" name="{{activeForm[2].name}}" value="{{activeForm[2].value}}" placeholder-class="placeholder" placeholder="请输入17位车架号"></input>
</view>
<view class="list_cell">
<view class="list_cell_bd">{{activeForm[3].label}}</view>
<textarea class="list_r" name="{{activeForm[3].name}}" placeholder-class="placeholder" placeholder="请输入安装备注"></textarea>
</view>
</view>
<view wx:if="{{userInput.orderType == '1'}}">
<view class="title">
<text>我的位置</text>
<text wx:if="{{unset}}" class="tip">您未开启小程序的定位功能</text>
<text wx:if="{{unset}}" bindtap="toqa" class="link">【如何开启】</text>
</view>
<view class="adr"><text>{{address||'地址无法获取'}}</text></view>
<view>
<locateMap
bind:unset="unset"
bind:locateChange="locateChange"
showLocation="{{showLocation}}"
longitude="{{longitude}}"
latitude="{{latitude}}"
scale="{{scale}}">
</locateMap>
</view>
</view>
<!-- <view class="btn_mg">
<button class="btn" form-type="submit">下一步</button>
</view> -->
<cover-view class="od_ctrl">
<button class="od_ctrl_btn" form-type="submit">下一步</button>
</cover-view>
</form>
</view>
\ No newline at end of file \ No newline at end of file
const restapi = require('../../utils/restapi.js')
const util = require('../../utils/util.js')
var app = getApp()
Page({
/**
* 页面的初始数据
*/
data: {
orderId: '',
keyWord: '',
isLoading: true,
pageIndex: 1,
hasNext: false,
list: [],
STATUS: {
TOCOMPLETE: 1,
FINISHED: 2,
CANCELED: 9
}
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
let queryBean = JSON.parse(options.queryBean);
const orderId = queryBean.id;
this.setData({
orderId
})
this.getList()
},
getList(prevArr = []) {
const params = {
orderId: this.data.orderId,
keyword: this.data.keyWord,
pageIndex: this.data.pageIndex,
pageSize: app.globalData.pageSize
}
restapi.getSubCarOrderList(params, res => {
const data = res.data;
let arr = [...prevArr, ...data.items]
/* arr.forEach(item => {
item.src = util.getDeviceIcon(item.deviceType),
item.btns = [{
name: '订单详情',
url: `../../../pages/detailed/detailed`
}]
}) */
console.log(this.data.i)
this.setData({
list: arr,
hasNext: data.page.hasNext,
isLoading: false
});
wx.stopPullDownRefresh()
})
},
deal(e){
let queryBean = {
orderId: this.data.orderId,
subOrderId: e.currentTarget.dataset.id
}
wx.navigateTo({
url: `/pages/dealVehicle/dealVehicle?queryBean=${JSON.stringify(queryBean)}`
})
},
// 搜索
search(e) {
this.setData({
keyWord: e.detail,
isLoading: true,
pageIndex: 1,
list: []
});
this.getList()
},
clear(e) {
this.setData({
keyWord: ''
})
this.onPullDownRefresh()
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady: function () {
},
/**
* 生命周期函数--监听页面显示
*/
onShow: function () {
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide: function () {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload: function () {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh: function () {
this.setData({
list: [],
isLoading: true,
hasNext: true,
pageIndex: 1
})
this.getList()
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom: function () {
if (this.data.hasNext) {
this.setData({
pageIndex: this.data.pageIndex + 1,
isLoading: true
})
this.getList(this.data.list)
}
},
/**
* 用户点击右上角分享
*/
onShareAppMessage: function () {
}
})
\ No newline at end of file \ No newline at end of file
<view class="al_ctrl_wrap">
<view class="al_ctrl_btn" bindtap="addAddress"><image src="../../../images/plus_s.png" class="icon_plus"></image>新增收货地址</view>
</view>
<view class="al_list">
<view class="al_list_item" wx:for="{{list}}" >
<image class="al_icon_locate" src="../../../images/locate.png"></image>
<view class="al_list_item_info" data-item="{{item}}" bindtap="choose">
<view class="al_list_item_main">
<text>{{item.name}}</text>
<text class="al_list_item_tel">{{item.phone}}</text>
</view>
<view class="al_list_item_adr">{{item.cityName}}{{item.address}}</view>
</view>
<view class="al_list_item_edit" data-id="{{item.id}}" data-address="{{item.address}}" data-name="{{item.name}}" data-phone="{{item.phone}}" data-multiids="{{item.multiids}}" bindtap="editAddress">编辑</view>
</view>
</view>
\ No newline at end of file \ No newline at end of file
page{
background: #fff;
}
.al_list{
}
.al_list_item{
display: flex;
align-items: center;
padding: 30rpx 0 30rpx 30rpx;
border-bottom: 1px solid #E0E7EE;
}
.al_icon_locate{
width: 100rpx;
height: 100rpx;
margin-right: 20rpx;
}
.al_list_item_info{
flex: 1;
}
.al_list_item_edit{
padding: 20rpx 30rpx 20rpx 20rpx;
border-left: 1px solid #efefef;
color: #999;
}
.al_list_item_tel{
color: #999;
margin-left: 20rpx;
}
\ No newline at end of file \ No newline at end of file
{
"usingComponents": {}
}
\ No newline at end of file \ No newline at end of file
<view class="weui-gallery {{show ? 'weui-gallery_show' : ''}} {{extClass}}">
<view class="weui-gallery__info">{{current+1}}/{{imgUrls.length}}</view>
<swiper class="weui-gallery__img__wrp" bindtap="hideGallery" indicator-dots="{{false}}" bindchange="change" current="{{current}}" autoplay="{{false}}" duration="{{500}}">
<block wx:for="{{imgUrls}}" wx:key="{{item + '-' +index}}">
<swiper-item>
<image mode="aspectFit" class="weui-gallery__img" src="{{item}}"></image>
</swiper-item>
</block>
</swiper>
<view class="weui-gallery__opr" wx:if="{{delete}}">
<navigator href="javascript:" bindtap="deleteImg" class="weui-gallery__del">删除</navigator>
</view>
</view>
{
"navigationBarTitleText": "实名认证",
"usingComponents": {}
}
\ No newline at end of file \ No newline at end of file
/* pages/register/registerBind/registerBind.wxss */
// pages/webpage/webpage.js
const restapi = require('../../utils/restapi.js')
var app = getApp()
Page({
/**
* 页面的初始数据
*/
data: {
jumpLink: ''
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
if('orderId' in options){
wx.setStorageSync('takeOrderId', options.orderId)
}
let domain = restapi.domain.split('//')[1]
let url = `https://open.weixin.qq.com/connect/oauth2/authorize?appid=wx93785bf5cd95e63f&redirect_uri=https%3a%2f%2f${domain}%2fcarservice%2fusercenter%2ftakeorder.html&response_type=code&scope=snsapi_base&state=STATE#wechat_redirect`
this.setData({
jumpLink: url
});
},
/**
* 接收H5传过来的参数
*/
onMessage(e) {
console.log("onMessage", e)
},
onShow: function () {
},
onUnload: function () {
}
})
\ No newline at end of file \ No newline at end of file
<groupSelect groups='{{list}}' groupTitle='braLetter' itemText='name' itemId='bid' bind:select="select" showSidebar="false"
></groupSelect>
\ No newline at end of file \ No newline at end of file
{
"navigationBarTitleText": "发货/修改物流",
"usingComponents": {},
"navigationBarBackgroundColor": "#5EB9FF",
"navigationBarTextStyle": "white"
}
\ No newline at end of file \ No newline at end of file
// components/detailedList/detailedList.js
import Util from '../../utils/util.js'
Component({
/**
* 组件的属性列表
*/
properties: {
detailed: Array
},
/**
* 组件的初始数据
*/
data: {
},
/**
* 组件的方法列表
*/
methods: {
previewImage(e) {
let current = e.currentTarget.dataset.src
let urls = e.currentTarget.dataset.urls
let arr = []
urls.forEach(e => {
arr.push(e)
})
wx.nextTick(() => {
wx.previewImage({
urls: arr, // 需要预览的图片http链接列表
current: current
})
})
},
eventsFunc(e){
console.log(e.currentTarget.dataset)
var eventsName = e.currentTarget.dataset.eventsname,
eventsParmas = e.currentTarget.dataset.eventsparmas;
Util[eventsName](eventsParmas);
}
}
})
\ No newline at end of file \ No newline at end of file
/* hardwareAdmin/pages/myStock/myStock.wxss */
\ No newline at end of file \ No newline at end of file
<view class="status-bar">
<view wx:for="{{list}}" class="status-bar-part{{index<idx?' status-done':''}}{{index==idx?' status-done status-done-last':''}}">
<view class="status-dot"></view>
<view>{{item}}</view>
</view>
<!-- <view class="status-bar-part status-done status-done-last">
<view class="status-dot"></view>
<view>待审核</view>
</view>
<view class="status-bar-part">
<view class="status-dot"></view>
<view>待审核</view>
</view>
<view class="status-bar-part">
<view class="status-dot"></view>
<view>待审核</view>
</view> -->
</view>
<!--components/searchBox/searchBox.wxml-->
<view class='search-box'>
<view class='search'>
<input placeholder='{{placeholder}}' confirm-type='search' type='text' bindconfirm='search' value='{{inputValue}}' bindinput='handleInput' maxlength='50'></input>
<view class='search-img' bindtap="clear" hidden='{{!inputValue}}'>
<icon type='clear' size='32rpx'></icon>
</view>
</view>
<view class='search-btn' bindtap='search'>搜索</view>
</view>
const restapi = require('../../../utils/restapi.js')
const app = getApp()
const moment = require('../../../utils/moment.min.js');
Page({
/**
* 页面的初始数据
*/
data: {
isLoading: true,
// 加载的数据
list: [],
// 分页
pageIndex: 1,
// 是否有下一页
hasNext: false,
deviceType: '',
name: '',
sortType: 1,
sortFilter: [{
label: '降序',
value: 1
},{
label: '升序',
value: 2
}],
},
getParams() {
return {
deviceType: this.data.deviceType,
name: this.data.name,
sortType: this.data.sortType,
pageIndex: this.data.pageIndex,
pageSize: app.globalData.pageSize
}
},
// 搜索
search(e) {
this.setData({
name: e.detail,
isLoading: true,
pageIndex: 1,
list: []
});
this.getList()
},
leftFilterChange(e) {
this.setData({
deviceType: e.detail,
list: [],
isLoading: true,
pageIndex: 1
});
this.getList()
},
rightFilterChange(e) {
this.setData({
sortType: e.detail,
list: [],
isLoading: true,
pageIndex: 1
});
this.getList()
},
clear(e) {
this.setData({
name: ''
})
this.onPullDownRefresh()
},
getList(prevArr = []) {
const params = this.getParams()
restapi.getWorkerStockList(params, res => {
const data = res.data;
let arr = [...prevArr, ...data.items]
this.setData({
list: arr,
hasNext: data.page.hasNext,
isLoading: false
});
wx.stopPullDownRefresh()
})
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function(options) {
this.getList()
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady: function() {
},
/**
* 生命周期函数--监听页面显示
*/
onShow: function() {
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide: function() {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload: function() {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh: function() {
this.setData({
list: [],
isLoading: true,
hasNext: true,
pageIndex: 1
})
this.getList()
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom: function() {
if (this.data.hasNext) {
this.setData({
pageIndex: this.data.pageIndex + 1,
isLoading: true
})
this.getList(this.data.list)
} else {
/*this.setData({
searchLoadingComplete: true,
searchLoading: false
})*/
}
},
/**
* 用户点击右上角分享
*/
onShareAppMessage: function() {
}
})
\ No newline at end of file \ No newline at end of file
// packageProfile/changePhone/phoneShow/phoneShow.js
Page({
/**
* 页面的初始数据
*/
data: {
userInfo: '',
showPhone: ''
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
// console.log(options)
this.data.userInfo = JSON.parse(options.userInfo)
let phone = this.data.userInfo.phoneNumber
this.setData({
showPhone: phone
})
},
submit() {
wx.navigateTo({
url: '../phoneVerify/phoneVerify?userInfo=' + JSON.stringify(this.data.userInfo),
})
}
})
\ No newline at end of file \ No newline at end of file
.device_input{
width: 500rpx;
margin-left: 20rpx;
}
.delete_btn {
}
.device-add{
display: flex;
}
.device-add-icon{
width: 100px;
}
.device-add-icon image{
width: 60rpx;
height: 60rpx;
}
.device-add-edit{
flex: 1;
}
.device-edit-bar{
position: fixed;
bottom: 0px;
left: 0px;
width: 100%;
height: 100px;
background-color: #ccc;
}
.icon_minus, .icon_plus{
width: 48rpx;
height: 48rpx;
margin-left: 30rpx;
}
.device_edit_item{
background-color: #fff;
border-top: 1px solid #efefef;
}
.device_edit_item:last-child{
border-bottom: 1px solid #efefef;
}
.device_input{
flex: 1;
height: 100%;
line-height: 100rpx;
color: #3DA5F5;
font-size: 32rpx;
display: flex;
align-items: center;
}
.device_input input{
display: inline-block;
color: #333;
width: 280rpx;
height: 100%;
}
.device_input .error_tip{
flex: 1;
text-align: right;
margin-right: 30rpx;
color: #FF7B7B;
font-size: 28rpx;
}
.device_item_content{
display: flex;
align-items: center;
height: 100rpx;
position: relative;
left: 0;
}
.device_item_content.delete_show{
left: -160rpx;
animation: deleteshow .3s;
-webkit-animation: deleteshow .3s; /* Safari 和 Chrome */
}
.device_item_content.delete_hide{
left: 0;
animation: deletehide .3s;
-webkit-animation: deletehide .3s; /* Safari 和 Chrome */
}
.delete_btn{
position: absolute;
top: 0;
right: -160rpx;
width: 160rpx;
height: 100rpx;
background-color: #FF7B7B;
color: #fff;
font-size: 28rpx;
text-align: center;
line-height: 100rpx;
}
.ctrl-bottom{
position: fixed;
width: 100%;
bottom: 0;
left:0;
background-color: #fff;
padding: 20px 0;
border-top: 2px solid #eee;
display: flex;
}
.ctrl-info{
flex: 1;
margin-left: 20px;
align-self: center;
}
.ctrl-info text:nth-child(2){
margin-left: 20px;
}
.ctrl-btn{
display: inline-block;
padding: 6px 24px;
color: #3DA5F5;
border: 1px solid #3DA5F5;
border-radius: 18px;
margin: 0 20px;
font-size: 14px;
}
.scan_btn{
position: fixed;
width: 80px;
height: 80px;
bottom: 84px;
left: 50%;
transform: translateX(-50%);
}
@keyframes deleteshow
{
from {
left: 0;
}
to {
left: -160rpx;
}
}
@-webkit-keyframes deleteshow /* Safari 与 Chrome */
{
from {
left: 0;
}
to {
left: -160rpx;
}
}
@keyframes deletehide
{
from {
left: -160rpx;
}
to {
left: 0;
}
}
@-webkit-keyframes deletehide /* Safari 与 Chrome */
{
from {
left: -160rpx;
}
to {
left: 0;
}
}
\ No newline at end of file \ No newline at end of file
/* pages/active/activeUploadImg/activeUploadImg.wxss */
.activeUploadImg .list .title {
color: #333333;
}
\ No newline at end of file \ No newline at end of file
// verifyAccount/orderDetail/orderDetail.js
const restapi = require('../../utils/restapi.js')
const util = require('../../utils/util.js')
const ORDER_TYPE = require('../../utils/constant').ORDER_TYPE;
const ORDER_MENU_STATUS = require('../../utils/constant').ORDER_MENU_STATUS;
const moment = require('../../utils/moment.min.js');
const {VERIFY_ACCOUNT_STATUS} = require('../../utils/constant');
const app = getApp()
Page({
/**
* 页面的初始数据
*/
data: {
orderStatus: '',
detailHidden: true,
list: [
{
isShow: true,//0
items: [{
label: '店面名称',
key: 'merchantInfo.name',
value: 'xxx'
},{
label: '联系人',
key: 'contact'
},{
label: '联系方式',
key: 'phoneNumber',
type: 'phone'
},{
label: '订单地址',
key: 'areaAddress'
},{
label: '下单时间',
key: 'createTime'
},{
label: '期望服务日期',
key: 'expectInstallTime'
},{
label: '服务项目',
key: 'installDeviceTypeName'
},{
label: '订单类型',
key: 'orderTypeValue'
},{
label: '订单编号',
key: 'orderSn'
},{
label: '第三方合同号',
key: 'workOrderNo'
},{
label: '检修原因',
key: 'repairReason',
hidden: true
}]
},{
isShow: true,//1
items: [{
label: '品牌车型',
key: 'brandModel'
},{
label: '车身颜色',
key: 'carColor'
},{
label: '车架号',
key: 'vinNo'
}]
},{
isShow: true,//2
items: [{
label: '车主',
key: 'carOwner'
},{
label: '联系方式',
key: 'carOwnerPhone',
type: 'phone'
}]
},{
isShow: true,//3
items: [{
label: '设备编码',
key: 'orderDevices',
type: 'devicelist'
}]
},{
isShow: true,//4
items: [{
label: '完成时间',
key: 'completeTime'
},{
label: '安装备注',
key: 'installRemark'
},{
label: '安装照片',
key: 'installPiuctures',
type: 'photo'
}]
}
],
VERIFY_ACCOUNT_STATUS,
statementStatus: ''
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
if('params' in options){
const {actualSettlement,advanceAmount,standardAmount,subsidyAmount,id,statementStatus} = JSON.parse(options.params);
this.setData({
actualSettlement: parseFloat(actualSettlement).toFixed(2),
advanceAmount: parseFloat(advanceAmount).toFixed(2),
standardAmount: parseFloat(standardAmount).toFixed(2),
subsidyAmount: parseFloat(subsidyAmount).toFixed(2),
id,
statementStatus
})
console.log(this.data.id)
this.getDetail()
}
},
getDetail(){
const that = this;
let getDeviceTypePromise = util.getDeviceTypeArr();
let getReserveReasonPromise = util.getReserveReasonArr();
let deviceTypesArr;
Promise.all([getDeviceTypePromise]).then((values)=>{
deviceTypesArr = values[0];
//reserveReasonArr = values[1];
const data = that.data;
const _list = data.list;
restapi.getOrderDetail({id: data.id}, res => {
const obj = res.data;
const orderStatus = util.getOrderStatus(obj.activeStatus, obj.orderType);
if(obj.canceled === 0){//是取消单
data.orderStatusValue = '已取消';
data.orderStatusIcon = 'cancel';
data.isCancel = true;
}else{
if(orderStatus === ORDER_MENU_STATUS.COMPLETE){
data.orderStatusValue = '已完成';
data.orderStatusIcon = 'complete';
}else if(orderStatus === ORDER_MENU_STATUS.TOCOMPLETE){
data.orderStatusValue = '待完成';
data.orderStatusIcon = 'tocomplete';
}else if(orderStatus === ORDER_MENU_STATUS.RECEIPT){
data.orderStatusValue = '待接单';
data.orderStatusIcon = 'receipt';
}
data.isCancel = false;
}
that.setData({
orderStatus,
orderStatusValue: data.orderStatusValue,
orderStatusIcon: data.orderStatusIcon,
isCancel: data.isCancel,
});
if (obj.activeStatus === 8) {//显示安装信息 8-已完成状态
_list[4].isShow = true;
if(obj.orderType === ORDER_TYPE.TAKEOFF || (obj.orderType === ORDER_TYPE.REPAIR&&obj.repairType===0)){
_list[4].items[2].hidden = true;
}else{
_list[4].items[2].hidden = false;
}
}else{
_list[4].isShow = false;
}
obj.expectInstallTime = moment(obj.expectInstallTime).format('YYYY-MM-DD');
if(data.orderStatus === ORDER_MENU_STATUS.TOCOMPLETE && (obj.orderType === ORDER_TYPE.REPAIR || obj.orderType === ORDER_TYPE.TAKEOFF)){
_list[3].isShow = true;
}else if(data.orderStatus === ORDER_MENU_STATUS.COMPLETE){
_list[3].isShow = true;
}else{
_list[3].isShow = false;
}
if(obj.orderDevices && obj.orderDevices.length){
obj.orderDevices.forEach((item)=>{
item.deviceTypeValue = util.getDictValueByKey(deviceTypesArr, item.deviceType);
})
}
if (obj.carInfo != null) {
obj.carInfo.brand = obj.carInfo.brand == null ? '' : obj.carInfo.brand
obj.carInfo.series = obj.carInfo.series == null ? '' : obj.carInfo.series
obj.carInfo.type = obj.carInfo.type == null ? '' : obj.carInfo.type
obj.brandModel = obj.carInfo.type == '' ? `${obj.carInfo.brand}\\${obj.carInfo.series}` : obj.brandModel = `${obj.carInfo.brand}\\${obj.carInfo.type}`
} else {
obj.brandModel = obj.carType
}
obj.areaAddress = obj.city ? (util.getCityNameByObj(obj.city)+obj.address) : obj.address;
obj.orderTypeValue = ORDER_TYPE[obj.orderType];
that.data.list.forEach((listItem)=>{
listItem.items.forEach((formItem)=>{
if(formItem.key === 'repairReason'){
if(obj.orderType === ORDER_TYPE.INSTALL){
formItem.hidden = true;
}else if(obj.orderType === ORDER_TYPE.TAKEOFF){
formItem.label = '拆除原因';
formItem.hidden = false;
}else if(obj.orderType === ORDER_TYPE.REPAIR){
formItem.label = '检修原因';
formItem.hidden = false;
}
}else if(formItem.key === 'installRemark'){
if(obj.orderType === ORDER_TYPE.INSTALL){
formItem.label = '安装备注';
}else if(obj.orderType === ORDER_TYPE.TAKEOFF){
formItem.label = '拆除备注';
}else if(obj.orderType === ORDER_TYPE.REPAIR){
formItem.label = '检修备注';
}
formItem.hidden = false;
}else if(formItem.key === 'deviceNo'||formItem.key === 'installLocation'){
if(obj.orderType === ORDER_TYPE.INSTALL||obj.orderType === ORDER_TYPE.REPAIR){
formItem.hidden = false;
}else{
formItem.hidden = true;
}
}
let _content;
if(formItem.key.indexOf('.')>-1){
const keyArr = formItem.key.split('.');
let _stain;
for(let i=0; i<keyArr.length; i++){
const key = keyArr[i]
if(i===0){
_stain = obj[key];
}else{
if(!_stain){
break;
}else{
_stain = _stain[key]
}
}
}
_content = _stain;
}else{
_content = obj[formItem.key];
}
if(formItem.type === 'photo'){
formItem.content = _content
}else{
formItem.content = _content || '--';
}
if(formItem.type === 'phone' && !_content){
delete formItem.type
}
});
});
that.setData({
list: that.data.list,
obj
});
wx.hideNavigationBarLoading()
wx.stopPullDownRefresh()
});
});
},
toggle(){
this.setData({
detailHidden: !this.data.detailHidden
})
},
previewImage(e) {
let current = e.currentTarget.dataset.src
let urls = e.currentTarget.dataset.urls
let arr = []
urls.forEach(e => {
arr.push(e)
})
wx.nextTick(() => {
wx.previewImage({
urls: arr, // 需要预览的图片http链接列表
current: current
})
})
},
callPhone(e){
util.callPhone(e.currentTarget.dataset.phone)
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady: function () {
},
/**
* 生命周期函数--监听页面显示
*/
onShow: function () {
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide: function () {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload: function () {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh: function () {
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom: function () {
},
/**
* 用户点击右上角分享
*/
onShareAppMessage: function () {
}
})
\ No newline at end of file \ No newline at end of file
/* components/loading/loading.wxss */
.loading{
padding: 10rpx;
text-align: center;
}
.loading:before{
display: inline-block;
margin-right: 5rpx;
vertical-align: middle;
content: '';
width: 40rpx;
height: 40rpx;
background: url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADwAAAA8CAMAAAANIilAAAAC91BMVEX////////7+/v39/f19fXt7e3p6enb29vX19fV1dXPz8/MzMzBwcGlpaWdnZ2Pj492dnb////7+/v5+fn39/fz8/Px8fHt7e3p6enl5eXh4eHb29vPz8/////7+/v5+fn39/fz8/Px8fHv7+/t7e3p6enn5+fh4eHd3d3b29vX19fR0dHMzMy/v7+1tbWzs7Opqamjo6Ofn5+dnZ2ZmZmPj498fHx6enp2dnb////7+/v5+fn39/f19fXz8/Px8fHv7+/p6enn5+fl5eXh4eHb29vZ2dnX19fV1dXJycm1tbWtra3////7+/v5+fn39/f19fXx8fHt7e3r6+vp6end3d3JycnHx8fFxcW5ubmzs7P////7+/v39/fz8/Px8fHt7e3r6+vn5+fd3d3X19f////7+/v39/fz8/Px8fHv7+/t7e3p6enn5+fh4eHf39/b29vZ2dnX19fHx8enp6ePj4/////7+/vz8/Px8fHv7+/p6enn5+fh4eHb29vX19fDw8O/v7+rq6v////7+/vt7e3n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2xrTrG1ILIjVm/j3Z2qx2OPbpb4+kqsBCj/rz4I/ZPwNqjsOc2mewbeLUOwJU53Mgf7OzpUfczmQlfp807QxRvr8MtOI7vA61Vcrl+H0xgbR3AE9N/J6ULaJ5LfVqtgmzTqaB5U5Ncr68Uw7IFcGVuYmJPmpn6LCfRQ9P2SjQGy+V1AEYrofH92VMsDTTPDoX/mI4kw4gIpqz2cXSKdSUHwrj/HASJ22ZhbBsrLRFkpz0JdfFvsQkwMn0blH5JEJ7tB7ClaVHs3Y3Atb4udu6RssYLhYzPhcL2j7FxWM7Boo8gvF9oj5sD0mXRc+XA2eZOXLmstEgAnlHkj8pLsFQwVgIHLfxFaXGGNDGu5DGDZEql0kPYDw+GDzHS9YCuPdyt/SG9vE6oJv8DNSseogTcN24AAAAASUVORK5CYIIvKiAgfHhHdjAwfGVlN2U1ZDdmNDU0NGFmMjNlNDlkMGU2OGVkNjNiY2IwICov') no-repeat;
background-size: contain;
animation: rotate 1s linear infinite;
}
.loading.complete:before{
display: none;
}
\ No newline at end of file \ No newline at end of file
{
"navigationBarTitleText": "拍照核验",
"usingComponents": {
"imgUpload": "../../../../components/imgUpload/imgUpload"
}
}
\ No newline at end of file \ No newline at end of file
{
"navigationBarTitleText": "订货单",
"enablePullDownRefresh": true,
"usingComponents": {}
}
\ No newline at end of file \ No newline at end of file
<view class="hw-bg">
<view class="hw-card">
<view class="dt_info">物流公司:{{detail.expressCompany}}</view>
<view class="dt_info">物流单号:{{detail.exNo}}</view>
</view>
<view class="hw-card">
<view class="dt_item" wx:for="{{detail.traces}}">
<view class="dt_item_adr">{{item.acceptStation}}</view>
<view class="dt_item_time">{{item.acceptTime}}</view>
</view>
</view>
</view>
<!--pages/agree/index.wxml-->
<web-view src="{{pageUrl}}"></web-view>
\ No newline at end of file \ No newline at end of file
{
"usingComponents": {
"imgUpload": "../../../../components/imgUpload/imgUpload"
}
}
\ No newline at end of file \ No newline at end of file
.stockList-item{
font-size: 28rpx;
display: -webkit-box;
display: -webkit-flex;
display: flex;
padding: 15rpx 30rpx;
background-color: #fff;
border-bottom: 2rpx solid #eee;
line-height: 1.8;
}
.stockList-item_center{
align-items: center;
}
.stockList-item_date{
font-size: 24rpx;
color: #999;
}
.stockList-item_lt{
-webkit-box-flex: 1;
-webkit-flex: 1;
flex: 1;
}
.stockList-count{
font-size: 28rpx;
padding: 10rpx 30rpx;
}
.stockList-item_rt.access:after{
content: " ";
display: inline-block;
height: 8px;
width: 8px;
border-width: 2px 2px 0 0;
border-color: #B2B2B2;
border-style: solid;
-webkit-transform: matrix(0.71, 0.71, -0.71, 0.71, 0, 0);
transform: matrix(0.71, 0.71, -0.71, 0.71, 0, 0);
position: relative;
}
.stock-name{
font-size: 32rpx;
}
\ No newline at end of file \ No newline at end of file
// pages/receipt/receipt.js
import formatTime from '../../../utils/util.js'
const restapi = require('../../../utils/restapi.js')
const app = getApp()
const util = require('../../../utils/util.js')
const ORDER_TYPE = require('../../../utils/constant').ORDER_TYPE;
const moment = require('../../../utils/moment.min.js');
Page({
/**
* 页面的初始数据
*/
data: {
//加载中
searchLoading: false,
//已全部加载完
searchLoadingComplete: false,
// 显示搜索数据还是加载的数据
showData: true,
// 加载的数据
orderMsg: [],
// 搜索的数据
searchOrderMsg: [],
// 搜索keyWord
keyWord: '',
// 0,待接单,2,待完成,1表示 已完成
orderStatus: '0',
// 1:待接单页面;2:待安装页面;3:已完成页面
// pageTag: "1"
pageIndex: 1,
// 是否有下一页
hasNext: false,
isLoading: false,
// 技工状态
workStatus: true,
// 是否不接单-弹窗
isStopModal: false,
userInfo: '',
args:{}
},
getParams() {
return {
keyWord: this.data.keyWord,
orderStatus: this.data.orderStatus,
pageIndex: this.data.pageIndex,
pageSize: 10
}
},
getOrder(arr = []) {
const params = this.getParams()
util.getDeviceTypeArr().then((serviceTypes)=>{
restapi.getOrdersByClientType(params, res => {
if (res.code == 200) {
let hasNext = res.data.page.hasNext ? true : false
if (this.data.showData) {
this.setData({
hasNext: hasNext,
orderMsg: [...this.data.orderMsg, ...res.data.items],
searchOrderMsg: [],
isLoading: false
})
arr = this.data.orderMsg
} else {
this.setData({
hasNext: hasNext,
searchOrderMsg: [...this.data.searchOrderMsg, ...res.data.items],
orderMsg: [],
isLoading: false
})
arr = this.data.searchOrderMsg
}
arr.forEach(e => {
// if (e.carType == '暂不选择' || e.carType == '其他' || e.carInfo.type == null) {
// e.brandModel = `${e.carInfo.brand}-${e.carInfo.series}`
// } else {
// e.brandModel = `${e.carInfo.brand}-${e.carInfo.type}`
// }
const item = e;
if(item.orderType === ORDER_TYPE.BID){
const _types = [];
item.serviceItems.forEach((_sItem)=>{
_types.push(util.getDictValueByKey(serviceTypes, _sItem.serviceType))
});
item.installDeviceTypeName = _types.join('、');
item.detail = `${item.carOwner}/${item.carOwnerPhone}`;
item.src = '/images/icon_bid.png';
}else{
if(item.orderType === ORDER_TYPE.VEHICLE){
item.detail = `${item.contact}/${item.phoneNumber}`
}else{
item.detail = item.carOwner ? `${item.carOwner}/${item.vinNo}` : (item.vinNo ? item.vinNo : '');
}
item.src = util.getDeviceIcon(item.installDeviceType);
}
e.brandModel = e.carInfo != null ? e.carInfo.type == null ? `${e.carInfo.brand}-${e.carInfo.series}` : `${e.carInfo.brand}-${e.carInfo.type}` : e.carType
/*let temp = e.installDeviceType.split('_')
e.src = util.getDeviceIcon(e.installDeviceType)
e.detail = e.carOwner ? `${e.carOwner}-${e.vinNo}` : e.vinNo ? e.vinNo : '\n'*/
e.btns = [{
name: '订单详情'
}]
if(item.checkInTime && moment(item.checkInTime).isSame(moment(), 'day')){
item.todayAlreadyLocate = true;
}else{
item.todayAlreadyLocate = false;
}
})
if (this.data.showData) {
this.setData({
orderMsg: arr
})
} else {
this.setData({
searchOrderMsg: arr
})
}
}
})
});
},
// 搜索
search(e) {
let showData = e.detail != '' ? false : true
this.setData({
searchLoadingComplete: false,
searchLoading: false,
keyWord: e.detail,
showData: showData,
orderMsg: [],
searchOrderMsg: [],
isLoading: true
})
this.getOrder()
},
clear(e) {
this.setData({
keyWord: ''
})
this.onPullDownRefresh()
},
// 改变技工接单状态
workerStatus() {
restapi.updateSysMechanic({
id: this.data.userInfo.userId,
workStatus: app.globalData.workStatus == 2 ? 1 : 2
}, res => {
if(res.code == 200) {
// console.log(res)
app.globalData.workStatus = app.globalData.workStatus == 2 ? 1 : 2
this.setData({
workStatus: app.globalData.workStatus
})
} else {}
})
},
changeStatus() {
let _this = this
if (this.data.workStatus == 1) {
this.setData({
isStopModal: true
})
wx.hideTabBar()
} else {
this.workerStatus()
}
// this.data.workStatus
// ?
// wx.showModal({
// title: '暂不接单',
// content: '停止接单后将无法接收到各类订单\n点击开始接单后可重新接单',
// confirmColor: "#39A3F5",
// success(res) {
// if (res.confirm) {
// // 接口--
// _this.workerStatus()
// }
// }
// })
// :
// this.workerStatus()
},
stopConfirm() {
this.setData({
isStopModal: false
})
wx.showTabBar()
this.workerStatus()
},
cancel() {
wx.showTabBar()
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function() {
if(!app.globalData.isPublicAuth){
restapi.getWechatOpenId({
publicCode: app.globalData.userCode.publicCode
}, res => {
restapi.getUserById(null, res => {
let userInfo = {
phoneNumber: res.data.phoneNumber,
userId: res.data.id
}
wx.setStorageSync('userInfo', userInfo);
this.init()
});
});
}else{
this.init()
}
},
init(){
const that = this;
wx.getSetting({
success(res) {
if (!res.authSetting['scope.userLocation']) {
wx.authorize({
scope: 'scope.userLocation',
success (res) {
that.getLocation()
},
fail(res){
}
})
}else{
that.getLocation()
}
}
});
this.data.userInfo = wx.getStorageSync('userInfo')
// console.log(this.data.userInfo)
// 从后端获取上次接单状态------
// app.globalData.workStatus = true
/*restapi.getMechanicById({
mechanicId: this.data.userInfo.userId
}, res => {
if(res.code == 200) {
app.globalData.workStatus = res.data.workStatus
this.setData({
workStatus: app.globalData.workStatus
})
} else {}
})*/
/*this.setData({
isLoading: true
})
this.getOrder()
app.globalData.flag = false
app.globalData.flagPage[this.data.orderStatus] = false*/
},
getLocation(){
wx.getLocation({//调用API得到经纬度
type: 'gcj02',
success: function (res) {
var speed = res.speed
var accuracy = res.accuracy
var latitude = res.latitude
var longitude = res.longitude
restapi.positioning({
latitude,
longitude
}, res=>{
})
}
})
},
onShow() {
if(!app.globalData.isOrderListTap){
this.setData({
orderMsg: [],
searchOrderMsg: [],
pageIndex: 1,
searchLoadingComplete: false,
isLoading: true
})
this.getOrder();
}else{
app.globalData.isOrderListTap = false;
}
/*let flag = app.globalData.flag
let flagPage = app.globalData.flagPage[this.data.orderStatus]
let _this = this
if (flag || flagPage) {
this.setData({
orderMsg: [],
searchOrderMsg: [],
pageIndex: 1,
searchLoadingComplete: false,
isLoading: true
})
this.getOrder()
wx.nextTick(() => {
app.globalData.flag = false
app.globalData.flagPage[_this.data.orderStatus] = false
})
}
this.setData({
workStatus: app.globalData.workStatus
})*/
},
onHide(){
app.globalData.flag = true
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh: function() {
this.setData({
searchLoadingComplete: false,
pageIndex: 1,
orderMsg: [],
searchOrderMsg: [],
isLoading: true
})
this.getOrder()
wx.nextTick(() => wx.stopPullDownRefresh())
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom: function() {
if (this.data.hasNext) {
this.setData({
pageIndex: this.data.pageIndex + 1,
searchLoading: true
})
wx.nextTick(() => this.getOrder())
} else {
this.setData({
searchLoadingComplete: true,
searchLoading: false
})
}
},
loginSuccess(res){
console.log(res)
},
loginFail(error){
console.log(error)
}
})
\ No newline at end of file \ No newline at end of file
<search-bar bindsearch="search" bindclear="clear" placeholder="姓名/车架号"></search-bar>
<view
class="list_none"
wx:if="{{!isLoading}}"
hidden='{{list.length>0}}'>
<text>暂无数据</text>
</view>
<view class="va_list">
<view class="va_list_item" wx:for="{{list}}" wx:key="{{item.id}}" data-item="{{item}}" bindtap="toDetail">
<view class="va_list_item_top">
<view class="install_type_name"><text>{{item.installDeviceTypeName}}</text> <text class="type_btn">{{ORDER_TYPE[item.orderType]}}</text></view>
<view class="install_time">{{item.completeTime||'--'}}</view>
</view>
<view class="va_list_item_main">
<view class="install_info">
<view class="user_standno"><text>{{item.carOwner}}/{{item.vinNo}}</text></view>
<view class="addr"><text>{{item.address}}</text></view>
</view>
<view class="install_price">¥{{item.actualSettlement}}</view>
</view>
</view>
</view>
<loading searchLoading='{{hasNext && pageIndex!=1}}' searchLoadingComplete='{{!hasNext && list.length}}' />
\ No newline at end of file \ No newline at end of file
<!--components/detailedList/detailedList.wxml-->
<view class="detailedList" wx:for="{{detailed}}" wx:key="k" wx:for-item="i" hidden="{{!i.isShow}}">
<view class="form-title">{{i.title}}</view>
<view class="form-cells">
<view class="form-cell" wx:for="{{i.detailedList}}" wx:key="index" wx:for-item="item">
<view class="form-ld">
<view form-label><text selectable="true">{{item.label}}</text></view>
</view>
<view style="text-align: center" wx:if="{{item.hasPhoto}}">
<image class="form-img" wx:for="{{item.content}}" wx:for-item="i" wx:key="k" src="{{i}}" bindtap="previewImage" data-src='{{i}}' data-urls='{{item.content}}'></image>
</view>
<view wx:else class="form-rd">
<navigator style="display: inline-block;text-decoration: underline;" wx:if="{{item.url}}" url="{{item.url}}">{{item.content}}</navigator>
<text wx:elif="{{!item.url&&item.events}}" class="{{item.events?'eventsFunc':''}}" data-eventsParmas='{{item.content}}' data-eventsName='{{item.events}}' bindtap='eventsFunc' selectable="true">{{item.content}}</text>
<text wx:elif="{{item.type == 'text'}}" selectable="true">{{item.content}}</text>
<view wx:else="{{!item.url&&!item.events}}">{{item.content}}</view>
</view>
</view>
</view>
</view>
\ No newline at end of file \ No newline at end of file
/* packagePersonal/pages/providerDetail/providerDetail.wxss */
.info_form_content{
text-align: right;
}
\ No newline at end of file \ No newline at end of file
const restapi = require('../../../utils/restapi.js')
const app = getApp()
const moment = require('../../../utils/moment.min.js');
Page({
/**
* 页面的初始数据
*/
data: {
isLoading: true,
// 加载的数据
list: [],
// 分页
pageIndex: 1,
// 是否有下一页
hasNext: false,
sn: '',
deviceType: '',
dateStart: '',
dateEnd: '',
id: undefined
},
getParams() {
const params = {
deviceNo: this.data.sn,
deviceType: this.data.deviceType,
dateStart: this.data.dateStart,
dateEnd: this.data.dateEnd,
pageIndex: this.data.pageIndex,
pageSize: app.globalData.pageSize
}
if(typeof this.data.id !== 'undefined'){
params.userId = this.data.id
}
return params;
},
// 搜索
search(e) {
let keyword = e.detail.replace(/(^\s*|\s*$)/g, '');
if(!/^\d{6,}$/.test(keyword)){
app.showToast('请输入6位及以上设备号');
return;
}
this.setData({
sn: keyword,
isLoading: true,
pageIndex: 1,
list: []
});
this.getList()
},
leftFilterChange(e) {
this.setData({
deviceType: e.detail,
list: [],
isLoading: true,
pageIndex: 1
});
this.getList()
},
rightFilterChange(e) {
console.log(moment(e.detail).startOf('month').format('YYYY-MM-DD'), moment(e.detail).endOf('month').format('YYYY-MM-DD'))
this.setData({
dateStart: moment(e.detail).startOf('month').format('YYYY-MM-DD'),
dateEnd: moment(e.detail).endOf('month').format('YYYY-MM-DD'),
list: [],
isLoading: true,
pageIndex: 1
});
this.getList()
},
clear(e) {
this.setData({
sn: ''
})
this.onPullDownRefresh()
},
getList(prevArr = []) {
const params = this.getParams()
restapi.getStockListByUserId(params, res => {
const data = res.data;
data.items.forEach((item)=>item.stockTime = moment(item.stockTime).format('YYYY-MM-DD HH:mm'))
let arr = [...prevArr, ...data.items]
this.setData({
list: arr,
hasNext: data.page.hasNext,
isLoading: false
});
wx.stopPullDownRefresh()
})
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function(options) {
if('id' in options){
this.setData({
id: options.id
})
wx.setNavigationBarTitle({
title: options.name
});
}
this.getList()
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady: function() {
},
/**
* 生命周期函数--监听页面显示
*/
onShow: function() {
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide: function() {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload: function() {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh: function() {
this.setData({
list: [],
isLoading: true,
hasNext: true,
pageIndex: 1
})
this.getList()
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom: function() {
if (this.data.hasNext) {
this.setData({
pageIndex: this.data.pageIndex + 1,
isLoading: true
})
this.getList(this.data.list)
} else {
/*this.setData({
searchLoadingComplete: true,
searchLoading: false
})*/
}
},
/**
* 用户点击右上角分享
*/
onShareAppMessage: function() {
}
})
\ No newline at end of file \ No newline at end of file
/* pages/login/login.wxss */
page {
background-color: #FFFFFF;
}
.login {
position: fixed;
top: 0;
left: 0;
right: 0;
bottom: 0;
background-color: #fff;
}
.login-content {
font-size: 36rpx;
margin: 0 40rpx;
}
.login-cell {
height: 88rpx;
width: 100%;
line-height: 88rpx;
border-bottom: 2rpx solid #eee;
position: relative;
}
.login-cell:last-child {
border-bottom: none;
}
/* .login-cell::after {
display: block;
content: "";
border-bottom: 1px solid #eee;
} */
.login-logo {
width: 430rpx;
height: 124rpx;
margin: 107rpx 160rpx 68rpx;
}
.login-icon {
display: inline-block;
width: 44rpx;
height: 44rpx;
vertical-align: middle;
}
.login-input {
/* flex-grow: 1; */
display: inline-block;
padding-left: 20rpx;
vertical-align: middle;
width: 500rpx;
overflow: hidden;
}
.login-forget-psw {
font-size: 28rpx;
color: #3da5f5;
float: right;
position: relative;
z-index: 9999;
}
.btnBox {
margin-top: 10rpx;
text-align: center;
}
.btn {
margin: 30rpx;
z-index: 9999;
}
.login-btn {
color: #fff;
background-color: #3da5f5;
}
.registered-btn {
color: #3da5f5;
background-color: #fff;
}
.login-bgImg {
position: fixed;
bottom: 0;
width: 660rpx;
height: 676rpx;
}
.icon_clear{
height: 32rpx;
transform: translateY(-30%)
}
/* 微信免密登陆 */
.open-seting-bg {
position: fixed;
width: 100%;
height: 100%;
top: 0;
left: 0;
background: rgba(0, 0, 0, 0.5);
z-index: 9999;
}
.btn-openset {
display: flex;
justify-content: space-around;
font-size: 30rpx;
margin-top: 60rpx;
}
.set-title {
font-size: 30rpx;
margin-top: 40rpx;
text-align: center;
}
.open-set-inner {
width: 400rpx;
height: 240rpx;
position: absolute;
top: 0;
left: 0;
bottom: 0;
right: 0;
margin: auto;
background: #ffffff;
z-index: 9999;
padding: 30rpx;
}
.btn-openset > view:nth-child(1) {
color: #919191;
}
.button-style {
width: 100%;
height: 100%;
background: #fff;
display: flex;
align-items: center;
justify-content: space-between;
padding: 0 0 0;
font-size: 30rpx;
line-height: 0;
color: red;
}
/* button::after {
border: 0;
} */
official-account{
position:fixed;
width:100%;
bottom:0;
left:0;
}
.is_agree{
position: relative;
z-index: 500;
padding: 0 30rpx;
font-size: 12px;
text-align: center;
}
.login_guide{
position: fixed;
width: 100%;
height: 100%;
top: 0;
left: 0;
display: flex;
flex-direction: column;
align-items: center;
justify-content: space-around;
}
.login_guide>image{
position: relative;
/* position: relative;
display: block;
margin: 0 auto; */
}
.login_guide .login_guide_bg{
position: absolute;
width: 100%;
height: 100%;
}
.login_guide .login_guide_title{
width: 492rpx;
height: 164rpx;
margin: 60rpx auto 40rpx;
}
.login_guide .login_guide_mid{
width: 340px;
height: 346px;
}
.login_guide .login_guide_btn{
width: 536rpx;
height: 116rpx;
}
.login_guide .login_guide_bottom{
width: 516rpx;
height: 34rpx;
margin-bottom: 20rpx;
}
.login_guide_hide{
animation: slide-left .5s ;
margin-left: 100%;
}
@keyframes slide-left {
from {margin-left: 0}
to {margin-left: 100%}
}
.box-animation {
}
.is_agree_link{
display: inline;
vertical-align: middle;
text-decoration: underline;
}
.is_agree_txt{
display: inline;
vertical-align: middle;
margin-right: 5px;
}
\ No newline at end of file \ No newline at end of file
// components/cityPicker/cityPicker.js
const restapi = require('../../utils/restapi.js');
Component({
/**
* 组件的属性列表
*/
properties: {
multiIds: {
type: String,
value: '',
observer(newVal, oldVal){
this.initArea()
}
},
placeholder: {
type: String,
value: '所在地区'
}
},
/**
* 组件的初始数据
*/
data: {
multiValue: '',
multiIndex: [],
multiArray: [
[],
[],
[]
],
objectMultiArray: [
[],
[],
[]
],
isLoading: false,
loadPromise: null
},
lifetimes: {
created(){
setTimeout(()=>{
this.initArea()
}, 100)
}
},
/**
* 组件的方法列表
*/
methods: {
// 获取城区信息
initArea() {
const _promise = new Promise((resolve, reject)=>{
let pId,cId,aId;
let _multiIdx = [];
if(this.data.multiIds){
const idsArr = this.data.multiIds.split(',');
pId = idsArr[0];
cId = idsArr[1];
aId = idsArr[2]
}
// 获取城区信息
const arr1 = [],
arr2 = [],
arr3 = []
let province = 'multiArray[' + 0 + ']'
let city = 'multiArray[' + 1 + ']'
let area = 'multiArray[' + 2 + ']'
let _province = 'objectMultiArray[' + 0 + ']'
let _city = 'objectMultiArray[' + 1 + ']'
let _area = 'objectMultiArray[' + 2 + ']'
restapi.getArea({
type: 'children'
}, p => {
p.data.forEach((item, idx) => {//console.log(item)
arr1.push(item.areaName);
if(pId && pId == item.id){
_multiIdx.push(idx)
}
})
restapi.getArea({
id: pId||p.data[0].id,
type: 'children'
}, c => {
c.data.forEach((item, idx) => {
arr2.push(item.areaName);
if(cId && cId == item.id){
_multiIdx.push(idx)
}
})
restapi.getArea({
id: cId||c.data[0].id,
type: 'children'
}, a => {
a.data.forEach((item, idx) => {
arr3.push(item.areaName);
if(aId && aId == item.id){
_multiIdx.push(idx)
}
})
console.log(_multiIdx)
this.setData({
[province]: arr1,
[city]: arr2,
[area]: arr3,
[_province]: p.data,
[_city]: c.data,
[_area]: a.data,
multiIndex: _multiIdx,
multiValue: arr1[_multiIdx[0]]+arr2[_multiIdx[1]]+arr3[_multiIdx[2]]
})
resolve()
})
})
})
});
this.setData({
loadPromise: _promise
})
},
initAreaData(){
this.getAreaData().then((data)=>{
console.log(data)
})
},
// 多列picker, 所在城区
bindMultiPickerChange(e) {console.log(e.detail.value)
if(this.data.loadPromise){
this.data.loadPromise.then(()=>{
let _chooseValue = e.detail.value;
if(_chooseValue[0] == null){
_chooseValue = [0,0,0]
}
this.setData({
multiIndex: _chooseValue
})
const idxArr = _chooseValue;
this.triggerEvent('citychange', this.data.objectMultiArray[2][idxArr[2]].id)
const objectMultiArray = this.data.objectMultiArray;
const pIdx = idxArr[0];
const cIdx = idxArr[1];
const dIdx = idxArr[2];
const citychangeData = {
province: objectMultiArray[0][pIdx].areaName,
provinceCode: objectMultiArray[0][pIdx].id,
city: objectMultiArray[1][cIdx].areaName,
cityCode: objectMultiArray[1][cIdx].id,
district: objectMultiArray[2][dIdx].areaName,
districtCode: objectMultiArray[2][dIdx].id
}
this.triggerEvent('citychangestr', JSON.stringify(citychangeData))
this.setData({
multiValue: citychangeData.province+citychangeData.city+citychangeData.district
})
})
}
},
bindMultiPickerColumnChange(e){
if(this._timeOutId) {
clearTimeout(this._timeOutId)
}
const _promise = new Promise((resolve, reject)=>{
const data = {
multiArray: this.data.multiArray,
multiIndex: this.data.multiIndex
}
let arr1 = [],
arr2 = [],
arr3 = []
let province = 'multiArray[' + 0 + ']'
let city = 'multiArray[' + 1 + ']'
let area = 'multiArray[' + 2 + ']'
let _province = 'objectMultiArray[' + 0 + ']'
let _city = 'objectMultiArray[' + 1 + ']'
let _area = 'objectMultiArray[' + 2 + ']'
data.multiIndex[e.detail.column] = e.detail.value
switch (e.detail.column) {
case 0:
this.data.multiIndex[1] = 0;
this.data.multiIndex[2] = 0;
this.setData({
[city]: [],
[area]: [],
[_city]: [],
[_area]: [],
multiIndex: this.data.multiIndex,
isLoading: true
})
this._timeOutId = setTimeout(()=>{
this.getAreaData(this.data.objectMultiArray[0][e.detail.value].id).then((cityData)=>{
arr2 = cityData.map((item)=>item.areaName)
this.getAreaData(cityData[0].id).then((areaData)=>{
arr3 = areaData.map((item)=>item.areaName)
this.setData({
[city]: arr2,
[area]: arr3,
[_city]: cityData,
[_area]: areaData,
multiIndex: this.data.multiIndex,
isLoading: false
})
resolve()
})
});
}, 0);
break
case 1:
this.data.multiIndex[2] = 0;
this.setData({
[area]: [],
[_area]: [],
multiIndex: this.data.multiIndex,
isLoading: true
})
this._timeOutId = setTimeout(()=>{
this.getAreaData(this.data.objectMultiArray[1][e.detail.value].id).then((areaData)=>{
arr3 = areaData.map((item)=>item.areaName)
this.setData({
[area]: arr3,
[_area]: areaData,
isLoading: false
})
resolve()
});
}, 0);
break
case 2:
resolve()
break;
}
})
this.setData({
loadPromise: _promise
})
},
bindMultiPickerColumnChange2(e) {console.log('bindMultiPickerColumnChange')
if(this._timeOutId){
clearTimeout(this._timeOutId)
}
this._timeOutId = setTimeout(()=>{
const data = {
multiArray: this.data.multiArray,
multiIndex: this.data.multiIndex
}
let arr1 = [],
arr2 = [],
arr3 = []
let province = 'multiArray[' + 0 + ']'
let city = 'multiArray[' + 1 + ']'
let area = 'multiArray[' + 2 + ']'
let _province = 'objectMultiArray[' + 0 + ']'
let _city = 'objectMultiArray[' + 1 + ']'
let _area = 'objectMultiArray[' + 2 + ']'
data.multiIndex[e.detail.column] = e.detail.value
switch (e.detail.column) {
case 0:
this.data.multiIndex[1] = 0
restapi.getArea({
id: this.data.objectMultiArray[0][e.detail.value].id,
type: 'children'
}, c => {
this.setData({
[city]: [],
[area]: []
})
arr2 = []
c.data.forEach(item => {
arr2.push(item.areaName)
})
c.data[0].id
restapi.getArea({
id: c.data[0].id,
type: 'children'
}, a => {
arr3 = []
a.data.forEach(item => {
arr3.push(item.areaName)
})
this.setData({
[city]: arr2,
[area]: arr3,
[_city]: c.data,
[_area]: a.data,
multiIndex: this.data.multiIndex
})
})
})
break
case 1:
restapi.getArea({
id: this.data.objectMultiArray[1][e.detail.value].id,
type: 'children'
}, a => {
arr3 = []
a.data.forEach(item => {
arr3.push(item.areaName)
})
this.setData({
[area]: arr3,
[_area]: a.data
})
})
break
}
},500)
},
getAreaData(id){
return new Promise((resolve, reject)=>{
const params = {
type: 'children'
}
if(typeof id !== 'undefined'){
params.id = id;
}
restapi.getArea(params, res => {
resolve(res.data)
})
})
}
}
})
{
"component": true,
"usingComponents": {
"mp-gallery": "../gallery/gallery"
}
}
// packagePersonal/pages/certify/ing/ing.js
const util = require('../../../../utils/util.js')
Page({
/**
* 页面的初始数据
*/
data: {
id: '',
providerPhone: ''
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
if('id' in options){
this.setData({
id: options.id
})
}
if('providerPhone' in options){
this.setData({
providerPhone: options.providerPhone
})
}
},
edit(){
wx.navigateTo({
url: `/packagePersonal/pages/certify/index/index?isEdit=true&id=${this.data.id}&providerPhone=${this.data.providerPhone}`,
})
},
callPhone(e){
util.callPhone(e.currentTarget.dataset.phone)
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady: function () {
},
/**
* 生命周期函数--监听页面显示
*/
onShow: function () {
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide: function () {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload: function () {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh: function () {
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom: function () {
},
/**
* 用户点击右上角分享
*/
onShareAppMessage: function () {
}
})
\ No newline at end of file \ No newline at end of file
<web-view src="{{jumpLink}}" bindmessage="onMessage"></web-view>
const restapi = require('../../../utils/restapi.js')
Page({
/**
* 页面的初始数据
*/
data: {
stock: ''
},
addNewOrder(){
wx.navigateTo({
url: '../../../hardwareAdmin/pages/orderEdit/orderEdit',
})
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
},
getAmount(){
restapi.getStockListByUserId({}, res => {
this.setData({
stock: res.data.page.totalCount
})
})
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady: function () {
},
/**
* 生命周期函数--监听页面显示
*/
onShow: function () {
this.getAmount()
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide: function () {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload: function () {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh: function () {
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom: function () {
},
/**
* 用户点击右上角分享
*/
onShareAppMessage: function () {
}
})
\ No newline at end of file \ No newline at end of file
// packagePersonal/pages/changePhone/help/help.js
Page({
/**
* 页面的初始数据
*/
data: {
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady: function () {
},
/**
* 生命周期函数--监听页面显示
*/
onShow: function () {
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide: function () {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload: function () {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh: function () {
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom: function () {
},
/**
* 用户点击右上角分享
*/
onShareAppMessage: function () {
}
})
\ No newline at end of file \ No newline at end of file
{
"navigationBarTitleText": "编辑收货地址",
"usingComponents": {}
}
\ No newline at end of file \ No newline at end of file
<!--pages/register/registerInfo/registerInfo.wxml-->
<view class="registerInfo list">
<form bindsubmit="formSubmit">
<view class="title">基础信息(必填)</view>
<view class="list_cells">
<view class="list_cell" wx:for="{{workerForm}}" wx:key="id" wx:for-index="formidx">
<view class="required">*</view>
<view class="list_cell_bd">{{item.label}}</view>
<picker class="list_r weui-cell__ft_in-access" wx:if="{{item.type == 'picker'}}" mode="multiSelector" name="{{item.name}}" bindchange="bindMultiPickerChange" bindcolumnchange="bindMultiPickerColumnChange" value="{{multiIndex}}" range="{{multiArray}}">
<input disabled placeholder="{{item.placeholder}}" placeholder-class="placeholder" value="{{(multiArray[0][multiIndex[0]])}}{{(multiArray[1][multiIndex[1]])}}{{multiArray[2][multiIndex[2]]}}"></input>
</picker>
<input wx:elif="{{item.name == 'phoneNumber'}}" class="list_r" value="{{item.value}}" name="{{item.name}}" bindinput='changeValue' data-target='phoneNumber' placeholder-class="placeholder" placeholder="{{item.placeholder}}" maxlength="{{item.maxlength ? item.maxlength : '-1'}}"></input>
<view wx:elif="{{item.name == 'verifyCode'}}" class="weui-cell list_r code">
<input class="weui-cell__bd code_input" name="verifyCode" placeholder-class="placeholder" maxlength='10' placeholder="短信验证码" type='number' value='{{verifyCode}}'/>
<text class="weui-cell__ft" class="vcode-btn" bindtap="send" style='color:{{cd<120?"#ccc":""}}'>发送验证码\t{{cd<120?cd + "s":""}}</text>
</view>
<textarea wx:elif="{{item.name == 'address'}}" class='list_r' value="{{item.value}}" name="{{item.name}}" placeholder-class="placeholder" placeholder="{{item.placeholder}}" maxlength='50'></textarea>
<input wx:else class="list_r" value="{{item.value}}" name="{{item.name}}" placeholder-class="placeholder" placeholder="{{item.placeholder}}" maxlength="{{item.maxlength ? item.maxlength : '-1'}}"></input>
</view>
</view>
<view class="title">技能信息(可多选)</view>
<view class="weui-cells">
<checkbox-group data-checkedid="{{idx}}" bindchange="changeChecked" wx:for="{{skill}}" name="skills" wx:key="id" wx:for-index="idx">
<view class="weui-cell">
<view class="weui-cell__hd" style="margin-right: 11rpx;">
<image class="icon" src="{{item.src}}"></image>
</view>
<view class="weui-flex weui-cell__bd info_list2">
<view class="info_list_title">{{item.value}}</view>
<input type="number" placeholder-class="placeholder" placeholder="请输入安装耗时(单位:分钟)" data-idx="{{idx}}" bindinput="getSkillsTime"></input>
</view>
<label>
<checkbox value="{{item.name}}" hidden="true" checked="{{item.checked}}" />
<block wx:if="{{item.checked}}">
<image class='checkIcon' src='../../../../images/icon_highlight.png'></image>
</block>
<block wx:else>
<image class='checkIcon' src='../../../../images/icon_norm.png'></image>
</block>
</label>
</view>
</checkbox-group>
</view>
<view class="btn_mg">
<button class="btn" form-type="submit">下一步</button>
</view>
</form>
</view>
\ No newline at end of file \ No newline at end of file
/* pages/dealVehicle/dealVehicle.wxss */
\ No newline at end of file \ No newline at end of file
<!--pages/install/install.wxml-->
<view class="install">
<!-- 搜索框 -->
<search-bar bindsearch='search' bindclear='clear' placeholder="订单编号/车架号/姓名"></search-bar>
<view class="">
<view style='text-align: center;font-size: 32rpx;' hidden='{{showData?orderMsg.length>0:searchOrderMsg.length>0}}'>{{isLoading?'正在加载中' : '暂无数据'}}</view>
<main-list orderMsg="{{showData?orderMsg:searchOrderMsg}}" orderStatus="{{orderStatus}}" >
</main-list>
</view>
</view>
<loading searchLoading='{{searchLoading}}' searchLoadingComplete='{{searchLoadingComplete}}' />
<!-- <view class="creatForm" bindtap="changeStatus">
<image wx:if="{{workStatus == 1}}" class="creatImg" src="../../../images/stop.png"></image>
<image wx:else class="startImg" src="../../../images/start.png"></image>
</view>
<modal show="{{isStopModal}}" bind:modalConfirm="stopConfirm" bind:cancel="cancel">
<view class="modal-content">
<view class="modalTitle">暂不接单</view>
<view class="modalCell">
<text class="modalLeft">停止接单后将无法接收到各类订单\n点击开始接单后可重新接单</text>
</view>
</view>
</modal> -->
\ No newline at end of file \ No newline at end of file
// pages/register/registerBind/registerBind.js
Page({
/**
* 页面的初始数据
*/
data: {
facilitatorMsg: {}
},
comfirmBind() {
let queryBean = JSON.stringify(this.data.facilitatorMsg)
wx.navigateTo({
url: '../registerInfo/registerInfo?queryBean=' + queryBean,
})
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
this.setData({
facilitatorMsg: JSON.parse(options.queryBean)
})
}
})
\ No newline at end of file \ No newline at end of file
const restapi = require('./restapi.js')
const ORDER_TYPE = require('./constant.js').ORDER_TYPE;
const ORDER_MENU_STATUS = require('./constant.js').ORDER_MENU_STATUS;
const formatTime = date => {
const year = date.getFullYear()
const month = date.getMonth() + 1
const day = date.getDate()
const hour = date.getHours()
const minute = date.getMinutes()
const second = date.getSeconds()
return [year, month, day].map(formatNumber).join('/') + ' ' + [hour, minute, second].map(formatNumber).join(':')
}
const formatNumber = n => {
n = n.toString()
return n[1] ? n : '0' + n
}
/**
* 日期格式化
* let time = new Date().format('yyyy-MM-dd hh:mm:ss')
*/
Date.prototype.format = function (fmt) {
let o = {
"M+": this.getMonth() + 1, //月份
"d+": this.getDate(), //日
"h+": this.getHours(), //小时
"m+": this.getMinutes(), //分
"s+": this.getSeconds(), //秒
//季度
"q+": Math.floor((this.getMonth() + 3) / 3),
"S": this.getMilliseconds() //毫秒
}
if (/(y+)/.test(fmt)) fmt = fmt.replace(RegExp.$1, (this.getFullYear() + "").substr(4 - RegExp.$1.length))
for (let k in o) {
if (new RegExp("(" + k + ")").test(fmt)) fmt = fmt.replace(RegExp.$1, (RegExp.$1.length == 1) ? (o[k]) : (("00" + o[k]).substr(("" + o[k]).length)))
}
return fmt
}
//调用系统通话功能
const callPhone = (phoneName) => {
console.log(phoneName,'phoneName')
wx.makePhoneCall({
phoneNumber: phoneName
})
}
function getDeviceIcon(devicetype){
const types = ['control_screen','gps','gps_wireless','car_dvr','car_mirrors']
const type = devicetype.replace('sys_order_service_item_', '');
return (types.indexOf(type)>-1)?'/images/icon_'+ type + '_v2.png':'/images/icon_other_v2.png'
}
let reserveReasonArr = [];//预约上门原因
let overdueReasonArr = [];//打卡超时原因
let deviceTypeArr = []; //安装类型
module.exports = {
formatTime: formatTime,
callPhone:callPhone,
getDeviceIcon,
getDeviceTypeArr: ()=>{
return new Promise((resolve, reject)=>{
if(deviceTypeArr.length>0){
resolve(deviceTypeArr)
}else{
restapi.getDictDataListByKey({
dictType: 'sys_order_service_item'
}, res => {
deviceTypeArr = res.data.items;
resolve(deviceTypeArr)
});
}
})
},
/*根据字典数组和key值获取value*/
getDictValueByKey(arr, key){
const findItem = arr.find((item)=>item.dataKey === key);
if(findItem){
return findItem.dataValue
}else{
return ''
}
},
getReserveReasonArr: ()=>{
return new Promise((resolve, reject)=>{
if(reserveReasonArr.length>0){
resolve(reserveReasonArr)
}else{
restapi.getDictDataListByKey({
dictType: 'reserve_install_reason'
}, res => {
reserveReasonArr = res.data.items;
resolve(reserveReasonArr)
});
}
})
},
getOverdueReasonArr: ()=>{
return new Promise((resolve, reject)=>{
if(overdueReasonArr.length>0){
resolve(overdueReasonArr)
}else{
restapi.getDictDataListByKey({
dictType: 'overdue_reason'
}, res => {
overdueReasonArr = res.data.items;
resolve(overdueReasonArr)
});
}
})
},
getCityNameByObj(obj){
let cityObj = obj;
let cityName = obj.areaName;
while(cityObj.children){
cityObj = cityObj.children[0];
cityName += cityObj.areaName;
}
return cityName;
},
getOrderStatus(activeStatus, orderType=undefined, group='worker'){
if(group === 'provider'){
if('1,2'.indexOf(activeStatus)>-1){
return ORDER_MENU_STATUS.RECEIPT
}else if('4,6,7'.indexOf(activeStatus)>-1){
return ORDER_MENU_STATUS.TOCOMPLETE
}else if(activeStatus === 8){
return ORDER_MENU_STATUS.COMPLETE
}
}else if(group === 'store' && typeof orderType !== 'undefined'){
if(orderType === ORDER_TYPE.BID){
if('1,3,10,15'.indexOf(activeStatus)>-1){
return ORDER_MENU_STATUS.RECEIPT
}else if('2,4,5,6,7'.indexOf(activeStatus)>-1){
return ORDER_MENU_STATUS.TOCOMPLETE
}else if(activeStatus === 8){
return ORDER_MENU_STATUS.COMPLETE
}
}else{
if('1,2,3,4,5'.indexOf(activeStatus)>-1){
return ORDER_MENU_STATUS.RECEIPT
}else if('6,7'.indexOf(activeStatus)>-1){
return ORDER_MENU_STATUS.TOCOMPLETE
}else if(activeStatus === 8){
return ORDER_MENU_STATUS.COMPLETE
}
}
}else if(group === 'worker'){
if('4'.indexOf(activeStatus)>-1){
return ORDER_MENU_STATUS.RECEIPT
}else if('6,7'.indexOf(activeStatus)>-1){
return ORDER_MENU_STATUS.TOCOMPLETE
}else if(activeStatus === 8){
return ORDER_MENU_STATUS.COMPLETE
}
}
}
}
/* components/locateMap/locateMap.wxss */
@import "../../weui.wxss";
map{
width: 100%;
height: 40vh;
position: relative;
}
.locate_btn{
display: block;
position: absolute;
bottom: 10px;
left: 10px;
background: #fff;
border: 1px solid #efefef;
border-radius: 10px;
padding: 4px;
display: flex;
font-size: 12px;
}
cover-image{
width: 16px;
height: 16px;
}
/*.locate_btn:before{
content: '';
display: inline-block;
width: 25px;
height: 16px;
background-size: 16px 16px;
background-repeat: no-repeat;
background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAAEEfUpiAAAAAXNSR0IArs4c6QAABY9JREFUWAmtV0lsHEUUraqesd09tkjEIuGYA0okDnB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UK9BrjG5o3ks4NK9iQZRJCEHEMobia2rpRZUduQwvAsfwdRk/EWh/KHo1jqw5SSCkpT14V+G+ceUAuN/AzhJYLMPX5t/AYR0ZGL3GWZI9bs7OCVMO964PDDQ9hItd0AQ3RRMKoNIV814vZ8Mz6QzKVq6svaR0/meK1eExSCxiY1t21avQdhS4V1fpoVx9ZptWcJN7blk8J6OX8m7gxAT21ANr5pfU7lsvdeX9rdscolXEUUpcjR7looVxQkRhTfnAULaJ1SABOZKUS/Uh805eQx1SHWK9FJGgeMSf3pKceyTpHc1YLwwWtxWPsHM4AgwYeN3CgY8AGbNUx+iUfzoMpmjfTVEGoC+20SgQkLeQFl9YKzuXkPVx9WYYe27VsVQJPIYeT7xcWhuB97+mrLU5AfpP/Tf2oXWojDJnuwP/a5RhbTqaQzM/rfhNJ9A5omK0iPX1zQ/5hixNg7j+MvsIL59IZJqOX8XchGwf9k9ExEcfmuYVs3vO2fbq/i+IiE4ToOeNY23qL1ON3GsLu2PWxLlQWo1tBw46bd5QUW9TPuimplDxyfih4nW2lsgDE7N8mOq41+g663QYrt5uRghScp+izseS2M6zbsAAwUAXj+fCMbfdZmhouipoxWtAH+Y7OL7k/wB2jtyZnD4pYj9qUS/TIyTnVG+xtVg2bLsD6I8CciBavuMXJ5beEqehQW/FstpXMyv/rArIK9X9P+k7a5csUjH3gU/BRBsnnVF5+MTvY9UNWpx3+nxfAxv6v5/gfCJXCgFRrBP8AAAAASUVORK5CYII=);
}*/
.locate_tip{
padding: 12rpx 30rpx;
font-size: 24rpx;
}
.locate_tip>icon{
opacity: .7;
margin-right: 10rpx;
}
.locate_tip>icon, .locate_tip>text{
vertical-align: middle;
}
.link{
color: #3DA5F5;
}
.locate_done{
background: #3DA5F5;
color: #fff;
}
.locate_icon{
width: 28rpx;
height: 28rpx;
vertical-align: middle;
margin-right: 10rpx;
}
\ No newline at end of file \ No newline at end of file
/* components/modal/modal.wxss */
.modal {
position: fixed;
top: 0;
right: 0;
bottom: 0;
left: 0;
z-index: 9999;
outline: 0;
text-align: center;
backface-visibility: hidden;
background: rgba(0, 0, 0, 0.6);
overflow-x: hidden;
overflow-y: auto;
}
.modal::before {
content: "\200B";
display: inline-block;
height: 100%;
vertical-align: middle;
}
.dialog {
position: relative;
display: inline-block;
vertical-align: middle;
margin-left: auto;
margin-right: auto;
width: 600rpx;
/* width: 680rpx; */
max-width: 100%;
background: #f8f8f8;
border-radius: 20rpx;
overflow: hidden;
}
.modal-content{
display: flex;
flex-direction: column;
background-color: #fff;
border-radius: 20rpx;
}
.modal-btn-wrapper{
display: flex;
flex-direction: row;
height: 90rpx;
line-height: 90rpx;
border-top: 2rpx solid rgba(7,17,27,0.1);
}
.cancel-btn, .confirm-btn{
flex: 1;
height: 90rpx;
line-height: 90rpx;
text-align: center;
font-size: 32rpx;
}
.cancel-btn{
border-right: 2rpx solid rgba(7,17,27,0.1);
}
.main-content{
flex: 1;
height: 100%;
overflow-y: hidden;
}
const restapi = require('../../../utils/restapi.js')
Page({
/**
* 页面的初始数据
*/
data: {
detail: {}
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
if('id' in options){
restapi.getDeliveryTrack({indentId: options.id}, res=>{
if(res.code == 200){
this.setData({
detail: res.data
})
}
});
}
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady: function () {
},
/**
* 生命周期函数--监听页面显示
*/
onShow: function () {
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide: function () {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload: function () {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh: function () {
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom: function () {
},
/**
* 用户点击右上角分享
*/
onShareAppMessage: function () {
}
})
\ No newline at end of file \ No newline at end of file
// pages/login/login.js
import WxValidate from '../../../utils/WxValidate.js'
const restapi = require('../../../utils/restapi.js')
var app = getApp()
Page({
/**
* 页面的初始数据
*/
data: {
openSet: false,
isView: false,
focus: false,
username: '',
password: '',
// username: '18574749274',
// username: '18873336682',
// username: '15017908843',
// username: '18688885555',
// username: '15527303703',
// username: '18576673306',
facilitatorMsg: {},
isAgree: false,
loginGuideHidden: false
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
if (options.code) {
app.globalData.userCode.publicCode = options.code
}
if (!restapi.getSessionId()) {
// 验证是否登录
restapi.checkLogin(res => {
console.log(res)
if (res.data.isLogin) {
wx.switchTab({
url: "/packageReceipt/pages/receipt/receipt"
})
} else {
wx.setNavigationBarTitle({
title: '包活干技工端'
})
}
})
} else {
if (app.globalData.loginStatus) {
wx.switchTab({
url: "/packageReceipt/pages/receipt/receipt"
})
}
}
},
/* 注册模块 */
register() {
var _this = this
var msgNeed = ['name', 'orgName', 'phoneNumber', 'serviceId']
wx.scanCode({
// 扫码成功
success: (res) => {
restapi.getServiceById({
serviceId: res.result
}, res => {
app.globalData.err(res, () => {
_this.setData({
facilitatorMsg: res.data
})
let isAllExist = msgNeed.every(item => _this.data.facilitatorMsg.hasOwnProperty(item))
if (isAllExist) {
let queryBean = JSON.stringify(res.data)
wx.navigateTo({
url: '../register/registerBind/registerBind?queryBean=' + queryBean,
})
} else {
app.toast('该服务商二维码无效,请与服务商确认后重试', '', 'none')
}
})
})
},
// 扫码失败
fail: () => {
app.toast('扫码失败', '', 'none')
}
})
},
// 验证-初始化
initValidate() {
let rules = {}
let validateMsg = {}
// 加上技能 - 验证
rules.username = {
required: true,
rangelength: [1, 50],
noEmoji: true
}
validateMsg.username = {
required: '请输入账号',
rangelength: '请输入50个以内的字符',
noEmoji: '账号不能输入表情'
}
rules.password = {
required: true,
rangelength: [6, 50]
}
validateMsg.password = {
required: '请输入密码',
rangelength: '请输入6-50位密码'
}
this.WxValidate = new WxValidate(rules, validateMsg)
},
/* 登录模块 */
login() {
this.initValidate()
const _this = this
// 验证
const params = {
username: this.data.username,
password: this.data.password
} //校验表单
if (!this.WxValidate.checkForm(params)) {
const error = this.WxValidate.errorList[0]
app.toast(error.msg, '', 'none')
return false
}
if (!this.data.isAgree) {
app.toast('请阅读并勾选服务协议', '', 'none')
return false;
}
restapi.login({
username: this.data.username,
password: this.data.password,
terminalType: 3
}, res => {
console.log(res)
app.globalData.isBindWechat = res.data.isMiniAuth
wx.setStorageSync(restapi.bhgSessionId, res.data.JSESSIONID)
/*if(app.globalData.userCode.publicCode){
restapi.getWechatOpenId({publicCode: app.globalData.userCode.publicCode}, res => {})
}*/
restapi.getUserById(null, res => {
if (res.code == 200) {
let userInfo = {
phoneNumber: res.data.phoneNumber,
userId: res.data.id
}
console.log(userInfo)
wx.setStorageSync('userInfo', userInfo)
}
})
/*if (app.globalData.isBindWechat) {
wx.reLaunch({
url: '../../../packageReceipt/pages/receipt/receipt',
})
} else {
wx.login({
success(res) {
app.globalData.userCode.miniCode = res.code;
_this.choose()
}
})
}*/
wx.login({
success(res) {
app.globalData.userCode.miniCode = res.code;
_this.choose()
}
});
});
},
/* 密码是否可见 */
pswShowOrHide() {
this.setData({
isView: !this.data.isView,
focus: true
})
},
// 改变input值
changeValue(e) {
let target = e.currentTarget.dataset.target
this.setData({
[target]: e.detail.value
})
},
// 清空input值
clearValue(e) {
let target = e.currentTarget.dataset.target
this.setData({
[target]: ''
})
},
forgetPassword() {
wx.navigateTo({
url: '../changePassword/changePassword',
})
},
/**
* 拒绝或者允许
*/
choose(e) {
/*let bool = e.target.dataset.value
// 0是拒绝 1是允许
if (bool == 0) {
delete app.globalData.userCode.miniCode
} else {
app.globalData.isBindWechat = true
}*/
app.globalData.isBindWechat = true
restapi.getWechatOpenId(app.globalData.userCode, res => {
console.log(res)
if (res.code == 2020) {
app.globalData.isBindWechat = false
app.showToast(res.message)
wx.login({
success(res) {
app.globalData.userCode.miniCode = res.code
console.log(res.code)
}
})
} else {
app.globalData.isPublicAuth = true;
wx.switchTab({
url: "/packageReceipt/pages/receipt/receipt"
})
}
})
},
toggleIsAgree(e) {
this.setData({
isAgree: !this.data.isAgree
})
},
closeLoginGuide() {
this.setData({
loginGuideHidden: true
})
},
toAgree(e) {
console.log(e)
let id = e.currentTarget.dataset.id
wx.navigateTo({
url: `/pages/agree/index?id=${id}`
})
},
})
\ No newline at end of file \ No newline at end of file
No preview for this file type
This diff is collapsed. Click to expand it.
This diff is collapsed. Click to expand it.
This diff is collapsed. Click to expand it.
images/badge.png

638 Bytes

This diff is collapsed. Click to expand it.
This diff is collapsed. Click to expand it.
This diff is collapsed. Click to expand it.
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!