Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Y
ydLife
Overview
Overview
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
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Sweet Zhang
ydLife
Commits
5f0c6d70
Commit
5f0c6d70
authored
Dec 23, 2020
by
sunchao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
控制必填&图片在微信端上传
parent
fa290fb1
Hide whitespace changes
Inline
Side-by-side
Showing
21 changed files
with
504 additions
and
197 deletions
+504
-197
src/app/common/life-common.service.ts
+10
-0
src/app/domain/experienceQuery.ts
+0
-1
src/app/my/application-process/bank-card/bank-card.component.html
+24
-0
src/app/my/application-process/bank-card/bank-card.component.scss
+62
-0
src/app/my/application-process/bank-card/bank-card.component.spec.ts
+25
-0
src/app/my/application-process/bank-card/bank-card.component.ts
+49
-0
src/app/my/application-process/employee-basic-info/employee-basic-info.component.ts
+0
-1
src/app/my/application-process/employee-education/employee-education.component.html
+4
-3
src/app/my/application-process/employee-education/employee-education.component.ts
+79
-44
src/app/my/application-process/employee-id-card/employee-id-card.component.html
+3
-3
src/app/my/application-process/employee-id-card/employee-id-card.component.ts
+84
-51
src/app/my/application-process/invitation/invitation.component.ts
+1
-1
src/app/my/application-process/personal-photos/personal-photos.component.html
+2
-2
src/app/my/application-process/personal-photos/personal-photos.component.ts
+73
-46
src/app/my/application-process/personal-statement/personal-statement.component.html
+5
-21
src/app/my/application-process/personal-statement/personal-statement.component.ts
+46
-18
src/app/my/application-process/work-experience/work-experience.component.html
+2
-0
src/app/my/application-process/work-experience/work-experience.component.ts
+22
-4
src/app/my/my-routing.module.ts
+3
-0
src/app/my/my.module.ts
+3
-2
src/app/my/my.service.ts
+7
-0
No files found.
src/app/common/life-common.service.ts
View file @
5f0c6d70
...
...
@@ -75,6 +75,16 @@ export class LifeCommonService {
return
deviceType
;
}
//检测是否微信浏览器
isWeiXin
(){
let
ua
:
any
=
window
.
navigator
.
userAgent
.
toLowerCase
();
if
(
ua
.
match
(
/MicroMessenger/i
)
==
'micromessenger'
){
return
true
;
}
else
{
return
false
;
}
}
/**
* shareCode生成器
*/
...
...
src/app/domain/experienceQuery.ts
View file @
5f0c6d70
export
class
ExperienceQuery
{
constructor
(
public
hiringBasicInfoId
?:
any
,
public
workingCompany
?:
string
,
public
position
?:
string
,
public
workingStart
?:
string
,
...
...
src/app/my/application-process/bank-card/bank-card.component.html
0 → 100644
View file @
5f0c6d70
<div
class=
"wrapper"
>
<div
class=
"title"
>
<div>
银行卡号
</div>
<span
class=
"page_mark"
>
5/8
</span>
</div>
<div
class=
"content"
>
<div
class=
"contentDetail employ"
>
<div
class=
"contentItem"
>
<input
class=
"form-control"
name=
""
id=
""
placeholder=
"开户行"
[(
ngModel
)]="
bankAccountOpening
"
/>
</div>
<div
class=
"contentItem"
>
<input
class=
"form-control"
placeholder=
"银行卡号:例如 630 1234 3453 5435"
[(
ngModel
)]="
bankAccountId
"
/>
</div>
<div
class=
"contentItem"
style=
"border:none;"
>
<input
class=
"form-control"
name=
""
id=
""
style=
"text-align: left;padding: 6px 0;"
placeholder=
"再次输入银行卡号以确认"
/>
</div>
</div>
</div>
<footer
class=
"fixed"
(
click
)="
next
()"
>
保存并下一步
</footer>
</div>
<ydlife-toast
*
ngIf=
"toastDialog"
[
toastInfo
]="
toastInfo
"
></ydlife-toast>
\ No newline at end of file
src/app/my/application-process/bank-card/bank-card.component.scss
0 → 100644
View file @
5f0c6d70
.wrapper
{
font-size
:
15px
;
background
:
#fff
;
min-height
:
100%
;
select
{
-webkit-appearance
:
none
;
}
input
:
:-
webkit-input-placeholder
{
font-size
:
15px
;}
input
:
-
moz-placeholder
{
font-size
:
15px
;}
input
:
:-
moz-placeholder
{
font-size
:
15px
;}
input
:
-
ms-input-placeholder
{
font-size
:
15px
;}
.title
{
padding
:
10px
13px
0
13px
;
display
:
flex
;
justify-content
:
space-between
;
font-weight
:
bold
;
align-items
:
center
;
}
.content
{
padding
:
10px
5px
;
position
:
relative
;
.contentDetail
{
.contentItem
{
display
:
flex
;
justify-content
:
space-between
;
align-items
:
center
;
margin
:
0
8px
5px
8px
;
>
span
:first-child
{
white-space
:
nowrap
;
}
input
.form-control
,
select
.form-control
{
display
:
inline-block
;
// width: 60%;
background
:
none
;
outline
:
none
;
border
:
none
;
text-align
:
left
;
box-shadow
:
none
;
display
:
flex
;
flex-wrap
:
wrap
;
font-size
:
16px
;
padding
:
6px
0
;
}
}
.contentItem
:last-child
{
border-bottom
:
none
;
}
select
.form-control
[
disabled
]
{
background-color
:
transparent
;
color
:
#999
;
}
}
.contentDetail.employ
.contentItem
{
padding
:
10px
0
;
border-bottom
:
1px
#e8e8e8
solid
;
margin
:
0
8px
0
8px
;
}
}
}
\ No newline at end of file
src/app/my/application-process/bank-card/bank-card.component.spec.ts
0 → 100644
View file @
5f0c6d70
import
{
async
,
ComponentFixture
,
TestBed
}
from
'@angular/core/testing'
;
import
{
BankCardComponent
}
from
'./bank-card.component'
;
describe
(
'BankCardComponent'
,
()
=>
{
let
component
:
BankCardComponent
;
let
fixture
:
ComponentFixture
<
BankCardComponent
>
;
beforeEach
(
async
(()
=>
{
TestBed
.
configureTestingModule
({
declarations
:
[
BankCardComponent
]
})
.
compileComponents
();
}));
beforeEach
(()
=>
{
fixture
=
TestBed
.
createComponent
(
BankCardComponent
);
component
=
fixture
.
componentInstance
;
fixture
.
detectChanges
();
});
it
(
'should create'
,
()
=>
{
expect
(
component
).
toBeTruthy
();
});
});
src/app/my/application-process/bank-card/bank-card.component.ts
0 → 100644
View file @
5f0c6d70
import
{
Component
,
OnInit
}
from
'@angular/core'
;
import
{
MyService
}
from
'../../my.service'
;
import
{
ActivatedRoute
,
Router
}
from
"@angular/router"
;
import
{
LifeCommonService
}
from
"../../../common/life-common.service"
;
@
Component
({
selector
:
'ydlife-bank-card'
,
templateUrl
:
'./bank-card.component.html'
,
styleUrls
:
[
'./bank-card.component.scss'
]
})
export
class
BankCardComponent
implements
OnInit
{
hiringBasicInfoId
:
any
;
bankAccountOpening
:
string
;
bankAccountId
:
string
;
toastDialog
:
boolean
;
toastInfo
:
any
;
sureBankAccountId
:
string
;
constructor
(
private
activatedRoute
:
ActivatedRoute
,
private
router
:
Router
,
public
lifeCommonService
:
LifeCommonService
,
public
myService
:
MyService
)
{
}
ngOnInit
()
{
const
title
=
this
.
activatedRoute
.
snapshot
.
data
[
0
][
'title'
];
this
.
lifeCommonService
.
setTitle
(
title
);
this
.
hiringBasicInfoId
=
this
.
activatedRoute
.
snapshot
.
queryParams
.
hiringBasicInfoId
?
this
.
activatedRoute
.
snapshot
.
queryParams
.
hiringBasicInfoId
:
null
;
}
next
(){
const
param
=
{
hiringBasicInfoId
:
this
.
hiringBasicInfoId
,
bankAccountOpening
:
this
.
bankAccountOpening
,
bankAccountId
:
this
.
bankAccountId
}
this
.
myService
.
saveBankAccount
(
param
).
subscribe
((
res
)
=>
{
if
(
res
[
'success'
]){
this
.
router
.
navigate
([
'/personal_statement'
],{
queryParams
:
{
hiringBasicInfoId
:
this
.
hiringBasicInfoId
}
});
}
else
{
this
.
toastDialog
=
true
;
this
.
toastInfo
=
{
status
:
1
,
msg
:
res
[
'message'
],
timeout
:
3000
,
align
:
'center'
};
}
})
}
}
src/app/my/application-process/employee-basic-info/employee-basic-info.component.ts
View file @
5f0c6d70
...
...
@@ -181,7 +181,6 @@ export class EmployeeBasicInfoComponent implements OnInit {
})
}
// 打开弹窗
openPopInfo
(
message
)
{
this
.
isNeedAlert
=
true
;
...
...
src/app/my/application-process/employee-education/employee-education.component.html
View file @
5f0c6d70
<div
class=
"wrapper"
>
<div
class=
"title"
>
<div>
学历信息
</div>
<span
class=
"page_mark"
>
5
/8
</span>
<span
class=
"page_mark"
>
4
/8
</span>
</div>
<div
class=
"content"
>
<div
class=
"contentDetail employ"
>
...
...
@@ -36,4 +36,5 @@
保存并下一步
</footer>
</div>
<ydlife-toast
*
ngIf=
"toastDialog"
[
toastInfo
]="
toastInfo
"
></ydlife-toast>
\ No newline at end of file
<ydlife-toast
*
ngIf=
"toastDialog"
[
toastInfo
]="
toastInfo
"
></ydlife-toast>
<ydlife-alert
*
ngIf=
"isNeedAlert"
[
dialogInfo
]="
dialogInfo
"
(
popInfo
)="
getPopInfo
()"
></ydlife-alert>
\ No newline at end of file
src/app/my/application-process/employee-education/employee-education.component.ts
View file @
5f0c6d70
...
...
@@ -18,6 +18,8 @@ export class EmployeeEducationComponent implements OnInit {
serverId
:
any
;
toastDialog
:
boolean
;
toastInfo
:
any
;
isNeedAlert
:
boolean
;
dialogInfo
:
any
;
constructor
(
private
activatedRoute
:
ActivatedRoute
,
private
router
:
Router
,
public
lifeCommonService
:
LifeCommonService
,
public
myService
:
MyService
,
private
changeDetectorRef
:
ChangeDetectorRef
)
{
...
...
@@ -32,25 +34,39 @@ export class EmployeeEducationComponent implements OnInit {
}
next
(){
const
param
=
{
hiringBasicInfoId
:
this
.
hiringBasicInfoId
,
lastGraduateGrade
:
this
.
lastGraduateGrade
,
lastGraduateSchool
:
this
.
lastGraduateSchool
,
certificationVxUrl
:
this
.
certificationVxUrl
if
(
!
this
.
lastGraduateGrade
){
this
.
openPopInfo
(
'最高学历不能为空!'
)
return
;
}
this
.
myService
.
saveLastGraduateGrade
(
param
).
subscribe
((
res
)
=>
{
if
(
res
[
'success'
]){
this
.
router
.
navigate
([
'/personal_statement'
],{
queryParams
:
{
hiringBasicInfoId
:
this
.
hiringBasicInfoId
}
});
}
else
{
this
.
toastDialog
=
true
;
this
.
toastInfo
=
{
status
:
1
,
msg
:
res
[
'message'
],
timeout
:
3000
,
align
:
'center'
};
if
(
!
this
.
lastGraduateSchool
){
this
.
openPopInfo
(
'毕业学校不能为空!'
)
return
;
}
if
(
!
this
.
certificationVxUrl
){
this
.
openPopInfo
(
'毕业证照片不能为空,请在微信端上传!'
)
return
;
}
if
(
this
.
lifeCommonService
.
isWeiXin
()){
const
param
=
{
hiringBasicInfoId
:
this
.
hiringBasicInfoId
,
lastGraduateGrade
:
this
.
lastGraduateGrade
,
lastGraduateSchool
:
this
.
lastGraduateSchool
,
certificationVxUrl
:
this
.
certificationVxUrl
}
})
this
.
myService
.
saveLastGraduateGrade
(
param
).
subscribe
((
res
)
=>
{
if
(
res
[
'success'
]){
this
.
router
.
navigate
([
'/bank_card'
],{
queryParams
:
{
hiringBasicInfoId
:
this
.
hiringBasicInfoId
}
});
}
else
{
this
.
toastDialog
=
true
;
this
.
toastInfo
=
{
status
:
1
,
msg
:
res
[
'message'
],
timeout
:
3000
,
align
:
'center'
};
}
})
}
}
// 教育等级查询
...
...
@@ -73,37 +89,56 @@ export class EmployeeEducationComponent implements OnInit {
}
selectPic
(){
// 5.1 拍照、本地选图
const
t
=
this
;
wx
.
chooseImage
({
count
:
1
,
// 默认9
sizeType
:
[
'original'
,
'compressed'
],
// 可以指定是原图还是压缩图,默认二者都有
sourceType
:
[
'album'
,
'camera'
],
// 可以指定来源是相册还是相机,默认二者都有
success
:
function
(
res
)
{
this
.
localId
=
res
.
localIds
[
0
];
// 返回选定照片的本地ID列表,localId可以作为img标签的src属性显示图片
const
THIS
=
t
;
wx
.
uploadImage
({
localId
:
this
.
localId
,
// 需要上传的图片的本地ID,由chooseImage接口获得
isShowProgressTips
:
1
,
// 默认为1,显示进度提示
success
:
function
(
response
)
{
THIS
.
serverId
=
response
.
serverId
;
// 返回图片的服务器端ID
const
m
=
{
mediaId
:
response
.
serverId
,
origin
:
'ydLife'
};
THIS
.
myService
.
mediaGet
(
m
).
subscribe
(
async
e
=>
{
if
(
e
[
'success'
])
{
THIS
.
certificationVxUrl
=
e
[
'data'
][
'imgUrl'
];
THIS
.
changeDetectorRef
.
markForCheck
();
THIS
.
changeDetectorRef
.
detectChanges
();
}
else
{
alert
(
e
[
'message'
]);
if
(
this
.
lifeCommonService
.
isWeiXin
()){
// 5.1 拍照、本地选图
const
t
=
this
;
wx
.
chooseImage
({
count
:
1
,
// 默认9
sizeType
:
[
'original'
,
'compressed'
],
// 可以指定是原图还是压缩图,默认二者都有
sourceType
:
[
'album'
,
'camera'
],
// 可以指定来源是相册还是相机,默认二者都有
success
:
function
(
res
)
{
this
.
localId
=
res
.
localIds
[
0
];
// 返回选定照片的本地ID列表,localId可以作为img标签的src属性显示图片
const
THIS
=
t
;
wx
.
uploadImage
({
localId
:
this
.
localId
,
// 需要上传的图片的本地ID,由chooseImage接口获得
isShowProgressTips
:
1
,
// 默认为1,显示进度提示
success
:
function
(
response
)
{
THIS
.
serverId
=
response
.
serverId
;
// 返回图片的服务器端ID
const
m
=
{
mediaId
:
response
.
serverId
,
origin
:
'ydLife'
};
THIS
.
myService
.
mediaGet
(
m
).
subscribe
(
async
e
=>
{
if
(
e
[
'success'
])
{
THIS
.
certificationVxUrl
=
e
[
'data'
][
'imgUrl'
];
THIS
.
changeDetectorRef
.
markForCheck
();
THIS
.
changeDetectorRef
.
detectChanges
();
}
else
{
alert
(
e
[
'message'
]);
}
});
}
});
}
});
}
});
}
else
{
this
.
openPopInfo
(
'请在微信端操作!'
)
}
}
// 打开弹窗
openPopInfo
(
message
)
{
this
.
isNeedAlert
=
true
;
this
.
dialogInfo
=
{
title
:
null
,
content
:
{
value
:
message
,
align
:
'center'
},
footer
:
[{
value
:
'我知道了'
,
routerLink
:
''
,
className
:
'weui-dialog__btn_primary'
}],
};
}
// 关闭弹窗
getPopInfo
()
{
this
.
isNeedAlert
=
false
;
}
}
src/app/my/application-process/employee-id-card/employee-id-card.component.html
View file @
5f0c6d70
<div
class=
"wrapper"
>
<div
class=
"title"
>
<div>
个人证件资料
</div>
<span
class=
"page_mark"
>
4
/8
</span>
<span
class=
"page_mark"
>
3
/8
</span>
</div>
<div
class=
"sub_title"
>
<strong>
身份证件
</strong>
...
...
@@ -45,4 +45,5 @@
保存并下一步
</footer>
</div>
<ydlife-toast
*
ngIf=
"toastDialog"
[
toastInfo
]="
toastInfo
"
></ydlife-toast>
\ No newline at end of file
<ydlife-toast
*
ngIf=
"toastDialog"
[
toastInfo
]="
toastInfo
"
></ydlife-toast>
<ydlife-alert
*
ngIf=
"isNeedAlert"
[
dialogInfo
]="
dialogInfo
"
(
popInfo
)="
getPopInfo
()"
></ydlife-alert>
src/app/my/application-process/employee-id-card/employee-id-card.component.ts
View file @
5f0c6d70
...
...
@@ -19,6 +19,8 @@ export class EmployeeIdCardComponent implements OnInit {
serverId
:
any
;
toastDialog
:
boolean
;
toastInfo
:
any
;
isNeedAlert
:
boolean
;
dialogInfo
:
any
;
constructor
(
private
activatedRoute
:
ActivatedRoute
,
private
router
:
Router
,
public
lifeCommonService
:
LifeCommonService
,
public
myService
:
MyService
,
private
changeDetectorRef
:
ChangeDetectorRef
)
{
...
...
@@ -37,62 +39,93 @@ export class EmployeeIdCardComponent implements OnInit {
}
next
(){
const
param
=
{
hiringBasicInfoId
:
this
.
hiringBasicInfoId
,
frontVxUrl
:
this
.
frontVxUrl
,
backVxUrl
:
this
.
backVxUrl
if
(
!
this
.
frontVxUrl
){
this
.
openPopInfo
(
'身份证正面照不能为空,请在微信端上传!'
)
return
;
}
this
.
myService
.
saveBasicInfo
(
param
).
subscribe
((
res
)
=>
{
if
(
res
[
'success'
]){
this
.
router
.
navigate
([
'/employee_education'
],{
queryParams
:
{
hiringBasicInfoId
:
this
.
hiringBasicInfoId
}
});
}
else
{
this
.
toastDialog
=
true
;
this
.
toastInfo
=
{
status
:
1
,
msg
:
res
[
'message'
],
timeout
:
3000
,
align
:
'center'
};
if
(
!
this
.
backVxUrl
){
this
.
openPopInfo
(
'身份证反面照不能为空,请在微信端上传!'
)
return
;
}
if
(
this
.
lifeCommonService
.
isWeiXin
()){
const
param
=
{
hiringBasicInfoId
:
this
.
hiringBasicInfoId
,
frontVxUrl
:
this
.
frontVxUrl
,
backVxUrl
:
this
.
backVxUrl
}
})
this
.
myService
.
saveBasicInfo
(
param
).
subscribe
((
res
)
=>
{
if
(
res
[
'success'
]){
this
.
router
.
navigate
([
'/employee_education'
],{
queryParams
:
{
hiringBasicInfoId
:
this
.
hiringBasicInfoId
}
});
}
else
{
this
.
toastDialog
=
true
;
this
.
toastInfo
=
{
status
:
1
,
msg
:
res
[
'message'
],
timeout
:
3000
,
align
:
'center'
};
}
})
}
else
{
this
.
openPopInfo
(
'请在微信端操作!'
)
}
}
selectPic
(
type
){
// 5.1 拍照、本地选图
const
t
=
this
;
wx
.
chooseImage
({
count
:
1
,
// 默认9
sizeType
:
[
'original'
,
'compressed'
],
// 可以指定是原图还是压缩图,默认二者都有
sourceType
:
[
'album'
,
'camera'
],
// 可以指定来源是相册还是相机,默认二者都有
success
:
function
(
res
)
{
this
.
localId
=
res
.
localIds
[
0
];
// 返回选定照片的本地ID列表,localId可以作为img标签的src属性显示图片
const
THIS
=
t
;
wx
.
uploadImage
({
localId
:
this
.
localId
,
// 需要上传的图片的本地ID,由chooseImage接口获得
isShowProgressTips
:
1
,
// 默认为1,显示进度提示
success
:
function
(
response
)
{
THIS
.
serverId
=
response
.
serverId
;
// 返回图片的服务器端ID
const
m
=
{
mediaId
:
response
.
serverId
,
origin
:
'ydLife'
};
THIS
.
myService
.
mediaGet
(
m
).
subscribe
(
async
e
=>
{
if
(
e
[
'success'
])
{
if
(
type
==
'front'
){
THIS
.
frontVxUrl
=
e
[
'data'
][
'imgUrl'
];
if
(
this
.
lifeCommonService
.
isWeiXin
()){
// 5.1 拍照、本地选图
const
t
=
this
;
wx
.
chooseImage
({
count
:
1
,
// 默认9
sizeType
:
[
'original'
,
'compressed'
],
// 可以指定是原图还是压缩图,默认二者都有
sourceType
:
[
'album'
,
'camera'
],
// 可以指定来源是相册还是相机,默认二者都有
success
:
function
(
res
)
{
this
.
localId
=
res
.
localIds
[
0
];
// 返回选定照片的本地ID列表,localId可以作为img标签的src属性显示图片
const
THIS
=
t
;
wx
.
uploadImage
({
localId
:
this
.
localId
,
// 需要上传的图片的本地ID,由chooseImage接口获得
isShowProgressTips
:
1
,
// 默认为1,显示进度提示
success
:
function
(
response
)
{
THIS
.
serverId
=
response
.
serverId
;
// 返回图片的服务器端ID
const
m
=
{
mediaId
:
response
.
serverId
,
origin
:
'ydLife'
};
THIS
.
myService
.
mediaGet
(
m
).
subscribe
(
async
e
=>
{
if
(
e
[
'success'
])
{
if
(
type
==
'front'
){
THIS
.
frontVxUrl
=
e
[
'data'
][
'imgUrl'
];
}
if
(
type
==
'back'
){
THIS
.
backVxUrl
=
e
[
'data'
][
'imgUrl'
];
}
THIS
.
changeDetectorRef
.
markForCheck
();
THIS
.
changeDetectorRef
.
detectChanges
();
}
else
{
alert
(
e
[
'message'
]);
}
if
(
type
==
'back'
){
THIS
.
backVxUrl
=
e
[
'data'
][
'imgUrl'
];
}
THIS
.
changeDetectorRef
.
markForCheck
();
THIS
.
changeDetectorRef
.
detectChanges
();
}
else
{
alert
(
e
[
'message'
]);
}
});
}
});
}
});
});
}
});
}
});
}
else
{
this
.
openPopInfo
(
'请在微信端操作!'
)
}
}
// 打开弹窗
openPopInfo
(
message
)
{
this
.
isNeedAlert
=
true
;
this
.
dialogInfo
=
{
title
:
null
,
content
:
{
value
:
message
,
align
:
'center'
},
footer
:
[{
value
:
'我知道了'
,
routerLink
:
''
,
className
:
'weui-dialog__btn_primary'
}],
};
}
// 关闭弹窗
getPopInfo
()
{
this
.
isNeedAlert
=
false
;
}
}
src/app/my/application-process/invitation/invitation.component.ts
View file @
5f0c6d70
...
...
@@ -45,7 +45,7 @@ export class InvitationComponent implements OnInit {
`https://
${
window
.
location
.
host
}
/ydLife/invitees?hiringBasicInfoId=
${
this
.
hiringBasicInfoId
}
&invitatorName=
${
this
.
invitatorName
}
`
,
imgUrl
);
}
else
{
alert
(
'请在
手机微信端
发送邀请'
);
alert
(
'请在
微信公众号中
发送邀请'
);
}
}
...
...
src/app/my/application-process/personal-photos/personal-photos.component.html
View file @
5f0c6d70
...
...
@@ -18,4 +18,5 @@
保存并下一步
</footer>
</div>
<ydlife-toast
*
ngIf=
"toastDialog"
[
toastInfo
]="
toastInfo
"
></ydlife-toast>
\ No newline at end of file
<ydlife-toast
*
ngIf=
"toastDialog"
[
toastInfo
]="
toastInfo
"
></ydlife-toast>
<ydlife-alert
*
ngIf=
"isNeedAlert"
[
dialogInfo
]="
dialogInfo
"
(
popInfo
)="
getPopInfo
()"
></ydlife-alert>
src/app/my/application-process/personal-photos/personal-photos.component.ts
View file @
5f0c6d70
...
...
@@ -14,6 +14,8 @@ export class PersonalPhotosComponent implements OnInit {
vxUrl
:
any
=
null
;
toastDialog
:
boolean
;
toastInfo
:
any
;
isNeedAlert
:
boolean
;
dialogInfo
:
any
;
constructor
(
private
activatedRoute
:
ActivatedRoute
,
private
router
:
Router
,
public
lifeCommonService
:
LifeCommonService
,
public
myService
:
MyService
,
private
changeDetectorRef
:
ChangeDetectorRef
)
{
}
...
...
@@ -26,56 +28,81 @@ export class PersonalPhotosComponent implements OnInit {
}
selectPic
(){
// 5.1 拍照、本地选图
const
t
=
this
;
wx
.
chooseImage
({
count
:
1
,
// 默认9
sizeType
:
[
'original'
,
'compressed'
],
// 可以指定是原图还是压缩图,默认二者都有
sourceType
:
[
'album'
,
'camera'
],
// 可以指定来源是相册还是相机,默认二者都有
success
:
function
(
res
)
{
this
.
localId
=
res
.
localIds
[
0
];
// 返回选定照片的本地ID列表,localId可以作为img标签的src属性显示图片
const
THIS
=
t
;
wx
.
uploadImage
({
localId
:
this
.
localId
,
// 需要上传的图片的本地ID,由chooseImage接口获得
isShowProgressTips
:
1
,
// 默认为1,显示进度提示
success
:
function
(
response
)
{
THIS
.
serverId
=
response
.
serverId
;
// 返回图片的服务器端ID
const
m
=
{
mediaId
:
response
.
serverId
,
origin
:
'ydLife'
};
THIS
.
myService
.
mediaGet
(
m
).
subscribe
(
async
e
=>
{
if
(
e
[
'success'
])
{
THIS
.
vxUrl
=
e
[
'data'
][
'imgUrl'
];
THIS
.
changeDetectorRef
.
markForCheck
();
THIS
.
changeDetectorRef
.
detectChanges
();
}
else
{
alert
(
e
[
'message'
]);
}
});
}
});
}
});
if
(
this
.
lifeCommonService
.
isWeiXin
()){
// 5.1 拍照、本地选图
const
t
=
this
;
wx
.
chooseImage
({
count
:
1
,
// 默认9
sizeType
:
[
'original'
,
'compressed'
],
// 可以指定是原图还是压缩图,默认二者都有
sourceType
:
[
'album'
,
'camera'
],
// 可以指定来源是相册还是相机,默认二者都有
success
:
function
(
res
)
{
this
.
localId
=
res
.
localIds
[
0
];
// 返回选定照片的本地ID列表,localId可以作为img标签的src属性显示图片
const
THIS
=
t
;
wx
.
uploadImage
({
localId
:
this
.
localId
,
// 需要上传的图片的本地ID,由chooseImage接口获得
isShowProgressTips
:
1
,
// 默认为1,显示进度提示
success
:
function
(
response
)
{
THIS
.
serverId
=
response
.
serverId
;
// 返回图片的服务器端ID
const
m
=
{
mediaId
:
response
.
serverId
,
origin
:
'ydLife'
};
THIS
.
myService
.
mediaGet
(
m
).
subscribe
(
async
e
=>
{
if
(
e
[
'success'
])
{
THIS
.
vxUrl
=
e
[
'data'
][
'imgUrl'
];
THIS
.
changeDetectorRef
.
markForCheck
();
THIS
.
changeDetectorRef
.
detectChanges
();
}
else
{
alert
(
e
[
'message'
]);
}
});
}
});
}
});
}
else
{
this
.
openPopInfo
(
'请在微信端操作!'
)
}
}
next
(){
const
param
=
{
hiringBasicInfoId
:
this
.
hiringBasicInfoId
,
vxUrl
:
this
.
vxUrl
if
(
!
this
.
vxUrl
)
{
this
.
openPopInfo
(
'您的个人照片不能为空,请在微信端上传!'
)
return
;
}
this
.
myService
.
savePersonPicture
(
param
).
subscribe
((
res
)
=>
{
if
(
res
[
'success'
]){
this
.
router
.
navigate
([
'/employee_id_card'
],{
queryParams
:
{
hiringBasicInfoId
:
this
.
hiringBasicInfoId
}
});
}
else
{
this
.
toastDialog
=
true
;
this
.
toastInfo
=
{
status
:
1
,
msg
:
res
[
'message'
],
timeout
:
3000
,
align
:
'center'
};
if
(
this
.
lifeCommonService
.
isWeiXin
()){
const
param
=
{
hiringBasicInfoId
:
this
.
hiringBasicInfoId
,
vxUrl
:
this
.
vxUrl
}
})
this
.
myService
.
savePersonPicture
(
param
).
subscribe
((
res
)
=>
{
if
(
res
[
'success'
]){
this
.
router
.
navigate
([
'/employee_id_card'
],{
queryParams
:
{
hiringBasicInfoId
:
this
.
hiringBasicInfoId
}
});
}
else
{
this
.
toastDialog
=
true
;
this
.
toastInfo
=
{
status
:
1
,
msg
:
res
[
'message'
],
timeout
:
3000
,
align
:
'center'
};
}
})
}
}
// 打开弹窗
openPopInfo
(
message
)
{
this
.
isNeedAlert
=
true
;
this
.
dialogInfo
=
{
title
:
null
,
content
:
{
value
:
message
,
align
:
'center'
},
footer
:
[{
value
:
'我知道了'
,
routerLink
:
''
,
className
:
'weui-dialog__btn_primary'
}],
};
}
// 关闭弹窗
getPopInfo
()
{
this
.
isNeedAlert
=
false
;
}
}
src/app/my/application-process/personal-statement/personal-statement.component.html
View file @
5f0c6d70
...
...
@@ -7,12 +7,12 @@
<div
class=
"content"
>
<ul>
<li
*
ngFor=
"let personalStatements of dropOptionsInfoList"
(
click
)="
selectStatements
(
personalStatements
)"
[
ngClass
]="{'
selected
'
:personalStatements
.
s
elected
}"
>
[
ngClass
]="{'
selected
'
:personalStatements
.
s
tatus
}"
>
<span>
{{personalStatements.dropOptionName}}
</span>
<span
class=
"iconfont icon-gougou"
*
ngIf=
"personalStatements.s
elected
"
></span>
<span
class=
"iconfont icon-gougou"
*
ngIf=
"personalStatements.s
tatus
"
></span>
</li>
</ul>
<textarea
class=
"form-control"
cols=
"10"
rows=
"5"
placeholder=
"输入报聘"
#
autofocusFlag
></textarea>
<textarea
class=
"form-control"
cols=
"10"
rows=
"5"
placeholder=
"输入报聘"
#
autofocusFlag
[(
ngModel
)]="
everWork
"
></textarea>
</div>
<footer
class=
"fixed"
(
click
)="
next
()"
>
保存并下一步
...
...
@@ -26,26 +26,10 @@
</div>
<div
class=
"content"
>
<ul>
<li
class=
"selected"
>
<span>
合同条款
</span>
<li
class=
"selected"
*
ngFor=
"let contractItem of contractTermsList"
>
<span>
{{contractItem.termName}}
</span>
<span
class=
"iconfont icon-gougou"
></span>
</li>
<li>
<span>
工作电脑/网络使用规律
</span>
<span
class=
"iconfont icon-ar-r"
></span>
</li>
<li>
<span>
保密协议
</span>
<span
class=
"iconfont icon-ar-r"
></span>
</li>
<li>
<span>
收集和利用个人信息协议书
</span>
<span
class=
"iconfont icon-ar-r"
></span>
</li>
<li>
<span>
员工说明书
</span>
<span
class=
"iconfont icon-ar-r"
></span>
</li>
</ul>
</div>
<footer
class=
"fixed"
(
click
)="
next
()"
>
...
...
src/app/my/application-process/personal-statement/personal-statement.component.ts
View file @
5f0c6d70
...
...
@@ -17,7 +17,9 @@ export class PersonalStatementComponent implements OnInit {
isNeedAlert
:
boolean
;
dialogInfo
:
any
;
autofocusFlag
:
boolean
;
dropOptionsInfoListParam
:
any
;
dropOptionsInfoListParam
:
Array
<
any
>
=
[];
contractTermsList
:
Array
<
any
>
;
everWork
:
string
;
constructor
(
private
myService
:
MyService
,
private
activatedRoute
:
ActivatedRoute
,
public
lifeCommonService
:
LifeCommonService
,
...
...
@@ -31,13 +33,15 @@ export class PersonalStatementComponent implements OnInit {
console
.
log
(
this
.
type
)
if
(
this
.
type
===
"personal_statement"
){
this
.
dropOptionsQuery
()
}
else
{
this
.
queryContractTerms
()
}
}
next
(){
if
(
this
.
type
==
'personal_statement'
){
this
.
savePersonalStatements
()
// this.router.navigate(['/contract'],{ queryParams: { hiringBasicInfoId:this.hiringBasicInfoId} });
this
.
savePersonalStatements
();
}
else
if
(
this
.
type
==
'contract'
){
this
.
router
.
navigate
([
'/signature'
],{
queryParams
:
{
hiringBasicInfoId
:
this
.
hiringBasicInfoId
}
});
}
...
...
@@ -47,12 +51,17 @@ export class PersonalStatementComponent implements OnInit {
this
.
myService
.
dropOptionsQuery
({
code
:
'EHiring_Personal_Statements'
}).
subscribe
((
res
)
=>
{
if
(
res
[
'success'
]){
this
.
dropOptionsInfoList
=
res
[
'data'
][
'dropMasterInfoList'
][
0
][
'dropOptionsInfoList'
];
this
.
dropOptionsInfoList
.
forEach
((
item
)
=>
{
item
.
status
=
0
;
item
.
userInput
=
null
;
})
}
else
{
this
.
openPopInfo
(
res
[
'message'
])
}
})
}
// 打开弹窗
openPopInfo
(
message
)
{
this
.
isNeedAlert
=
true
;
...
...
@@ -64,33 +73,52 @@ export class PersonalStatementComponent implements OnInit {
}
selectStatements
(
personalStatements
){
personalStatements
.
selected
=
!
personalStatements
.
selected
;
if
(
personalStatements
.
id
==
'241'
&&
personalStatements
.
selected
==
true
){
if
(
personalStatements
.
status
==
1
){
personalStatements
.
status
=
0
;
}
else
{
personalStatements
.
status
=
1
;
}
if
(
personalStatements
.
id
==
'241'
&&
personalStatements
.
status
==
1
){
//点击曾经报聘输入报聘自动获取焦点
this
.
elementView
.
nativeElement
.
focus
();
}
}
savePersonalStatements
(){
this
.
dropOptionsInfoListParam
=
[];
for
(
let
i
=
0
;
i
<
this
.
dropOptionsInfoList
.
length
;
i
++
){
this
.
dropOptionsInfoList
[
i
][
'personalStatements'
]
=
this
.
dropOptionsInfoList
[
i
][
'dropOptionName'
];
this
.
dropOptionsInfoList
[
i
][
'personalStatementsId'
]
=
this
.
dropOptionsInfoList
[
i
][
'id'
];
if
(
this
.
dropOptionsInfoList
[
i
][
'selected'
]
==
true
){
this
.
dropOptionsInfoList
[
i
][
'status'
]
=
1
;
this
.
dropOptionsInfoList
[
i
][
'mdDropOptionName'
]
=
this
.
dropOptionsInfoList
[
i
][
'dropOptionName'
];
this
.
dropOptionsInfoList
[
i
][
'mdDropOptionId'
]
=
this
.
dropOptionsInfoList
[
i
][
'id'
];
if
(
this
.
dropOptionsInfoList
[
i
][
'id'
]
==
'241'
){
this
.
dropOptionsInfoListParam
.
push
({
hiringBasicInfoId
:
this
.
hiringBasicInfoId
,
mdDropOptionName
:
this
.
dropOptionsInfoList
[
i
][
'dropOptionName'
],
mdDropOptionId
:
this
.
dropOptionsInfoList
[
i
][
'id'
],
status
:
this
.
dropOptionsInfoList
[
i
][
'status'
],
userInput
:
this
.
everWork
?
this
.
everWork
:
null
})
}
else
{
this
.
dropOptionsInfoList
[
i
][
'status'
]
=
0
;
this
.
dropOptionsInfoListParam
.
push
({
hiringBasicInfoId
:
this
.
hiringBasicInfoId
,
mdDropOptionName
:
this
.
dropOptionsInfoList
[
i
][
'dropOptionName'
],
mdDropOptionId
:
this
.
dropOptionsInfoList
[
i
][
'id'
],
status
:
this
.
dropOptionsInfoList
[
i
][
'status'
],
userInput
:
null
})
}
// this.dropOptionsInfoListParam = this.dropOptionsInfoListParam.push(
// {hiringBasicInfoId:this.hiringBasicInfoId,
// personalStatements:this.dropOptionsInfoList[i]['dropOptionName'],
// personalStatementsId:this.dropOptionsInfoList[i]['id'],
// status:this.dropOptionsInfoList[i]['status']
// }
// )
}
console
.
log
(
this
.
dropOptionsInfoListParam
)
}
queryContractTerms
(){
this
.
myService
.
queryContractTerms
().
subscribe
((
res
)
=>
{
console
.
log
(
res
)
if
(
res
[
'success'
]){
this
.
contractTermsList
=
res
[
'data'
][
'contractTermsList'
];
}
})
}
// 关闭弹窗
getPopInfo
()
{
this
.
isNeedAlert
=
false
;
}
}
src/app/my/application-process/work-experience/work-experience.component.html
View file @
5f0c6d70
...
...
@@ -75,3 +75,5 @@
</footer>
</div>
<ydlife-toast
*
ngIf=
"toastDialog"
[
toastInfo
]="
toastInfo
"
></ydlife-toast>
<ydlife-alert
*
ngIf=
"isNeedAlert"
[
dialogInfo
]="
dialogInfo
"
(
popInfo
)="
getPopInfo
()"
></ydlife-alert>
src/app/my/application-process/work-experience/work-experience.component.ts
View file @
5f0c6d70
...
...
@@ -11,7 +11,7 @@ import { ExperienceQuery } from '../../../domain/experienceQuery';
})
export
class
WorkExperienceComponent
implements
OnInit
{
hiringBasicInfoId
:
any
;
addExperience
:
ExperienceQuery
=
new
ExperienceQuery
(
null
,
null
,
null
,
null
,
null
);
addExperience
:
ExperienceQuery
=
new
ExperienceQuery
(
null
,
null
,
null
,
null
);
//工作经历列表
experienceList
:
Array
<
any
>
;
minDate
:
any
=
new
Date
(
'1900-01-01'
);
...
...
@@ -21,6 +21,8 @@ export class WorkExperienceComponent implements OnInit {
//控制弹框
toastDialog
:
boolean
;
toastInfo
:
any
;
isNeedAlert
:
boolean
;
dialogInfo
:
any
;
constructor
(
private
activatedRoute
:
ActivatedRoute
,
private
router
:
Router
,
public
lifeCommonService
:
LifeCommonService
,
public
myService
:
MyService
)
{
...
...
@@ -31,13 +33,14 @@ export class WorkExperienceComponent implements OnInit {
const
title
=
this
.
activatedRoute
.
snapshot
.
data
[
0
][
'title'
];
this
.
lifeCommonService
.
setTitle
(
title
);
this
.
hiringBasicInfoId
=
this
.
activatedRoute
.
snapshot
.
queryParams
.
hiringBasicInfoId
?
this
.
activatedRoute
.
snapshot
.
queryParams
.
hiringBasicInfoId
:
null
;
this
.
addExperience
=
new
ExperienceQuery
(
this
.
hiringBasicInfoId
,
null
,
null
,
null
,
null
);
this
.
addExperience
=
new
ExperienceQuery
(
null
,
null
,
null
,
null
);
}
next
(){
const
experienceParam
=
{
workingExperienceList
:
this
.
experienceList
workingExperienceList
:
this
.
experienceList
,
hiringBasicInfoId
:
this
.
hiringBasicInfoId
}
this
.
myService
.
saveWorkingExperience
(
experienceParam
).
subscribe
((
res
)
=>
{
if
(
res
[
'success'
]){
...
...
@@ -60,7 +63,7 @@ export class WorkExperienceComponent implements OnInit {
this
.
experienceList
.
push
(
this
.
addExperience
)
this
.
showworkingStart
=
null
;
this
.
showworkingEnd
=
null
;
this
.
addExperience
=
new
ExperienceQuery
(
this
.
hiringBasicInfoId
,
null
,
null
,
null
,
null
);
this
.
addExperience
=
new
ExperienceQuery
(
null
,
null
,
null
,
null
);
}
}
...
...
@@ -88,4 +91,19 @@ export class WorkExperienceComponent implements OnInit {
this
.
showworkingEnd
=
result
;
}
}
// 打开弹窗
openPopInfo
(
message
)
{
this
.
isNeedAlert
=
true
;
this
.
dialogInfo
=
{
title
:
null
,
content
:
{
value
:
message
,
align
:
'center'
},
footer
:
[{
value
:
'我知道了'
,
routerLink
:
''
,
className
:
'weui-dialog__btn_primary'
}],
};
}
// 关闭弹窗
getPopInfo
()
{
this
.
isNeedAlert
=
false
;
}
}
src/app/my/my-routing.module.ts
View file @
5f0c6d70
...
...
@@ -39,6 +39,8 @@ import { EmployeeEducationComponent } from './application-process/employee-educa
import
{
PersonalStatementComponent
}
from
'./application-process/personal-statement/personal-statement.component'
;
import
{
SignatureComponent
}
from
'./application-process/signature/signature.component'
;
import
{
EmployeeSubmitComponent
}
from
'./application-process/employee-submit/employee-submit.component'
;
import
{
BankCardComponent
}
from
'./application-process/bank-card/bank-card.component'
;
const
myRoutes
:
Routes
=
[
{
path
:
''
,
component
:
MyCenterHomeComponent
,
canActivate
:
[
AuthGuard
],
data
:
[{
title
:
'银盾保险经纪 - 工作台'
}]
},
...
...
@@ -81,6 +83,7 @@ const myRoutes: Routes = [
{
path
:
'personal_photos'
,
component
:
PersonalPhotosComponent
,
data
:
[{
title
:
'银盾经纪人报聘'
}]
},
{
path
:
'employee_id_card'
,
component
:
EmployeeIdCardComponent
,
data
:
[{
title
:
'银盾经纪人报聘'
}]
},
{
path
:
'employee_education'
,
component
:
EmployeeEducationComponent
,
data
:
[{
title
:
'银盾经纪人报聘'
}]
},
{
path
:
'bank_card'
,
component
:
BankCardComponent
,
data
:[{
title
:
'银盾经纪人报聘'
}]},
{
path
:
'personal_statement'
,
component
:
PersonalStatementComponent
,
data
:
[{
type
:
'personal_statement'
,
title
:
'银盾经纪人报聘'
}]
},
{
path
:
'contract'
,
component
:
PersonalStatementComponent
,
data
:
[{
type
:
'contract'
,
title
:
'银盾经纪人报聘'
}]
},
{
path
:
'signature'
,
component
:
SignatureComponent
,
data
:
[{
title
:
'银盾经纪人报聘'
}]},
...
...
src/app/my/my.module.ts
View file @
5f0c6d70
...
...
@@ -47,9 +47,10 @@ import { EmployeeIdCardComponent } from './application-process/employee-id-card/
import
{
EmployeeEducationComponent
}
from
'./application-process/employee-education/employee-education.component'
;
import
{
PersonalStatementComponent
}
from
'./application-process/personal-statement/personal-statement.component'
;
import
{
SignatureComponent
}
from
'./application-process/signature/signature.component'
;
import
{
EmployeeSubmitComponent
}
from
'./application-process/employee-submit/employee-submit.component'
import
{
EmployeeSubmitComponent
}
from
'./application-process/employee-submit/employee-submit.component'
;
import
{
BankCardComponent
}
from
'./application-process/bank-card/bank-card.component'
@
NgModule
({
declarations
:
[
MyCenterHomeComponent
,
MkMaterialComponent
,
MkMaterialDetailComponent
,
FileUploadComponent
,
ImportantAnnouncementComponent
,
SalesDetailComponent
,
AnnouncementDetailComponent
,
MyBusinessComponent
,
MyBusinessDetailComponent
,
PickerComponent
,
MyToastComponent
,
SalesRankComponent
,
TeamRankComponent
,
RecruitingComponent
,
RecruitingDetailComponent
,
ThanksComponent
,
MySettingComponent
,
MySettingDetailComponent
,
MyNewsComponent
,
MyTargetComponent
,
TeamPanelComponent
,
SwitchNumberPipe
,
TeamSalesScoreComponent
,
ScoreDetailsComponent
,
BusinessCardComponent
,
OrderDetailComponent
,
SalaryComponent
,
TodoListComponent
,
AddTaskComponent
,
MedicalServiceComponent
,
InvitationComponent
,
RegisterComponent
,
EmployeeInfoComponent
,
EmployeeBasicInfoComponent
,
WorkExperienceComponent
,
PersonalPhotosComponent
,
EmployeeIdCardComponent
,
EmployeeEducationComponent
,
PersonalStatementComponent
,
SignatureComponent
,
EmployeeSubmitComponent
],
declarations
:
[
MyCenterHomeComponent
,
MkMaterialComponent
,
MkMaterialDetailComponent
,
FileUploadComponent
,
ImportantAnnouncementComponent
,
SalesDetailComponent
,
AnnouncementDetailComponent
,
MyBusinessComponent
,
MyBusinessDetailComponent
,
PickerComponent
,
MyToastComponent
,
SalesRankComponent
,
TeamRankComponent
,
RecruitingComponent
,
RecruitingDetailComponent
,
ThanksComponent
,
MySettingComponent
,
MySettingDetailComponent
,
MyNewsComponent
,
MyTargetComponent
,
TeamPanelComponent
,
SwitchNumberPipe
,
TeamSalesScoreComponent
,
ScoreDetailsComponent
,
BusinessCardComponent
,
OrderDetailComponent
,
SalaryComponent
,
TodoListComponent
,
AddTaskComponent
,
MedicalServiceComponent
,
InvitationComponent
,
RegisterComponent
,
EmployeeInfoComponent
,
EmployeeBasicInfoComponent
,
WorkExperienceComponent
,
PersonalPhotosComponent
,
EmployeeIdCardComponent
,
EmployeeEducationComponent
,
PersonalStatementComponent
,
SignatureComponent
,
EmployeeSubmitComponent
,
BankCardComponent
],
imports
:
[
CommonModule
,
LifeCommonModule
,
...
...
src/app/my/my.service.ts
View file @
5f0c6d70
...
...
@@ -475,4 +475,11 @@ export class MyService {
return
this
.
http
.
post
(
url
,
JSON
.
stringify
(
param
));
}
//合同文档查询接口
queryContractTerms
(){
const
url
=
this
.
ydapi
+
'/practitionerHiring/queryContractTerms'
;
return
this
.
http
.
post
(
url
,
JSON
.
stringify
({}));
}
}
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