Commit 561663c5 by lishengfu

Merge branch 'master' of gitlab.corp.qinqinxiaobao.com:frontend_vue/qqxb-self-service

parents 84c87798 529884ed
...@@ -7,30 +7,30 @@ ...@@ -7,30 +7,30 @@
<div class="box"> <div class="box">
<div class="item"> <div class="item">
<span>是否有传染病、精神病及任何慢性疾病史?</span> <span>是否有传染病、精神病及任何慢性疾病史?</span>
<van-radio-group v-model="radio" direction="horizontal" class="item-radio"> <van-radio-group v-model="radio1" direction="horizontal" class="item-radio">
<van-radio name="1" checked-color="#07c160"></van-radio> <van-radio name="1" checked-color="#07c160"></van-radio>
<van-radio name="2" checked-color="#07c160"></van-radio> <van-radio name="2" checked-color="#07c160"></van-radio>
</van-radio-group> </van-radio-group>
</div> </div>
<div class="item"> <div class="item">
<span>是否与其他公司签订过“竞业禁止协议”?</span> <span>是否与其他公司签订过“竞业禁止协议”?</span>
<van-radio-group v-model="radio" direction="horizontal" class="item-radio"> <van-radio-group v-model="radio2" direction="horizontal" class="item-radio">
<van-radio name="1" checked-color="#07c160"></van-radio> <van-radio name="3" checked-color="#07c160"></van-radio>
<van-radio name="2" checked-color="#07c160"></van-radio> <van-radio name="4" checked-color="#07c160"></van-radio>
</van-radio-group> </van-radio-group>
</div> </div>
<div class="item"> <div class="item">
<span>是否曾因个人行为不检而被其他公司解雇?</span> <span>是否曾因个人行为不检而被其他公司解雇?</span>
<van-radio-group v-model="radio" direction="horizontal" class="item-radio"> <van-radio-group v-model="radio3" direction="horizontal" class="item-radio">
<van-radio name="1" checked-color="#07c160"></van-radio> <van-radio name="5" checked-color="#07c160"></van-radio>
<van-radio name="2" checked-color="#07c160"></van-radio> <van-radio name="6" checked-color="#07c160"></van-radio>
</van-radio-group> </van-radio-group>
</div> </div>
<div class="item"> <div class="item">
<span>是否愿意接受我公司及派至公司一切规章制度?</span> <span>是否愿意接受我公司及派至公司一切规章制度?</span>
<van-radio-group v-model="radio" direction="horizontal" class="item-radio"> <van-radio-group v-model="radio4" direction="horizontal" class="item-radio">
<van-radio name="1" checked-color="#07c160"></van-radio> <van-radio name="7" checked-color="#07c160"></van-radio>
<van-radio name="2" checked-color="#07c160"></van-radio> <van-radio name="8" checked-color="#07c160"></van-radio>
</van-radio-group> </van-radio-group>
</div> </div>
</div> </div>
...@@ -48,7 +48,10 @@ import { Component } from "vue-property-decorator"; ...@@ -48,7 +48,10 @@ import { Component } from "vue-property-decorator";
}, },
data() { data() {
return { return {
radio: 1 radio1: 1,
radio2: 2,
radio3: 3,
radio4: 4
}; };
} }
}) })
......
...@@ -41,7 +41,7 @@ ...@@ -41,7 +41,7 @@
<van-field <van-field
readonly readonly
clickable clickable
:value="obj.infoRegisteredResidence" v-model="obj.infoRegisteredResidence"
label="户口性质" label="户口性质"
placeholder="请选择" placeholder="请选择"
@click="showCategory = true" @click="showCategory = true"
...@@ -50,7 +50,7 @@ ...@@ -50,7 +50,7 @@
<van-field <van-field
readonly readonly
clickable clickable
:value="obj.unitPreSocialStatus" v-model="obj.unitPreSocialStatus"
label="前期社保状态" label="前期社保状态"
placeholder="请选择" placeholder="请选择"
@click="showSocialStatus = true" @click="showSocialStatus = true"
...@@ -59,7 +59,7 @@ ...@@ -59,7 +59,7 @@
<van-field <van-field
readonly readonly
clickable clickable
:value="obj.unitPrePaymentType" v-model="obj.unitPrePaymentType"
label="前期缴费种类" label="前期缴费种类"
placeholder="请选择" placeholder="请选择"
@click="showPaymentType = true" @click="showPaymentType = true"
...@@ -68,7 +68,7 @@ ...@@ -68,7 +68,7 @@
<van-field <van-field
readonly readonly
clickable clickable
:value="obj.unitPreSocialCity" v-model="obj.unitPreSocialCity"
label="原社保缴纳省市" label="原社保缴纳省市"
placeholder="请选择" placeholder="请选择"
@click="showSocialCity = true" @click="showSocialCity = true"
...@@ -79,7 +79,7 @@ ...@@ -79,7 +79,7 @@
<van-field <van-field
readonly readonly
clickable clickable
:value="obj.unitRelationUnit" v-model="obj.unitRelationUnit"
label="与原单位关系" label="与原单位关系"
placeholder="请选择" placeholder="请选择"
@click="showRelationUnit = true" @click="showRelationUnit = true"
...@@ -88,14 +88,20 @@ ...@@ -88,14 +88,20 @@
<van-field <van-field
readonly readonly
clickable clickable
:value="obj.unitPreEmploymentStatus" v-model="obj.unitPreEmploymentStatus"
label="前期就业状态" label="前期就业状态"
placeholder="请选择" placeholder="请选择"
@click="showEmploymentStatus = true" @click="showEmploymentStatus = true"
/> />
<div style="margin: 16px;"> <div style="margin: 16px;">
<van-button round block type="info" native-type="submit" @click="updateContactInfo">保存</van-button> <van-button
round
block
type="info"
native-type="submit"
@click="updateContactInfo_click"
>保存</van-button>
</div> </div>
<!-- 户口性质 --> <!-- 户口性质 -->
...@@ -159,7 +165,7 @@ ...@@ -159,7 +165,7 @@
<script lang="ts"> <script lang="ts">
import Vue from "vue"; import Vue from "vue";
import { Button, Icon, Popup, Form, Picker, Field, Toast} from "vant"; import { Button, Icon, Popup, Form, Picker, Field, Toast } from "vant";
import { Component } from "vue-property-decorator"; import { Component } from "vue-property-decorator";
@Component({ @Component({
...@@ -169,11 +175,14 @@ import { Component } from "vue-property-decorator"; ...@@ -169,11 +175,14 @@ import { Component } from "vue-property-decorator";
[Popup.name]: Popup, [Popup.name]: Popup,
[Form.name]: Form, [Form.name]: Form,
[Picker.name]: Picker, [Picker.name]: Picker,
[Field.name]: Field, [Field.name]: Field
} }
}) })
export default class socialInfo extends Vue { export default class socialInfo extends Vue {
private obj: any = {}; private obj: any = {};
private city: any = {};
private parents: any = [];
private childrens: any = [];
private show: boolean = false; private show: boolean = false;
private showCategory: boolean = false; private showCategory: boolean = false;
private showSocialStatus: boolean = false; private showSocialStatus: boolean = false;
...@@ -184,50 +193,109 @@ export default class socialInfo extends Vue { ...@@ -184,50 +193,109 @@ export default class socialInfo extends Vue {
private columns: any = { private columns: any = {
category: ["城镇", "农业"], category: ["城镇", "农业"],
socialStatus:["曾上过社会保险","从未上过社会保险"], socialStatus: ["曾上过社会保险", "从未上过社会保险"],
paymentType:["养老","失业","工伤","生育","医疗","住房"], paymentType: ["养老", "失业", "工伤", "生育", "医疗", "住房"],
relationUnit:["与原单位已不存在任何劳动关系","与原单位仍保持劳动关系,社保由原单位缴纳"], relationUnit: [
employmentStatus:["下岗","内退","其他"], "与原单位已不存在任何劳动关系",
socialCity:["北京市","郑州市"] "与原单位仍保持劳动关系,社保由原单位缴纳"
],
employmentStatus: ["下岗", "内退", "其他"],
socialCity: [
{
text: "浙江",
children: [
{
text: "杭州",
children: [{ text: "西湖区" }, { text: "余杭区" }]
},
{
text: "温州",
children: [{ text: "鹿城区" }, { text: "瓯海区" }]
}
]
}
]
}; };
// 户口性质 // 户口性质
onConfirmCategory(value:string, index:any) { onConfirmCategory(value: string, index: any) {
this.obj.infoRegisteredResidence = value; this.obj.infoRegisteredResidence = value;
this.showCategory = false; this.showCategory = false;
} }
// 前期社保状态 // 前期社保状态
onConfirmSocialStatus(value:string, index:any) { onConfirmSocialStatus(value: string, index: any) {
this.obj.unitPreSocialStatus = value; this.obj.unitPreSocialStatus = value;
this.showSocialStatus = false; this.showSocialStatus = false;
} }
// 前期缴费种类 // 前期缴费种类
onConfirmPaymentType(value:string, index:any) { onConfirmPaymentType(value: string, index: any) {
this.obj.unitPrePaymentType = value; this.obj.unitPrePaymentType = value;
this.showPaymentType = false; this.showPaymentType = false;
} }
// 原社保缴纳省市 // 原社保缴纳省市
onConfirmSocialCity(value:string, index:any) { onConfirmSocialCity(value: string, index: any) {
this.obj.unitPreSocialCity = value; this.obj.unitPreSocialCity = value;
this.showSocialCity = false; this.showSocialCity = false;
} }
// 与原单位关系 // 与原单位关系
onConfirmRelationUnit(value:string, index:any) { onConfirmRelationUnit(value: string, index: any) {
this.obj.unitRelationUnit = value; this.obj.unitRelationUnit = value;
this.showRelationUnit = false; this.showRelationUnit = false;
} }
// 前期就业状态 // 前期就业状态
onConfirmEmploymentStatus(value:string, index:any) { onConfirmEmploymentStatus(value: string, index: any) {
this.obj.unitPreEmploymentStatus = value; this.obj.unitPreEmploymentStatus = value;
this.showEmploymentStatus = false; this.showEmploymentStatus = false;
} }
private getCityList(): void {
this.$server.EmployeeService.getCityList({})
.then(res => {
console.log("citylist", res);
this.city = res;
for (let i = 0; i < this.city.length; i++) {
if (this.city[i].parentId == 0) {
this.parents.push(this.city[i]);
}
if (this.city[i].parentId != 0) {
this.childrens.push(this.city[i]);
}
}
//没有父节点的数据
console.log(this.parents);
//有父节点的数据
console.log(this.childrens);
// 城市3级级联 鄙人黔驴技穷,有请大佬继续 https://blog.csdn.net/MySunshine07/article/details/104960244?utm_medium=distribute.pc_relevant.none-task-blog-baidujs-1
// let fliterEvent = (parents:any, childrens:any) => {
// parents.forEach(parent => {
// childrens.forEach((current:any, index:any) => {
// if (current.parentId === parent.id) {
// let temp = JSON.parse(JSON.stringify(children));
// temp.splice(index, 1);
// fliterEvent([current], temp);
// typeof parent.children !== "undefined"
// ? parent.children.push(current)
// : (parent.children = [current]);
// }
// });
// });
// };
// function translator(parents, childrens) {
// fliterEvent(parents, childrens);
// return parents;
// }
})
.catch(error => {
console.log(error);
});
}
created() { private getSocialInfo(): void {
let params = { let params = {
edId: this.$route.query.ed_id edId: this.$route.query.ed_id
}; };
...@@ -239,10 +307,12 @@ export default class socialInfo extends Vue { ...@@ -239,10 +307,12 @@ export default class socialInfo extends Vue {
}) })
.catch(error => {}); .catch(error => {});
} }
editInfo(): void { editInfo(): void {
this.show = true; this.show = true;
} }
updateContactInfo() {
updateContactInfo_click() {
let data = { let data = {
id: this.$route.query.ed_id, id: this.$route.query.ed_id,
infoRegisteredResidence: this.obj.infoRegisteredResidence, // 户口性质 infoRegisteredResidence: this.obj.infoRegisteredResidence, // 户口性质
...@@ -293,6 +363,11 @@ export default class socialInfo extends Vue { ...@@ -293,6 +363,11 @@ export default class socialInfo extends Vue {
console.log(error); console.log(error);
}); });
} }
created() {
this.getSocialInfo();
this.getCityList();
}
} }
</script> </script>
......
...@@ -3,6 +3,7 @@ ...@@ -3,6 +3,7 @@
*/ */
export interface EmployeeInterface { export interface EmployeeInterface {
getUserInfo(params: any): Promise<any>; getUserInfo(params: any): Promise<any>;
getCityList(params: any): Promise<any>; // 获取城市列表
getDispatchList(params: any): Promise<any>; //根据身份证获取用户所属派遣公司列表 getDispatchList(params: any): Promise<any>; //根据身份证获取用户所属派遣公司列表
getDispatchInfo(params: any): Promise<any>; //通过身份证号和派遣公司ID拿到派遣员工的信息(劳务派遣首页数据) getDispatchInfo(params: any): Promise<any>; //通过身份证号和派遣公司ID拿到派遣员工的信息(劳务派遣首页数据)
getWorkInfoList(params: any): Promise<any>; //获取工作信息列表 getWorkInfoList(params: any): Promise<any>; //获取工作信息列表
......
...@@ -240,6 +240,15 @@ class EmployeeService implements EmployeeInterface { ...@@ -240,6 +240,15 @@ class EmployeeService implements EmployeeInterface {
return request.put(url, params, this.header) return request.put(url, params, this.header)
} }
/**
* 获取城市列表
* @param params
*/
public getCityList(params: any): Promise<any> {
let url = urls.employeeUrl + `/api/user/dispatch/cities`;
return request.get(url, params, this.header)
}
public getAgileWorker(params: any): Promise<any> { public getAgileWorker(params: any): Promise<any> {
let url = urls.employeeUrl + `/api/user/employee/${params.idNo}/bill/item`; let url = urls.employeeUrl + `/api/user/employee/${params.idNo}/bill/item`;
return request.get(url, params, this.header) return request.get(url, params, this.header)
......
...@@ -80,21 +80,26 @@ export default class Index extends Vue { ...@@ -80,21 +80,26 @@ export default class Index extends Vue {
private position: string = ""; private position: string = "";
private entry_date: string = ""; private entry_date: string = "";
private id_no: string = ""; private id_no: string = "";
private ed_id: string = "8"; private sp_id: string = "";
private ed_id: string = "";
created() { created() {
const id_no = this.$route.query.id_no as string; const id_no = this.$route.query.id_no as string;
this.id_no = window.atob(encodeURI(id_no)); this.id_no = window.atob(encodeURI(id_no));
let params={ this.sp_id = this.$route.query.sp_id as string;
spId:1,
idNo:this.$route.query.id_no let params = {
} spId: this.sp_id,
this.$server.EmployeeService.getDispatchInfo(params).then(res=>{ idNo: this.id_no
console.log(res) };
}).catch(error=>{
console.log(error) this.$server.EmployeeService.getDispatchInfo(params)
}) .then(res => {
console.log(res);
})
.catch(error => {
console.log(error);
});
} }
} }
</script> </script>
......
...@@ -7,15 +7,15 @@ ...@@ -7,15 +7,15 @@
<p>可查看专项订单服务,使用职场小工具</p> <p>可查看专项订单服务,使用职场小工具</p>
</div> </div>
</a>--> </a>-->
<a class="si-child" id="dispatch-employee" @click="toIndex"> <a class="si-child" id="dispatch-employee" @click="toIndex_click">
<img src="../assets/images/agent/company-employee.png" alt /> <img src="../assets/images/agent/dispatch-employee.png" alt />
<div class="si-child-desc"> <div class="si-child-desc">
<h4>我是派遣员工</h4> <h4>我是派遣员工</h4>
<p>可查看编辑自己的劳务派遣员工档案信息</p> <p>可查看编辑自己的劳务派遣员工档案信息</p>
</div> </div>
</a> </a>
<a class="si-child" id="flex-employee" @click="toFlex"> <a class="si-child" id="flex-employee" @click="toFlex">
<img src="../assets/images/agent/company-employee.png" alt /> <img src="../assets/images/agent/flex-employee.png" alt />
<div class="si-child-desc"> <div class="si-child-desc">
<h4>我是灵活用工员工</h4> <h4>我是灵活用工员工</h4>
<p>可查看灵活用工人员任务信息</p> <p>可查看灵活用工人员任务信息</p>
...@@ -37,17 +37,24 @@ export default class SelectIdentity extends Vue { ...@@ -37,17 +37,24 @@ export default class SelectIdentity extends Vue {
this.$router.push({ name: "FlexEmployee", query: { id_no: this.id_no } }); this.$router.push({ name: "FlexEmployee", query: { id_no: this.id_no } });
} }
private toIndex(): void { private toIndex(sp_id: string): void {
this.$router.push({ name: "Index", query: { id_no: this.id_no } }); this.$router.push({
name: "Index",
query: { id_no: this.id_no, sp_id: sp_id }
});
// this.$router.push({ name: "ChooseCompany", query: { id_no: this.id_no } }); // this.$router.push({ name: "ChooseCompany", query: { id_no: this.id_no } });
} }
private toIndex_click(): void {
const sp_id: string = "";
this.toIndex(sp_id);
}
async created() { async created() {
await this.$server.EmployeeService.getUserInfo({}) await this.$server.EmployeeService.getUserInfo({})
.then(res => { .then(res => {
if (res.data && res.data.uthStatus && res.data.uthStatus > 0) { if (res.data && res.data.uthStatus && res.data.uthStatus > 0) {
this.id_no = res.data.personalIdCardNo; this.id_no = res.data.personalIdCardNo;
console.log("this.id_no=", this.id_no);
} else { } else {
//TODO: 跳转到实名认证 //TODO: 跳转到实名认证
} }
...@@ -55,6 +62,13 @@ export default class SelectIdentity extends Vue { ...@@ -55,6 +62,13 @@ export default class SelectIdentity extends Vue {
.catch(err => { .catch(err => {
console.log("err=", err); console.log("err=", err);
}); });
this.$server.EmployeeService.getDispatchList({ idNo: this.id_no })
.then(res => {
console.log("getDispatchList res=", res);
})
.catch(err => {
console.log("err=", err);
});
} }
} }
</script> </script>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment