精度丢失
This commit is contained in:
parent
38a0182e14
commit
f5c1af34d9
2
.env.dev
2
.env.dev
@ -6,7 +6,7 @@ VITE_DEV=true
|
||||
# 请求路径
|
||||
# VITE_BASE_URL='http://192.168.0.66:48080'
|
||||
# VITE_BASE_URL='http://192.168.0.189:48080'
|
||||
VITE_BASE_URL='http://192.168.77.50:48080'
|
||||
VITE_BASE_URL='http://10.10.5.5:48080'
|
||||
|
||||
# 文件上传类型:server - 后端上传, client - 前端直连上传,仅支持S3服务
|
||||
VITE_UPLOAD_TYPE=server
|
||||
|
@ -5,7 +5,8 @@ VITE_DEV=true
|
||||
|
||||
# 请求路径
|
||||
# VITE_BASE_URL='http://192.168.77.50:48080'
|
||||
VITE_BASE_URL='http://10.10.100.24:48080'
|
||||
# VITE_BASE_URL='http://10.10.100.32:48080'
|
||||
VITE_BASE_URL='http://10.10.5.5:48080'
|
||||
|
||||
# 文件上传类型:server - 后端上传, client - 前端直连上传,仅支持 S3 服务
|
||||
VITE_UPLOAD_TYPE=server
|
||||
|
@ -5,6 +5,7 @@ import qs from 'qs'
|
||||
import { config } from '@/config/axios/config'
|
||||
import { getAccessToken, getRefreshToken, getTenantId, removeToken, setToken } from '@/utils/auth'
|
||||
import errorCode from './errorCode'
|
||||
import JSONBigInt from 'json-bigint'
|
||||
|
||||
import { resetRouter } from '@/router'
|
||||
import { deleteUserCache } from '@/hooks/web/useCache'
|
||||
@ -36,6 +37,16 @@ const service: AxiosInstance = axios.create({
|
||||
paramsSerializer: (params) => {
|
||||
return qs.stringify(params, { allowDots: true })
|
||||
}
|
||||
// transformResponse: [
|
||||
// (data) => {
|
||||
// try {
|
||||
// // 使用 json-bigint 解析,大数字会转为字符串
|
||||
// return JSONBigInt.parse(data)
|
||||
// } catch (e) {
|
||||
// return data
|
||||
// }
|
||||
// }
|
||||
// ]
|
||||
})
|
||||
|
||||
// request拦截器
|
||||
|
@ -346,22 +346,16 @@
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import JSONBigInt from 'json-bigint'
|
||||
import { ref, reactive, onMounted, onBeforeUnmount } from 'vue'
|
||||
defineOptions({ name: 'BoardCarBoard' })
|
||||
import * as CarApi from '@/api/car/index'
|
||||
// import { Swiper, SwiperSlide } from 'swiper/vue'
|
||||
// 导入两个组件内的路由守卫API
|
||||
import { onBeforeRouteLeave, onBeforeRouteUpdate } from 'vue-router'
|
||||
const message = useMessage() // 消息弹窗
|
||||
// 引入swiper样式(按需导入)
|
||||
// import 'swiper/css/pagination' // 轮播图底面的小圆点
|
||||
// import 'swiper/css/navigation' // 轮播图两边的左右箭头
|
||||
// import 'swiper/css/scrollbar' // 轮播图的滚动条, 轮播图里一般不怎么会使用到滚动条,如果有用到的话import导入就行
|
||||
// 引入swiper核心和所需模块
|
||||
// import { Autoplay, Pagination, Navigation, Scrollbar } from 'swiper'
|
||||
import createEditDialog from './createEditDialog.vue'
|
||||
|
||||
defineOptions({ name: 'BoardCarBoard' })
|
||||
|
||||
const message = useMessage() // 消息弹窗
|
||||
const route = useRoute() // 路由
|
||||
// import 'swiper/css'
|
||||
const router = useRouter() // 路由对象
|
||||
const createEditDialogRef = ref(null)
|
||||
const list = ref([])
|
||||
@ -371,25 +365,7 @@ const queryParams = reactive({
|
||||
robotNo: undefined,
|
||||
robotStatisticsType: undefined //车辆状态类型(待命:standby, 任务中:inTask, 锁定:doLock, 离线:offline, 充电中:charge, 故障:fault)
|
||||
})
|
||||
// const spaceBetween = ref(20)
|
||||
// const navigation = ref({
|
||||
// nextEl: '.swiper-button-next-custome',
|
||||
// prevEl: '.swiper-button-prev-custome'
|
||||
// })
|
||||
// // 在modules加入要使用的模块
|
||||
// const modules = [Autoplay, Navigation, Scrollbar]
|
||||
// // Pagination
|
||||
// const prevEl = (item, index) => {
|
||||
// // console.log('上一张' + index + item)
|
||||
// }
|
||||
// const nextEl = () => {
|
||||
// // console.log('下一张')
|
||||
// }
|
||||
// // 更改当前活动swiper
|
||||
// const onSlideChange = (swiper) => {
|
||||
// // swiper是当前轮播的对象,里面可以获取到当前swiper的所有信息,当前索引是activeIndex
|
||||
// console.log(swiper.activeIndex)
|
||||
// }
|
||||
|
||||
const timerRef = ref(null)
|
||||
//查询车辆列表
|
||||
const getCarList = async () => {
|
||||
@ -401,8 +377,8 @@ const getCarList = async () => {
|
||||
getCarList()
|
||||
getRobotInformationStatistics()
|
||||
}, 10000)
|
||||
|
||||
let res = await CarApi.getRobotInformationList(queryParams)
|
||||
// console.log(res.list)
|
||||
list.value = res.list
|
||||
}
|
||||
const carStatistics = ref({
|
||||
|
Loading…
Reference in New Issue
Block a user