Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
H
hnyc-portrait
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
zhaochengxiang
hnyc-portrait
Commits
3d0676a5
Commit
3d0676a5
authored
Jul 23, 2021
by
zhaochengxiang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
参数调整
parent
9cecb262
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
98 additions
and
62 deletions
+98
-62
Dashboard.jsx
src/view/Dashboard.jsx
+48
-30
mDashboard.jsx
src/view/mDashboard.jsx
+50
-32
No files found.
src/view/Dashboard.jsx
View file @
3d0676a5
...
...
@@ -199,32 +199,46 @@ class Dashboard extends Component {
});
this
.
setState
({
loadingOrder
:
true
},
()
=>
{
PostJSON
(
"/data/json/queryByCriteria"
,{
payload
:
{
"userName"
:
"root"
,
"tableModelId"
:
"5e967f53ed72724be6c0bbe8"
,
"whereCriterias"
:[{
"operator"
:
"eq"
,
"parameter"
:
"lic_no"
,
"values"
:[
_custId
]}],
"orderByCriterias"
:[{
"order"
:
"DESC"
,
"parameter"
:
"order_num"
}],
"pageNo"
:
"1"
,
"pageSize"
:
"10"
}}).
then
(
function
(
data
)
{
PostJSON
(
"/data/json/queryByCriteria"
,{
payload
:
{
"tableModelId"
:
"60f97f82ed72725de379586d"
,
"whereCriterias"
:[{
"operator"
:
"eq"
,
"parameter"
:
"lic_no"
,
"values"
:[
_custId
]}],
"orderByCriterias"
:[{
"order"
:
"DESC"
,
"parameter"
:
"order_num"
}],
"pageNo"
:
"1"
,
"pageSize"
:
"10"
},
cfg
:
{
headers
:
{
'Cache-Control'
:
'no-cache,no-store,must-revalidate,max-age=-1,private'
,
'Authorization'
:
'Basic cDUyMDIxNDpkYXRhU2hhcmluZ0AxMjM='
}
}
}).
then
(
function
(
data
)
{
this
.
setState
({
loadingOrder
:
false
,
orderData
:
data
.
data
||
[]
});
}.
bind
(
this
));
});
this
.
setState
({
loadingTrend
:
true
},
()
=>
{
PostJSON
(
"/data/json/queryByCriteria"
,{
payload
:
{
"userName"
:
"root"
,
"tableModelId"
:
"5e9feb08abc30a63724d8eb9"
,
"whereCriterias"
:[{
"operator"
:
"eq"
,
"parameter"
:
"lic_no"
,
"values"
:[
_custId
]}],
"orderByCriterias"
:[{
"order"
:
"DESC"
,
"parameter"
:
"dt"
}],
"pageNo"
:
"1"
,
"pageSize"
:
"3"
}}).
then
(
function
(
data
)
{
this
.
setState
({
loadingTrend
:
false
,
trendData
:
(
data
.
data
||
[]).
reverse
()
},()
=>
{
this
.
handleTrendChange
(
curTrendKey
);
});
}.
bind
(
this
));
});
PostJSON
(
"/data/json/queryByCriteria"
,{
payload
:
{
"tableModelId"
:
"60f97f82ed72725de379586e"
,
"whereCriterias"
:[{
"operator"
:
"eq"
,
"parameter"
:
"lic_no"
,
"values"
:[
_custId
]}],
"orderByCriterias"
:[{
"order"
:
"DESC"
,
"parameter"
:
"dt"
}],
"pageNo"
:
"1"
,
"pageSize"
:
"3"
},
cfg
:
{
headers
:
{
'Cache-Control'
:
'no-cache,no-store,must-revalidate,max-age=-1,private'
,
'Authorization'
:
'Basic cDUyMDIxNDpkYXRhU2hhcmluZ0AxMjM='
}
}
}).
then
(
function
(
data
)
{
this
.
setState
({
loadingTrend
:
false
,
trendData
:
(
data
.
data
||
[]).
reverse
()
},()
=>
{
this
.
handleTrendChange
(
curTrendKey
);
});
}.
bind
(
this
));
});
}
getNowTime
=
()
=>
{
...
...
@@ -286,19 +300,19 @@ class Dashboard extends Component {
let
series
=
[];
let
unit
=
''
;
trendData
&&
trendData
.
map
((
item
,
index
)
=>
{
xAxis
.
push
(
item
.
dt
);
xAxis
.
push
(
item
.
DT
);
if
(
value
===
'0'
)
{
series
.
push
(
item
.
once_order_num
||
''
);
unit
=
item
.
once_order_num_unit
||
''
;
series
.
push
(
item
.
ONCE_ORDER_NUM
||
''
);
unit
=
item
.
ONCE_ORDER_NUM_UNIT
||
''
;
}
else
if
(
value
===
'1'
)
{
series
.
push
(
item
.
month_order_s
||
''
);
unit
=
item
.
month_order_s_unit
||
''
;
series
.
push
(
item
.
MONTH_ORDER_S
||
''
);
unit
=
item
.
MONTH_ORDER_S_UNIT
||
''
;
}
else
if
(
value
===
'2'
)
{
series
.
push
(
item
.
out_pro_wgt
||
''
);
unit
=
item
.
out_pro_wgt_unit
||
''
;
series
.
push
(
item
.
OUT_PRO_WGT
||
''
);
unit
=
item
.
OUT_PRO_WGT_UNIT
||
''
;
}
else
if
(
value
===
'3'
)
{
series
.
push
(
item
.
month_utilization_rate
||
''
);
unit
=
item
.
month_utilization_rate_unit
||
''
;
series
.
push
(
item
.
MONTH_UTILIZATION_RATE
||
''
);
unit
=
item
.
MONTH_UTILIZATION_RATE_UNIT
||
''
;
}
return
item
;
...
...
@@ -395,6 +409,10 @@ class Dashboard extends Component {
<
div
>
经营规模
</
div
>
<
div
className=
"text-primary"
>
{
data
.
custSaleScope
||
''
}
</
div
>
</
Col
>
<
Col
md=
{
12
}
>
<
div
>
是否直送
</
div
>
<
div
className=
"text-primary"
>
{
data
.
custIsInPoint
||
''
}
</
div
>
</
Col
>
</
Row
>
</>
)
...
...
src/view/mDashboard.jsx
View file @
3d0676a5
...
...
@@ -209,31 +209,45 @@ class mDashboard extends Component {
});
this
.
setState
({
loadingOrder
:
true
},
()
=>
{
PostJSON
(
"/data/json/queryByCriteria"
,{
payload
:
{
"userName"
:
"root"
,
"tableModelId"
:
"5e967f53ed72724be6c0bbe8"
,
"whereCriterias"
:[{
"operator"
:
"eq"
,
"parameter"
:
"lic_no"
,
"values"
:[
_custId
]}],
"orderByCriterias"
:[{
"order"
:
"DESC"
,
"parameter"
:
"order_num"
}],
"pageNo"
:
"1"
,
"pageSize"
:
"10"
}}).
then
(
function
(
data
)
{
this
.
setState
({
loadingOrder
:
false
,
orderData
:
data
.
data
||
[]
});
}.
bind
(
this
));
});
PostJSON
(
"/data/json/queryByCriteria"
,{
payload
:
{
"tableModelId"
:
"60f97f82ed72725de379586d"
,
"whereCriterias"
:[{
"operator"
:
"eq"
,
"parameter"
:
"lic_no"
,
"values"
:[
_custId
]}],
"orderByCriterias"
:[{
"order"
:
"DESC"
,
"parameter"
:
"order_num"
}],
"pageNo"
:
"1"
,
"pageSize"
:
"10"
},
cfg
:
{
headers
:
{
'Cache-Control'
:
'no-cache,no-store,must-revalidate,max-age=-1,private'
,
'Authorization'
:
'Basic cDUyMDIxNDpkYXRhU2hhcmluZ0AxMjM='
}
}
}).
then
(
function
(
data
)
{
this
.
setState
({
loadingOrder
:
false
,
orderData
:
data
.
data
||
[]
});
}.
bind
(
this
));
});
this
.
setState
({
loadingTrend
:
true
},
()
=>
{
PostJSON
(
"/data/json/queryByCriteria"
,{
payload
:
{
"userName"
:
"root"
,
"tableModelId"
:
"5e9feb08abc30a63724d8eb9"
,
"whereCriterias"
:[{
"operator"
:
"eq"
,
"parameter"
:
"lic_no"
,
"values"
:[
_custId
]}],
"orderByCriterias"
:[{
"order"
:
"DESC"
,
"parameter"
:
"dt"
}],
"pageNo"
:
"1"
,
"pageSize"
:
"3"
}}).
then
(
function
(
data
)
{
this
.
setState
({
loadingTrend
:
false
,
trendData
:
(
data
.
data
||
[]).
reverse
()
},()
=>
{
this
.
handleTrendChange
(
curTrendKey
);
});
}.
bind
(
this
));
PostJSON
(
"/data/json/queryByCriteria"
,{
payload
:
{
"tableModelId"
:
"60f97f82ed72725de379586e"
,
"whereCriterias"
:[{
"operator"
:
"eq"
,
"parameter"
:
"lic_no"
,
"values"
:[
_custId
]}],
"orderByCriterias"
:[{
"order"
:
"DESC"
,
"parameter"
:
"dt"
}],
"pageNo"
:
"1"
,
"pageSize"
:
"3"
},
cfg
:
{
headers
:
{
'Cache-Control'
:
'no-cache,no-store,must-revalidate,max-age=-1,private'
,
'Authorization'
:
'Basic cDUyMDIxNDpkYXRhU2hhcmluZ0AxMjM='
}
}
}).
then
(
function
(
data
)
{
this
.
setState
({
loadingTrend
:
false
,
trendData
:
(
data
.
data
||
[]).
reverse
()
},()
=>
{
this
.
handleTrendChange
(
curTrendKey
);
});
}.
bind
(
this
));
});
}
...
...
@@ -296,19 +310,19 @@ class mDashboard extends Component {
let
series
=
[];
let
unit
=
''
;
trendData
&&
trendData
.
map
((
item
,
index
)
=>
{
xAxis
.
push
(
item
.
dt
);
xAxis
.
push
(
item
.
DT
);
if
(
value
===
'0'
)
{
series
.
push
(
item
.
once_order_num
||
''
);
unit
=
item
.
once_order_num_unit
||
''
;
series
.
push
(
item
.
ONCE_ORDER_NUM
||
''
);
unit
=
item
.
ONCE_ORDER_NUM_UNIT
||
''
;
}
else
if
(
value
===
'1'
)
{
series
.
push
(
item
.
month_order_s
||
''
);
unit
=
item
.
month_order_s_unit
||
''
;
series
.
push
(
item
.
MONTH_ORDER_S
||
''
);
unit
=
item
.
MONTH_ORDER_S_UNIT
||
''
;
}
else
if
(
value
===
'2'
)
{
series
.
push
(
item
.
out_pro_wgt
||
''
);
unit
=
item
.
out_pro_wgt_unit
||
''
;
series
.
push
(
item
.
OUT_PRO_WGT
||
''
);
unit
=
item
.
OUT_PRO_WGT_UNIT
||
''
;
}
else
if
(
value
===
'3'
)
{
series
.
push
(
item
.
month_utilization_rate
||
''
);
unit
=
item
.
month_utilization_rate_unit
||
''
;
series
.
push
(
item
.
MONTH_UTILIZATION_RATE
||
''
);
unit
=
item
.
MONTH_UTILIZATION_RATE_UNIT
||
''
;
}
return
item
;
...
...
@@ -405,6 +419,10 @@ class mDashboard extends Component {
<
div
>
经营规模
</
div
>
<
div
className=
"text-primary"
>
{
data
.
custSaleScope
||
''
}
</
div
>
</
Col
>
<
Col
md=
{
12
}
>
<
div
>
是否直送
</
div
>
<
div
className=
"text-primary"
>
{
data
.
custIsInPoint
||
''
}
</
div
>
</
Col
>
</
Row
>
</>
)
...
...
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