Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
M
muChangApp
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
WitCloud
muChangApp
Commits
1e2662a0
Commit
1e2662a0
authored
Aug 07, 2019
by
frank
🏀
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
做了风机,喷淋,照明完成中
parent
dda81506
Hide whitespace changes
Inline
Side-by-side
Showing
17 changed files
with
288 additions
and
142 deletions
+288
-142
app-routing.module.ts
src/app/app-routing.module.ts
+18
-9
app.module.ts
src/app/app.module.ts
+16
-2
kanban.component.scss
src/app/components/kanban/kanban.component.scss
+2
-2
wt.module.ts
src/app/components/wt/wt.module.ts
+4
-1
east.page.html
src/app/east/east.page.html
+77
-76
east.page.scss
src/app/east/east.page.scss
+9
-2
env-detail.module.ts
src/app/envCtrl/env-detail/env-detail.module.ts
+28
-8
env-detail.page.html
src/app/envCtrl/env-detail/env-detail.page.html
+21
-17
env-detail.page.scss
src/app/envCtrl/env-detail/env-detail.page.scss
+1
-1
env-detail.page.ts
src/app/envCtrl/env-detail/env-detail.page.ts
+3
-1
env-home.page.html
src/app/envCtrl/env-home/env-home.page.html
+0
-3
env-home.page.ts
src/app/envCtrl/env-home/env-home.page.ts
+21
-3
tabs.module.ts
src/app/envCtrl/tabs/tabs.module.ts
+62
-10
tabs.page.html
src/app/envCtrl/tabs/tabs.page.html
+4
-4
home.page.ts
src/app/home/home.page.ts
+3
-1
index.page.html
src/app/index/index.page.html
+2
-2
variables.scss
src/theme/variables.scss
+17
-0
No files found.
src/app/app-routing.module.ts
View file @
1e2662a0
...
...
@@ -9,6 +9,12 @@ import {RowPage} from './row/row.page';
import
{
IndexPage
}
from
'./index/index.page'
;
import
{
OtherPage
}
from
'./other/other.page'
;
import
{
MinePage
}
from
'./mine/mine.page'
;
import
{
EnvFanPage
}
from
'./envCtrl/env-fan/env-fan.page'
;
import
{
EnvDetailPage
}
from
'./envCtrl/env-detail/env-detail.page'
;
import
{
EnvShowerPage
}
from
'./envCtrl/env-shower/env-shower.page'
;
import
{
EnvLightPageModule
}
from
'./envCtrl/env-light/env-light.module'
;
import
{
EnvLightPage
}
from
'./envCtrl/env-light/env-light.page'
;
import
{
EnvWaterchannelPage
}
from
'./envCtrl/env-waterchannel/env-waterchannel.page'
;
const
routes
:
Routes
=
[
{
...
...
@@ -26,15 +32,18 @@ const routes: Routes = [
]
},
{
path
:
'login'
,
component
:
LoginPage
},
// {path: 'tabs', loadChildren: './envCtrl/tabs/tabs.module#TabsPageModule'},
// { path: 'env-detail', loadChildren: './envCtrl/env-detail/env-detail.module#EnvDetailPageModule' },
// { path: 'env-cfg', loadChildren: './envCtrl/env-cfg/env-cfg.module#EnvCfgPageModule' },
// { path: 'env-alarm', loadChildren: './envCtrl/env-alarm/env-alarm.module#EnvAlarmPageModule' },
// { path: 'env-home', loadChildren: './envCtrl/env-home/env-home.module#EnvHomePageModule' },
// { path: 'env-detail', loadChildren: './envCtrl/env-detail/env-detail.module#EnvDetailPageModule' },
// { path: 'env-cfg', loadChildren: './envCtrl/env-cfg/env-cfg.module#EnvCfgPageModule' },
// { path: 'env-alarm', loadChildren: './envCtrl/env-alarm/env-alarm.module#EnvAlarmPageModule' },
{
path
:
'env-home'
,
loadChildren
:
'./envCtrl/env-home/env-home.module#EnvHomePageModule'
},
{
path
:
'env-detail'
,
component
:
EnvDetailPage
,
children
:
[
{
path
:
'fan'
,
component
:
EnvFanPage
},
{
path
:
'shower'
,
component
:
EnvShowerPage
},
{
path
:
'light'
,
component
:
EnvLightPage
},
{
path
:
'waterchannel'
,
component
:
EnvWaterchannelPage
},
{
path
:
''
,
redirectTo
:
'fan'
,
pathMatch
:
'prefix'
},
]
},
{
path
:
'tabs'
,
loadChildren
:
'./envCtrl/tabs/tabs.module#TabsPageModule'
},
// {path: 'd', component: EnvFanPage},
];
@
NgModule
({
...
...
src/app/app.module.ts
View file @
1e2662a0
...
...
@@ -42,12 +42,21 @@ import {Load} from './service/load';
import
{
LoadingBumpComponent
}
from
'./components/loading-bump/loading-bump.component'
;
import
{
KanbanComponent
}
from
'./components/kanban/kanban.component'
;
import
{
WtModule
}
from
'./components/wt/wt.module'
;
import
{
EnvHomePage
}
from
'./envCtrl/env-home/env-home.page'
;
import
{
EnvAnalPage
}
from
'./envCtrl/env-anal/env-anal.page'
;
import
{
EnvDetailPage
}
from
'./envCtrl/env-detail/env-detail.page'
;
import
{
EnvCfgPage
}
from
'./envCtrl/env-cfg/env-cfg.page'
;
import
{
EnvShowerPage
}
from
'./envCtrl/env-shower/env-shower.page'
;
import
{
EnvWaterchannelPage
}
from
'./envCtrl/env-waterchannel/env-waterchannel.page'
;
import
{
EnvAlarmPage
}
from
'./envCtrl/env-alarm/env-alarm.page'
;
import
{
EnvFanPage
}
from
'./envCtrl/env-fan/env-fan.page'
;
import
{
TabsPage
}
from
'./envCtrl/tabs/tabs.page'
;
import
{
EnvLightPage
}
from
'./envCtrl/env-light/env-light.page'
;
@
NgModule
({
declarations
:
[
AppComponent
,
SubTitleComponent
,
SwitchComponent
,
AlarmBarComponent
,
SearchHistoryComponent
,
RefreshComponent
,
...
...
@@ -60,7 +69,12 @@ import {WtModule} from './components/wt/wt.module';
IndexPage
,
OtherPage
,
SearchPage
,
MinePage
MinePage
,
EnvDetailPage
,
EnvFanPage
,
EnvShowerPage
,
EnvLightPage
,
EnvWaterchannelPage
,
],
entryComponents
:
[],
imports
:
[
...
...
src/app/components/kanban/kanban.component.scss
View file @
1e2662a0
...
...
@@ -25,7 +25,7 @@
}
.sub-left
{
font-size
:
30px
;
font-size
:
20px
;
//30
position
:relative
;
// border-right: #cccccc 1px solid;
display
:
inline
;
...
...
@@ -33,7 +33,7 @@
}
.sub-right
{
font-size
:
30px
;
font-size
:
20px
;
//30
position
:relative
;
display
:
inline
;
width
:
50%
;
...
...
src/app/components/wt/wt.module.ts
View file @
1e2662a0
...
...
@@ -2,15 +2,18 @@ import { NgModule } from '@angular/core';
import
{
CommonModule
}
from
'@angular/common'
;
import
{
KanbanComponent
}
from
'../kanban/kanban.component'
;
import
{
IonicModule
}
from
'@ionic/angular'
;
import
{
SwitchComponent
}
from
'../switch/switch.component'
;
@
NgModule
({
declarations
:
[
KanbanComponent
,
],
declarations
:
[
KanbanComponent
,
SwitchComponent
],
imports
:
[
CommonModule
,
IonicModule
,
],
exports
:
[
KanbanComponent
,
SwitchComponent
,
]
})
export
class
WtModule
{
}
src/app/east/east.page.html
View file @
1e2662a0
<div
class=
"mainCon"
style=
"padding-top: 45px;"
[@
EnterLeave
]
>
<Navbar
[
leftContent
]="
icon
"
(
onLeftClick
)="
onLeftClick
()"
[
rightContent
]="
r
"
style=
"background-color: #28c9bd;position: fixed;top: 0;width: 100%;z-index: 2;"
>
{{fieldRegionName}}控制
</Navbar>
<ng-template
#
r
>
<span
(
click
)="
pullToRefresh
()"
>
刷新
</span>
</ng-template>
<div
class=
"topPart"
>
<ListItem
multipleLine
*
ngIf=
"yewei || yewei === 0"
>
当前液位:
<div
class=
"process"
>
<div
[
class
]="'
inlineProcess
'
+
color
"
[
ngStyle
]="{
width:
proc
+
'%'}"
>
<div
class=
"mainCon"
style=
""
[@
EnterLeave
]
>
<Navbar
[
leftContent
]="
icon
"
(
onLeftClick
)="
onLeftClick
()"
[
rightContent
]="
r
"
style=
"background-color: #28c9bd;position: fixed;top: 0;width: 100%;z-index: 2;"
>
{{fieldRegionName}}控制
</Navbar>
<ng-template
#
r
>
<span
(
click
)="
pullToRefresh
()"
>
刷新
</span>
</ng-template>
<ion-content
style=
"padding-top: 45px ;margin-bottom:45px ;position:relative;overflow-y:auto;"
>
<div
class=
"topPart"
>
<ListItem
multipleLine
*
ngIf=
"yewei || yewei === 0"
>
当前液位:
<div
class=
"process"
>
<div
[
class
]="'
inlineProcess
'
+
color
"
[
ngStyle
]="{
width:
proc
+
'%'}"
>
</div>
</div>
</div>
{{yewei.toFixed(2)}}m
</ListItem>
<ListItem
multipleLine
*
ngIf=
"temp || temp === 0"
>
当前温度:
<div
style=
"display: inline-block;margin-left: calc(100% - 145px);vertical-align: middle"
>
{{temp.toFixed(2)}}℃
</div>
</ListItem>
<div
*
ngFor=
"let a of nb;let i = index"
>
<ListItem
multipleLine
[
extra
]="
a
.
fieldDeviceName =
==
'南水'
?
s1
:
s2
"
>
{{a.fieldDeviceName}}
{{yewei.toFixed(2)}}m
</ListItem>
<ListItem
multipleLine
*
ngIf=
"a.fieldDeviceName === '南水' ? nanClicked : beiClicked"
>
选择开启时间
<Stepper
class=
"stepClass"
[(
ngModel
)]="
duration
"
[
min
]="
1
"
[
showNumber
]="
true
"
></Stepper>
分钟
<div
style=
"text-align: right;padding-top: 10px"
>
<div
Button
style=
"margin-right: 10px"
class=
"btn"
(
click
)="
cancel
()"
[
inline
]="
true
"
[
size
]="'
small
'"
[
type
]="'
default
'"
>
取消
</div>
<div
Button
(
click
)="
confirm
(
a
)"
class=
"btn"
[
inline
]="
true
"
[
size
]="'
small
'"
[
type
]="'
primary
'"
>
确认
</div>
<ListItem
multipleLine
*
ngIf=
"temp || temp === 0"
>
当前温度:
<div
style=
"display: inline-block;margin-left: calc(100% - 145px);vertical-align: middle"
>
{{temp.toFixed(2)}}℃
</div>
</ListItem>
<div
*
ngFor=
"let a of nb;let i = index"
>
<ListItem
multipleLine
[
extra
]="
a
.
fieldDeviceName =
==
'南水'
?
s1
:
s2
"
>
{{a.fieldDeviceName}}
</ListItem>
<ListItem
multipleLine
*
ngIf=
"a.fieldDeviceName === '南水' ? nanClicked : beiClicked"
>
选择开启时间
<Stepper
class=
"stepClass"
[(
ngModel
)]="
duration
"
[
min
]="
1
"
[
showNumber
]="
true
"
></Stepper>
分钟
<div
style=
"text-align: right;padding-top: 10px"
>
<div
Button
style=
"margin-right: 10px"
class=
"btn"
(
click
)="
cancel
()"
[
inline
]="
true
"
[
size
]="'
small
'"
[
type
]="'
default
'"
>
取消
</div>
<div
Button
(
click
)="
confirm
(
a
)"
class=
"btn"
[
inline
]="
true
"
[
size
]="'
small
'"
[
type
]="'
primary
'"
>
确认
</div>
</div>
</ListItem>
</div>
</div>
</div>
<div
class=
"middlePart"
>
<ion-item
lines=
"full"
>
<ion-label>
运行模式
</ion-label>
<ion-select
multiple=
"false"
cancelText=
"取消"
okText=
"确认"
[(
ngModel
)]="
workModeSetting
.
workMode
"
[(
value
)]="
workModeSetting
.
workMode
"
(
ionChange
)="
workModeEvent
()"
>
<ion-select-option
value=
"0"
>
现场控制
</ion-select-option>
<ion-select-option
value=
"1"
>
远程手控
</ion-select-option>
<ion-select-option
value=
"2"
>
全自动
</ion-select-option>
</ion-select>
</ion-item>
<div
class=
"middlePart"
>
<ion-item
lines=
"full"
>
<ion-label>
运行模式
</ion-label>
<ion-select
multiple=
"false"
cancelText=
"取消"
okText=
"确认"
[(
ngModel
)]="
workModeSetting
.
workMode
"
[(
value
)]="
workModeSetting
.
workMode
"
(
ionChange
)="
workModeEvent
()"
>
<ion-select-option
value=
"0"
>
现场控制
</ion-select-option>
<ion-select-option
value=
"1"
>
远程手控
</ion-select-option>
<ion-select-option
value=
"2"
>
全自动
</ion-select-option>
</ion-select>
</ion-item>
<!--<ion-label>发现设备运行时间过长</ion-label>-->
<!--<ion-label>发现设备运行时间过长</ion-label>-->
</div>
<div
class=
"bottomPart"
>
<ion-list>
<ion-item
*
ngFor=
"let a of devices;let i = index"
lines =
"full"
>
<ion-label>
{{a.fieldDeviceName}}
</ion-label>
<v-switch
(
click
)="
toggle
(
a
)"
[
value
]="
a
.
value
"
[
disabled
]="
opDisable
"
[
loading
]="
a
.
loading
"
></v-switch>
</ion-item>
</ion-list>
<!--<ListItem multipleLine *ngFor="let a of devices;let i = index">-->
<!---->
<!---->
<!--</ListItem>-->
</div>
<ion-button
color=
"danger"
expand=
"full"
(
click
)="
unlock
()"
*
ngIf=
"alarmMsg.locked"
>
现设备运行时间过长点击解锁
</ion-button>
</div>
<div
class=
"bottomPart"
>
<ion-list>
<ion-item
*
ngFor=
"let a of devices;let i = index"
lines =
"full"
>
<ion-label>
{{a.fieldDeviceName}}
</ion-label>
<v-switch
(
click
)="
toggle
(
a
)"
[
value
]="
a
.
value
"
[
disabled
]="
opDisable
"
[
loading
]="
a
.
loading
"
></v-switch>
</ion-item>
</ion-list>
<!--<ListItem multipleLine *ngFor="let a of devices;let i = index">-->
<!---->
<!---->
<!--</ListItem>-->
</div>
<ion-button
color=
"danger"
expand=
"full"
(
click
)="
unlock
()"
*
ngIf=
"alarmMsg.locked"
>
现设备运行时间过长点击解锁
</ion-button>
</ion-content>
</div>
<ng-template
#
icon
>
<span
class=
"vo v-back"
></span>
</ng-template>
<ng-template
#
s1
>
<v-switch
[
value
]="
value
[
0
]"
[
disabled
]="
beiLoading
||
value
[
1
]"
(
click
)="
toggleNb
(
0
)"
[
loading
]="
nanLoading
"
></v-switch>
</ng-template>
<ng-template
#
s2
>
<v-switch
[
value
]="
value
[
1
]"
[
disabled
]="
nanLoading
||
value
[
0
]"
(
click
)="
toggleNb
(
1
)"
[
loading
]="
beiLoading
"
></v-switch>
</ng-template>
<ng-template
#
icon
>
<span
class=
"vo v-back"
></span>
</ng-template>
<ng-template
#
s1
>
<v-switch
[
value
]="
value
[
0
]"
[
disabled
]="
beiLoading
||
value
[
1
]"
(
click
)="
toggleNb
(
0
)"
[
loading
]="
nanLoading
"
></v-switch>
</ng-template>
<ng-template
#
s2
>
<v-switch
[
value
]="
value
[
1
]"
[
disabled
]="
nanLoading
||
value
[
0
]"
(
click
)="
toggleNb
(
1
)"
[
loading
]="
beiLoading
"
></v-switch>
</ng-template>
<v-loading-bump
style=
"z-index: 9999; color: red"
[
remain
]="
comm
.
remain
"
*
ngIf=
"comm.isLoading"
></v-loading-bump>
src/app/east/east.page.scss
View file @
1e2662a0
...
...
@@ -34,6 +34,13 @@
}
.mainCon
{
height
:
100%
;
background-color
:
white
;
//height: 100%;
//background-color: white;
//overflow-x: hidden;-webkit-overflow-scrolling: touch;
//padding-top: 45px;
//margin-bottom: 90px;
}
.topPart
{
padding-top
:
45px
;
}
\ No newline at end of file
src/app/envCtrl/env-detail/env-detail.module.ts
View file @
1e2662a0
...
...
@@ -8,17 +8,31 @@ import { IonicModule } from '@ionic/angular';
import
{
EnvDetailPage
}
from
'./env-detail.page'
;
import
{
WtModule
}
from
'../../components/wt/wt.module'
;
import
{
EnvHomePage
}
from
'../env-home/env-home.page'
;
import
{
EnvShowerPage
}
from
'../env-shower/env-shower.page'
;
import
{
EnvLightPage
}
from
'../env-light/env-light.page'
;
import
{
EnvFanPage
}
from
'../env-fan/env-fan.page'
;
import
{
EnvWaterchannelPage
}
from
'../env-waterchannel/env-waterchannel.page'
;
const
routes
:
Routes
=
[
{
path
:
''
,
component
:
EnvDetailPage
,
children
:
[
{
path
:
'tab-2-fan'
,
component
:
EnvHomePage
},
]
// {
// path: 'tab-2-shower',
// component: EnvShowerPage
// },
// {
// path: 'tab-2-light',
// component: EnvLightPage
// },
// {
// path: 'tab-2-channel',
// component: EnvWaterchannelPage
// },
// {
// path:'',
// component: EnvFanPage
// }
}
];
...
...
@@ -30,7 +44,13 @@ const routes: Routes = [
WtModule
,
// for test
RouterModule
.
forChild
(
routes
)
],
declarations
:
[
EnvDetailPage
,
EnvHomePage
,]
declarations
:
[
EnvDetailPage
,
EnvWaterchannelPage
,
EnvLightPage
,
EnvFanPage
,
EnvShowerPage
,
]
})
export
class
EnvDetailPageModule
{}
src/app/envCtrl/env-detail/env-detail.page.html
View file @
1e2662a0
<ion-header>
<ion-header
style=
"background-color: #F3F4F4;"
>
<ion-toolbar>
<ion-title>
envDetail
</ion-title>
<ion-buttons
slot=
"start"
>
<ion-back-button></ion-back-button>
</ion-buttons>
<ion-title>
1号牛舍设备详情
</ion-title>
</ion-toolbar>
<div>
<div
style=
"margin-top: 10px;margin-bottom: 10px"
>
<span
style=
"font-size: 20px"
>
{{item.online ? '在线' : '离线'}}
</span>
<div
class=
"right"
>
{{item.time | date: 'yyyy-MM-dd HH:mm:ss'}}
</div>
</div>
<v-kanban
class=
"home-bar"
></v-kanban>
<v-kanban
class=
"home-bar"
></v-kanban>
<v-kanban
class=
"home-bar"
></v-kanban>
<v-kanban
class=
"home-bar"
></v-kanban>
<div>
<v-kanban
class=
"home-bar"
></v-kanban>
<v-kanban
class=
"home-bar"
></v-kanban>
<v-kanban
class=
"home-bar"
></v-kanban>
<v-kanban
class=
"home-bar"
></v-kanban>
</div>
</ion-header>
<ion-content>
<ion-content
style=
"background-color: #F3F4F4;"
>
<ion-tabs>
<!-- Tab bar -->
<ion-tab-bar
slot=
"top"
>
<ion-tab-button
tab=
"
tab-2-
fan"
>
<ion-
icon
name=
"person"
></ion-icon
>
<ion-tab-button
tab=
"fan"
>
<ion-
label>
风机
</ion-label
>
</ion-tab-button>
<ion-tab-button
tab=
"
喷淋
"
>
<ion-
icon
name=
"call"
></ion-icon
>
<ion-tab-button
tab=
"
shower
"
>
<ion-
label>
喷淋
</ion-label
>
</ion-tab-button>
<ion-tab-button
tab=
"
照明
"
>
<ion-
icon
name=
"settings"
></ion-icon
>
<ion-tab-button
tab=
"
light
"
>
<ion-
label>
照明
</ion-label
>
</ion-tab-button>
<ion-tab-button
tab=
"
水槽
"
>
<ion-
icon
name=
"settings"
></ion-icon
>
<ion-tab-button
tab=
"
waterchannel
"
>
<ion-
label>
水槽
</ion-label
>
</ion-tab-button>
<!--<ion-tab-button tab="settings">-->
<!--<ion-icon name="settings"></ion-icon>-->
...
...
@@ -36,5 +41,4 @@
<!--</ion-tab-button>-->
</ion-tab-bar>
</ion-tabs>
<ion-router-outlet></ion-router-outlet>
</ion-content>
src/app/envCtrl/env-detail/env-detail.page.scss
View file @
1e2662a0
.right
{
float
:
right
;
color
:
#
ffd31
a
;
color
:
#
aa
a
;
}
.home-bar
{
...
...
src/app/envCtrl/env-detail/env-detail.page.ts
View file @
1e2662a0
import
{
Component
,
OnInit
}
from
'@angular/core'
;
import
{
Api
}
from
'../../service/api'
;
import
{
NavController
}
from
'@ionic/angular'
;
@
Component
({
selector
:
'v-env-detail'
,
...
...
@@ -7,7 +9,7 @@ import { Component, OnInit } from '@angular/core';
})
export
class
EnvDetailPage
implements
OnInit
{
constructor
()
{
}
constructor
(
private
api
:
Api
,
public
nav
:
NavController
,
)
{
}
item
=
{
name
:
'1号牛舍'
,
...
...
src/app/envCtrl/env-home/env-home.page.html
View file @
1e2662a0
...
...
@@ -22,9 +22,6 @@
<v-kanban
class=
"home-bar"
></v-kanban>
<v-kanban
class=
"home-bar"
></v-kanban>
<v-kanban
class=
"home-bar"
></v-kanban>
<v-kanban
class=
"home-bar"
></v-kanban>
<v-kanban
class=
"home-bar"
></v-kanban>
<v-kanban
class=
"home-bar"
></v-kanban>
<h1
style=
"
font-size: 16px;
padding-left: 5px;
...
...
src/app/envCtrl/env-home/env-home.page.ts
View file @
1e2662a0
...
...
@@ -144,9 +144,27 @@ export class EnvHomePage implements OnInit {
this
.
tf
.
transfer
({
url
:
'/index'
});
}
}
toControl
(
p
){
//
// toControl(one){
// const query = '?name=' + one.name + '&no=' + one.no + '&group=' + one.group;
// // this.tf.transfer({
// // url: '/' + one.url,
// // query: query,
// // hash: ''
// // });
// this.nav.navigateForward(one.url + query);
// }
toControl
(
one
)
{
const
query
=
'/env-detail?name='
+
one
.
name
+
'&no='
+
one
.
no
+
'&group='
+
one
.
group
;
// this.tf.transfer({
// url: '/' + one.url,
// query: query,
// hash: ''
// });
console
.
log
(
query
);
this
.
nav
.
navigateForward
(
query
);
//this.nav.navigateRoot(one.url + query);
}
getData
()
...
...
src/app/envCtrl/tabs/tabs.module.ts
View file @
1e2662a0
...
...
@@ -14,6 +14,10 @@ import {EnvCfgPage} from '../env-cfg/env-cfg.page';
import
{
KanbanComponent
}
from
'../../components/kanban/kanban.component'
;
import
{
AppModule
}
from
'../../app.module'
;
import
{
WtModule
}
from
'../../components/wt/wt.module'
;
import
{
EnvFanPage
}
from
'../env-fan/env-fan.page'
;
import
{
EnvShowerPage
}
from
'../env-shower/env-shower.page'
;
import
{
EnvLightPage
}
from
'../env-light/env-light.page'
;
import
{
EnvWaterchannelPage
}
from
'../env-waterchannel/env-waterchannel.page'
;
const
routes
:
Routes
=
[
{
...
...
@@ -24,13 +28,10 @@ const routes: Routes = [
path
:
'tab-home'
,
component
:
EnvHomePage
},
{
path
:
'tab-detail'
,
component
:
EnvDetailPage
,
// loadChildren:[{
// path:'./envCtrl/env-detail/env-detail.module#EnvDetailPageModule',
// }]
},
// {
// path: 'tab-detail',
// component: EnvDetailPage
// },
{
path
:
'tab-anal'
,
component
:
EnvAnalPage
...
...
@@ -47,9 +48,61 @@ const routes: Routes = [
path
:
''
,
redirectTo
:
'/tabs/tab-home'
,
pathMatch
:
'full'
}
},
// {
// path: 'tab-2-fan',
// redirectTo: '/tabs/tab-detail/tab-2-fan',
// pathMatch: 'full'
// },
// {
// path: 'tab-2-fan',
// redirectTo: '/tabs/tab-detail/tab-2-fan',
// pathMatch: 'full'
// },
// {
// path: 'tab-2-shower',
// redirectTo: '/tabs/tab-detail/tab-2-shower',
// pathMatch: 'full'
// },
// {
// path: 'tab-2-light',
// redirectTo: '/tabs/tab-detail/tab-2-light',
// pathMatch: 'full'
// },
// {
// path: 'tab-2-channel',
// redirectTo: '/tabs/tab-detail/tab-2-channel',
// pathMatch: 'full'
// },
]
}
},
// {
// path: 'tab-detail',
// component: EnvDetailPage,
// children:[
// {
// path: 'tab-2-fan',
// component: EnvFanPage
// },
// {
// path: 'tab-2-shower',
// component: EnvShowerPage
// },
// {
// path: 'tab-2-light',
// component: EnvLightPage
// },
// {
// path: 'tab-2-channel',
// component: EnvWaterchannelPage
// },
// {
// path: '',
// redirectTo: 'tab-2-fan',
// },
// ],
//
// }
];
@
NgModule
({
...
...
@@ -63,7 +116,6 @@ const routes: Routes = [
declarations
:
[
TabsPage
,
EnvHomePage
,
EnvAnalPage
,
EnvDetailPage
,
EnvAlarmPage
,
EnvCfgPage
,
]
...
...
src/app/envCtrl/tabs/tabs.page.html
View file @
1e2662a0
...
...
@@ -6,10 +6,10 @@
<ion-icon
name=
"home"
></ion-icon>
</ion-tab-button>
<
ion-tab-button
tab=
"tab-detail"
>
<
ion-label>
详情
</ion-label
>
<
ion-icon
name=
"settings"
></ion-icon
>
<
/ion-tab-button
>
<
!--<ion-tab-button tab="tab-detail">--
>
<
!--<ion-label>详情</ion-label>--
>
<
!--<ion-icon name="settings"></ion-icon>--
>
<
!--</ion-tab-button>--
>
<ion-tab-button
tab=
"tab-anal"
>
<ion-label>
分析
</ion-label>
...
...
src/app/home/home.page.ts
View file @
1e2662a0
...
...
@@ -59,7 +59,8 @@ export class HomePage implements OnInit, OnDestroy {
// ionic的生命周期函数
ionViewWillEnter
()
{
this
.
slideDidChange
();
//this.getData(0);
this
.
getData
(
0
);
console
.
log
(
'-ionViewWillEnter'
);
}
ngOnDestroy
():
void
{
...
...
@@ -111,6 +112,7 @@ export class HomePage implements OnInit, OnDestroy {
// query: query,
// hash: ''
// });
console
.
log
(
one
.
url
+
query
);
this
.
nav
.
navigateForward
(
one
.
url
+
query
);
//this.nav.navigateRoot(one.url + query);
}
...
...
src/app/index/index.page.html
View file @
1e2662a0
...
...
@@ -12,8 +12,8 @@
<div
class=
"mainContent"
>
<div
class=
"contentPart"
>
<div
class=
"leftOnPart"
(
click
)="
goTo
('
home
')"
></div>
<
div
class=
"rightOnPart "
(
click
)="
goTo
('
row
')"
></div
>
<
!--<div class="rightOnPart " (click)="goTo('tabs/tab-home')"></div>--
>
<
!--<div class="rightOnPart " (click)="goTo('row')"></div>--
>
<
div
class=
"rightOnPart "
(
click
)="
goTo
('
tabs
/
tab-home
')"
></div
>
<div
class=
"leftUnderPart"
(
click
)="
goTo
('
alarm
')"
></div>
<div
class=
"rightUnderPart"
(
click
)="
goTo
('
mine
')"
></div>
</div>
...
...
src/theme/variables.scss
View file @
1e2662a0
...
...
@@ -74,4 +74,21 @@
--ion-color-light-contrast-rgb
:
0
,
0
,
0
;
--ion-color-light-shade
:
#d7d8da
;
--ion-color-light-tint
:
#f5f6f9
;
/** white **/
--ion-color-white
:
#FFFFFF
;
--ion-color-white-rgb
:
255
,
255
,
255
;
--ion-color-white-contrast
:
#000000
;
--ion-color-white-contrast-rgb
:
0
,
0
,
0
;
--ion-color-white-shade
:
#e0e0e0
;
--ion-color-white-tint
:
#ffffff
;
}
.ion-color-white
{
--ion-color-base
:
var
(
--
ion-color-white
);
--ion-color-base-rgb
:
var
(
--
ion-color-white-rgb
);
--ion-color-contrast
:
var
(
--
ion-color-white-contrast
);
--ion-color-contrast-rgb
:
var
(
--
ion-color-white-contrast-rgb
);
--ion-color-shade
:
var
(
--
ion-color-white-shade
);
--ion-color-tint
:
var
(
--
ion-color-white-tint
);
}
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