Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
P
party-build-cloud
Project
Project
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wangqinghua
party-build-cloud
Commits
5c38ee91
Commit
5c38ee91
authored
Apr 29, 2019
by
wangqinghua
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
发现二级菜单
parent
eb1043ff
Show whitespace changes
Inline
Side-by-side
Showing
15 changed files
with
354 additions
and
34 deletions
+354
-34
app.scss
src/app/app.scss
+2
-2
party.json
src/assets/json/party.json
+109
-0
index.html
src/index.html
+1
-1
search-new.html
src/pages/home-pages/search-new/search-new.html
+20
-1
search-new.scss
src/pages/home-pages/search-new/search-new.scss
+3
-1
search-new.ts
src/pages/home-pages/search-new/search-new.ts
+7
-0
learn-manage.scss
src/pages/home/learn-manage/learn-manage/learn-manage.scss
+16
-0
person.html
src/pages/home/surveyManage/modal/person/person.html
+1
-1
discover.html
src/pages/tabs/discover/discover.html
+11
-2
discover.scss
src/pages/tabs/discover/discover.scss
+23
-2
discover.ts
src/pages/tabs/discover/discover.ts
+148
-14
home.html
src/pages/tabs/home/home.html
+3
-6
home.scss
src/pages/tabs/home/home.scss
+1
-0
home.ts
src/pages/tabs/home/home.ts
+3
-4
tabs.service.ts
src/pages/tabs/tabs.service.ts
+6
-0
No files found.
src/app/app.scss
View file @
5c38ee91
...
...
@@ -203,8 +203,8 @@ p {
#tips
{
position
:
absolute
;
bottom
:
0
;
height
:
3
px
;
bottom
:
5px
;
height
:
2
px
;
width
:
3rem
;
background-color
:
#e12724
;
-webkit-transition
:
left
500ms
;
...
...
src/assets/json/party.json
0 → 100644
View file @
5c38ee91
[
{
"name"
:
"支部风采"
,
"type"
:
13
,
"index"
:
0
,
"children"
:
[
{
"name"
:
"推荐"
,
"type"
:
13
},
{
"name"
:
"支部活动"
,
"type"
:
13
},
{
"name"
:
"党建联建"
,
"type"
:
14
},
{
"name"
:
"结对帮扶"
,
"type"
:
15
}
]
},
{
"name"
:
"机关党委"
,
"type"
:
5
,
"index"
:
1
,
"children"
:
[
{
"name"
:
"最新"
,
"type"
:
5
},
{
"name"
:
"通知公告"
,
"type"
:
5
},
{
"name"
:
"党建动态"
,
"type"
:
6
},
{
"name"
:
"工作提示"
,
"type"
:
7
},
{
"name"
:
"党务参考"
,
"type"
:
8
}
]
},
{
"name"
:
"党风廉政"
,
"type"
:
9
,
"index"
:
2
,
"children"
:
[
{
"name"
:
"最新"
,
"type"
:
9
},
{
"name"
:
"廉政格言"
,
"type"
:
9
},
{
"name"
:
"纪检提示"
,
"type"
:
10
},
{
"name"
:
"风险排查"
,
"type"
:
11
},
{
"name"
:
"警示教育"
,
"type"
:
12
}
]
},
{
"name"
:
"互动交流"
,
"type"
:
-1
,
"index"
:
3
,
"children"
:
[
{
"name"
:
"最新"
,
"type"
:
-1
},
{
"name"
:
"学思践悟"
,
"type"
:
-1
},
{
"name"
:
"话题讨论"
,
"type"
:
-1
},
{
"name"
:
"你问我答"
,
"type"
:
-1
}
]
},
{
"name"
:
"知识拓展"
,
"type"
:
-1
,
"index"
:
4
,
"children"
:
[]
}
]
\ No newline at end of file
src/index.html
View file @
5c38ee91
...
...
@@ -3,7 +3,7 @@
<head>
<meta
charset=
"UTF-8"
>
<title>
智汇组工
</title>
<title>
部机关党建云平台
</title>
<meta
name=
"viewport"
content=
"initial-scale=1, maximum-scale=1, user-scalable=no, width=device-width"
>
<!-- <meta name="viewport" content="viewport-fit=cover, width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no"> -->
...
...
src/pages/home-pages/search-new/search-new.html
View file @
5c38ee91
...
...
@@ -38,6 +38,7 @@
<span>
{{item.publishTime | date:'yyyy-MM-dd'}}
</span>
</p>
<div
class=
"item-news"
>
<ng-container
*
ngIf=
"item.imgUrl"
>
<ion-row
class=
"news-item"
>
<ion-col
col-8
class=
"news-left"
>
<p
class=
"news-title"
>
{{item.title}}
</p>
...
...
@@ -53,9 +54,27 @@
</p>
</ion-col>
<ion-col
col-4
class=
"news-right"
>
<img
src=
"./assets/imgs/demo.png
"
>
<img
[
src
]="
picture
+
item
.
imgUrl
"
>
</ion-col>
</ion-row>
</ng-container>
<ng-container
*
ngIf=
"!item.imgUrl"
>
<ion-row
class=
"news-item"
>
<ion-col
col-12
class=
"news-left"
>
<p
class=
"news-title"
>
{{item.title}}
</p>
<p
class=
"news-end"
>
<ion-icon
style=
"font-size: 2.5rem;vertical-align: sub"
name=
"eye"
></ion-icon>
<span>
{{item.browseCount}}
</span>
<ion-icon
name=
"chatboxes"
></ion-icon>
<span>
{{item.commentCount}}
</span>
<ion-icon
name=
"thumbs-up"
></ion-icon>
<span>
{{item.likeCount}}
</span>
<ion-icon
name=
"heart"
></ion-icon>
<span>
{{item.collectionCount}}
</span>
</p>
</ion-col>
</ion-row>
</ng-container>
</div>
</div>
</ng-container>
...
...
src/pages/home-pages/search-new/search-new.scss
View file @
5c38ee91
...
...
@@ -55,6 +55,7 @@ page-search-new {
align-self
:
flex-start
;
font-weight
:
bold
;
width
:
100%
;
padding
:
.5rem
0
;
}
.news-end
{
align-self
:
flex-end
;
...
...
@@ -66,8 +67,9 @@ page-search-new {
}
}
.news-right
{
padding
:
5px
0
;
text-align
:
center
;
img
{
height
:
60px
;
border-radius
:
.5rem
;
}
}
...
...
src/pages/home-pages/search-new/search-new.ts
View file @
5c38ee91
...
...
@@ -2,6 +2,7 @@ import { Component } from '@angular/core';
import
{
IonicPage
,
NavController
,
NavParams
}
from
'ionic-angular'
;
import
{
TabsService
}
from
"../../tabs/tabs.service"
;
import
{
StuffDetailPage
}
from
"../stuff-detail/stuff-detail"
;
import
{
AppGlobal
}
from
"../../../service/http.service"
;
@
IonicPage
()
...
...
@@ -11,6 +12,7 @@ import {StuffDetailPage} from "../stuff-detail/stuff-detail";
})
export
class
SearchNewPage
{
picture
:
string
=
AppGlobal
.
domain
+
'/wisdomgroup'
;
newList
=
[];
searchObj
=
{
title
:
''
,
...
...
@@ -41,6 +43,11 @@ export class SearchNewPage {
this
.
tabs
.
stuffPage
(
data
).
subscribe
(
(
res
)
=>
{
this
.
newList
=
res
.
data
;
this
.
newList
.
forEach
(
e
=>
{
if
(
e
.
attachments
.
length
>
0
)
{
e
.
imgUrl
=
e
.
attachments
[
0
].
path
;
}
})
}
)
}
...
...
src/pages/home/learn-manage/learn-manage/learn-manage.scss
View file @
5c38ee91
...
...
@@ -25,4 +25,20 @@ page-learn-manage {
font-size
:
1
.5rem
;
border-radius
:
2px
;
}
.tabs-parent
{
display
:
flex
;
flex-direction
:
row
;
flex-wrap
:
nowrap
;
position
:
relative
;
background-color
:
#fff
;
margin-bottom
:
.5rem
;
font-size
:
1
.7rem
;
.tabs-children
{
flex
:
1
;
text-align
:
center
;
cursor
:
pointer
;
height
:
4rem
;
line-height
:
4rem
;
}
}
}
src/pages/home/surveyManage/modal/person/person.html
View file @
5c38ee91
...
...
@@ -18,7 +18,7 @@
<ion-content
padding
>
<ion-list
radio-group
[(
ngModel
)]="
group
"
>
<ion-list
radio-group
[(
ngModel
)]="
group
"
(
ionChange
)="
change
()"
>
<ion-item
*
ngFor=
"let item of batchList;let i = index;"
>
<ion-label>
{{item.groupName}}
</ion-label>
<ion-label>
{{item.groupCount}}人
</ion-label>
...
...
src/pages/tabs/discover/discover.html
View file @
5c38ee91
...
...
@@ -27,13 +27,22 @@
<div
class=
"scroll-tab"
>
<div
class=
"news-content"
>
<div
#
tabsParent
class=
"tabs-parent"
>
<div
#
tabsChildren
*
ngFor=
"let item of tabsList;"
(
click
)="
change
(
item
)"
class=
"tabs-children"
>
<span
#
tabSpan
[
style
.
color
]="
index =
=
item
.
type
?
'#
e12724
'
:
''"
>
{{item.name}}
</span>
<div
#
tabsChildren
*
ngFor=
"let item of tabsList;"
(
click
)="
changeParent
(
item
)"
class=
"tabs-children"
>
<span
#
tabSpan
[
style
.
color
]="
indexParent =
=
item
.
indexParent
?
'#
e12724
'
:
''"
>
{{item.name}}
</span>
</div>
<span
#
tips
id=
"tips"
></span>
</div>
</div>
</div>
<div
class=
"scroll-tab"
>
<div
class=
"news-content"
#
newsContent
>
<div
class=
"tabs-parent"
>
<div
class=
"tabs-child"
>
<span
*
ngFor=
"let ch of childrenList"
[
ngClass
]="{'
select
'
:indexChildren =
=
ch
.
indexChildren
}"
(
click
)="
changeChildren
(
ch
)"
>
{{ch.name}}
</span>
</div>
</div>
</div>
</div>
<div
class=
"search-content"
>
<ng-container
*
ngFor=
"let item of newList"
>
...
...
src/pages/tabs/discover/discover.scss
View file @
5c38ee91
...
...
@@ -73,7 +73,7 @@ page-discover {
display
:
flex
;
flex-flow
:
row
wrap
;
min-height
:
100%
;
padding
:
5px
0
;
padding
:
5px
;
.news-title
{
align-self
:
flex-start
;
font-weight
:
bold
;
...
...
@@ -91,7 +91,8 @@ page-discover {
}
}
.news-right
{
padding
:
5px
0
;
padding
:
5px
;
text-align
:
center
;
img
{
border-radius
:
.5rem
;
}
...
...
@@ -101,4 +102,24 @@ page-discover {
border-top
:
1px
solid
#eeeeee
;
}
}
.tabs-child
{
padding
:
0
1rem
;
span
{
display
:
inline-block
;
background-color
:
#f2f2f2
;
color
:
#777777
;
border-radius
:
5px
;
margin-right
:
10px
;
width
:
6rem
;
padding
:
3px
0
;
text-align
:
center
;
font-size
:
1
.4rem
;
border
:
1px
solid
#f2f2f2
;
}
span
.select
{
background-color
:
#fed3d3
;
color
:
#e12724
;
border
:
1px
solid
#e12724
;
}
}
}
src/pages/tabs/discover/discover.ts
View file @
5c38ee91
...
...
@@ -19,15 +19,123 @@ export class DiscoverPage {
@
ViewChild
(
'tabsParent'
)
tabsParent
:
ElementRef
;
@
ViewChild
(
'tabsChildren'
)
tabsChildren
:
ElementRef
;
@
ViewChild
(
'tabSpan'
)
tabSpan
:
ElementRef
;
@
ViewChild
(
'newsContent'
)
newsContent
:
ElementRef
;
//所属板块类型:
//1党章党规,2系列讲话,3中央精神,4本市部署,5通知公告,6党建动态,7工作提示,8党务参考
//9廉政格言,10纪检提示,11风险排查,12警示教育,13支部活动,14党建联建,15结对帮扶
tabsList
=
[
{
name
:
"支部风采"
,
type
:
13
,
index
:
0
},
{
name
:
"机关党委"
,
type
:
5
,
index
:
1
},
{
name
:
"党风廉政"
,
type
:
9
,
index
:
2
},
{
name
:
"互动交流"
,
type
:
-
1
,
index
:
3
},
{
name
:
"知识拓展"
,
type
:
-
1
,
index
:
4
},
{
"name"
:
"支部风采"
,
"type"
:
13
,
"indexParent"
:
0
,
"children"
:
[
{
"name"
:
"推荐"
,
"type"
:
13
,
"indexChildren"
:
'01'
},
{
"name"
:
"支部活动"
,
"type"
:
13
,
"indexChildren"
:
'02'
},
{
"name"
:
"党建联建"
,
"type"
:
14
,
"indexChildren"
:
'03'
},
{
"name"
:
"结对帮扶"
,
"type"
:
15
,
"indexChildren"
:
'04'
}
]
},
{
"name"
:
"机关党委"
,
"type"
:
5
,
"indexParent"
:
1
,
"children"
:
[
{
"name"
:
"最新"
,
"type"
:
5
,
"indexChildren"
:
'11'
},
{
"name"
:
"通知公告"
,
"type"
:
5
,
"indexChildren"
:
'12'
},
{
"name"
:
"党建动态"
,
"type"
:
6
,
"indexChildren"
:
'13'
},
{
"name"
:
"工作提示"
,
"type"
:
7
,
"indexChildren"
:
'14'
},
{
"name"
:
"党务参考"
,
"type"
:
8
,
"indexChildren"
:
'15'
}
]
},
{
"name"
:
"党风廉政"
,
"type"
:
9
,
"indexParent"
:
2
,
"children"
:
[
{
"name"
:
"最新"
,
"type"
:
9
,
"indexChildren"
:
'21'
},
{
"name"
:
"廉政格言"
,
"type"
:
9
,
"indexChildren"
:
'22'
},
{
"name"
:
"纪检提示"
,
"type"
:
10
,
"indexChildren"
:
'23'
},
{
"name"
:
"风险排查"
,
"type"
:
11
,
"indexChildren"
:
'24'
},
{
"name"
:
"警示教育"
,
"type"
:
12
,
"indexChildren"
:
'25'
}
]
},
{
"name"
:
"互动交流"
,
"type"
:
-
1
,
"indexParent"
:
3
,
"children"
:
[
{
"name"
:
"最新"
,
"type"
:
-
1
,
"indexChildren"
:
'31'
},
{
"name"
:
"学思践悟"
,
"type"
:
-
1
,
"indexChildren"
:
'32'
},
{
"name"
:
"话题讨论"
,
"type"
:
-
1
,
"indexChildren"
:
'33'
},
{
"name"
:
"你问我答"
,
"type"
:
-
1
,
"indexChildren"
:
'34'
}]
},
{
"name"
:
"知识拓展"
,
"type"
:
-
1
,
"indexParent"
:
4
,
"children"
:
[]}
];
index
=
0
;
childrenList
=
[];
indexParent
=
0
;
indexChildren
=
0
;
isSign
=
false
;
newList
;
//新闻列表
noReadNum
;
...
...
@@ -44,28 +152,54 @@ export class DiscoverPage {
}
ionViewDidEnter
()
{
this
.
change
(
this
.
tabsList
[
0
]);
this
.
change
Parent
(
this
.
tabsList
[
0
]);
}
//所属板块类型:
//1党章党规,2系列讲话,3中央精神,4本市部署,5通知公告,6党建动态,7工作提示,8党务参考
//9廉政格言,10纪检提示,11风险排查,12警示教育,13支部活动,14党建联建,15结对帮扶
change
(
item
)
{
const
index
=
item
.
index
;
//父级选择
changeParent
(
item
)
{
console
.
log
(
this
.
newsContent
);
this
.
newsContent
.
nativeElement
.
scrollLeft
=
0
;
//二级菜单滑动重置
const
index
=
item
.
indexParent
;
this
.
indexParent
=
index
;
this
.
childrenList
=
item
.
children
;
this
.
indexChildren
=
this
.
childrenList
[
0
].
indexChildren
;
let
itemWidth
=
window
.
screen
.
width
/
4
;
let
spanWidth
=
this
.
tabSpan
.
nativeElement
.
offsetWidth
;
//文字宽度
this
.
tips
.
nativeElement
.
style
.
width
=
this
.
tabSpan
.
nativeElement
.
offsetWidth
+
'px'
;
// 自身div的一半 - 滑块的一半
this
.
tips
.
nativeElement
.
style
.
left
=
itemWidth
*
(
index
)
+
(
itemWidth
-
spanWidth
)
/
2
+
'px'
;
this
.
index
=
index
;
const
data
=
{
pageSize
:
1
,
pageCount
:
100
,
obj
:
{
'plateType'
:
item
.
type
,
resourceType
:
1
'resourceType'
:
1
}
};
this
.
tabsSer
.
stuffPage
(
data
).
subscribe
(
(
res
)
=>
{
this
.
newList
=
res
.
data
;
this
.
newList
.
forEach
(
e
=>
{
if
(
e
.
attachments
.
length
>
0
)
{
e
.
imgUrl
=
e
.
attachments
[
0
].
path
;
}
})
}
)
}
//子级选择
changeChildren
(
item
)
{
this
.
indexChildren
=
item
.
indexChildren
;
const
data
=
{
pageSize
:
1
,
pageCount
:
100
,
obj
:
{
'plateType'
:
item
.
type
,
'resourceType'
:
1
}
};
this
.
tabsSer
.
stuffPage
(
data
).
subscribe
(
(
res
)
=>
{
this
.
newList
=
res
.
data
;
...
...
src/pages/tabs/home/home.html
View file @
5c38ee91
...
...
@@ -10,12 +10,9 @@
<ion-icon
class=
"search-icon"
name=
"search"
></ion-icon>
</ion-buttons>
<ion-buttons
end
>
<button
ion-button
icon-only
*
ngIf=
"signObj.isSign == 'no'"
(
click
)="
signNow
()"
class=
"toolbar-signUp"
>
<button
ion-button
icon-only
(
click
)="
signNow
()"
class=
"toolbar-signUp"
>
<span
class=
"signUp-span"
>
签到
</span>
</button>
<button
ion-button
icon-only
*
ngIf=
"signObj.isSign == 'yes'"
class=
"toolbar-signUp"
>
<span
class=
"signUp-span"
>
已签到
</span>
</button>
</ion-buttons>
<ion-buttons
end
>
<button
ion-button
icon-only
(
click
)="
goToNotice
()"
class=
"toolbar-icon"
>
...
...
@@ -95,8 +92,8 @@
{{signObj.text}}
</div>
<div
class=
"mask-button"
>
<button
*
ngIf=
"signObj.isSign == 'no'"
[
disabled
]="
disabledClick
"
class=
"submit-btn submit"
(
click
)="
signUp
()"
>
签到{{signText}}
</button>
<button
*
ngIf=
"signObj.isSign == 'no'"
[
disabled
]="
disabledClick
"
class=
"submit-btn submit"
(
click
)="
signUp
()"
>
签到{{signText}}
</button>
<button
*
ngIf=
"signObj.isSign == 'yes'"
[
disabled
]="
true
"
class=
"submit-btn submit"
>
已签到
</button>
</div>
</div>
</div>
src/pages/tabs/home/home.scss
View file @
5c38ee91
...
...
@@ -146,6 +146,7 @@ page-home {
}
.news-right
{
text-align
:
center
;
img
{
border-radius
:
.5rem
;
height
:
60px
;
...
...
src/pages/tabs/home/home.ts
View file @
5c38ee91
...
...
@@ -82,6 +82,7 @@ export class HomePage {
}
//跑马灯
lineChange
()
{
let
child_div
=
this
.
lineChangeEle
.
nativeElement
.
children
;
setTimeout
(()
=>
{
...
...
@@ -197,9 +198,8 @@ export class HomePage {
)
}
//签到
//签到
接口
signUp
()
{
this
.
signObj
.
isSign
=
'yes'
;
this
.
tabsSer
.
sign
().
subscribe
(
(
res
)
=>
{
this
.
isSign
=
false
;
...
...
@@ -212,7 +212,7 @@ export class HomePage {
)
}
//签到
//签到
倒计时
signNow
()
{
this
.
isSign
=
true
;
let
totalTime
=
5
;
...
...
@@ -240,7 +240,6 @@ export class HomePage {
this
.
navCtrl
.
push
(
SearchNewPage
);
}
//消息提醒页面
goToNotice
()
{
this
.
navCtrl
.
push
(
NoticePage
);
...
...
src/pages/tabs/tabs.service.ts
View file @
5c38ee91
...
...
@@ -139,5 +139,10 @@ export class TabsService {
return
this
.
http
.
get
(
AppGlobal
.
domain
+
'/wisdomgroup/sysmanagement/usergroup/search.ajax'
);
}
//获取文章分类
getType
():
Observable
<
any
>
{
return
this
.
http
.
get
(
'./assets/json/party.json'
);
}
}
\ No newline at end of file
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