Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
F
FleetTruckView
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
FleetTruck
FleetTruckView
Commits
47edb76b
Commit
47edb76b
authored
Apr 03, 2025
by
李玲燕
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
commit
parent
309d21cc
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
8 additions
and
5 deletions
+8
-5
main.js
src/main.js
+2
-1
VehicleStore.js
src/store/VehicleStore.js
+3
-2
BasicMessage.vue
src/views/BasicMessage.vue
+3
-2
No files found.
src/main.js
View file @
47edb76b
...
...
@@ -66,9 +66,10 @@ app.use(router)
.
use
(
ViewUIPlus
)
.
use
(
pinia
)
const
config_url
=
process
.
env
.
NODE_ENV
===
'development'
?
'../config.json'
:
'/config.json'
function
getSysConfig
()
{
return
new
Promise
((
resolve
,
reject
)
=>
{
axios
.
get
(
'/config.json'
).
then
((
result
)
=>
{
axios
.
get
(
config_url
).
then
((
result
)
=>
{
let
config
=
result
.
data
resolve
(
config
)
}).
catch
((
error
)
=>
{
...
...
src/store/VehicleStore.js
View file @
47edb76b
...
...
@@ -124,8 +124,8 @@ export const useVehicleStore = defineStore('vehicle', {
}
},
setBasicInfo
(
data
)
{
const
{
oil
,
tire0
,
tire1
,
tire2
,
tire3
,
tire4
,
tire5
}
=
data
this
.
vehicleBasic
=
{
oil
,
tire0
,
tire1
,
tire2
,
tire3
,
tire4
,
tire5
}
const
{
oil
,
isOil
,
tire0
,
tire1
,
tire2
,
tire3
,
tire4
,
tire5
}
=
data
this
.
vehicleBasic
=
{
oil
,
isOil
,
tire0
,
tire1
,
tire2
,
tire3
,
tire4
,
tire5
}
}
}
})
\ No newline at end of file
src/views/BasicMessage.vue
View file @
47edb76b
...
...
@@ -20,7 +20,7 @@
<span
class=
"middle-img"
:style=
"`background-image: url('/image/ic_$
{item.name}.png')`">
{{
basicMid
[
item
.
title
]
||
0
}}{{
item
.
unit
}}
</span>
<span>
{{
item
.
label
}}
</span>
<span>
{{
item
.
title
==
'oil'
?
basicMid
.
isOil
?
'油量'
:
'电量'
:
item
.
label
}}
</span>
</li>
</ul>
</div>
...
...
@@ -213,8 +213,9 @@
number
.
value
=
loginAckValue
.
number
}
if
(
vehicleBasic
)
{
const
{
oil
}
=
vehicleBasic
const
{
oil
,
isOil
}
=
vehicleBasic
basicMid
[
'oil'
]
=
oil
?
oil
.
toFixed
(
2
)
:
0
basicMid
[
'isOil'
]
=
isOil
}
if
(
currentBasic
)
{
const
{
vehicleLoad
,
vehicleSpeed
}
=
currentBasic
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment