Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
F
fmp_takeout
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
zhenfei.zhang
fmp_takeout
Commits
e2ca1c49
Commit
e2ca1c49
authored
Aug 07, 2017
by
guanghui.cui
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
账单功能
parent
b73febe4
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
27 additions
and
7 deletions
+27
-7
Model/orderObject.cpp
+1
-1
Thread/workThread/flowcontroll.cpp
+9
-2
Ui/DetailForm.cpp
+17
-4
No files found.
Model/orderObject.cpp
View file @
e2ca1c49
...
...
@@ -46,7 +46,7 @@ void OrderObject::FromJson(const QJsonObject &json)
}
QString
order_file
=
ConfigManger
::
GetInstance
().
GetBillFile
();
order_file
+=
"."
+
channel
+
"."
+
QDateTime
::
fromTime_t
(
create_time
).
toString
(
"yyyyMMddhhmmss"
)
+
"."
+
QString
::
number
(
order_index
);
order_file
+=
"."
+
channel
+
"."
+
order_id
+
"."
+
QString
::
number
(
order_index
);
QFileInfo
bill_fm
(
order_file
);
qDebug
()
<<
"order_file is"
<<
order_file
;
...
...
Thread/workThread/flowcontroll.cpp
View file @
e2ca1c49
...
...
@@ -996,6 +996,7 @@ QString flowControll::getHostMacAddress()
return
true
;
}
}
return
result
;
}
...
...
@@ -1215,7 +1216,12 @@ bool flowControll::_RefundOrder(const QString& orderId, QString reason)//退单
void
flowControll
::
onReEntryOrder
(
OrderObject
*
orderObject
,
int
operation
)
{
if
(
operation
==
OPERATIONMAME_ENTRY
)
int
result
;
if
(
operation
!=
OPERATIONMAME_ENTRY
)
{
return
;
}
if
((
orderObject
->
status
!=
100
&&
orderObject
->
status
!=
3
)
&&!
Orderstatus
::
getInstance
().
isentry
(
orderObject
->
order_id
))
{
if
(
!
DoSalesSlip
(
orderObject
,
0
))
{
...
...
@@ -1227,7 +1233,8 @@ bool flowControll::_RefundOrder(const QString& orderId, QString reason)//退单
QLOG_INFO
()
<<
QString
(
"[entry order %1 success]."
).
arg
(
orderObject
->
order_id
);
}
}
else
if
((
orderObject
->
status
==
100
||
orderObject
->
status
==
3
)
&&!
Orderstatus
::
getInstance
().
isrefund
(
orderObject
->
order_id
)
&&
Orderstatus
::
getInstance
().
isentry
(
orderObject
->
order_id
))
{
QString
tmpstr
=
""
;
if
(
!
RefuseSalesSlip
(
orderObject
))
...
...
Ui/DetailForm.cpp
View file @
e2ca1c49
...
...
@@ -56,6 +56,8 @@ DetailForm &DetailForm::GetInstance()
DetailForm
::~
DetailForm
()
{
if
(
m_orderObject
)
m_orderObject
->
mate_assigned
=
0
;
delete
ui
;
}
...
...
@@ -127,6 +129,7 @@ void DetailForm::showUi(OrderObject *orderObject)
// {
// ui->againWrite->hide();
// }
if
(
orderObject
->
status
==
3
||
orderObject
->
status
==
100
)
{
if
(
!
Orderstatus
::
getInstance
().
isrefund
(
orderObject
->
order_id
))
...
...
@@ -134,14 +137,22 @@ void DetailForm::showUi(OrderObject *orderObject)
ui
->
againWrite
->
show
();
ui
->
againWrite
->
setProperty
(
"operation"
,
OPERATIONMAME_REFUDN
);
}
else
{
ui
->
againWrite
->
hide
();
}
}
else
{
if
(
!
Orderstatus
::
getInstance
().
isentry
(
orderObject
->
order_id
))
if
(
!
Orderstatus
::
getInstance
().
isentry
(
orderObject
->
order_id
))
//是否成功写过销售单
{
ui
->
againWrite
->
show
();
ui
->
againWrite
->
setProperty
(
"operation"
,
OPERATIONMAME_ENTRY
);
}
else
{
ui
->
againWrite
->
hide
();
}
}
ui
->
refuseorder
->
setProperty
(
"operation"
,
OPERATION_REFUSE
);
...
...
@@ -170,8 +181,9 @@ void DetailForm::showUi(OrderObject *orderObject)
ui
->
detailnull
->
hide
();
}
if
(
m_rejectForm
==
NULL
)
{
m_rejectForm
=
new
RejectForm
(
this
);
}
bool
assigned
=
_ReadBilledMates
();
QLOG_INFO
()
<<
"read order mates: "
<<
m_orderObject
->
pvm
<<
assigned
;
...
...
@@ -202,8 +214,9 @@ void DetailForm::WriteData(/*char data[]*/)
{
return
;
}
emit
reEntryOrder
(
m_orderObject
,
btn
->
property
(
"opertion"
).
toInt
());
hide
();
emit
reEntryOrder
(
m_orderObject
,
btn
->
property
(
"opertion"
).
toInt
());
m_orderObject
->
mate_assigned
=
0
;
hide
();
}
QString
DetailForm
::
_Penny2Dollar
(
int
penny
)
...
...
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