Commit ee45d415 by e

updata

parent ade06ad5
Showing with 70 additions and 10 deletions
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
<div class="header"> <div class="header">
<div class="tip"></div> <div class="tip"></div>
<div class="title">社保信息</div> <div class="title">社保信息</div>
<van-icon size="14px" color="#E1E4EB" name="arrow" /> <van-icon size="14px" color="#E1E4EB" name="arrow" @click="editInfo" />
</div> </div>
<div class="box"> <div class="box">
<div class="item"> <div class="item">
...@@ -35,31 +35,91 @@ ...@@ -35,31 +35,91 @@
<label>{{obj.unitPreEmploymentStatus}}</label> <label>{{obj.unitPreEmploymentStatus}}</label>
</div> </div>
</div> </div>
<van-popup v-model="show" position="right" :style="{ height: '100%',width: '90%' }">
<van-form>
<van-field v-model="infoRegisteredResidence" label="户口性质" placeholder="请选择户口性质" />
<van-field v-model="unitPreSocialStatus" label="前期社保状态" placeholder="请选择前期社保状态" />
<van-field v-model="unitPrePaymentType" label="前期缴费种类" placeholder="请选择前期缴费种类" />
<van-field v-model="unitPreSocialCity" label="原社保缴纳省市" placeholder="请选择原社保缴纳省市" />
<van-field v-model="unitPreSocialUnit" label="原社保缴纳单位" placeholder="请填写原社保缴纳单位" />
<van-field v-model="unitRelationUnit" label="与原单位关系" placeholder="请选择与原单位关系" />
<van-field v-model="unitPreEmploymentStatus" label="前期就业状态" placeholder="请选择前期就业状态" />
<div style="margin: 16px;">
<van-button round block type="info" native-type="submit" @click="updateContactInfo">保存</van-button>
</div>
</van-form>
</van-popup>
</div> </div>
</template> </template>
<script lang="ts"> <script lang="ts">
import Vue from "vue"; import Vue from "vue";
import { Icon } 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({
components:{ components: {
[Icon.name]: Icon [Button.name]: Button,
[Icon.name]: Icon,
[Popup.name]: Popup,
[Form.name]: Form,
[Picker.name]: Picker,
[Field.name]: Field
} }
}) })
export default class socialInfo extends Vue { export default class socialInfo extends Vue {
private obj:object={} private infoRegisteredResidence:string="" // 户口性质
created(){ private unitPreSocialStatus:string="" // 前期社保状态
private unitPrePaymentType:string="" // 前期缴费种类
private unitPreSocialCity:string="" // 原社保缴纳省市
private unitPreSocialUnit:string="" // 原社保缴纳单位
private unitRelationUnit:string="" // 与原单位关系
private unitPreEmploymentStatus:string="" // 前期就业状态
private obj: object = {};
private show: boolean = false;
created() {
let params = { let params = {
edId: this.$route.query.ed_id edId: this.$route.query.ed_id
}; };
this.$server.EmployeeService.getSocialInfo(params).then(res=>{ this.$server.EmployeeService.getSocialInfo(params)
// console.log("res="+JSON.stringify(res)) .then(res => {
this.obj=res; console.log("res=" + JSON.stringify(res)+'社保信息');
}).catch(error=>{
this.obj = res;
})
.catch(error => {});
}
editInfo(): void {
this.show = true;
}
updateContactInfo() {
let data = {
id: this.$route.query.ed_id,
infoRegisteredResidence: this.infoRegisteredResidence,
unitRelationUnit: this.unitRelationUnit,
unitPreEmploymentStatus: this.unitPreEmploymentStatus,
unitPreSocialStatus: this.unitPreSocialStatus,
unitPrePaymentType: this.unitPrePaymentType,
unitPreSocialUnit: this.unitPreSocialUnit,
unitPreSocialCity: this.unitPreSocialCity
};
if (!this.unitPreSocialUnit) {
Toast("请填写原社保缴纳单位");
return;
}
this.$server.EmployeeService.saveSocialInfo(data)
.then(res => {
if (res == true) {
Toast.success("保存成功");
}
}) })
.catch(error => {
console.log(error);
});
} }
} }
</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