Browse Source

[完善] 登录页面完善, echarts数据处理完善

master
陈鹏飞 5 years ago
parent
commit
2cea294a90
  1. 2
      src/app/pages/lockscreen/lockscreen.component.html
  2. 2
      src/app/pages/lockscreen/lockscreen.component.ts
  3. 6
      src/app/ui/eharts-statistics/eharts-statistics.component.ts

2
src/app/pages/lockscreen/lockscreen.component.html

@ -6,8 +6,8 @@
<form (ngSubmit)="onSubmit(form.value)" #form="ngForm" class="example-container">
<div class="input" style="margin-bottom: 50px;">
<label class="role" [ngClass]="{'isCheck': roleType=='1'}" (click)='toggle(1)'>教员</label>
<label class="role" [ngClass]="{'isCheck': roleType=='2'}" (click)='toggle(2)'>学员</label>
<label class="role" [ngClass]="{'isCheck': roleType=='1'}" (click)='toggle(1)'>教员</label>
</div>
<div class="input">

2
src/app/pages/lockscreen/lockscreen.component.ts

@ -20,7 +20,7 @@ export class LockscreenComponent implements OnInit {
}
roleType:string = '1'; //登录角色
roleType:string = '2'; //登录角色
errmsg :string = ''; //错误信息

6
src/app/ui/eharts-statistics/eharts-statistics.component.ts

@ -138,9 +138,9 @@ export class EhartsStatisticsComponent implements OnInit {
return b.count - a.count
} )
newData.forEach(element => {
postNames.push(element.postName)
catalogs.push(element.catalog)
counts.push(element.count)
postNames.push(element.postName ? element.postName : '暂无数据')
catalogs.push(element.catalog ? element.catalog : '暂无数据')
counts.push(element.count ? element.count : 0)
});
this.echartsInit(postNames,catalogs,counts)
}

Loading…
Cancel
Save