Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
W
WX_h5
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
godwithdh
WX_h5
Commits
b2def7ed
Commit
b2def7ed
authored
Apr 20, 2020
by
张锡奇
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of
ssh://47.110.145.204:2222/godwithdh/wx_h5
parents
2103b51e
a207c68c
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
263 additions
and
51 deletions
+263
-51
index.js
config/index.js
+8
-1
axios.js
src/libs/axios.js
+1
-1
host.js
src/libs/host.js
+2
-1
index.js
src/router/index.js
+6
-0
Finance.vue
src/view/tiip/kanban/Finance.vue
+82
-48
FinanceDetail.vue
src/view/tiip/kanban/FinanceDetail.vue
+164
-0
No files found.
config/index.js
View file @
b2def7ed
...
@@ -3,7 +3,8 @@
...
@@ -3,7 +3,8 @@
// see http://vuejs-templates.github.io/webpack for documentation.
// see http://vuejs-templates.github.io/webpack for documentation.
const
path
=
require
(
'path'
)
const
path
=
require
(
'path'
)
let
host
=
'https://weixin.huansi.net/apiproxy/huansi/Mall'
;
// let host = 'https://weixin.huansi.net/apiproxy/huansi/Mall';
let
host
=
`https://weixin.huansi.net/apiproxy/huansi/TIP_Test`
;
module
.
exports
=
{
module
.
exports
=
{
dev
:
{
dev
:
{
...
@@ -11,6 +12,12 @@ module.exports = {
...
@@ -11,6 +12,12 @@ module.exports = {
assetsSubDirectory
:
'static'
,
assetsSubDirectory
:
'static'
,
assetsPublicPath
:
'/'
,
assetsPublicPath
:
'/'
,
proxyTable
:
{
proxyTable
:
{
"/TIP_Test"
:{
target
:
"https://weixin.huansi.net/apiproxy/huansi/TIP_Test"
,
pathRewrite
:
{
'^/TIP_Test'
:
''
},
changeOrigin
:
true
,
secure
:
true
},
'/api'
:
{
'/api'
:
{
target
:
host
,
target
:
host
,
pathRewrite
:
{
'^/api'
:
''
},
pathRewrite
:
{
'^/api'
:
''
},
...
...
src/libs/axios.js
View file @
b2def7ed
...
@@ -54,6 +54,6 @@ AsInst.interceptors.response.use(response => {
...
@@ -54,6 +54,6 @@ AsInst.interceptors.response.use(response => {
// Message.error('后端服务请求404错误');
// Message.error('后端服务请求404错误');
}
}
//请求错误时做些事
//请求错误时做些事
return
Promise
.
reject
(
error
);
return
Promise
.
reject
(
error
.
response
);
});
});
export
default
AsInst
;
export
default
AsInst
;
src/libs/host.js
View file @
b2def7ed
...
@@ -12,10 +12,11 @@ function urlFun(name){
...
@@ -12,10 +12,11 @@ function urlFun(name){
/**
/**
* 默认公司
* 默认公司
*/
*/
// default:`http://192.168.4.
34
:5001`,
// default:`http://192.168.4.
51
:5001`,
// default:`https://weixin.huansi.net/apiproxy/huansi/hszh_HSFabricTradeTest`,
// default:`https://weixin.huansi.net/apiproxy/huansi/hszh_HSFabricTradeTest`,
// default:`https://weixin.huansi.net/apiproxy/huansi/service/proxy/${userID}`,
// default:`https://weixin.huansi.net/apiproxy/huansi/service/proxy/${userID}`,
default
:
`https://weixin.huansi.net/apiproxy/huansi/Tip`
,
default
:
`https://weixin.huansi.net/apiproxy/huansi/Tip`
,
// default:`https://weixin.huansi.net/apiproxy/huansi/TIP_Test`,
/**
/**
* 基本地址
* 基本地址
*/
*/
...
...
src/router/index.js
View file @
b2def7ed
...
@@ -115,6 +115,12 @@ let tipRoutes = [
...
@@ -115,6 +115,12 @@ let tipRoutes = [
title
:
"经营分析"
title
:
"经营分析"
}
}
},
},
{
path
:
"/financeDetail"
,
name
:
"financeDetail"
,
component
:()
=>
import
(
"@/view/tiip/kanban/FinanceDetail.vue"
),
meta
:{
title
:
""
}
},
{
{
path
:
"/kanbanOperateDetail"
,
path
:
"/kanbanOperateDetail"
,
name
:
"tiipOperateDetail"
,
name
:
"tiipOperateDetail"
,
...
...
src/view/tiip/kanban/Finance.vue
View file @
b2def7ed
<
style
lang=
"less"
>
<
style
lang=
"less"
>
.Finance{
.Finance{
>div{
.card{
>.title_{
background: #fff;
display: inline-block;
border-radius: 7px;
background: #5E9AFE;
box-shadow: 1px 1px 3px #aaa;
color: #fff;
padding: 10px;
border-bottom-right-radius: 50px;
margin: 10px;
border-top-right-radius: 50px;
padding: 6px 15px;
display: flex;
font-size: 16px;
flex-wrap: wrap;
justify-content: space-between;
>.title{
font-size: 12px !important;
font-weight: 600;
}
}
>.card{
>.more{
background: #fff;
color:#35BAF6;
border-radius: 7px;
}
box-shadow: 1px 1px 3px #aaa;
>.should{
padding: 10px;
display: flex;
margin: 10px;
text-align: center;
min-height:60px;
width:100%;
>div{
display: flex;
flex-direction: column;
justify-content: space-between;
width: 50%;
>span{
padding:2px 0;
&:nth-child(2){
font-weight: bold;
font-size: 23px;
}
}
}
}
>.actual{
display: flex;
text-align: center;
min-height:40px;
width:100%;
>div{
>div{
border-left: 3px solid #5E9AFE;
padding-left: 8px;
display: flex;
display: flex;
>div.num{
flex-direction: column;
flex-grow:1;
justify-content: space-between;
>div{
width: 50%;
font-size:15px;
&:last-child{
&:not(:last-child){padding-bottom:4px;}
border-left:2px solid #03A9F4;
>span:first-child{
}
color:#777;
>span{
padding-right:10px;
padding:2px 0;
}
&:first-child{
font-weight: bold;
font-size: 23px;
}
}
}
}
}
}
}
}
}
}
...
@@ -39,26 +63,33 @@
...
@@ -39,26 +63,33 @@
</
style
>
</
style
>
<
template
>
<
template
>
<div
class=
"Finance"
:style=
"list.length==0&&'background:#fff;height:100%;'"
>
<div
class=
"Finance"
:style=
"list.length==0&&'background:#fff;height:100%;'"
>
<div
v-for=
"(v,k) in list"
:key=
'k'
v-if=
"list.length>0"
>
<div
class=
"card"
v-if=
"list.length>0"
>
<!--
<div
class=
"title_"
>
{{
v
.
sName
}}
</div>
-->
<span
class=
"title"
>
应收应付
</span>
<div
class=
"card"
>
<span
class=
"more"
@
click=
"more(1,0)"
>
更多
</span>
<span
style=
"font-size:15px;"
>
{{
v
.
sName
}}
</span>
<div
class=
"should"
>
<div>
<div
@
click=
"more(1,0)"
>
<div
class=
"num"
>
<span>
应收账款
</span>
<div><span>
数量
</span><span>
{{
Number
(
v
.
nQty
||
0
)
}}
</span></div>
<span>
{{
(
list
.
filter
(
v
=>
v
.
sName
==
"应收"
)[
0
]
&&
list
.
filter
(
v
=>
v
.
sName
==
"应收"
)[
0
].
nAmount
||
0
).
toLocaleString
()
}}
</span>
<div><span>
金额
</span><span
style=
"color:#5E9AFE;"
>
{{
Number
(
v
.
nAmount
||
0
).
toLocaleString
()
}}
</span></div>
<span>
余额:
{{
(
list
.
filter
(
v
=>
v
.
sName
==
"应收"
)[
0
]
&&
list
.
filter
(
v
=>
v
.
sName
==
"应收"
)[
0
].
nCloseAmount
||
0
).
toLocaleString
()
}}
</span>
<div><span>
余额
</span><span
style=
"color:#901AF7;"
>
{{
Number
(
v
.
nCloseAmount
||
0
).
toLocaleString
()
}}
</span></div>
</div>
</div>
<div
@
click=
"more(1,1)"
>
<XCircle
<span>
应付账款
</span>
style=
"width: 70px;height: 70px;margin-right:15px;"
<span
style=
"color:red;"
>
{{
(
list
.
filter
(
v
=>
v
.
sName
==
"应付"
)[
0
]
&&
list
.
filter
(
v
=>
v
.
sName
==
"应付"
)[
0
].
nAmount
||
0
).
toLocaleString
()
}}
</span>
:percent=
"Number(v.nPercent)||0"
<span>
余额:
{{
(
list
.
filter
(
v
=>
v
.
sName
==
"应付"
)[
0
]
&&
list
.
filter
(
v
=>
v
.
sName
==
"应付"
)[
0
].
nCloseAmount
||
0
).
toLocaleString
()
}}
</span>
:stroke-width=
"10"
</div>
:id=
"`perent$
{k}`"
</div>
:stroke-color="color[k%4]"
</div>
:trail-width="5"
<div
class=
"card"
v-if=
"list.length>0"
>
trail-color="#ececec">
<span
class=
"title"
>
实收实付
</span>
<span
style=
"color:#36D1DC;"
>
{{
Number
(
v
.
nPercent
)
||
0
}}
%
</span>
<span
class=
"more"
@
click=
"more(2,0)"
>
更多
</span>
</XCircle>
<div
class=
"actual"
>
<div
@
click=
"more(2,0)"
>
<span>
{{
(
list
.
filter
(
v
=>
v
.
sName
==
"实付"
)[
0
]
&&
list
.
filter
(
v
=>
v
.
sName
==
"实付"
)[
0
].
nAmount
||
0
).
toLocaleString
()
}}
</span>
<span>
实收账款
</span>
</div>
<div
@
click=
"more(2,1)"
>
<span
style=
"color:red;"
>
{{
(
list
.
filter
(
v
=>
v
.
sName
==
"实付"
)[
0
]
&&
list
.
filter
(
v
=>
v
.
sName
==
"实付"
)[
0
].
nAmount
||
0
).
toLocaleString
()
}}
</span>
<span>
实付账款
</span>
</div>
</div>
</div>
</div>
</div>
</div>
...
@@ -121,7 +152,10 @@ export default {
...
@@ -121,7 +152,10 @@ export default {
showConfirmButton
:
false
,
showConfirmButton
:
false
,
})
})
}
}
}
},
more
(
val
,
tabIndex
){
this
.
$router
.
push
({
name
:
"financeDetail"
,
params
:{
mode
:
val
,
tabIndex
:
tabIndex
,
start
:
this
.
start
,
end
:
this
.
end
}})
},
},
},
}
}
</
script
>
</
script
>
src/view/tiip/kanban/FinanceDetail.vue
0 → 100644
View file @
b2def7ed
<
style
lang=
"less"
>
#FinanceDetail{
display: flex;
flex-direction: column;
height:100%;
>.search{
padding:5px;
text-align: center;
>input{
background: #fff;
width: 90%;
border-radius: 5px;
height: 30px;
border: 1px solid #e9ecf3;
padding: 2px;
}
}
>.balance{
padding: 10px;
justify-content: space-between;
display: flex;
background: #fff;
border-bottom:1px solid #ddd;
}
>.content{
flex-grow:1;
overflow: auto;
height:1px;
font-size:15px;
>.list{
background:#fff;
display:flex;
>span{
&:first-child{
padding: 10px 5px;
min-width: 30px;
text-align: right;
font-weight: 600;
}
&:nth-child(2n){
flex-grow:1;
}
&:nth-child(2n-1){
flex-shrink: 0;
}
&:not(:first-child){
border-bottom: 1px solid #ddd;
display: flex;
align-items: center;
color:#777;
}
&:last-child{
padding:0 10px;
}
}
}
}
}
</
style
>
<
template
>
<div
id=
"FinanceDetail"
>
<tab
v-model=
"tabIndex"
prevent-default
default-color=
"#000"
active-color=
"#5E9AFE"
@
on-before-index-change=
"switchTabItem"
>
<template
v-if=
"$route.params.mode==1"
>
<tab-item
selected
>
应收账款
</tab-item>
<tab-item>
应付账款
</tab-item>
</
template
>
<
template
v-else
>
<tab-item
selected
>
实收账款
</tab-item>
<tab-item>
实付账款
</tab-item>
</
template
>
</tab>
<div
class=
"search"
>
<input
placeholder=
"请输入客户简称/名称进行搜索"
v-model=
"searchValue"
/>
</div>
<div
class=
"balance"
v-if=
"$route.params.mode==1"
>
<span>
余额
</span>
<span>
{{balance.toLocaleString()}}
</span>
</div>
<div
class=
"content"
>
<div
class=
"list"
v-for=
"(v,k) in list"
:key=
"k"
>
<span>
{{k}}
</span>
<span>
{{v["客户名称"]}}
</span>
<span>
{{v["总金额"]}}
</span>
</div>
<img
src=
"@/assets/noData.jpg"
style=
"width:100%;"
v-if=
"list.length==0"
/>
</div>
</div>
</template>
<
script
>
import
Util
from
'@/libs/util.js'
import
{
Tab
,
TabItem
}
from
'vux'
var
inputIng
=
false
var
searchIng
=
false
export
default
{
name
:
"FinanceDetail"
,
components
:{
Tab
,
TabItem
},
data
(){
return
{
tabIndex
:
0
,
searchValue
:
""
,
balance
:
0
,
list
:[],
}
},
activated
(){
this
.
tabIndex
=
this
.
$route
.
params
.
tabIndex
this
.
$nextTick
(()
=>
{
this
.
searchList
();
})
},
watch
:{
searchValue
(
n
,
o
){
this
.
delayedSearch
()
},
},
methods
:{
switchTabItem
(
index
){
if
(
this
.
tabIndex
!=
index
){
this
.
tabIndex
=
index
this
.
searchList
()
}
},
async
searchList
(){
var
data
=
[
{
key
:
"begin_date"
,
value
:
Util
.
dateFormat
(
this
.
$route
.
params
.
start
,
"yyyy-MM-dd"
)},
{
key
:
"end_date"
,
value
:
Util
.
dateFormat
(
this
.
$route
.
params
.
end
,
"yyyy-MM-dd 23:59"
)},
{
key
:
"url"
,
value
:
"Financial Summary Dtl"
},
{
key
:
"sType"
,
value
:(
this
.
$route
.
params
.
mode
==
1
?
'应'
:
'实'
)
+
(
this
.
tabIndex
==
0
?
'收'
:
'付'
)}
]
this
.
searchValue
&&
data
.
push
({
key
:
"sQueryValue"
,
value
:
this
.
searchValue
})
var
value
=
await
this
.
request
(
"getBoss"
,{
data
:
data
},
"加载中"
,{})
this
.
list
=
value
this
.
total
()
},
total
(){
this
.
balance
=
0
this
.
list
.
forEach
(
v
=>
{
this
.
balance
+=
v
[
"总金额"
]
})
},
delayedSearch
(){
inputIng
=
true
if
(
!
searchIng
){
searchIng
=
true
inputIng
=
false
this
.
searchList
()
setTimeout
(()
=>
{
searchIng
=
false
if
(
inputIng
){
inputIng
=
false
this
.
delayedSearch
()
}
},
500
)
}
}
}
}
</
script
>
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