Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wisdom-ces
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
wisdom-ces
Commits
fc025215
Commit
fc025215
authored
Sep 21, 2018
by
wangqinghua
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
问卷调查
parent
890fbd68
Hide whitespace changes
Inline
Side-by-side
Showing
18 changed files
with
270 additions
and
131 deletions
+270
-131
outGoingReportDetail.ts
...pages/report/outGoingReportDetail/outGoingReportDetail.ts
+16
-1
create.html
src/pages/surveyManage/item/create/create.html
+3
-10
create.ts
src/pages/surveyManage/item/create/create.ts
+40
-16
desicr.html
src/pages/surveyManage/item/desicr/desicr.html
+3
-3
desicr.ts
src/pages/surveyManage/item/desicr/desicr.ts
+26
-2
edit.html
src/pages/surveyManage/item/edit/edit.html
+4
-4
edit.scss
src/pages/surveyManage/item/edit/edit.scss
+3
-0
edit.ts
src/pages/surveyManage/item/edit/edit.ts
+14
-1
select-type.ts
src/pages/surveyManage/item/select-type/select-type.ts
+5
-9
list.html
src/pages/surveyManage/list/list.html
+10
-45
list.scss
src/pages/surveyManage/list/list.scss
+21
-0
list.ts
src/pages/surveyManage/list/list.ts
+38
-9
person.html
src/pages/surveyManage/modal/person/person.html
+13
-1
person.ts
src/pages/surveyManage/modal/person/person.ts
+20
-10
home.html
src/pages/tabs/home/home.html
+28
-19
home.module.ts
src/pages/tabs/home/home.module.ts
+3
-1
home.ts
src/pages/tabs/home/home.ts
+14
-0
appHttpService.ts
src/service/appHttpService.ts
+9
-0
No files found.
src/pages/report/outGoingReportDetail/outGoingReportDetail.ts
View file @
fc025215
...
@@ -120,7 +120,22 @@ export class OutGoingReportDetailPage {
...
@@ -120,7 +120,22 @@ export class OutGoingReportDetailPage {
}
}
ngOnInit
():
void
{
ngOnInit
():
void
{
const
data
=
{
'inorout'
:
'2'
}
this
.
appService
.
ObserverHttpGetOption
(
'/wisdomgroup/area/area/getProvince'
,
data
).
subscribe
(
(
res
:
Response
)
=>
{
console
.
log
(
res
)
}
)
const
data1
=
{
'parentId'
:
'8514'
}
this
.
appService
.
ObserverHttpGetOption
(
'/wisdomgroup/area/area/getCityByParentId'
,
data1
).
subscribe
(
(
res
:
Response
)
=>
{
console
.
log
(
res
)
}
)
}
}
...
...
src/pages/surveyManage/item/create/create.html
View file @
fc025215
<!--
Generated template for the CreatePage page.
See http://ionicframework.com/docs/components/#navigation for more info on
Ionic pages and navigation.
-->
<ion-header>
<ion-header>
<ion-navbar>
<ion-navbar>
...
@@ -20,16 +14,15 @@
...
@@ -20,16 +14,15 @@
<ion-list>
<ion-list>
<ion-item>
<ion-item>
<ion-label
color=
"primary"
stacked
><span
class=
"color-red"
>
*
</span>
标题
</ion-label>
<ion-label
color=
"primary"
stacked
><span
class=
"color-red"
>
*
</span>
标题
</ion-label>
<ion-input
type=
"text"
placeholder=
"请输入标题"
></ion-input>
<ion-input
type=
"text"
[(
ngModel
)]="
titile
"
placeholder=
"请输入标题"
></ion-input>
</ion-item>
</ion-item>
<div
class=
"create-content"
*
ngIf=
"qType != 4 && qType != 1"
>
<div
class=
"create-content"
*
ngIf=
"qType != 4 && qType != 1"
>
<p>
选项
</p>
<p>
选项
</p>
<ion-item
*
ngFor=
"let item of
option
List;let i = index;"
>
<ion-item
*
ngFor=
"let item of
quesDesc
List;let i = index;"
>
<span
(
click
)="
removeOption
(
i
)"
class=
"color-red"
>
-
</span>
<span
(
click
)="
removeOption
(
i
)"
class=
"color-red"
>
-
</span>
<input
type=
"text"
[(
ngModel
)]="
item
.
desc
"
placeholder=
"请输入选项"
>
<input
type=
"text"
[(
ngModel
)]="
item
.
option_title
"
placeholder=
"请输入选项"
>
<ion-icon
float-right
ios=
"ios-more"
md=
"md-more"
></ion-icon>
<ion-icon
float-right
ios=
"ios-more"
md=
"md-more"
></ion-icon>
</ion-item>
</ion-item>
<p
(
click
)="
addOption
()"
><span>
+
</span>
添加选项
</p>
<p
(
click
)="
addOption
()"
><span>
+
</span>
添加选项
</p>
</div>
</div>
<div
class=
"create-set"
>
<div
class=
"create-set"
>
...
...
src/pages/surveyManage/item/create/create.ts
View file @
fc025215
import
{
Component
}
from
'@angular/core'
;
import
{
Component
}
from
'@angular/core'
;
import
{
IonicPage
,
NavController
,
NavParams
}
from
'ionic-angular'
;
import
{
IonicPage
,
NavController
,
NavParams
}
from
'ionic-angular'
;
import
{
EditPage
}
from
"../edit/edit"
;
import
{
EditPage
}
from
"../edit/edit"
;
import
{
AppService
}
from
"../../../../service/appHttpService"
;
/**
* Generated class for the CreatePage page.
*
* See https://ionicframework.com/docs/components/#navigation for more info on
* Ionic pages and navigation.
*/
@
IonicPage
()
@
IonicPage
()
@
Component
({
@
Component
({
...
@@ -17,17 +12,25 @@ import {EditPage} from "../edit/edit";
...
@@ -17,17 +12,25 @@ import {EditPage} from "../edit/edit";
export
class
CreatePage
{
export
class
CreatePage
{
qType
;
//题目类型
qType
;
//题目类型
lastchange
;
titile
;
//标题
morechange
;
quesDescList
=
[
//选项
{
option_title
:
''
,
//选项文字
canFill
:
2
,
// 1是 2否
isNeed
:
'1'
,
// 1是 2否
index
:
0
},
//序号
]
lastchange
;
morechange
;
set
:{
//设置
set
:{
//设置
lastchange
:
'1'
,
lastchange
:
'1'
,
morechange
:
'1'
,
morechange
:
'1'
,
isAns
:
''
isAns
:
''
};
};
optionList
=
[
//选项
{
desc
:
''
}
constructor
(
public
navCtrl
:
NavController
,
public
navParams
:
NavParams
,
]
public
appService
:
AppService
)
{
constructor
(
public
navCtrl
:
NavController
,
public
navParams
:
NavParams
)
{
}
}
ionViewDidLoad
()
{
ionViewDidLoad
()
{
...
@@ -36,16 +39,37 @@ export class CreatePage {
...
@@ -36,16 +39,37 @@ export class CreatePage {
}
}
addOption
(){
addOption
(){
const
option
=
{
desc
:
''
};
const
option
=
{
this
.
optionList
.
push
(
option
);
option_title
:
''
,
//选项文字
canFill
:
2
,
// 1是 2否
isNeed
:
'1'
,
// 1是 2否
index
:
0
};
//序号
this
.
quesDescList
.
push
(
option
);
}
}
removeOption
(
i
){
removeOption
(
i
){
this
.
option
List
.
splice
(
i
,
1
);
this
.
quesDesc
List
.
splice
(
i
,
1
);
}
}
submit
(){
submit
(){
this
.
navCtrl
.
push
(
'EditPage'
);
// this.navCtrl.push('EditPage');
const
data
=
[
{
questionId
:
''
,
isAns
:
''
,
quesType
:
this
.
qType
,
title
:
this
.
titile
,
limlt
:
''
,
//问答的字数限制
quesDesc
:
this
.
quesDescList
}
]
this
.
appService
.
ObserverHttpPostData
(
'/wisdomgroup/modules/question/saveQuestion'
,
this
.
set
)
.
subscribe
(
(
res
)
=>
{
console
.
log
(
res
);
}
)
}
}
}
}
src/pages/surveyManage/item/desicr/desicr.html
View file @
fc025215
...
@@ -11,15 +11,15 @@
...
@@ -11,15 +11,15 @@
<ion-list>
<ion-list>
<ion-item>
<ion-item>
<ion-label
stacked
><span
class=
"color-red"
>
*
</span>
问卷标题
</ion-label>
<ion-label
stacked
><span
class=
"color-red"
>
*
</span>
问卷标题
</ion-label>
<ion-input
class=
"label-input"
type=
"password
"
placeholder=
"请输入标题"
></ion-input>
<ion-input
class=
"label-input"
[(
ngModel
)]="
desrc
.
title
"
type=
"text
"
placeholder=
"请输入标题"
></ion-input>
</ion-item>
</ion-item>
<ion-item>
<ion-item>
<span><span
class=
"color-red"
>
*
</span>
参与用户组
</span>
<span><span
class=
"color-red"
>
*
</span>
参与用户组
</span>
<span
(
click
)="
selectPerson
()"
class=
"color-666"
style=
"font-size: 1.5rem"
float-right
>
选择用户组
<ion-icon
style=
"vertical-align: text-bottom
;"
ios=
"ios-arrow-forward"
md=
"md-arrow-forward"
></ion-icon>
</span>
<span
(
click
)="
selectPerson
()"
class=
"color-666"
style=
"font-size: 1.5rem"
float-right
>
{{groupName}}
<ion-icon
style=
"vertical-align: text-bottom;margin-left: 4px
;"
ios=
"ios-arrow-forward"
md=
"md-arrow-forward"
></ion-icon>
</span>
</ion-item>
</ion-item>
<ion-item>
<ion-item>
<ion-label
stacked
><span
class=
"color-red"
>
*
</span>
问卷说明
</ion-label>
<ion-label
stacked
><span
class=
"color-red"
>
*
</span>
问卷说明
</ion-label>
<ion-textarea></ion-textarea>
<ion-textarea
[(
ngModel
)]="
desrc
.
explai
"
></ion-textarea>
</ion-item>
</ion-item>
</ion-list>
</ion-list>
...
...
src/pages/surveyManage/item/desicr/desicr.ts
View file @
fc025215
...
@@ -2,6 +2,7 @@ import { Component } from '@angular/core';
...
@@ -2,6 +2,7 @@ import { Component } from '@angular/core';
import
{
IonicPage
,
ModalController
,
NavController
,
NavParams
}
from
'ionic-angular'
;
import
{
IonicPage
,
ModalController
,
NavController
,
NavParams
}
from
'ionic-angular'
;
import
{
EditPage
}
from
"../edit/edit"
;
import
{
EditPage
}
from
"../edit/edit"
;
import
{
PersonPage
}
from
"../../modal/person/person"
;
import
{
PersonPage
}
from
"../../modal/person/person"
;
import
{
AppService
}
from
"../../../../service/appHttpService"
;
@
IonicPage
()
@
IonicPage
()
...
@@ -11,8 +12,19 @@ import {PersonPage} from "../../modal/person/person";
...
@@ -11,8 +12,19 @@ import {PersonPage} from "../../modal/person/person";
})
})
export
class
DesicrPage
{
export
class
DesicrPage
{
desrc
=
{
title
:
''
,
//问卷标题
explai
:
''
,
//问卷说明
usergroup
:
''
,
//用户组id
isopen
:
0
,
//是否公开
isans
:
1
,
//是否匿名
state
:
1
//状态
};
groupName
=
'选择用户组'
;
constructor
(
public
navCtrl
:
NavController
,
public
navParams
:
NavParams
,
constructor
(
public
navCtrl
:
NavController
,
public
navParams
:
NavParams
,
public
modalCtrl
:
ModalController
)
{
public
modalCtrl
:
ModalController
,
public
appService
:
AppService
)
{
}
}
ionViewDidLoad
()
{
ionViewDidLoad
()
{
...
@@ -20,11 +32,23 @@ export class DesicrPage {
...
@@ -20,11 +32,23 @@ export class DesicrPage {
}
}
submitOrder
(){
submitOrder
(){
this
.
navCtrl
.
push
(
'EditPage'
);
// this.navCtrl.push('EditPage');
const
data
=
{}
this
.
appService
.
ObserverHttpPost
(
'/wisdomgroup/modules/question/create'
,
this
.
desrc
)
.
subscribe
(
(
res
)
=>
{
this
.
navCtrl
.
pop
();
}
)
}
}
selectPerson
(){
selectPerson
(){
let
modal
=
this
.
modalCtrl
.
create
(
PersonPage
);
let
modal
=
this
.
modalCtrl
.
create
(
PersonPage
);
modal
.
onDidDismiss
(
data
=>
{
console
.
log
(
data
);
this
.
desrc
.
usergroup
=
data
.
id
;
this
.
groupName
=
data
.
groupName
;
})
modal
.
present
();
modal
.
present
();
}
}
...
...
src/pages/surveyManage/item/edit/edit.html
View file @
fc025215
...
@@ -34,19 +34,19 @@
...
@@ -34,19 +34,19 @@
<ion-footer>
<ion-footer>
<div
class=
"footter-opr"
>
<div
class=
"footter-opr"
>
<div
(
click
)="
add
()"
>
<div
(
click
)="
add
()"
>
<img
src=
"../../../../assets/imgs/survey/add.png"
alt=
""
>
<img
src=
"../../../../assets/imgs/survey/add.png"
alt=
""
>
<br>
<span>
题目
</span>
<span>
题目
</span>
</div>
</div>
<div
(
click
)="
set
()"
>
<div
(
click
)="
set
()"
>
<img
src=
"../../../../assets/imgs/survey/set.png"
alt=
""
>
<img
src=
"../../../../assets/imgs/survey/set.png"
alt=
""
>
<br>
<span>
设置
</span>
<span>
设置
</span>
</div>
</div>
<div
(
click
)="
look
()"
>
<div
(
click
)="
look
()"
>
<img
src=
"../../../../assets/imgs/survey/look.png"
alt=
""
>
<img
src=
"../../../../assets/imgs/survey/look.png"
alt=
""
>
<br>
<span>
预览
</span>
<span>
预览
</span>
</div>
</div>
<div
(
click
)="
save
()"
>
<div
(
click
)="
save
()"
>
<img
src=
"../../../../assets/imgs/survey/save.png"
alt=
""
>
<img
src=
"../../../../assets/imgs/survey/save.png"
alt=
""
>
<br>
<span>
保存
</span>
<span>
保存
</span>
</div>
</div>
</div>
</div>
...
...
src/pages/surveyManage/item/edit/edit.scss
View file @
fc025215
...
@@ -33,6 +33,9 @@ page-edit {
...
@@ -33,6 +33,9 @@ page-edit {
align-items
:
center
;
align-items
:
center
;
padding
:
11px
0
;
padding
:
11px
0
;
background-color
:
#fff
;
background-color
:
#fff
;
img
{
width
:
26px
;
}
}
}
.footter-opr
{
.footter-opr
{
border-top
:
1px
solid
#cccccc
;
border-top
:
1px
solid
#cccccc
;
...
...
src/pages/surveyManage/item/edit/edit.ts
View file @
fc025215
import
{
Component
}
from
'@angular/core'
;
import
{
Component
}
from
'@angular/core'
;
import
{
IonicPage
,
NavController
,
NavParams
,
ModalController
}
from
'ionic-angular'
;
import
{
IonicPage
,
NavController
,
NavParams
,
ModalController
}
from
'ionic-angular'
;
import
{
SelectTypePage
}
from
"../select-type/select-type"
;
import
{
SelectTypePage
}
from
"../select-type/select-type"
;
import
{
AppService
}
from
"../../../../service/appHttpService"
;
@
IonicPage
()
@
IonicPage
()
@
Component
({
@
Component
({
...
@@ -10,8 +11,9 @@ import {SelectTypePage} from "../select-type/select-type";
...
@@ -10,8 +11,9 @@ import {SelectTypePage} from "../select-type/select-type";
export
class
EditPage
{
export
class
EditPage
{
editIndex
;
editIndex
;
id
;
constructor
(
public
navCtrl
:
NavController
,
public
navParams
:
NavParams
,
constructor
(
public
navCtrl
:
NavController
,
public
navParams
:
NavParams
,
public
modalCtrl
:
ModalController
)
{
public
modalCtrl
:
ModalController
,
public
appService
:
AppService
)
{
}
}
qList
=
[
qList
=
[
{
name
:
'测试'
},
{
name
:
'测试'
},
...
@@ -21,7 +23,18 @@ export class EditPage {
...
@@ -21,7 +23,18 @@ export class EditPage {
];
];
ionViewDidLoad
()
{
ionViewDidLoad
()
{
this
.
id
=
this
.
navParams
.
get
(
'id'
);
console
.
log
(
'ionViewDidLoad EditPage'
);
console
.
log
(
'ionViewDidLoad EditPage'
);
this
.
getDetail
();
}
getDetail
(){
this
.
appService
.
ObserverHttpGet
(
'/wisdomgroup/modules/question/findQuesByQuestionId'
,{
id
:
this
.
id
})
.
subscribe
(
(
res
)
=>
{
console
.
log
(
res
);
}
)
}
}
//添加题目
//添加题目
...
...
src/pages/surveyManage/item/select-type/select-type.ts
View file @
fc025215
import
{
Component
}
from
'@angular/core'
;
import
{
Component
}
from
'@angular/core'
;
import
{
IonicPage
,
NavController
,
NavParams
}
from
'ionic-angular'
;
import
{
IonicPage
,
NavController
,
NavParams
}
from
'ionic-angular'
;
import
{
CreatePage
}
from
"../create/create"
;
import
{
CreatePage
}
from
"../create/create"
;
import
{
AppService
}
from
"../../../../service/appHttpService"
;
/**
import
{
Response
}
from
"@angular/http"
;
* Generated class for the SelectTypePage page.
*
* See https://ionicframework.com/docs/components/#navigation for more info on
* Ionic pages and navigation.
*/
@
IonicPage
()
@
IonicPage
()
@
Component
({
@
Component
({
...
@@ -16,11 +11,12 @@ import {CreatePage} from "../create/create";
...
@@ -16,11 +11,12 @@ import {CreatePage} from "../create/create";
})
})
export
class
SelectTypePage
{
export
class
SelectTypePage
{
constructor
(
public
navCtrl
:
NavController
,
public
navParams
:
NavParams
)
{
constructor
(
public
navCtrl
:
NavController
,
public
navParams
:
NavParams
,
public
appService
:
AppService
)
{
}
}
ionViewDidLoad
()
{
ionViewDidLoad
()
{
console
.
log
(
'ionViewDidLoad SelectTypePage'
);
}
}
select
(
type
){
select
(
type
){
...
...
src/pages/surveyManage/list/list.html
View file @
fc025215
...
@@ -9,7 +9,9 @@
...
@@ -9,7 +9,9 @@
<div
class=
"swiper-wrapper"
>
<div
class=
"swiper-wrapper"
>
<!-- {{i==0?'bottomLine':''}}是初始化的时候默认选择第一个菜单 -->
<!-- {{i==0?'bottomLine':''}}是初始化的时候默认选择第一个菜单 -->
<div
class=
"swiper-slide"
*
ngFor=
"let item of menuList;let i=index;"
tappable
(
click
)="
selectPageMenu
(
i
)"
>
<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
class=
" {{swiperIndex == i? 'swiper-title':''}} "
>
{{item.name}}
</span>
<span></span>
<span></span>
</div>
</div>
</div>
</div>
...
@@ -19,63 +21,26 @@
...
@@ -19,63 +21,26 @@
<ion-content>
<ion-content>
<ion-slides
#
contentSlides
class=
"height-190"
(
ionSlideDidChange
)="
slideChanged
()"
>
<ion-slide
*
ngFor=
"let item of menuList"
>
<ion-content
direction=
"y"
scrollbar-y=
"true"
class=
"bgc-e7e8ed"
>
<ion-content
direction=
"y"
scrollbar-y=
"true"
class=
"bgc-e7e8ed"
>
<ion-list>
<ion-list>
<ion-item
class=
"item-list"
>
<ion-item
class=
"item-list"
*
ngFor=
"let item of contentList.datalist"
>
<div
class=
"item"
(
click
)="
showOpra
(
item
)"
>
<div
class=
"item"
(
click
)="
showOpra
(
item
)"
>
<div
class=
"item-header"
>
<div
class=
"item-header"
>
<div
class=
"item-header-style"
>
<div
class=
"item-header-style"
>
<span
class=
"item-title"
>
疗休养调查
</span>
<span
class=
"item-title"
>
{{item.title}}
</span>
<span
float-right
class=
"btn btn1"
*
ngIf=
"item.state==1 "
>
未发布
</span>
<span
float-right
class=
"btn btn2"
*
ngIf=
"item.state==2 "
>
已发布
</span>
<span
float-right
class=
"btn btn3"
*
ngIf=
"item.state==3 "
>
已过期
</span>
</div>
</div>
<button
ion-button
round
class=
"btn btn1"
*
ngIf=
"item.activityState==2 "
>
未发布
</button>
<button
ion-button
round
class=
"btn btn1"
*
ngIf=
"item.activityState==2 "
>
已发布
</button>
<button
ion-button
round
class=
"btn btn1"
*
ngIf=
"item.activityState==2 "
>
已过期
</button>
</div>
</div>
<div
class=
"content-button"
>
<div
class=
"content-button"
>
<span>
参与人员:
</span>
<span>
参与人员:
</span>
<span>
最新批次名称
</span>
<span>
{{item.groupName}}
</span>
</div>
</div>
</ion-item>
<ion-item
class=
"item-list"
>
<div
class=
"item"
(
click
)="
showOpra
(
item
)"
>
<div
class=
"item-header"
>
<div
class=
"item-header-style"
>
<span
class=
"item-title"
>
疗休养调查
</span>
</div>
<button
ion-button
round
class=
"btn btn1"
*
ngIf=
"item.activityState==2 "
>
未发布
</button>
<button
ion-button
round
class=
"btn btn1"
*
ngIf=
"item.activityState==2 "
>
已发布
</button>
<button
ion-button
round
class=
"btn btn1"
*
ngIf=
"item.activityState==2 "
>
已过期
</button>
</div>
<div
class=
"content-button"
>
<span>
参与人员:
</span>
<span>
最新批次名称
</span>
</div>
</div>
</ion-item>
<ion-item
class=
"item-list"
>
<div
class=
"item"
(
click
)="
showOpra
(
item
)"
>
<div
class=
"item-header"
>
<div
class=
"item-header-style"
>
<span
class=
"item-title"
>
疗休养调查
</span>
</div>
<button
ion-button
round
class=
"btn btn1"
*
ngIf=
"item.activityState==2 "
>
未发布
</button>
<button
ion-button
round
class=
"btn btn1"
*
ngIf=
"item.activityState==2 "
>
已发布
</button>
<button
ion-button
round
class=
"btn btn1"
*
ngIf=
"item.activityState==2 "
>
已过期
</button>
</div>
<div
class=
"content-button"
>
<span>
参与人员:
</span>
<span>
最新批次名称
</span>
</div>
</div>
</div>
</div>
</ion-item>
</ion-item>
</ion-list>
</ion-list>
</ion-content>
</ion-content>
</ion-slide>
</ion-slides>
</ion-content>
</ion-content>
<ion-footer
*
ngIf=
"showOp"
>
<ion-footer
*
ngIf=
"showOp"
>
...
@@ -86,6 +51,6 @@
...
@@ -86,6 +51,6 @@
<div
(
click
)="
delete
()"
><span>
删除
</span></div>
<div
(
click
)="
delete
()"
><span>
删除
</span></div>
</div>
</div>
<ion-toolbar>
<ion-toolbar>
<ion-title>
取消
</ion-title>
<ion-title>
<span
(
click
)="
cancle
()"
>
取消
</span>
</ion-title>
</ion-toolbar>
</ion-toolbar>
</ion-footer>
</ion-footer>
src/pages/surveyManage/list/list.scss
View file @
fc025215
...
@@ -73,4 +73,25 @@ page-list {
...
@@ -73,4 +73,25 @@ page-list {
border
:
1px
solid
#aaa
;
border
:
1px
solid
#aaa
;
padding
:
10px
25px
;
padding
:
10px
25px
;
}
}
.btn1
{
font-size
:
1
.5rem
;
color
:
#fca268
;
border
:
1px
solid
#fca268
;
padding
:
1px
4px
;
border-radius
:
4px
;
}
.btn2
{
font-size
:
1
.5rem
;
color
:
#61be5f
;
border
:
1px
solid
#61be5f
;
padding
:
1px
4px
;
border-radius
:
4px
;
}
.btn3
{
font-size
:
1
.5rem
;
color
:
#dddddd
;
border
:
1px
solid
#dddddd
;
padding
:
1px
4px
;
border-radius
:
4px
;
}
}
}
src/pages/surveyManage/list/list.ts
View file @
fc025215
...
@@ -4,6 +4,8 @@ import {DetailPage} from "../item/detail/detail";
...
@@ -4,6 +4,8 @@ import {DetailPage} from "../item/detail/detail";
import
{
ResultPage
}
from
"../result/result"
;
import
{
ResultPage
}
from
"../result/result"
;
import
{
CreatePage
}
from
"../item/create/create"
;
import
{
CreatePage
}
from
"../item/create/create"
;
import
{
DesicrPage
}
from
"../item/desicr/desicr"
;
import
{
DesicrPage
}
from
"../item/desicr/desicr"
;
import
{
AppService
}
from
"../../../service/appHttpService"
;
import
{
EditPage
}
from
"../item/edit/edit"
;
declare
var
Swiper
;
declare
var
Swiper
;
...
@@ -14,22 +16,30 @@ declare var Swiper;
...
@@ -14,22 +16,30 @@ declare var Swiper;
})
})
export
class
ListPage
{
export
class
ListPage
{
@
ViewChild
(
'contentSlides'
)
contentSlides
:
Slides
;
@
ViewChild
(
'contentSlides'
)
contentSlides
:
Slides
;
menuList
=
[
contentList
=
<
any
>
[
{
name
:
'草稿箱'
,
id
:
'1'
,
itemList
:[{
one
:
''
},{
one
:
''
},{
one
:
''
},{
one
:
''
},]},
{
datalist
:[]}
{
name
:
'已发布'
,
id
:
'2'
,
itemList
:[{
one
:
''
},{
one
:
''
},{
one
:
''
},{
one
:
''
},]},
{
name
:
'已过期'
,
id
:
'3'
,
itemList
:[{
one
:
''
},{
one
:
''
},{
one
:
''
},{
one
:
''
},]},
];
];
menuList
=
[
{
name
:
'草稿箱'
},
{
name
:
'已发布'
},
{
name
:
'已过期'
}
]
showOp
=
false
;
showOp
=
false
;
swiperIndex
;
swiperIndex
;
swiper
;
swiper
;
constructor
(
public
navCtrl
:
NavController
,
public
navParams
:
NavParams
)
{
temp
;
//选中的item
constructor
(
public
navCtrl
:
NavController
,
public
navParams
:
NavParams
,
public
appService
:
AppService
)
{
}
}
ionViewDidLoad
()
{
ionViewDidLoad
()
{
this
.
initSwiper
();
this
.
initSwiper
();
this
.
selectPageMenu
(
0
);
this
.
swiperIndex
=
0
;
this
.
swiperIndex
=
0
;
}
}
initSwiper
(){
initSwiper
(){
this
.
swiper
=
new
Swiper
(
'.pageMenuSlides .swiper-container'
,
{
this
.
swiper
=
new
Swiper
(
'.pageMenuSlides .swiper-container'
,
{
//设置slider容器能够同时显示的slides数量(
//设置slider容器能够同时显示的slides数量(
...
@@ -59,20 +69,29 @@ export class ListPage {
...
@@ -59,20 +69,29 @@ export class ListPage {
}
}
selectPageMenu
(
index
)
{
selectPageMenu
(
index
)
{
const
data
=
{
state
:
index
+
1
};
this
.
appService
.
ObserverHttpGet
(
'/wisdomgroup/modules/question/findByState'
,
data
)
.
subscribe
(
(
res
:
Response
)
=>
{
this
.
contentList
=
res
.
json
();
}
)
this
.
swiperIndex
=
index
;
this
.
swiperIndex
=
index
;
//切换页面
//切换页面
this
.
contentSlides
.
slideTo
(
index
);
//
this.contentSlides.slideTo(index);
}
}
slideChanged
()
{
slideChanged
()
{
//getActiveIndex()获得当前页面的index
//getActiveIndex()获得当前页面的index
let
index
=
this
.
contentSlides
.
getActiveIndex
();
let
index
=
this
.
contentSlides
.
getActiveIndex
();
//s切换菜单
//s切换菜单
this
.
swiper
.
slideTo
(
index
,
300
);
// this.swiper.slideTo(index, 300);
}
}
showOpra
(
item
){
showOpra
(
item
){
this
.
temp
=
item
;
this
.
showOp
=
true
;
this
.
showOp
=
true
;
}
}
...
@@ -83,7 +102,7 @@ export class ListPage {
...
@@ -83,7 +102,7 @@ export class ListPage {
//查看
//查看
look
(){
look
(){
this
.
navCtrl
.
push
(
'
DetailPage'
);
this
.
navCtrl
.
push
(
'
EditPage'
,{
id
:
this
.
temp
.
id
}
);
}
}
//结果
//结果
...
@@ -98,7 +117,17 @@ export class ListPage {
...
@@ -98,7 +117,17 @@ export class ListPage {
//删除
//删除
delete
(){
delete
(){
console
.
log
(
this
.
temp
);
this
.
appService
.
ObserverHttpGet
(
'/wisdomgroup/modules/question/delete'
,{
id
:
this
.
temp
.
id
})
.
subscribe
((
res
)
=>
{
console
.
log
(
res
);
this
.
selectPageMenu
(
0
);
this
.
showOp
=
false
;
})
}
cancle
(){
this
.
showOp
=
false
;
}
}
}
}
src/pages/surveyManage/modal/person/person.html
View file @
fc025215
...
@@ -9,10 +9,22 @@
...
@@ -9,10 +9,22 @@
<ion-icon
name=
"md-close"
showWhen=
"android,windows"
></ion-icon>
<ion-icon
name=
"md-close"
showWhen=
"android,windows"
></ion-icon>
</button>
</button>
</ion-buttons>
</ion-buttons>
<ion-buttons
end
>
<button
ion-button
(
click
)="
dismiss
()"
>
<span
ion-text
color=
"primary"
showWhen=
"ios"
>
确定
</span>
<ion-icon
name=
"md-close"
showWhen=
"android,windows"
></ion-icon>
</button>
</ion-buttons>
</ion-navbar>
</ion-navbar>
</ion-header>
</ion-header>
<ion-content
padding
>
<ion-content
padding
>
<ion-list
radio-group
[(
ngModel
)]="
group
"
>
<ion-item
*
ngFor=
"let item of batchList;let i = index;"
>
<ion-label>
{{item.groupName}}
</ion-label>
<ion-label>
{{item.groupCount}}人
</ion-label>
<ion-radio
checked=
"false"
value=
"{{i}}"
></ion-radio>
</ion-item>
</ion-list>
</ion-content>
</ion-content>
src/pages/surveyManage/modal/person/person.ts
View file @
fc025215
import
{
Component
}
from
'@angular/core'
;
import
{
Component
}
from
'@angular/core'
;
import
{
IonicPage
,
NavController
,
NavParams
,
ViewController
}
from
'ionic-angular'
;
import
{
IonicPage
,
NavController
,
NavParams
,
ViewController
}
from
'ionic-angular'
;
import
{
Response
}
from
"@angular/http"
;
import
{
AppService
}
from
"../../../../service/appHttpService"
;
/**
* Generated class for the PersonPage page.
*
* See https://ionicframework.com/docs/components/#navigation for more info on
* Ionic pages and navigation.
*/
@
Component
({
@
Component
({
selector
:
'page-person'
,
selector
:
'page-person'
,
...
@@ -14,17 +10,31 @@ import {IonicPage, NavController, NavParams, ViewController} from 'ionic-angular
...
@@ -14,17 +10,31 @@ import {IonicPage, NavController, NavParams, ViewController} from 'ionic-angular
})
})
export
class
PersonPage
{
export
class
PersonPage
{
group
;
//组织id
batchList
=
[];
constructor
(
public
navCtrl
:
NavController
,
public
navParams
:
NavParams
,
constructor
(
public
navCtrl
:
NavController
,
public
navParams
:
NavParams
,
public
viewCtrl
:
ViewController
)
{
public
viewCtrl
:
ViewController
,
public
appService
:
AppService
)
{
}
}
ionViewDidLoad
()
{
ionViewDidLoad
()
{
console
.
log
(
'ionViewDidLoad PersonPage'
);
const
data
=
{
pageSize
:
'1000'
,
pageNumber
:
'1'
};
this
.
appService
.
ObserverHttpGetData
(
"wisdomgroup/sysmanagement/usergroup/search.ajax"
,
data
)
.
subscribe
((
res
:
Response
)
=>
{
let
data
=
res
.
json
();
this
.
batchList
=
data
.
list
;
console
.
log
(
this
.
batchList
);
},
error
=>
{
this
.
appService
.
alert
(
'网络异常!'
);
}
);
}
}
dismiss
()
{
dismiss
()
{
let
data
=
{
'foo'
:
'bar'
};
this
.
viewCtrl
.
dismiss
(
this
.
batchList
[
this
.
group
]);
this
.
viewCtrl
.
dismiss
(
data
);
}
}
}
}
src/pages/tabs/home/home.html
View file @
fc025215
...
@@ -96,25 +96,25 @@
...
@@ -96,25 +96,25 @@
<!--</div>-->
<!--</div>-->
</div>
</div>
</div>
</div>
<
div
class=
"item4"
>
<
!--<div class="item4">--
>
<
div
class=
"item4-1"
>
<
!--<div class="item4-1">--
>
<
ion-icon
name=
"md-people"
class=
"icon4"
></ion-icon
>
<
!--<ion-icon name="md-people" class="icon4"></ion-icon>--
>
<
label
class=
"duty_arrangements"
>
日历
</label
>
<
!--<label class="duty_arrangements">日历</label>--
>
<!--
<label class="more" (click)="wait()"
>
<!--
<!– <label class="more" (click)="wait()">--
>
更多
<!--更多-->
<
ion-icon name="arrow-dropright"></ion-icon
>
<
!--<ion-icon name="arrow-dropright"></ion-icon>--
>
<
/label>
-->
<
!--</label> –>
-->
<
/div
>
<
!--</div>--
>
<
div
class=
"item4-2"
>
<
!--<div class="item4-2">--
>
<
div
class=
"item4-title"
>
{{year}}年{{month}}月,第{{weekNo}}周
</div
>
<
!--<div class="item4-title">{{year}}年{{month}}月,第{{weekNo}}周</div>--
>
<
div
class=
"group"
(
click
)="
myCalendar
()"
>
<
!--<div class="group" (click)="myCalendar()">--
>
<
div
*
ngFor=
"let item of week"
class=
"card4"
>
<
!--<div *ngFor="let item of week" class="card4">--
>
<
div
class=
"card4-1"
>
{{item.title}}
</div
>
<
!--<div class="card4-1">{{item.title}}</div>--
>
<
div
class=
"{{item.isToday?'selected':''}} card4-2"
>
{{item.date}}
</div
>
<
!--<div class="{{item.isToday?'selected':''}} card4-2">{{item.date}}</div>--
>
<
/div
>
<
!--</div>--
>
<
/div
>
<
!--</div>--
>
<
/div
>
<
!--</div>--
>
<
/div
>
<
!--</div>--
>
<!--<div class="item5">-->
<!--<div class="item5">-->
<!--<div class="item5-1">-->
<!--<div class="item5-1">-->
<!--<ion-icon name="list" class="icon5"></ion-icon>-->
<!--<ion-icon name="list" class="icon5"></ion-icon>-->
...
@@ -137,8 +137,16 @@
...
@@ -137,8 +137,16 @@
<!--</div> –>-->
<!--</div> –>-->
<!--</div>-->
<!--</div>-->
<!--</div>-->
<!--</div>-->
<ion-calendar
[(
ngModel
)]="
date
"
(
onChange
)="
onChange
($
event
)"
[
options
]="
optionsMulti
"
[
type
]="
type
"
[
format
]="'
YYYY-MM-DD
'"
>
</ion-calendar>
</ion-content>
</ion-content>
<div
class=
"cover"
*
ngIf=
"isWait"
(
click
)="
cancleWait
()"
>
<div
class=
"cover"
*
ngIf=
"isWait"
(
click
)="
cancleWait
()"
>
<img
src=
"./assets/imgs/development.jpg"
class=
"wait"
>
<img
src=
"./assets/imgs/development.jpg"
class=
"wait"
>
</div>
</div>
\ No newline at end of file
src/pages/tabs/home/home.module.ts
View file @
fc025215
...
@@ -2,6 +2,7 @@ import { NgModule } from '@angular/core';
...
@@ -2,6 +2,7 @@ import { NgModule } from '@angular/core';
import
{
IonicPageModule
}
from
'ionic-angular'
;
import
{
IonicPageModule
}
from
'ionic-angular'
;
import
{
HomePage
}
from
'./home'
;
import
{
HomePage
}
from
'./home'
;
import
{
CalendarModule
}
from
"ion2-calendar"
;
@
NgModule
({
@
NgModule
({
...
@@ -9,7 +10,8 @@ import { HomePage } from './home';
...
@@ -9,7 +10,8 @@ import { HomePage } from './home';
HomePage
,
HomePage
,
],
],
imports
:
[
imports
:
[
IonicPageModule
.
forChild
(
HomePage
)
IonicPageModule
.
forChild
(
HomePage
),
CalendarModule
],
],
entryComponents
:
[
entryComponents
:
[
HomePage
,
HomePage
,
...
...
src/pages/tabs/home/home.ts
View file @
fc025215
...
@@ -16,6 +16,7 @@ import { OutGoingReportEditPage } from '../../report/outGoingReportEdit/outGoing
...
@@ -16,6 +16,7 @@ import { OutGoingReportEditPage } from '../../report/outGoingReportEdit/outGoing
import
{
AnnouncementViewPage
}
from
'../../announcementView/announcementView'
;
import
{
AnnouncementViewPage
}
from
'../../announcementView/announcementView'
;
import
{
MoreAppPage
}
from
"../../home/more-app/more-app"
;
import
{
MoreAppPage
}
from
"../../home/more-app/more-app"
;
import
{
ReportTrackPage
}
from
"../../report/reportTrack/reportTrack"
;
import
{
ReportTrackPage
}
from
"../../report/reportTrack/reportTrack"
;
import
{
CalendarComponentOptions
}
from
"ion2-calendar"
;
@
IonicPage
()
@
IonicPage
()
@
Component
({
@
Component
({
...
@@ -30,6 +31,17 @@ export class HomePage {
...
@@ -30,6 +31,17 @@ export class HomePage {
hasNewNotice
:
number
=
0
;
hasNewNotice
:
number
=
0
;
hasNewPremanager
:
number
=
0
;
hasNewPremanager
:
number
=
0
;
//日历
date
:
string
;
type
:
'string'
;
optionsMulti
:
CalendarComponentOptions
=
{
pickMode
:
'multi'
,
monthFormat
:
'YYYY 年 MM 月 '
,
weekdays
:
[
'天'
,
'一'
,
'二'
,
'三'
,
'四'
,
'五'
,
'六'
],
weekStart
:
1
,
};
//待出行
//待出行
waitgoCount
=
'0'
;
waitgoCount
=
'0'
;
//待确认
//待确认
...
@@ -55,6 +67,8 @@ export class HomePage {
...
@@ -55,6 +67,8 @@ export class HomePage {
//当前第几周
//当前第几周
weekNo
;
weekNo
;
//当前周日历展示
//当前周日历展示
week
:
Week
[]
=
[{
week
:
Week
[]
=
[{
id
:
0
,
id
:
0
,
...
...
src/service/appHttpService.ts
View file @
fc025215
...
@@ -80,6 +80,14 @@ export class AppService {
...
@@ -80,6 +80,14 @@ export class AppService {
return
this
.
http
.
get
(
url
,
params
)
//本地
return
this
.
http
.
get
(
url
,
params
)
//本地
}
}
//get请求带?的
ObserverHttpGetOption
(
url
,
params
):
Observable
<
any
>
{
// return this.http.get(AppGlobal.domain+url+this.encode(params,"get")) //app
return
this
.
http
.
get
(
url
,{
params
:
params
});
//本地
}
//delete
//delete
ObserverHttpDetelete
(
url
,
params
):
Observable
<
any
>
{
ObserverHttpDetelete
(
url
,
params
):
Observable
<
any
>
{
// return this.http.get(AppGlobal.domain+url+this.encode(params,"get")) //app
// return this.http.get(AppGlobal.domain+url+this.encode(params,"get")) //app
...
@@ -100,6 +108,7 @@ export class AppService {
...
@@ -100,6 +108,7 @@ export class AppService {
//post请求
//post请求
ObserverHttpPost
(
url
,
params
)
{
ObserverHttpPost
(
url
,
params
)
{
console
.
log
(
'post'
);
// return this.http.post(AppGlobal.domain+url,null,{ //app
// return this.http.post(AppGlobal.domain+url,null,{ //app
return
this
.
http
.
post
(
url
,
null
,{
//本地
return
this
.
http
.
post
(
url
,
null
,{
//本地
params
:
this
.
encode
(
params
,
'post'
),
params
:
this
.
encode
(
params
,
'post'
),
...
...
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