Commit e653d064 by Sweet Zhang

优化

parent f7bfc4f0
<!--The content below is only a placeholder and can be replaced.-->
<div ydlifeScroll>
<div style="padding-bottom: 49px;">
<div [ngStyle]="{'padding-bottom':isShowIndexBtn ? '49px' : '0'}">
<router-outlet></router-outlet>
</div>
<ydlife-guide-page *ngIf="shareGuidePageEnable"></ydlife-guide-page>
......@@ -18,7 +18,7 @@
</div>
</div>
<footer>
<footer *ngIf="isShowIndexBtn">
<ul>
<li *ngFor="let item of menuLists" (click)="menuSelect(item)">
<div>
......@@ -28,4 +28,14 @@
</li>
</ul>
</footer>
</div>
<!--弹窗提醒 -->
<div class="tipsInfoContainer" *ngIf="viewStatus===0" (click)="closeDialog($event)">
<div class="tipsInfoContent">
<img src="./assets/images/bell.png" alt="" class="bell">
<img src="./assets/images/dialogBg.png" alt="" style="margin-top:-2px">
<div>您有续期保单待处理</div>
<button (click)="viewDetail()">立即查看</button>
</div>
</div>
\ No newline at end of file
......@@ -59,4 +59,49 @@ footer{
}
}
}
}
.tipsInfoContainer {
width: 100%;
height: 100%;
background: rgba(0, 0, 0, 0.5);
position: fixed;
left: 0;
top: 0;
display: flex;
align-items: center;
.tipsInfoContent {
position: relative;
width: 85%;
padding-bottom: 10px;
margin: 0 auto;
background: #fff;
border-radius: 10px;
text-align: center;
color: #1b5b99;
max-width: 500px;
div{
font-size: 20px;
margin-bottom: 30px;
margin-top: 20px;
}
button {
background: #1b5b99;
color: #fff;
width: 142px;
height: 33px;
line-height: 33px;
text-align: center;
border:none;
outline:none;
border-radius:35px;
}
.bell{
position: absolute;
left: 50%;
top: 0;
transform: translate(-50%,-50%);
width: 30px
}
}
}
\ No newline at end of file
......@@ -3,6 +3,7 @@ import { AuthService } from "./auth/auth.service";
import { LifeCommonService } from "./common/life-common.service";
import { Subscription } from "rxjs/index";
import {Router, NavigationStart, ActivatedRoute, NavigationEnd} from '@angular/router';
import { MyService } from './my/my.service';
declare var wx: any;
......@@ -23,10 +24,14 @@ export class AppComponent implements OnInit, OnDestroy {
// 提问icon显示隐藏
askIconFlag:boolean = true;
iconShowFlag:boolean = true;
// 0是未看 1是已看
viewStatus:number;
lifeCustomerInfo:any;
constructor(private router: Router,
private authService: AuthService,
private lifeCommonService: LifeCommonService,
private activatedRoute:ActivatedRoute,
private myService:MyService,
private el:ElementRef) {
this.subscription = lifeCommonService.shareStatus$.subscribe(status => {
this.shareGuidePageEnable = status == '1';
......@@ -49,11 +54,22 @@ export class AppComponent implements OnInit, OnDestroy {
this.router.navigate([item.link]);
}
closeDialog(e){
if(e.target.className==='tipsInfoContainer'){
this.viewStatus = 1;
sessionStorage.setItem('hadView','true')
}
}
viewDetail(){
this.viewStatus = 1;
sessionStorage.setItem('hadView','true');
this.router.navigate(['/renewal_reminder'])
}
ngOnInit() {
sessionStorage.setItem('iconShowFlag','true')
this.loginId = localStorage.getItem('lifeCustomerInfo')?JSON.parse(localStorage.getItem('lifeCustomerInfo')).mobileNo:null;
sessionStorage.setItem('iconShowFlag','true');
this.lifeCustomerInfo = JSON.parse(localStorage.getItem('lifeCustomerInfo')) ? JSON.parse(localStorage.getItem('lifeCustomerInfo')) : null;
this.loginId = this.lifeCustomerInfo ? this.lifeCustomerInfo.mobileNo:null;
this.authService.obtainToken(this.loginId).subscribe(res => {
if (res['success']) {
localStorage.setItem('lifeToken', res['data']['token']);
......@@ -61,12 +77,22 @@ export class AppComponent implements OnInit, OnDestroy {
}
});
// 查询是否有续期提醒订单
if(sessionStorage.getItem('hadView')){
this.viewStatus = 1;
}else{
this.queryNoticeList();
}
this.getVersion();
this.router.events.forEach((event) => {
if (event instanceof NavigationStart) {
// 控制首页浮标显示与否
// 控制首页浮标显示与否和底部菜单
this.isShowIndexBtn = event.url != '/login';
this.iconShowFlag = !!localStorage.getItem('lifeCustomerInfo');
if(event.url.indexOf('/material/')>=0){
this.isShowIndexBtn = false;
}
// 更新底部图标状态
if(event.url.indexOf('/product')===0){
this.selectedMenuKey = 2
......@@ -104,6 +130,19 @@ export class AppComponent implements OnInit, OnDestroy {
});
}
// 获取是否有续期提醒订单
queryNoticeList(){
this.myService.queryNoticeList({practitionerId:this.lifeCustomerInfo.practitionerId,status:0}).subscribe(res=>{
if(res['success']){
if(res['data']['list'] && res['data']['list'].length > 0){
this.viewStatus = 0;
}else{
sessionStorage.setItem('hadView','true')
}
}
})
}
// 关闭弹窗
getPopInfo() {
this.isNeedAlert = false;
......
......@@ -7,6 +7,7 @@
}
.weui-form{
padding: 56px 15px 0px 15px;
height: 100vh;
}
.weui-form__opr-area{
.login{
......
......@@ -129,7 +129,10 @@ ul,ol{
color: #fff;
text-align: center;
position: fixed;
bottom: 0;
bottom: 49px;
color: #fff;
text-align: center;
width: 100%;
font-size: 20px;
font-weight: bold;
}
......
......@@ -25,6 +25,7 @@
display: flex;
justify-content: center;
align-items: center;
z-index: 2;
>div{
background-color: #fff;
width: 80%;
......
......@@ -90,7 +90,7 @@
min-width: 320px;
max-width: 640px;
position: fixed;
bottom: 0;
bottom: 50px;
left: 0;
right: 0;
height: 56px;
......
......@@ -89,7 +89,7 @@
width: 100%;
height: 48px;
line-height: 48px;
bottom: 0;
bottom: 50px;
left: 0;
background: #ff9700;
text-align: center;
......
......@@ -17,8 +17,11 @@
min-width: 320px;
max-width: 640px;
margin: 0 auto;
bottom: 0;
bottom: 50px;
left: 0;
position: fixed;
width: 100%;
color: #fff;
text-align: center;
}
}
......@@ -37,7 +37,7 @@
}
.send{
position: fixed;
bottom: 30px;
bottom: 60px;
width: 100%;
div{
margin: 0 40px;
......
......@@ -25,9 +25,7 @@ export class ImportantAnnouncementComponent implements OnInit, AfterViewInit {
}
ngAfterViewInit() {
setTimeout(() => {
this.switchCategory(this.selectedCategoryId)
}, 500);
}
// 获取所有的公告类型
......
<section class="header">
<div class="topContent">
<i class="iconfont icon-fanhui"></i>
<i [routerLink]="'/news'">
<img src="assets/images/indexIcons/news.png" alt="" srcset="">
</i>
</div>
<!--头部经纪人信息START-->
<div class="brokerInfoContent">
<div class="avatar" routerLink="setting">
<img style="width: 60px;height: 60px;"
src="{{lifeCustomerInfo?.practitionerBasicInfo?.headImagePath ? lifeCustomerInfo?.practitionerBasicInfo?.headImagePath : './assets/images/icons/meng.png'}}"
alt="头像">
</div>
<div class="brokerInfo">
<div class="brokerName">
<div style="letter-spacing: 2px"><span>{{lifeCustomerInfo?.practitionerBasicInfo?.name}}</span></div>
<span i class="iconfont icon-ar-r" style="font-size:18px;" routerLink="/setting"></span>
</div>
<div class="brokerTag">
<div>
<p>{{lifeCustomerInfo?.practitionerBasicInfo?.insurerBranchName ?
lifeCustomerInfo?.practitionerBasicInfo?.insurerBranchName : '银盾保险'}}</p>
</div>
<div>|</div>
<div>{{lifeCustomerInfo?.practitionerBasicInfo?.subordinateName}}</div>
<div>|</div>
<div><span class="ydTitle">{{lifeCustomerInfo?.practitionerBasicInfo?.levelName}}</span></div>
</div>
</div>
</div>
<!--头部经纪人信息END-->
</section>
<section class="championLists">
<div style="padding-right: 4px">
<div></div>
<div style="display:flex;align-items:center"><img src="assets/images/indexIcons/king.png" alt="" style="width: 30px;margin-right: 3px;">
<span style="font-size: 24px;">龙虎榜</span></div>
<i class="iconfont icon-fanhui" style="color:'#6F1F0D'" (click)="jumpToDetail()"></i>
</div>
<div style="display: flex;flex-direction:column">
<ul class="tab">
<li *ngFor="let item of performanceList" (click)="rank(item.time,1,2)"
[ngClass]="{selected:performanceSelectedFlag==item.time}">
<div style="position: relative;">
<span>{{item.name}}</span>
</div>
</li>
</ul>
<ul>
<li>首年保费</li>
<li>首年佣金</li>
<li>件数</li>
<li style="text-indent: 12px;">完成率</li>
</ul>
<ul>
<li>¥{{onlineInfo?.fyc | number: "1.0-0"}}</li>
<li>¥{{onlineInfo?.fyp | number: "1.0-0"}}</li>
<li>{{onlineInfo?.count?onlineInfo.count:'-'}}</li>
<li style="text-indent: 12px;">{{onlineInfo?.completionRate?onlineInfo.completionRate + '%':'-'}}</li>
</ul>
</div>
</section>
<section class="lists">
<ul>
<li *ngFor="let item of menuLists" (click)="goDetail(item)">
<div>{{item.name}}</div>
<div>
<i class="iconfont icon-fanhui"></i>
</div>
</li>
</ul>
</section>
<section class="copyrightContent">
<p>上海银盾保险经纪有限公司</p>
<p>保险业务经营许可证:269615000000800</p>
<p>
<img src="assets/images/indexIcons/copyright.png" alt="" srcset="">
版权所有©2021银盾保险在线 沪ICP备310115020189293号</p>
</section>
\ No newline at end of file
.icon-fanhui{
display: inline-block;
transform: rotate(180deg);
}
.lists{
ul{
padding-left: 15px;
border-radius: 10px;
background: #fff;
margin: 0 10px;
li{
display: flex;
justify-content: space-between;
align-items: center;
color: #333;
background: #fff;
padding: 14px 5px;
border-bottom: 1px solid #e4e4e4;
&:last-child{
border: none;
}
}
}
}
.brokerInfoContent{
display: flex;
.avatar {
width: 60px;
height: 60px;
border-radius: 50%;
overflow: hidden;
}
.brokerInfo {
flex: 1;
margin-left: 4px;
.brokerName {
display: flex;
justify-content: space-between;
font-weight: normal;
font-size: 16px;
> div:first-child {
display: flex;
align-items: flex-end;
font-size: 20px;
font-weight: 800;
}
}
.brokerTag {
border-radius: 6px;
display: flex;
font-weight: normal;
font-size: 14px;
> div {
display: flex;
align-items: center;
margin-right: 5px;
}
}
}
}
.header{
background: #fff;
padding-left: 16px;
padding-right: 15px;
padding-bottom: 100px;
.topContent{
padding-top: 10px;
display: flex;
justify-content: space-between;
padding-bottom: 20px;
.icon-fanhui{
transform: rotate(0deg);
}
}
}
.championLists{
background: url(/assets/images/indexIcons/mineBg.png);
min-height: 160px;
margin-left: 9px;
margin-right: 11px;
margin-top: -90px;
background-size: cover;
border-radius: 10px;
>div{
display: flex;
justify-content: space-between;
align-items: center;
span{
font-size: 12px;
color: #6F1F0D;
}
}
ul {
display: flex;
list-style: none;
margin-bottom: 5px;
width: 100%;
justify-content: space-between;
padding-left: 35px;
padding-right: 40px;
li {
flex: 0 0 70px;
font-size: 12px;
color: #6F1F0D;
text-align: center;
font-weight: 600;
&.selected{
span {
position: relative;
font-size: 16px;
&:after{
content: '';
position:absolute;
bottom: -10px;
left: 0;
width: 100%;
height: 2px;
background-color: #6F1F0D;
}
};
}
}
&.tab{
border-bottom: 1px solid #fff;
li{
color: #fff;
line-height: 38px;
height: 38px;
}
}
}
}
.copyrightContent{
margin-top: 23px;
text-align: center;
p{
color: #666;
margin-bottom: 4px;
&:last-child{
color: #999;
font-size:10px;
display: flex;
align-items: center;
justify-content: center;
margin-bottom: 33px;
img{
width: 15px;
margin-right: 2px;
}
}
}
}
\ No newline at end of file
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
import { MineComponent } from './mine.component';
describe('MineComponent', () => {
let component: MineComponent;
let fixture: ComponentFixture<MineComponent>;
beforeEach(async(() => {
TestBed.configureTestingModule({
declarations: [ MineComponent ]
})
.compileComponents();
}));
beforeEach(() => {
fixture = TestBed.createComponent(MineComponent);
component = fixture.componentInstance;
fixture.detectChanges();
});
it('should create', () => {
expect(component).toBeTruthy();
});
});
import { Component, OnInit } from '@angular/core';
import { Router } from '@angular/router';
import { LifeCommonService } from 'src/app/common/life-common.service';
import { MyService } from '../my.service';
@Component({
selector: 'ydlife-mine',
templateUrl: './mine.component.html',
styleUrls: ['./mine.component.scss']
})
export class MineComponent implements OnInit {
lifeCustomerInfo: any = JSON.parse(localStorage.getItem('lifeCustomerInfo')) ? JSON.parse(localStorage.getItem('lifeCustomerInfo')) : null;
public menuLists = [
{id:1,name:'全部工具',link:'/moreFeatures',params:null},
{id:2,name:'公司制度',link:'/fileUpload',params:{fileUploadType:'management'}},
{id:3,name:'新人入口',link:'/newPeople',params:null},
{id:4,name:'我的薪资',link:'/salary',params:null},
{id:5,name:'我的积分',link:'/integration',params:null},
]
performanceList:Array<any>;
performanceSelectedFlag: string = '1';
onlineInfo: any;
offlineInfo: any;
constructor(private lifeCommonService:LifeCommonService,private myService:MyService,private router:Router) { }
ngOnInit() {
this.performanceList = [
{ name: `${this.lifeCommonService.dateFormat(new Date, ('M'))}月`, time: 1 },
{ name: `${this.getQuarter(this.lifeCommonService.dateFormat(new Date, ('M')))}`, time: 3 },
{ name: '本年度', time: 2 },
{ name:'往期历史' , time: 4 }
]
//初始化调本月线上 保费+ 本月线下保费
this.rank(1, 1, 1)
}
goDetail(item){
if(item.link){
this.router.navigate([item.link])
}
if(item.link && item.params){
this.router.navigate([item.link],{queryParams:item.params})
}
}
//获取季度
getQuarter(quarter) {
if (quarter == '1' || quarter == '2' || quarter == '3') {
return '第一季度';
}
if (quarter == '4' || quarter == '5' || quarter == '6') {
return '第二季度';
}
if (quarter == '7' || quarter == '8' || quarter == '9') {
return '第三季度';
}
if (quarter == '10' || quarter == '11' || quarter == '12') {
return '第四季度';
}
}
/**
* time 1-month,2-year,3-季度
* type 1-保费,2-佣金 3-件数
* platform //1-online,2-offline
*/
rank(time, platform, type) {
this.performanceSelectedFlag = time;
if(time==4){
this.router.navigate(['/historical_rank'])
}else{
const param = {
mobileNo: JSON.parse(localStorage.getItem('lifeCustomerInfo'))['mobileNo'],
time: time,
platform: platform,
type: type,
isPersonal:0
}
this.myService.rank(param).subscribe((res) => {
if (res['success']) {
if (platform == 1) {
this.onlineInfo = res['data']['practitionerInfo'];
}
if (platform == 2) {
this.offlineInfo = res['data']['practitionerInfo'];
}
}
});
}
}
jumpToDetail() {
this.router.navigate(['/rank'], { queryParams: { time: this.performanceSelectedFlag } });
}
}
<header>
<i class="iconfont icon-fanhui" (click)="goBack()"></i>
<div style="margin-left: -30px;">全部工具</div>
<div></div>
</header>
<div *ngFor="let item of feartureLists" class="featureListsContent">
<h5>{{item.title}}</h5>
<ul>
<li *ngFor="let subItem of item.subItems" (click)="featureSelect(subItem)">
<div>
<img [src]="'assets/images/indexIcons/' + subItem.icon + '.png'" alt="">
</div>
<p>{{subItem.name}}</p>
</li>
</ul>
</div>
<Modal [(ngModel)]="this.state.modal1" [transparent]="true" [maskClosable]="true" (onClose)="onClose('modal1')">
<div [ngStyle]="{ height: 100, overflow: 'scroll',color:'#000' }">
此功能暂未开放,敬请期待。
</div>
</Modal>
\ No newline at end of file
header{
height: 44px;
color: #333;
display: flex;
justify-content: space-between;
align-items: center;
padding-left: 15px;
background: #fff;
}
.featureListsContent{
padding: 15px 10px;
background-color: #fff;
h5{
font-size: 15px;
color: #333;
margin-top: 15px;
margin-bottom: 10px;
font-weight: bold;
}
ul{
display: flex;
flex-wrap: wrap;
li{
width: 0;
flex: 0 0 25%;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
img{
width: 48px;
}
p{
white-space: nowrap;
font-size: 14px;
}
}
}
}
\ No newline at end of file
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
import { MoreFeaturesComponent } from './more-features.component';
describe('MoreFeaturesComponent', () => {
let component: MoreFeaturesComponent;
let fixture: ComponentFixture<MoreFeaturesComponent>;
beforeEach(async(() => {
TestBed.configureTestingModule({
declarations: [ MoreFeaturesComponent ]
})
.compileComponents();
}));
beforeEach(() => {
fixture = TestBed.createComponent(MoreFeaturesComponent);
component = fixture.componentInstance;
fixture.detectChanges();
});
it('should create', () => {
expect(component).toBeTruthy();
});
});
import { Location } from '@angular/common';
import { Component, OnInit } from '@angular/core';
import { Router } from '@angular/router';
@Component({
selector: 'ydlife-more-features',
templateUrl: './more-features.component.html',
styleUrls: ['./more-features.component.scss']
})
export class MoreFeaturesComponent implements OnInit {
lifeCustomerInfo: any = JSON.parse(localStorage.getItem('lifeCustomerInfo')) ? JSON.parse(localStorage.getItem('lifeCustomerInfo')) : null;
public feartureLists = [
{key:'00',title:'营销工具',subItems:[
{no:1,name:'线上投保',icon:'onlineInsurance',link:'',path:`https://${window.location.host}/index?source=dyd`,isOpen:true},
{no:2,name:'产品库',icon:'product-market',link:'/product',path:'',isOpen:true},
{no:3,name:'投核保知识库',icon:'insuranceKnowledgeBase',link:'/underwriting_knowledge',path:'',isOpen:true},
{no:4,name:'计划书',icon:'proposals',link:'',path:'',isOpen:false},
{no:5,name:'产品海报',icon:'productPoster',link:'/material',path:'',isOpen:true},
{no:6,name:'文章分享',icon:'articleShare',link:'/article/null',path:'',isOpen:true},
{no:7,name:'AI保险医生',icon:'aiDoctor',link:'',path:`https://${window.location.host}/questionnaire/#/index?campaign=AIRobot&task=AItask1&customerId=${this.lifeCustomerInfo.customerId}`,isOpen:true},
]},
{key:'01',title:'保单服务',subItems:[
{no:8,name:'我的保单',icon:'policyLists',link:'/salesDetail',path:'',isOpen:true},
{no:9,name:'续期管理',icon:'renewalManagement',link:'/renewal_reminder',path:'',isOpen:true},
]}
,{
key:'02',title:'客户管理',subItems:[
{no:10,name:'成交客户',icon:'customers',link:'/customer',path:'',isOpen:true},
{no:11,name:'潜在客户',icon:'potentialCustomers',link:'/business',path:'',isOpen:true},
]
}
,{
key:'03',title:'我的增员',subItems:[
{no:12,name:'团队增员',icon:'teamIncreaseStaff',link:'/recruiting',path:'',isOpen:true},
{no:13,name:'报聘审批',icon:'employmentApproval',link:'/approval_list',path:'',isOpen:true},
]
}
,{
key:'04',title:'我的展业',subItems:[
{no:14,name:'目标设置',icon:'targetSetting',link:'/target',path:'',isOpen:true},
{no:15,name:'我的日程',icon:'schedule',link:'/todo',path:'',isOpen:true},
{no:16,name:'活动量统计',icon:'activityStatistics',link:'/scoreDeatil',path:'',isOpen:true},
{no:17,name:'我的工号',icon:'jobNumber',link:'',path:'',isOpen:false},
{no:18,name:'联合销售',icon:'jointSale',link:'/joint_sales',path:'',isOpen:true},
{no:19,name:'客户告知书',icon:'customerNotification',link:'/business',path:'',isOpen:true},
{no:20,name:'我的业绩',icon:'achievement',link:'',path:'',isOpen:false},
{no:21,name:'我的薪资',icon:'salary',link:'/salary',path:'',isOpen:true},
{no:22,name:'我的竞赛',icon:'competition',link:'',path:'',isOpen:false},
]
}
,{
key:'05',title:'银盾学院',subItems:[
{no:23,name:'保险ABC',icon:'insuranceABC',link:'',path:`https://${window.location.host}/issue`,isOpen:true},
{no:24,name:'岗前训',icon:'preJobTraining',link:'/prejobTraining',path:'',isOpen:true},
{no:25,name:'新人训',icon:'newTraining',link:'/newTraining',path:'',isOpen:true},
{no:26,name:'提升训',icon:'promotionTraining',link:'/advanceTraining',path:'',isOpen:true},
{no:27,name:'CFFP培训',icon:'cffpTraining',link:'/cffpTraining',path:'',isOpen:true},
{no:28,name:'产品培训',icon:'productTraining',link:'/productTraining',path:'',isOpen:true},
{no:29,name:'我的培训',icon:'training',link:'',path:'',isOpen:false},
]
}
,{
key:'06',title:'我的团队',subItems:[
{no:30,name:'我的团队',icon:'team',link:'/teamPanel',path:'',isOpen:true},
{no:31,name:'团队业绩',icon:'teamPerformance',link:'/teamRank',path:'',isOpen:true},
{no:32,name:'团队晋升考核',icon:'teamPromotionAssessment',link:'',path:'',isOpen:false},
{no:33,name:'团队PEP',icon:'temPEP',link:'/teamPanel/teamSalesScore',path:'',isOpen:true},
{no:34,name:'团队学习',icon:'teamLearning',link:'',path:'',isOpen:false},
{no:35,name:'团队竞赛',icon:'teamCompetition',link:'',path:'',isOpen:false},
]
}
]
public state = {
modal1:false
}
onClose(key) {
this.state[key] = false;
}
featureSelect(item){
if(!item.isOpen){
this.state['modal1'] = true;
}
if(item.path){
window.open(item.path);
}else if(item.link){
this.router.navigate([`./${item.link}`]);
}
}
// 返回上一页
goBack(){
this.location.back()
}
constructor(private router:Router,private location:Location) { }
ngOnInit() {
}
}
.wrapper {
padding-bottom: 40px;
font-size: 16px;
background-color: #fff;
select {
-webkit-appearance: none;
border: none;
......@@ -44,7 +45,7 @@
color: #fff;
background: #0767bf;
text-align: center;
bottom: 5px;
bottom: 56px;
}
.contentDetail {
margin-top: 15px;
......@@ -141,7 +142,7 @@
color: #fff;
background: #0767bf;
text-align: center;
bottom: 5px;
bottom: 55px;
font-size: 28px;
// color: #ff5933;
font-weight: bold;
......@@ -176,7 +177,7 @@
}
.viewReportBtn{
position: fixed;
bottom: 0;
bottom: 50px;
left: 0;
width: 100%;
height: 44px;
......@@ -187,7 +188,7 @@
}
.send{
position: fixed;
bottom: 30px;
bottom: 60px;
width: 100%;
div{
margin: 0 40px;
......
.salesWrapper{
width: 100%;
height: 100%;
height: calc(100vh - 49px);
overflow: auto;
background:#fff;
.search_wrapper{
......@@ -94,7 +94,7 @@
color: #fff;
font-size: 18px;
position: fixed;
bottom: 0;
bottom: 50px;
text-align: center;
}
}
\ No newline at end of file
......@@ -18,14 +18,14 @@
</section>
<section style="margin-top:-85px;">
<!-- banner图 -->
<WingBlank *ngIf="bannerLists.data.length>0">
<WingBlank *ngIf="bannerLists.length>0">
<Carousel [infinite]="true"
[vertical]="false"
[selectedIndex]="1"
>
<CarouselSlide *ngFor="let item of bannerLists.data">
<div style="display: inline-block; width: 100%;border-radius:10px;overflow:hidden" [ngStyle]="{'height': bannerLists.imgHeight}">
<img src="{{item}}" style=" pointer-events: none; width: 100%;"/>
<CarouselSlide *ngFor="let item of bannerLists" (click)="goBannerPro(item.destinationAddress)">
<div style="display: inline-block; width: 100%;border-radius:10px;overflow:hidden" [ngStyle]="{'height': '145px'}">
<img src="{{item.filePath}}" style=" pointer-events: none; width: 100%;" />
</div>
</CarouselSlide>
</Carousel>
......@@ -46,7 +46,7 @@
<!-- 公告 -->
<div>
<img src="assets/images/indexIcons/notice.png" alt="" srcset="">
<span>银盾公告</span>
<span>{{announcementInfo}}</span>
</div>
<div>
<i class="iconfont icon-fanhui"></i>
......@@ -56,7 +56,7 @@
<!-- 热销产品 -->
<h4>热销产品</h4>
<ul>
<li *ngFor="let item of hotProductLists">
<li *ngFor="let item of hotProductLists" (click)="goProductDetail(item)">
<div>
<h5>{{item.planName}}</h5>
<p *ngFor="let label of item.labels" class="strengths"><span>.</span><span>{{label}}</span></p>
......@@ -69,15 +69,22 @@
<!-- 互联网产品 -->
<div>
<h4>互联网产品</h4>
<div class="viewMore" [routerLink]="'/product'">
<div class="viewMore" (click)="searchProduct()">
<span>更多</span>
<i class="iconfont icon-fanhui"></i>
</div>
</div>
<ul>
<li *ngFor="let item of onlineProductLists">
<li *ngFor="let item of onlineProductLists" (click)="goProductDetail(item)">
<h5>{{item.planName}}</h5>
<p *ngFor="let label of item.labels" class="strengths">{{label}}</p>
<div class="desc">
<div>
<p *ngFor="let label of item.labels" class="strengths">{{label}}</p>
</div>
<div>
<img src="{{item.iconPath}}" alt="" srcset="">
</div>
</div>
</li>
</ul>
</section>
......
......@@ -9,7 +9,7 @@
.searchContent{
display: flex;
align-items: center;
background-color: #cbe5ff;
background-color: #c8e5ff;
padding: 7px 10px 90px;
i{
flex-basis: 24px;
......@@ -76,7 +76,6 @@
height:16px;
background-color: #5F83FF;
border-radius: 2px;
}
}
}
......@@ -198,15 +197,25 @@
white-space: nowrap;
line-height: 18px;
}
>p{
font-size: 12px;
font-weight: 400;
color: #666666;
width: 96%;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
.desc{
display: flex;
justify-content: space-between;
>div{
p{
font-size: 12px;
font-weight: 400;
color: #666666;
width: 100%;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
img{
width: 44px;
}
}
}
}
}
......
import { Component, OnInit, ViewChild, ElementRef, AfterViewInit } from '@angular/core';
import { Router } from '@angular/router';
import { LifeCommonService } from 'src/app/common/life-common.service';
import { MyService } from '../my.service';
declare var wx: any;
@Component({
......@@ -8,21 +9,21 @@ declare var wx: any;
styleUrls: ['./my-center-home.component.scss'],
})
export class MyCenterHomeComponent implements OnInit {
public searchText:string;
productInfo: any;
inquiry: any;
public announcementInfo: string;
public searchText: string;
public featureLists = [
{key:'00',name:'产品库',icon:'productLibary',link:'/product',isOpen:true},
{key:'01',name:'计划书',icon:'proposals',link:'',isOpen:false},
{key:'02',name:'我的保单',icon:'policyLists',link:'/salesDetail',isOpen:true},
{key:'03',name:'续期管理',icon:'renewalManagement',link:'/renewal_reminder',isOpen:true},
{key:'04',name:'成交客户',icon:'customers',link:'/customer',isOpen:true},
{key:'05',name:'我的增员',icon:'increaseStaff',link:'/business',isOpen:true},
{key:'06',name:'银盾学院',icon:'ydCollege',link:'',isOpen:false},
{key:'07',name:'更多功能',icon:'more',link:'',isOpen:true}
{ key: '00', name: '产品库', icon: 'productLibary', link: '/product', isOpen: true },
{ key: '01', name: '计划书', icon: 'proposals', link: '', isOpen: false },
{ key: '02', name: '我的保单', icon: 'policyLists', link: '/salesDetail', isOpen: true },
{ key: '03', name: '续期管理', icon: 'renewalManagement', link: '/renewal_reminder', isOpen: true },
{ key: '04', name: '成交客户', icon: 'customers', link: '/customer', isOpen: true },
{ key: '05', name: '我的增员', icon: 'increaseStaff', link: '/recruiting', isOpen: true },
{ key: '06', name: '银盾学院', icon: 'ydCollege', link: '', isOpen: false },
{ key: '07', name: '更多功能', icon: 'more', link: '/moreFeatures', isOpen: true }
]
public bannerLists = {
data: [],
imgHeight: '145px'
};
public bannerLists = [];
public hotProductLists = [];
public onlineProductLists = [];
state = {
......@@ -33,51 +34,114 @@ export class MyCenterHomeComponent implements OnInit {
}
submit(value) {
if(value.trim()){
this.router.navigate(['/product',{queryName:value.trim()}])
if (value.trim()) {
this.router.navigate(['/product', { queryName: value.trim() }])
}
}
searchProduct() {
// 查询互联网产品
this.router.navigate(['/product', { queryTagId: 272 }])
}
clear(value) {
this.searchText = '';
}
// 查询银盾公告
announcementQuery() {
this.myService.announcementQuery(null, 37).subscribe(res => {
if (res['success']) {
this.announcementInfo = res['data']['announcementInfoList'] ? res['data']['announcementInfoList'][0]['title'] : '银盾公告'
}
})
}
// 点击模块导航
featureSelect(item){
if(item.isOpen){
featureSelect(item) {
if (item.isOpen) {
this.router.navigate([item.link]);
}else{
} else {
this.state.modal1 = true;
}
}
// 获取轮播图
filePathQuery(){
this.myService.filePath(6,0,7,null,null).subscribe(res=>{
if(res['success']){
this.bannerLists.data = [];
for(let item of res['data']['fileUploadItemList']){
this.bannerLists.data.push(item.filePath)
}
filePathQuery() {
this.myService.filePath(6, 0, 7, null, null).subscribe(res => {
if (res['success']) {
this.bannerLists = res['data']['fileUploadItemList'] || [];
}
})
}
// 模糊查询产品
queryproductlistbytag(tagId,dataName){
this.myService.queryproductlistbytag({mdTagId:tagId}).subscribe(res=>{
if(res['success']){
queryproductlistbytag(tagId, dataName) {
this.myService.queryproductlistbytag({ mdTagId: tagId }).subscribe(res => {
if (res['success']) {
this[dataName] = res['data']['plans']
}
})
}
constructor(private myService:MyService,private router:Router){}
// 点击产品进入详情页
goProductDetail(product): void {
if (product.isThirdpartyPurchase == 1) {
if (product.thirdpartyPurchaseUrl) {
window.location.href = product.thirdpartyPurchaseUrl;
} else {
alert('请配置跳转链接');
}
} else {
this.productInfo = product;
this.productInfo.type = 2;
this.inquiry = {
planId: this.productInfo.planId,
adultCount: this.productInfo.adultCount,
childCount: this.productInfo.childCount,
eldCount: this.productInfo.eldCount,
dayCount: this.productInfo.minDay
};
this.setInitDate();
localStorage.setItem('inquiry', JSON.stringify(this.inquiry));
if (this.productInfo.noPlanProduct === true) {
window.location.href = `https://${window.location.host}/life/${this.productInfo.productId}`
} else {
if (this.productInfo.productCategoryId === 1 || this.productInfo.productCategoryId === 4) {
window.location.href = `https://${window.location.host}/pdetail/${this.productInfo.planId}`
} else if (this.productInfo.productCategoryId === 2) {
window.location.href = `https://${window.location.host}/hProductDetail/${this.productInfo.planId}?type=7`
} else if (this.productInfo.productCategoryId === 5) {
window.location.href = `https://${window.location.host}/hProductDetail/${this.productInfo.planId}?type=9`
} else {
window.location.href = `https://${window.location.host}/life/${this.productInfo.productId}`
this.router.navigate(['/pdetail', this.productInfo.planId]);
}
}
}
}
// 根据开始时间设置结束时间,天数应减1,当日~当日是一天
setInitDate() {
this.productInfo.dayCount = this.lifeCommonService.yearDayCount(this.productInfo.dayCount, this.productInfo.insurerId == '5');
this.lifeCommonService.setInitDate(this.productInfo.dayCount);
}
goBannerPro(destinationAddress) {
if (destinationAddress) {
window.open(destinationAddress);
} else {
return;
}
}
constructor(private myService: MyService, private router: Router, private lifeCommonService: LifeCommonService) { }
ngOnInit(): void {
this.filePathQuery()
// 查询互联网产品
this.queryproductlistbytag(272,'onlineProductLists');
this.queryproductlistbytag(272, 'onlineProductLists');
// 查询热销产品
this.queryproductlistbytag(119,'hotProductLists');
this.queryproductlistbytag(119, 'hotProductLists');
// 查询最新一条公告
this.announcementQuery();
}
}
......
......@@ -77,6 +77,8 @@ import { IntegrationRuleComponent } from './integration-rule/integration-rule.co
import { VideoComponent } from '../common/video/video.component';
import { QrcodeUploadComponent } from './application-process/qrcode-upload/qrcode-upload.component';
import { NewsDetailComponent } from './news-detail/news-detail.component';
import { MoreFeaturesComponent } from './more-features/more-features.component';
import { MineComponent } from './mine/mine.component';
const myRoutes: Routes = [
......@@ -178,6 +180,8 @@ const myRoutes: Routes = [
{ path: 'video',component:VideoComponent,canActivate:[AuthGuard],data:{title: '视频播放'}},
{ path: 'pdfView',component:VideoComponent,canActivate:[AuthGuard],data:{title: 'PDF查看'}},
{ path: 'newsDetail/:id',component:NewsDetailComponent,canActivate:[AuthGuard],data:{title: '消息详情'}},
{ path: 'moreFeatures',component:MoreFeaturesComponent,canActivate:[AuthGuard],data:{title: '全部工具'}},
{ path: 'mine',component:MineComponent,canActivate:[AuthGuard],data:{title: '全部工具'}},
];
......
......@@ -86,7 +86,7 @@
color: #fff;
background: #0767bf;
text-align: center;
bottom: 30px;
bottom: 60px;
font-size: 28px;
// color: #ff5933;
font-weight: bold;
......
......@@ -92,9 +92,11 @@ import { IntegrationRuleComponent } from './integration-rule/integration-rule.co
import { VideoComponent } from '../common/video/video.component';
import { QrcodeUploadComponent } from './application-process/qrcode-upload/qrcode-upload.component';
import { NewsDetailComponent } from './news-detail/news-detail.component';
import { MoreFeaturesComponent } from './more-features/more-features.component';
import { MineComponent } from './mine/mine.component';
@NgModule({
declarations: [MyCenterHomeComponent, MkMaterialComponent, MkMaterialDetailComponent, FileUploadComponent, ImportantAnnouncementComponent, SalesDetailComponent, AnnouncementDetailComponent, MyBusinessComponent, MyBusinessDetailComponent, PickerComponent, MyToastComponent, SalesRankComponent, TeamRankComponent, RecruitingComponent, RecruitingDetailComponent, ThanksComponent, MySettingComponent, MySettingDetailComponent, MyNewsComponent, MyTargetComponent, TeamPanelComponent, SwitchNumberPipe,SafeResourceUrlPipe, TeamSalesScoreComponent, ScoreDetailsComponent, BusinessCardComponent, OrderDetailComponent, SalaryComponent, TodoListComponent, AddTaskComponent, MedicalServiceComponent, InvitationComponent, RegisterComponent, EmployeeInfoComponent, EmployeeBasicInfoComponent, WorkExperienceComponent, PersonalPhotosComponent, EmployeeIdCardComponent, EmployeeEducationComponent, PersonalStatementComponent, SignatureComponent, EmployeeSubmitComponent, BankCardComponent, MemberDetailComponent, ApprovalListComponent, ApprovalCommentsComponent, ApprovalResultListComponent, MyApplicationComponent, SuggestionComponent, EmployeeSalaryComponent, HistoricalRankComponent, TeamAreaPanelComponent, ArticleComponent, ArticleDetailComponent, ArticleReadComponent,SalaryDetailComponent,SalaryFirstYearComponent,DetailModalComponent, ProductComponent, ProductDataComponent, CommissionComponent, FileListComponent,MyCustomerComponent, CustomerRelationComponent, MyCustomerPolicyComponent, UnderwritingKnowledgeComponent, MyQuestionComponent, AskComponent, MenuItemComponent, MemberListComponent, ENoticeComponent, ENoticeSignComponent, RenewalReminderComponent, RenewalReminderDetailComponent, JointSalesComponent, JointSaleDetailComponent, IntegrationComponent, IntegrationDetailComponent, IntegrationRuleComponent, VideoComponent, QrcodeUploadComponent, NewsDetailComponent],
declarations: [MyCenterHomeComponent, MkMaterialComponent, MkMaterialDetailComponent, FileUploadComponent, ImportantAnnouncementComponent, SalesDetailComponent, AnnouncementDetailComponent, MyBusinessComponent, MyBusinessDetailComponent, PickerComponent, MyToastComponent, SalesRankComponent, TeamRankComponent, RecruitingComponent, RecruitingDetailComponent, ThanksComponent, MySettingComponent, MySettingDetailComponent, MyNewsComponent, MyTargetComponent, TeamPanelComponent, SwitchNumberPipe,SafeResourceUrlPipe, TeamSalesScoreComponent, ScoreDetailsComponent, BusinessCardComponent, OrderDetailComponent, SalaryComponent, TodoListComponent, AddTaskComponent, MedicalServiceComponent, InvitationComponent, RegisterComponent, EmployeeInfoComponent, EmployeeBasicInfoComponent, WorkExperienceComponent, PersonalPhotosComponent, EmployeeIdCardComponent, EmployeeEducationComponent, PersonalStatementComponent, SignatureComponent, EmployeeSubmitComponent, BankCardComponent, MemberDetailComponent, ApprovalListComponent, ApprovalCommentsComponent, ApprovalResultListComponent, MyApplicationComponent, SuggestionComponent, EmployeeSalaryComponent, HistoricalRankComponent, TeamAreaPanelComponent, ArticleComponent, ArticleDetailComponent, ArticleReadComponent,SalaryDetailComponent,SalaryFirstYearComponent,DetailModalComponent, ProductComponent, ProductDataComponent, CommissionComponent, FileListComponent,MyCustomerComponent, CustomerRelationComponent, MyCustomerPolicyComponent, UnderwritingKnowledgeComponent, MyQuestionComponent, AskComponent, MenuItemComponent, MemberListComponent, ENoticeComponent, ENoticeSignComponent, RenewalReminderComponent, RenewalReminderDetailComponent, JointSalesComponent, JointSaleDetailComponent, IntegrationComponent, IntegrationDetailComponent, IntegrationRuleComponent, VideoComponent, QrcodeUploadComponent, NewsDetailComponent, MoreFeaturesComponent, MineComponent],
imports: [
CommonModule,
LifeCommonModule,
......
......@@ -55,6 +55,7 @@
}
.right {
width: calc(100% - 90px);
height: calc(100vh - 44px);
position: relative;
background-color: #fff;
.mask {
......@@ -93,6 +94,7 @@
padding: 20px 0 20px 10px;
z-index: 1000;
overflow-y: auto;
margin-top: -44px;
ul{
> li {
margin-bottom: 10px;
......
......@@ -25,6 +25,7 @@ export class ProductComponent implements OnInit {
rightTagIds:Array<any> = [];
topAndright:Array<any> = [];
queryName:string;
queryTagId:number;
constructor(private myService: MyService,
public lifeCommonService: LifeCommonService,
private router: Router,
......@@ -38,6 +39,7 @@ export class ProductComponent implements OnInit {
this.tagViewQuery(305,true);
this.tagViewQuery(309,true);
this.queryName = this.route.snapshot.params['queryName'];
this.queryTagId = this.route.snapshot.params['queryTagId'];
}
clear() {
......@@ -91,6 +93,8 @@ export class ProductComponent implements OnInit {
if(isFirstSearch){
if(this.queryName){
this.switchCategory(1,null);
}else if(this.queryTagId){
this.switchCategory(1,{id:270,tagId:this.queryTagId});
}else{
this.switchCategory(1,this.leftList[0])
}
......
......@@ -14,7 +14,7 @@
background: #C81B1E;
line-height: 56px;
position: fixed;
bottom: 0;
bottom: 50px;
color: #fff;
text-align: center;
font-size: 19px;
......@@ -59,7 +59,7 @@
color: #fff;
background: #0767bf;
text-align: center;
bottom: 5px;
bottom: 55px;
left: 42%;
}
.contentDetail {
......@@ -171,7 +171,7 @@
color: #fff;
background: #0767bf;
text-align: center;
bottom: 5px;
bottom: 55px;
font-size: 28px;
// color: #ff5933;
font-weight: bold;
......
......@@ -113,7 +113,7 @@
color: #fff;
font-size: 18px;
position: fixed;
bottom: 0;
bottom: 50px;
text-align: center;
}
}
......@@ -82,7 +82,7 @@
text-align: center;
font-size: 18px;
color: #1B5B99;
margin: 100px auto 30px;
margin: 80px auto 30px;
}
ul{
display: flex;
......@@ -107,7 +107,7 @@
left: 0;
width: 80%;
margin: 0 auto;
transform: translate(13%,100%);
transform: translate(13%,30%);
background-color: #fff;
border-radius: 6px;
padding: 10px 20px;
......
......@@ -78,7 +78,7 @@
min-width: 320px;
max-width: 640px;
width: 100%;
bottom: 0;
bottom: 49px;
width: 92%;
margin: 3px auto;
height: 50px;
......
......@@ -182,7 +182,10 @@
min-width: 320px;
max-width: 640px;
margin: 0 auto;
bottom: 0;
bottom: 49px;
color: #fff;
text-align: center;
width: 100%;
}
}
.editContainer {
......@@ -190,7 +193,7 @@
background: #ffffff;
padding: 10px;
position: fixed;
bottom: 0;
bottom: 49px;
width: 100%;
height: 45%;
background-color: #fff;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment