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
2850fb13
Commit
2850fb13
authored
Mar 02, 2020
by
sunchao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
重要公告bug修复
parent
e7d273b3
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
14 additions
and
4 deletions
+14
-4
src/app/my/my-center-home/my-center-home.component.html
+2
-1
src/app/my/my-center-home/my-center-home.component.ts
+12
-3
No files found.
src/app/my/my-center-home/my-center-home.component.html
View file @
2850fb13
...
@@ -75,7 +75,8 @@
...
@@ -75,7 +75,8 @@
<div
class=
"performance_wrapper notice"
>
<div
class=
"performance_wrapper notice"
>
<div
style=
"position: relative;"
>
<div
style=
"position: relative;"
>
<h3
style=
"font-size: 16px;color: #ff002a;"
>
公告
</h3><i
class=
"iconfont"
style=
"color: #ff002a;"
>

</i>
<h3
style=
"font-size: 16px;color: #ff002a;"
>
公告
</h3><i
class=
"iconfont"
style=
"color: #ff002a;"
>

</i>
<div
#
hide
style=
"font-size: 14px;"
[
innerHtml
]="
firstAnnouncement
"
></div>
<div
#
hide
style=
"font-size: 14px;position: absolute;z-index:-100"
[
innerHtml
]="
firstAnnouncement
"
></div>
<div>
{{this.firstAnnouncementTitle}}
</div>
<span
style=
"position:absolute;right:5px;font-size: 12px;color:#408dc9;"
routerLink=
"importantAnnouncement"
>
更多
</span>
<span
style=
"position:absolute;right:5px;font-size: 12px;color:#408dc9;"
routerLink=
"importantAnnouncement"
>
更多
</span>
</div>
</div>
</div>
</div>
...
...
src/app/my/my-center-home/my-center-home.component.ts
View file @
2850fb13
import
{
Component
,
OnInit
}
from
'@angular/core'
;
import
{
Component
,
OnInit
,
ViewChild
,
ElementRef
,
AfterViewInit
}
from
'@angular/core'
;
import
{
Router
}
from
"@angular/router"
;
import
{
Router
}
from
"@angular/router"
;
import
{
LifeCommonService
}
from
"../../common/life-common.service"
;
import
{
LifeCommonService
}
from
"../../common/life-common.service"
;
import
{
environment
}
from
"../../../environments/environment"
;
import
{
environment
}
from
"../../../environments/environment"
;
...
@@ -12,7 +12,8 @@ declare var wx: any;
...
@@ -12,7 +12,8 @@ declare var wx: any;
templateUrl
:
'./my-center-home.component.html'
,
templateUrl
:
'./my-center-home.component.html'
,
styleUrls
:
[
'./my-center-home.component.scss'
]
styleUrls
:
[
'./my-center-home.component.scss'
]
})
})
export
class
MyCenterHomeComponent
implements
OnInit
{
export
class
MyCenterHomeComponent
implements
OnInit
,
AfterViewInit
{
@
ViewChild
(
'hide'
)
hide
:
ElementRef
menuLists
:
Array
<
any
>
;
menuLists
:
Array
<
any
>
;
isNeedAlert
:
boolean
;
isNeedAlert
:
boolean
;
dialogInfo
:
any
;
dialogInfo
:
any
;
...
@@ -28,6 +29,7 @@ export class MyCenterHomeComponent implements OnInit {
...
@@ -28,6 +29,7 @@ export class MyCenterHomeComponent implements OnInit {
products
:
Plans
[];
products
:
Plans
[];
productInfo
:
Plans
;
productInfo
:
Plans
;
inquiry
:
User
;
inquiry
:
User
;
firstAnnouncementTitle
:
string
;
constructor
(
constructor
(
private
router
:
Router
,
private
router
:
Router
,
private
lifeCommonService
:
LifeCommonService
,
private
lifeCommonService
:
LifeCommonService
,
...
@@ -101,6 +103,12 @@ export class MyCenterHomeComponent implements OnInit {
...
@@ -101,6 +103,12 @@ export class MyCenterHomeComponent implements OnInit {
this
.
recommendPlanQuery
();
this
.
recommendPlanQuery
();
}
}
ngAfterViewInit
()
{
setTimeout
(()
=>
{
this
.
firstAnnouncementTitle
=
this
.
getStr
(
this
.
hide
.
nativeElement
.
innerText
,
'28'
)
},
500
);
}
// 菜单导航
// 菜单导航
menuNavigation
(
item
)
{
menuNavigation
(
item
)
{
if
(
item
.
routerLink
)
{
if
(
item
.
routerLink
)
{
...
@@ -139,7 +147,8 @@ export class MyCenterHomeComponent implements OnInit {
...
@@ -139,7 +147,8 @@ export class MyCenterHomeComponent implements OnInit {
this
.
myService
.
announcementQuery
(
null
,
null
).
subscribe
(
res
=>
{
this
.
myService
.
announcementQuery
(
null
,
null
).
subscribe
(
res
=>
{
if
(
res
[
'success'
])
{
if
(
res
[
'success'
])
{
this
.
announcementLists
=
res
[
'data'
][
'announcementInfoList'
];
this
.
announcementLists
=
res
[
'data'
][
'announcementInfoList'
];
this
.
firstAnnouncement
=
this
.
getStr
(
this
.
announcementLists
[
0
][
'title'
],
'36'
);
this
.
firstAnnouncement
=
this
.
announcementLists
[
0
][
'title'
];
}
}
});
});
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment