var inputText = [{
"userTypeId": "1002",
"birthday": null,
"postCategory": null,
"zipCode": "",
"nation": null,
"idCard": null,
"nengjiCode": "",
"companyName": "",
"signUrl": "",
"orgId": 194,
"pinYin": null,
"workNo": "45678",
"userTypeCode": "1000100101",
"uid": "zhouqi234",
"photoUrl": "",
"joinDate": null,
"zgxl": null,
"rank": "员工",
"userEmail": "zhouqi@163.com",
"id": "456789765",
"politicalAffiliation": null,
"email": "zhouqi@163.com",
"order": "999",
"companyCode": "",
"counterpartUnionCode": "",
"nengjiName": "",
"sex": "1",
"partJobs": null,
"mobile": "",
"inventedOrgid": "",
"userName": "董国十一",
"postSequence": null,
"jobId": 3,
"hyzk": null,
"createTime": "2019-11-01 12:17:56",
"dutyShortName": "tyui",
"phone": null,
"companyAddress": "",
"nativePlace": null,
"weChatId": "678945885",
"appRoles": "sys011",
"status": "1"
}, {
"userTypeId": "1002",
"birthday": null,
"postCategory": null,
"zipCode": "",
"nation": null,
"idCard": null,
"nengjiCode": "",
"companyName": "",
"signUrl": "",
"orgId": 196,
"pinYin": null,
"workNo": "",
"userTypeCode": "1000100101",
"uid": "houqids",
"photoUrl": "",
"joinDate": null,
"zgxl": null,
"rank": "员工",
"userEmail": "",
"id": "56787654345665456",
"politicalAffiliation": null,
"email": "",
"order": "999",
"companyCode": "",
"counterpartUnionCode": "",
"nengjiName": "",
"sex": "1",
"partJobs": null,
"mobile": "",
"inventedOrgid": "",
"userName": "后期*周",
"postSequence": null,
"jobId": 3,
"hyzk": null,
"createTime": "2019-11-18 14:43:10",
"dutyShortName": "",
"phone": null,
"companyAddress": "",
"nativePlace": null,
"weChatId": null,
"appRoles": "sys011",
"status": "1"
}];
var outputObj = [];
//console.log(inputText)
for (var i = 0; i <= inputText.length; i++) {
var data = inputText[i];
employee_number=data.workNo;
var statu=data["ststus"];
var values = {
"employee_number":data["workNo"].toString(),
"x_uid_number" : data["uid"].toString(),
"name" : data["userName"].toString(),
"date_of_birth" : data["birthday"].toString()==null?null:data["birthday"].slice(6,14),
"x_national_number" : data["idCard"],
"x_phone_number" : data["mobile"],
"x_email_address" : data["email"],
"department_id" : data["orgId"],
"position_id" : data["jobId"],
"x_job_classification_id" : data["dutyShortName"],
"x_job_sequence_id" : data["postSequence"],
"x_job_grade_id" : data["rank"],
"x_position_type" : data["postCategory"],
"x_nengji_id" :data["nengjiCode"],
"hire_date" : data["joinDate"],
//todo
"x_qvid" :data["weChatId"],
full_data_mode=true,
standard_mode=true,
if(statu=0){
status="active"
}else if(data.status==1){
status="inactive"
}
outputObj.push(values)
}
}
console.log(outputObj)
console