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
48fea58e
Commit
48fea58e
authored
Oct 19, 2018
by
wangqinghua
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
color
parent
22ab2b7b
Show whitespace changes
Inline
Side-by-side
Showing
13 changed files
with
120 additions
and
78 deletions
+120
-78
config.xml
config.xml
+2
-2
joinDetail.html
src/pages/activity-track/joinDetail/joinDetail.html
+2
-2
replace-apply.ts
src/pages/activity-track/replace-apply/replace-apply.ts
+51
-38
activityApply.html
src/pages/activity/activityApply/activityApply.html
+1
-1
activityApply.ts
src/pages/activity/activityApply/activityApply.ts
+7
-1
activityDetail.html
src/pages/activity/activityDetail/activityDetail.html
+6
-4
activityDetail.scss
src/pages/activity/activityDetail/activityDetail.scss
+1
-0
activityDetail.ts
src/pages/activity/activityDetail/activityDetail.ts
+3
-2
order-detail.html
src/pages/activity/order-detail/order-detail.html
+4
-1
order-detail.ts
src/pages/activity/order-detail/order-detail.ts
+7
-2
block-list.html
src/pages/contact/block-list/block-list.html
+7
-0
block-list.ts
src/pages/contact/block-list/block-list.ts
+2
-2
home.ts
src/pages/tabs/home/home.ts
+27
-23
No files found.
config.xml
View file @
48fea58e
<?xml version='1.0' encoding='utf-8'?>
<widget
id=
"io.ionic.starter
"
version=
"1.3.1
"
xmlns=
"http://www.w3.org/ns/widgets"
xmlns:cdv=
"http://cordova.apache.org/ns/1.0"
>
<name>
智汇19号
</name>
<widget
id=
"io.ionic.starter
2"
version=
"1.3.5
"
xmlns=
"http://www.w3.org/ns/widgets"
xmlns:cdv=
"http://cordova.apache.org/ns/1.0"
>
<name>
智汇19号
(测)
</name>
<description>
An awesome Ionic/Cordova app.
</description>
<author
email=
"hi@ionicframework"
href=
"http://ionicframework.com/"
>
Ionic Framework Team
</author>
<content
src=
"index.html"
/>
...
...
src/pages/activity-track/joinDetail/joinDetail.html
View file @
48fea58e
...
...
@@ -96,8 +96,8 @@
<button
ion-button
round
class=
"btn color3"
>
未报名
</button>
</div>
<div
class=
"margin-top-5"
>
<span
disabled
(
click
)="
goSignUp
(
item
)"
ion-button
round
class=
"btn color3 blue-btn"
>
代报名
</span>
<span
disabled
(
click
)="
sayNo
(
item
)"
ion-button
round
class=
"btn color3 red-btn"
>
不参加
</span>
<span
(
click
)="
goSignUp
(
item
)"
ion-button
round
class=
"btn color3 blue-btn"
>
代报名
</span>
<span
(
click
)="
sayNo
(
item
)"
ion-button
round
class=
"btn color3 red-btn"
>
不参加
</span>
</div>
</div>
</div>
...
...
src/pages/activity-track/replace-apply/replace-apply.ts
View file @
48fea58e
import
{
Component
}
from
'@angular/core'
;
import
{
Component
}
from
'@angular/core'
;
import
{
IonicPage
,
ModalController
,
NavController
,
NavParams
}
from
'ionic-angular'
;
import
{
Response
}
from
"@angular/http"
;
import
{
AppService
}
from
"../../../service/appHttpService"
;
...
...
@@ -18,7 +18,7 @@ export class ReplaceApplyPage {
personInfo
;
//报名人信息
activity
;
//活动信息
batchList
;
//批次列表
item
;
//批次信息
item
;
//批次信息
itemName
=
'请选择批次'
;
//报名信息
...
...
@@ -27,30 +27,30 @@ export class ReplaceApplyPage {
Orderbz
:
''
,
//报名备注
Activityid
:
''
,
//关联活动id
Batchid
:
''
,
//关联批次id
UserID
:
''
,
//用户id
Username
:
''
,
//用户名称
Usertel
:
''
//用户手机
UserID
:
''
,
//用户id
Username
:
''
,
//用户名称
Usertel
:
''
//用户手机
};
constructor
(
public
navCtrl
:
NavController
,
public
navParams
:
NavParams
,
public
appService
:
AppService
,
public
modalCtrl
:
ModalController
)
{
public
appService
:
AppService
,
public
modalCtrl
:
ModalController
)
{
}
ionViewDidLoad
()
{
console
.
log
(
'ionViewDidLoad ReplaceApplyPage'
);
}
ionViewDidEnter
()
{
ionViewDidEnter
()
{
this
.
activityId
=
this
.
navParams
.
get
(
"id"
);
this
.
personInfo
=
this
.
navParams
.
get
(
"personInfo"
);
this
.
getActivety
();
}
//获取活动信息
getActivety
()
{
getActivety
()
{
let
now
=
new
Date
().
getTime
();
this
.
appService
.
ObserverHttpGet
(
"/wisdomgroup/modules/activity/findAllActivityForAppWithXQ"
,
{
"id"
:
this
.
activityId
})
.
subscribe
((
res
:
Response
)
=>
{
this
.
appService
.
ObserverHttpGet
(
"/wisdomgroup/modules/activity/findAllActivityForAppWithXQ"
,
{
"id"
:
this
.
activityId
})
.
subscribe
((
res
:
Response
)
=>
{
this
.
activity
=
res
.
json
();
this
.
batchList
=
this
.
activity
.
batchList
;
},
(
error
)
=>
{
...
...
@@ -61,17 +61,17 @@ export class ReplaceApplyPage {
//携带人数 数字加减
add
()
{
if
(
!
this
.
item
)
{
if
(
!
this
.
item
)
{
return
false
;
}
console
.
log
(
"1:"
+
this
.
order
.
Personnumber
);
if
(
this
.
order
.
Personnumber
<
this
.
item
.
batchPerNumber
)
{
console
.
log
(
"1:"
+
this
.
order
.
Personnumber
);
if
(
this
.
order
.
Personnumber
<
this
.
item
.
batchPerNumber
)
{
this
.
order
.
Personnumber
++
;
}
}
next
()
{
if
(
!
this
.
item
)
{
if
(
!
this
.
item
)
{
return
false
;
}
if
(
this
.
order
.
Personnumber
>=
1
)
{
...
...
@@ -80,10 +80,10 @@ export class ReplaceApplyPage {
}
//选择批次
selectblock
(){
let
modal
=
this
.
modalCtrl
.
create
(
BlockModalPage
,{
blockList
:
this
.
batchList
});
modal
.
onDidDismiss
(
res
=>
{
if
(
res
)
{
selectblock
()
{
let
modal
=
this
.
modalCtrl
.
create
(
BlockModalPage
,
{
blockList
:
this
.
batchList
});
modal
.
onDidDismiss
(
res
=>
{
if
(
res
)
{
this
.
item
=
res
;
this
.
itemName
=
res
.
batchName
;
}
...
...
@@ -100,48 +100,61 @@ export class ReplaceApplyPage {
applyNum:报名批次数量
**/
if
(
!
this
.
item
)
{
this
.
appService
.
popToastView
(
"请选择报名批次"
,
'middle'
,
1000
);
if
(
!
this
.
item
)
{
this
.
appService
.
popToastView
(
"请选择报名批次"
,
'middle'
,
1000
);
return
false
;
}
if
(
new
Date
().
getTime
()
>
new
Date
(
this
.
item
.
batchEndDate
).
getTime
()
)
{
this
.
appService
.
popToastView
(
"该批次已过截止时间"
,
'middle'
,
1000
);
if
(
new
Date
().
getTime
()
>
new
Date
(
this
.
item
.
batchEndDate
).
getTime
())
{
this
.
appService
.
popToastView
(
"该批次已过截止时间"
,
'middle'
,
1000
);
return
false
;
}
let
leaveNum
=
this
.
item
.
batchLimitNumber
-
this
.
item
.
hasSignUpCount
;
let
applyNum
=
0
;
this
.
activity
.
batchList
.
forEach
((
res
)
=>
{
if
(
res
.
order
)
{
console
.
log
(
res
.
order
);
applyNum
++
;
this
.
activity
.
batchList
.
forEach
((
res
)
=>
{
if
(
res
.
order
)
{
console
.
log
(
res
);
//
applyNum
++
;
}
});
//报名次数 applyCount 1,2,3,4,5,0-> 不限
if
(
this
.
activity
.
applyCount
>
0
){
if
(
applyNum
>=
this
.
activity
.
applyCount
){
this
.
appService
.
popToastView
(
"提交失败,报名批次达到上限"
,
'middle'
,
1000
);
return
false
;
}
else
if
(
Number
(
this
.
order
.
Personnumber
+
1
)
>
Number
(
leaveNum
))
{
this
.
appService
.
popToastView
(
"报名人数超过了该批次的剩余人数"
,
'middle'
,
1000
);
console
.
log
(
Number
(
this
.
order
.
Personnumber
+
1
),
Number
(
leaveNum
));
console
.
log
(
applyNum
,
this
.
activity
.
applyCount
);
if
(
this
.
activity
.
applyCount
==
0
)
{
console
.
log
(
'true1'
);
if
(
Number
(
this
.
order
.
Personnumber
+
1
)
>
Number
(
leaveNum
))
{
console
.
log
(
'报名人数超过了该批次的剩余人数'
);
this
.
appService
.
popToastView
(
"报名人数超过了该批次的剩余人数"
,
'middle'
,
1000
);
return
false
;
}
else
{
this
.
submitOrder
();
//
this.submitOrder();
}
}
else
{
//报名(新增)
this
.
submitOrder
();
if
(
applyNum
>=
this
.
activity
.
applyCount
)
{
console
.
log
(
'提交失败,报名批次达到上限'
);
this
.
appService
.
popToastView
(
"提交失败,报名批次达到上限"
,
'middle'
,
1000
);
return
false
;
}
else
if
(
Number
(
this
.
order
.
Personnumber
+
1
)
>
Number
(
leaveNum
))
{
console
.
log
(
'报名人数超过了该批次的剩余人数'
);
this
.
appService
.
popToastView
(
"报名人数超过了该批次的剩余人数"
,
'middle'
,
1000
);
return
false
;
}
else
{
console
.
log
(
'true'
);
// this.submitOrder();
}
}
}
// 提交订单
submitOrder
(){
submitOrder
()
{
const
order
=
{
Personnumber
:
this
.
order
.
Personnumber
,
//携带人数
Orderbz
:
this
.
order
.
Orderbz
,
//报名备注
Activityid
:
this
.
activityId
,
//关联活动id
Batchid
:
this
.
item
.
id
,
//关联批次id
UserID
:
this
.
personInfo
.
id
,
Username
:
this
.
personInfo
.
name
,
Usertel
:
this
.
personInfo
.
mobile
UserID
:
this
.
personInfo
.
id
,
Username
:
this
.
personInfo
.
name
,
Usertel
:
this
.
personInfo
.
mobile
};
this
.
order
.
Batchid
=
this
.
item
.
id
;
this
.
order
.
Activityid
=
this
.
item
.
activityId
;
...
...
src/pages/activity/activityApply/activityApply.html
View file @
48fea58e
...
...
@@ -29,5 +29,5 @@
<ion-textarea
[(
ngModel
)]="
order
.
Orderbz
"
class=
"content-textarea"
></ion-textarea>
</ion-item>
<button
class=
"submit-btn submit"
(
click
)="
con
firmOrder
()"
>
提交订单
</button>
<button
class=
"submit-btn submit"
(
click
)="
con
dirmAlert
()"
>
提交订单
</button>
</ion-content>
src/pages/activity/activityApply/activityApply.ts
View file @
48fea58e
...
...
@@ -131,8 +131,14 @@ export class ActivityApplyPage {
this
.
isCover
=
true
;
}
condirmAlert
(){
this
.
appService
.
alert
(
'确定提交该活动订单?'
,(
res
)
=>
{
this
.
confirmOrder
();
})
}
//报名
confirmOrder
(
orderId
)
{
confirmOrder
()
{
//验证信息:
/**0.对于暂未有批次的。
1.判断携带人数是否超过限额人数。
...
...
src/pages/activity/activityDetail/activityDetail.html
View file @
48fea58e
...
...
@@ -11,11 +11,13 @@
</div>
<div
class=
"item1-content"
>
<div
class=
"margin-5-0"
>
<label
class=
"item1-title"
>
{{activity?.activityName}}
</label>
<label
class=
"item1-title"
>
{{activity?.activityName}}
<button
class=
"btn-introduce"
(
click
)="
show
()"
>
具体介绍
</button>
</label>
</div>
<div
class=
"item1-introduction"
>
{{activity.activityIntro}}
<button
class=
"btn-introduce"
(
click
)="
show
()"
>
具体介绍
</button>
<!--{{activity.activityIntro}}-->
{{introduce}}
</div>
</div>
</div>
...
...
@@ -31,7 +33,7 @@
<span
*
ngIf=
"activity.applyCount == 0 || !activity.applyCount"
>
{{ batchList.length}}
</span>
<span
*
ngIf=
"activity.applyCount != 0"
>
{{activity.applyCount}}
</span>
个批次)
<ng-container
*
ngIf=
"batch?.order?.orderstate
== 1 || batch?.order?.orderstate =
= 2"
>
<ng-container
*
ngIf=
"batch?.order?.orderstate
!= 1 && batch?.order?.orderstate !
= 2"
>
<span
*
ngIf=
"activity?.activityNo == '0'"
(
click
)="
sayNo
()"
class=
"item-type"
>
不想参加
</span>
...
...
src/pages/activity/activityDetail/activityDetail.scss
View file @
48fea58e
...
...
@@ -196,6 +196,7 @@ page-activityDetail {
float
:
right
;
color
:
#666666
;
border-radius
:
4px
;
margin-right
:
18px
;
}
.back-btn
{
...
...
src/pages/activity/activityDetail/activityDetail.ts
View file @
48fea58e
...
...
@@ -17,7 +17,8 @@ export class ActivityDetailPage {
activityId
;
//活动ID
batches
:
object
[];
activity
=
{
batchList
:
[]
batchList
:
[],
activityIntro
:
''
};
picture
:
string
=
AppGlobal
.
picture
;
batchList
=
[];
...
...
@@ -45,12 +46,12 @@ export class ActivityDetailPage {
}
findMyOrderByOrderId
()
{
let
now
=
new
Date
().
getTime
();
this
.
appService
.
ObserverHttpGet
(
"/wisdomgroup/modules/activity/findAllActivityForAppWithXQ"
,
{
"id"
:
this
.
activityId
})
.
subscribe
((
res
:
Response
)
=>
{
this
.
activity
=
res
.
json
();
this
.
batchList
=
this
.
activity
.
batchList
;
this
.
subIntroduce
(
this
.
activity
.
activityIntro
);
for
(
let
i
=
0
;
i
<
this
.
batchList
.
length
;
i
++
)
{
let
endDate
=
this
.
batchList
[
i
].
batchEndDate
+
" 24:00:00"
;
endDate
=
new
Date
(
endDate
).
getTime
()
+
''
;
//判断是否过截止日期
...
...
src/pages/activity/order-detail/order-detail.html
View file @
48fea58e
...
...
@@ -25,7 +25,10 @@
<p><span>
出行日期:
</span><span>
{{batch?.batchGoDate}}
</span></p>
<p><span>
集合时间:
</span><span>
{{batch?.batchSetTime}}
</span></p>
<p><span>
集合地点:
</span><span>
{{batch?.batchSetAddress}}
</span></p>
<p><span>
活动须知:
</span><span>
{{batch?.batchNotice}}
</span></p>
<p><span>
联络员:
</span><span>
{{batch?.liamand}}
</span></p>
<p><span>
联络电话:
</span><span>
{{batch?.liamantel}}
</span></p>
<p><span>
活动须知:
</span><br>
<span
[
innerHtml
]='
batch
.
batchNotice
'
></span>
</div>
</div>
<div
class=
"content-button"
>
...
...
src/pages/activity/order-detail/order-detail.ts
View file @
48fea58e
...
...
@@ -2,6 +2,7 @@ import {Component} from '@angular/core';
import
{
IonicPage
,
NavController
,
NavParams
}
from
'ionic-angular'
;
import
{
Response
}
from
"@angular/http"
;
import
{
AppService
}
from
"../../../service/appHttpService"
;
import
{
DomSanitizer
}
from
"@angular/platform-browser"
;
@
IonicPage
()
...
...
@@ -19,19 +20,23 @@ export class OrderDetailPage {
activityName
:
''
,
activityIntro
:
''
};
//活动
batch
;
//批次
batch
=
{
batchNotice
:
<
any
>
''
};
//批次
isCover
=
false
;
isIntroduce
=
false
;
constructor
(
public
navCtrl
:
NavController
,
public
navParams
:
NavParams
,
public
appService
:
AppService
)
{
public
appService
:
AppService
,
public
sanitizer
:
DomSanitizer
)
{
}
ionViewDidEnter
()
{
this
.
order
=
this
.
navParams
.
get
(
'item'
);
this
.
activity
=
this
.
navParams
.
get
(
'item'
).
activity
;
this
.
batch
=
this
.
navParams
.
get
(
'item'
).
batch
;
let
con
=
this
.
batch
.
batchNotice
.
replace
(
/
\r?\n
/g
,
"<br />"
);
this
.
batch
.
batchNotice
=
this
.
sanitizer
.
bypassSecurityTrustHtml
(
con
);
console
.
log
(
this
.
order
);
}
...
...
src/pages/contact/block-list/block-list.html
View file @
48fea58e
...
...
@@ -18,8 +18,15 @@
<ion-item-sliding
*
ngFor=
"let contactPerson of contactPersons"
>
<ion-item>
<div
class=
"contact-box"
(
click
)="
contactPersonInfo
(
contactPerson
)"
>
<ng-container
*
ngIf=
"contactPerson?.picUrl && contactPerson?.picUrl != ''"
>
<img
src=
"{{picture+contactPerson.picUrl}}"
class=
"contact-img"
>
</ng-container>
<ng-container
*
ngIf=
"!contactPerson?.picUrl || contactPerson?.picUrl == ''"
>
<img
src=
"./assets/imgs/man.png"
class=
"contact-img"
*
ngIf=
"contactPerson.gender =='1'||contactPerson.gender==null"
>
<img
src=
"./assets/imgs/woman.png"
class=
"contact-img"
*
ngIf=
"contactPerson.gender =='0'"
>
</ng-container>
<div
class=
"contact-box-right"
>
<div>
<span
class=
"contact-name"
>
{{contactPerson.name}}
</span>
...
...
src/pages/contact/block-list/block-list.ts
View file @
48fea58e
import
{
Component
}
from
'@angular/core'
;
import
{
IonicPage
,
ModalController
,
NavController
,
NavParams
,
ToastController
}
from
'ionic-angular'
;
import
{
AppService
}
from
"../../../service/appHttpService"
;
import
{
App
Global
,
App
Service
}
from
"../../../service/appHttpService"
;
import
{
ContactModalPage
}
from
"../contact-modal/contact-modal"
;
import
{
PersonListPage
}
from
"../person-list/person-list"
;
import
{
message
}
from
"../../../app/main"
;
...
...
@@ -16,7 +16,7 @@ export class BlockListPage {
orgid
;
orgName
;
contactPersons
;
picture
:
string
=
AppGlobal
.
picture
;
constructor
(
public
navCtrl
:
NavController
,
public
navParams
:
NavParams
,
public
appService
:
AppService
,
public
modalCtrl
:
ModalController
,
public
toastCtrl
:
ToastController
)
{
...
...
src/pages/tabs/home/home.ts
View file @
48fea58e
...
...
@@ -387,22 +387,6 @@ export class HomePage {
}
loadEvent
(
year
,
month
)
{
let
date
=
new
Date
();
//4.每月的周末
let
d
=
new
Date
(
year
,
month
,
0
).
getDate
();
for
(
let
i
=
1
;
i
<
d
+
1
;
i
++
)
{
date
.
setFullYear
(
year
,
month
-
1
,
i
);
let
day
=
date
.
getDay
();
if
(
day
==
6
||
day
==
0
)
{
const
data
=
{
date
:
new
Date
(
year
,
month
-
1
,
i
),
disable
:
true
,
cssClass
:
'dayOff1'
};
this
.
newArr
.
push
(
data
);
}
}
//5.获取每月值班信息
const
data
=
{
date
:
year
+
'/'
+
month
+
'/01'
...
...
@@ -430,6 +414,33 @@ export class HomePage {
cssClass
:
'dayOff1'
};
this
.
newArr
.
push
(
data
);
});
this
.
setCalendar
(
year
,
month
);
});
},
error
=>
{
this
.
appService
.
alert
(
'网络异常!'
);
}
);
}
setCalendar
(
year
,
month
){
let
date
=
new
Date
();
//4.每月的周末
let
d
=
new
Date
(
year
,
month
,
0
).
getDate
();
for
(
let
i
=
1
;
i
<
d
+
1
;
i
++
)
{
date
.
setFullYear
(
year
,
month
-
1
,
i
);
let
day
=
date
.
getDay
();
if
(
day
==
6
||
day
==
0
)
{
const
data
=
{
date
:
new
Date
(
year
,
month
-
1
,
i
),
disable
:
true
,
cssClass
:
'dayOff1'
};
this
.
newArr
.
push
(
data
);
}
}
this
.
optionsMulti
=
{
pickMode
:
'multi'
,
monthFormat
:
'YYYY 年 MM 月 '
,
...
...
@@ -439,13 +450,6 @@ export class HomePage {
disableWeeks
:
[
0
,
1
,
2
,
3
,
4
,
5
,
6
],
daysConfig
:
this
.
newArr
};
})
});
},
error
=>
{
this
.
appService
.
alert
(
'网络异常!'
);
}
);
}
onChange
(
e
)
{
...
...
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