Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
cdz_gateway_v2
Overview
Overview
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
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
杨苏杭
cdz_gateway_v2
Commits
277a93be
Commit
277a93be
authored
Dec 06, 2018
by
yangsh
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改功率上报的用电量更新开始充电的用电量
parent
85be0ea8
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
5 additions
and
1 deletions
+5
-1
.idea/workspace.xml
+0
-0
application/controller/business/charger/OverController.php
+1
-0
application/controller/business/power/PowerController.php
+4
-1
No files found.
.idea/workspace.xml
View file @
277a93be
This diff is collapsed.
Click to expand it.
application/controller/business/charger/OverController.php
View file @
277a93be
...
@@ -64,6 +64,7 @@ class OverController extends Controller
...
@@ -64,6 +64,7 @@ class OverController extends Controller
$order
->
setEndCapacity
(
$capacity
);
$order
->
setEndCapacity
(
$capacity
);
$order
->
setEndCode
(
$state
);
$order
->
setEndCode
(
$state
);
$portId
=
isset
(
$_SESSION
[
'port_logic_id'
][
$logicId
])
?
$_SESSION
[
'port_logic_id'
][
$logicId
]
:
0
;
$portId
=
isset
(
$_SESSION
[
'port_logic_id'
][
$logicId
])
?
$_SESSION
[
'port_logic_id'
][
$logicId
]
:
0
;
if
(
$portId
!==
0
)
{
if
(
$portId
!==
0
)
{
$this
->
logRecord
->
setPortId
(
$portId
);
$this
->
logRecord
->
setPortId
(
$portId
);
}
}
...
...
application/controller/business/power/PowerController.php
View file @
277a93be
...
@@ -83,6 +83,7 @@ class PowerController extends Controller
...
@@ -83,6 +83,7 @@ class PowerController extends Controller
}
else
{
}
else
{
$orderModel
=
new
OrderModel
();
$orderModel
=
new
OrderModel
();
$orderModel
->
update
([
'start_capacity'
=>
$capacity
],
'id ='
.
$orderId
.
'and start_capacity = -1'
);
$orderModel
->
update
([
'end_capacity'
=>
$capacity
],
'id = '
.
$orderId
);
$orderModel
->
update
([
'end_capacity'
=>
$capacity
],
'id = '
.
$orderId
);
}
}
...
@@ -174,8 +175,10 @@ class PowerController extends Controller
...
@@ -174,8 +175,10 @@ class PowerController extends Controller
//更新结束充电用电量
//更新结束充电用电量
if
(
$i
===
(
$count
-
1
))
{
if
(
$i
===
(
$count
-
1
))
{
$orderModel
=
new
OrderModel
();
$orderModel
=
new
OrderModel
();
$capacity
=
hexdec
(
$capacitys
[
$i
]);
$orderModel
->
update
([
'start_capacity'
=>
$capacity
],
'id ='
.
$orderId
.
'and start_capacity = -1'
);
$orderModel
->
update
([
$orderModel
->
update
([
'end_capacity'
=>
hexdec
(
$capacitys
[
$i
])
,
'end_capacity'
=>
$capacity
,
],
'id = '
.
$orderId
);
],
'id = '
.
$orderId
);
}
}
}
}
...
...
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