三轮车购买哦
This commit is contained in:
parent
8de048e341
commit
8965c01b23
22
App.vue
22
App.vue
@ -21,11 +21,16 @@
|
|||||||
// uni.showModal({
|
// uni.showModal({
|
||||||
// content: info.referrerInfo.extraData
|
// content: info.referrerInfo.extraData
|
||||||
// })
|
// })
|
||||||
|
// console.log('App Launch:',info);
|
||||||
if (info.referrerInfo?.extraData?.uniMP) {
|
if (info.referrerInfo?.extraData?.uniMP) {
|
||||||
//监听宿主App通讯数据
|
//监听宿主App通讯数据
|
||||||
uni.onHostEventReceive((event, data) => {
|
uni.onHostEventReceive((event, data) => {
|
||||||
if(event=='getLocation') uni.$emit('uniMP_getLocation', data);
|
if(event=='getLocation') uni.$emit('uniMP_getLocation', data);
|
||||||
|
else if(event=='im'){
|
||||||
|
uni.navigateTo({
|
||||||
|
url:'/subpkg/chatMang/index'
|
||||||
|
})
|
||||||
|
}
|
||||||
});
|
});
|
||||||
uni.setStorageSync('uniMP', info.referrerInfo?.extraData?.uniMP);
|
uni.setStorageSync('uniMP', info.referrerInfo?.extraData?.uniMP);
|
||||||
uni.setStorageSync('APP_token', info.referrerInfo?.extraData?.token);
|
uni.setStorageSync('APP_token', info.referrerInfo?.extraData?.token);
|
||||||
@ -64,10 +69,25 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
onShow: function() {
|
onShow: function() {
|
||||||
|
// uni.onHostEventReceive((event, data) => {
|
||||||
|
// // if(event=='getLocation') uni.$emit('uniMP_getLocation', data);
|
||||||
|
// });
|
||||||
// const audioContext = uni.createInnerAudioContext()
|
// const audioContext = uni.createInnerAudioContext()
|
||||||
// // 设置音频文件地址
|
// // 设置音频文件地址
|
||||||
// audioContext.src = '/static/mp3/order.mp3'
|
// audioContext.src = '/static/mp3/order.mp3'
|
||||||
// 播放音频
|
// 播放音频
|
||||||
|
uni.onHostEventReceive((event,data)=>{
|
||||||
|
if(event=='im'){
|
||||||
|
uni.navigateTo({
|
||||||
|
url:'/subpkg/chatMang/index'
|
||||||
|
})
|
||||||
|
}else if(event=='re_id'){
|
||||||
|
uni.setStorageSync("re_id",data)
|
||||||
|
}
|
||||||
|
// console.log('Receive event('+event+') from HOST: '+JSON.stringify(data));
|
||||||
|
|
||||||
|
|
||||||
|
});
|
||||||
//#ifdef APP-PLUS
|
//#ifdef APP-PLUS
|
||||||
jpushModule.initJPushService()
|
jpushModule.initJPushService()
|
||||||
jpushModule.addNotificationListener(res => {
|
jpushModule.addNotificationListener(res => {
|
||||||
|
@ -3,8 +3,8 @@ let httpApi; // 总域名
|
|||||||
let httpApiTwo; // 物流系统域名
|
let httpApiTwo; // 物流系统域名
|
||||||
let httpApiTest
|
let httpApiTest
|
||||||
|
|
||||||
// const env = 'dev'; // 开发
|
const env = 'dev'; // 开发
|
||||||
const env = 'prod'; // 生产
|
// const env = 'prod'; // 生产
|
||||||
// const env = 'prew'; // 预上线
|
// const env = 'prew'; // 预上线
|
||||||
|
|
||||||
switch (env) {
|
switch (env) {
|
||||||
@ -22,7 +22,7 @@ switch (env) {
|
|||||||
httpApi = 'https://ceshi-worker-task.lihaink.cn' //测试
|
httpApi = 'https://ceshi-worker-task.lihaink.cn' //测试
|
||||||
httpApiThree = 'https://ceshi-worker-task.lihaink.cn' //测试
|
httpApiThree = 'https://ceshi-worker-task.lihaink.cn' //测试
|
||||||
httpApiTwo = 'https://ceshi-logistics.lihaink.cn' //测试环境
|
httpApiTwo = 'https://ceshi-logistics.lihaink.cn' //测试环境
|
||||||
httpApiTest = 'http://192.168.1.13:8081' //测试环境
|
httpApiTest = 'http://192.168.1.11:8081' //测试环境
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -119,8 +119,8 @@
|
|||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="" style="display: flex;">
|
<view class="" style="display: flex;">
|
||||||
<view class="brange">
|
<view class="brange" v-if="managerInfo.msg_num">
|
||||||
99
|
{{managerInfo.msg_num}}
|
||||||
</view>
|
</view>
|
||||||
<view class="iconfont icon-you">
|
<view class="iconfont icon-you">
|
||||||
<uni-icons type="forward"></uni-icons>
|
<uni-icons type="forward"></uni-icons>
|
||||||
@ -131,7 +131,7 @@
|
|||||||
|
|
||||||
<view class="my_task">
|
<view class="my_task">
|
||||||
<view class="task_title flex_a_c_j_sb">
|
<view class="task_title flex_a_c_j_sb">
|
||||||
<view class="title">工作管理</view>
|
<view class="title" @click="leftClick">工作管理</view>
|
||||||
<!-- <view class="flex_a_c"
|
<!-- <view class="flex_a_c"
|
||||||
>更多
|
>更多
|
||||||
<view class="iconfont icon-you">
|
<view class="iconfont icon-you">
|
||||||
@ -263,6 +263,7 @@ export default {
|
|||||||
},
|
},
|
||||||
data () {
|
data () {
|
||||||
return {
|
return {
|
||||||
|
|
||||||
brange:0,
|
brange:0,
|
||||||
options: {
|
options: {
|
||||||
data: '',
|
data: '',
|
||||||
@ -313,14 +314,11 @@ export default {
|
|||||||
};
|
};
|
||||||
},
|
},
|
||||||
async onLoad () {
|
async onLoad () {
|
||||||
|
|
||||||
await this.$onLaunched;
|
await this.$onLaunched;
|
||||||
this.is_captain = JSON.parse(uni.getStorageSync("USER_INFO")||'{}')?.is_captain
|
this.is_captain = JSON.parse(uni.getStorageSync("USER_INFO")||'{}')?.is_captain
|
||||||
this.options.data = bj;
|
this.options.data = bj;
|
||||||
let user_id= JSON.parse( uni.getStorageSync("USER_INFO")).id
|
|
||||||
getAreaManagerApi({user_id}).then(res=>{
|
|
||||||
console.log(res.data)
|
|
||||||
this.managerInfo=res.data
|
|
||||||
})
|
|
||||||
//#ifdef APP-PLUS
|
//#ifdef APP-PLUS
|
||||||
let that = this;
|
let that = this;
|
||||||
jpushModule.addNotificationListener(function (result) {
|
jpushModule.addNotificationListener(function (result) {
|
||||||
@ -355,8 +353,16 @@ export default {
|
|||||||
})
|
})
|
||||||
},
|
},
|
||||||
async onShow () {
|
async onShow () {
|
||||||
|
// uni.navigateTo({
|
||||||
|
// url:'/subpkg/chatMang/index'
|
||||||
|
// }
|
||||||
// this.getUserIndex()
|
// this.getUserIndex()
|
||||||
// this.getIndexList()
|
// this.getIndexList()
|
||||||
|
let user_id= JSON.parse( uni.getStorageSync("USER_INFO")).id
|
||||||
|
getAreaManagerApi({user_id}).then(res=>{
|
||||||
|
console.log(res.data)
|
||||||
|
this.managerInfo=res.data
|
||||||
|
})
|
||||||
await this.$onLaunched;
|
await this.$onLaunched;
|
||||||
if (uni.getStorageSync('uniMP')) this.uniMP = true;
|
if (uni.getStorageSync('uniMP')) this.uniMP = true;
|
||||||
userInfo().then(({
|
userInfo().then(({
|
||||||
@ -456,6 +462,7 @@ export default {
|
|||||||
})
|
})
|
||||||
},
|
},
|
||||||
leftClick (e) {
|
leftClick (e) {
|
||||||
|
console.log("发送给宿主")
|
||||||
uni.sendHostEvent('closeApp', e, (ret) => {
|
uni.sendHostEvent('closeApp', e, (ret) => {
|
||||||
//发送消息成功回调
|
//发送消息成功回调
|
||||||
console.log('关闭应用' + JSON.stringify(ret));
|
console.log('关闭应用' + JSON.stringify(ret));
|
||||||
|
@ -19,8 +19,13 @@
|
|||||||
</view>
|
</view>
|
||||||
<view @longpress="copyText(item.content)" class="task-li-content" v-if="item.type=='text'"
|
<view @longpress="copyText(item.content)" class="task-li-content" v-if="item.type=='text'"
|
||||||
style="margin-right: 10rpx;">
|
style="margin-right: 10rpx;">
|
||||||
|
<view style="color: #576B95;" @click="href(item.content)" v-if="isLink(item.content)">
|
||||||
{{item.content}}
|
{{item.content}}
|
||||||
</view>
|
</view>
|
||||||
|
<view class="" v-else>
|
||||||
|
{{item.content}}
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
<!-- 图片 -->
|
<!-- 图片 -->
|
||||||
<view class="task-li-content" v-if="item.type=='image'" style="margin-right: 10rpx;"
|
<view class="task-li-content" v-if="item.type=='image'" style="margin-right: 10rpx;"
|
||||||
@tap="previewImage(item.content)">
|
@tap="previewImage(item.content)">
|
||||||
@ -45,7 +50,15 @@
|
|||||||
<!-- 文字 -->
|
<!-- 文字 -->
|
||||||
<view class="task-li-content" @longpress="copyText(item.content)" v-if="item.type=='text'"
|
<view class="task-li-content" @longpress="copyText(item.content)" v-if="item.type=='text'"
|
||||||
style="margin-right: 10rpx;">
|
style="margin-right: 10rpx;">
|
||||||
{{item.content}}
|
<!-- {{item.content}} -->
|
||||||
|
|
||||||
|
<view style="color: #576B95;" @click="href(item.content)" v-if="isLink(item.content)">
|
||||||
|
{{item.content}}
|
||||||
|
</view>
|
||||||
|
<view class="" v-else>
|
||||||
|
{{item.content}}
|
||||||
|
</view>
|
||||||
|
<!-- <a href="item.content" target="_blank"> {{item.content}}</a> -->
|
||||||
</view>
|
</view>
|
||||||
<!-- 图片 -->
|
<!-- 图片 -->
|
||||||
<view class="task-li-content" v-if="item.type=='image'" style="margin-right: 10rpx;"
|
<view class="task-li-content" v-if="item.type=='image'" style="margin-right: 10rpx;"
|
||||||
@ -166,6 +179,15 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
isLink(text){
|
||||||
|
var pattern = /^(https?:\/\/|www\.|.*\.com).*$/i;
|
||||||
|
return pattern.test(text);
|
||||||
|
},
|
||||||
|
href(url){
|
||||||
|
// uni.navigate
|
||||||
|
plus.runtime.openURL(url);
|
||||||
|
// plus.runtime.openUrl(url)
|
||||||
|
},
|
||||||
previewImage(src) {
|
previewImage(src) {
|
||||||
this.imageList[0]=src
|
this.imageList[0]=src
|
||||||
uni.previewImage({
|
uni.previewImage({
|
||||||
@ -546,6 +568,8 @@
|
|||||||
// color: white;
|
// color: white;
|
||||||
word-break: break-all;
|
word-break: break-all;
|
||||||
max-width: 60vw;
|
max-width: 60vw;
|
||||||
|
overflow-wrap: break-word;
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -23,7 +23,15 @@
|
|||||||
<view class="car-info-r">
|
<view class="car-info-r">
|
||||||
选择该车辆为监管车辆
|
选择该车辆为监管车辆
|
||||||
<view class="" style="margin: 10rpx 50rpx;">
|
<view class="" style="margin: 10rpx 50rpx;">
|
||||||
<checkbox @tap='change' activeBorderColor='red' color="#FFCC33" backgroundColor='#FFCC33'></checkbox>
|
<u-checkbox-group
|
||||||
|
v-model="checkboxValue1[index]"
|
||||||
|
placement="column"
|
||||||
|
@change="checkboxChange(index)"
|
||||||
|
>
|
||||||
|
<u-checkbox
|
||||||
|
>
|
||||||
|
</u-checkbox>
|
||||||
|
</u-checkbox-group>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
@ -66,12 +74,24 @@
|
|||||||
a:"https://tse3-mm.cn.bing.net/th/id/OIP-C.0xzWZj1_A-nzJiUBxrk8XQHaEo?w=298&h=186&c=7&r=0&o=5&pid=1.7",
|
a:"https://tse3-mm.cn.bing.net/th/id/OIP-C.0xzWZj1_A-nzJiUBxrk8XQHaEo?w=298&h=186&c=7&r=0&o=5&pid=1.7",
|
||||||
carList:[1,1,1,1,1,1,,1,1,],
|
carList:[1,1,1,1,1,1,,1,1,],
|
||||||
showPop:false,
|
showPop:false,
|
||||||
checkList:[1,1,1,1,1,1,1,1]
|
checkList:[1,1,1,1,1,1,1,1],
|
||||||
|
checkboxValue1:[],
|
||||||
|
arr:[]
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
,methods:{
|
,methods:{
|
||||||
|
checkboxChange(i){
|
||||||
|
if(this.arr.includes(i)){
|
||||||
|
// this.arr
|
||||||
|
}else{
|
||||||
|
|
||||||
|
this.arr.push(i)
|
||||||
|
}
|
||||||
|
|
||||||
|
console.log(this.arr)
|
||||||
|
},
|
||||||
close() {
|
close() {
|
||||||
this.showPop=false
|
this.showPop=false
|
||||||
},
|
},
|
||||||
|
@ -11,6 +11,10 @@
|
|||||||
|
|
||||||
<u-empty text="你还没有所属车辆哦,请向镇公司申请用车或使用自有车辆并绑定系统~" icon="../../static/img/empty/data.png">
|
<u-empty text="你还没有所属车辆哦,请向镇公司申请用车或使用自有车辆并绑定系统~" icon="../../static/img/empty/data.png">
|
||||||
</u-empty>
|
</u-empty>
|
||||||
|
<view class="">
|
||||||
|
|
||||||
|
<mytn text='购买车辆' ></mytn>
|
||||||
|
</view>
|
||||||
<view>
|
<view>
|
||||||
<mytn text='申请用车' class="upCar" :position="false" @click="applycarFn"></mytn>
|
<mytn text='申请用车' class="upCar" :position="false" @click="applycarFn"></mytn>
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user