Commit dee26855 authored by wangqinghua's avatar wangqinghua

上拉加载页面详情

parent aff0710f
......@@ -19,6 +19,7 @@
<preference name="SplashShowOnlyFirstTime" value="false" />
<preference name="SplashScreen" value="screen" />
<preference name="SplashScreenDelay" value="20000" />
<preference name="ShowSplashScreenSpinner" value="false"/>
<platform name="android">
<allow-intent href="market:*" />
<icon density="ldpi" src="resources/android/icon/drawable-ldpi-icon.png" />
......
......@@ -133,11 +133,11 @@ p {
font-weight: 400;
}
.toolbar-background-ios {
ion-navbar .toolbar-background-ios {
background-color: #e12724;
}
.header-ios .toolbar-ios:last-child .toolbar-background-ios {
ion-navbar .header-ios .toolbar-ios:last-child .toolbar-background-ios {
border-bottom: 1px solid #e12724;
}
......
......@@ -34,7 +34,7 @@ slide {
height: 2rem;
line-height: 2rem;
padding: 0 1rem;
font-size: 1.6rem;
font-size: 1.4rem;
font-weight: 500;
font-family: 'SourceHanSans-Bold';
.slide-index{
......
......@@ -19,7 +19,8 @@
</button>
</ion-buttons>
</ion-navbar>
<div class="tabs-fixed">
<ion-toolbar class="fixed-toolbar">
<div ion-fixed class="tabs-fixed">
<div class="scroll-tab">
<div class="news-content">
<div #tabsParent class="tabs-parent">
......@@ -30,6 +31,10 @@
</div>
</div>
</div>
</div>
</ion-toolbar>
<ion-toolbar class="fixed-toolbar">
<div class="tabs-fixed">
<div class="scroll-tab">
<div class="news-content" #newsContent>
<div class="tabs-parent">
......@@ -40,6 +45,7 @@
</div>
</div>
</div>
</ion-toolbar>
</ion-header>
<ion-content>
......@@ -101,7 +107,7 @@
</ion-slide>
</ion-slides>
<ion-infinite-scroll (ionInfinite)="doInfinite($event)">
<ion-infinite-scroll #infiniteScrollContent (ionInfinite)="doInfinite($event)">
<ion-infinite-scroll-content
loadingSpinner="bubbles" threshold="10%"
loadingText="加载更多..."></ion-infinite-scroll-content>
......
page-discover {
background-color: #fff;
ion-content{
top: 100px;
}
ion-toolbar .toolbar-background-ios{
background-color: #fff;
}
.header-ios .toolbar-ios:last-child .toolbar-background-ios{
border-width: 0px;
}
.toolbar .searchbar-ios .searchbar-input {
background-color: #e12724;
......@@ -58,7 +62,6 @@ page-discover {
margin-right: -.3rem;
}
}
//新闻区
.search-content{
padding: 0 1rem;
......@@ -131,7 +134,7 @@ page-discover {
.tabs-fixed{
position: fixed;
top: 44px;
top: 0px;
left: 0px;
width: 100%;
z-index: 99999;
......@@ -142,6 +145,9 @@ page-discover {
}
}
.fixed-toolbar{
background-color: #fff;
}
.swiper-slide{
align-items: baseline;
......
import {Component, ElementRef, ViewChild} from '@angular/core';
import {Component, ElementRef, Renderer2, ViewChild} from '@angular/core';
import {IonicPage, NavController, NavParams, Slide, Slides} from 'ionic-angular';
import {SearchNewPage} from "../../home-pages/search-new/search-new";
import {TabsService} from "../tabs.service";
......@@ -22,6 +22,7 @@ export class DiscoverPage {
@ViewChild('tabsChildren') tabsChildren: ElementRef;
@ViewChild('tabSpan') tabSpan: ElementRef;
@ViewChild('newsContent') newsContent: ElementRef;
@ViewChild('infiniteScrollContent') infiniteScrollContent: ElementRef;
//所属板块类型:
//1党章党规,2系列讲话,3中央精神,4本市部署,5通知公告,6党建动态,7工作提示,8党务参考
......@@ -148,7 +149,7 @@ export class DiscoverPage {
toIndex;
constructor(public navCtrl: NavController, public navParams: NavParams,
public commonSer: CommonService,
public commonSer: CommonService,public renderer:Renderer2,
public tabsSer: TabsService, public emitSer: EmitService) {
// 接收发射过来的数据
this.emitSer.eventEmit.subscribe((value: any) => {
......@@ -274,9 +275,10 @@ export class DiscoverPage {
}
doInfinite(e) {
console.log('infinite')
this.renderer.setStyle(this.infiniteScrollContent.nativeElement,'height','84px');
setTimeout(()=>{
e.complete();
this.renderer.setStyle(this.infiniteScrollContent.nativeElement,'height','0px');
},1000)
}
......
......@@ -262,7 +262,7 @@ export class HomePage {
setTimeout(()=>{
e.complete();
this.renderer.setStyle(this.infiniteScrollContent.nativeElement,'height','0px');
},2000)
},1000)
}
//下拉刷新
......
......@@ -15,8 +15,8 @@ export class AppGlobal {
//接口基地址
// static domain = "http://101.89.112.92:80"; //正式环境
// static domain = "http://180.168.156.212:2931"; //测试环境
// static domain = "http://47.103.35.216:8080"; //阿里云地址
static domain = ""; //本地环境
static domain = "http://47.103.35.216:8080"; //阿里云地址
// static domain = ""; //本地环境
//图片地址
// static picture = AppGlobal.domain + "/wisdomgroup/manager/getIcon/"; //正式地址
......
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