Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Y
ydLife
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Sweet Zhang
ydLife
Commits
0b73e3aa
Commit
0b73e3aa
authored
May 26, 2020
by
Chao Sun
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
团队成员分值显示
parent
b0b131ba
Hide whitespace changes
Inline
Side-by-side
Showing
24 changed files
with
474 additions
and
137 deletions
+474
-137
src/app/common/life-common.module.ts
+1
-0
src/app/common/life-common.service.ts
+9
-0
src/app/common/pipe/switch-number.pipe.spec.ts
+8
-0
src/app/common/pipe/switch-number.pipe.ts
+42
-0
src/app/domain/recruitingQuery.ts
+3
-1
src/app/my/my-business-detail/my-business-detail.component.html
+14
-14
src/app/my/my-business-detail/my-business-detail.component.ts
+3
-1
src/app/my/my-center-home/my-center-home.component.html
+4
-2
src/app/my/my-center-home/my-center-home.component.ts
+1
-1
src/app/my/my-routing.module.ts
+3
-2
src/app/my/my-target/my-target.component.html
+5
-5
src/app/my/my-target/my-target.component.ts
+62
-60
src/app/my/my.module.ts
+3
-2
src/app/my/my.service.ts
+22
-1
src/app/my/recruiting-detail/recruiting-detail.component.html
+8
-3
src/app/my/team-panel/team-panel.component.html
+35
-34
src/app/my/team-panel/team-panel.component.scss
+10
-5
src/app/my/team-panel/team-panel.component.ts
+76
-3
src/app/my/team-rank/team-rank.component.scss
+2
-1
src/app/my/team-rank/team-rank.component.ts
+3
-2
src/app/my/team-sales-score/team-sales-score.component.html
+38
-0
src/app/my/team-sales-score/team-sales-score.component.scss
+56
-0
src/app/my/team-sales-score/team-sales-score.component.spec.ts
+25
-0
src/app/my/team-sales-score/team-sales-score.component.ts
+41
-0
No files found.
src/app/common/life-common.module.ts
View file @
0b73e3aa
...
@@ -5,6 +5,7 @@ import { FormsModule } from "@angular/forms";
...
@@ -5,6 +5,7 @@ import { FormsModule } from "@angular/forms";
import
{
GuidePageComponent
}
from
'./guide-page/guide-page.component'
;
import
{
GuidePageComponent
}
from
'./guide-page/guide-page.component'
;
import
{
SafeHtmlPipe
}
from
'./safe-html.pipe'
;
import
{
SafeHtmlPipe
}
from
'./safe-html.pipe'
;
@
NgModule
({
@
NgModule
({
declarations
:
[
AlertComponent
,
GuidePageComponent
,
SafeHtmlPipe
],
declarations
:
[
AlertComponent
,
GuidePageComponent
,
SafeHtmlPipe
],
imports
:
[
imports
:
[
...
...
src/app/common/life-common.service.ts
View file @
0b73e3aa
...
@@ -177,4 +177,13 @@ export class LifeCommonService {
...
@@ -177,4 +177,13 @@ export class LifeCommonService {
let
L
=
appU
[
appU
.
length
-
1
];
let
L
=
appU
[
appU
.
length
-
1
];
return
L
;
return
L
;
}
}
toPercent
(
point
)
{
if
(
point
==
0
)
{
return
0
;
}
var
str
=
Number
(
point
*
100
).
toFixed
();
str
+=
"%"
;
return
str
;
}
}
}
src/app/common/pipe/switch-number.pipe.spec.ts
0 → 100644
View file @
0b73e3aa
import
{
SwitchNumberPipe
}
from
'./switch-number.pipe'
;
describe
(
'SwitchNumberPipe'
,
()
=>
{
it
(
'create an instance'
,
()
=>
{
const
pipe
=
new
SwitchNumberPipe
();
expect
(
pipe
).
toBeTruthy
();
});
});
src/app/common/pipe/switch-number.pipe.ts
0 → 100644
View file @
0b73e3aa
import
{
Pipe
,
PipeTransform
}
from
'@angular/core'
;
@
Pipe
({
name
:
'switchNumber'
})
export
class
SwitchNumberPipe
implements
PipeTransform
{
transform
(
value
:
any
,
args
?:
any
):
any
{
if
((
value
+
""
).
trim
()
==
""
)
{
return
""
;
}
if
(
typeof
value
==
'string'
)
{
value
=
value
.
replace
(
/,/gi
,
''
);
}
if
((
value
+
""
).
trim
()
==
""
)
{
return
""
;
}
if
(
isNaN
(
value
))
{
return
""
;
}
value
=
value
+
""
;
if
(
/^.*
\.
.*$/
.
test
(
value
))
{
let
pointIndex
=
value
.
lastIndexOf
(
"."
);
let
intPart
=
value
.
substring
(
0
,
pointIndex
);
let
pointPart
=
value
.
substring
(
pointIndex
+
1
,
value
.
length
);
intPart
=
intPart
+
""
;
const
re
=
/
(
-
?\d
+
)(\d{3})
/
while
(
re
.
test
(
intPart
))
{
intPart
=
intPart
.
replace
(
re
,
"$1,$2"
)
}
value
=
intPart
+
"."
+
pointPart
;
}
else
{
value
=
value
+
""
;
var
re
=
/
(
-
?\d
+
)(\d{3})
/
while
(
re
.
test
(
value
))
{
value
=
value
.
replace
(
re
,
"$1,$2"
)
}
}
return
value
;
}
}
src/app/domain/recruitingQuery.ts
View file @
0b73e3aa
...
@@ -14,7 +14,8 @@ export class RecruitingQuery {
...
@@ -14,7 +14,8 @@ export class RecruitingQuery {
public
operateUserId
?:
string
,
public
operateUserId
?:
string
,
public
potentialId
?:
any
,
public
potentialId
?:
any
,
public
practitionerId
?:
any
,
public
practitionerId
?:
any
,
public
createdAt
?:
any
public
createdAt
?:
any
,
public
timeToOnboarding
?:
any
)
{
)
{
}
}
}
}
\ No newline at end of file
src/app/my/my-business-detail/my-business-detail.component.html
View file @
0b73e3aa
...
@@ -16,12 +16,12 @@
...
@@ -16,12 +16,12 @@
<div
class=
"contentItem"
>
<div
class=
"contentItem"
>
<span>
姓名
</span>
<span>
姓名
</span>
<input
class=
"form-control"
type=
"text"
placeholder=
"{{readonlyFlag ?'暂无姓名':'请输入姓名'}}"
<input
class=
"form-control"
type=
"text"
placeholder=
"{{readonlyFlag ?'暂无姓名':'请输入姓名'}}"
[(
ngModel
)]="
editBusiness
.
name
"
[
disabled
]="
readonlyFlag
"
/>
[(
ngModel
)]="
editBusiness
.
name
"
[
disabled
]="
readonlyFlag
"
(
blur
)="
inputBlur
()"
/>
</div>
</div>
<div
class=
"contentItem"
>
<div
class=
"contentItem"
>
<span>
年龄
</span>
<span>
年龄
</span>
<input
class=
"form-control"
type=
"text"
placeholder=
"{{readonlyFlag ?'暂无年龄信息':'请输入年龄'}}"
<input
class=
"form-control"
type=
"text"
placeholder=
"{{readonlyFlag ?'暂无年龄信息':'请输入年龄'}}"
[(
ngModel
)]="
editBusiness
.
age
"
[
disabled
]="
readonlyFlag
"
/>
[(
ngModel
)]="
editBusiness
.
age
"
[
disabled
]="
readonlyFlag
"
(
blur
)="
inputBlur
()"
/>
</div>
</div>
<div
class=
"contentItem"
>
<div
class=
"contentItem"
>
<span>
性别
</span>
<span>
性别
</span>
...
@@ -43,7 +43,7 @@
...
@@ -43,7 +43,7 @@
<div
class=
"contentItem"
>
<div
class=
"contentItem"
>
<span>
血型
</span>
<span>
血型
</span>
<select
name=
"bloodTypeId"
id=
"bloodTypeId"
class=
"form-control"
[
disabled
]="
readonlyFlag
"
<select
name=
"bloodTypeId"
id=
"bloodTypeId"
class=
"form-control"
[
disabled
]="
readonlyFlag
"
[(
ngModel
)]="
editBusiness
.
bloodTypeId
"
>
[(
ngModel
)]="
editBusiness
.
bloodTypeId
"
(
blur
)="
inputBlur
()"
>
<option
value=
""
>
{{readonlyFlag ?'暂无血型信息':'请选择血型'}}
</option>
<option
value=
""
>
{{readonlyFlag ?'暂无血型信息':'请选择血型'}}
</option>
<option
*
ngFor=
"let businessBloodItem of businessBloodList"
[
value
]="
businessBloodItem
.
id
"
>
<option
*
ngFor=
"let businessBloodItem of businessBloodList"
[
value
]="
businessBloodItem
.
id
"
>
{{businessBloodItem.dropOptionName}}
</option>
{{businessBloodItem.dropOptionName}}
</option>
...
@@ -54,7 +54,7 @@
...
@@ -54,7 +54,7 @@
<div
class=
"contentItem"
>
<div
class=
"contentItem"
>
<span>
星座
</span>
<span>
星座
</span>
<select
name=
"businessZodiacId"
id=
"businessZodiacId"
class=
"form-control"
[
disabled
]="
readonlyFlag
"
<select
name=
"businessZodiacId"
id=
"businessZodiacId"
class=
"form-control"
[
disabled
]="
readonlyFlag
"
[(
ngModel
)]="
editBusiness
.
zodiacTypeId
"
>
[(
ngModel
)]="
editBusiness
.
zodiacTypeId
"
(
blur
)="
inputBlur
()"
>
<option
value=
""
>
{{readonlyFlag ?'暂无星座信息':'请选择星座'}}
</option>
<option
value=
""
>
{{readonlyFlag ?'暂无星座信息':'请选择星座'}}
</option>
<option
*
ngFor=
"let businessZodiacItem of businessZodiacList"
[
value
]="
businessZodiacItem
.
id
"
>
<option
*
ngFor=
"let businessZodiacItem of businessZodiacList"
[
value
]="
businessZodiacItem
.
id
"
>
{{businessZodiacItem.dropOptionName}}
</option>
{{businessZodiacItem.dropOptionName}}
</option>
...
@@ -71,7 +71,7 @@
...
@@ -71,7 +71,7 @@
<i
class=
"iconfont icon-dianhua"
style=
"color: #e10d0d;"
></i>
<i
class=
"iconfont icon-dianhua"
style=
"color: #e10d0d;"
></i>
{{editBusiness.mobileNo}}
</a>
{{editBusiness.mobileNo}}
</a>
<input
class=
"form-control"
type=
"text"
[(
ngModel
)]="
editBusiness
.
mobileNo
"
*
ngIf=
"opportunityId==0"
<input
class=
"form-control"
type=
"text"
[(
ngModel
)]="
editBusiness
.
mobileNo
"
*
ngIf=
"opportunityId==0"
placeholder=
"请输入手机号"
maxlength=
"11"
/>
placeholder=
"请输入手机号"
maxlength=
"11"
(
blur
)="
inputBlur
()"
/>
</div>
</div>
<div
class=
"contentItem"
>
<div
class=
"contentItem"
>
<span>
微信
</span>
<span>
微信
</span>
...
@@ -90,29 +90,29 @@
...
@@ -90,29 +90,29 @@
<div
class=
"contentItem"
>
<div
class=
"contentItem"
>
<span>
预计FYP
</span>
<span>
预计FYP
</span>
<input
class=
"form-control"
type=
"number"
placeholder=
"{{readonlyFlag ?'暂无预计FYP':'请输入预计FYP'}}"
<input
class=
"form-control"
type=
"number"
placeholder=
"{{readonlyFlag ?'暂无预计FYP':'请输入预计FYP'}}"
[
disabled
]="
readonlyFlag
"
[(
ngModel
)]="
editBusiness
.
fyp
"
/>
[
disabled
]="
readonlyFlag
"
[(
ngModel
)]="
editBusiness
.
fyp
"
(
blur
)="
inputBlur
()"
/>
</div>
</div>
<div
class=
"contentItem"
>
<div
class=
"contentItem"
>
<span>
预计FYC
</span>
<span>
预计FYC
</span>
<input
class=
"form-control"
type=
"number"
placeholder=
"{{readonlyFlag ?'暂无预计FYC':'请输入预计FYC'}}"
<input
class=
"form-control"
type=
"number"
placeholder=
"{{readonlyFlag ?'暂无预计FYC':'请输入预计FYC'}}"
[
disabled
]="
readonlyFlag
"
[(
ngModel
)]="
editBusiness
.
fyc
"
/>
[
disabled
]="
readonlyFlag
"
[(
ngModel
)]="
editBusiness
.
fyc
"
(
blur
)="
inputBlur
()"
/>
</div>
</div>
<div
class=
"contentItem"
>
<div
class=
"contentItem"
>
<span>
预计成交件数
</span>
<span>
预计成交件数
</span>
<input
class=
"form-control"
type=
"number"
placeholder=
"{{readonlyFlag ?'暂无预计件数':'请输入预计件数'}}"
<input
class=
"form-control"
type=
"number"
placeholder=
"{{readonlyFlag ?'暂无预计件数':'请输入预计件数'}}"
[
disabled
]="
readonlyFlag
"
[(
ngModel
)]="
editBusiness
.
pieces
"
/>
[
disabled
]="
readonlyFlag
"
[(
ngModel
)]="
editBusiness
.
pieces
"
(
blur
)="
inputBlur
()"
/>
</div>
</div>
<div
class=
"contentItem"
>
<div
class=
"contentItem"
>
<span>
预计成交时间
</span>
<span>
预计成交时间
</span>
<input
class=
"form-control"
type=
"date"
placeholder=
"{{readonlyFlag ?'暂无预计成交时间':'请输入预计成交时间'}}"
<input
class=
"form-control"
type=
"date"
placeholder=
"{{readonlyFlag ?'暂无预计成交时间':'请输入预计成交时间'}}"
[
disabled
]="
readonlyFlag
"
[(
ngModel
)]="
editBusiness
.
timeToClose
"
/>
[
disabled
]="
readonlyFlag
"
[(
ngModel
)]="
editBusiness
.
timeToClose
"
(
blur
)="
inputBlur
()"
/>
</div>
</div>
</div>
</div>
<div
class=
"wrapper_item"
>
<div
class=
"wrapper_item"
>
<div
class=
"contentItem"
>
<div
class=
"contentItem"
>
<span>
商机来源
</span>
<span>
商机来源
</span>
<select
*
ngIf=
"opportunityId==0"
name=
"businessSourceId"
id=
"businessSourceId"
class=
"form-control"
<select
*
ngIf=
"opportunityId==0"
name=
"businessSourceId"
id=
"businessSourceId"
class=
"form-control"
[(
ngModel
)]="
editBusiness
.
sourceFrom
"
[
disabled
]="
readonlyFlag
"
>
[(
ngModel
)]="
editBusiness
.
sourceFrom
"
[
disabled
]="
readonlyFlag
"
(
blur
)="
inputBlur
()"
>
<option
value=
""
>
{{readonlyFlag ?'暂无商机来源':'请选择商机来源'}}
</option>
<option
value=
""
>
{{readonlyFlag ?'暂无商机来源':'请选择商机来源'}}
</option>
<option
*
ngFor=
"let businessSourceItem of businessSourceList"
[
value
]="
businessSourceItem
.
id
"
>
<option
*
ngFor=
"let businessSourceItem of businessSourceList"
[
value
]="
businessSourceItem
.
id
"
>
{{businessSourceItem.dropOptionName}}
</option>
{{businessSourceItem.dropOptionName}}
</option>
...
@@ -142,7 +142,7 @@
...
@@ -142,7 +142,7 @@
<span>
备注
</span>
<span>
备注
</span>
<div
style=
"padding: 6px 15px;padding: 6px 15px;"
>
<div
style=
"padding: 6px 15px;padding: 6px 15px;"
>
<input
class=
"form-control"
type=
"text"
[
disabled
]="
readonlyFlag
"
[(
ngModel
)]="
editBusiness
.
remark
"
<input
class=
"form-control"
type=
"text"
[
disabled
]="
readonlyFlag
"
[(
ngModel
)]="
editBusiness
.
remark
"
placeholder=
"备注信息"
/>
placeholder=
"备注信息"
(
blur
)="
inputBlur
()"
/>
</div>
</div>
</div>
</div>
</div>
</div>
...
@@ -191,15 +191,15 @@
...
@@ -191,15 +191,15 @@
(
click
)="
ownOpportunityRecordSave
(
opportunityRecordItem
)"
></i>
(
click
)="
ownOpportunityRecordSave
(
opportunityRecordItem
)"
></i>
</div>
</div>
</li>
</li>
<li>
<
!-- <
li>
<div class="salesNotice">{{(editBusiness.opportunityDate).substr(0,10)}}</div>
<div class="salesNotice">{{(editBusiness.opportunityDate).substr(0,10)}}</div>
<div style="display: flex;justify-content: space-between;">
<div style="display: flex;justify-content: space-between;">
<div>商机状态</div>
<div>商机状态</div>
<div>待跟进</div>
<div>待跟进</div>
</div>
</div>
</li>
</li>
-->
</ul>
</ul>
<div
class=
"add"
(
click
)="
showToast
()"
>
<div
class=
"add"
*
ngIf=
"status==0"
(
click
)="
showToast
()"
>
<!-- <i class="iconfont icon-jia" (click)="ownOpportunityRecordSave()"></i> -->
<!-- <i class="iconfont icon-jia" (click)="ownOpportunityRecordSave()"></i> -->
<i
class=
"iconfont icon-jiahao"
></i>
<i
class=
"iconfont icon-jiahao"
></i>
</div>
</div>
...
...
src/app/my/my-business-detail/my-business-detail.component.ts
View file @
0b73e3aa
...
@@ -61,6 +61,7 @@ export class MyBusinessDetailComponent implements OnInit {
...
@@ -61,6 +61,7 @@ export class MyBusinessDetailComponent implements OnInit {
//控制tab可不可点
//控制tab可不可点
clickFlag
:
boolean
;
clickFlag
:
boolean
;
remarkId
:
any
;
remarkId
:
any
;
status
:
any
;
constructor
(
private
activateRoute
:
ActivatedRoute
,
private
myService
:
MyService
,
constructor
(
private
activateRoute
:
ActivatedRoute
,
private
myService
:
MyService
,
public
lifeCommonService
:
LifeCommonService
,
private
router
:
Router
,
)
{
public
lifeCommonService
:
LifeCommonService
,
private
router
:
Router
,
)
{
this
.
titleList
=
[
this
.
titleList
=
[
...
@@ -140,8 +141,9 @@ export class MyBusinessDetailComponent implements OnInit {
...
@@ -140,8 +141,9 @@ export class MyBusinessDetailComponent implements OnInit {
this
.
opportunitySurveyAnswersList
=
res
[
'data'
][
'opportunityConsultationInfo'
][
'opportunitySurveyAnswersList'
]
this
.
opportunitySurveyAnswersList
=
res
[
'data'
][
'opportunityConsultationInfo'
][
'opportunitySurveyAnswersList'
]
this
.
editBusiness
=
res
[
'data'
][
'opportunityBasicInformationInfo'
];
this
.
editBusiness
=
res
[
'data'
][
'opportunityBasicInformationInfo'
];
this
.
opportunityCustomerTags
=
res
[
'data'
][
'opportunityBasicInformationInfo'
][
'opportunityCustomerTags'
]
this
.
opportunityCustomerTags
=
res
[
'data'
][
'opportunityBasicInformationInfo'
][
'opportunityCustomerTags'
]
this
.
opportunityRecordInfos
=
res
[
'data'
][
'opportunityRecordInfos'
];
this
.
opportunityRecordInfos
=
res
[
'data'
][
'opportunityRecord
SituationInfo'
][
'opportunityRecord
Infos'
];
this
.
isCompletedQuestionnaire
=
res
[
'data'
][
'opportunityConsultationInfo'
][
'isCompletedQuestionnaire'
];
this
.
isCompletedQuestionnaire
=
res
[
'data'
][
'opportunityConsultationInfo'
][
'isCompletedQuestionnaire'
];
this
.
status
=
res
[
'data'
][
'opportunityRecordSituationInfo'
][
'status'
];
//如果没有性别显示暂无性别
//如果没有性别显示暂无性别
if
(
!
res
[
'data'
][
'opportunityBasicInformationInfo'
][
'gender'
])
{
if
(
!
res
[
'data'
][
'opportunityBasicInformationInfo'
][
'gender'
])
{
this
.
sexFlag
=
false
;
this
.
sexFlag
=
false
;
...
...
src/app/my/my-center-home/my-center-home.component.html
View file @
0b73e3aa
...
@@ -100,9 +100,11 @@
...
@@ -100,9 +100,11 @@
<li
class=
"markPrice"
>
{{this.activities_grade?.scoreWeek}}
</li>
<li
class=
"markPrice"
>
{{this.activities_grade?.scoreWeek}}
</li>
<li
class=
"markPrice"
>
{{this.activities_grade?.scoreMonth}}
</li>
<li
class=
"markPrice"
>
{{this.activities_grade?.scoreMonth}}
</li>
<li
class=
"markPrice"
>
<li
class=
"markPrice"
>
{{this.activities_grade?.achievementRateWeek!=null ? this.activities_grade?.achievementRateWeek:'-'}}
</li>
{{this.activities_grade?.achievementRateWeek!=null ? lifeCommonService.toPercent(this.activities_grade?.achievementRateWeek) :'-'}}
</li>
<li
class=
"markPrice"
>
<li
class=
"markPrice"
>
{{this.activities_grade?.achievementRateMonth!=null ?this.activities_grade?.achievementRateMonth :'-'}}
</li>
{{this.activities_grade?.achievementRateMonth!=null ? lifeCommonService.toPercent(this.activities_grade?.achievementRateMonth) :'-'}}
</li>
<li
class=
"markPrice"
>
{{this.activities_grade?.addOpportunityNum}}
</li>
<li
class=
"markPrice"
>
{{this.activities_grade?.addOpportunityNum}}
</li>
</ul>
</ul>
</div>
</div>
...
...
src/app/my/my-center-home/my-center-home.component.ts
View file @
0b73e3aa
...
@@ -37,7 +37,7 @@ export class MyCenterHomeComponent implements OnInit, AfterViewInit {
...
@@ -37,7 +37,7 @@ export class MyCenterHomeComponent implements OnInit, AfterViewInit {
constructor
(
constructor
(
private
router
:
Router
,
private
router
:
Router
,
p
rivate
lifeCommonService
:
LifeCommonService
,
p
ublic
lifeCommonService
:
LifeCommonService
,
private
myService
:
MyService
,
private
myService
:
MyService
,
private
ls
:
LocalStorage
,
private
ls
:
LocalStorage
,
private
activatedRoute
:
ActivatedRoute
,
private
activatedRoute
:
ActivatedRoute
,
...
...
src/app/my/my-routing.module.ts
View file @
0b73e3aa
...
@@ -20,6 +20,7 @@ import { MySettingDetailComponent } from './my-setting-detail/my-setting-detail.
...
@@ -20,6 +20,7 @@ import { MySettingDetailComponent } from './my-setting-detail/my-setting-detail.
import
{
MyNewsComponent
}
from
'./my-news/my-news.component'
;
import
{
MyNewsComponent
}
from
'./my-news/my-news.component'
;
import
{
MyTargetComponent
}
from
"./my-target/my-target.component"
;
import
{
MyTargetComponent
}
from
"./my-target/my-target.component"
;
import
{
TeamPanelComponent
}
from
'./team-panel/team-panel.component'
;
import
{
TeamPanelComponent
}
from
'./team-panel/team-panel.component'
;
import
{
TeamSalesScoreComponent
}
from
'./team-sales-score/team-sales-score.component'
;
const
myRoutes
:
Routes
=
[
const
myRoutes
:
Routes
=
[
{
path
:
''
,
component
:
MyCenterHomeComponent
,
canActivate
:
[
AuthGuard
],
data
:
[{
title
:
'银盾保险经纪 - 工作台'
}]
},
{
path
:
''
,
component
:
MyCenterHomeComponent
,
canActivate
:
[
AuthGuard
],
data
:
[{
title
:
'银盾保险经纪 - 工作台'
}]
},
...
@@ -41,8 +42,8 @@ const myRoutes: Routes = [
...
@@ -41,8 +42,8 @@ const myRoutes: Routes = [
{
path
:
'setting/:uploadType'
,
component
:
MySettingDetailComponent
,
canActivate
:
[
AuthGuard
]
},
{
path
:
'setting/:uploadType'
,
component
:
MySettingDetailComponent
,
canActivate
:
[
AuthGuard
]
},
{
path
:
'news'
,
component
:
MyNewsComponent
,
canActivate
:
[
AuthGuard
]
},
{
path
:
'news'
,
component
:
MyNewsComponent
,
canActivate
:
[
AuthGuard
]
},
{
path
:
'target'
,
component
:
MyTargetComponent
,
canActivate
:
[
AuthGuard
]
},
{
path
:
'target'
,
component
:
MyTargetComponent
,
canActivate
:
[
AuthGuard
]
},
{
path
:
'teamPanel'
,
component
:
TeamPanelComponent
,
canActivate
:
[
AuthGuard
]
}
{
path
:
'teamPanel'
,
component
:
TeamPanelComponent
,
canActivate
:
[
AuthGuard
]
}
,
{
path
:
'teamPanel/:type'
,
component
:
TeamSalesScoreComponent
,
canActivate
:
[
AuthGuard
]
}
];
];
@
NgModule
({
@
NgModule
({
...
...
src/app/my/my-target/my-target.component.html
View file @
0b73e3aa
...
@@ -21,7 +21,7 @@
...
@@ -21,7 +21,7 @@
<div
class=
"title"
>
个人年度销售目标
</div>
<div
class=
"title"
>
个人年度销售目标
</div>
<div
class=
"content_target_item"
>
<div
class=
"content_target_item"
>
<span>
首年保费FYP
</span>
<span>
首年保费FYP
</span>
<input
class=
"form-control"
type=
"text"
[(
ngModel
)]="
premium
"
(
ngModelChange
)="
getMonthAverage
('
premium
')"
<input
class=
"form-control"
type=
"text"
[(
ngModel
)]="
premium
"
(
ngModelChange
)="
getMonthAverage
('
premium
')
;
"
(
blur
)="
inputBlur
()"
placeholder=
"{{personalSalesReadonlyFlag?'暂无预计年保费':'请输入预计年保费'}}"
(
blur
)="
inputBlur
()"
placeholder=
"{{personalSalesReadonlyFlag?'暂无预计年保费':'请输入预计年保费'}}"
[
disabled
]="
personalSalesReadonlyFlag
"
/>
[
disabled
]="
personalSalesReadonlyFlag
"
/>
</div>
</div>
...
@@ -52,8 +52,8 @@
...
@@ -52,8 +52,8 @@
<span
style=
"font-weight: bold;"
>
{{salesTargetMonthsItem.monthNum}}月销售目标
</span>
<span
style=
"font-weight: bold;"
>
{{salesTargetMonthsItem.monthNum}}月销售目标
</span>
<div
class=
"content_target_item"
>
<div
class=
"content_target_item"
>
<span>
FYP
</span>
<span>
FYP
</span>
<input
type=
"
number
"
class=
"form-control"
placeholder=
"{{personalSalesReadonlyFlag?'暂无目标保费':'请输入目标保费'}}"
<input
type=
"
text
"
class=
"form-control"
placeholder=
"{{personalSalesReadonlyFlag?'暂无目标保费':'请输入目标保费'}}"
[(
ngModel
)]="
salesTargetMonthsItem
.
premium
"
(
ngModelChange
)="
changePremium
()"
[(
ngModel
)]="
salesTargetMonthsItem
.
premium
"
(
ngModelChange
)="
changePremium
()
;
"
[
disabled
]="
personalSalesReadonlyFlag
"
(
blur
)="
inputBlur
()"
>
[
disabled
]="
personalSalesReadonlyFlag
"
(
blur
)="
inputBlur
()"
>
</div>
</div>
<div
class=
"content_target_item"
>
<div
class=
"content_target_item"
>
...
@@ -79,7 +79,7 @@
...
@@ -79,7 +79,7 @@
<i
class=
"iconfont icon-save"
*
ngIf=
"!readonlyFlag && salesTargetFlag && !personalSalesActivityFlag"
<i
class=
"iconfont icon-save"
*
ngIf=
"!readonlyFlag && salesTargetFlag && !personalSalesActivityFlag"
(
click
)="
salesTargetMonthSave
(
1
)"
></i>
(
click
)="
salesTargetMonthSave
(
1
)"
></i>
<div
class=
"title"
>
月均销售活动量目标
</div>
<div
class=
"title"
>
月均销售活动量目标
</div>
<div
*
ngIf=
"!salesTarget
Flag
"
style=
"text-align: center;"
>
请先设置销售目标
</div>
<div
*
ngIf=
"!salesTarget
Actions || salesTargetActions.length<=0
"
style=
"text-align: center;"
>
请先设置销售目标
</div>
<div
class=
"content_target_item"
*
ngFor=
"let salesTargetActionItem of salesTargetActions"
>
<div
class=
"content_target_item"
*
ngFor=
"let salesTargetActionItem of salesTargetActions"
>
<span>
{{salesTargetActionItem.leadsActionName}}
</span>
<span>
{{salesTargetActionItem.leadsActionName}}
</span>
<input
class=
"form-control"
type=
"text"
[(
ngModel
)]="
salesTargetActionItem
.
actionStandards
"
<input
class=
"form-control"
type=
"text"
[(
ngModel
)]="
salesTargetActionItem
.
actionStandards
"
...
@@ -131,7 +131,7 @@
...
@@ -131,7 +131,7 @@
<i
class=
"iconfont icon-save"
*
ngIf=
"!readonlyFlag && recruitingTargetFlag && !recruitsActivityReadonlyFlag"
<i
class=
"iconfont icon-save"
*
ngIf=
"!readonlyFlag && recruitingTargetFlag && !recruitsActivityReadonlyFlag"
(
click
)="
potentialGoalsActionsUpdate
()"
></i>
(
click
)="
potentialGoalsActionsUpdate
()"
></i>
<div
class=
"title"
>
月均增员活动量目标
</div>
<div
class=
"title"
>
月均增员活动量目标
</div>
<div
*
ngIf=
"!
recruitingTargetFlag
"
style=
"text-align: center;"
>
请先设置增员目标
</div>
<div
*
ngIf=
"!
goalsActionsInfoList || goalsActionsInfoList.length<=0
"
style=
"text-align: center;"
>
请先设置增员目标
</div>
<div
class=
"content_target_item"
*
ngFor=
"let goalsActionsInfoItem of goalsActionsInfoList"
>
<div
class=
"content_target_item"
*
ngFor=
"let goalsActionsInfoItem of goalsActionsInfoList"
>
<span>
{{goalsActionsInfoItem.potentialActionName}}
</span>
<span>
{{goalsActionsInfoItem.potentialActionName}}
</span>
<input
type=
"number"
style=
"width: 30%;"
class=
"form-control"
<input
type=
"number"
style=
"width: 30%;"
class=
"form-control"
...
...
src/app/my/my-target/my-target.component.ts
View file @
0b73e3aa
...
@@ -20,13 +20,13 @@ export class MyTargetComponent implements OnInit {
...
@@ -20,13 +20,13 @@ export class MyTargetComponent implements OnInit {
salesTargetMonths
:
Array
<
any
>
;
salesTargetMonths
:
Array
<
any
>
;
practitionerId
:
any
;
practitionerId
:
any
;
//个人保费
//个人保费
premium
:
number
;
premium
:
any
;
//个人佣金
//个人佣金
commission
:
number
;
commission
:
any
;
//个人件数
//个人件数
pieces
:
number
;
pieces
:
any
;
//个人件平均保费
//个人件平均保费
pieceAveragePremium
:
number
;
pieceAveragePremium
:
any
;
recruitGoalForMonthList
:
Array
<
any
>
;
recruitGoalForMonthList
:
Array
<
any
>
;
numberRecruitsYear
:
number
;
numberRecruitsYear
:
number
;
numberMDRTYear
:
number
;
numberMDRTYear
:
number
;
...
@@ -39,6 +39,7 @@ export class MyTargetComponent implements OnInit {
...
@@ -39,6 +39,7 @@ export class MyTargetComponent implements OnInit {
goalsActionsInfoList
:
Array
<
any
>
;
goalsActionsInfoList
:
Array
<
any
>
;
salesTargetFlag
:
boolean
=
true
;
salesTargetFlag
:
boolean
=
true
;
recruitingTargetFlag
:
boolean
=
true
;
recruitingTargetFlag
:
boolean
=
true
;
money
:
any
;
constructor
(
private
myService
:
MyService
)
{
}
constructor
(
private
myService
:
MyService
)
{
}
ngOnInit
()
{
ngOnInit
()
{
...
@@ -60,6 +61,7 @@ export class MyTargetComponent implements OnInit {
...
@@ -60,6 +61,7 @@ export class MyTargetComponent implements OnInit {
salesTargetMonths
:
this
.
salesTargetMonths
,
salesTargetMonths
:
this
.
salesTargetMonths
,
goalsType
:
goalsType
goalsType
:
goalsType
}
}
console
.
log
(
this
.
premium
)
for
(
let
i
=
0
;
i
<
this
.
salesTargetMonths
.
length
;
i
++
)
{
for
(
let
i
=
0
;
i
<
this
.
salesTargetMonths
.
length
;
i
++
)
{
if
(
!
this
.
salesTargetMonths
[
i
][
'premium'
]
&&
this
.
salesTargetMonths
[
i
][
'premium'
]
!=
0
)
{
if
(
!
this
.
salesTargetMonths
[
i
][
'premium'
]
&&
this
.
salesTargetMonths
[
i
][
'premium'
]
!=
0
)
{
this
.
toastDialog
=
true
;
this
.
toastDialog
=
true
;
...
@@ -124,20 +126,7 @@ export class MyTargetComponent implements OnInit {
...
@@ -124,20 +126,7 @@ export class MyTargetComponent implements OnInit {
this
.
personalSalesReadonlyFlag
=
true
;
this
.
personalSalesReadonlyFlag
=
true
;
this
.
personalSalesActivityFlag
=
true
;
this
.
personalSalesActivityFlag
=
true
;
}
else
{
}
else
{
this
.
salesTargetMonths
=
[
this
.
initSalesTargetMonths
();
{
premium
:
null
,
commission
:
null
,
pieces
:
null
,
pieceAveragePremium
:
null
,
monthNum
:
1
},
{
premium
:
null
,
commission
:
null
,
pieces
:
null
,
pieceAveragePremium
:
null
,
monthNum
:
2
},
{
premium
:
null
,
commission
:
null
,
pieces
:
null
,
pieceAveragePremium
:
null
,
monthNum
:
3
},
{
premium
:
null
,
commission
:
null
,
pieces
:
null
,
pieceAveragePremium
:
null
,
monthNum
:
4
},
{
premium
:
null
,
commission
:
null
,
pieces
:
null
,
pieceAveragePremium
:
null
,
monthNum
:
5
},
{
premium
:
null
,
commission
:
null
,
pieces
:
null
,
pieceAveragePremium
:
null
,
monthNum
:
6
},
{
premium
:
null
,
commission
:
null
,
pieces
:
null
,
pieceAveragePremium
:
null
,
monthNum
:
7
},
{
premium
:
null
,
commission
:
null
,
pieces
:
null
,
pieceAveragePremium
:
null
,
monthNum
:
8
},
{
premium
:
null
,
commission
:
null
,
pieces
:
null
,
pieceAveragePremium
:
null
,
monthNum
:
9
},
{
premium
:
null
,
commission
:
null
,
pieces
:
null
,
pieceAveragePremium
:
null
,
monthNum
:
10
},
{
premium
:
null
,
commission
:
null
,
pieces
:
null
,
pieceAveragePremium
:
null
,
monthNum
:
11
},
{
premium
:
null
,
commission
:
null
,
pieces
:
null
,
pieceAveragePremium
:
null
,
monthNum
:
12
}
]
this
.
salesTargetFlag
=
false
;
this
.
salesTargetFlag
=
false
;
this
.
personalSalesReadonlyFlag
=
false
;
this
.
personalSalesReadonlyFlag
=
false
;
this
.
personalSalesActivityFlag
=
false
;
this
.
personalSalesActivityFlag
=
false
;
...
@@ -150,20 +139,7 @@ export class MyTargetComponent implements OnInit {
...
@@ -150,20 +139,7 @@ export class MyTargetComponent implements OnInit {
}
else
{
}
else
{
this
.
commission
=
this
.
pieceAveragePremium
=
this
.
pieces
=
this
.
premium
=
null
;
this
.
commission
=
this
.
pieceAveragePremium
=
this
.
pieces
=
this
.
premium
=
null
;
this
.
salesTargetFlag
=
false
;
this
.
salesTargetFlag
=
false
;
this
.
salesTargetMonths
=
[
this
.
initSalesTargetMonths
()
{
premium
:
null
,
commission
:
null
,
pieces
:
null
,
pieceAveragePremium
:
null
,
monthNum
:
1
},
{
premium
:
null
,
commission
:
null
,
pieces
:
null
,
pieceAveragePremium
:
null
,
monthNum
:
2
},
{
premium
:
null
,
commission
:
null
,
pieces
:
null
,
pieceAveragePremium
:
null
,
monthNum
:
3
},
{
premium
:
null
,
commission
:
null
,
pieces
:
null
,
pieceAveragePremium
:
null
,
monthNum
:
4
},
{
premium
:
null
,
commission
:
null
,
pieces
:
null
,
pieceAveragePremium
:
null
,
monthNum
:
5
},
{
premium
:
null
,
commission
:
null
,
pieces
:
null
,
pieceAveragePremium
:
null
,
monthNum
:
6
},
{
premium
:
null
,
commission
:
null
,
pieces
:
null
,
pieceAveragePremium
:
null
,
monthNum
:
7
},
{
premium
:
null
,
commission
:
null
,
pieces
:
null
,
pieceAveragePremium
:
null
,
monthNum
:
8
},
{
premium
:
null
,
commission
:
null
,
pieces
:
null
,
pieceAveragePremium
:
null
,
monthNum
:
9
},
{
premium
:
null
,
commission
:
null
,
pieces
:
null
,
pieceAveragePremium
:
null
,
monthNum
:
10
},
{
premium
:
null
,
commission
:
null
,
pieces
:
null
,
pieceAveragePremium
:
null
,
monthNum
:
11
},
{
premium
:
null
,
commission
:
null
,
pieces
:
null
,
pieceAveragePremium
:
null
,
monthNum
:
12
}
]
}
}
})
})
}
}
...
@@ -188,6 +164,22 @@ export class MyTargetComponent implements OnInit {
...
@@ -188,6 +164,22 @@ export class MyTargetComponent implements OnInit {
//获取月销售平均值
//获取月销售平均值
getMonthAverage
(
type
)
{
getMonthAverage
(
type
)
{
// let premium, pieceAveragePremium, commission;
// if (String(this.premium).indexOf(",") != -1) {
// premium = this.premium.replace(/,/g, '');
// } else {
// premium = this.premium;
// }
// if (String(this.pieceAveragePremium).indexOf(",") != -1) {
// pieceAveragePremium = this.pieceAveragePremium.replace(/,/g, '');
// } else {
// pieceAveragePremium = this.pieceAveragePremium
// }
// if (String(this.commission).indexOf(",") != -1) {
// commission = this.commission.replace(/,/g, '');
// } else {
// commission = this.commission
// }
this
.
salesTargetMonths
.
forEach
(
item
=>
{
this
.
salesTargetMonths
.
forEach
(
item
=>
{
if
(
type
===
'premium'
)
{
if
(
type
===
'premium'
)
{
item
.
premium
=
Math
.
ceil
(
this
.
premium
/
12
);
item
.
premium
=
Math
.
ceil
(
this
.
premium
/
12
);
...
@@ -281,20 +273,7 @@ export class MyTargetComponent implements OnInit {
...
@@ -281,20 +273,7 @@ export class MyTargetComponent implements OnInit {
this
.
recruitingTargetFlag
=
true
;
this
.
recruitingTargetFlag
=
true
;
this
.
recruitsReadonlyFlag
=
true
;
this
.
recruitsReadonlyFlag
=
true
;
}
else
{
}
else
{
this
.
recruitGoalForMonthList
=
[
this
.
initRecruitGoalForMonthList
();
{
numberMDRT
:
null
,
numberRecruits
:
null
,
month
:
1
},
{
numberMDRT
:
null
,
numberRecruits
:
null
,
month
:
2
},
{
numberMDRT
:
null
,
numberRecruits
:
null
,
month
:
3
},
{
numberMDRT
:
null
,
numberRecruits
:
null
,
month
:
4
},
{
numberMDRT
:
null
,
numberRecruits
:
null
,
month
:
5
},
{
numberMDRT
:
null
,
numberRecruits
:
null
,
month
:
6
},
{
numberMDRT
:
null
,
numberRecruits
:
null
,
month
:
7
},
{
numberMDRT
:
null
,
numberRecruits
:
null
,
month
:
8
},
{
numberMDRT
:
null
,
numberRecruits
:
null
,
month
:
9
},
{
numberMDRT
:
null
,
numberRecruits
:
null
,
month
:
10
},
{
numberMDRT
:
null
,
numberRecruits
:
null
,
month
:
11
},
{
numberMDRT
:
null
,
numberRecruits
:
null
,
month
:
12
}
]
this
.
recruitingTargetFlag
=
false
;
this
.
recruitingTargetFlag
=
false
;
this
.
recruitsReadonlyFlag
=
false
;
this
.
recruitsReadonlyFlag
=
false
;
}
}
...
@@ -302,20 +281,7 @@ export class MyTargetComponent implements OnInit {
...
@@ -302,20 +281,7 @@ export class MyTargetComponent implements OnInit {
this
.
numberRecruitsYear
=
null
;
this
.
numberRecruitsYear
=
null
;
this
.
numberMDRTYear
=
null
;
this
.
numberMDRTYear
=
null
;
this
.
recruitingTargetFlag
=
false
;
this
.
recruitingTargetFlag
=
false
;
this
.
recruitGoalForMonthList
=
[
this
.
initRecruitGoalForMonthList
();
{
numberMDRT
:
null
,
numberRecruits
:
null
,
month
:
1
},
{
numberMDRT
:
null
,
numberRecruits
:
null
,
month
:
2
},
{
numberMDRT
:
null
,
numberRecruits
:
null
,
month
:
3
},
{
numberMDRT
:
null
,
numberRecruits
:
null
,
month
:
4
},
{
numberMDRT
:
null
,
numberRecruits
:
null
,
month
:
5
},
{
numberMDRT
:
null
,
numberRecruits
:
null
,
month
:
6
},
{
numberMDRT
:
null
,
numberRecruits
:
null
,
month
:
7
},
{
numberMDRT
:
null
,
numberRecruits
:
null
,
month
:
8
},
{
numberMDRT
:
null
,
numberRecruits
:
null
,
month
:
9
},
{
numberMDRT
:
null
,
numberRecruits
:
null
,
month
:
10
},
{
numberMDRT
:
null
,
numberRecruits
:
null
,
month
:
11
},
{
numberMDRT
:
null
,
numberRecruits
:
null
,
month
:
12
}
]
}
}
})
})
}
}
...
@@ -393,4 +359,40 @@ export class MyTargetComponent implements OnInit {
...
@@ -393,4 +359,40 @@ export class MyTargetComponent implements OnInit {
inputBlur
()
{
inputBlur
()
{
window
.
scrollTo
(
0
,
0
)
window
.
scrollTo
(
0
,
0
)
}
}
//初始化增员目标
initRecruitGoalForMonthList
()
{
this
.
recruitGoalForMonthList
=
[
{
numberMDRT
:
null
,
numberRecruits
:
null
,
month
:
1
},
{
numberMDRT
:
null
,
numberRecruits
:
null
,
month
:
2
},
{
numberMDRT
:
null
,
numberRecruits
:
null
,
month
:
3
},
{
numberMDRT
:
null
,
numberRecruits
:
null
,
month
:
4
},
{
numberMDRT
:
null
,
numberRecruits
:
null
,
month
:
5
},
{
numberMDRT
:
null
,
numberRecruits
:
null
,
month
:
6
},
{
numberMDRT
:
null
,
numberRecruits
:
null
,
month
:
7
},
{
numberMDRT
:
null
,
numberRecruits
:
null
,
month
:
8
},
{
numberMDRT
:
null
,
numberRecruits
:
null
,
month
:
9
},
{
numberMDRT
:
null
,
numberRecruits
:
null
,
month
:
10
},
{
numberMDRT
:
null
,
numberRecruits
:
null
,
month
:
11
},
{
numberMDRT
:
null
,
numberRecruits
:
null
,
month
:
12
}
]
}
//初始化商机目标
initSalesTargetMonths
()
{
this
.
salesTargetMonths
=
[
{
premium
:
null
,
commission
:
null
,
pieces
:
null
,
pieceAveragePremium
:
null
,
monthNum
:
1
},
{
premium
:
null
,
commission
:
null
,
pieces
:
null
,
pieceAveragePremium
:
null
,
monthNum
:
2
},
{
premium
:
null
,
commission
:
null
,
pieces
:
null
,
pieceAveragePremium
:
null
,
monthNum
:
3
},
{
premium
:
null
,
commission
:
null
,
pieces
:
null
,
pieceAveragePremium
:
null
,
monthNum
:
4
},
{
premium
:
null
,
commission
:
null
,
pieces
:
null
,
pieceAveragePremium
:
null
,
monthNum
:
5
},
{
premium
:
null
,
commission
:
null
,
pieces
:
null
,
pieceAveragePremium
:
null
,
monthNum
:
6
},
{
premium
:
null
,
commission
:
null
,
pieces
:
null
,
pieceAveragePremium
:
null
,
monthNum
:
7
},
{
premium
:
null
,
commission
:
null
,
pieces
:
null
,
pieceAveragePremium
:
null
,
monthNum
:
8
},
{
premium
:
null
,
commission
:
null
,
pieces
:
null
,
pieceAveragePremium
:
null
,
monthNum
:
9
},
{
premium
:
null
,
commission
:
null
,
pieces
:
null
,
pieceAveragePremium
:
null
,
monthNum
:
10
},
{
premium
:
null
,
commission
:
null
,
pieces
:
null
,
pieceAveragePremium
:
null
,
monthNum
:
11
},
{
premium
:
null
,
commission
:
null
,
pieces
:
null
,
pieceAveragePremium
:
null
,
monthNum
:
12
}
]
}
}
}
src/app/my/my.module.ts
View file @
0b73e3aa
...
@@ -24,10 +24,11 @@ import { MySettingDetailComponent } from './my-setting-detail/my-setting-detail.
...
@@ -24,10 +24,11 @@ import { MySettingDetailComponent } from './my-setting-detail/my-setting-detail.
import
{
MyNewsComponent
}
from
'./my-news/my-news.component'
;
import
{
MyNewsComponent
}
from
'./my-news/my-news.component'
;
import
{
MyTargetComponent
}
from
'./my-target/my-target.component'
;
import
{
MyTargetComponent
}
from
'./my-target/my-target.component'
;
import
{
TeamPanelComponent
}
from
'./team-panel/team-panel.component'
;
import
{
TeamPanelComponent
}
from
'./team-panel/team-panel.component'
;
import
{
SwitchNumberPipe
}
from
'../common/pipe/switch-number.pipe'
;
import
{
TeamSalesScoreComponent
}
from
'./team-sales-score/team-sales-score.component'
;
@
NgModule
({
@
NgModule
({
declarations
:
[
MyCenterHomeComponent
,
MkMaterialComponent
,
MkMaterialDetailComponent
,
FileUploadComponent
,
ImportantAnnouncementComponent
,
SalesDetailComponent
,
AnnouncementDetailComponent
,
MyBusinessComponent
,
MyBusinessDetailComponent
,
PickerComponent
,
ToastComponent
,
SalesRankComponent
,
TeamRankComponent
,
RecruitingComponent
,
RecruitingDetailComponent
,
ThanksComponent
,
MySettingComponent
,
MySettingDetailComponent
,
MyNewsComponent
,
MyTargetComponent
,
TeamPanelComponent
],
declarations
:
[
MyCenterHomeComponent
,
MkMaterialComponent
,
MkMaterialDetailComponent
,
FileUploadComponent
,
ImportantAnnouncementComponent
,
SalesDetailComponent
,
AnnouncementDetailComponent
,
MyBusinessComponent
,
MyBusinessDetailComponent
,
PickerComponent
,
ToastComponent
,
SalesRankComponent
,
TeamRankComponent
,
RecruitingComponent
,
RecruitingDetailComponent
,
ThanksComponent
,
MySettingComponent
,
MySettingDetailComponent
,
MyNewsComponent
,
MyTargetComponent
,
TeamPanelComponent
,
SwitchNumberPipe
,
TeamSalesScoreComponent
],
imports
:
[
imports
:
[
CommonModule
,
CommonModule
,
LifeCommonModule
,
LifeCommonModule
,
...
...
src/app/my/my.service.ts
View file @
0b73e3aa
...
@@ -128,7 +128,7 @@ export class MyService {
...
@@ -128,7 +128,7 @@ export class MyService {
//查询团队业绩及是否团队长
//查询团队业绩及是否团队长
subordinateSystemMemberQuery
(
practitionerId
)
{
subordinateSystemMemberQuery
(
practitionerId
)
{
const
url
=
this
.
API
+
'/practitioner/subordinateSystemMemberQuery'
;
const
url
=
this
.
ydapi
+
'/practitioner/subordinateSystemMemberQuery'
;
return
this
.
http
return
this
.
http
.
post
(
url
,
JSON
.
stringify
(
practitionerId
));
.
post
(
url
,
JSON
.
stringify
(
practitionerId
));
}
}
...
@@ -259,4 +259,25 @@ export class MyService {
...
@@ -259,4 +259,25 @@ export class MyService {
return
this
.
http
return
this
.
http
.
post
(
url
,
JSON
.
stringify
(
param
));
.
post
(
url
,
JSON
.
stringify
(
param
));
}
}
//团队平均
teamActionsAverageQuery
(
param
)
{
const
url
=
this
.
ydapi
+
'/practitioner/teamActionsAverageQuery'
;
return
this
.
http
.
post
(
url
,
JSON
.
stringify
(
param
));
}
//增员统计
potentialActivityQuery
(
param
)
{
const
url
=
this
.
ydapi
+
'/practitioner/potentialActivityQuery'
;
return
this
.
http
.
post
(
url
,
JSON
.
stringify
(
param
));
}
//团队成员销售活动量得分
playerSalesActivityQuery
(
param
)
{
const
url
=
this
.
ydapi
+
'/practitioner/playerSalesActivityQuery'
;
return
this
.
http
.
post
(
url
,
JSON
.
stringify
(
param
));
}
}
}
src/app/my/recruiting-detail/recruiting-detail.component.html
View file @
0b73e3aa
...
@@ -15,7 +15,7 @@
...
@@ -15,7 +15,7 @@
<div
class=
"contentItem"
>
<div
class=
"contentItem"
>
<span><sub>
*
</sub>
姓名
</span>
<span><sub>
*
</sub>
姓名
</span>
<input
class=
"form-control"
type=
"text"
placeholder=
"{{readonlyFlag ?'暂无姓名':'请输入姓名'}}"
<input
class=
"form-control"
type=
"text"
placeholder=
"{{readonlyFlag ?'暂无姓名':'请输入姓名'}}"
[(
ngModel
)]="
editRecruiting
.
name
"
[
disabled
]="
readonlyFlag
"
/>
[(
ngModel
)]="
editRecruiting
.
name
"
[
disabled
]="
readonlyFlag
"
(
blur
)="
inputBlur
()"
/>
</div>
</div>
<div
class=
"contentItem"
>
<div
class=
"contentItem"
>
<span>
年龄
</span>
<span>
年龄
</span>
...
@@ -59,7 +59,7 @@
...
@@ -59,7 +59,7 @@
<div
class=
"contentItem"
>
<div
class=
"contentItem"
>
<span>
学历
</span>
<span>
学历
</span>
<select
class=
"form-control"
[(
ngModel
)]="
editRecruiting
.
educationLevel
"
[
disabled
]="
readonlyFlag
"
<select
class=
"form-control"
[(
ngModel
)]="
editRecruiting
.
educationLevel
"
[
disabled
]="
readonlyFlag
"
style=
" direction: rtl;"
>
style=
" direction: rtl;"
(
blur
)="
inputBlur
()"
>
<option
value=
''
>
{{readonlyFlag ?'暂无学历信息':'请选择学历'}}
</option>
<option
value=
''
>
{{readonlyFlag ?'暂无学历信息':'请选择学历'}}
</option>
<option
*
ngFor=
"let educationLevelItem of educationLevelList"
[
value
]="
educationLevelItem
.
id
"
>
<option
*
ngFor=
"let educationLevelItem of educationLevelList"
[
value
]="
educationLevelItem
.
id
"
>
{{educationLevelItem.name}}
{{educationLevelItem.name}}
...
@@ -69,7 +69,7 @@
...
@@ -69,7 +69,7 @@
<div
class=
"contentItem"
>
<div
class=
"contentItem"
>
<span>
招募来源
</span>
<span>
招募来源
</span>
<select
class=
"form-control"
[(
ngModel
)]="
editRecruiting
.
resourceDropMasterId
"
[
disabled
]="
readonlyFlag
"
<select
class=
"form-control"
[(
ngModel
)]="
editRecruiting
.
resourceDropMasterId
"
[
disabled
]="
readonlyFlag
"
style=
" direction: rtl;"
>
style=
" direction: rtl;"
(
blur
)="
inputBlur
()"
>
<option
value=
""
>
{{readonlyFlag ?'暂无招募来源':'请选择招募来源'}}
</option>
<option
value=
""
>
{{readonlyFlag ?'暂无招募来源':'请选择招募来源'}}
</option>
<option
*
ngFor=
"let resourceItem of resourceList"
[
value
]="
resourceItem
.
id
"
>
<option
*
ngFor=
"let resourceItem of resourceList"
[
value
]="
resourceItem
.
id
"
>
{{resourceItem.dropOptionName}}
{{resourceItem.dropOptionName}}
...
@@ -81,6 +81,11 @@
...
@@ -81,6 +81,11 @@
<input
class=
"form-control"
type=
"text"
placeholder=
"增员创建时间"
[(
ngModel
)]="
editRecruiting
.
createdAt
"
disabled
/>
<input
class=
"form-control"
type=
"text"
placeholder=
"增员创建时间"
[(
ngModel
)]="
editRecruiting
.
createdAt
"
disabled
/>
</div>
</div>
<div
class=
"contentItem"
*
ngIf=
"this.id!=0"
>
<div
class=
"contentItem"
*
ngIf=
"this.id!=0"
>
<span>
预计报聘时间
</span>
<input
class=
"form-control"
type=
"date"
placeholder=
"{{readonlyFlag ?'暂无预计报聘时间':'请选择预计报聘时间'}}"
[(
ngModel
)]="
editRecruiting
.
timeToOnboarding
"
[
disabled
]="
readonlyFlag
"
(
blur
)="
inputBlur
()"
/>
</div>
<div
class=
"contentItem"
*
ngIf=
"this.id!=0"
>
<span>
增员状态
</span>
<span>
增员状态
</span>
<div
style=
"padding: 6px 15px;padding: 6px 15px;color: #e10d0d;font-weight: bold;"
>
<div
style=
"padding: 6px 15px;padding: 6px 15px;color: #e10d0d;font-weight: bold;"
>
{{editRecruiting.trackStatus}}
</div>
{{editRecruiting.trackStatus}}
</div>
...
...
src/app/my/team-panel/team-panel.component.html
View file @
0b73e3aa
...
@@ -6,21 +6,21 @@
...
@@ -6,21 +6,21 @@
</div>
</div>
<div
class=
"taem_panel_item_wrapper"
>
<div
class=
"taem_panel_item_wrapper"
>
<div
class=
"taem_panel_item_top"
>
<div
class=
"taem_panel_item_top"
>
<div>
<div
class=
"item_title"
>
战队业绩
战队业绩
</div>
</div>
<ul
class=
"tab"
>
<ul
class=
"tab"
>
<li>
本月
</li>
<li
[
ngClass
]="{
selected:selectedRecruitingItem=
==1}"
(
click
)="
subordinateSystemMemberQuery
(
1
)"
>
本月
</li>
<li
>
季度
</li>
<li
[
ngClass
]="{
selected:selectedRecruitingItem=
==3}"
(
click
)="
subordinateSystemMemberQuery
(
3
)"
>
本季
</li>
<li>
本年
</li>
<li
[
ngClass
]="{
selected:selectedRecruitingItem=
==2}"
(
click
)="
subordinateSystemMemberQuery
(
2
)"
>
本年
</li>
</ul>
</ul>
</div>
</div>
<div
class=
"taem_panel_item_content"
>
<div
class=
"taem_panel_item_content"
>
<ul>
<ul>
<li>
¥
2,500
</li>
<li>
¥
{{statisticInfo?.fyp}}
</li>
<li>
¥
25
</li>
<li>
¥
{{statisticInfo?.fyc}}
</li>
<li>
1
</li>
<li>
{{statisticInfo?.count}}
</li>
<li>
20%
</li>
<li>
{{statisticInfo?.completionRate | percent }}
</li>
</ul>
</ul>
<ul>
<ul>
<li>
首年保费
</li>
<li>
首年保费
</li>
...
@@ -30,21 +30,21 @@
...
@@ -30,21 +30,21 @@
</ul>
</ul>
</div>
</div>
<div
class=
"next"
>
<div
class=
"next"
>
<span
class=
"iconfont icon-
xiangxia
"
routerLink=
"/teamRank"
></span>
<span
class=
"iconfont icon-
ar-r
"
routerLink=
"/teamRank"
></span>
</div>
</div>
</div>
</div>
<div
class=
"taem_panel_item_wrapper"
>
<div
class=
"taem_panel_item_wrapper"
>
<div
class=
"taem_panel_item_top"
>
<div
class=
"taem_panel_item_top"
>
<div>
<div
class=
"item_title"
>
战队销售活动量
战队销售活动量
</div>
</div>
</div>
</div>
<div
class=
"taem_panel_item_content"
>
<div
class=
"taem_panel_item_content"
>
<ul>
<ul>
<li>
8
</li>
<li>
{{ this.teamActionsData?.scoreDayAverage | number: "1.0-0"}}
</li>
<li>
100
</li>
<li>
{{this.teamActionsData?.scoreWeekAverage | number: "1.0-0"}}
</li>
<li>
48
</li>
<li>
{{this.teamActionsData?.scoreMonthAverage | number: "1.0-0"}}
</li>
<li>
12
</li>
<li>
{{this.teamActionsData?.opportunitiesNum}}
</li>
</ul>
</ul>
<ul>
<ul>
<li>
今天平均
</li>
<li>
今天平均
</li>
...
@@ -54,50 +54,50 @@
...
@@ -54,50 +54,50 @@
</ul>
</ul>
</div>
</div>
<div
class=
"next"
>
<div
class=
"next"
>
<span
class=
"iconfont icon-
xiangxia
"
></span>
<span
class=
"iconfont icon-
ar-r"
routerLink=
"teamSalesScore
"
></span>
</div>
</div>
</div>
</div>
<div
class=
"taem_panel_item_wrapper"
>
<div
class=
"taem_panel_item_wrapper"
>
<div
class=
"taem_panel_item_top"
>
<div
class=
"taem_panel_item_top"
>
<div>
<div
class=
"item_title"
>
战队销售业绩预测
战队销售业绩预测
</div>
</div>
<ul
class=
"tab"
>
<ul
class=
"tab"
>
<li>
本月
</li>
<li
[
ngClass
]="{
selected:selectedSalseItem=
=='month'}"
(
click
)="
selectSales
('
month
')"
>
本月
</li>
<li
>
季度
</li>
<li
[
ngClass
]="{
selected:selectedSalseItem=
=='quarter'}"
(
click
)="
selectSales
('
quarter
')"
>
本季
</li>
<li>
本年
</li>
<li
[
ngClass
]="{
selected:selectedSalseItem=
=='year'}"
(
click
)="
selectSales
('
year
')"
>
本年
</li>
</ul>
</ul>
</div>
</div>
<div
class=
"taem_panel_item_content"
>
<div
class=
"taem_panel_item_content"
>
<ul>
<ul>
<li>
¥
2,500
</li>
<li>
¥
{{premiums | number:'1.0-0'}}
</li>
<li>
¥
25
</li>
<li>
¥
{{commission | number:'1.0-0'}}
</li>
<li>
1
</li>
<li>
{{count | number:'1.0-0'}}
</li>
<li>
20%
</li>
<li>
{{completionRates | percent}}
</li>
</ul>
</ul>
<ul>
<ul>
<li>
月保费预测
</li>
<li>
{{selectedSalseItemName}}保费
</li>
<li>
月佣金预测
</li>
<li>
{{selectedSalseItemName}}佣金
</li>
<li>
月预计
件数
</li>
<li>
{{selectedSalseItemName}}
件数
</li>
<li>
月
完成率
</li>
<li>
{{selectedSalseItemName}}
完成率
</li>
</ul>
</ul>
</div>
</div>
<div
class=
"next"
>
<div
class=
"next"
>
<span
class=
"iconfont icon-
xiangxia
"
></span>
<span
class=
"iconfont icon-
ar-r"
routerLink=
"forecast
"
></span>
</div>
</div>
</div>
</div>
<div
class=
"taem_panel_item_wrapper"
>
<div
class=
"taem_panel_item_wrapper"
>
<div
class=
"taem_panel_item_top"
>
<div
class=
"taem_panel_item_top"
>
<div>
<div
class=
"item_title"
>
我的增员活动量
我的增员活动量
</div>
</div>
</div>
</div>
<div
class=
"taem_panel_item_content"
>
<div
class=
"taem_panel_item_content"
>
<ul>
<ul>
<li>
1
</li>
<li>
{{recruitingStatistics?.activityForToday}}
</li>
<li>
6
</li>
<li>
{{recruitingStatistics?.activityForWeek}}
</li>
<li>
10
</li>
<li>
{{recruitingStatistics?.activityForMonth}}
</li>
<li>
0
</li>
<li>
{{recruitingStatistics?.recruitSucceed}}
</li>
</ul>
</ul>
<ul>
<ul>
<li>
今天
</li>
<li>
今天
</li>
...
@@ -107,7 +107,7 @@
...
@@ -107,7 +107,7 @@
</ul>
</ul>
</div>
</div>
<div
class=
"next"
>
<div
class=
"next"
>
<span
class=
"iconfont icon-
xiangxia
"
routerLink=
"/recruiting"
></span>
<span
class=
"iconfont icon-
ar-r
"
routerLink=
"/recruiting"
></span>
</div>
</div>
</div>
</div>
</div>
</div>
\ No newline at end of file
src/app/my/team-panel/team-panel.component.scss
View file @
0b73e3aa
.taem_panel_wrapper
{
.taem_panel_wrapper
{
padding
:
5px
8px
;
padding
:
5px
8px
;
background
:
#
f6f7f2
;
background
:
#
eff0f1
;
// background: #0664a4;
// background: #0664a4;
height
:
auto
;
height
:
auto
;
ul
li
,
ol
li
{
ul
li
,
ol
li
{
...
@@ -29,13 +29,17 @@
...
@@ -29,13 +29,17 @@
justify-content
:
space-between
;
justify-content
:
space-between
;
align-items
:
center
;
align-items
:
center
;
height
:
38px
;
height
:
38px
;
.item_title
{
font-weight
:
bold
;
font-size
:
16px
;
}
.tab
{
.tab
{
display
:
flex
;
display
:
flex
;
width
:
35%
;
width
:
35%
;
justify-content
:
space-around
;
justify-content
:
space-around
;
li
{
li
.selected
{
width
:
33%
;
font-weight
:
bold
;
text-align
:
right
;
border-bottom
:
3px
red
solid
;
}
}
}
}
}
}
...
@@ -52,7 +56,7 @@
...
@@ -52,7 +56,7 @@
}
}
}
}
.next
{
.next
{
text-align
:
center
;
text-align
:
right
;
}
}
}
}
}
}
\ No newline at end of file
src/app/my/team-panel/team-panel.component.ts
View file @
0b73e3aa
import
{
Component
,
OnInit
}
from
'@angular/core'
;
import
{
Component
,
OnInit
}
from
'@angular/core'
;
import
{
MyService
}
from
'../my.service'
;
@
Component
({
@
Component
({
selector
:
'ydlife-team-panel'
,
selector
:
'ydlife-team-panel'
,
...
@@ -8,12 +9,84 @@ import { Component, OnInit } from '@angular/core';
...
@@ -8,12 +9,84 @@ import { Component, OnInit } from '@angular/core';
export
class
TeamPanelComponent
implements
OnInit
{
export
class
TeamPanelComponent
implements
OnInit
{
//战队名称
//战队名称
subordinateSystemName
:
any
;
subordinateSystemName
:
any
;
constructor
()
{
}
teamActionsData
:
any
;
//保费
premiums
:
number
;
//佣金
commission
:
number
;
//件数
count
:
number
;
//完成率
completionRates
:
number
;
selectedSalseItem
:
any
;
selectedSalseItemName
:
any
;
practitionerId
:
any
;
recruitingStatistics
:
any
;
selectedRecruitingItem
:
any
;
statisticInfo
:
any
;
constructor
(
private
myService
:
MyService
)
{
}
ngOnInit
()
{
ngOnInit
()
{
this
.
subordinateSystemName
=
sessionStorage
.
getItem
(
'subordinateSystemName'
)
this
.
practitionerId
=
JSON
.
parse
(
localStorage
.
getItem
(
'lifeCustomerInfo'
))[
'practitionerId'
];
this
.
subordinateSystemName
=
sessionStorage
.
getItem
(
'subordinateSystemName'
);
this
.
teamActionsAverageQuery
();
this
.
potentialActivityQuery
();
this
.
subordinateSystemMemberQuery
(
1
);
}
teamActionsAverageQuery
()
{
this
.
myService
.
teamActionsAverageQuery
({
practitionerId
:
this
.
practitionerId
}).
subscribe
((
res
)
=>
{
if
(
res
[
'success'
])
{
this
.
teamActionsData
=
res
[
'data'
];
this
.
selectSales
(
'month'
)
}
})
}
}
selectSales
(
type
)
{
this
.
selectedSalseItem
=
type
;
if
(
type
===
'month'
)
{
this
.
selectedSalseItemName
=
'本月'
;
this
.
premiums
=
this
.
teamActionsData
.
premiumMonth
;
this
.
commission
=
this
.
teamActionsData
.
commissionMonth
;
this
.
count
=
this
.
teamActionsData
.
piecesMonth
;
this
.
completionRates
=
this
.
teamActionsData
.
achievementRateMonth
;
}
if
(
type
===
'quarter'
)
{
this
.
selectedSalseItemName
=
'本季'
;
this
.
premiums
=
this
.
teamActionsData
.
premiumQuarter
;
this
.
commission
=
this
.
teamActionsData
.
commissionQuarter
;
this
.
count
=
this
.
teamActionsData
.
piecesQuarter
;
this
.
completionRates
=
this
.
teamActionsData
.
achievementRateQuarter
;
}
if
(
type
===
'year'
)
{
this
.
selectedSalseItemName
=
'本年'
;
this
.
premiums
=
this
.
teamActionsData
.
premiumYear
;
this
.
commission
=
this
.
teamActionsData
.
commissionYear
;
this
.
count
=
this
.
teamActionsData
.
piecesYear
;
this
.
completionRates
=
this
.
teamActionsData
.
achievementRateYear
;
}
}
subordinateSystemMemberQuery
(
type
)
{
this
.
selectedRecruitingItem
=
type
;
const
param
=
{
time
:
type
,
practitionerId
:
this
.
practitionerId
}
this
.
myService
.
subordinateSystemMemberQuery
(
param
).
subscribe
((
res
)
=>
{
if
(
res
[
'success'
])
{
this
.
statisticInfo
=
res
[
'data'
][
'statisticInfo'
]
}
})
}
//增员统计
potentialActivityQuery
()
{
this
.
myService
.
potentialActivityQuery
({
practitionerId
:
this
.
practitionerId
}).
subscribe
((
res
)
=>
{
if
(
res
[
'success'
])
{
this
.
recruitingStatistics
=
res
[
'data'
];
console
.
log
(
res
)
}
})
}
}
}
src/app/my/team-rank/team-rank.component.scss
View file @
0b73e3aa
...
@@ -4,6 +4,7 @@
...
@@ -4,6 +4,7 @@
// background: #f7f7f2;
// background: #f7f7f2;
min-height
:
100%
;
min-height
:
100%
;
height
:
auto
;
height
:
auto
;
overflow
:
hidden
;
ul
,
ol
{
ul
,
ol
{
list-style
:
none
;
list-style
:
none
;
}
}
...
@@ -40,7 +41,7 @@
...
@@ -40,7 +41,7 @@
width
:
60%
;
width
:
60%
;
ul
.tab
{
ul
.tab
{
float
:
right
;
float
:
right
;
width
:
5
0%
;
width
:
7
0%
;
font-size
:
16px
;
font-size
:
16px
;
color
:
#fff
;
color
:
#fff
;
li
{
li
{
...
...
src/app/my/team-rank/team-rank.component.ts
View file @
0b73e3aa
...
@@ -16,8 +16,9 @@ export class TeamRankComponent implements OnInit {
...
@@ -16,8 +16,9 @@ export class TeamRankComponent implements OnInit {
statisticInfo
:
any
;
statisticInfo
:
any
;
constructor
(
private
myService
:
MyService
)
{
constructor
(
private
myService
:
MyService
)
{
this
.
performanceList
=
[
this
.
performanceList
=
[
{
time
:
'1'
,
name
:
'本月'
},
{
time
:
1
,
name
:
'本月'
},
{
time
:
'2'
,
name
:
'本年'
}
{
time
:
3
,
name
:
'本季'
},
{
time
:
2
,
name
:
'本年'
}
]
]
this
.
list
=
[
this
.
list
=
[
{
type
:
'online'
,
name
:
'线上'
},
{
type
:
'online'
,
name
:
'线上'
},
...
...
src/app/my/team-sales-score/team-sales-score.component.html
0 → 100644
View file @
0b73e3aa
<div
class=
"team_sales_detail_wrapper"
>
<div
class=
"teamHeader"
>
<div
class=
"teamItem teamInfo"
>
<span
class=
"icon-tuandui iconfont"
style=
"position: absolute;width:45px;height:45px;line-height:35px;font-size: 30px;left:0;border: 1px #dcdcdc solid; padding: 5px;border-radius: 50%;"
></span>
<div
style=
"float: left;"
>
{{subordinateSystemName}}战队
</div>
</div>
</div>
<div
*
ngIf=
"this.showType==='teamSalesScore'"
>
<div
class=
"rankInfoWrapper"
>
<div
class=
"rankContent"
>
<div
style=
"font-size: 18px;margin-bottom: 10px;"
>
战队成员销售活动量得分
</div>
<ul>
<li>
姓名
</li>
<li>
今天得分
</li>
<li>
本周得分
</li>
<li>
本月得分
</li>
<li>
本周新增商机
</li>
</ul>
<div
style=
"width: 100%;text-align: center;float: left;height: 35px;"
*
ngIf=
"playerSalesActivityInfo?.length <=0"
>
暂无战队成员,努力去增员吧
</div>
<ul
*
ngFor=
"let playerSalesActivityItem of playerSalesActivityInfo;index as i;"
>
<li>
{{playerSalesActivityItem.name}}
</li>
<li>
{{playerSalesActivityItem.scoreDay!=null?playerSalesActivityItem.scoreDay:'-'}}
</li>
<li>
{{playerSalesActivityItem.scoreWeek!=null?playerSalesActivityItem.scoreWeek:'-'}}
</li>
<li>
{{playerSalesActivityItem.scoreMonth!=null?playerSalesActivityItem.scoreMonth:'-'}}
</li>
<li>
{{playerSalesActivityItem.addOpportunityNum!=null?playerSalesActivityItem.addOpportunityNum:'-'}}
</li>
</ul>
</div>
</div>
</div>
<div
*
ngIf=
"this.showType==='forecast'"
>
预测
</div>
</div>
\ No newline at end of file
src/app/my/team-sales-score/team-sales-score.component.scss
0 → 100644
View file @
0b73e3aa
.team_sales_detail_wrapper
{
padding
:
5px
8px
;
background
:
#eff0f1
;
overflow
:
hidden
;
height
:
100%
;
.teamInfo
{
font-size
:
24px
;
position
:
relative
;
display
:
flex
;
align-items
:
center
;
justify-content
:
center
;
padding
:
15px
0
10px
0
;
text-align
:
center
;
overflow
:
hidden
;
border-radius
:
6px
;
color
:
#ff002a
;
}
.rankInfoWrapper
{
overflow
:
auto
;
width
:
100%
;
float
:
left
;
.rankContent
{
float
:
left
;
width
:
100%
;
overflow
:
auto
;
background
:
#fff
;
box-shadow
:
0
0px
2
.5px
#eceaea
;
border-radius
:
6px
;
padding
:
5px
;
ul
{
width
:
100%
;
height
:
30px
;
line-height
:
30px
;
li
{
float
:
left
;
width
:
18%
;
text-align
:
center
;
margin
:
0
1%
;
position
:
relative
;
margin-bottom
:
5px
;
overflow
:
hidden
;
height
:
30px
;
li
.icon
.iconfont
{
position
:
absolute
;
}
}
li
.name
{
width
:
20%
;
}
li
:last-child
{
margin-right
:
0
;
}
}
}
}
}
src/app/my/team-sales-score/team-sales-score.component.spec.ts
0 → 100644
View file @
0b73e3aa
import
{
async
,
ComponentFixture
,
TestBed
}
from
'@angular/core/testing'
;
import
{
TeamSalesScoreComponent
}
from
'./team-sales-score.component'
;
describe
(
'TeamSalesScoreComponent'
,
()
=>
{
let
component
:
TeamSalesScoreComponent
;
let
fixture
:
ComponentFixture
<
TeamSalesScoreComponent
>
;
beforeEach
(
async
(()
=>
{
TestBed
.
configureTestingModule
({
declarations
:
[
TeamSalesScoreComponent
]
})
.
compileComponents
();
}));
beforeEach
(()
=>
{
fixture
=
TestBed
.
createComponent
(
TeamSalesScoreComponent
);
component
=
fixture
.
componentInstance
;
fixture
.
detectChanges
();
});
it
(
'should create'
,
()
=>
{
expect
(
component
).
toBeTruthy
();
});
});
src/app/my/team-sales-score/team-sales-score.component.ts
0 → 100644
View file @
0b73e3aa
import
{
Component
,
OnInit
}
from
'@angular/core'
;
import
{
ActivatedRoute
,
Router
}
from
"@angular/router"
;
import
{
MyService
}
from
'../my.service'
;
@
Component
({
selector
:
'ydlife-team-sales-score'
,
templateUrl
:
'./team-sales-score.component.html'
,
styleUrls
:
[
'./team-sales-score.component.scss'
]
})
export
class
TeamSalesScoreComponent
implements
OnInit
{
showType
:
any
;
practitionerId
:
any
;
subordinateSystemName
:
any
;
playerSalesActivityInfo
:
Array
<
any
>
;
constructor
(
private
activateRoute
:
ActivatedRoute
,
private
router
:
Router
,
private
myService
:
MyService
)
{
}
ngOnInit
()
{
this
.
practitionerId
=
JSON
.
parse
(
localStorage
.
getItem
(
'lifeCustomerInfo'
))[
'practitionerId'
];
this
.
subordinateSystemName
=
sessionStorage
.
getItem
(
'subordinateSystemName'
);
//判断显示销售得分还是销售预测
this
.
showType
=
this
.
activateRoute
.
snapshot
.
paramMap
.
get
(
'type'
);
console
.
log
(
this
.
showType
)
if
(
this
.
showType
===
'teamSalesScore'
)
{
this
.
playerSalesActivityQuery
()
}
if
(
this
.
showType
===
''
)
{
}
}
//获取成员销售活动量得分
playerSalesActivityQuery
()
{
this
.
myService
.
playerSalesActivityQuery
({
practitionerId
:
this
.
practitionerId
}).
subscribe
((
res
)
=>
{
console
.
log
(
res
)
if
(
res
[
'success'
])
{
this
.
playerSalesActivityInfo
=
res
[
'data'
][
'playerSalesActivityInfo'
]
}
})
}
}
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