Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
F
fe-app-h5
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
万亚飞
fe-app-h5
Commits
fac43759
Commit
fac43759
authored
May 28, 2019
by
万亚飞
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix
parent
9a407488
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
177 additions
and
186 deletions
+177
-186
App.jsx
src/App.jsx
+5
-2
DepositPay.js
src/pages/deposit/DepositPay.js
+21
-24
DepositUser.js
src/pages/deposit/DepositUser.js
+72
-75
Train.js
src/pages/user/Train.js
+28
-31
TrainList.js
src/pages/user/TrainList.js
+51
-54
photoswipe.css
src/static/styles/photoswipe.css
+0
-0
No files found.
src/App.jsx
View file @
fac43759
...
...
@@ -33,8 +33,11 @@ class App extends React.Component {
search
=
search
.
substr
(
1
).
split
(
'&'
);
let
obj
=
{};
search
.
forEach
(
item
=>
{
let
it
=
item
.
match
(
/
(
.+
)
=
(
.+
)
/
);
obj
[
it
[
1
]]
=
it
[
2
];
if
(
item
)
{
console
.
log
(
item
);
let
it
=
item
.
match
(
/
(
.+
)
=
(
.+
)
/
);
obj
[
it
[
1
]]
=
it
[
2
];
}
});
return
obj
;
}
...
...
src/pages/deposit/DepositPay.js
View file @
fac43759
import
React
,
{
Component
}
from
'react'
;
import
Layout
from
'../../Components/static/Layout/Layout'
;
import
{
List
,
Icon
,
Button
,
Toast
}
from
'antd-mobile'
;
import
app
from
'../../static/js/native'
;
import
fetch
from
'../../api/fetch'
;
...
...
@@ -185,31 +184,29 @@ export default class DepositPay extends Component {
<
/div
>
);
return
(
<
Layout
title
=
{
title
}
border
=
"true"
>
<
div
className
=
"bg-grey-bj deposit-wrap"
>
{
isQualityType
?
(
<
div
>
<
List
className
=
"my-list"
>
<
Item
extra
=
{
extra2
(
needPayQuality
,
true
)}
>
质量保证金
<
/Item
>
<
/List
>
<
/div
>
)
:
(
<
div
>
{
depositAmount
>
0
&&
lists
(
true
,
'已缴纳项目'
)}
{
lists
(
false
,
'*选择多项时,保证金按金额最高的一项缴纳'
)}
<
/div
>
)}
<
div
className
=
"fixBottom"
>
<
div
className
=
"fz13 tac ptb20"
>
点击缴纳保证金即代表您同意
<
a
href
=
"/deposit/protocol"
>
《保证金协议》
<
/a
>
<
/div
>
<
Button
type
=
"primary"
className
=
"bdrs0"
onClick
=
{
this
.
submit
}
>
(
¥
{
isQualityType
?
needPayQuality
:
needPayMoney
})
缴纳保证金
<
/Button
>
<
div
className
=
"bg-grey-bj deposit-wrap"
>
{
isQualityType
?
(
<
div
>
<
List
className
=
"my-list"
>
<
Item
extra
=
{
extra2
(
needPayQuality
,
true
)}
>
质量保证金
<
/Item
>
<
/List
>
<
/div
>
{
/* <div className={"h100"}/> */
}
)
:
(
<
div
>
{
depositAmount
>
0
&&
lists
(
true
,
'已缴纳项目'
)}
{
lists
(
false
,
'*选择多项时,保证金按金额最高的一项缴纳'
)}
<
/div
>
)}
<
div
className
=
"fixBottom"
>
<
div
className
=
"fz13 tac ptb20"
>
点击缴纳保证金即代表您同意
<
a
href
=
"/deposit/protocol"
>
《保证金协议》
<
/a
>
<
/div
>
<
Button
type
=
"primary"
className
=
"bdrs0"
onClick
=
{
this
.
submit
}
>
(
¥
{
isQualityType
?
needPayQuality
:
needPayMoney
})
缴纳保证金
<
/Button
>
<
/div
>
<
/Layout
>
{
/* <div className={"h100"}/> */
}
<
/div
>
);
}
}
src/pages/deposit/DepositUser.js
View file @
fac43759
import
React
,
{
Component
}
from
'react'
;
import
Layout
from
'../../Components/static/Layout/Layout'
;
import
{
List
,
Icon
,
Toast
}
from
'antd-mobile'
;
import
app
from
'../../static/js/native'
;
import
Tips
from
'../../Components/common/Tips/Tips'
;
...
...
@@ -68,90 +67,88 @@ export default class DepositPay extends Component {
render
()
{
let
{
depositMoney
,
qualityDepositMoney
,
depositList
,
depositAmountNeedPay
}
=
this
.
state
;
return
(
<
Layout
title
=
"我的保证金"
border
=
"true"
>
<
div
className
=
{
'deposit-user'
}
>
<
Tips
money
=
{
depositAmountNeedPay
}
/
>
<
div
className
=
"pt10 box-c tal"
>
<
b
className
=
"fz14 box-c"
>
保证金总余额:
<
span
className
=
"blue fz18"
>
{
depositMoney
+
qualityDepositMoney
}
<
/span
>
<
/b
>
<
/div
>
<
div
className
=
{
'deposit-pannel'
}
>
<
div
className
=
{
'deposit-pannel-item bdb1'
}
>
<
div
className
=
"fx1 tal"
>
<
div
className
=
{
'fz17'
}
>
<
div
className
=
{
'fz14'
}
>
类目保证金余额(元)
<
/div
>
<
b
className
=
{
'fz30'
}
>
{
depositMoney
}
<
/b
>
<
/div
>
<
/div
>
<
div
className
=
{
'tar'
}
>
<
span
className
=
{
'button-primary'
}
onClick
=
{()
=>
{
window
.
location
.
href
=
`/new/deposit/Pay?money=
${
depositMoney
}
`
;
}}
>
去缴纳
<
/span
>
<
div
className
=
{
'deposit-user'
}
>
<
Tips
money
=
{
depositAmountNeedPay
}
/
>
<
div
className
=
"pt10 box-c tal"
>
<
b
className
=
"fz14 box-c"
>
保证金总余额:
<
span
className
=
"blue fz18"
>
{
depositMoney
+
qualityDepositMoney
}
<
/span
>
<
/b
>
<
/div
>
<
div
className
=
{
'deposit-pannel'
}
>
<
div
className
=
{
'deposit-pannel-item bdb1'
}
>
<
div
className
=
"fx1 tal"
>
<
div
className
=
{
'fz17'
}
>
<
div
className
=
{
'fz14'
}
>
类目保证金余额(元)
<
/div
>
<
b
className
=
{
'fz30'
}
>
{
depositMoney
}
<
/b
>
<
/div
>
<
/div
>
<
div
className
=
{
'p20'
}
>
<
div
className
=
{
'mb10'
}
>
可展开服务
<
/div
>
<
div
className
=
{
'tagsWrap'
}
>
{
depositList
&&
depositList
.
length
>
0
&&
depositList
.
map
((
item
,
index
)
=>
(
<
span
className
=
{
'tags'
}
key
=
{
index
}
>
{
item
}
<
/span
>
))}
<
/div
>
<
div
className
=
"c9 fz11 pt10"
>*
咨询师须缴纳类目保证金才能开展对应的服务
<
/div
>
<
div
className
=
{
'tar'
}
>
<
span
className
=
{
'button-primary'
}
onClick
=
{()
=>
{
window
.
location
.
href
=
`/new/deposit/Pay?money=
${
depositMoney
}
`
;
}}
>
去缴纳
<
/span
>
<
/div
>
<
/div
>
<
div
className
=
{
'p20'
}
>
<
div
className
=
{
'mb10'
}
>
可展开服务
<
/div
>
<
div
className
=
{
'tagsWrap'
}
>
{
depositList
&&
depositList
.
length
>
0
&&
depositList
.
map
((
item
,
index
)
=>
(
<
span
className
=
{
'tags'
}
key
=
{
index
}
>
{
item
}
<
/span
>
))}
<
/div
>
<
div
className
=
"c9 fz11 pt10"
>*
咨询师须缴纳类目保证金才能开展对应的服务
<
/div
>
<
/div
>
<
/div
>
<
div
className
=
{
'deposit-pannel'
}
>
<
div
className
=
{
'deposit-pannel-item'
}
>
<
div
className
=
"fx1"
>
<
div
className
=
{
'fz17'
}
>
<
div
className
=
{
'fz14'
}
>
质量保证金余额(元)
<
/div
>
<
b
className
=
{
'fz30'
}
>
{
qualityDepositMoney
}
<
/b
>
<
/div
>
<
/div
>
<
div
className
=
{
'tar'
}
>
<
span
className
=
{
'button-primary'
}
onClick
=
{()
=>
{
window
.
location
.
href
=
`/new/deposit/Pay?needPayQuality=
${
depositAmountNeedPay
}
`
;
}}
>
去缴纳
<
/span
>
<
div
className
=
{
'deposit-pannel'
}
>
<
div
className
=
{
'deposit-pannel-item'
}
>
<
div
className
=
"fx1"
>
<
div
className
=
{
'fz17'
}
>
<
div
className
=
{
'fz14'
}
>
质量保证金余额(元)
<
/div
>
<
b
className
=
{
'fz30'
}
>
{
qualityDepositMoney
}
<
/b
>
<
/div
>
<
/div
>
<
div
className
=
{
'p20 pt0'
}
>
<
div
className
=
"c9 fz11 pt10"
>*
当咨询师存在违规行为须缴纳质量保证金
<
/div
>
<
div
className
=
{
'tar'
}
>
<
span
className
=
{
'button-primary'
}
onClick
=
{()
=>
{
window
.
location
.
href
=
`/new/deposit/Pay?needPayQuality=
${
depositAmountNeedPay
}
`
;
}}
>
去缴纳
<
/span
>
<
/div
>
<
/div
>
<
List
className
=
"my-list mt20"
>
{
lists
&&
lists
.
length
>
0
&&
lists
.
map
((
item
,
index
)
=>
{
return
(
<
Item
arrow
=
"horizontal"
onClick
=
{()
=>
{
this
.
goToTarget
(
item
);
}}
key
=
{
index
}
>
{
item
.
name
}
<
/Item
>
);
})}
<
/List
>
<
div
className
=
{
'p20 pt0'
}
>
<
div
className
=
"c9 fz11 pt10"
>*
当咨询师存在违规行为须缴纳质量保证金
<
/div
>
<
/div
>
<
/div
>
<
/Layout
>
<
List
className
=
"my-list mt20"
>
{
lists
&&
lists
.
length
>
0
&&
lists
.
map
((
item
,
index
)
=>
{
return
(
<
Item
arrow
=
"horizontal"
onClick
=
{()
=>
{
this
.
goToTarget
(
item
);
}}
key
=
{
index
}
>
{
item
.
name
}
<
/Item
>
);
})}
<
/List
>
<
/div
>
);
}
}
src/pages/user/Train.js
View file @
fac43759
...
...
@@ -4,7 +4,6 @@ import { List, DatePicker, Toast, Modal } from 'antd-mobile';
import
moment
from
'moment'
;
import
classNames
from
'classnames'
;
import
app
from
'../../static/js/native'
;
import
Layout
from
'../../Components/static/Layout/Layout'
;
import
UpLoad
from
'../../Components/common/Upload/Upload'
;
import
{
getParam
,
getImgNaturalDimensions
}
from
'@/utils/tools'
;
import
{
getParameterByName
}
from
'../../utils/common'
;
...
...
@@ -187,38 +186,36 @@ class Train extends Component {
render
()
{
const
{
startTime
,
endTime
,
backgroundArea
,
certificateFiles
,
viewImages
}
=
this
.
state
;
return
(
<
Layout
title
=
"受训背景"
>
<
div
className
=
"train-warp"
>
<
List
className
=
{
classNames
({
startActive
:
startTime
,
endActive
:
endTime
})}
>
<
DatePicker
mode
=
"month"
minDate
=
{
min
}
maxDate
=
{
now
}
value
=
{
startTime
}
extra
=
"开始时间"
title
=
"开始时间"
format
=
{
this
.
formatShowDate
}
onChange
=
{
date
=>
this
.
changeTime
(
'startTime'
,
date
)}
>
<
List
.
Item
>
<
span
className
=
"c-red"
>*<
/span> <span>开始时间:</
span
>
<
/List.Item
>
<
/DatePicker
>
<
DatePicker
mode
=
"month"
minDate
=
{
min
}
maxDate
=
{
now
}
value
=
{
endTime
}
extra
=
"结束时间"
title
=
"结束时间"
format
=
{
this
.
formatShowDate
}
onChange
=
{
date
=>
this
.
changeTime
(
'endTime'
,
date
)}
>
<
List
.
Item
>
<
span
className
=
"c-red"
>*<
/span> <span>结束时间:</
span
>
<
/List.Item
>
<
/DatePicker
>
<
Item
className
=
""
>
<
span
className
=
"c-red"
>*<
/span> <span>培训名称:</
span
>
<
/Item
>
<
/List
>
<
div
className
=
"box-c"
>
<
div
className
=
"train-name"
>
<
textarea
className
=
"yui-textarea"
name
=
"backgroundArea"
value
=
{
backgroundArea
}
onChange
=
{
this
.
handleInputChange
}
placeholder
=
"建议一次添加一个受训背景"
rows
=
"4"
/>
<
/div
>
<
div
className
=
"fz16 b mt20 mb5"
>
上传证书图片
<
/div
>
<
div
className
=
"c-b3"
>
证书信息真实,照片清晰可辨,信息完整无缺失,严禁经过
ps
处理(最多
1
张)
<
/div
>
<
UpLoad
certificateFiles
=
{
certificateFiles
}
viewImages
=
{
viewImages
}
refresh
=
{
this
.
refreshFile
}
delFile
=
{
this
.
delFile
}
/
>
<
/div
>
<
div
className
=
"bottom-operate"
>
<
button
disabled
=
{
this
.
state
.
isEdit
&&
!
this
.
state
.
hasChange
}
onClick
=
{
this
.
submitTrain
}
className
=
"am-button am-button-primary"
>
提交
<
/button
>
<
div
className
=
"train-warp"
>
<
List
className
=
{
classNames
({
startActive
:
startTime
,
endActive
:
endTime
})}
>
<
DatePicker
mode
=
"month"
minDate
=
{
min
}
maxDate
=
{
now
}
value
=
{
startTime
}
extra
=
"开始时间"
title
=
"开始时间"
format
=
{
this
.
formatShowDate
}
onChange
=
{
date
=>
this
.
changeTime
(
'startTime'
,
date
)}
>
<
List
.
Item
>
<
span
className
=
"c-red"
>*<
/span> <span>开始时间:</
span
>
<
/List.Item
>
<
/DatePicker
>
<
DatePicker
mode
=
"month"
minDate
=
{
min
}
maxDate
=
{
now
}
value
=
{
endTime
}
extra
=
"结束时间"
title
=
"结束时间"
format
=
{
this
.
formatShowDate
}
onChange
=
{
date
=>
this
.
changeTime
(
'endTime'
,
date
)}
>
<
List
.
Item
>
<
span
className
=
"c-red"
>*<
/span> <span>结束时间:</
span
>
<
/List.Item
>
<
/DatePicker
>
<
Item
className
=
""
>
<
span
className
=
"c-red"
>*<
/span> <span>培训名称:</
span
>
<
/Item
>
<
/List
>
<
div
className
=
"box-c"
>
<
div
className
=
"train-name"
>
<
textarea
className
=
"yui-textarea"
name
=
"backgroundArea"
value
=
{
backgroundArea
}
onChange
=
{
this
.
handleInputChange
}
placeholder
=
"建议一次添加一个受训背景"
rows
=
"4"
/>
<
/div
>
<
div
className
=
"fz16 b mt20 mb5"
>
上传证书图片
<
/div
>
<
div
className
=
"c-b3"
>
证书信息真实,照片清晰可辨,信息完整无缺失,严禁经过
ps
处理(最多
1
张)
<
/div
>
<
UpLoad
certificateFiles
=
{
certificateFiles
}
viewImages
=
{
viewImages
}
refresh
=
{
this
.
refreshFile
}
delFile
=
{
this
.
delFile
}
/
>
<
/div
>
<
div
className
=
"bottom-operate"
>
<
button
disabled
=
{
this
.
state
.
isEdit
&&
!
this
.
state
.
hasChange
}
onClick
=
{
this
.
submitTrain
}
className
=
"am-button am-button-primary"
>
提交
<
/button
>
<
/div
>
<
/
Layout
>
<
/
div
>
);
}
}
...
...
src/pages/user/TrainList.js
View file @
fac43759
...
...
@@ -3,7 +3,6 @@ import { Link } from 'react-router-dom';
import
{
Modal
,
Toast
}
from
'antd-mobile'
;
import
{
linkTo
}
from
'@/utils/tools'
;
import
Layout
from
'../../Components/static/Layout/Layout'
;
import
TrainItem
from
'../../Components/page/user/TrainItem'
;
import
app
from
'../../static/js/native'
;
...
...
@@ -65,62 +64,60 @@ class TrainList extends Component {
render
()
{
const
{
trainList
,
delDialogObj
}
=
this
.
state
;
return
(
<
Layout
title
=
"受训背景"
>
<
div
className
=
"train-warp"
>
{
trainList
.
length
?
(
<
div
className
=
"train-list"
>
<
ul
>
{
trainList
.
map
((
train
,
index
)
=>
{
return
<
TrainItem
iType
=
{
3
}
key
=
{
index
}
data
=
{
train
}
delToggle
=
{
this
.
delTrain
}
/>
;
})}
<
/ul
>
<
div
className
=
"train-warp"
>
{
trainList
.
length
?
(
<
div
className
=
"train-list"
>
<
ul
>
{
trainList
.
map
((
train
,
index
)
=>
{
return
<
TrainItem
iType
=
{
3
}
key
=
{
index
}
data
=
{
train
}
delToggle
=
{
this
.
delTrain
}
/>
;
})}
<
/ul
>
<
div
className
=
"bottom-operate"
>
<
a
onClick
=
{()
=>
{
linkTo
(
'/new/user/train/add'
);
}}
className
=
"am-button am-button-primary"
>
添加受训背景
<
/a
>
<
/div
>
<
div
className
=
"bottom-operate"
>
<
a
onClick
=
{()
=>
{
linkTo
(
'/new/user/train/add'
);
}}
className
=
"am-button am-button-primary"
>
添加受训背景
<
/a
>
<
/div
>
<
Modal
footer
=
{[
{
text
:
'点错了'
,
onPress
:
()
=>
{
this
.
onCloseDel
();
}
},
{
text
:
'删除'
,
onPress
:
()
=>
{
this
.
subDel
();
}
<
Modal
footer
=
{[
{
text
:
'点错了'
,
onPress
:
()
=>
{
this
.
onCloseDel
();
}
]}
className
=
"del-train-dialog"
transparent
maskClosable
visible
=
{
delDialogObj
.
isShow
}
title
=
{
delDialogObj
.
title
}
/
>
<
/div
>
)
:
(
<
a
onClick
=
{()
=>
{
linkTo
(
'/new/user/train/add'
);
}}
className
=
"add-train"
>
<
i
className
=
"y-icon-add"
/>
<
span
>
添加受训背景
<
/span
>
<
/a
>
)}
<
/div
>
<
/Layout
>
},
{
text
:
'删除'
,
onPress
:
()
=>
{
this
.
subDel
();
}
}
]}
className
=
"del-train-dialog"
transparent
maskClosable
visible
=
{
delDialogObj
.
isShow
}
title
=
{
delDialogObj
.
title
}
/
>
<
/div
>
)
:
(
<
a
onClick
=
{()
=>
{
linkTo
(
'/new/user/train/add'
);
}}
className
=
"add-train"
>
<
i
className
=
"y-icon-add"
/>
<
span
>
添加受训背景
<
/span
>
<
/a
>
)}
<
/div
>
);
}
}
...
...
src/static/styles/photoswipe.css
deleted
100644 → 0
View file @
9a407488
This diff is collapsed.
Click to expand it.
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