Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
CRM
Project
Project
Details
Activity
Releases
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
华国豪
CRM
Commits
e7f634de
Commit
e7f634de
authored
Feb 14, 2020
by
华国豪
🙄
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
商机
parent
c564e44d
Show whitespace changes
Inline
Side-by-side
Showing
19 changed files
with
2226 additions
and
146 deletions
+2226
-146
customerManage.css
src/assets/css/customerManage.css
+55
-0
init.css
src/assets/css/init.css
+40
-0
shangji.png
src/assets/img/cust/shangji.png
+0
-0
HomeNavLeft.vue
src/components/HomeNav/HomeNavLeft.vue
+2
-1
Activity.vue
src/components/assembly/Activity.vue
+3
-3
Contacts.vue
src/components/assembly/Contacts.vue
+2
-2
TeamMembers.vue
src/components/assembly/TeamMembers.vue
+183
-10
customerInfoBox.vue
src/components/assembly/customerInfoBox.vue
+3
-2
addBusinTeamman.vue
src/components/businessManagement/addBusinTeamman.vue
+194
-0
addBusinessBox.vue
src/components/businessManagement/addBusinessBox.vue
+424
-0
businessInfoBox.vue
src/components/businessManagement/businessInfoBox.vue
+388
-0
businessManagement.vue
src/components/businessManagement/businessManagement.vue
+555
-0
customerManage.vue
src/components/customerManage/customerManage.vue
+35
-69
addContacts.vue
src/components/dialogModel/addContacts.vue
+1
-26
addTeamman.vue
src/components/dialogModel/addTeamman.vue
+194
-0
customerDialogBox.vue
src/components/dialogModel/customerDialogBox.vue
+11
-33
editTeamPower.vue
src/components/dialogModel/editTeamPower.vue
+127
-0
select.vue
src/components/dialogModel/select.vue
+0
-0
router.js
src/router.js
+9
-0
No files found.
src/assets/css/customerManage.css
View file @
e7f634de
...
@@ -84,3 +84,58 @@
...
@@ -84,3 +84,58 @@
.customerManage
.add-box2
.el-form-item__label
{
.customerManage
.add-box2
.el-form-item__label
{
text-align
:
left
;
text-align
:
left
;
}
}
.customerManage
.selection-box
{
display
:
flex
;
align-items
:
center
;
}
.customerManage
.selection-box
span
{
font-size
:
12px
;
text-align
:
center
;
}
.customerManage
.selection-box
.el-button
{
color
:
#666
;
background-color
:
#f6f8fa
;
border-color
:
#f6f8fa
;
font-size
:
12px
;
height
:
28px
;
border-radius
:
14px
;
padding
:
5px
12px
;
margin-left
:
15px
;
}
.customerManage
.selection-box
.el-button
i
{
margin-right
:
5px
;
}
.customerManage
.selection-box
.el-button
:hover
{
background
:
#2362fb
;
border-color
:
#2362fb
;
color
:
#fff
;
}
.customerManage
.dialog-footer
{
text-align
:
center
;
background-color
:
rgba
(
248
,
250
,
251
,
1
);
padding-bottom
:
20px
;
}
.customerManage
.el-dialog__footer
{
padding
:
0
;
}
.transfer-box
.add-tit
{
display
:
flex
;
justify-content
:
space-between
;
align-items
:
center
;
height
:
20px
;
}
.transfer-box
.add-tit
p
{
display
:
flex
;
align-items
:
center
;
font-weight
:
bold
;
color
:
rgba
(
17
,
17
,
17
,
1
);
font-size
:
14px
;
}
.transfer-box
.add-tit
p
span
{
display
:
inline-block
;
width
:
6px
;
height
:
6px
;
background
:
rgba
(
13
,
36
,
129
,
1
);
border-radius
:
50%
;
margin-right
:
10px
;
}
\ No newline at end of file
src/assets/css/init.css
View file @
e7f634de
...
@@ -28,6 +28,9 @@ table { border-collapse:collapse; border-spacing:0; }
...
@@ -28,6 +28,9 @@ table { border-collapse:collapse; border-spacing:0; }
text-align
:
center
;
text-align
:
center
;
margin-right
:
20px
;
margin-right
:
20px
;
}
}
.crm-btn.crm-btn-mini.el-button
{
padding
:
5px
10px
;
}
.crm-btn-mini.el-button
{
.crm-btn-mini.el-button
{
border-radius
:
0
;
border-radius
:
0
;
padding
:
6px
12px
;
padding
:
6px
12px
;
...
@@ -135,7 +138,16 @@ table { border-collapse:collapse; border-spacing:0; }
...
@@ -135,7 +138,16 @@ table { border-collapse:collapse; border-spacing:0; }
.MyEditForm
.MyEditForm-item
.form-check
.el-form-item__label
{
.MyEditForm
.MyEditForm-item
.form-check
.el-form-item__label
{
display
:
block
;
display
:
block
;
width
:
100%
;
width
:
100%
;
text-align
:
left
;
}
.MyEditForm
.MyEditForm-item
.el-date-editor.el-input
{
width
:
100%
;
}
}
.MyEditForm
.MyEditForm-item
.el-input__prefix
{
right
:
5px
;
top
:
-17px
;
left
:
inherit
;
}
.cp
{
.cp
{
cursor
:
pointer
;
cursor
:
pointer
;
}
}
...
@@ -186,3 +198,31 @@ textarea{
...
@@ -186,3 +198,31 @@ textarea{
.margin-right0
{
.margin-right0
{
margin-right
:
0
!important
;
margin-right
:
0
!important
;
}
}
/* el */
.el-dialog__body
{
background-color
:
rgba
(
248
,
250
,
251
,
1
);
padding-top
:
20px
;
max-height
:
500px
;
overflow
:
auto
;
}
.add-box-btn.el-button
{
border-radius
:
0
;
background-color
:
rgba
(
13
,
36
,
129
,
.8
);
border-color
:
rgba
(
13
,
36
,
129
,
.8
);
color
:
white
;
padding
:
12px
43px
;
}
.add-box-btn.el-button
:hover
{
background-color
:
rgba
(
13
,
36
,
129
,
1
);
border-color
:
rgba
(
13
,
36
,
129
,
1
);
color
:
white
;
}
.add-box-btn.el-button.add-box-cancel
{
color
:
rgba
(
13
,
36
,
129
,
.8
);
background-color
:
white
;
}
.add-box-btn.el-button.add-box-cancel
:hover
{
color
:
rgba
(
13
,
36
,
129
,
1
);
background-color
:
white
;
}
\ No newline at end of file
src/assets/img/cust/shangji.png
0 → 100644
View file @
e7f634de
1.86 KB
src/components/HomeNav/HomeNavLeft.vue
View file @
e7f634de
...
@@ -112,7 +112,8 @@ export default {
...
@@ -112,7 +112,8 @@ export default {
},
},
{
{
class
:
"iconfont iconshangji"
,
class
:
"iconfont iconshangji"
,
name
:
"商机"
name
:
"商机"
,
path
:
'/businessManagement'
},
},
{
{
class
:
"iconfont iconhetong"
,
class
:
"iconfont iconhetong"
,
...
...
src/components/assembly/Activity.vue
View file @
e7f634de
...
@@ -8,7 +8,7 @@
...
@@ -8,7 +8,7 @@
align-items
:
center
;
align-items
:
center
;
}
}
.activity
.btn-list
.btn-list-item
{
.activity
.btn-list
.btn-list-item
{
padding
:
8
px
;
padding
:
5px
10
px
;
font-size
:
12px
;
font-size
:
12px
;
color
:
#666666
;
color
:
#666666
;
background
:
rgba
(
13
,
36
,
129
,
.1
);
background
:
rgba
(
13
,
36
,
129
,
.1
);
...
@@ -69,7 +69,7 @@
...
@@ -69,7 +69,7 @@
padding-right
:
10px
;
padding-right
:
10px
;
}
}
.activity
.genjin-ctrl
.fabu-btn
{
.activity
.genjin-ctrl
.fabu-btn
{
padding
:
6px
23
px
;
padding
:
5px
10
px
;
border
:
1px
solid
rgba
(
13
,
36
,
129
,
1
);
border
:
1px
solid
rgba
(
13
,
36
,
129
,
1
);
color
:
#0D2481
;
color
:
#0D2481
;
font-size
:
12px
;
font-size
:
12px
;
...
@@ -350,7 +350,7 @@
...
@@ -350,7 +350,7 @@
</div>
</div>
</template>
</template>
<
script
>
<
script
>
import
addContacts
from
"./addContacts"
;
import
addContacts
from
".
./dialogModel
/addContacts"
;
export
default
{
export
default
{
components
:
{
components
:
{
addContacts
addContacts
...
...
src/components/assembly/Contacts.vue
View file @
e7f634de
...
@@ -10,7 +10,7 @@
...
@@ -10,7 +10,7 @@
<
template
>
<
template
>
<div
class=
"Contacts"
>
<div
class=
"Contacts"
>
<div
class=
"add-contacts"
>
<div
class=
"add-contacts"
>
<el-button
icon=
"el-icon-plus"
class=
"crm-btn query-btn margin-right0"
@
click=
"addContactsShow=true"
>
新建联系人
</el-button>
<el-button
icon=
"el-icon-plus"
class=
"crm-btn query-btn
crm-btn-mini
margin-right0"
@
click=
"addContactsShow=true"
>
新建联系人
</el-button>
</div>
</div>
<el-table
<el-table
v-loading=
"loading"
v-loading=
"loading"
...
@@ -51,7 +51,7 @@
...
@@ -51,7 +51,7 @@
</div>
</div>
</template>
</template>
<
script
>
<
script
>
import
addContacts
from
"./addContacts"
;
import
addContacts
from
".
./dialogModel
/addContacts"
;
export
default
{
export
default
{
components
:
{
components
:
{
addContacts
addContacts
...
...
src/components/assembly/TeamMembers.vue
View file @
e7f634de
<
style
>
<
style
>
.addTeamman-ctrl
{
text-align
:
right
;
padding
:
10px
0
;
}
</
style
>
</
style
>
<
template
>
<
template
>
<div
class=
"TeamMembers"
>
<div
class=
"addTeamman"
>
TeamMembers
<div
class=
"addTeamman-ctrl"
>
<el-button
icon=
"el-icon-plus"
class=
"crm-btn crm-btn-mini query-btn"
@
click=
"addTeammanShow=true"
>
团队成员
</el-button>
<el-button
class=
"crm-btn query-btn crm-btn-mini easy-btn"
@
click=
"bianji"
>
编辑
</el-button>
<el-button
class=
"crm-btn query-btn crm-btn-mini easy-btn"
@
click=
"yichu"
>
移除
</el-button>
<el-button
class=
"crm-btn query-btn crm-btn-mini org-btn margin-right0"
@
click=
"tuichu"
>
退出团队
</el-button>
</div>
<el-table
v-loading=
"loading"
stripe
ref=
"multipleTable"
:data=
"dataList"
tooltip-effect=
"dark"
style=
"width: 100%"
@
selection-change=
"handleSelectionChange"
row-class-name=
"font-size-12"
>
<el-table-column
:selectable=
'checkboxT'
fixed
type=
"selection"
width=
"40"
></el-table-column>
<el-table-column
prop=
"EmpName"
label=
"销售名称"
show-overflow-tooltip
>
</el-table-column>
<el-table-column
prop=
"PostName"
label=
"岗位"
show-overflow-tooltip
>
</el-table-column>
<el-table-column
prop=
"RoleName"
label=
"角色名称"
show-overflow-tooltip
>
</el-table-column>
<el-table-column
prop=
"RoleType"
label=
"角色属性"
show-overflow-tooltip
>
<template
slot-scope=
"scope"
>
<p
v-if=
"scope.row.RoleType === 1"
>
负责人
</p>
<p
v-else
>
普通员工
</p>
</
template
>
</el-table-column>
<el-table-column
prop=
"JurisdictionName"
label=
"权限"
show-overflow-tooltip
>
</el-table-column>
</el-table>
<div
v-if=
"addTeammanShow"
>
<addTeamman
:ID=
"CustomerId"
@
addTeammanOk=
"addTeammanOk"
/>
</div>
<div
v-if=
"editTeamPowerShow"
>
<editTeamPower
:CustomerId=
"CustomerId"
:ID=
"IDs"
@
addTeammanOk=
"addTeammanOk"
/>
</div>
</div>
</div>
</template>
</template>
<
script
>
<
script
>
import
addTeamman
from
"../dialogModel/addTeamman"
;
import
editTeamPower
from
"../dialogModel/editTeamPower"
;
export
default
{
export
default
{
components
:
{
addTeamman
,
editTeamPower
},
props
:{
props
:{
CustomerId
:
{
type
:
Number
,
default
:
0
}
},
},
data
()
{
data
()
{
return
{
return
{
loading
:
false
,
addTeammanShow
:
false
,
editTeamPowerShow
:
false
,
dataList
:
[],
multipleSelection
:
[],
IDs
:
''
};
};
},
watch
:{
},
watch
:{
CustomerId
:
{
handler
(
val
,
oldVal
){
console
.
log
(
val
)
this
.
GetCustomerTeamList
()
},
deep
:
true
}
},
},
mounted
()
{
mounted
()
{
this
.
GetCustomerTeamList
()
let
$this
=
this
this
.
MsgBus
.
$on
(
'closeaddTeamman'
,
function
(){
$this
.
addTeammanShow
=
false
})
this
.
MsgBus
.
$on
(
'closeeditTeamPower'
,
function
(){
$this
.
editTeamPowerShow
=
false
})
},
},
methods
:
{
methods
:
{
tuichu
(){
this
.
$confirm
(
'确定退出团队?'
,
'提示'
,
{
confirmButtonText
:
'确定'
,
cancelButtonText
:
'取消'
,
type
:
'warning'
}).
then
(()
=>
{
let
str
=
''
this
.
multipleSelection
.
map
((
x
,
i
)
=>
{
str
=
str
+
x
+
','
})
let
msg
=
{
CustomerId
:
this
.
CustomerId
,
IDs
:
str
.
substring
(
0
,
str
.
length
-
1
)
}
this
.
apipost
(
'/api/Customer/ExitCustomerJurisdiction'
,
msg
,
res
=>
{
if
(
res
.
data
.
resultCode
==
1
)
{
this
.
$message
.
success
(
'操作成功'
)
this
.
GetCustomerTeamList
()
}
})
}).
catch
(()
=>
{
this
.
$message
({
type
:
'info'
,
message
:
'已取消'
});
});
},
yichu
(){
if
(
this
.
multipleSelection
.
length
<
1
)
{
return
this
.
$message
.
error
(
'请勾选需要操作的团队成员'
)
}
this
.
$confirm
(
'此操作将移除这些团队成员是否继续?'
,
'提示'
,
{
confirmButtonText
:
'确定'
,
cancelButtonText
:
'取消'
,
type
:
'warning'
}).
then
(()
=>
{
let
str
=
''
this
.
multipleSelection
.
map
((
x
,
i
)
=>
{
str
=
str
+
x
+
','
})
let
msg
=
{
CustomerId
:
this
.
CustomerId
,
IDs
:
str
.
substring
(
0
,
str
.
length
-
1
)
}
this
.
apipost
(
'/api/Customer/RemoveCustomerListJurisdiction'
,
msg
,
res
=>
{
if
(
res
.
data
.
resultCode
==
1
)
{
this
.
$message
.
success
(
'操作成功'
)
this
.
GetCustomerTeamList
()
}
})
}).
catch
(()
=>
{
this
.
$message
({
type
:
'info'
,
message
:
'已取消'
});
});
},
bianji
(){
if
(
this
.
multipleSelection
.
length
<
1
)
{
return
this
.
$message
.
error
(
'请勾选需要操作的团队成员'
)
}
let
str
=
''
this
.
multipleSelection
.
map
((
x
,
i
)
=>
{
str
=
str
+
x
+
','
})
this
.
IDs
=
str
.
substring
(
0
,
str
.
length
-
1
)
this
.
editTeamPowerShow
=
true
},
checkboxT
(
row
,
index
){
if
(
row
.
JurisdictionName
===
'负责人权限'
){
return
0
;
}
else
{
return
1
;
}
},
handleSelectionChange
(
val
)
{
this
.
multipleSelection
=
val
.
map
(
x
=>
x
.
ID
)
},
addTeammanOk
(){
this
.
GetCustomerTeamList
()
},
GetCustomerTeamList
(){
if
(
this
.
CustomerId
===
0
)
return
this
.
loading
=
true
this
.
apipost
(
'/api/Customer/GetCustomerTeamList'
,
{
CustomerId
:
this
.
CustomerId
},
res
=>
{
if
(
res
.
data
.
resultCode
==
1
)
{
this
.
loading
=
false
this
.
dataList
=
res
.
data
.
data
}
})
},
}
}
}
}
</
script
>
</
script
>
\ No newline at end of file
src/components/assembly/customerInfoBox.vue
View file @
e7f634de
...
@@ -70,7 +70,7 @@
...
@@ -70,7 +70,7 @@
<i
class=
"iconfont icongengduo"
></i>
<i
class=
"iconfont icongengduo"
></i>
</el-button>
</el-button>
<el-dropdown-menu
slot=
"dropdown"
>
<el-dropdown-menu
slot=
"dropdown"
>
<el-dropdown-item
command=
"z"
><i
class=
"iconfont iconplus-transfer"
></i>
转移
111
</el-dropdown-item>
<el-dropdown-item
command=
"z"
><i
class=
"iconfont iconplus-transfer"
></i>
转移
</el-dropdown-item>
<el-dropdown-item
command=
"g"
><i
class=
"iconfont icongonghaiguanli"
></i>
放入公海
</el-dropdown-item>
<el-dropdown-item
command=
"g"
><i
class=
"iconfont icongonghaiguanli"
></i>
放入公海
</el-dropdown-item>
<el-dropdown-item
command=
"s"
><i
class=
"iconfont iconsuoguan"
></i>
锁定
</el-dropdown-item>
<el-dropdown-item
command=
"s"
><i
class=
"iconfont iconsuoguan"
></i>
锁定
</el-dropdown-item>
<el-dropdown-item
command=
"j"
><i
class=
"iconfont iconsuokai"
></i>
解锁
</el-dropdown-item>
<el-dropdown-item
command=
"j"
><i
class=
"iconfont iconsuokai"
></i>
解锁
</el-dropdown-item>
...
@@ -110,7 +110,7 @@
...
@@ -110,7 +110,7 @@
<Contacts
:CustomerId=
"CustomerId"
/>
<Contacts
:CustomerId=
"CustomerId"
/>
</el-tab-pane>
</el-tab-pane>
<el-tab-pane
label=
"团队成员"
name=
"4"
>
<el-tab-pane
label=
"团队成员"
name=
"4"
>
<TeamMembers
/>
<TeamMembers
:CustomerId=
"CustomerId"
/>
</el-tab-pane>
</el-tab-pane>
<el-tab-pane
label=
"商机"
name=
"5"
>
<el-tab-pane
label=
"商机"
name=
"5"
>
<Business
/>
<Business
/>
...
@@ -170,6 +170,7 @@ export default {
...
@@ -170,6 +170,7 @@ export default {
CustomerId
:
{
CustomerId
:
{
handler
(
val
,
oldVal
){
handler
(
val
,
oldVal
){
this
.
init
()
this
.
init
()
this
.
activeName
=
'1'
},
},
deep
:
true
deep
:
true
}
}
...
...
src/components/businessManagement/addBusinTeamman.vue
0 → 100644
View file @
e7f634de
<
style
>
.addTeamman
.add-tit
{
display
:
flex
;
justify-content
:
space-between
;
align-items
:
center
;
height
:
20px
;
}
.addTeamman
.add-tit
p
{
display
:
flex
;
align-items
:
center
;
font-weight
:
bold
;
color
:
rgba
(
17
,
17
,
17
,
1
);
font-size
:
14px
;
}
.addTeamman
.add-tit
p
span
{
display
:
inline-block
;
width
:
6px
;
height
:
6px
;
background
:
rgba
(
13
,
36
,
129
,
1
);
border-radius
:
50%
;
margin-right
:
10px
;
}
.addTeamman
.el-dialog__header
{
padding
:
15px
20px
;
background
:
rgba
(
255
,
255
,
255
,
1
);
}
.addTeamman
.dialog-footer
{
text-align
:
center
;
background-color
:
rgba
(
248
,
250
,
251
,
1
);
padding-bottom
:
20px
;
}
.addTeamman
.el-dialog__footer
{
padding
:
0
;
}
.addTeamman
.el-tag.el-tag--info
{
background-color
:
rgba
(
0
,
0
,
0
,
0
);
border-color
:
rgba
(
0
,
0
,
0
,
0
);
display
:
inline-block
;
white-space
:
nowrap
;
overflow
:
hidden
;
text-overflow
:
ellipsis
;
}
</
style
>
<
template
>
<el-dialog
@
closed=
"closedDialog"
:modal=
"false"
:visible
.
sync=
"dialogTableVisible"
width=
"450px"
:close-on-click-modal=
"false"
class=
"addTeamman"
>
<div
class=
"add-tit"
slot=
"title"
>
<p><span></span>
添加团队成员
</p>
<span
icon=
"el-icon-close"
></span>
</div>
<div
class=
"form-box"
>
<el-form
:model=
"form"
ref=
"form"
class=
"MyEditForm"
>
<div
class=
"MyEditForm-item"
>
<el-form-item
label=
"成员"
class=
"label-pad-left"
prop=
"ContactDuty"
>
<el-select
multiple
filterable
v-model=
"EmpIdsS"
placeholder=
"请选择联系人职务"
>
<el-option
v-for=
"item in EmployeeList"
:label=
'item.EmName'
:value=
'item.EmployeeId'
:key=
'item.EmployeeId'
>
</el-option>
</el-select>
</el-form-item>
</div>
<div
class=
"MyEditForm-item"
>
<el-form-item
label=
"权限"
class=
"label-pad-left form-check"
>
<div
class=
"pad-left-10"
>
<el-radio
v-model=
"form.IsRead"
:label=
"0"
>
只读
</el-radio>
<el-radio
v-model=
"form.IsRead"
:label=
"1"
>
读写
</el-radio>
</div>
</el-form-item>
</div>
<div
class=
"MyEditForm-item"
>
<el-form-item
label=
"同时添加至"
class=
"label-pad-left form-check"
>
<div
class=
"pad-left-10"
>
<el-checkbox-group
v-model=
"TransferOther"
>
<el-checkbox
:value=
"2"
:label=
"2"
>
商机
</el-checkbox>
<el-checkbox
:value=
"3"
:label=
"3"
>
合同
</el-checkbox>
</el-checkbox-group>
</div>
</el-form-item>
</div>
</el-form>
</div>
<div
slot=
"footer"
class=
"dialog-footer"
>
<el-button
type=
"primary"
class=
"add-box-btn"
@
click=
"submitForm('form')"
>
确 定
</el-button>
<el-button
class=
"add-box-btn add-box-cancel"
@
click=
"dialogTableVisible = false, resetForm('form')"
>
取 消
</el-button>
</div>
</el-dialog>
</
template
>
<
script
>
export
default
{
props
:
[
'ID'
],
data
()
{
return
{
dialogTableVisible
:
true
,
EmployeeList
:
[],
EmpIdsS
:
[],
TransferOther
:
[],
form
:
{
CustomerIds
:
0
,
EmpIds
:
''
,
IsRead
:
0
,
TransferOther
:
''
}
};
},
watch
:{
},
mounted
()
{
this
.
Employee
()
let
$this
=
this
setTimeout
(()
=>
{
$this
.
dialogTableVisible
=
true
},
50
)
},
methods
:
{
closedDialog
(){
this
.
MsgBus
.
$emit
(
'closeaddTeamman'
)
},
addData
(){
this
.
form
.
CustomerIds
=
this
.
ID
if
(
this
.
EmpIdsS
.
length
<
1
)
{
return
this
.
$message
.
error
(
'请选择成员'
)
}
else
{
let
str
=
''
this
.
EmpIdsS
.
map
((
x
,
i
)
=>
{
str
=
str
+
x
+
','
})
this
.
form
.
EmpIds
=
str
.
substring
(
0
,
str
.
length
-
1
)
}
if
(
this
.
TransferOther
.
length
<
1
)
{
let
str2
=
''
this
.
TransferOther
.
map
((
x
,
i
)
=>
{
str2
=
str2
+
x
+
','
})
this
.
form
.
TransferOther
=
str2
.
substring
(
0
,
str2
.
length
-
1
)
}
this
.
apipost
(
'/api/Customer/AddTeamMembers'
,
this
.
form
,
res
=>
{
if
(
res
.
data
.
resultCode
==
1
)
{
this
.
resetForm
(
"form"
);
this
.
dialogTableVisible
=
false
;
this
.
$emit
(
'addTeammanOk'
)
this
.
$message
.
success
(
res
.
data
.
message
)
}
else
{
this
.
$message
.
error
(
res
.
data
.
message
)
}
})
},
submitForm
(
addMsg
)
{
//提交创建、修改表单
this
.
$refs
[
addMsg
].
validate
(
valid
=>
{
if
(
valid
)
{
this
.
addData
();
}
else
{
return
false
;
}
});
},
Employee
(){
let
userInfo
=
this
.
getLocalStorage
()
let
msg
=
{
RB_Group_id
:
userInfo
.
RB_Group_id
,
BranchId
:
-
1
,
DepartmentId
:
0
,
PostId
:
0
,
IsLeave
:
0
,
}
this
.
apipost2
(
"admin_get_EmployeeGetList"
,
this
.
msg
,
res
=>
{
if
(
res
.
data
.
resultCode
==
1
)
{
this
.
EmployeeList
=
res
.
data
.
data
;
}
else
{
}
},
err
=>
{}
);
},
resetForm
(
formName
)
{
// 重置表单
this
.
form
=
{
CustomerId
:
0
,
EmpIds
:
[],
IsRead
:
0
,
TransferOther
:
[]
}
this
.
$refs
[
formName
].
resetFields
();
},
}
}
</
script
>
\ No newline at end of file
src/components/businessManagement/addBusinessBox.vue
0 → 100644
View file @
e7f634de
<
style
>
.customerDialogBox.add-box
.add-tit
{
display
:
flex
;
justify-content
:
space-between
;
align-items
:
center
;
height
:
20px
;
}
.customerDialogBox.add-box
.add-tit
p
{
display
:
flex
;
align-items
:
center
;
font-weight
:
bold
;
color
:
rgba
(
17
,
17
,
17
,
1
);
font-size
:
14px
;
}
.customerDialogBox.add-box
.add-tit
p
span
{
display
:
inline-block
;
width
:
6px
;
height
:
6px
;
background
:
rgba
(
13
,
36
,
129
,
1
);
border-radius
:
50%
;
margin-right
:
10px
;
}
.customerDialogBox.add-box
.el-dialog__header
{
padding
:
15px
20px
;
background
:
rgba
(
255
,
255
,
255
,
1
);
}
.customerDialogBox.add-box
.dialog-footer
{
text-align
:
center
;
background-color
:
rgba
(
248
,
250
,
251
,
1
);
padding-bottom
:
20px
;
}
.customerDialogBox.add-box
.el-dialog__footer
{
padding
:
0
;
}
.customerDialogBox.add-box
.el-dialog__body
{
background-color
:
rgba
(
248
,
250
,
251
,
1
);
padding-top
:
20px
;
max-height
:
500px
;
overflow
:
auto
;
}
.customerDialogBox
.add-box-btn.el-button
{
border-radius
:
0
;
background-color
:
rgba
(
13
,
36
,
129
,
.8
);
border-color
:
rgba
(
13
,
36
,
129
,
.8
);
color
:
white
;
padding
:
12px
43px
;
}
.customerDialogBox
.add-box-btn.el-button
:hover
{
background-color
:
rgba
(
13
,
36
,
129
,
1
);
border-color
:
rgba
(
13
,
36
,
129
,
1
);
color
:
white
;
}
.customerDialogBox
.add-box-btn.el-button.add-box-cancel
{
color
:
rgba
(
13
,
36
,
129
,
.8
);
background-color
:
white
;
}
.customerDialogBox
.add-box-btn.el-button.add-box-cancel
:hover
{
color
:
rgba
(
13
,
36
,
129
,
1
);
background-color
:
white
;
}
.customerDialogBox
.el-input
.el-input-group__append
{
background-color
:
rgba
(
13
,
36
,
129
,
1
);
border-color
:
rgba
(
13
,
36
,
129
,
1
);
color
:
#fff
;
}
.customerDialogBox
.form-box
.form-box-tit
{
display
:
flex
;
align-items
:
center
;
margin-bottom
:
20px
;
}
.customerDialogBox
.form-box
.radius
{
display
:
flex
;
width
:
4px
;
height
:
4px
;
background
:
rgba
(
255
,
164
,
117
,
1
);
border-radius
:
50%
;
margin-right
:
10px
;
}
.customerDialogBox
.up-img-box
.uib-item
{
margin-right
:
30px
;
width
:
120px
;
height
:
120px
;
background-color
:
white
;
position
:
relative
;
margin-bottom
:
30px
;
}
.customerDialogBox
.up-img-box
.uib-item
p
{
position
:
absolute
;
bottom
:
-30px
;
font-size
:
12px
;
text-align
:
center
;
width
:
100%
;
}
.customerDialogBox
.up-img-box
.uib-item
:hover
.imgzhe-btn
{
opacity
:
1
}
.customerDialogBox
.imgzhe
{
width
:
100%
;
height
:
100%
;
position
:
absolute
;
top
:
0
;
}
.customerDialogBox
.imgzhe
.imgzhe-btn
{
background
:
rgba
(
0
,
0
,
0
,
0.6
);
width
:
100%
;
height
:
100%
;
text-align
:
center
;
line-height
:
120px
;
position
:
absolute
;
top
:
0
;
opacity
:
1
;
transition
:
all
linear
.5s
}
.customerDialogBox
.imgzhe
.imgzhe-btn
i
{
font-size
:
22px
;
margin-right
:
5px
;
color
:
white
;
cursor
:
pointer
;
}
.customerDialogBox
.up-ctrl
{
position
:
absolute
;
left
:
0
;
top
:
0
;
width
:
100%
;
height
:
100%
;
}
.customerDialogBox
.up-ctrl
>
div
{
width
:
100%
;
height
:
100%
;
text-align
:
center
;
line-height
:
140px
;
}
</
style
>
<
template
>
<el-dialog
:visible
.
sync=
"dialogTableVisible"
@
closed=
"closedDialog"
:close-on-click-modal=
"false"
class=
"add-box add-box1 customerDialogBox"
>
<div
class=
"add-tit"
slot=
"title"
>
<p><span></span>
{{
name
}}
</p>
<span
icon=
"el-icon-close"
></span>
</div>
<div
class=
"form-box"
v-if=
"show"
>
<el-form
:model=
"form"
ref=
"form"
class=
"MyEditForm"
:rules=
"rules"
>
<p
class=
"form-box-tit"
><span
class=
"radius"
></span>
基本信息
</p>
<el-row
:gutter=
"30"
>
<el-col
:span=
"8"
>
<div
class=
"MyEditForm-item"
>
<el-form-item
label=
"商机名称"
prop=
"BusinessName"
>
<el-input
placeholder=
"请输入商机名称"
v-model=
"form.BusinessName"
></el-input>
</el-form-item>
</div>
</el-col>
<el-col
:span=
"8"
>
<div
class=
"MyEditForm-item"
>
<el-form-item
label=
"客户"
prop=
"CustomerId"
>
<el-select
v-model=
"form.CustomerId"
filterable
placeholder=
"请选择客户"
>
<el-option
v-for=
"item in CustomerList"
:key=
"item.CustomerId"
:label=
"item.CustomerName"
:value=
"item.CustomerId"
>
</el-option>
</el-select>
</el-form-item>
</div>
</el-col>
<el-col
:span=
"8"
>
<div
class=
"MyEditForm-item"
>
<el-form-item
label=
"预计人数"
prop=
"PeopleNumber"
>
<el-input
placeholder=
"请输入预计人数"
onkeyup=
"this.value=this.value.replace(/[^\d.]/g,'');"
v-model=
"form.PeopleNumber"
></el-input>
</el-form-item>
</div>
</el-col>
</el-row>
<el-row
:gutter=
"30"
>
<el-col
:span=
"8"
>
<div
class=
"MyEditForm-item"
>
<el-form-item
label=
"预算价格"
prop=
"BudgetPrice"
>
<el-input
placeholder=
"请输入预算价格"
onkeyup=
"this.value=this.value.replace(/[^\d.]/g,'');"
v-model=
"form.BudgetPrice"
></el-input>
</el-form-item>
</div>
</el-col>
<el-col
:span=
"8"
>
<div
class=
"MyEditForm-item"
>
<el-form-item
label=
"线路"
prop=
"LineId"
>
<el-select
v-model=
"form.LineId"
filterable
@
change=
"getLineTeamList(form.LineId)"
placeholder=
"请选择线路"
>
<el-option
v-for=
"item in LineList"
:label=
'item.LineName'
:value=
'item.LineID'
:key=
'item.LineID'
>
</el-option>
</el-select>
</el-form-item>
</div>
</el-col>
<el-col
:span=
"8"
>
<div
class=
"MyEditForm-item"
>
<el-form-item
label=
"系列"
prop=
"LineteamId"
>
<el-select
v-model=
"form.LineteamId"
filterable
placeholder=
"请选择系列"
>
<el-option
v-for=
"item in LineTeamList"
:label=
'item.LtName'
:value=
'item.LtID'
:key=
'item.LtID'
>
</el-option>
</el-select>
</el-form-item>
</div>
</el-col>
</el-row>
<el-row
:gutter=
"30"
>
<el-col
:span=
"8"
>
<div
class=
"MyEditForm-item MyEditForm-item-time"
>
<el-form-item
label=
"出发时间"
prop=
"DepartTime"
>
<el-date-picker
value-format=
"yyyy-MM-dd HH:mm:ss"
v-model=
"form.DepartTime"
:clearable=
"false"
type=
"datetime"
placeholder=
"选择出发时间"
>
</el-date-picker>
</el-form-item>
</div>
</el-col>
<el-col
:span=
"8"
>
<div
class=
"MyEditForm-item MyEditForm-item-time"
>
<el-form-item
label=
"商机状态"
prop=
"BusinessStatus"
>
<el-select
v-model=
"form.BusinessStatus"
placeholder=
"请选择商机状态"
>
<el-option
v-for=
"item in BusinessStatusEnum"
:label=
'item.Name'
:value=
'item.ID'
:key=
'item.ID'
>
</el-option>
</el-select>
</el-form-item>
</div>
</el-col>
</el-row>
<el-row>
<el-col
:span=
"24"
>
<div
class=
"MyEditForm-item label-pad-left"
>
<el-form-item
label=
"备注"
>
<el-input
type=
"textarea"
placeholder=
"商机备注"
v-model=
"form.Remark"
></el-input>
</el-form-item>
</div>
</el-col>
</el-row>
</el-form>
</div>
<div
slot=
"footer"
class=
"dialog-footer"
>
<el-button
type=
"primary"
class=
"add-box-btn"
@
click=
"submitForm('form')"
>
确 定
</el-button>
<el-button
class=
"add-box-btn add-box-cancel"
@
click=
"dialogTableVisible = false, resetForm('form')"
>
取 消
</el-button>
</div>
</el-dialog>
</
template
>
<
script
>
export
default
{
props
:{
ID
:
{
type
:
Number
,
default
:
0
},
name
:
{
type
:
String
,
default
:
'新建商机'
}
},
data
()
{
return
{
CustomerList
:
[],
LineList
:
[],
LineTeamList
:
[],
dialogTableVisible
:
false
,
form
:
{
ID
:
0
,
CustomerId
:
''
,
BudgetPrice
:
''
,
LineId
:
''
,
BusinessName
:
''
,
BusinessStatus
:
''
,
LineteamId
:
''
,
DepartTime
:
''
,
PeopleNumber
:
1
,
Remark
:
''
,
},
BusinessStatusEnum
:
[],
rules
:{
CustomerId
:
[
{
required
:
true
,
message
:
'请选择客户'
,
trigger
:
'change'
}
],
BusinessName
:
[
{
required
:
true
,
message
:
'请输入商机名称'
,
trigger
:
'blur'
}
],
BudgetPrice
:
[
{
required
:
true
,
message
:
'请输入预算价格'
,
trigger
:
'blur'
}
],
BusinessStatus
:
[
{
required
:
true
,
message
:
'请选择商机状态'
,
trigger
:
'change'
}
],
LineId
:
[
{
required
:
true
,
message
:
'请选择线路'
,
trigger
:
'change'
}
],
LineteamId
:
[
{
required
:
true
,
message
:
'请选择系列'
,
trigger
:
'change'
}
],
DepartTime
:
[
{
required
:
true
,
message
:
'请选择时间'
,
trigger
:
'change'
}
],
PeopleNumber
:
[
{
required
:
true
,
message
:
'请输入预计人数'
,
trigger
:
'blur'
}
],
Remark
:
[
{
required
:
true
,
message
:
'请输入备注'
,
trigger
:
'blur'
}
],
},
show
:
true
,
};
},
watch
:{
ID
:
{
handler
(
val
,
oldVal
){
console
.
log
(
val
)
},
deep
:
true
}
},
mounted
()
{
this
.
getCustomerList
()
this
.
getLineList
()
this
.
GetBusinessStatusEnum
()
let
$this
=
this
setTimeout
(()
=>
{
$this
.
dialogTableVisible
=
true
},
50
)
if
(
this
.
ID
!==
0
)
{
this
.
apipost
(
'/api/Customer/GetAllBusinessModel'
,
{
BusinessId
:
this
.
ID
},
res
=>
{
if
(
res
.
data
.
resultCode
==
1
)
{
let
data
=
res
.
data
.
data
if
(
data
.
LineId
)
{
this
.
getLineTeamList
(
data
.
LineId
,
1
)
}
this
.
form
=
data
}
})
}
},
methods
:
{
//获取系列列表
getLineTeamList
(
lineId
,
type
)
{
if
(
!
type
)
{
this
.
form
.
LineteamId
=
''
}
this
.
apipost2
(
"team_post_GetList"
,
{
lineID
:
lineId
,
isTOOP
:
1
},
res
=>
{
if
(
res
.
data
.
resultCode
==
1
)
{
this
.
LineTeamList
=
res
.
data
.
data
;
}
});
},
getLineList
()
{
this
.
apipost2
(
"line_post_GetAllList_V2"
,
{
LineDirection
:
0
},
res
=>
{
if
(
res
.
data
.
resultCode
==
1
)
{
this
.
LineList
=
res
.
data
.
data
;
}
});
},
GetBusinessStatusEnum
(){
this
.
apipost
(
'/api/Customer/GetBusinessStatusEnum'
,
{},
res
=>
{
if
(
res
.
data
.
resultCode
==
1
)
{
this
.
BusinessStatusEnum
=
res
.
data
.
data
}
})
},
getCustomerList
(){
this
.
apipost
(
'/api/Customer/GetCustomerListByCreateInfo'
,
{},
res
=>
{
if
(
res
.
data
.
resultCode
==
1
)
{
this
.
CustomerList
=
res
.
data
.
data
}
})
},
closedDialog
(){
this
.
MsgBus
.
$emit
(
'closeBusinessDialogBox'
)
},
addData
(){
this
.
apipost
(
'/api/Customer/CreateCustomerBusiness'
,
this
.
form
,
res
=>
{
if
(
res
.
data
.
resultCode
==
1
)
{
this
.
dialogTableVisible
=
false
;
// 有id 发送更新抽屉消息
if
(
this
.
CustomerId
!==
0
)
{
this
.
$message
.
success
(
'修改商机成功'
);
this
.
MsgBus
.
$emit
(
'RefreshInfoBox'
)
}
else
{
this
.
$message
.
success
(
'新建商机成功'
);
}
this
.
$emit
(
'getList'
)
this
.
resetForm
(
"form"
);
}
else
{
this
.
$message
.
error
(
res
.
data
.
message
);
}
})
},
submitForm
(
addMsg
)
{
//提交创建、修改表单
this
.
$refs
[
addMsg
].
validate
(
valid
=>
{
if
(
valid
)
{
this
.
addData
();
}
else
{
return
false
;
}
});
},
resetForm
(
formName
)
{
// 重置表单
this
.
form
=
{
ID
:
0
,
CustomerId
:
0
,
BudgetPrice
:
''
,
LineId
:
''
,
BusinessName
:
''
,
BusinessStatus
:
''
,
LineteamId
:
''
,
DepartTime
:
''
,
PeopleNumber
:
0
,
Remark
:
''
,
}
this
.
$refs
[
formName
].
resetFields
();
},
}
}
</
script
>
\ No newline at end of file
src/components/businessManagement/businessInfoBox.vue
0 → 100644
View file @
e7f634de
<
style
>
.businessInfoBox.drawer-box
{
height
:
100%
;
}
.businessInfoBox
.drawer-header
{
height
:
83px
;
display
:
flex
;
align-items
:
center
;
justify-content
:
space-between
;
padding
:
0
30px
;
}
.businessInfoBox
.drawer-header
.left
{
display
:
flex
;
align-items
:
center
;
}
.businessInfoBox
.drawer-header
.left
img
{
display
:
inline-block
;
margin-right
:
10px
;
width
:
26px
;
height
:
26px
;
}
.businessInfoBox
.drawer-body
{
height
:
calc
(
100%
-
83px
);
}
.businessInfoBox
.drawer-body
.top-info
{
height
:
115px
;
padding
:
30px
;
box-sizing
:
border-box
;
font-size
:
12px
;
background-color
:
#F6F4FC
;
}
.businessInfoBox
.drawer-body
.top-info
.info-lable
{
display
:
inline-block
;
width
:
100px
;
color
:
#999999
;
}
.businessInfoBox
.margin-bottom-25
{
margin-bottom
:
25px
;
}
.businessInfoBox
.drawer-box
.el-tabs__nav-wrap
::after
{
height
:
0
;
}
.businessInfoBox
.drawer-body
.el-tabs__header
{
padding
:
0
25px
;
margin-bottom
:
0
;
}
.businessInfoBox
.drawer-body
.content
{
height
:
calc
(
100%
-
115px
);
}
.businessInfoBox
.drawer-body
.el-tabs
{
height
:
100%
;
}
.businessInfoBox
.drawer-body
.el-tabs__content
{
background-color
:
#F6F4FC
;
padding
:
0
20px
20px
20px
;
height
:
calc
(
100%
-
40px
);
box-sizing
:
border-box
;
}
.state-box
{
padding
:
15px
;
border-top
:
1px
solid
#e6e6e6
;
border-bottom
:
1px
solid
#e6e6e6
;
background-color
:
#fff
;
}
.busi-state
{
position
:
relative
;
padding-left
:
20px
;
overflow-x
:
auto
;
overflow-y
:
hidden
;
z-index
:
1
;
display
:
flex
;
align-items
:
center
;
}
.busi-state-item
{
padding
:
0
30px
;
height
:
38px
;
position
:
relative
;
margin
:
5px
5px
5px
0
;
border-top
:
2px
solid
#ebebeb
;
border-bottom
:
2px
solid
#ebebeb
;
line-height
:
36px
;
}
.state-suc
.circle-left
,
.state-suc
.circle-right
{
border-color
:
#00ca9d
!important
;
background-color
:
#00ca9d
!important
;
}
.busi-state-item
.state-circle
{
width
:
37px
;
height
:
38px
;
border-radius
:
19px
;
background-color
:
#fff
;
-webkit-transform
:
rotate
(
45deg
);
transform
:
rotate
(
45deg
);
position
:
absolute
;
z-index
:
-1
;
top
:
-1px
}
.circle-left
{
border-left
:
2px
solid
#ebebeb
;
border-bottom
:
2px
solid
#ebebeb
;
top
:
-2px
;
left
:
-17px
;
}
.state-suc
{
border-top
:
1px
solid
#00ca9d
;
border-bottom
:
1px
solid
#00ca9d
;
background-color
:
#00ca9d
;
color
:
#fff
;
}
.state-suc
.arrow-right
{
border-color
:
#00ca9d
!important
;
background-color
:
#00ca9d
!important
;
}
.busi-state-item
{
cursor
:
pointer
;
}
.busi-state-item
.state-arrow
{
width
:
38px
;
height
:
38px
;
-webkit-transform
:
scale
(
.707
)
rotate
(
45deg
);
transform
:
scale
(
.707
)
rotate
(
45deg
);
border-top
:
2px
solid
#ebebeb
;
border-right
:
2px
solid
#ebebeb
;
background-color
:
#fff
;
position
:
absolute
;
}
.state-doing
{
border-top
:
2px
solid
#00ca9d
;
border-bottom
:
2px
solid
#00ca9d
;
background-color
:
#fff
;
color
:
#00ca9d
;
}
.arrow-right
{
z-index
:
1
;
top
:
-1px
;
right
:
-20px
;
}
.state-doing
.arrow-left
,
.state-doing
.arrow-right
,
.state-doing
.circle-left
,
.state-doing
.circle-right
{
border-color
:
#00ca9d
!important
;
background-color
:
#fff
!important
;
}
.arrow-left
{
top
:
-1px
;
left
:
-18px
;
}
.state-undo
{
border-top
:
2px
solid
#ebebeb
;
border-bottom
:
2px
solid
#ebebeb
;
background-color
:
#fff
;
color
:
#666
;
}
.circle-right
{
border-top
:
2px
solid
#ebebeb
;
border-right
:
2px
solid
#ebebeb
;
z-index
:
1
;
top
:
-1px
;
right
:
-17.5px
;
}
.busi-state-item
.el-icon-arrow-down
{
padding-right
:
10px
;
}
.state-handel-cont
>
div
{
display
:
flex
;
align-items
:
center
;
justify-content
:
space-between
;
padding
:
10px
0
;
cursor
:
pointer
;
}
.state-handel-cont
>
div
:hover
{
background-color
:
#f7f8fa
;
}
</
style
>
<
template
>
<div
class=
"businessInfoBox drawer-box"
v-if=
"loading"
>
<div
class=
"drawer-header"
>
<div
class=
"left"
>
<img
src=
"../../assets/img/cust/shangji.png"
alt=
""
>
<p>
{{
detailsData
.
BusinessName
}}
</p>
</div>
<div
class=
"right"
>
<el-button
class=
"crm-btn query-btn"
@
click=
"editCustbusiness"
>
编辑
</el-button>
<el-button
class=
"crm-btn easy-btn iconfont iconplus-transfer "
>
转移
</el-button>
<el-dropdown
@
command=
"handleCommand"
style=
"top: 1px;"
>
<el-button
class=
"crm-btn crm-btn-more easy-btn margin-right0"
>
<i
class=
"iconfont icongengduo"
></i>
</el-button>
<el-dropdown-menu
slot=
"dropdown"
>
<el-dropdown-item
command=
"d"
><i
class=
"iconfont icondelete"
></i>
删除
</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
</div>
</div>
<div
class=
"drawer-body"
>
<div
class=
"top-info"
>
<el-row
class=
"margin-bottom-25"
>
<el-col
:span=
"12"
>
<span
class=
"info-lable"
>
所属客户:
</span><span
>
{{
detailsData
.
CustomerName
}}
</span>
</el-col>
<el-col
:span=
"12"
>
<span
class=
"info-lable"
>
商机金额(元):
</span><span
>
{{
detailsData
.
BudgetPrice
}}
</span>
</el-col>
</el-row>
<el-row>
<el-col
:span=
"12"
>
<span
class=
"info-lable"
>
负责人:
</span><span>
{{
detailsData
.
PersonChargeStr
}}
</span>
</el-col>
<el-col
:span=
"12"
>
<span
class=
"info-lable"
>
创建时间:
</span><span>
{{
detailsData
.
CreateTime
}}
</span>
</el-col>
</el-row>
</div>
<div
class=
"content"
>
<div
class=
"state-box"
>
<div
class=
"busi-state"
>
<el-popover
placement=
"bottom"
width=
"150"
title=
"验证客户"
trigger=
"hover"
>
<p>
很好
</p>
<div
slot=
"reference"
class=
"busi-state-item state-suc"
>
验证客户
<div
class=
"state-circle circle-left"
></div>
<div
class=
"state-arrow arrow-right"
></div>
</div>
</el-popover>
<el-popover
placement=
"bottom"
width=
"150"
title=
"需求分析"
trigger=
"hover"
>
<p>
很好11
</p>
<div
slot=
"reference"
class=
"busi-state-item state-doing"
>
需求分析
<div
class=
"state-arrow arrow-left"
></div>
<div
class=
"state-arrow arrow-right"
></div>
</div>
</el-popover>
<el-popover
placement=
"bottom"
width=
"150"
title=
"方案/报价"
trigger=
"hover"
>
<p>
很好1122
</p>
<div
slot=
"reference"
class=
"busi-state-item state-undo"
>
方案/报价
<div
class=
"state-arrow arrow-left"
></div>
<div
class=
"state-arrow arrow-right"
></div>
</div>
</el-popover>
<el-popover
placement=
"bottom"
width=
"150"
trigger=
"hover"
>
<div
class=
"state-handel-cont"
>
<div
@
click=
"setBusinessState(1)"
>
<div>
赢单
</div>
<div>
100%
</div>
</div>
<div
@
click=
"setBusinessState(2)"
>
<div>
无效
</div>
<div>
0%
</div>
</div>
<div
@
click=
"setBusinessState(3)"
>
<div>
输单
</div>
<div>
0%
</div>
</div>
</div>
<div
slot=
"reference"
class=
"busi-state-item state-undo"
>
<i
class=
"el-icon-arrow-down"
></i>
结束
<div
class=
"state-arrow arrow-left"
></div>
<div
class=
"state-circle circle-right"
></div>
</div>
</el-popover>
</div>
</div>
<el-tabs
v-model=
"activeName"
>
<el-tab-pane
label=
"活动"
name=
"1"
>
<Activity
:BusinessId=
"BusinessId"
/>
</el-tab-pane>
<el-tab-pane
label=
"详细资料"
name=
"2"
>
<Details
:detailsData=
"detailsData"
/>
</el-tab-pane>
<el-tab-pane
label=
"联系人"
name=
"3"
>
<Contacts
:BusinessId=
"BusinessId"
/>
</el-tab-pane>
<el-tab-pane
label=
"团队成员"
name=
"4"
>
<TeamMembers/>
</el-tab-pane>
<el-tab-pane
label=
"商机"
name=
"5"
>
<Business
/>
</el-tab-pane>
<el-tab-pane
label=
"合同"
name=
"6"
>
<Agreement
/>
</el-tab-pane>
<el-tab-pane
label=
"回款"
name=
"7"
>
<MoneyBack
/>
</el-tab-pane>
<el-tab-pane
label=
"附件"
name=
"8"
>
<Enclosure
/>
</el-tab-pane>
<el-tab-pane
label=
"操作记录"
name=
"9"
>
<Record
/>
</el-tab-pane>
</el-tabs>
</div>
</div>
</div>
</
template
>
<
script
>
import
Activity
from
"../assembly/Activity"
;
import
Details
from
"../assembly/Details"
;
import
Contacts
from
"../assembly/Contacts"
;
import
TeamMembers
from
"../assembly/TeamMembers"
;
import
Business
from
"../assembly/Business"
;
import
Agreement
from
"../assembly/Agreement"
;
import
MoneyBack
from
"../assembly/MoneyBack"
;
import
Enclosure
from
"../assembly/Enclosure"
;
import
Record
from
"../assembly/Record"
;
export
default
{
components
:
{
Activity
,
Details
,
Contacts
,
TeamMembers
,
Business
,
Agreement
,
MoneyBack
,
Enclosure
,
Record
},
props
:{
BusinessId
:
{
type
:
Number
,
default
:
0
}
},
data
()
{
return
{
detailsData
:
{},
loading
:
true
,
activeName
:
'1'
,
};
},
watch
:{
BusinessId
:
{
handler
(
val
,
oldVal
){
this
.
init
()
this
.
activeName
=
'1'
},
deep
:
true
}
},
mounted
()
{
let
$this
=
this
$this
.
init
()
// 监听修改更新界面
this
.
MsgBus
.
$on
(
'RefreshInfoBox'
,
function
()
{
$this
.
init
()
})
},
methods
:
{
setBusinessState
(){
},
init
(){
this
.
apipost
(
'/api/Customer/GetAllBusinessModel'
,
{
BusinessId
:
this
.
BusinessId
},
res
=>
{
if
(
res
.
data
.
resultCode
==
1
)
{
this
.
detailsData
=
res
.
data
.
data
}
})
},
handleCommand
(
command
){
if
(
command
===
'z'
)
{
this
.
$emit
(
'transferS'
,
3
);
}
else
if
(
command
===
'g'
)
{
this
.
$emit
(
'watersS'
,
1
)
}
},
handleClick
(
tab
,
event
)
{},
editCustbusiness
(){
this
.
$emit
(
'editCustbusiness'
,
1
)
},
handleClose
(
done
)
{
done
();
}
}
}
</
script
>
\ No newline at end of file
src/components/businessManagement/businessManagement.vue
0 → 100644
View file @
e7f634de
<
style
>
@import
'../../assets/css/customerManage.css'
;
</
style
>
<
template
>
<div
class=
"customerManage"
>
<div
class=
"tools"
>
<h1>
商机管理
</h1>
<div>
<el-input
placeholder=
"请输入商机名"
v-model=
"msg.BusinessName"
class=
"input-with-select"
>
<el-button
slot=
"append"
icon=
"el-icon-search"
@
click=
"getList"
></el-button>
</el-input>
</div>
<div
class=
"rightmenu"
>
<el-button
icon=
"el-icon-plus"
class=
"crm-btn org-btn"
@
click=
"BusinessId = 0, dialogBusinessVisibleName = '新建商机', dialogBusinessVisible=true"
>
新建商机
</el-button>
<el-dropdown>
<el-button
class=
"crm-btn crm-btn-more easy-btn margin-right0"
>
<i
class=
"iconfont icongengduo"
></i>
</el-button>
<el-dropdown-menu
slot=
"dropdown"
>
<el-dropdown-item><i
class=
"iconfont icondaochu"
></i>
导出
</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
</div>
</div>
<div
class=
"query-box"
>
<div
v-if=
"!multipleSelection.length"
>
<div>
<span
class=
"font-size-12"
style=
"padding-right: 10px"
>
场景
</span>
<el-select
size=
"mini"
v-model=
"msg.WhereType"
placeholder=
"请选择"
>
<el-option
v-for=
"item in WhereTypeList"
:key=
"item.id"
:label=
"item.name"
:value=
"item.id"
>
</el-option>
</el-select>
</div>
</div>
<div
v-else
class=
"flex-center"
>
<p
class=
"font-size-12"
>
已选
<span
class=
"font-color-link"
>
{{
multipleSelection
.
length
}}
</span>
项
</p>
<div
class=
"selection-box"
>
<el-button
v-for=
"(item, index) in selectionList"
:key=
"index"
@
click=
"item.myFun"
><i
:class=
"item.class"
></i>
{{
item
.
name
}}
</el-button>
</div>
</div>
</div>
<div
class=
"page-content"
>
<el-table
v-if=
"loading"
v-loading=
"true"
:data=
"[]"
>
<el-table-column
v-for=
"(item, index) in queryType2"
:key=
"index"
:label=
"item.label"
>
</el-table-column>
</el-table>
<el-table
v-if=
"!loading"
ref=
"multipleTable"
:data=
"tableData"
tooltip-effect=
"dark"
style=
"width: 100%"
height=
"730"
border
row-class-name=
"font-size-12"
@
selection-change=
"handleSelectionChange"
>
<el-table-column
fixed
type=
"selection"
width=
"40"
></el-table-column>
<el-table-column
fixed
prop=
"BusinessName"
label=
"商机名称"
width=
"120"
show-overflow-tooltip
>
<template
slot-scope=
"scope"
>
<p
@
click=
"openDetails2(scope)"
class=
"font-color-link cp"
>
{{
scope
.
row
.
BusinessName
}}
</p>
</
template
>
</el-table-column>
<el-table-column
prop=
"CustomerName"
label=
"客户名称"
v-if=
"queryType[1].show"
show-overflow-tooltip
>
<
template
slot-scope=
"scope"
>
<p
@
click=
"openDetails(scope)"
class=
"font-color-link cp"
>
{{
scope
.
row
.
CustomerName
}}
</p>
</
template
>
</el-table-column>
<el-table-column
prop=
"BudgetPrice"
label=
"预算价格"
sortable
v-if=
"queryType[2].show"
show-overflow-tooltip
>
</el-table-column>
<el-table-column
prop=
"PeopleNumber"
label=
"预计人数"
sortable
v-if=
"queryType[3].show"
show-overflow-tooltip
>
</el-table-column>
<el-table-column
prop=
"BusinessStatusStr"
label=
"商机状态"
v-if=
"queryType[5].show"
show-overflow-tooltip
>
</el-table-column>
<el-table-column
prop=
"DepartTimestr"
label=
"预计出发时间"
sortable
v-if=
"queryType[6].show"
show-overflow-tooltip
>
</el-table-column>
<el-table-column
prop=
"Remark"
label=
"备注"
v-if=
"queryType[4].show"
show-overflow-tooltip
>
</el-table-column>
<el-table-column
prop=
"PersonChargeStr"
label=
"负责人"
sortable
v-if=
"queryType[7].show"
show-overflow-tooltip
>
</el-table-column>
<el-table-column
prop=
"UpdateTimestr"
label=
"更新时间"
sortable
v-if=
"queryType[7].show"
show-overflow-tooltip
>
</el-table-column>
<el-table-column
prop=
"CreateByStr"
label=
"创建人"
v-if=
"queryType[9].show"
show-overflow-tooltip
>
</el-table-column>
<el-table-column
prop=
"CreateTimestr"
label=
"创建时间"
sortable
v-if=
"queryType[8].show"
show-overflow-tooltip
>
</el-table-column>
<el-table-column
prop=
"IsCarefor"
fixed=
"right"
width=
"50"
label=
"关注"
>
<
template
slot-scope=
"scope"
>
<p>
<el-tooltip
class=
"item"
effect=
"dark"
content=
"关注"
placement=
"top"
>
<i
v-if=
"scope.row.IsCarefor === 0"
class=
"el-icon-star-off cp"
></i>
</el-tooltip>
<el-tooltip
class=
"item"
effect=
"dark"
content=
"取消关注"
placement=
"top"
>
<i
v-if=
"scope.row.IsCarefor === 1"
class=
"el-icon-star-on cp"
></i>
</el-tooltip>
</p>
</
template
>
</el-table-column>
<el-table-column
width=
"40"
fixed=
"right"
>
<
template
slot=
"header"
slot-scope=
"scope"
>
<el-popover
placement=
"bottom"
width=
"240"
>
<mySelect
:queryType=
"queryType"
@
listenTochildEvent=
"showMessageFromChild"
/>
<i
class=
"el-icon-s-operation cp"
slot=
"reference"
></i>
</el-popover>
</
template
>
</el-table-column>
</el-table>
</div>
<div>
<!-- <el-pagination
class="Mypagination"
background
@current-change="handleCurrentChange"
:page-sizes="[30, 60, 90, 100]"
:page-size="msg.pageSize"
layout="sizes, prev, pager, next"
@size-change="handleSizeChange"
:total="total">
</el-pagination> -->
</div>
<el-drawer
:with-header=
"false"
size=
'70%'
:visible
.
sync=
"drawer"
direction=
"rtl"
:before-close=
"handleClose"
>
<customerInfoBox
:CustomerId=
"CustomerId"
@
transferS=
"transfer"
@
watersS=
"waters"
@
editCustS=
"editCust"
/>
</el-drawer>
<el-drawer
:with-header=
"false"
size=
'70%'
:visible
.
sync=
"drawer2"
direction=
"rtl"
:before-close=
"handleClose"
>
<businessInfoBox
:BusinessId=
"BusinessId"
@
transferS=
"transfer"
@
watersS=
"waters"
@
editCustbusiness=
"editCustbusiness"
/>
</el-drawer>
<!-- 编辑客户 -->
<div
v-if=
"dialogCustomerVisible"
>
<customerDialogBox
:name=
"dialogTableVisibleName"
:CustomerId=
"CustomerId"
/>
</div>
<!-- 添加商机弹窗 -->
<div
v-if=
"dialogBusinessVisible"
>
<addBusinessBox
@
getList=
"getList"
:name=
"dialogBusinessVisibleName"
:ID=
"BusinessId"
/>
</div>
</div>
</template>
<
script
>
import
mySelect
from
"../dialogModel/select"
;
import
customerInfoBox
from
"../assembly/customerInfoBox"
;
import
customerDialogBox
from
"../dialogModel/customerDialogBox"
;
import
businessInfoBox
from
"./businessInfoBox"
;
import
addBusinessBox
from
"./addBusinessBox"
;
export
default
{
components
:
{
mySelect
,
customerInfoBox
,
businessInfoBox
,
addBusinessBox
,
customerDialogBox
},
data
()
{
return
{
queryType2
:
[
{
label
:
'商机名称'
,
show
:
true
,
},{
label
:
'客户名称'
,
show
:
true
,
},{
label
:
'预算价格'
,
show
:
true
,
},{
label
:
'预计人数'
,
show
:
true
,
},{
label
:
'备注'
,
show
:
true
,
},{
label
:
'预计出发时间'
,
show
:
true
,
},{
label
:
'负责人'
,
show
:
true
,
},{
label
:
'更新时间'
,
show
:
true
,
},{
label
:
'创建人'
,
show
:
true
,
},{
label
:
'创建时间'
,
show
:
true
,
}
],
queryType
:
[
{
label
:
'商机名称'
,
show
:
true
,
},{
label
:
'客户名称'
,
show
:
true
,
},{
label
:
'预算价格'
,
show
:
true
,
},{
label
:
'预计人数'
,
show
:
true
,
},{
label
:
'备注'
,
show
:
true
,
},{
label
:
'预计出发时间'
,
show
:
true
,
},{
label
:
'负责人'
,
show
:
true
,
},{
label
:
'更新时间'
,
show
:
true
,
},{
label
:
'创建人'
,
show
:
true
,
},{
label
:
'创建时间'
,
show
:
true
,
}
],
BusinessId
:
0
,
dialogTableVisibleName
:
'新增客户'
,
dialogBusinessVisibleName
:
'新建商机'
,
CustomerId
:
0
,
CustomerIdStr
:
''
,
addBusinessShow
:
false
,
transferVisible
:
false
,
dialogCustomerVisible
:
false
,
mySelectCtrl
:
false
,
drawer
:
false
,
drawer2
:
false
,
loading
:
true
,
dialogBusinessVisible
:
false
,
tableData
:
[],
multipleSelection
:
[],
EmployeeList
:
[],
value
:
''
,
userInfo
:
{},
transferMsg
:
{
CustomerIds
:
[],
TransferType
:
1
,
//类型,1-移除,2-转为团员
IsRead
:
0
,
//0-读写,1-只读
EmpId
:
''
,
TransferOther
:
[]
//1-联系人,2-商机,3-合同
},
msg
:
{
BusinessName
:
''
,
pageIndex
:
1
,
pageSize
:
30
,
ContactNumber
:
''
,
WhereType
:
-
1
,
OrderBy
:
''
},
total
:
0
,
WhereTypeList
:
[
{
id
:
-
1
,
name
:
'全部'
},{
id
:
1
,
name
:
'我负责的'
},{
id
:
2
,
name
:
'下属的'
},{
id
:
3
,
name
:
'我参与的'
},{
id
:
4
,
name
:
'我关注的'
},
],
selectionList
:
[
{
name
:
'转移'
,
class
:
'iconfont iconplus-transfer'
,
myFun
:
this
.
transfer
},{
name
:
'导出选中'
,
class
:
'iconfont icondaochu'
,
myFun
:
this
.
export
},{
name
:
'删除'
,
class
:
'iconfont icondelete'
,
myFun
:
this
.
delete
},{
name
:
'添加团队成员'
,
class
:
'iconfont icontianjia'
,
myFun
:
this
.
addCust
}
]
};
},
mounted
()
{
this
.
userInfo
=
this
.
getLocalStorage
();
this
.
getList
()
this
.
Employee
()
let
$this
=
this
this
.
MsgBus
.
$on
(
'closeCustomerDialogBox'
,
function
(){
$this
.
dialogCustomerVisible
=
false
})
this
.
MsgBus
.
$on
(
'closeBusinessDialogBox'
,
function
(){
$this
.
dialogBusinessVisible
=
false
})
this
.
MsgBus
.
$on
(
'closeaddTeamman'
,
function
(){
$this
.
addBusinessShow
=
false
})
},
methods
:
{
Employee
(){
let
msg
=
{
RB_Group_id
:
this
.
userInfo
.
RB_Group_id
,
BranchId
:
-
1
,
DepartmentId
:
0
,
PostId
:
0
,
IsLeave
:
0
,
}
this
.
apipost2
(
"admin_get_EmployeeGetList"
,
this
.
msg
,
res
=>
{
if
(
res
.
data
.
resultCode
==
1
)
{
this
.
EmployeeList
=
res
.
data
.
data
;
}
else
{
}
},
err
=>
{}
);
},
//添加团队成员
addCust
(){
let
str
=
''
this
.
multipleSelection
.
map
((
x
,
i
)
=>
{
str
=
str
+
x
+
','
})
this
.
CustomerIdStr
=
str
.
substring
(
0
,
str
.
length
-
1
)
this
.
addBusinessShow
=
true
},
//删除
delete
(){
console
.
log
(
'删除'
)
},
//导出
export
(){
console
.
log
(
'导出'
)
},
// 更改状态
changeState
(){
console
.
log
(
'更改状态'
)
},
// 放入公海
waters
(
type
){
let
tips
=
'是否放入公海?'
if
(
type
===
1
)
{
tips
=
'是否把客户“'
+
this
.
CustomerName
+
'”放入公海?'
this
.
multipleSelection
.
push
(
this
.
CustomerId
)
}
this
.
$confirm
(
tips
,
'提示'
,
{
confirmButtonText
:
'确定'
,
cancelButtonText
:
'取消'
,
type
:
'warning'
}).
then
(()
=>
{
let
str
=
''
this
.
multipleSelection
.
map
((
x
,
i
)
=>
{
str
=
str
+
x
+
','
})
this
.
apipost
(
'/api/Customer/RemoveMyCustomer'
,
{
CustomerIds
:
str
.
substring
(
0
,
str
.
length
-
1
)},
res
=>
{
if
(
res
.
data
.
resultCode
==
1
)
{
if
(
type
===
1
)
{}
{
this
.
drawer
=
false
}
this
.
multipleSelection
=
[]
this
.
$message
.
success
(
res
.
data
.
message
);
this
.
getList
()
}
})
}).
catch
(()
=>
{
this
.
$message
({
type
:
'info'
,
message
:
'已取消'
});
});
},
// 转移
transfer
(
type
){
if
(
type
!==
2
)
{
if
(
type
===
3
)
{}
{
this
.
multipleSelection
.
push
(
this
.
CustomerId
)
}
this
.
transferVisible
=
true
}
else
{
if
(
this
.
transferMsg
.
EmpId
===
''
)
{
return
this
.
$message
.
error
(
'请选择变更负责人!'
)
}
let
str
=
''
this
.
multipleSelection
.
map
((
x
,
i
)
=>
{
str
=
str
+
x
+
','
})
let
str2
=
''
this
.
transferMsg
.
TransferOther
.
map
((
x
,
i
)
=>
{
str2
=
str2
+
x
+
','
})
this
.
transferMsg
.
CustomerIds
=
str
.
substring
(
0
,
str
.
length
-
1
)
this
.
transferMsg
.
TransferOther
=
str2
.
substring
(
0
,
str
.
length
-
1
)
this
.
apipost
(
'/api/Customer/TransferCustomer'
,
this
.
transferMsg
,
res
=>
{
if
(
res
.
data
.
resultCode
==
1
)
{
this
.
multipleSelection
=
[]
this
.
transferVisible
=
false
if
(
type
===
3
)
{}
{
this
.
drawer
=
false
}
this
.
$message
.
success
(
res
.
data
.
message
);
this
.
getList
()
this
.
transferMsg
=
{
CustomerIds
:
[],
TransferType
:
1
,
IsRead
:
0
,
EmpId
:
''
,
TransferOther
:
[]
}
}
})
}
},
showMessageFromChild
(
list
){
this
.
mySelectCtrl
=!
this
.
mySelectCtrl
if
(
list
)
{
this
.
queryType
=
list
this
.
getList
()
}
},
editCustbusiness
(){
this
.
dialogBusinessVisibleName
=
'修改商机'
this
.
dialogBusinessVisible
=
true
},
editCust
(){
this
.
dialogTableVisibleName
=
'修改客户'
this
.
dialogCustomerVisible
=
true
},
openDetails2
(
scope
){
console
.
log
(
scope
.
row
)
this
.
BusinessId
=
scope
.
row
.
ID
this
.
drawer2
=
true
},
openDetails
(
scope
){
this
.
drawer
=
true
this
.
CustomerId
=
scope
.
row
.
CustomerId
this
.
CustomerName
=
scope
.
row
.
CustomerName
this
.
drawer
=
true
},
handleSizeChange
(
val
)
{
this
.
msg
.
pageSize
=
val
this
.
getList
();
},
handleCurrentChange
(
val
)
{
this
.
msg
.
pageIndex
=
val
;
this
.
getList
();
},
handleClose
(
done
)
{
done
();
},
getList
:
function
(){
this
.
tableData
=
[]
this
.
loading
=
true
this
.
apipost
(
'/api/Customer/GetCustomerBusinessPage'
,
this
.
msg
,
res
=>
{
if
(
res
.
data
.
resultCode
==
1
)
{
this
.
tableData
=
res
.
data
.
data
.
pageData
;
this
.
total
=
res
.
data
.
data
.
count
;
this
.
loading
=
false
;
}
})
},
handleSelectionChange
(
val
)
{
this
.
multipleSelection
=
val
.
map
(
x
=>
x
.
CustomerId
)
}
}
};
</
script
>
src/components/customerManage/customerManage.vue
View file @
e7f634de
...
@@ -12,7 +12,7 @@
...
@@ -12,7 +12,7 @@
</div>
</div>
<div
class=
"rightmenu"
>
<div
class=
"rightmenu"
>
<el-button
class=
"crm-btn query-btn"
@
click=
"getList"
>
查询
</el-button>
<el-button
class=
"crm-btn query-btn"
@
click=
"getList"
>
查询
</el-button>
<el-button
icon=
"el-icon-plus"
class=
"crm-btn org-btn"
@
click=
"CustomerId = 0,dialogTableVisible=true"
>
新增
</el-button>
<el-button
icon=
"el-icon-plus"
class=
"crm-btn org-btn"
@
click=
"CustomerId = 0,
dialogTableVisibleName = '新增客户',
dialogTableVisible=true"
>
新增
</el-button>
<el-dropdown>
<el-dropdown>
<el-button
class=
"crm-btn crm-btn-more easy-btn margin-right0"
>
<el-button
class=
"crm-btn crm-btn-more easy-btn margin-right0"
>
<i
class=
"iconfont icongengduo"
></i>
<i
class=
"iconfont icongengduo"
></i>
...
@@ -255,12 +255,12 @@
...
@@ -255,12 +255,12 @@
:visible
.
sync=
"drawer"
:visible
.
sync=
"drawer"
direction=
"rtl"
direction=
"rtl"
:before-close=
"handleClose"
>
:before-close=
"handleClose"
>
<customerInfoBox
:CustomerId=
"CustomerId"
:detailsData=
"details"
@
transferS=
"transfer"
@
watersS=
"waters"
@
editCustS=
"editCust"
/>
<customerInfoBox
:CustomerId=
"CustomerId"
@
transferS=
"transfer"
@
watersS=
"waters"
@
editCustS=
"editCust"
/>
</el-drawer>
</el-drawer>
<div
v-if=
"dialogTableVisible"
>
<div
v-if=
"dialogTableVisible"
>
<customerDialogBox
@
getList=
"getList"
:CustomerId=
"CustomerId"
/>
<customerDialogBox
@
getList=
"getList"
:
name=
"dialogTableVisibleName"
:
CustomerId=
"CustomerId"
/>
</div>
</div>
<el-dialog
:visible
.
sync=
"transferVisible"
:close-on-click-modal=
"false"
width=
"450px"
custom-class=
"add-box add-box2"
>
<el-dialog
:visible
.
sync=
"transferVisible"
:close-on-click-modal=
"false"
width=
"450px"
custom-class=
"
transfer-box
add-box add-box2"
>
<div
class=
"add-tit"
slot=
"title"
>
<div
class=
"add-tit"
slot=
"title"
>
<p><span></span>
客户转移
</p>
<p><span></span>
客户转移
</p>
<span
icon=
"el-icon-close"
></span>
<span
icon=
"el-icon-close"
></span>
...
@@ -313,17 +313,23 @@
...
@@ -313,17 +313,23 @@
<el-button
class=
"add-box-btn add-box-cancel"
@
click=
"transferVisible = false"
>
取 消
</el-button>
<el-button
class=
"add-box-btn add-box-cancel"
@
click=
"transferVisible = false"
>
取 消
</el-button>
</div>
</div>
</el-dialog>
</el-dialog>
<!-- 添加团队成员弹窗 -->
<div
v-if=
"addTeammanShow"
>
<addTeamman
:ID=
"CustomerIdStr"
@
addTeammanOk=
"addTeammanOk"
/>
</div>
</div>
</div>
</template>
</template>
<
script
>
<
script
>
import
mySelect
from
"../
assembly
/select"
;
import
mySelect
from
"../
dialogModel
/select"
;
import
customerInfoBox
from
"../assembly/customerInfoBox"
;
import
customerInfoBox
from
"../assembly/customerInfoBox"
;
import
customerDialogBox
from
"../assembly/customerDialogBox"
;
import
customerDialogBox
from
"../dialogModel/customerDialogBox"
;
import
addTeamman
from
"../dialogModel/addTeamman"
;
export
default
{
export
default
{
components
:
{
components
:
{
mySelect
,
mySelect
,
customerInfoBox
,
customerInfoBox
,
customerDialogBox
customerDialogBox
,
addTeamman
},
},
data
()
{
data
()
{
return
{
return
{
...
@@ -447,36 +453,17 @@ export default {
...
@@ -447,36 +453,17 @@ export default {
show
:
true
,
show
:
true
,
},
},
],
],
form
:
{
CustomerId
:
0
,
CustomerName
:
''
,
CustomerLevel
:
''
,
Contact
:
''
,
ContactNumber
:
''
,
Address
:
''
,
Remark
:
''
,
Premises
:
''
,
CustomerStatus
:
0
,
CustomerSourceType
:
''
,
CustomerSource
:
''
,
Country
:
''
,
Province
:
''
,
City
:
''
,
District
:
''
,
BrandIds
:
[],
Images
:
[],
BusinessCardPhotos
:
[],
HousePhotos
:
[],
},
CustomerId
:
0
,
CustomerId
:
0
,
CustomerIdStr
:
''
,
addTeammanShow
:
false
,
transferVisible
:
false
,
transferVisible
:
false
,
mySelectCtrl
:
false
,
mySelectCtrl
:
false
,
drawer
:
false
,
drawer
:
false
,
loading
:
true
,
loading
:
true
,
dialogTableVisible
:
false
,
dialogTableVisible
:
false
,
dialogTableVisibleName
:
'新增客户'
,
tableData
:
[],
tableData
:
[],
multipleSelection
:
[],
multipleSelection
:
[],
details
:
{},
EmployeeList
:
[],
EmployeeList
:
[],
value
:
''
,
value
:
''
,
userInfo
:
{},
userInfo
:
{},
...
@@ -548,11 +535,12 @@ export default {
...
@@ -548,11 +535,12 @@ export default {
name
:
'添加团队成员'
,
name
:
'添加团队成员'
,
class
:
'iconfont icontianjia'
,
class
:
'iconfont icontianjia'
,
myFun
:
this
.
addCust
myFun
:
this
.
addCust
},{
name
:
'删除团队成员'
,
class
:
'iconfont iconjian'
,
myFun
:
this
.
delCust
},
},
// {
// name: '删除团队成员',
// class:'iconfont iconjian',
// myFun: this.delCust,
// },
]
]
};
};
},
},
...
@@ -564,6 +552,9 @@ export default {
...
@@ -564,6 +552,9 @@ export default {
this
.
MsgBus
.
$on
(
'closeCustomerDialogBox'
,
function
(){
this
.
MsgBus
.
$on
(
'closeCustomerDialogBox'
,
function
(){
$this
.
dialogTableVisible
=
false
$this
.
dialogTableVisible
=
false
})
})
this
.
MsgBus
.
$on
(
'closeaddTeamman'
,
function
(){
$this
.
addTeammanShow
=
false
})
},
},
methods
:
{
methods
:
{
Employee
(){
Employee
(){
...
@@ -595,9 +586,17 @@ export default {
...
@@ -595,9 +586,17 @@ export default {
Unlock
(){
Unlock
(){
console
.
log
(
'解锁'
)
console
.
log
(
'解锁'
)
},
},
addTeammanOk
(){
this
.
addTeammanShow
=
false
},
//添加团队成员
//添加团队成员
addCust
(){
addCust
(){
console
.
log
(
'添加团队成员'
)
let
str
=
''
this
.
multipleSelection
.
map
((
x
,
i
)
=>
{
str
=
str
+
x
+
','
})
this
.
CustomerIdStr
=
str
.
substring
(
0
,
str
.
length
-
1
)
this
.
addTeammanShow
=
true
},
},
//删除团队成员
//删除团队成员
delCust
(){
delCust
(){
...
@@ -698,47 +697,14 @@ export default {
...
@@ -698,47 +697,14 @@ export default {
}
}
},
},
editCust
(){
editCust
(){
this
.
dialogTableVisibleName
=
'修改客户'
this
.
dialogTableVisible
=
true
this
.
dialogTableVisible
=
true
this
.
form
=
this
.
details
},
},
openDetails
(
scope
){
openDetails
(
scope
){
this
.
drawer
=
true
this
.
drawer
=
true
this
.
CustomerId
=
scope
.
row
.
CustomerId
this
.
CustomerId
=
scope
.
row
.
CustomerId
this
.
CustomerName
=
scope
.
row
.
CustomerName
this
.
CustomerName
=
scope
.
row
.
CustomerName
this
.
apipost
(
'/api/Customer/GetAllCustmersModel'
,
{
CustomerId
:
this
.
CustomerId
},
res
=>
{
if
(
res
.
data
.
resultCode
==
1
)
{
let
data
=
res
.
data
.
data
if
(
!
data
.
HousePhotos
){
data
.
HousePhotos
=
[]
}
if
(
!
data
.
BusinessCardPhotos
){
data
.
BusinessCardPhotos
=
[]
}
if
(
!
data
.
Images
){
data
.
Images
=
[]
}
if
(
!
data
.
CustomerSourceType
){
data
.
CustomerSourceType
=
''
}
if
(
!
data
.
CustomerSource
){
data
.
CustomerSource
=
''
}
if
(
!
data
.
Province
){
data
.
Province
=
''
}
if
(
!
data
.
Country
){
data
.
Country
=
''
}
if
(
!
data
.
City
){
data
.
City
=
''
}
if
(
!
data
.
District
){
data
.
District
=
''
}
this
.
details
=
data
this
.
drawer
=
true
this
.
drawer
=
true
}
})
},
},
handleSizeChange
(
val
)
{
handleSizeChange
(
val
)
{
this
.
msg
.
pageSize
=
val
this
.
msg
.
pageSize
=
val
...
...
src/components/
assembly
/addContacts.vue
→
src/components/
dialogModel
/addContacts.vue
View file @
e7f634de
...
@@ -32,32 +32,6 @@
...
@@ -32,32 +32,6 @@
.addContacts
.el-dialog__footer
{
.addContacts
.el-dialog__footer
{
padding
:
0
;
padding
:
0
;
}
}
.addContacts
.el-dialog__body
{
background-color
:
rgba
(
248
,
250
,
251
,
1
);
padding-top
:
20px
;
max-height
:
500px
;
overflow
:
auto
;
}
.addContacts
.add-box-btn.el-button
{
border-radius
:
0
;
background-color
:
rgba
(
13
,
36
,
129
,
.8
);
border-color
:
rgba
(
13
,
36
,
129
,
.8
);
color
:
white
;
padding
:
12px
43px
;
}
.addContacts
.add-box-btn.el-button
:hover
{
background-color
:
rgba
(
13
,
36
,
129
,
1
);
border-color
:
rgba
(
13
,
36
,
129
,
1
);
color
:
white
;
}
.addContacts
.add-box-btn.el-button.add-box-cancel
{
color
:
rgba
(
13
,
36
,
129
,
.8
);
background-color
:
white
;
}
.addContacts
.add-box-btn.el-button.add-box-cancel
:hover
{
color
:
rgba
(
13
,
36
,
129
,
1
);
background-color
:
white
;
}
</
style
>
</
style
>
<
template
>
<
template
>
<el-dialog
@
closed=
"closedDialog"
:modal=
"false"
:visible
.
sync=
"dialogTableVisible"
:close-on-click-modal=
"false"
class=
"addContacts"
>
<el-dialog
@
closed=
"closedDialog"
:modal=
"false"
:visible
.
sync=
"dialogTableVisible"
:close-on-click-modal=
"false"
class=
"addContacts"
>
...
@@ -202,6 +176,7 @@ export default {
...
@@ -202,6 +176,7 @@ export default {
this
.
form
.
CustomerId
=
this
.
ID
this
.
form
.
CustomerId
=
this
.
ID
this
.
apipost
(
'/api/Customer/CreateMyCustomerContact'
,
this
.
form
,
res
=>
{
this
.
apipost
(
'/api/Customer/CreateMyCustomerContact'
,
this
.
form
,
res
=>
{
if
(
res
.
data
.
resultCode
==
1
)
{
if
(
res
.
data
.
resultCode
==
1
)
{
this
.
$message
.
success
(
'操作成功'
)
this
.
resetForm
(
"form"
);
this
.
resetForm
(
"form"
);
this
.
dialogTableVisible
=
false
;
this
.
dialogTableVisible
=
false
;
this
.
$emit
(
'addContactsOk'
)
this
.
$emit
(
'addContactsOk'
)
...
...
src/components/dialogModel/addTeamman.vue
0 → 100644
View file @
e7f634de
<
style
>
.addTeamman
.add-tit
{
display
:
flex
;
justify-content
:
space-between
;
align-items
:
center
;
height
:
20px
;
}
.addTeamman
.add-tit
p
{
display
:
flex
;
align-items
:
center
;
font-weight
:
bold
;
color
:
rgba
(
17
,
17
,
17
,
1
);
font-size
:
14px
;
}
.addTeamman
.add-tit
p
span
{
display
:
inline-block
;
width
:
6px
;
height
:
6px
;
background
:
rgba
(
13
,
36
,
129
,
1
);
border-radius
:
50%
;
margin-right
:
10px
;
}
.addTeamman
.el-dialog__header
{
padding
:
15px
20px
;
background
:
rgba
(
255
,
255
,
255
,
1
);
}
.addTeamman
.dialog-footer
{
text-align
:
center
;
background-color
:
rgba
(
248
,
250
,
251
,
1
);
padding-bottom
:
20px
;
}
.addTeamman
.el-dialog__footer
{
padding
:
0
;
}
.addTeamman
.el-tag.el-tag--info
{
background-color
:
rgba
(
0
,
0
,
0
,
0
);
border-color
:
rgba
(
0
,
0
,
0
,
0
);
display
:
inline-block
;
white-space
:
nowrap
;
overflow
:
hidden
;
text-overflow
:
ellipsis
;
}
</
style
>
<
template
>
<el-dialog
@
closed=
"closedDialog"
:modal=
"false"
:visible
.
sync=
"dialogTableVisible"
width=
"450px"
:close-on-click-modal=
"false"
class=
"addTeamman"
>
<div
class=
"add-tit"
slot=
"title"
>
<p><span></span>
添加团队成员
</p>
<span
icon=
"el-icon-close"
></span>
</div>
<div
class=
"form-box"
>
<el-form
:model=
"form"
ref=
"form"
class=
"MyEditForm"
>
<div
class=
"MyEditForm-item"
>
<el-form-item
label=
"成员"
class=
"label-pad-left"
prop=
"ContactDuty"
>
<el-select
multiple
filterable
v-model=
"EmpIdsS"
placeholder=
"请选择联系人职务"
>
<el-option
v-for=
"item in EmployeeList"
:label=
'item.EmName'
:value=
'item.EmployeeId'
:key=
'item.EmployeeId'
>
</el-option>
</el-select>
</el-form-item>
</div>
<div
class=
"MyEditForm-item"
>
<el-form-item
label=
"权限"
class=
"label-pad-left form-check"
>
<div
class=
"pad-left-10"
>
<el-radio
v-model=
"form.IsRead"
:label=
"0"
>
只读
</el-radio>
<el-radio
v-model=
"form.IsRead"
:label=
"1"
>
读写
</el-radio>
</div>
</el-form-item>
</div>
<div
class=
"MyEditForm-item"
>
<el-form-item
label=
"同时添加至"
class=
"label-pad-left form-check"
>
<div
class=
"pad-left-10"
>
<el-checkbox-group
v-model=
"TransferOther"
>
<el-checkbox
:value=
"2"
:label=
"2"
>
商机
</el-checkbox>
<el-checkbox
:value=
"3"
:label=
"3"
>
合同
</el-checkbox>
</el-checkbox-group>
</div>
</el-form-item>
</div>
</el-form>
</div>
<div
slot=
"footer"
class=
"dialog-footer"
>
<el-button
type=
"primary"
class=
"add-box-btn"
@
click=
"submitForm('form')"
>
确 定
</el-button>
<el-button
class=
"add-box-btn add-box-cancel"
@
click=
"dialogTableVisible = false, resetForm('form')"
>
取 消
</el-button>
</div>
</el-dialog>
</
template
>
<
script
>
export
default
{
props
:
[
'ID'
],
data
()
{
return
{
dialogTableVisible
:
true
,
EmployeeList
:
[],
EmpIdsS
:
[],
TransferOther
:
[],
form
:
{
CustomerIds
:
0
,
EmpIds
:
''
,
IsRead
:
0
,
TransferOther
:
''
}
};
},
watch
:{
},
mounted
()
{
this
.
Employee
()
let
$this
=
this
setTimeout
(()
=>
{
$this
.
dialogTableVisible
=
true
},
50
)
},
methods
:
{
closedDialog
(){
this
.
MsgBus
.
$emit
(
'closeaddTeamman'
)
},
addData
(){
this
.
form
.
CustomerIds
=
this
.
ID
if
(
this
.
EmpIdsS
.
length
<
1
)
{
return
this
.
$message
.
error
(
'请选择成员'
)
}
else
{
let
str
=
''
this
.
EmpIdsS
.
map
((
x
,
i
)
=>
{
str
=
str
+
x
+
','
})
this
.
form
.
EmpIds
=
str
.
substring
(
0
,
str
.
length
-
1
)
}
if
(
this
.
TransferOther
.
length
<
1
)
{
let
str2
=
''
this
.
TransferOther
.
map
((
x
,
i
)
=>
{
str2
=
str2
+
x
+
','
})
this
.
form
.
TransferOther
=
str2
.
substring
(
0
,
str2
.
length
-
1
)
}
this
.
apipost
(
'/api/Customer/AddTeamMembers'
,
this
.
form
,
res
=>
{
if
(
res
.
data
.
resultCode
==
1
)
{
this
.
resetForm
(
"form"
);
this
.
dialogTableVisible
=
false
;
this
.
$emit
(
'addTeammanOk'
)
this
.
$message
.
success
(
res
.
data
.
message
)
}
else
{
this
.
$message
.
error
(
res
.
data
.
message
)
}
})
},
submitForm
(
addMsg
)
{
//提交创建、修改表单
this
.
$refs
[
addMsg
].
validate
(
valid
=>
{
if
(
valid
)
{
this
.
addData
();
}
else
{
return
false
;
}
});
},
Employee
(){
let
userInfo
=
this
.
getLocalStorage
()
let
msg
=
{
RB_Group_id
:
userInfo
.
RB_Group_id
,
BranchId
:
-
1
,
DepartmentId
:
0
,
PostId
:
0
,
IsLeave
:
0
,
}
this
.
apipost2
(
"admin_get_EmployeeGetList"
,
this
.
msg
,
res
=>
{
if
(
res
.
data
.
resultCode
==
1
)
{
this
.
EmployeeList
=
res
.
data
.
data
;
}
else
{
}
},
err
=>
{}
);
},
resetForm
(
formName
)
{
// 重置表单
this
.
form
=
{
CustomerId
:
0
,
EmpIds
:
[],
IsRead
:
0
,
TransferOther
:
[]
}
this
.
$refs
[
formName
].
resetFields
();
},
}
}
</
script
>
\ No newline at end of file
src/components/
assembly
/customerDialogBox.vue
→
src/components/
dialogModel
/customerDialogBox.vue
View file @
e7f634de
...
@@ -76,32 +76,6 @@
...
@@ -76,32 +76,6 @@
border-radius
:
50%
;
border-radius
:
50%
;
margin-right
:
10px
;
margin-right
:
10px
;
}
}
.customerDialogBox
.selection-box
{
display
:
flex
;
align-items
:
center
;
}
.customerDialogBox
.selection-box
span
{
font-size
:
12px
;
text-align
:
center
;
}
.customerDialogBox
.selection-box
.el-button
{
color
:
#666
;
background-color
:
#f6f8fa
;
border-color
:
#f6f8fa
;
font-size
:
12px
;
height
:
28px
;
border-radius
:
14px
;
padding
:
5px
12px
;
margin-left
:
15px
;
}
.customerDialogBox
.selection-box
.el-button
i
{
margin-right
:
5px
;
}
.customerDialogBox
.selection-box
.el-button
:hover
{
background
:
#2362fb
;
border-color
:
#2362fb
;
color
:
#fff
;
}
.customerDialogBox
.up-img-box
.uib-item
{
.customerDialogBox
.up-img-box
.uib-item
{
margin-right
:
30px
;
margin-right
:
30px
;
width
:
120px
;
width
:
120px
;
...
@@ -160,7 +134,7 @@
...
@@ -160,7 +134,7 @@
<
template
>
<
template
>
<el-dialog
:visible
.
sync=
"dialogTableVisible"
@
closed=
"closedDialog"
:close-on-click-modal=
"false"
class=
"add-box add-box1 customerDialogBox"
>
<el-dialog
:visible
.
sync=
"dialogTableVisible"
@
closed=
"closedDialog"
:close-on-click-modal=
"false"
class=
"add-box add-box1 customerDialogBox"
>
<div
class=
"add-tit"
slot=
"title"
>
<div
class=
"add-tit"
slot=
"title"
>
<p><span></span>
新建客户
</p>
<p><span></span>
{{
name
}}
</p>
<span
icon=
"el-icon-close"
></span>
<span
icon=
"el-icon-close"
></span>
</div>
</div>
<div
class=
"form-box"
v-if=
"show"
>
<div
class=
"form-box"
v-if=
"show"
>
...
@@ -414,6 +388,10 @@ export default {
...
@@ -414,6 +388,10 @@ export default {
CustomerId
:
{
CustomerId
:
{
type
:
Number
,
type
:
Number
,
default
:
0
default
:
0
},
name
:
{
type
:
String
,
default
:
'新增客户'
}
}
},
},
data
()
{
data
()
{
...
@@ -661,14 +639,14 @@ export default {
...
@@ -661,14 +639,14 @@ export default {
Id
:
ID
Id
:
ID
};
};
if
(
type
==
1
)
{
if
(
type
==
1
)
{
this
.
Province
=
""
;
this
.
form
.
Province
=
""
;
this
.
City
=
""
;
this
.
form
.
City
=
""
;
this
.
District
=
""
;
this
.
form
.
District
=
""
;
}
else
if
(
type
==
2
)
{
}
else
if
(
type
==
2
)
{
this
.
City
=
""
;
this
.
form
.
City
=
""
;
this
.
District
=
""
;
this
.
form
.
District
=
""
;
}
else
if
(
type
==
3
)
{
}
else
if
(
type
==
3
)
{
this
.
District
=
""
;
this
.
form
.
District
=
""
;
}
}
if
(
this
.
QCountry
!==
""
)
{
if
(
this
.
QCountry
!==
""
)
{
this
.
apipost2
(
this
.
apipost2
(
...
...
src/components/dialogModel/editTeamPower.vue
0 → 100644
View file @
e7f634de
<
style
>
.editTeamPower
.add-tit
{
display
:
flex
;
justify-content
:
space-between
;
align-items
:
center
;
height
:
20px
;
}
.editTeamPower
.add-tit
p
{
display
:
flex
;
align-items
:
center
;
font-weight
:
bold
;
color
:
rgba
(
17
,
17
,
17
,
1
);
font-size
:
14px
;
}
.editTeamPower
.add-tit
p
span
{
display
:
inline-block
;
width
:
6px
;
height
:
6px
;
background
:
rgba
(
13
,
36
,
129
,
1
);
border-radius
:
50%
;
margin-right
:
10px
;
}
.editTeamPower
.el-dialog__header
{
padding
:
15px
20px
;
background
:
rgba
(
255
,
255
,
255
,
1
);
}
.editTeamPower
.dialog-footer
{
text-align
:
center
;
background-color
:
rgba
(
248
,
250
,
251
,
1
);
padding-bottom
:
20px
;
}
.editTeamPower
.el-dialog__footer
{
padding
:
0
;
}
</
style
>
<
template
>
<el-dialog
@
closed=
"closedDialog"
:modal=
"false"
width=
"400px"
:visible
.
sync=
"dialogTableVisible"
:close-on-click-modal=
"false"
class=
"editTeamPower"
>
<div
class=
"add-tit"
slot=
"title"
>
<p><span></span>
编辑权限
</p>
<span
icon=
"el-icon-close"
></span>
</div>
<div
class=
"form-box"
>
<el-form
:model=
"form"
ref=
"form"
class=
"MyEditForm"
>
<div
class=
"MyEditForm-item"
>
<el-form-item
label=
"权限"
class=
"label-pad-left form-check"
>
<div
class=
"pad-left-10"
>
<el-radio
v-model=
"form.IsRead"
:label=
"1"
>
只读
</el-radio>
<el-radio
v-model=
"form.IsRead"
:label=
"0"
>
读写
</el-radio>
</div>
</el-form-item>
</div>
</el-form>
</div>
<div
slot=
"footer"
class=
"dialog-footer"
>
<el-button
type=
"primary"
class=
"add-box-btn"
@
click=
"submitForm('form')"
>
确 定
</el-button>
<el-button
class=
"add-box-btn add-box-cancel"
@
click=
"dialogTableVisible = false, resetForm('form')"
>
取 消
</el-button>
</div>
</el-dialog>
</
template
>
<
script
>
export
default
{
props
:{
ID
:
{
type
:
''
,
default
:
0
},
CustomerId
:
{
type
:
Number
,
default
:
0
}
},
data
()
{
return
{
dialogTableVisible
:
true
,
zwList
:
[],
form
:
{
CustomerId
:
0
,
ID
:
''
,
IsRead
:
1
,
}
};
},
watch
:{
},
mounted
()
{
let
$this
=
this
setTimeout
(()
=>
{
$this
.
dialogTableVisible
=
true
},
50
)
},
methods
:
{
closedDialog
(){
this
.
MsgBus
.
$emit
(
'closeeditTeamPower'
)
},
addData
(){
this
.
form
.
CustomerId
=
this
.
CustomerId
this
.
form
.
IDs
=
this
.
ID
this
.
apipost
(
'/api/Customer/EditCustomerJurisdiction'
,
this
.
form
,
res
=>
{
if
(
res
.
data
.
resultCode
==
1
)
{
this
.
$message
.
success
(
'操作成功'
)
this
.
resetForm
(
"form"
);
this
.
dialogTableVisible
=
false
;
this
.
$emit
(
'addTeammanOk'
)
}
})
},
submitForm
(
addMsg
)
{
//提交创建、修改表单
this
.
$refs
[
addMsg
].
validate
(
valid
=>
{
if
(
valid
)
{
this
.
addData
();
}
else
{
return
false
;
}
});
},
resetForm
(
formName
)
{
// 重置表单
this
.
form
=
{
CustomerId
:
0
,
ID
:
''
,
IsRead
:
0
,
}
this
.
$refs
[
formName
].
resetFields
();
},
}
}
</
script
>
\ No newline at end of file
src/components/
assembly
/select.vue
→
src/components/
dialogModel
/select.vue
View file @
e7f634de
File moved
src/router.js
View file @
e7f634de
...
@@ -5,6 +5,7 @@ import login from "./views/login";
...
@@ -5,6 +5,7 @@ import login from "./views/login";
import
Home
from
"./components/Home"
import
Home
from
"./components/Home"
import
customerManage
from
"./components/customerManage/customerManage"
import
customerManage
from
"./components/customerManage/customerManage"
import
customerManageDemo
from
"./components/customerManage/customerManageDemo"
import
customerManageDemo
from
"./components/customerManage/customerManageDemo"
import
businessManagement
from
"./components/businessManagement/businessManagement"
Vue
.
use
(
Router
);
Vue
.
use
(
Router
);
export
default
new
Router
({
export
default
new
Router
({
...
@@ -64,6 +65,14 @@ export default new Router({
...
@@ -64,6 +65,14 @@ export default new Router({
meta
:
{
meta
:
{
title
:
"客户管理"
title
:
"客户管理"
}
}
},
{
path
:
"/businessManagement"
,
name
:
"businessManagement"
,
component
:
businessManagement
,
meta
:
{
title
:
"商机管理"
}
}
}
]
]
},
},
...
...
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