Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
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
Boards
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
Kimber
CRM
Commits
1176053a
Commit
1176053a
authored
Mar 09, 2023
by
Kimber
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
'update'
parent
026b8f52
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
384 additions
and
272 deletions
+384
-272
customer.js
src/api/customer.js
+9
-0
index.vue
src/views/customerManagement/index.vue
+375
-272
No files found.
src/api/customer.js
View file @
1176053a
...
...
@@ -135,3 +135,12 @@ export function technicalDirector() {
}
// 导出Excel
export
function
exportExcel
(
params
)
{
return
request
({
url
:
'
/api/customer/exportExcel
'
,
method
:
'
get
'
,
//responseType:'blob',
params
})
}
\ No newline at end of file
src/views/customerManagement/index.vue
View file @
1176053a
...
...
@@ -5,7 +5,7 @@
<el-input
type=
"number"
v-model=
"tel"
style=
"width:
180px; margin-left: 2
0px"
style=
"width:
130px; margin-left: 1
0px"
placeholder=
"请输入电话"
clearable
/>
...
...
@@ -15,7 +15,7 @@
filterable
clearable
allow-create
style=
"
margin-left: 30
px;"
style=
"
width:180px; margin-left: 15
px;"
>
<el-option
v-for=
"item in typeManage.dropData"
...
...
@@ -27,7 +27,7 @@
<el-input
v-model=
"salesName"
type=
"text"
style=
"width:
180px; margin-left: 20
px"
style=
"width:
150px; margin-left: 15
px"
placeholder=
"请输入销售人员"
clearable
/>
...
...
@@ -37,7 +37,7 @@
filterable
clearable
allow-create
style=
"
margin-left: 30
px;"
style=
"
width:160px;margin-left: 15
px;"
>
<el-option
v-for=
"item in validornotData"
...
...
@@ -45,9 +45,19 @@
:value=
"item.value"
/>
</el-select>
<el-select
v-model=
"dealStatus"
placeholder=
"是否成交"
filterable
clearable
allow-create
style=
"width:120px;margin-left: 15px;"
>
<el-option
v-for=
"item in Dict.dealStatus"
:label=
"item.name"
:value=
"item.value"
/>
</el-select>
<el-date-picker
:default-time=
"['00:00:00', '23:59:59']"
style=
"width:
380px !important;margin-left: 30
px;"
style=
"width:
200px !important;margin-left: 15
px;"
v-model=
"searchTime"
type=
"datetimerange"
range-separator=
"至"
...
...
@@ -57,16 +67,22 @@
/>
<el-button
type=
"success"
style=
"margin-left:
30
px"
style=
"margin-left:
15
px"
icon=
"el-icon-search"
@
click=
"toSearch"
>
搜索
</el-button
>
<el-button
type=
"primary"
style=
"margin-left:
30
px"
style=
"margin-left:
15
px"
icon=
"el-icon-circle-plus"
@
click=
"newlyAdd('add')"
>
新增
</el-button>
<el-button
type=
"warning"
style=
"margin-left: 15px"
icon=
"el-icon-circle-plus"
@
click=
"reqExportExcel()"
>
导出
</el-button>
</div>
<!-- 获取全部 -->
<div
class=
"table-wrapper"
>
...
...
@@ -76,7 +92,6 @@
>
<el-table-column
type=
"index"
label=
"序号"
width=
"60"
/>
<el-table-column
prop=
"name"
label=
"姓名"
width=
"120"
/>
<el-table-column
prop=
"tel"
label=
"电话"
width=
"140"
/>
<el-table-column
prop=
"giveUp"
label=
"是否废弃"
width=
"130"
>
<template
slot-scope=
"scope"
>
<span
v-if=
"scope.row.giveUp === 0"
style=
"color: #67c23a;"
>
有效
</span>
...
...
@@ -92,27 +107,41 @@
<span
v-else
style=
"color: #67c23a;"
>
已成交
</span>
</
template
>
</el-table-column>
<el-table-column
prop=
"itemCompletedQuantity"
label=
"成交数量"
/>
<el-table-column
prop=
"classidStr"
label=
"信息分类"
width=
"150"
/>
<el-table-column
prop=
"inforSourceVo"
label=
"客户来源"
width=
"150"
/>
<el-table-column
prop=
"custLevel"
label=
"客户级别"
width=
"150"
/>
<el-table-column
prop=
"custType"
label=
"客户类型"
width=
"150"
/>
<el-table-column
label=
"操作"
fixed=
"right"
width=
"220"
>
<
template
slot-scope=
"scope"
>
<el-button
size=
"mini"
type=
"primary"
icon=
"el-icon-view"
@
click=
"see($event, scope.$index, scope.row)"
>
查看
</el-button
>
<el-button
size=
"mini"
type=
"primary"
icon=
"el-icon-edit"
@
click=
"newlyAdd('edit', $event, scope.$index, scope.row)"
>
编辑
</el-button
>
</
template
>
<el-table-column
prop=
"tel"
label=
"电话"
width=
"140"
/>
<el-table-column
prop=
"custAddr"
label=
"地址"
width=
"140"
/>
<el-table-column
prop=
"qqnub"
label=
"QQ"
width=
"140"
/>
<el-table-column
prop=
"weixin"
label=
"微信"
width=
"140"
/>
<el-table-column
prop=
"priorSaleidStr"
label=
"原销售"
width=
"100"
/>
<el-table-column
label=
"操作"
fixed=
"right"
width=
"280"
>
<
template
slot-scope=
"scope"
>
<el-button
size=
"mini"
type=
"primary"
icon=
"el-icon-view"
@
click=
"see($event, scope.$index, scope.row)"
>
查看
</el-button
>
<el-button
size=
"mini"
type=
"primary"
icon=
"el-icon-edit"
@
click=
"newlyAdd('edit', $event, scope.$index, scope.row)"
>
编辑
</el-button
>
<el-button
size=
"mini"
type=
"warning"
icon=
"el-icon-edit"
:disabled=
"!scope.row.giveUp"
@
click=
"restartConfig(scope.row)"
>
重分配
</el-button
>
</
template
>
</el-table-column>
</el-table>
<el-pagination
...
...
@@ -275,6 +304,9 @@
<el-input
v-model=
"addEntry.entryName"
type=
"text"
clearable
style=
"width: 200px !important;"
/>
</el-form-item>
<el-form-item
prop=
"erpOrderNo"
label=
"ERP单号"
style=
"margin-left: 30px;"
>
<el-input
v-model=
"addEntry.erpOrderNo"
type=
"text"
clearable
style=
"width:200px !important;"
placeholder=
"请输入ERP单号"
/>
</el-form-item>
<el-form-item
label=
"需求描述:"
autosize
prop=
"specific"
style=
"margin-left: 30px;margin-top:10px;"
>
<el-input
type=
"textarea"
...
...
@@ -295,21 +327,19 @@
:model=
"renewEntry"
:rules=
"renewrules"
>
<el-form-item
prop=
"entryName"
label=
"项目名称"
style=
"margin-left: 30px;"
>
<el-input
v-model=
"renewEntry.entryName"
type=
"text"
clearable
style=
"width: 200px !important;"
/>
</el-form-item>
<el-form-item
label=
"需求描述:"
autosize
prop=
"specific"
style=
"margin-left: 30px;margin-top:10px;"
>
<el-input
type=
"textarea"
v-model=
"renewEntry.specific"
:rows=
"5"
style=
"width:50%!important;"
>
</el-input>
</el-form-item>
<el-form-item
prop=
"entryName"
label=
"项目名称"
style=
"margin-left: 30px;"
>
<el-input
v-model=
"renewEntry.entryName"
type=
"text"
clearable
style=
"width: 200px !important;"
/>
</el-form-item>
<el-form-item
prop=
"erpOrderNo"
label=
"ERP单号"
style=
"margin-left: 30px;"
>
<el-input
v-model=
"renewEntry.erpOrderNo"
type=
"text"
clearable
style=
"width:200px !important;"
placeholder=
"请输入ERP单号"
/>
</el-form-item>
<el-form-item
label=
"需求描述:"
autosize
prop=
"specific"
style=
"margin-left: 30px;margin-top:10px;"
>
<el-input
type=
"textarea"
v-model=
"renewEntry.specific"
:rows=
"5"
style=
"width:50%!important;"
/>
</el-form-item>
</el-form>
<div
slot=
"footer"
>
<el-button
type=
"primary"
@
click=
"renewUpate"
>
确定
</el-button>
<el-button
type=
"primary"
@
click=
"renewUpate"
>
确定
</el-button>
</div>
</el-dialog>
<!-- 废弃弹窗 -->
...
...
@@ -721,69 +751,67 @@
<div
slot=
"footer"
>
<el-button
type=
"primary"
@
click=
"deliverUpate"
>
确定
</el-button>
</div>
</el-dialog>
<!-- 发布跟进记录 -->
<el-dialog
:title=
"flowup.title"
:visible.sync=
"modifyreleaseDialog"
append-to-body
>
<el-form
</el-dialog>
<!-- 发布跟进记录 -->
<el-dialog
:title=
"flowup.title"
:visible.sync=
"modifyreleaseDialog"
append-to-body
>
<el-form
ref=
"fileForm"
:model=
"flowup.from"
max-height=
"500"
max-height=
"500"
:rules=
"releaserules"
>
<el-form-item
prop=
"followStatus"
label=
"跟进状态:"
style=
"margin-left: 30px;"
>
<el-select
v-model=
"flowup.from.followStatus"
clearable
placeholder=
"请选择跟进状态"
>
<el-option
v-for=
"item in Dict.followUpList"
:key=
"item.value"
:label=
"item.name"
:value=
"item.value"
:disabled=
"item.followdisabled"
>
<el-form-item
prop=
"followStatus"
label=
"跟进状态:"
style=
"margin-left: 30px;"
>
<el-select
v-model=
"flowup.from.followStatus"
clearable
placeholder=
"请选择跟进状态"
@
change=
"isErpOnchange"
>
<el-option
v-for=
"item in Dict.followUpList"
:key=
"item.value"
:label=
"item.name"
:value=
"item.value"
:disabled=
"item.followdisabled"
>
</el-option>
</el-select>
</el-form-item>
<el-form-item
prop=
"erpOrderNo"
label=
"ERP单号"
style=
"margin-left:30px;"
v-if=
"flowup.isErpOrderNo"
>
<el-input
v-model=
"flowup.from.erpOrderNo"
style=
"width:200px;"
type=
"text"
placeholder=
"请输入ERP单号"
/>
</el-form-item>
<el-form-item
prop=
"remindTime"
label=
"下次提醒时间:"
style=
"margin-left: 30px;"
>
<el-date-picker
v-model=
"flowup.from.remindTime"
type=
"datetime"
clearable
placeholder=
"选择日期"
>
</el-date-picker>
</el-form-item>
<el-form-item
label=
"跟进结果:"
autosize
prop=
"followResult"
style=
"margin-left: 30px;margin-top:10px;"
>
<el-input
type=
"textarea"
v-model=
"flowup.from.followResult"
:rows=
"5"
clearable
style=
"width: 80%!important;"
>
</el-input>
</el-form-item>
<el-form-item
prop=
"followFiles"
label=
"文件名称"
:label-width=
"'120px'"
>
<div
v-if=
"showPrise"
>
{{this.flowup.from.followFiles}}
</div>
<el-upload
class=
"upload"
name=
"file"
ref=
"fileRef"
:limit=
"1"
:on-change=
"handleBeforeUpload"
:auto-upload=
"false"
:before-remove=
"removeFileCallback"
>
</el-option>
</el-select>
</el-form-item>
<el-form-item
prop=
"remindTime"
label=
"下次提醒时间:"
style=
"margin-left: 30px;"
>
<el-date-picker
v-model=
"flowup.from.remindTime"
type=
"datetime"
clearable
placeholder=
"选择日期"
>
</el-date-picker>
</el-form-item>
<el-form-item
label=
"跟进结果:"
autosize
prop=
"followResult"
style=
"margin-left: 30px;margin-top:10px;"
>
<el-input
type=
"textarea"
v-model=
"flowup.from.followResult"
:rows=
"5"
clearable
style=
"width: 80%!important;"
>
</el-input>
</el-form-item>
<el-form-item
prop=
"followFiles"
label=
"文件名称"
:label-width=
"'120px'"
>
<div
v-if=
"showPrise"
>
{{this.flowup.from.followFiles}}
</div>
<el-upload
class=
"upload"
name=
"file"
ref=
"fileRef"
:limit=
"1"
:on-change=
"handleBeforeUpload"
:auto-upload=
"false"
:before-remove=
"removeFileCallback"
>
<el-button
type=
"text"
size=
"small"
icon=
"el-icon-upload"
>
点击上传
</el-button>
</el-upload>
</el-form-item>
</el-form>
<div
slot=
"footer"
>
<el-button
type=
"primary"
@
click=
"emodifyupate"
>
确定
</el-button>
</div>
</el-dialog>
<!-- 指派售前人员 -->
<el-dialog
title=
"售前技术支持"
:visible.sync=
"assignDialog"
append-to-body
>
<el-button
type=
"text"
size=
"small"
icon=
"el-icon-upload"
>
点击上传
</el-button>
</el-upload>
</el-form-item>
</el-form>
<div
slot=
"footer"
>
<el-button
type=
"primary"
@
click=
"emodifyupate"
>
确定
</el-button>
</div>
</el-dialog>
<!-- 指派售前人员 -->
<el-dialog
title=
"售前技术支持"
:visible.sync=
"assignDialog"
append-to-body
>
<el-form
ref=
"saleEngineerRef"
:model=
"handoverSalemanfrom"
...
...
@@ -821,7 +849,7 @@
<div
slot=
"footer"
>
<el-button
type=
"primary"
@
click=
"salesmanUpate"
>
提交
</el-button>
</div>
</el-dialog>
</el-dialog>
</div>
</template>
...
...
@@ -829,7 +857,7 @@
import
axios
from
"
axios
"
;
import
{
getAllCategory
,
getAllcustomer
,
addcustomer
,
getAllProvince
,
allData
,
addPop
,
toUpdate
,
editcustomer
,
getCode
,
releaseFollowuprecord
,
followupData
,
searchContent
,
deleteFollowuprecord
,
modifyFollowuprecord
,
selectvalue
,
read
,
technicalDirector
editcustomer
,
getCode
,
releaseFollowuprecord
,
followupData
,
searchContent
,
deleteFollowuprecord
,
modifyFollowuprecord
,
selectvalue
,
read
,
technicalDirector
,
exportExcel
}
from
"
@/api/customer.js
"
;
import
{
getAllsupport
,
deliverList
,
changeMan
,
assignPresales
,
findWhereDeal
,
bandonmentRequest
}
from
"
@/api/newCustomer.js
"
;
import
{
parseTime
}
from
"
../../utils
"
;
...
...
@@ -863,6 +891,7 @@ export default {
//新增项目新增
addEntry
:{
entryName
:
''
,
//项目名称
erpOrderNo
:
''
,
//erp单号
specific
:
''
,
//需求描述
clientId
:
''
,
//客户id
flag
:
1
...
...
@@ -870,6 +899,7 @@ export default {
renewEntry
:{
entryName
:
''
,
//项目名称
erpOrderNo
:
''
,
//erp单号
specific
:
''
,
//需求描述
clientId
:
''
//客户id
},
...
...
@@ -901,6 +931,7 @@ export default {
giveUp
:
""
,
// 是否有效
giveorValid
:
""
,
dealStatus
:
""
,
// 是否成交
// 新增
addFormInfo
:{
title
:
'
新增客户
'
,
...
...
@@ -1038,6 +1069,7 @@ export default {
record
:
''
,
formItem
:{},
timeDifference
:{},
isErpOrderNo
:
false
,
},
// 跟进状态全部表格返显
flowupManage
:{
...
...
@@ -1118,6 +1150,7 @@ export default {
releaserules
:{
followStatus
:
[{
required
:
true
,
message
:
"
请选择跟进状态
"
,
trigger
:
"
blur
"
}],
//erpOrderNo: [{ required: true, message: "请选择ERP单号", trigger: "blur"}],
// followFiles: [{ required: true, message: "请上传文件", trigger: "blur"}],
remindTime
:
[{
required
:
true
,
message
:
"
请选择时间
"
,
trigger
:
"
blur
"
}],
followResult
:
[{
required
:
true
,
message
:
"
请输入跟进结果
"
,
trigger
:
"
blur
"
}],
...
...
@@ -1130,8 +1163,7 @@ export default {
},
bandonmentrules
:{
reason
:
[{
required
:
true
,
message
:
"
请输入废弃原因
"
,
trigger
:
"
change
"
}],
}
},
};
},
// 售前技术支持下拉框设置默认选项
...
...
@@ -1159,15 +1191,15 @@ export default {
methods
:
{
// 获取分类下拉列表
getSelectInfo
(){
var
typeM
=
this
.
typeManage
;
var
params
=
{
page
:
1
,
pageSize
:
999
,
};
getAllCategory
(
params
).
then
((
res
)
=>
{
var
dropDown
=
res
.
object
.
records
||
[];
typeM
.
dropData
=
dropDown
;
});
var
typeM
=
this
.
typeManage
;
var
params
=
{
page
:
1
,
pageSize
:
999
,
};
getAllCategory
(
params
).
then
((
res
)
=>
{
var
dropDown
=
res
.
object
.
records
||
[];
typeM
.
dropData
=
dropDown
;
});
},
// 表格加深颜色样式
tableRowClassName
({
row
,
rowIndex
})
{
...
...
@@ -1193,35 +1225,37 @@ export default {
});
},
//1.获取全部信息管理
allcustomer
(
params
){
var
typeM
=
this
.
typeManage
;
var
params
=
{
page
:
typeM
.
page
,
pageSize
:
typeM
.
size
,
};
getAllcustomer
(
params
).
then
((
res
)
=>
{
var
records
=
res
.
object
.
records
||
[];
typeM
.
tableData
=
records
;
typeM
.
total
=
res
.
object
.
total
;
});
},
handleSizeChange
(
val
)
{
// 每页多少条
this
.
typeManage
.
size
=
val
;
// this.allcustomer()
this
.
toSearch
();
},
handleCurrentChange
(
val
)
{
// 当前是多少页
this
.
typeManage
.
page
=
val
;
// this.allcustomer()
this
.
toSearch
();
},
//2.根据名称获取信息分类
toSearch
()
{
var
typeM
=
this
.
typeManage
;
allcustomer
(
params
){
var
typeM
=
this
.
typeManage
;
var
params
=
{
page
:
typeM
.
page
,
pageSize
:
typeM
.
size
,
};
searchContent
(
params
).
then
((
res
)
=>
{
var
records
=
res
.
object
.
records
||
[];
typeM
.
tableData
=
records
;
typeM
.
total
=
res
.
object
.
total
;
});
},
handleSizeChange
(
val
)
{
// 每页多少条
this
.
typeManage
.
size
=
val
;
// this.allcustomer()
this
.
loadData
(
this
.
typeManage
.
page
);
},
handleCurrentChange
(
val
)
{
// 当前是多少页
// this.allcustomer()
this
.
loadData
(
val
);
},
//2.根据名称获取信息分类
toSearch
(
page
)
{
this
.
loadData
();
},
loadData
(
page
){
var
typeM
=
this
.
typeManage
;
var
param
=
{
page
:
this
.
typeManage
.
page
,
page
:
page
||
0
,
pageSize
:
this
.
typeManage
.
size
,
// giveUp:this.giveorValid,
};
...
...
@@ -1229,18 +1263,19 @@ export default {
this
.
tel
&&
(
param
.
tel
=
this
.
tel
);
this
.
salesName
&&
(
param
.
salesName
=
this
.
salesName
);
this
.
className
&&
(
param
.
className
=
this
.
className
);
console
.
log
(
param
,
"
________
"
)
this
.
dealStatus
&&
(
param
.
dealStatus
=
this
.
dealStatus
);
// 时间
if
(
this
.
searchTime
instanceof
Array
)
{
param
.
startTime
=
parseTime
(
new
Date
(
this
.
searchTime
[
0
]));
param
.
endTime
=
parseTime
(
new
Date
(
this
.
searchTime
[
1
]));
}
searchContent
(
param
).
then
((
res
)
=>
{
//getAllcustomer(param).then((res) => {
var
selectlist
=
res
.
object
.
records
||
[];
typeM
.
tableData
=
selectlist
;
typeM
.
total
=
res
.
object
.
total
;
});
},
},
// 新增编辑客户信息
newlyAdd
(
type
,
e
,
index
,
item
){
if
(
type
===
'
edit
'
){
...
...
@@ -1410,6 +1445,7 @@ export default {
if
(
valid
)
{
var
params
=
{
project_name
:
this
.
addEntry
.
entryName
,
erpOrderNo
:
this
.
addEntry
.
erpOrderNo
,
project_remarks
:
this
.
addEntry
.
specific
,
customerid
:
this
.
addEntry
.
clientId
+
''
};
...
...
@@ -1436,6 +1472,7 @@ export default {
this
.
renewDialog
=
true
;
this
.
renewEntry
.
clientId
=
item
.
id
//客户id
this
.
renewEntry
.
entryName
=
item
.
projectName
//项目名称
this
.
renewEntry
.
erpOrderNo
=
item
.
erpOrderNo
//erp
this
.
renewEntry
.
specific
=
item
.
projectRemarks
//需求描述
},
renewUpate
(){
...
...
@@ -1443,6 +1480,7 @@ export default {
if
(
valid
)
{
var
params
=
{
project_name
:
this
.
renewEntry
.
entryName
,
erpOrderNo
:
this
.
renewEntry
.
erpOrderNo
,
project_remarks
:
this
.
renewEntry
.
specific
,
id
:
this
.
renewEntry
.
clientId
};
...
...
@@ -1521,7 +1559,7 @@ export default {
});
},
//计算时间差
timeDifc
(
start
,
end
){
timeDifc
(
start
,
end
){
var
startTime
,
endTime
;
if
(
this
.
flowupManage
.
flowupManagedata
!=
null
){
var
array
=
this
.
flowupManage
.
flowupManagedata
...
...
@@ -1549,7 +1587,6 @@ export default {
// 编辑跟踪记录
modifyRelease
(
type
,
item
){
console
.
log
(
"
dianle
"
,
this
.
flowup
)
if
(
this
.
flowup
.
from
.
projectId
){
this
.
flowup
.
reqType
=
type
;
for
(
var
i
=
0
;
i
<
this
.
Dict
.
followUpList
.
length
;
i
++
){
...
...
@@ -1572,14 +1609,15 @@ export default {
// 清空文件
this
.
$refs
.
fileRef
.
clearFiles
()
});
this
.
flowup
.
isErpOrderNo
=
false
;
}
else
{
this
.
flowup
.
title
=
'
编辑客户信息
'
;
this
.
modifyreleaseDialog
=
true
;
this
.
flowup
.
from
=
Object
.
assign
({},
item
);
this
.
showPrise
=
true
this
.
flowup
.
from
.
ifFileExist
=
0
;
console
.
log
(
this
.
flowup
.
from
,
"
编辑跟踪记录-----
"
)
this
.
flowup
.
isErpOrderNo
=
(
this
.
flowup
.
from
.
followStatus
===
3
);
console
.
log
(
this
.
flowup
.
from
,
"
编辑跟踪记录-----
"
);
}
}
else
{
...
...
@@ -1598,6 +1636,7 @@ export default {
if
(
valid
)
{
var
params
=
new
FormData
();
params
.
append
(
'
projectId
'
,
this
.
flowup
.
from
.
projectId
+
''
);
//项目id
this
.
flowup
.
from
.
erpOrderNo
&&
params
.
append
(
'
erpOrderNo
'
,
this
.
flowup
.
from
.
erpOrderNo
);
if
(
!
this
.
flowup
.
from
.
followFiles
){
delete
params
.
followFiles
}
else
{
...
...
@@ -1611,6 +1650,8 @@ export default {
new
Date
(
this
.
flowup
.
from
.
remindTime
)
);
params
.
append
(
'
remindTime
'
,
this
.
flowup
.
from
.
remindTime
);
//时间
releaseFollowuprecord
(
params
).
then
((
res
)
=>
{
this
.
modifyreleaseDialog
=
false
;
this
.
followDisplay
();
...
...
@@ -1625,21 +1666,22 @@ export default {
})
}
else
{
var
params
=
new
FormData
();
params
.
append
(
'
id
'
,
this
.
flowup
.
from
.
id
+
''
);
//项目id
if
(
this
.
flowup
.
from
.
ifFileExist
===
0
){
delete
params
.
followFiles
}
else
{
params
.
append
(
'
followFiles
'
,
this
.
flowup
.
from
.
followFiles
);
//文件.
}
params
.
append
(
'
followStatus
'
,
this
.
flowup
.
from
.
followStatus
);
//状态
params
.
append
(
'
followResult
'
,
this
.
flowup
.
from
.
followResult
);
//结果
params
.
append
(
'
ifFileExist
'
,
this
.
flowup
.
from
.
ifFileExist
);
//文件状态
// 时间
this
.
flowup
.
from
.
remindTime
=
this
.
toolformatTime
(
new
Date
(
this
.
flowup
.
from
.
remindTime
)
);
params
.
append
(
'
remindTime
'
,
this
.
flowup
.
from
.
remindTime
);
//时间
params
.
append
(
'
id
'
,
this
.
flowup
.
from
.
id
+
''
);
//项目id
this
.
flowup
.
from
.
erpOrderNo
&&
params
.
append
(
'
erpOrderNo
'
,
this
.
flowup
.
from
.
erpOrderNo
);
if
(
this
.
flowup
.
from
.
ifFileExist
===
0
){
delete
params
.
followFiles
}
else
{
params
.
append
(
'
followFiles
'
,
this
.
flowup
.
from
.
followFiles
);
//文件.
}
params
.
append
(
'
followStatus
'
,
this
.
flowup
.
from
.
followStatus
);
//状态
params
.
append
(
'
followResult
'
,
this
.
flowup
.
from
.
followResult
);
//结果
params
.
append
(
'
ifFileExist
'
,
this
.
flowup
.
from
.
ifFileExist
);
//文件状态
// 时间
this
.
flowup
.
from
.
remindTime
=
this
.
toolformatTime
(
new
Date
(
this
.
flowup
.
from
.
remindTime
)
);
params
.
append
(
'
remindTime
'
,
this
.
flowup
.
from
.
remindTime
);
//时间
modifyFollowuprecord
(
params
).
then
((
res
)
=>
{
this
.
modifyreleaseDialog
=
false
;
...
...
@@ -1741,127 +1783,188 @@ export default {
this
.
handoverDialog
=
true
},
deliverUpate
(){
this
.
$refs
.
handpeopleRef
.
validate
((
valid
)
=>
{
if
(
valid
)
{
var
params
=
{
id
:
this
.
addEntry
.
clientId
,
newUserId
:
this
.
salesPersonnelfrom
.
changesalesman
,
};
var
self
=
this
;
changeMan
(
params
).
then
((
res
)
=>
{
this
.
handoverDialog
=
false
;
self
.
$message
({
type
:
"
success
"
,
message
:
"
转交销售人员成功
"
,
});
window
.
location
.
reload
();
},
()
=>
{
this
.
$message
.
error
(
"
转交销售人员失败
"
);
}
);
}
})
},
//指派售前人员弹窗
saleAssign
(){
this
.
assignDialog
=
true
;
},
salesmanUpate
(){
this
.
$refs
.
saleEngineerRef
.
validate
((
valid
)
=>
{
if
(
valid
)
{
this
.
handoverSalemanfrom
.
userId
=
this
.
$store
.
getters
.
user
.
id
;
var
params
=
{
userId
:
this
.
handoverSalemanfrom
.
userId
,
leaderId
:
this
.
handoverSalemanfrom
.
salesman
,
projectId
:
this
.
handoverSalemanfrom
.
entryName
,
description
:
this
.
handoverSalemanfrom
.
description
,
};
var
self
=
this
;
assignPresales
(
params
).
then
((
res
)
=>
{
this
.
assignDialog
=
false
;
self
.
$message
({
type
:
"
success
"
,
message
:
"
指派售前人员成功
"
,
},
()
=>
{
this
.
$message
.
error
(
"
指派售前人员失败
"
);
}
);
});
}
})
},
// 项目成交记录接口
projectTransactionRecord
(){
var
params
=
{
page
:
this
.
projectTransaction
.
page
,
pageSize
:
this
.
projectTransaction
.
size
,
customerId
:
this
.
addEntry
.
clientId
};
findWhereDeal
(
params
).
then
((
res
)
=>
{
this
.
projectTransaction
.
tableTwoData
=
res
.
object
.
records
this
.
projectTransaction
.
total
=
res
.
object
.
total
});
},
//获取全部信息管理分页
projectTransactionChange
(
val
)
{
// 每页多少条
this
.
projectTransaction
.
size
=
val
;
this
.
projectTransactionRecord
();
},
projectTransactionCurrentChange
(
val
)
{
// 当前是多少页
this
.
projectTransaction
.
page
=
val
;
this
.
projectTransactionRecord
();
},
// 废弃弹窗
bandonment
(){
this
.
bandonmentDialog
=
true
;
},
bandonmentUpate
(){
this
.
$refs
.
bandonmentData
.
validate
((
valid
)
=>
{
this
.
$refs
.
handpeopleRef
.
validate
((
valid
)
=>
{
if
(
valid
)
{
console
.
log
(
'
validate ________________
'
,
this
.
addEntry
);
var
params
=
{
id
:
this
.
addEntry
.
clientId
,
giveUpResult
:
this
.
bandonmentEntry
.
reaso
n
,
id
:
this
.
addEntry
.
clientId
,
newUserId
:
this
.
salesPersonnelfrom
.
changesalesma
n
,
};
var
self
=
this
;
bandonmentRequest
(
params
).
then
((
res
)
=>
{
this
.
bandonment
Dialog
=
false
;
changeMan
(
params
).
then
((
res
)
=>
{
this
.
handover
Dialog
=
false
;
self
.
$message
({
type
:
"
success
"
,
message
:
"
废弃成功
"
,
},
()
=>
{
this
.
$message
.
error
(
"
废弃失败
"
);
}
);
});
message
:
"
转交销售人员成功
"
,
});
window
.
location
.
reload
();
},
()
=>
{
this
.
$message
.
error
(
"
转交销售人员失败
"
);
}
);
}
})
},
//指派售前人员弹窗
saleAssign
(){
this
.
assignDialog
=
true
;
},
salesmanUpate
(){
this
.
$refs
.
saleEngineerRef
.
validate
((
valid
)
=>
{
if
(
valid
)
{
this
.
handoverSalemanfrom
.
userId
=
this
.
$store
.
getters
.
user
.
id
;
var
params
=
{
userId
:
this
.
handoverSalemanfrom
.
userId
,
leaderId
:
this
.
handoverSalemanfrom
.
salesman
,
projectId
:
this
.
handoverSalemanfrom
.
entryName
,
description
:
this
.
handoverSalemanfrom
.
description
,
};
var
self
=
this
;
assignPresales
(
params
).
then
((
res
)
=>
{
this
.
assignDialog
=
false
;
self
.
$message
({
type
:
"
success
"
,
message
:
"
指派售前人员成功
"
,
},
()
=>
{
this
.
$message
.
error
(
"
指派售前人员失败
"
);
}
})
},
// 默认勾选
singleElection
(
row
)
{
this
.
templateSelection
=
row
.
id
this
.
checkList
=
this
.
addManage
.
addManagedata
.
filter
((
item
)
=>
item
.
id
===
row
.
id
)
this
.
flowup
.
from
.
projectId
=
row
.
id
;
this
.
followDisplay
()
},
// 文件下载与图片预览
upateFile
(
val
){
if
(
val
){
window
.
open
(
'
http://oa.gemho.cn:8004/project_follow_file/
'
+
val
);
}
else
{
this
.
$notify
({
title
:
'
未找到文件或图片!
'
,
type
:
'
error
'
,
duration
:
3500
});
}
);
});
}
})
},
// 项目成交记录接口
projectTransactionRecord
(){
var
params
=
{
page
:
this
.
projectTransaction
.
page
,
pageSize
:
this
.
projectTransaction
.
size
,
customerId
:
this
.
addEntry
.
clientId
};
findWhereDeal
(
params
).
then
((
res
)
=>
{
this
.
projectTransaction
.
tableTwoData
=
res
.
object
.
records
this
.
projectTransaction
.
total
=
res
.
object
.
total
});
},
//获取全部信息管理分页
projectTransactionChange
(
val
)
{
// 每页多少条
this
.
projectTransaction
.
size
=
val
;
this
.
projectTransactionRecord
();
},
projectTransactionCurrentChange
(
val
)
{
// 当前是多少页
this
.
projectTransaction
.
page
=
val
;
this
.
projectTransactionRecord
();
},
// 废弃弹窗
bandonment
(){
this
.
bandonmentDialog
=
true
;
},
bandonmentUpate
(){
this
.
$refs
.
bandonmentData
.
validate
((
valid
)
=>
{
if
(
valid
)
{
var
params
=
{
id
:
this
.
addEntry
.
clientId
,
giveUpResult
:
this
.
bandonmentEntry
.
reason
,
};
var
self
=
this
;
bandonmentRequest
(
params
).
then
((
res
)
=>
{
this
.
bandonmentDialog
=
false
;
self
.
$message
({
type
:
"
success
"
,
message
:
"
废弃成功
"
,
},
()
=>
{
this
.
$message
.
error
(
"
废弃失败
"
);
}
);
});
}
})
},
// 默认勾选
singleElection
(
row
)
{
this
.
templateSelection
=
row
.
id
this
.
checkList
=
this
.
addManage
.
addManagedata
.
filter
((
item
)
=>
item
.
id
===
row
.
id
)
this
.
flowup
.
from
.
projectId
=
row
.
id
;
this
.
followDisplay
()
},
// 文件下载与图片预览
upateFile
(
val
){
if
(
val
){
window
.
open
(
'
http://oa.gemho.cn:8004/project_follow_file/
'
+
val
);
}
else
{
this
.
$notify
({
title
:
'
未找到文件或图片!
'
,
type
:
'
error
'
,
duration
:
3500
});
}
},
};
},
reqExportExcel
(){
var
param
=
{
tel
:
this
.
tel
,
className
:
this
.
className
,
salesName
:
this
.
salesName
,
dealStatus
:
this
.
dealStatus
,
giveUp
:
this
.
giveUp
,
page
:
this
.
typeManage
.
page
,
pageSize
:
this
.
typeManage
.
size
,
};
// 时间
if
(
this
.
searchTime
instanceof
Array
)
{
param
.
startTime
=
parseTime
(
new
Date
(
this
.
searchTime
[
0
]));
param
.
endTime
=
parseTime
(
new
Date
(
this
.
searchTime
[
1
]));
}
exportExcel
(
param
).
then
((
res
)
=>
{
if
(
res
.
code
===
200
){
window
.
open
(
'
oa.gemho.cn:8004/customer_follow_form/
'
+
res
.
object
);
}
else
{
this
.
$message
.
error
(
"
导出异常!
"
);
};
/* var downloadFile = function(obj, name, suffix){
var url = window.URL.createObjectURL(new Blob([obj]));
var link = document.createElement('a');
link.style.display = 'none';
link.href = url;
var fileName = name + '.' + suffix;
link.setAttribute('download', fileName);
document.body.appendChild(link);
link.click();
document.body.removeChild(link);
};
var name = '客户信息管理' + new Date().getTime();
downloadFile(res, name, 'xlsx') */
});
},
// 重新分配
restartConfig
(
row
){
this
.
addEntry
.
clientId
=
row
.
id
;
/* var params = {
id:this.addEntry.clientId,
newUserId:this.salesPersonnelfrom.changesalesman,
}; */
console
.
log
(
'
row ________________
'
,
row
,
this
.
addEntry
);
this
.
handoverDialog
=
true
},
isErpOnchange
(
e
){
this
.
flowup
.
isErpOrderNo
=
(
e
===
3
)
console
.
log
(
'
isErpOnchange ________________
'
,
e
);
},
},
};
</
script
>
<
style
lang=
"scss"
scoped
>
.search-wrapper
{
...
...
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