Commit 06aa8d0a authored by wangqinghua's avatar wangqinghua

图片

parent 2998a412
// http://ionicframework.com/docs/theming/
// App Global Sass
// --------------------------------------------------
// Put style rules here that you want to apply globally. These
// styles are for the entire app and not just one component.
// Additionally, this file can be also used as an entry point
// to import other Sass files to be included in the output CSS.
//
// Shared Sass variables, which can be used to adjust Ionic's
// default Sass variables, belong in "theme/variables.scss".
//
// To declare rules for a specific mode, create a child rule
// for the .md, .ios, or .wp mode classes. The mode class is
// automatically applied to the <body> element in the app.
@import "../theme/icon.scss";
.back-button-icon-ios{
......@@ -42,3 +27,49 @@
border-radius: 4px;
height: 35px;
}
//tabs-icon
ion-icon {
&[class*="custom-"] {
margin: 0 5px 0 0;
vertical-align: middle;
$sz: 20px;
width: $sz;
height: $sz;
}
// custom icons
&[class*="home-on"] {
background: url(../assets/imgs/tabs/icon-home-on.png) no-repeat 50% 50%;
background-size: contain;
}
&[class*="home-off"] {
background: url(../assets/imgs/tabs/icon-home-off.png) no-repeat 50% 50%;
background-size: contain;
}
&[class*="contact-on"] {
background: url(../assets/imgs/tabs/icon-contact-on.png) no-repeat 50% 50%;
background-size: contain;
}
&[class*="contact-off"] {
background: url(../assets/imgs/tabs/icon-contact-off.png) no-repeat 50% 50%;
background-size: contain;
}
&[class*="notice-on"] {
background: url(../assets/imgs/tabs/icon-notice-on.png) no-repeat 50% 50%;
background-size: contain;
}
&[class*="notice-off"] {
background: url(../assets/imgs/tabs/icon-notice-off.png) no-repeat 50% 50%;
background-size: contain;
}
&[class*="owner-on"] {
background: url(../assets/imgs/tabs/icon-onwer-on.png) no-repeat 50% 50%;
background-size: contain;
}
&[class*="owner-off"] {
background: url(../assets/imgs/tabs/icon-owner-off.png) no-repeat 50% 50%;
background-size: contain;
}
}
\ No newline at end of file
......@@ -4,6 +4,8 @@ page-duty {
flex-direction: row;
align-items: center;
justify-content: center;
height: 3rem;
background-color: #fff;
}
.duty div{
width: 50%;
......@@ -20,7 +22,7 @@ page-duty {
width: 100%;
height: 2px;
background-color: #24bafc;
bottom: -8px;
bottom: -10px;
left: 0px;
}
}
......@@ -19,20 +19,19 @@ export class DutyPage {
menuList = [
{name:'值班安排'},
{name:'我的值班'},
]
];
swiperIndex;
changeType = 1;
dayObj;
nightObj;
nowDuty;
historyDuty;
date: string[] = ['2018-01-01', '2018-01-02', '2018-01-05'];
options: CalendarComponentOptions = {
from: new Date(2000, 0, 1),
monthFormat: 'YYYY 年 MM 月 ',
weekdays: weekDay,
monthPickerFormat:monthCh,
pickMode: 'multi',
pickMode: 'single',
color:'danger'
};
constructor(public navCtrl: NavController, public navParams: NavParams,
......@@ -65,9 +64,9 @@ export class DutyPage {
}
onChange(e){
const date = new Date(e.time).toLocaleDateString();
console.log(e);
const date = new Date(e).toLocaleDateString();
this.getDuty(date);
console.log(date);
}
getDuty(date){
......
......@@ -37,8 +37,6 @@ export class LoginPage {
}
ionViewDidLoad(){
alert("123");
this.storage.get("userLoginInfo").then((value)=>{
if(value!=null && value != ''){
this.user = value;
......
......@@ -14,9 +14,9 @@
<ion-label class="padding-left-16">{{temp.title}}</ion-label>
</ion-item>
<div class="question-list">
<ion-item *ngFor="let item of qList;let i = index" (click)="itemEdit(i)">
<ion-item *ngFor="let item of contentList;let i = index" (click)="itemEdit(i)">
<div class="item-content">
<p>1.【判断】是否愿意修养</p>
<p>{{i +1}}.{{item.title}}</p>
<p><input type="radio"></p>
<p><input type="radio"></p>
</div>
......
......@@ -8,21 +8,23 @@
<div class="swiper-container">
<div class="swiper-wrapper">
<!-- {{i==0?'bottomLine':''}}是初始化的时候默认选择第一个菜单 -->
<!--<div class="swiper-slide" *ngFor="let item of menuList;let i=index;" tappable (click)="selectPageMenu(i)">-->
<!--<span class=" {{swiperIndex == i? 'swiper-title':''}} ">-->
<!--{{item.name}}-->
<!--</span>-->
<!--<span></span>-->
<!--</div>-->
<div class="swiper-slide" *ngFor="let item of menuList;let i=index;" tappable (click)="selectPageMenu(i)">
<span class=" {{swiperIndex == i? 'swiper-title':''}} ">
{{item.name}}
</span>
<span></span>
</div>
</div>
</div>
</div>
</ion-header>
<ion-content>
<!--<ion-content style="{{showOp == true ? 'height: calc(100vh - 11rem);':''}}">-->
<ion-content [ngStyle]="{ 'height':showOp == true? 'calc(100vh - 11rem)':'' }">
<ion-content direction="y" scrollbar-y="true" class="bgc-e7e8ed">
<ion-list>
<!--<ng-container *ngIf="contentList.datalist.length > 0">-->
<ion-item class="item-list" *ngFor="let item of contentList.datalist">
<div class="item" (click)="showOpra(item)">
<div class="item-header">
......@@ -39,6 +41,10 @@
</div>
</div>
</ion-item>
<!--</ng-container>-->
<!--<ng-container *ngIf="contentList.datalist.length == 0">-->
<!--暂无数据-->
<!--</ng-container>-->
</ion-list>
</ion-content>
</ion-content>
......
......@@ -5,7 +5,6 @@ page-list {
.swiper-container{
width: 100%;
height: 40px;
border-bottom: 1px solid #dddddd;
}
.swiper-slide{
//设置菜单栏的颜色
......@@ -29,7 +28,7 @@ page-list {
width: 100%;
height: 2px;
background-color: #24bafc;
bottom: -8px;
bottom: -9px;
left: 0px;
}
}
......@@ -62,13 +61,18 @@ page-list {
display: flex;
flex-direction: row;
flex-wrap: wrap;
height: 100px;
height: 11rem;
background-color: #f8f8f8;
border-bottom: 1px solid #bbbbbb;
}
.footter-opr div{
width: 33%;
text-align: center;
display: flex;
justify-content: center;
align-items: center;
}
.footter-opr div span{
display: inline-block;
border-radius: 5px;
border: 1px solid #aaa;
padding: 10px 25px;
......
......@@ -81,6 +81,7 @@ export class ListPage {
}
)
this.swiperIndex = index;
this.showOp = false;
//切换页面
// this.contentSlides.slideTo(index);
}
......
......@@ -152,12 +152,12 @@ export class HomePage {
ionViewDidEnter() {
setTimeout(() => {
if (this.slidersItems.length > 0) {
this.slides.freeMode = true;
this.slides.autoplay = 2000;
this.slides.speed = 500;
this.slides.loop = true;
this.slides.autoplayDisableOnInteraction=false;
this.slides.startAutoplay();
// this.slides.freeMode = true;
// this.slides.autoplay = 2000;
// this.slides.speed = 500;
// this.slides.loop = true;
// this.slides.autoplayDisableOnInteraction=false;
// this.slides.startAutoplay();
}
}, 1000)
}
......
<ion-tabs>
<ion-tab *ngFor = "let tabRoot of tabRoots" [root] = "tabRoot.root" tabTitle="{{tabRoot.tabTitle}}" tabIcon="{{tabRoot.tabIcon}}"></ion-tab>
<ng-container *ngFor = "let tabRoot of tabRoots;let i = index;">
<ion-tab (ionSelect)="onChange(i)" [root] = "tabRoot.root" tabTitle="{{tabRoot.tabTitle}}" tabIcon="{{ tabsIndex == i ? tabRoot.tabIconOn:tabRoot.tabIconOff }}"></ion-tab>
</ng-container>
</ion-tabs>
<!-- <ion-tabs>
<ion-tab [root] = "tab1Root" tabTitle="首页" tabIcon="myhome"></ion-tab>
<ion-tab [root] = "tab2Root" tabTitle="通讯录" tabIcon="mycontact"></ion-tab>
<ion-tab *ngIf="role==1" [root] = "tab3Root" tabTitle="工作台" tabIcon="myworkbench"></ion-tab>
<ion-tab *ngIf="role==1" [root] = "tab4Root" tabTitle="我的" tabIcon="mymine"></ion-tab>
<ion-tab *ngIf="role==0" [root] = "tab4Root" tabTitle="我的" tabIcon="mymine"></ion-tab>
</ion-tabs> -->
<!-- 为什么这么写,为了顺序 -->
......@@ -29,7 +29,7 @@ export class TabsPage {
userid: string;
roleflag: any;
tabsIndex;
role: any;
constructor(
public navCtrl: NavController,
......@@ -44,19 +44,27 @@ export class TabsPage {
this.tabRoots = [{
root: HomePage,
tabTitle: '首页',
tabIcon: 'myhome'
tabIconOn: 'custom-home-on',
tabIconOff: 'custom-home-off',
index:0
}, {
root: ContactPage,
tabTitle: '通讯录',
tabIcon: 'mycontact'
tabIconOn: 'custom-contact-on',
tabIconOff: 'custom-contact-off',
index:1
}, {
root: NoticePage,
tabTitle: '消息',
tabIcon: 'myworkbench'
tabIconOn: 'custom-notice-on',
tabIconOff: 'custom-notice-off',
index:2
}, {
root: MinePage,
tabTitle: '我的',
tabIcon: 'mymine'
tabIconOn: 'custom-owner-on',
tabIconOff: 'custom-owner-off',
index:3
}];
//判断是否密码为初始六个0
......@@ -70,6 +78,11 @@ export class TabsPage {
}
onChange(e){
this.tabsIndex =e;
}
// ionViewDidEnter() {
// this.queryUserRole();
// }
......
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