DESKTOP-2IO5MST\huting před 1 rokem
rodič
revize
58df8587cd
3 změnil soubory, kde provedl 74 přidání a 39 odebrání
  1. 59
    22
      pages/index/index.vue
  2. 15
    13
      pages/user/user.vue
  3. 0
    4
      utils/network/request.js

+ 59
- 22
pages/index/index.vue Zobrazit soubor



<!-- 消息滚动显示 --> <!-- 消息滚动显示 -->
<view class="backlog-notice"> <view class="backlog-notice">
<notice-bar :noticeList="state.noticeList" @noticeClick="$util.msg('该功能正在开发中,敬请期待!')"></notice-bar>
<notice-bar :noticeList="state.noticeList" @noticeClick="goOrder(3)"></notice-bar>
</view> </view>


<!--快速办理通道 --> <!--快速办理通道 -->
querySwiper, querySwiper,
envs, envs,
infoQuery, infoQuery,
queryHighMsg
queryHighMsg,
orderList
} from "@/utils/network/api.js"; } from "@/utils/network/api.js";
import { import {
reactive reactive
swiperList: [], swiperList: [],
noticeList: [ noticeList: [
//公告栏列表 //公告栏列表
{
title: "您有一条待办事项,还未办理完成",
id: 1,
},
{
title: "XXX刚刚申请了公交车发行",
id: 2,
},
{
title: "您还有一条订单已经发货了",
id: 3,
},
{
title: "订单等您确认收货",
id: 4,
},
{
title: "最新的新闻资讯请点击哈哈哈哈哈哈哈假的假的假的假的基督教",
id: 5,
},
// {
// title: "您有{}条未完成订单,前往处理",
// id: 1,
// },
// {
// title: "XXX刚刚申请了公交车发行",
// id: 2,
// },
// {
// title: "您还有一条订单已经发货了",
// id: 3,
// },
// {
// title: "订单等您确认收货",
// id: 4,
// },
// {
// title: "最新的新闻资讯请点击哈哈哈哈哈哈哈假的假的假的假的基督教",
// id: 5,
// },
], ],
flowPathTabList: ["办理流程", "办理条件", "常见问题"], flowPathTabList: ["办理流程", "办理条件", "常见问题"],
tabActive: "办理流程", tabActive: "办理流程",
highMsg(); //高速快讯 highMsg(); //高速快讯
processeCondition();//办理条件 processeCondition();//办理条件
commonQuestion(); commonQuestion();
doSomething();//代办事项
}) })


onMounted(() => { onMounted(() => {
console.log(err); console.log(err);
}); });
} }
// 代办事项
const doSomething = () => {
let options = {
type: 2, //type: 2,JSON格式提交数据(默认表单形式提交)
data: {
"opId": getItem(StorageKeys.OpenId),
"source": "WECHAT",
"vehiclePlate": "",
"tabIndex": 3 + '',
"pageNo": 1,
"pageSize": 100,
"promotionModes": 1
},
method: "POST", //提交方式(默认POST)
};

//调用方式
request(orderList, options)
.then((res) => {
let data = stringToJson(res.bizContent)
let obj = {};
obj["id"] = 1;
obj['title'] = "您有" + data.data.length + "条未完成订单,前往处理"
state.noticeList.push(obj)
console.log("代办事项", data.data)
})
.catch((err) => {
console.log(err);
});
}
const goOrder = (index) => {
uni.reLaunch({
url: `../order/order?index=${index}`
})
}
</script> </script>


<style> <style>

+ 15
- 13
pages/user/user.vue Zobrazit soubor

<view class="car-item" v-for="(item,index) in state.list"> <view class="car-item" v-for="(item,index) in state.list">
<image :src="`${$imgUrl}che.png`" class="car-pic"></image> <image :src="`${$imgUrl}che.png`" class="car-pic"></image>
<view class="car-info"> <view class="car-info">
<view class="car-no"><text class="no">{{item.vehiclePlate}}</text><text class="color">{{item.color}}</text></view>
<view class="car-no"><text class="no">{{item.vehiclePlate}}</text><text
class="color">{{item.color}}</text></view>
<view class="card-no">卡号:{{item.cardId}}</view> <view class="card-no">卡号:{{item.cardId}}</view>
<view class="card-no">签号:{{item.obuId}}</view> <view class="card-no">签号:{{item.obuId}}</view>
</view> </view>
stringToJson stringToJson
} from "@/utils/network/encryption.js"; } from "@/utils/network/encryption.js";
import filter from '@/components/filter/filter.vue'; import filter from '@/components/filter/filter.vue';
import { vehiclePlateColor, vehiclePlateColorPai} from "@/datas/vehiclePlateColor.js";
import { vehiclePlateColor, vehiclePlateColorPai } from "@/datas/vehiclePlateColor.js";
const height = ref(null); const height = ref(null);
const top = ref(null); const top = ref(null);
const margin = ref(null); const margin = ref(null);
opId: "", opId: "",
}, },
accountInfoVo: { accountInfoVo: {
nickName:'',
nickName: '',
mobile: '' mobile: ''
}, },
monthFlowingVo: { monthFlowingVo: {
vehicleSum: 0, vehicleSum: 0,
orderStatus0: 0 orderStatus0: 0
},//车数量 ,代办数量 },//车数量 ,代办数量
isTrajectory:false, //是否有轨迹
isTrajectory: false, //是否有轨迹
}); });
onMounted(() => { onMounted(() => {
const res = uni.getMenuButtonBoundingClientRect(); const res = uni.getMenuButtonBoundingClientRect();
state.data.opId = getItem(StorageKeys.OpenId); state.data.opId = getItem(StorageKeys.OpenId);
mobile.value = getItem("mobile"); mobile.value = getItem("mobile");
}); });
const goTrajectory=()=>{
if(state.isTrajectory){
const goTrajectory = () => {
if (state.isTrajectory) {
uni.navigateTo({ uni.navigateTo({
url:"/subpackage/personal-center/trajectory/trajectory"
url: "/subpackage/personal-center/trajectory/trajectory"
}) })
}else{
} else {
msg("暂无轨迹") msg("暂无轨迹")
} }
} }
console.log('用户信息', res) console.log('用户信息', res)
let data = stringToJson(res.bizContent) let data = stringToJson(res.bizContent)
state.accountInfoVo = data.accountInfoVo; state.accountInfoVo = data.accountInfoVo;
if(data.monthFlowingVo && JSON.stringify(data.monthFlowingVo) != "{}"){
if (data.monthFlowingVo && JSON.stringify(data.monthFlowingVo) != "{}") {
state.monthFlowingVo = data.monthFlowingVo; state.monthFlowingVo = data.monthFlowingVo;
state.isTrajectory=true;
state.isTrajectory = true;
} }
state.userVehicleInfoSumQueryVo.vehicleSum = JSON.parse(JSON.stringify(data.userVehicleInfoSumQueryVo)).vehicleSum; state.userVehicleInfoSumQueryVo.vehicleSum = JSON.parse(JSON.stringify(data.userVehicleInfoSumQueryVo)).vehicleSum;
state.userVehicleInfoSumQueryVo.orderStatus0 = JSON.parse(JSON.stringify(data.userVehicleInfoSumQueryVo)).orderStatus0; state.userVehicleInfoSumQueryVo.orderStatus0 = JSON.parse(JSON.stringify(data.userVehicleInfoSumQueryVo)).orderStatus0;
} }
}); });
} }
const goOrder=(index)=>{
const goOrder = (index) => {
uni.reLaunch({ uni.reLaunch({
url:`../order/order?index=${index}`
url: `../order/order?index=${index}`
}) })
} }
</script> </script>
.menu .sub-tit { .menu .sub-tit {
padding-right: 20rpx; padding-right: 20rpx;
} }
.color{

.color {
padding: 4rpx 8rpx; padding: 4rpx 8rpx;
border-radius: 10rpx; border-radius: 10rpx;
color: white; color: white;

+ 0
- 4
utils/network/request.js Zobrazit soubor

accessToken: getItem(StorageKeys.Token) accessToken: getItem(StorageKeys.Token)
} }
options.url = envs[process.env.NODE_ENV].baseUrl + '/api/interfaceMidGroundIn' options.url = envs[process.env.NODE_ENV].baseUrl + '/api/interfaceMidGroundIn'
<<<<<<< HEAD
// options.url = envs[process.env.NODE_ENV].baseUrl + '/ifzt/api/interfaceMidGroundIn'
=======
>>>>>>> 29fd2fd4ca7fc1cfd9a89c58cda5f16861e566da
// options.url = envs[process.env.NODE_ENV].baseUrl + '/ifzt/api/interfaceMidGroundIn' // options.url = envs[process.env.NODE_ENV].baseUrl + '/ifzt/api/interfaceMidGroundIn'
//默认json数据格式提交` //默认json数据格式提交`
let contentType = 'application/x-www-form-urlencoded' let contentType = 'application/x-www-form-urlencoded'

Načítá se…
Zrušit
Uložit