Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
B
biz.qingxiao.com
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
wangxuelai
biz.qingxiao.com
Commits
9082d681
Commit
9082d681
authored
Jan 15, 2020
by
baixian
Browse files
Options
Browse Files
Download
Plain Diff
优化
parents
46e2eb18
fadb1f6e
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
80 additions
and
5 deletions
+80
-5
index.js
src/pages/crm/index.js
+3
-1
index.js
src/pages/crmdetail/index.js
+76
-4
index.js
src/utils/index.js
+1
-0
No files found.
src/pages/crm/index.js
View file @
9082d681
...
...
@@ -425,10 +425,12 @@ class Crm extends React.Component {
title
:
'活动标题'
,
dataIndex
:
'customers'
,
key
:
'customers'
,
width
:
300
,
render
:
(
text
,
record
)
=>
{
return
(
<
div
>
{
record
.
customers
.
activity_title
?
record
.
customers
.
activity_title
:
'-'
}
{
record
.
source_type
!=
10
&&
<
div
>-<
/div>
}
{
record
.
source_type
==
10
&&
record
.
customers
.
map
(
ele
=>
<
div
>
{
ele
.
activity_title
}
<
/div>
)
}
<
/div
>
);
},
...
...
src/pages/crmdetail/index.js
View file @
9082d681
...
...
@@ -19,7 +19,7 @@ import {
import
moment
from
'moment'
;
import
{
routerRedux
}
from
'dva/router'
;
import
pageStyle
from
'./index.less'
;
import
{
pageIn
,
hasBtnPower
,
btnPermission
,
translateType
}
from
'../../utils/index'
;
import
{
pageIn
,
hasBtnPower
,
btnPermission
,
translateType
,
formatDate
}
from
'../../utils/index'
;
import
AddLogModal
from
'./AddLogModal'
;
import
BtnPermission
from
'../../components/BtnPermission'
;
import
RenewEdit
from
'../student/RenewEdit'
;
...
...
@@ -201,6 +201,12 @@ class Crm extends React.Component {
}
=
this
.
props
;
const
{
tabIndex
}
=
this
.
state
;
const
activityColumns
=
[
{
title
:
'活动标题'
,
dataIndex
:
'activity_title'
,
key
:
'activity_title'
,
width
:
400
,
},
{
title
:
'活动类型'
,
dataIndex
:
'activity_type'
,
...
...
@@ -212,14 +218,80 @@ class Crm extends React.Component {
},
},
{
title
:
'活动标题'
,
dataIndex
:
'activity_title'
,
key
:
'activity_title'
,
title
:
'报名时间'
,
dataIndex
:
'create_time'
,
key
:
'create_time'
,
render
:
(
text
,
record
)
=>
{
return
(
<
span
>
{
record
.
created_at
}
<
/span
>
);
},
},
{
title
:
'其他信息'
,
dataIndex
:
'address'
,
key
:
'address'
,
render
(
text
,
record
)
{
const
detail
=
JSON
.
parse
(
record
.
detail
);
console
.
log
(
detail
,
'detail'
);
return
(
<
div
>
{
detail
.
new_form_joiners
&&
<
div
>
<
div
>
姓名:
{
detail
.
new_form_joiners
.
name
}
<
/div
>
<
div
>
购买商品:
{
detail
.
new_form_joiners
.
new_form_order
&&
detail
.
new_form_joiners
.
new_form_order
.
length
>
0
&&
detail
.
new_form_joiners
.
new_form_order
[
0
].
goods_title
}
<
/div
>
{
detail
.
new_form_joiners
.
customize_1
!=
''
&&
<
div
>
customize_1
:
{
detail
.
new_form_joiners
.
customize_1
}
<
/div
>
}
{
detail
.
new_form_joiners
.
customize_2
!=
''
&&
<
div
>
customize_2
:
{
detail
.
new_form_joiners
.
customize_2
}
<
/div
>
}
{
detail
.
new_form_joiners
.
customize_3
!=
''
&&
<
div
>
customize_2
:
{
detail
.
new_form_joiners
.
customize_3
}
<
/div
>
}
<
/div
>
}
{
detail
.
new_group_order
&&
<
div
>
<
div
>
姓名:
{
detail
.
new_group_order
.
name
}
<
/div
>
<
div
>
身份:
{
detail
.
new_group_order
.
is_leader
==
1
?
'团长'
:
'团员'
}
<
/div
>
<
div
>
购买商品:
{
detail
.
new_group_order
.
group_good
&&
detail
.
new_group_order
.
group_good
.
name
}
<
/div
>
{
detail
.
new_group_order
.
other1
!=
''
&&
<
div
>
other1
:
{
detail
.
new_group_order
.
other1
}
<
/div
>
}
{
detail
.
new_group_order
.
other2
!=
''
&&
<
div
>
other2
:
{
detail
.
new_group_order
.
other2
}
<
/div
>
}
{
detail
.
new_group_order
.
other3
!=
''
&&
<
div
>
other3
:
{
detail
.
new_group_order
.
other3
}
<
/div
>
}
<
/div
>
}
<
/div
>
);
},
},
];
const
dynamicColumns
=
[
...
...
src/utils/index.js
View file @
9082d681
...
...
@@ -152,6 +152,7 @@ function isOnline(expiredate) {
return
false
;
}
function
formatDate
(
date
)
{
console
.
log
(
date
,
'date'
);
const
time
=
Number
(
date
);
if
(
time
===
undefined
||
time
===
''
||
time
<=
0
)
{
...
...
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