From d624db0b35ac540d8f10f7dce0ea76041646881e Mon Sep 17 00:00:00 2001
From: liujun <liujun@zcloudchina.com>
Date: Fri, 28 Feb 2025 16:43:38 +0800
Subject: [PATCH] =?UTF-8?q?1=E3=80=81=E7=9B=B8=E5=85=B3=E6=96=B9token?=
 =?UTF-8?q?=E4=B8=8D=E5=88=B7=E6=96=B0=E9=97=AE=E9=A2=98=202=E3=80=81?=
 =?UTF-8?q?=E7=9B=B8=E5=85=B3=E6=96=B9=E4=BA=BA=E5=91=98=E4=BF=A1=E6=81=AF?=
 =?UTF-8?q?=E7=BC=96=E8=BE=91=E9=94=99=E8=AF=AF=E9=97=AE=E9=A2=98=203?=
 =?UTF-8?q?=E3=80=81=E7=9B=B8=E5=85=B3=E6=96=B9=E5=B0=B1=E8=81=8C=E5=8E=86?=
 =?UTF-8?q?=E5=8F=B2=E8=AE=B0=E5=BD=95bug?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

---
 api/api.js                        |   8 +
 api/refreshToken.js               |  14 +
 package-lock.json                 |  16 +-
 package.json                      |   3 +-
 pages/employed_by/index.vue       |  56 +-
 pages/mine/information/index.vue  | 194 +++----
 pages/mine/information/update.vue | 855 ++++++++++++++++--------------
 utils/request.js                  |   5 +-
 utils/tools.js                    |   4 +-
 9 files changed, 607 insertions(+), 548 deletions(-)
 create mode 100644 api/api.js
 create mode 100644 api/refreshToken.js

diff --git a/api/api.js b/api/api.js
new file mode 100644
index 0000000..73884c4
--- /dev/null
+++ b/api/api.js
@@ -0,0 +1,8 @@
+import {post, upload} from "../utils/request";
+// 已重构接口
+export const getUserInfoV1 = (params) => post("/app/sys/user/getXgfUserInfo", params) // 获取用户信息
+export const setUserInitV1 = (params) => post("/app/sys/user/xgfInit", params) //更新用户信息
+export const getDicLevel = (params) => post("/app/sys/dictionaries/getLevels", params) // 获取数据字典
+export const getEmpLog = (params) => post("/app/sys/user/getEmpLog", params) // 获取就职记录
+export const uploadFile = (params) => upload("/app/sys/file/uploadFile", params);
+export const setRefreshToken = (params) => post("/sys/refreshToken", params ); // 刷新token
diff --git a/api/refreshToken.js b/api/refreshToken.js
new file mode 100644
index 0000000..77ab822
--- /dev/null
+++ b/api/refreshToken.js
@@ -0,0 +1,14 @@
+import dayjs from "dayjs";
+import store from "../store";
+import {setRefreshToken} from "./api";
+
+export default async function () {
+    const userStore = store.state.userInfo;
+    if (userStore.getTokenTime) {
+        if (dayjs().diff(dayjs(userStore.getTokenTime), "minute") >= 5) {
+            await userStore.setTokenTime(dayjs().format("YYYY-MM-DD HH:mm:ss"));
+            await setRefreshToken();
+        }
+    }
+
+}
diff --git a/package-lock.json b/package-lock.json
index 1cd7706..36ed9ae 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -15,7 +15,8 @@
       },
       "devDependencies": {
         "@types/html5plus": "^1.0.2",
-        "@types/uni-app": "^1.4.4"
+        "@types/uni-app": "^1.4.4",
+        "dayjs": "^1.11.13"
       }
     },
     "node_modules/@babel/parser": {
@@ -59,6 +60,13 @@
       "resolved": "https://registry.npmjs.org/csstype/-/csstype-3.1.2.tgz",
       "integrity": "sha512-I7K1Uu0MBPzaFKg4nI5Q7Vs2t+3gWWW648spaF+Rg7pI9ds18Ugn+lvg4SHczUdKlHI5LWBXyqfS8+DufyBsgQ=="
     },
+    "node_modules/dayjs": {
+      "version": "1.11.13",
+      "resolved": "https://registry.npmmirror.com/dayjs/-/dayjs-1.11.13.tgz",
+      "integrity": "sha512-oaMBel6gjolK862uaPQOVTA7q3TZhuSvuMQAAglQDOWYO9A91IrAOUJEyKVlqJlHE0vq5p5UXxzdPfMH/x6xNg==",
+      "dev": true,
+      "license": "MIT"
+    },
     "node_modules/deepmerge": {
       "version": "4.3.1",
       "resolved": "https://registry.npmjs.org/deepmerge/-/deepmerge-4.3.1.tgz",
@@ -215,6 +223,12 @@
       "resolved": "https://registry.npmjs.org/csstype/-/csstype-3.1.2.tgz",
       "integrity": "sha512-I7K1Uu0MBPzaFKg4nI5Q7Vs2t+3gWWW648spaF+Rg7pI9ds18Ugn+lvg4SHczUdKlHI5LWBXyqfS8+DufyBsgQ=="
     },
+    "dayjs": {
+      "version": "1.11.13",
+      "resolved": "https://registry.npmmirror.com/dayjs/-/dayjs-1.11.13.tgz",
+      "integrity": "sha512-oaMBel6gjolK862uaPQOVTA7q3TZhuSvuMQAAglQDOWYO9A91IrAOUJEyKVlqJlHE0vq5p5UXxzdPfMH/x6xNg==",
+      "dev": true
+    },
     "deepmerge": {
       "version": "4.3.1",
       "resolved": "https://registry.npmjs.org/deepmerge/-/deepmerge-4.3.1.tgz",
diff --git a/package.json b/package.json
index 10161aa..79817bc 100644
--- a/package.json
+++ b/package.json
@@ -16,6 +16,7 @@
   "license": "ISC",
   "devDependencies": {
     "@types/html5plus": "^1.0.2",
-    "@types/uni-app": "^1.4.4"
+    "@types/uni-app": "^1.4.4",
+    "dayjs": "^1.11.13"
   }
 }
diff --git a/pages/employed_by/index.vue b/pages/employed_by/index.vue
index 4fe1361..a78bbb0 100644
--- a/pages/employed_by/index.vue
+++ b/pages/employed_by/index.vue
@@ -4,48 +4,48 @@
       <u-list-item v-for="(item, index) in list" :key="index">
         <view>
           <view class="flex-between main-title">
-            <text>单位名称:{{ item.RELEVANT_UNIT_NAME }}</text>
+            <text>单位名称:{{ item.relevantUnitName }}</text>
           </view>
-          <view class="flex-between mt-10 subtitle" v-show="item.START_DATE">
-            <text>就职时间:{{ item.START_DATE }}-{{ item.END_DATE || '至今' }}</text>
+          <view class="flex-between mt-10 subtitle" v-show="item.startDate">
+            <text>就职时间:{{ item.startDate }}-{{ item.endDate || '至今' }}</text>
           </view>
-          <view class="flex-between mt-10 subtitle" v-show="item.DEPART_STATE">
+          <view class="flex-between mt-10 subtitle" v-show="item.departState">
             <text>就职状态:
-              <template v-if="item.DEPART_STATE === '0'">在职</template>
-              <template v-if="item.DEPART_STATE === '1'">离职</template>
-              <template v-if="item.DEPART_STATE === '-1'">离职申请中</template>
-              <template v-if="item.DEPART_STATE === '2'">待审核</template>
-              <template v-if="item.DEPART_STATE === '3'">已审核</template>
+              <template v-if="item.departState === '0'">在职</template>
+              <template v-if="item.departState === '1'">离职</template>
+              <template v-if="item.departState === '-1'">离职申请中</template>
+              <template v-if="item.departState === '2'">待审核</template>
+              <template v-if="item.departState === '3'">已审核</template>
             </text>
           </view>
           <view class="flex-between mt-10 subtitle">
             <text>单位在职申请审核状态:
-              <template v-if="item.AUDIT_STATE === '0'">已打回</template>
-              <template v-if="item.AUDIT_STATE === '1'">待审核</template>
-              <template v-if="item.AUDIT_STATE === '2'">审核通过</template>
+              <template v-if="item.auditState === '0'">已打回</template>
+              <template v-if="item.auditState === '1'">待审核</template>
+              <template v-if="item.auditState === '2'">审核通过</template>
             </text>
           </view>
-          <view class="flex-between mt-10 subtitle" v-show="item.DEPART_STATE !== '0' && item.REVIEW_STATE">
+          <view class="flex-between mt-10 subtitle" v-show="item.departState !== '0' && item.reviewState">
             <text>单位离职申请审核状态:
-              <template v-if="item.REVIEW_STATE === '0'">已打回</template>
-              <template v-if="item.REVIEW_STATE === '1'">待审核</template>
-              <template v-if="item.REVIEW_STATE === '2'">审核通过</template>
+              <template v-if="item.reviewState === '0'">已打回</template>
+              <template v-if="item.reviewState === '1'">待审核</template>
+              <template v-if="item.reviewState === '2'">审核通过</template>
             </text>
           </view>
 
-          <view class="flex-between mt-10 subtitle" v-if="item.AUDIT_REMARKS">
-            <text>审核意见:{{ item.AUDIT_REMARKS }}
+          <view class="flex-between mt-10 subtitle" v-if="item.auditRemarks">
+            <text>审核意见:{{ item.auditRemarks }}
             </text>
           </view>
           <view class="flex-between mt-10 subtitle">
             <view></view>
             <view class="flex-between">
               <u-button type="primary" text="查看" size="mini"
-                        @click="fnView(item.EMPLOYMENT_APPLY_MANAGEMENT_ID, item.CORPINFO_ID, item.DEPART_STATE)"></u-button>
+                        @click="fnView(item.employmentApplyManagementId, item.corpinfoId, item.departState)"></u-button>
               <view class="ml-10">
                 <u-button type="primary" text="离职" size="mini"
-                          v-if="item.DEPART_STATE === '0'"
-                          @click="fnResignationApplication(item.EMPLOYMENT_APPLY_MANAGEMENT_ID,item.RELEVANT_UNIT_NAME)">
+                          v-if="item.departState === '0'"
+                          @click="fnResignationApplication(item.employmentApplyManagementId,item.relevantUnitName)">
                 </u-button>
               </view>
             </view>
@@ -58,9 +58,7 @@
 </template>
 
 <script>
-import {
-  getEmployedBy
-} from "../../api";
+import {getEmpLog} from "../../api/api";
 
 export default {
   data() {
@@ -76,11 +74,13 @@ export default {
   },
   methods: {
     async getData() {
-      let resData = await getEmployedBy({
-        showCount: this.pageSize,
-        currentPage: this.currentPage,
+      let resData = await getEmpLog({
+        id: this.$store.getters.getUserInfo.USER_ID,
+        limit: this.pageSize,
+        curPage: this.currentPage,
+        postMethod: 'application/json'
       });
-      this.list = [...this.list, ...resData.varList];
+      this.list = [...this.list, ...resData.page.list];
       this.totalPage = resData.page.totalPage;
     },
     resetList() {
diff --git a/pages/mine/information/index.vue b/pages/mine/information/index.vue
index 5072063..b1ebdb1 100644
--- a/pages/mine/information/index.vue
+++ b/pages/mine/information/index.vue
@@ -4,19 +4,14 @@
       <u-cell-group>
         <u-cell title="照片">
           <template #value>
-            <u--image :src="info.userPhoto" shape="circle" width="100rpx" height="100rpx"></u--image>
+            <u--image :src="userPhoto" shape="circle" width="100rpx" height="100rpx"></u--image>
           </template>
         </u-cell>
-        <u-cell title="姓名" :value="info.NAME"></u-cell>
-        <u-cell title="性别" :value="info.SEX === '1' ? '女' : '男'">
-          <template #value>
-            {{ info.SEX === '1' ? '女' : '' }}
-            {{ info.SEX === '0' ? '男' : '' }}
-          </template>
-        </u-cell>
-        <u-cell title="出生年月" :value="info.DATE_OF_BIRTH"></u-cell>
-        <u-cell title="年龄" :value="info.AGE"></u-cell>
-        <u-cell title="身份证" :value="info.CARD_ID" @blur="fnIDCardDeduplication"></u-cell>
+        <u-cell title="姓名" :value="info.name"></u-cell>
+        <u-cell title="性别" :value="info.userDetails.sex === '1' ? '女' : '男'"></u-cell>
+        <u-cell title="出生年月" :value="info.userDetails.dateOfBirth"></u-cell>
+        <u-cell title="年龄" :value="info.userDetails.age"></u-cell>
+        <u-cell title="身份证" :value="info.userDetails.cardId"></u-cell>
         <u-cell title="身份证照片">
           <template #value>
             <view v-for="(item,index) in userCardIDPhotoFile" :key="index"
@@ -26,26 +21,25 @@
             </view>
           </template>
         </u-cell>
-        <u-cell title="民族" :value="info.minzuName"></u-cell>
+        <u-cell title="民族" :value="info.userDetails.nationalityName"></u-cell>
         <u-cell title="户口所在地">
           <template #value>
-            <u--text :lines="2" align="right" :text="info.HKLOCAL"></u--text>
+            <u--text :lines="2" align="right" :text="info.userDetails.hklocal"></u--text>
           </template>
         </u-cell>
         <u-cell title="现住址">
           <template #value>
-            <u--text :lines="2" align="right" :text="info.ADDRESS"></u--text>
+            <u--text :lines="2" align="right" :text="info.userDetails.address"></u--text>
           </template>
         </u-cell>
-        <u-cell title="联系电话" :value="info.PHONE"></u-cell>
-        <u-cell title="婚姻状况" :value="info.MARITALSTATUS == 0 ? '未婚':'已婚'"></u-cell>
-        <u-cell title="政治面貌" :value="info.zzName"></u-cell>
-        <u-cell v-if="info.POLITICAL_STATUS == 'zhonggongdangyuan'" title="入党时间"
-                :value="info.POLITICAL_TIME"></u-cell>
-        <u-cell title="是否缴纳社保" :value="info.IS_SOCIAL_NAME"></u-cell>
-        <!-- 用v-if会出现渲染问题导致出现两行相同的数据 所以改成v-show modify by water_xu 2024.7.19 -->
-        <u-cell title="社会保障号" v-show="info.IS_SOCIAL==='1'" :value="info.SOCIAL_NUMBER"></u-cell>
-        <u-cell title="社会保障卡照片" v-show="info.IS_SOCIAL==='1'">
+        <u-cell title="联系电话" :value="info.userDetails.phone"></u-cell>
+        <u-cell title="婚姻状况" :value="info.userDetails.maritalstatus === 0 ? '未婚':'已婚'"></u-cell>
+        <u-cell title="政治面貌" :value="info.userDetails.politicalStatusName"></u-cell>
+        <u-cell v-if="info.userDetails.politicalStatus === 'zhonggongdangyuan'" title="入党时间"
+                :value="info.userDetails.politicalTime"></u-cell>
+        <u-cell title="是否缴纳社保" :value="info.userDetails.isSocial === '1'? '是' : '否'"></u-cell>
+        <u-cell title="社会保障号" v-show="info.userDetails.isSocial==='1'" :value="info.userDetails.socialNumber"></u-cell>
+        <u-cell title="社会保障卡照片" v-show="info.userDetails.isSocial === '1'">
           <template #value>
             <view v-for="(item,index) in socialPhotoFile" :key="index"
                   style="display: flex;justify-content: space-between;margin-left: 10rpx;">
@@ -54,8 +48,8 @@
             </view>
           </template>
         </u-cell>
-        <u-cell title="是否签订劳动合同" :value="info.IS_SIGN_LABOR_NAME"></u-cell>
-        <u-cell title="合同图片" v-show="info.IS_SIGN_LABOR==='1'">
+        <u-cell title="是否签订劳动合同" :value="info.userDetails.isSignLabor === '1' ? '是':'否'"></u-cell>
+        <u-cell title="合同图片" v-show="info.userDetails.isSignLabor==='1'">
           <template #value>
             <view v-for="(item,index) in contractFile" :key="index"
                   style="display: flex;justify-content: space-between;margin-left: 10rpx;">
@@ -64,9 +58,9 @@
             </view>
           </template>
         </u-cell>
-        <u-cell title="是否缴纳商业保险" :value="info.ISPAY_NAME"></u-cell>
-        <u-cell title="商业保险单号" v-show="info.ISPAY==='1'" :value="info.ISPAY_NUMBER"></u-cell>
-        <u-cell title="保险图片" v-show="info.ISPAY==='1'">
+        <u-cell title="是否缴纳商业保险" :value="info.userDetails.ispay === '1' ? '是':'否'"></u-cell>
+        <u-cell title="商业保险单号" v-show="info.userDetails.ispay === '1'" :value="info.ispayNumber"></u-cell>
+        <u-cell title="保险图片" v-show="info.userDetails.ispay === '1'">
           <template #value>
             <view v-for="(item,index) in insuranceFile" :key="index"
                   style="display: flex;justify-content: space-between;margin-left: 10rpx;">
@@ -75,9 +69,9 @@
             </view>
           </template>
         </u-cell>
-        <u-cell title="是否按期缴纳工伤保险" :value="info.IS_INJURIES_PAY_NAME"></u-cell>
-        <u-cell title="工伤保险有效期" v-show="info.IS_INJURIES_PAY==='1'" :value="info.IS_INJURIES_PAY_TIME"></u-cell>
-        <u-cell title="工伤保险凭证" v-show="info.IS_INJURIES_PAY==='1'">
+        <u-cell title="是否按期缴纳工伤保险" :value="info.userDetails.isInjuriesPay === '1' ? '是':'否'"></u-cell>
+        <u-cell title="工伤保险有效期" v-show="info.userDetails.isInjuriesPay==='1'" :value="info.userDetails.isInjuriesPayTime"></u-cell>
+        <u-cell title="工伤保险凭证" v-show="info.userDetails.isInjuriesPay==='1'">
           <template #value>
             <view v-for="(item,index) in injuriesPayTiemFile" :key="index"
                   style="display: flex;justify-content: space-between;margin-left: 10rpx;">
@@ -86,9 +80,9 @@
             </view>
           </template>
         </u-cell>
-        <u-cell title="岗位名称(工种)" :value="info.POST_ID"></u-cell>
-        <u-cell title="是否参加三级安全培训" :value="info.IS_LEVEL_THREE_NAME"></u-cell>
-        <u-cell title="三级安全培训照片" v-show="info.IS_LEVEL_THREE==='1'">
+        <u-cell title="岗位名称(工种)" :value="info.userDetails.postName"></u-cell>
+        <u-cell title="是否参加三级安全培训" :value="info.userDetails.isLevelThree === '1' ? '是':'否'"></u-cell>
+        <u-cell title="三级安全培训照片" v-show="info.userDetails.isLevelThree === '1'">
           <template #value>
             <view v-for="(item,index) in photosOfLevel" :key="index"
                   style="display: flex;justify-content: space-between;margin-left: 10rpx;">
@@ -97,7 +91,7 @@
             </view>
           </template>
         </u-cell>
-        <u-cell title="是否流动人员" :value="info.ISFLOW_NAME"></u-cell>
+        <u-cell title="是否流动人员" :value="info.emp.isflow === '1' ? '是':'否'"></u-cell>
       </u-cell-group>
     </view>
     <fab-button type="edit" @click="$u.route({url: '/pages/mine/information/update'})"/>
@@ -110,19 +104,32 @@ import {
   getEmployedBy, getIDCardDeduplication
 } from "../../../api";
 import FabButton from "@/components/fab_button/index.vue";
+import {getUserInfoV1} from "../../../api/api";
 
 export default {
   components: {FabButton},
   data() {
     return {
-      info: {},
+      info: {
+        userDetails:{
+          sex:'0',
+          dateOfBirth:'1900-01-01'
+        },
+        emp:{
+          isflow:'0'
+        },
+        age: '0',
+        nationalityName:'',
+        hklocal: '',
+        maritalstatus:'0'
+      },
       userCardIDPhotoFile: [],
       socialPhotoFile: [],
       injuriesPayTiemFile: [],
       photosOfLevel: [],
       contractFile: [],
       insuranceFile: [],
-      EMPLOYMENT_APPLY_MANAGEMENT_ID: '',
+      userPhoto: ''
     }
   },
   onShow() {
@@ -134,98 +141,53 @@ export default {
     }
   },
   methods: {
-    async fnIDCardDeduplication(CARD_ID = this.form.CARD_ID) {
-      let resData = await getIDCardDeduplication({CARD_ID})
-      if (resData.pd) {
-        uni.$u.toast('身份证号重复')
-        return true
-      }
-      return false
-    },
     fnPreview(urls) {
       uni.previewImage({
         urls
       })
     },
     async fnGetData() {
+      let data = await getUserInfoV1(
+          {
+            id: this.$store.getters.getUserInfo.USER_ID,
+            postMethod: 'application/json'
+          }
+      )
+      this.info = data.info
+      // 身份证
       this.userCardIDPhotoFile = []
+      for (let i = 0; i < this.info.userCardInfo.length; i++) {
+        this.userCardIDPhotoFile.push(this.$filePath + this.info.userCardInfo[i].filepath)
+      }
+      // 社保
       this.socialPhotoFile = []
+      for (let i = 0; i < this.info.socSecurityInfo.length; i++) {
+        this.socialPhotoFile.push(this.$filePath + this.info.socSecurityInfo[i].filepath)
+      }
+      // 工伤保险
       this.injuriesPayTiemFile = []
+      for (let i = 0; i < this.info.empInsuranceInfo.length; i++) {
+        this.injuriesPayTiemFile.push(this.$filePath + this.info.empInsuranceInfo[i].filepath)
+      }
+      // 劳动合同
       this.contractFile = []
+      for (let i = 0; i < this.info.contractInfo.length; i++) {
+        this.contractFile.push(this.$filePath + this.info.contractInfo[i].filepath)
+      }
+      // 三级培训
       this.photosOfLevel = []
+      for (let i = 0; i < this.info.threeLevelInfo.length; i++) {
+        this.photosOfLevel.push(this.$filePath + this.info.threeLevelInfo[i].filepath)
+      }
+      // 商业保险
       this.insuranceFile = []
-      let Employed = await getEmployedBy({
-        showCount: 10,
-        currentPage: 1,
-        DEPART_STATE: '0'
-      })
-      if (Employed.varList.length > 0) {
-        Employed.varList.forEach(item => {
-          console.log(item.EMPLOYMENT_APPLY_MANAGEMENT_ID);
-          this.EMPLOYMENT_APPLY_MANAGEMENT_ID = item.EMPLOYMENT_APPLY_MANAGEMENT_ID
-        })
+      for (let i = 0; i < this.info.insuranceInfo.length; i++) {
+        this.insuranceFile.push(this.$filePath + this.info.insuranceInfo[i].filepath)
       }
-      let resData = await getUserInfo({
-        USER_ID: this.userInfo.USER_ID,
-        CORPINFO_ID: this.userInfo.CORPINFO_ID,
-        EMPLOYMENT_APPLY_MANAGEMENT_ID: this.EMPLOYMENT_APPLY_MANAGEMENT_ID
-      })
-      this.info = resData.pd
-      for (let i = 0; i < resData.userCardIDPhotoFile.length; i++) {
-        this.userCardIDPhotoFile.push(this.$filePath + resData.userCardIDPhotoFile[i].FILEPATH)
-      }
-      for (let i = 0; i < resData.socialPhotoFile.length; i++) {
-        this.socialPhotoFile.push(this.$filePath + resData.socialPhotoFile[i].FILEPATH)
-      }
-
-      for (let i = 0; i < resData.workInsurancePhotoFile.length; i++) {
-        this.injuriesPayTiemFile.push(this.$filePath + resData.workInsurancePhotoFile[i].FILEPATH)
-      }
-
-      for (let i = 0; i < resData.contractFile.length; i++) {
-        this.contractFile.push(this.$filePath + resData.contractFile[i].FILEPATH)
-      }
-
-      for (let i = 0; i < resData.photosOfLevel.length; i++) {
-        this.photosOfLevel.push(this.$filePath + resData.photosOfLevel[i].FILEPATH)
-      }
-
-      for (let i = 0; i < resData.insuranceFile.length; i++) {
-        this.insuranceFile.push(this.$filePath + resData.insuranceFile[i].FILEPATH)
-      }
-
-      if (this.info.ISFLOW === '0') {
-        this.info.ISFLOW_NAME = '否'
-      } else if (this.info.ISFLOW === '1') {
-        this.info.ISFLOW_NAME = '是'
-      }
-      if (this.info.IS_SOCIAL === '0') {
-        this.info.IS_SOCIAL_NAME = '否'
-      } else if (this.info.IS_SOCIAL === '1') {
-        this.info.IS_SOCIAL_NAME = '是'
-      }
-      if (this.info.IS_INJURIES_PAY === '0') {
-        this.info.IS_INJURIES_PAY_NAME = '否'
-      } else if (this.info.IS_INJURIES_PAY === '1') {
-        this.info.IS_INJURIES_PAY_NAME = '是'
-      }
-      if (this.info.IS_SIGN_LABOR === '0') {
-        this.info.IS_SIGN_LABOR_NAME = '否'
-      } else if (this.info.IS_SIGN_LABOR === '1') {
-        this.info.IS_SIGN_LABOR_NAME = '是'
-      }
-      if (this.info.IS_LEVEL_THREE === '0') {
-        this.info.IS_LEVEL_THREE_NAME = '否'
-      } else if (this.info.IS_LEVEL_THREE === '1') {
-        this.info.IS_LEVEL_THREE_NAME = '是'
-      }
-      if (this.info.ISPAY === '1') {
-        this.info.ISPAY_NAME = '是'
-      } else {
-        this.info.ISPAY_NAME = '否'
-      }
-      if (resData.userPhotoFile.length > 0) {
-        this.$set(this.info, 'userPhoto', this.$filePath + resData.userPhotoFile[0].FILEPATH)
+      // 头像
+      this.userPhoto = []
+      if (this.info.userPhotoInfo && this.info.userPhotoInfo.length > 0){
+        this.userPhoto = this.$filePath + this.info.userPhotoInfo[0].filepath
       }
     }
   },
diff --git a/pages/mine/information/update.vue b/pages/mine/information/update.vue
index de2a1fe..b80b54a 100644
--- a/pages/mine/information/update.vue
+++ b/pages/mine/information/update.vue
@@ -2,24 +2,25 @@
   <view class="content">
     <view class="card">
       <u--form labelPosition="left" :model="form" :rules="rules" ref="form" labelWidth="120px">
-        <u-form-item label="照片" prop="userPhoto" borderBottom required>
-          <u-upload :fileList="form.userPhoto" @afterRead="fnAfterRead" @delete="fnDeletePic" :maxCount="1"
+        <u-form-item label="照片" prop="userPhotoFile" borderBottom required>
+          <u-upload :fileList="form.userPhotoFile" @afterRead="fnAfterRead" @delete="fnDeletePic" :maxCount="1"
                     previewFullImage></u-upload>
         </u-form-item>
-        <u-form-item label="姓名" prop="NAME" borderBottom required>
-          <u--input border="none" v-model="form.NAME"></u--input>
+        <u-form-item label="姓名" prop="name" borderBottom required>
+          <u--input border="none" v-model="form.name"></u--input>
         </u-form-item>
-        <u-form-item label="性别" prop="SEX_NAME" borderBottom required>
-          <u--input border="none" v-model="form.SEX_NAME" disabled disabledColor="#ffffff"></u--input>
+        <u-form-item label="性别" prop="sex" borderBottom required>
+          <u--input border="none" v-model="form.sexName" disabled
+                    disabledColor="#ffffff"></u--input>
         </u-form-item>
-        <u-form-item label="出生年月" prop="DATE_OF_BIRTH" borderBottom required>
-          <u--input border="none" v-model="form.DATE_OF_BIRTH" disabled disabledColor="#ffffff"></u--input>
+        <u-form-item label="出生年月" prop="dateOfBirth" borderBottom required>
+          <u--input border="none" v-model="form.dateOfBirth" disabled disabledColor="#ffffff"></u--input>
         </u-form-item>
-        <u-form-item label="年龄" prop="AGE" borderBottom required>
-          <u--input border="none" v-model="form.AGE" disabled disabledColor="#ffffff"></u--input>
+        <u-form-item label="年龄" prop="age" borderBottom required>
+          <u--input border="none" v-model="form.age" disabled disabledColor="#ffffff"></u--input>
         </u-form-item>
-        <u-form-item label="身份证" prop="CARD_ID" borderBottom required>
-          <u--input border="none" v-model="form.CARD_ID" @blur="fnCardIdDisassembly"></u--input>
+        <u-form-item label="身份证" prop="cardId" borderBottom required>
+          <u--input border="none" v-model="form.cardId" @blur="fnCardIdDisassembly"></u--input>
         </u-form-item>
         <u-form-item label="身份证照片(正反面)" prop="userCardIDPhotoFile" borderBottom required labelPosition="top"
                      labelWidth="auto">
@@ -32,61 +33,59 @@
             </view>
           </view>
         </u-form-item>
-        <u-form-item label="民族" prop="NATIONALITY" borderBottom required
-                     @click="singleChoiceClick('NATIONALITY')">
-          <u--input v-model="form.NATIONALITY_NAME" border="none" disabled disabledColor="#ffffff">
-          </u--input>
+        <u-form-item label="民族" prop="nationalityName" borderBottom required @click="singleChoiceClick('nationality')">
+          <u--input v-model="form.nationalityName" border="none" disabled disabledColor="#ffffff"></u--input>
         </u-form-item>
-        <u-form-item label="户口所在地" prop="HKLOCAL" borderBottom required>
-          <u--textarea border="none" v-model="form.HKLOCAL" autoHeight></u--textarea>
+        <u-form-item label="户口所在地" prop="hklocal" borderBottom required>
+          <u--textarea border="none" v-model="form.hklocal" autoHeight></u--textarea>
         </u-form-item>
-        <u-form-item label="现住址" prop="ADDRESS" borderBottom required>
-          <u--textarea border="none" v-model="form.ADDRESS" autoHeight></u--textarea>
+        <u-form-item label="现住址" prop="address" borderBottom required>
+          <u--textarea border="none" v-model="form.address" autoHeight></u--textarea>
         </u-form-item>
-        <u-form-item label="联系电话" prop="PHONE" borderBottom required>
-          <u--input border="none" v-model="form.PHONE" :disabled="true"></u--input>
+        <u-form-item label="联系电话" prop="phone" borderBottom required>
+          <u--input border="none" v-model="form.phone" :disabled="true"></u--input>
         </u-form-item>
-        <u-form-item label="文化程度" prop="DEGREE_OF_EDUCATION" borderBottom required
-                     @click="singleChoiceClick('DEGREE_OF_EDUCATION')">
-          <u--input v-model="form.DEGREE_OF_EDUCATION_NAME" border="none" disabled disabledColor="#ffffff">
+        <u-form-item label="文化程度" prop="degreeOfEducationName" borderBottom required
+                     @click="singleChoiceClick('degreeOfEducation')">
+          <u--input v-model="form.degreeOfEducationName" border="none" disabled disabledColor="#ffffff">
           </u--input>
         </u-form-item>
         <view>
-          <u-form-item label="婚姻状况" prop="MARITALSTATUS" borderBottom required
-                       @click="singleChoiceClick('MARITALSTATUS')">
-            <u--input v-model="form.MARITALSTATUS_NAME" border="none" disabled disabledColor="#ffffff">
+          <u-form-item label="婚姻状况" prop="maritalstatusName" borderBottom required
+                       @click="singleChoiceClick('maritalstatus')">
+            <u--input v-model="form.maritalstatusName" border="none" disabled disabledColor="#ffffff">
             </u--input>
           </u-form-item>
         </view>
         <view>
-          <u-form-item label="政治面貌" prop="POLITICAL_STATUS" borderBottom required
-                       @click="singleChoiceClick('POLITICAL_STATUS')">
-            <u--input v-model="form.POLITICAL_STATUS_NAME" border="none" disabled disabledColor="#ffffff">
+          <u-form-item label="政治面貌" prop="politicalStatusName" borderBottom required
+                       @click="singleChoiceClick('politicalStatus')">
+            <u--input v-model="form.politicalStatusName" border="none" disabled disabledColor="#ffffff">
             </u--input>
           </u-form-item>
         </view>
         <view>
-          <u-form-item v-if="form.POLITICAL_STATUS == 'zhonggongdangyuan'" label="入党时间" prop="POLITICAL_STATUS"
+          <u-form-item v-if="form.politicalStatus === 'zhonggongdangyuan'" label="入党时间" prop="POLITICAL_STATUS"
                        borderBottom required
-                       @click="fnShowDatePicke('POLITICAL_TIME')">
-            <u--input v-model="form.POLITICAL_TIME" border="none" disabled disabledColor="#ffffff">
+                       @click="fnShowDatePicke('politicalTime')">
+            <u--input v-model="form.politicalTime" border="none" disabled disabledColor="#ffffff">
             </u--input>
           </u-form-item>
         </view>
         <view>
-          <u-form-item label="是否缴纳社保" prop="IS_SOCIAL_NAME" borderBottom required
+          <u-form-item label="是否缴纳社保" prop="isSocialName" borderBottom required
                        @click="fnShowIsSocial">
-            <u--input v-model="form.IS_SOCIAL_NAME" border="none" disabled disabledColor="#ffffff"
+            <u--input v-model="form.isSocialName" border="none" disabled disabledColor="#ffffff"
                       inputAlign="right"></u--input>
           </u-form-item>
         </view>
         <view>
-          <u-form-item v-if="form.IS_SOCIAL==='1'" label="社会保障号码" prop="SOCIAL_NUMBER" borderBottom required>
-            <u--input border="none" v-model="form.SOCIAL_NUMBER"></u--input>
+          <u-form-item v-if="form.isSocial==='1'" label="社会保障号码" prop="SOCIAL_NUMBER" borderBottom required>
+            <u--input border="none" v-model="form.socialNumber"></u--input>
           </u-form-item>
         </view>
         <view>
-          <u-form-item v-if="form.IS_SOCIAL==='1'" label="社会保障卡" prop="socialPhotoFile" borderBottom required
+          <u-form-item v-if="form.isSocial==='1'" label="社会保障卡" prop="socialPhotoFile" borderBottom required
                        labelPosition="top" labelWidth="auto">
             <view class="mt-10 w100">
               <u-upload :fileList="form.socialPhotoFile" @afterRead="fnAttSocialAdd"
@@ -95,20 +94,20 @@
           </u-form-item>
         </view>
         <view>
-          <u-form-item label="是否缴纳保险" prop="IS_BF_NAME" borderBottom required @click="fnShowBf">
-            <u--input v-model="form.IS_BF_NAME" border="none" disabled disabledColor="#ffffff"
+          <u-form-item label="是否缴纳保险" prop="isBfName" borderBottom required @click="fnShowBf">
+            <u--input v-model="form.isBfName" border="none" disabled disabledColor="#ffffff"
                       inputAlign="right"></u--input>
           </u-form-item>
         </view>
         <view>
-          <u-form-item label="是否签订劳动合同" prop="IS_SIGN_LABOR_NAME" borderBottom required
+          <u-form-item label="是否签订劳动合同" prop="isSignLaborName" borderBottom required
                        @click="fnShowIsSignLabor">
-            <u--input v-model="form.IS_SIGN_LABOR_NAME" border="none" disabled disabledColor="#ffffff"
+            <u--input v-model="form.isSignLaborName" border="none" disabled disabledColor="#ffffff"
                       inputAlign="right"></u--input>
           </u-form-item>
         </view>
         <view>
-          <u-form-item v-if="form.IS_SIGN_LABOR==='1'" label="合同图片" prop="contractFile" borderBottom required
+          <u-form-item v-if="form.isSignLabor==='1'" label="合同图片" prop="contractFile" borderBottom required
                        labelPosition="top" labelWidth="auto">
             <view class="mt-10 w100">
               <u-upload :fileList="form.contractFile" @afterRead="fnIsSignLaborAdd"
@@ -117,18 +116,18 @@
           </u-form-item>
         </view>
         <view>
-          <u-form-item label="是否缴纳商业保险" prop="ISPAY_NAME" borderBottom required @click="fnShowIsPay">
-            <u--input v-model="form.ISPAY_NAME" border="none" disabled disabledColor="#ffffff"
+          <u-form-item label="是否缴纳商业保险" prop="ispayName" borderBottom required @click="fnShowIsPay">
+            <u--input v-model="form.ispayName" border="none" disabled disabledColor="#ffffff"
                       inputAlign="right"></u--input>
           </u-form-item>
         </view>
         <view>
-          <u-form-item v-if="form.ISPAY==='1'" label="商业保险单号" prop="ISPAY_NUMBER" borderBottom required>
-            <u--input border="none" v-model="form.ISPAY_NUMBER"></u--input>
+          <u-form-item v-if="form.ispay==='1'" label="商业保险单号" prop="ispayNumber" borderBottom required>
+            <u--input border="none" v-model="form.ispayNumber"></u--input>
           </u-form-item>
         </view>
         <view>
-          <u-form-item v-if="form.ISPAY==='1'" label="保险图片" prop="insuranceFile" borderBottom required
+          <u-form-item v-if="form.ispay==='1'" label="保险图片" prop="insuranceFile" borderBottom required
                        labelPosition="top" labelWidth="auto">
             <view class="mt-10 w100">
               <u-upload :fileList="form.insuranceFile" @afterRead="fnIsPayAdd" @delete="fnIsPayDelete"
@@ -137,22 +136,22 @@
           </u-form-item>
         </view>
         <view>
-          <u-form-item label="是否按期缴纳工伤保险" prop="IS_INJURIES_PAY_NAME" borderBottom required
+          <u-form-item label="是否按期缴纳工伤保险" prop="isInjuriesPayName" borderBottom required
                        @click="fnShowEmploymentInjuryInsurance">
-            <u--input v-model="form.IS_INJURIES_PAY_NAME" border="none" disabled disabledColor="#ffffff"
+            <u--input v-model="form.isInjuriesPayName" border="none" disabled disabledColor="#ffffff"
                       inputAlign="right"></u--input>
           </u-form-item>
         </view>
         <view>
-          <u-form-item label="工伤保险有效期" v-if="form.IS_INJURIES_PAY==='1'" prop="IS_INJURIES_PAY_TIME" borderBottom
+          <u-form-item label="工伤保险有效期" v-if="form.isInjuriesPay==='1'" prop="isInjuriesPayTime" borderBottom
                        required @click="fnShowInjuriesPayTiemEducation">
-            <u--input v-model="form.IS_INJURIES_PAY_TIME" border="none" disabled disabledColor="#ffffff"
+            <u--input v-model="form.isInjuriesPayTime" border="none" disabled disabledColor="#ffffff"
                       inputAlign="right"></u--input>
           </u-form-item>
         </view>
         <view>
           <u-form-item label="上传工伤保险凭证" prop="injuriesPayTiemFile" borderBottom required
-                       v-if="form.IS_INJURIES_PAY==='1'" labelPosition="top" labelWidth="auto">
+                       v-if="form.isInjuriesPay==='1'" labelPosition="top" labelWidth="auto">
             <view class="mt-10 w100">
               <u-upload :fileList="form.injuriesPayTiemFile"
                         @afterRead="fnInjuriesPayTiemAttachmentsAfterRead" @delete="fnInjuriesPayTiemAttachmentsDelete"
@@ -161,19 +160,19 @@
           </u-form-item>
         </view>
         <view>
-          <u-form-item label="岗位名称(工种)" prop="POST_ID" borderBottom required>
-            <u--textarea border="none" v-model="form.POST_ID" autoHeight></u--textarea>
+          <u-form-item label="岗位名称(工种)" prop="postId" borderBottom required>
+            <u--textarea border="none" v-model="form.postId" autoHeight></u--textarea>
           </u-form-item>
         </view>
         <view>
-          <u-form-item label="是否参加三级安全培训" prop="IS_LEVEL_THREE_NAME" borderBottom required
+          <u-form-item label="是否参加三级安全培训" prop="isLevelThreeName" borderBottom required
                        @click="fnShowPhotosOfLevel">
-            <u--input v-model="form.IS_LEVEL_THREE_NAME" border="none" disabled disabledColor="#ffffff"
+            <u--input v-model="form.isLevelThreeName" border="none" disabled disabledColor="#ffffff"
                       inputAlign="right"></u--input>
           </u-form-item>
         </view>
         <view>
-          <u-form-item v-if="form.IS_LEVEL_THREE === '1'" label="三级安全培训照片" prop="photosOfLevel" borderBottom
+          <u-form-item v-if="form.isLevelThree === '1'" label="三级安全培训照片" prop="photosOfLevel" borderBottom
                        required labelPosition="top" labelWidth="auto">
             <view class="mt-10 w100">
               <u-upload :fileList="form.photosOfLevel" @afterRead="fnPhotosOfLevelAdd"
@@ -182,13 +181,13 @@
             </view>
           </u-form-item>
         </view>
-        <u-form-item label="是否流动人员" prop="ISFLOW_NAME" borderBottom required
+        <u-form-item label="是否流动人员" prop="isflowName" borderBottom required
                      @click="fnShowFloatingPersonnel">
-          <u--input v-model="form.ISFLOW_NAME" border="none" disabled disabledColor="#ffffff"
+          <u--input v-model="form.isflowName" border="none" disabled disabledColor="#ffffff"
                     inputAlign="right"></u--input>
         </u-form-item>
       </u--form>
-      <u-picker ref="uPicker" :show="singleChoice" :columns="singleChoiceColumns" keyName="NAME"
+      <u-picker ref="uPicker" :show="singleChoice" :columns="singleChoiceColumns" keyName="name"
                 @confirm="fnSingleChoiceConfirm" @cancel="fnSingleChoiceCancel"></u-picker>
       <u-datetime-picker :show="datePicker" v-model="dateValue" mode="date" @confirm="fnDateConfirm"
                          @cancel="fnDateCancel"></u-datetime-picker>
@@ -219,16 +218,8 @@
 </template>
 
 <script>
-import {
-  getDataDictionary,
-  getIDCardDeduplication,
-  getPhoneNumberDeduplication,
-  getUserInfo,
-  removeUploadAttachments,
-  setUploadAttachments,
-  setUserInfo,
-  getEmployedBy
-} from "../../../api";
+import {getIDCardDeduplication, getPhoneNumberDeduplication,} from "../../../api/index";
+import {getDicLevel, getUserInfoV1, setUserInitV1, uploadFile} from "../../../api/api";
 
 export default {
   data() {
@@ -241,8 +232,8 @@ export default {
       dateValue: new Date().toString(),
       showIsSocial: false,
       showEmploymentInjuryInsurance: false,
-      injuriesPayTiemFile: [], //工伤保险有效凭证
-      showInjuriesPayTiem: false, //工伤保险有效期
+      injuriesPayTiemFile: [],
+      showInjuriesPayTiem: false,
       IS_INJURIES_PAY_TIME: new Date().toString(),
       EMPLOYMENT_APPLY_MANAGEMENT_ID: '',
 
@@ -256,49 +247,73 @@ export default {
       personWorkTypeColumns: [],
       prePhotoId: [],
       form: {
-        userPhoto: [],
+        xgfUserId:'',
+        userId: '',
+        userPhoto:[],
+        userCard:[],
+        socSecurity:[],
+        contract:[],
+        insurance:[],
+        empInsurance:[],
+        threeLevel:[],
+        userPhotoFile: [],
+        name: '',
+        sex:'',
+        sexName:'',
+        dateOfBirth:'',
+        age:'',
+        cardId:'',
         userCardIDPhotoFile: [],
+        nationalityName:'',
+        nationality:'',
+        hklocal:'',
+        address:'',
+        phone:'',
+        degreeOfEducationName: '',
+        degreeOfEducation: '',
+        maritalstatusName:'',
+        maritalstatus:'',
+        politicalStatusName:'',
+        politicalStatus:'',
+        politicalTime:'',
+        isSocialName:'',
+        isSocial:'',
+        socialNumber:'',
         socialPhotoFile: [],
-        contractFile: [],
-        injuriesPayTiemFile: [],
-        photosOfLevel: [],
+        isBfName:'',
+        isBf:'',
+        isSignLaborName:'',
+        isSignLabor:'',
+        contractFile:[],
+        ispayName:'',
+        ispay:'',
+        ispayNumber:'',
         insuranceFile: [],
-        IS_INJURIES_PAY_TIME: '',
-        NAME: '',
-        USERNAME: '',
-        SEX: '',
-        SEX_NAME: '',
-        DATE_OF_BIRTH: '',
-        AGE: '',
-        CARD_ID: '',
-        HKLOCAL: '',
-        ADDRESS: '',
-        PHONE: '',
-        DEGREE_OF_EDUCATION: '',
-        DEGREE_OF_EDUCATION_NAME: '',
-        SOCIAL_NUMBER: '',
-        ISFLOW: '',
-        ISFLOW_NAME: '',
-        IS_SOCIAL: '',
-        IS_SOCIAL_NAME: '',
-        IS_BF_NAME: '',
-        IS_BF: '',
-        IS_SIGN_LABOR: '',
-        IS_SIGN_LABOR_NAME: '',
-        POST_ID: '',
-        IS_LEVEL_THREE: '',
-        IS_LEVEL_THREE_NAME: '',
-        ISPAY: '',
-        ISPAY_NAME: ''
+        isInjuriesPayName:'',
+        isInjuriesPay:'',
+        isInjuriesPayTime:'',
+        injuriesPayTiemFile: [],
+        postId:'',
+        isLevelThreeName:'',
+        isLevelThree:'',
+        photosOfLevel: [],
+        isflowName:'',
+        isflow:'',
+        username: '',
+        departmentId:'',
+        emp:{},
+        userDetails:{},
+        deleteFileIds: [],
+        postMethod: 'application/json'
       },
       rules: {
-        userPhoto: {
+        userPhotoFile: {
           type: 'array',
           required: true,
           message: '请上传照片',
           trigger: ['change']
         },
-        NAME: {
+        name: {
           required: true,
           message: '请填写姓名',
           trigger: ['blur']
@@ -321,7 +336,7 @@ export default {
           message: '请上传社保卡正反照',
           trigger: ['change']
         },
-        CARD_ID: [{
+        cardId: [{
           required: true,
           message: '请填写身份证号',
           trigger: ['blur']
@@ -334,17 +349,17 @@ export default {
             trigger: ['blur'],
           },
         ],
-        HKLOCAL: {
+        hklocal: {
           required: true,
           message: '请填写户口所在地',
           trigger: ['blur']
         },
-        ADDRESS: {
+        address: {
           required: true,
           message: '请填写现住址',
           trigger: ['blur']
         },
-        PHONE: [{
+        phone: [{
           required: true,
           message: '请填写联系电话',
           trigger: ['blur']
@@ -357,43 +372,37 @@ export default {
             trigger: ['blur'],
           },
         ],
-        DEGREE_OF_EDUCATION_NAME: {
+        degreeOfEducationName: {
           required: true,
           message: '请选择文化程度',
           trigger: ['change']
         },
-        PERSON_WORK_TYPE: {
-          required: false,
-          message: '请选择工种',
-          trigger: ['change']
-        },
-        ISFLOW_NAME: {
+        isflowName: {
           required: true,
           message: '请选择是否为流动人员',
           trigger: ['change']
         },
-
-        IS_SOCIAL_NAME: {
+        isSocialName: {
           required: true,
           message: '请选择是否缴纳社保',
           trigger: ['change']
         },
-        IS_INJURIES_PAY_NAME: {
+        isInjuriesPayName: {
           required: true,
           message: '请选择是否按期缴纳工伤保险',
           trigger: ['change']
         },
-        IS_INJURIES_PAY_TIME: {
+        isInjuriesPayTime: {
           required: true,
           message: '请选择工伤保险有效期',
           trigger: ['change']
         },
-        IS_BF_NAME: {
+        isBfName: {
           required: true,
           message: '请选择是否是否缴纳保险',
           trigger: ['change']
         },
-        IS_SIGN_LABOR_NAME: {
+        isSignLaborName: {
           required: true,
           message: '请选择是否签订劳动合同',
           trigger: ['change']
@@ -410,7 +419,7 @@ export default {
           message: '请上传保险图片',
           trigger: ['change']
         },
-        POST_ID: {
+        postId: {
           required: true,
           message: '请填写岗位',
           trigger: ['change']
@@ -421,17 +430,102 @@ export default {
           message: '请上传三级安全培训照片',
           trigger: ['change']
         },
-        IS_LEVEL_THREE_NAME: {
+        isLevelThreeName: {
           required: true,
           message: '请选择是否为三级人员',
           trigger: ['change']
         },
-        ISPAY_NUMBER: {
+        ispayNumber: {
           required: true,
           message: '请填写商业保单号',
           trigger: ['change']
         },
-      }
+      },
+      emp: {
+        employmentApplyManagementId: "",
+        corpinfoId: "",
+        relevantUnitName: "",
+        startDate: "",
+        endDate: "",
+        leaveReason: "",
+        applyTime: "",
+        userId: "",
+        auditState: "",
+        departState: "",
+        reviewState: "",
+        departmentId: "",
+        remarks: "",
+        auditRemarks: "",
+        auditTime: "",
+        auditPerson: "",
+        corpStartDate: "",
+        postId: "",
+        entryDate: "",
+        isSignLabor: "0",
+        isInjuriesPay: "0",
+        socialNumber: "",
+        ispay: "0",
+        isLevelThree: "0",
+        isSafetyTell: "0",
+        isBodyAdapt: "0",
+        isSpecialJob: "0",
+        isflow: "0",
+        isSocial: "0",
+        socialType: "",
+        isBf: "0",
+      },
+      userDetails: {
+        userId: "",
+        name: "",
+        phone: "",
+        departState: "0",
+        personWorkType: "",
+        personWorkTypeName: "",
+        age: "",
+        hklocal: "",
+        address: "",
+        degreeOfEducation: "",
+        degreeOfEducationName: "",
+        corpStartDate: "",
+        postId: "",
+        postName: "",
+        workSign: "",
+        joinedDate: "",
+        workDate: "",
+        photo: "",
+        dateOfBirth: "",
+        ispay: "0",
+        ispayNumber: "",
+        isSafetyTell: "0",
+        isSafetyTime: "",
+        isInjuriesPay: "0",
+        isSignLabor: "0",
+        sex: "",
+        entryDate: "",
+        nationality: "",
+        nationalityName: "",
+        maritalstatus: "",
+        politicalTime: "",
+        politicalStatus: "",
+        politicalStatusName: "",
+        isInjuriesPayTime: "",
+        isLevelThree: "0",
+        isBodyAdapt: "0",
+        isSpecialJob: "0",
+        belongToCorp: "",
+        belongToCorpName: "",
+        corpinfoId: "",
+        cardId: "",
+        departmentId: "",
+        departmentName: "",
+        isSocial: "0",
+        isBf: "0",
+        socialNumber: "",
+        zzname: "",
+        annex: "",
+        attorney: "",
+        commitmentLetter: "",
+      },
     }
   },
   onLoad() {
@@ -447,14 +541,13 @@ export default {
       // 设置选中的就是第一个元素
       this.$refs.uPicker.setIndexs([0])
       this.changeFrom = changeFrom
-      if (changeFrom == 'NATIONALITY') this.fnGetDataDictionary('0a0e406f27f74ee698fe9979d25f62dd')
-      if (changeFrom == 'DEGREE_OF_EDUCATION') this.fnGetDataDictionary('d7d80f08d73a4accbccf4fd3d8d1d867')
-      if (changeFrom == 'MARITALSTATUS') this.singleChoiceColumns = [[{NAME: '已婚', BIANMA: '1'}, {
-        NAME: '未婚',
-        BIANMA: '0'
+      if (changeFrom === 'nationality') this.fnGetDataDictionary('0a0e406f27f74ee698fe9979d25f62dd')
+      if (changeFrom === 'degreeOfEducation') this.fnGetDataDictionary('d7d80f08d73a4accbccf4fd3d8d1d867')
+      if (changeFrom === 'maritalstatus') this.singleChoiceColumns = [[{name: '已婚', bianma: '1'}, {
+        name: '未婚',
+        bianma: '0'
       }]]
-      if (changeFrom == 'POLITICAL_STATUS') this.fnGetDataDictionary('6351efdd12dc4730952e5d195718e252')
-
+      if (changeFrom === 'politicalStatus') this.fnGetDataDictionary('6351efdd12dc4730952e5d195718e252')
       this.singleChoice = true
     },
     // 日期确认
@@ -471,8 +564,8 @@ export default {
       this.datePicker = true
     },
     fnSingleChoiceConfirm(event) {
-      this.$set(this.form, this.changeFrom, event.value[0].BIANMA)
-      this.$set(this.form, this.changeFrom + '_NAME', event.value[0].NAME)
+      this.$set(this.form, this.changeFrom, event.value[0].bianma)
+      this.$set(this.form, this.changeFrom + 'Name', event.value[0].name)
       this.singleChoice = false
     },
     fnSingleChoiceCancel() {
@@ -491,6 +584,7 @@ export default {
         content: '确定删除吗',
         success: async (res) => {
           if (res.confirm) {
+            console.log('?????')
             if (event.file.id) {
               // 准备删除的数据
               this.prePhotoId.push(event.file.id)
@@ -500,6 +594,7 @@ export default {
               duration: 2000
             });
             this.form.userCardIDPhotoFile.splice(event.index, 1)
+            this.form.deleteFileIds.push(event.file.id)
           } else if (res.cancel) {
           }
         }
@@ -526,6 +621,7 @@ export default {
               duration: 2000
             });
             this.form.socialPhotoFile.splice(event.index, 1)
+            this.form.deleteFileIds.push(event.file.id)
           } else if (res.cancel) {
             // console.log('用户点击取消');
           }
@@ -553,6 +649,7 @@ export default {
               duration: 2000
             });
             this.form.contractFile.splice(event.index, 1)
+            this.form.deleteFileIds.push(event.file.id)
           } else if (res.cancel) {
             // console.log('用户点击取消');
           }
@@ -580,6 +677,7 @@ export default {
               duration: 2000
             });
             this.form.insuranceFile.splice(event.index, 1)
+            this.form.deleteFileIds.push(event.file.id)
           } else if (res.cancel) {
             // console.log('用户点击取消');
           }
@@ -607,16 +705,17 @@ export default {
               duration: 2000
             });
             this.form.photosOfLevel.splice(event.index, 1)
+            this.form.deleteFileIds.push(event.file.id)
           } else if (res.cancel) {
             // console.log('用户点击取消');
           }
         }
       });
     },
-
-    async fnGetDataDictionary(DICTIONARIES_ID) {
-      let resData = await getDataDictionary({
-        DICTIONARIES_ID
+    async fnGetDataDictionary(dictionariesId) {
+      let resData = await getDicLevel({
+        dictionariesId:dictionariesId,
+        postMethod: 'application/json'
       })
       this.singleChoiceColumns = [resData.list]
     },
@@ -624,8 +723,8 @@ export default {
       this.showDegreeOfEducation = !this.showDegreeOfEducation
     },
     fnDegreeOfEducationConfirm(e) {
-      this.form.DEGREE_OF_EDUCATION = e.value[0].BIANMA
-      this.form.DEGREE_OF_EDUCATION_NAME = e.value[0].NAME
+      this.form.degreeOfEducation = e.value[0].bianma
+      this.form.degreeOfEducationName = e.value[0].name
       this.fnShowDegreeOfEducation()
     },
     fnShowPersonWorkType() {
@@ -644,51 +743,49 @@ export default {
       this.showIsPay = !this.showIsPay
     },
     fnShowIsPayConfirm(e) {
-      this.form.ISPAY = e.value[0].id
-      this.form.ISPAY_NAME = e.value[0].name
+      this.form.ispay = e.value[0].id
+      this.form.ispayNumber = e.value[0].name
       this.fnShowIsPay()
     },
     fnShowPhotosOfLevel() {
       this.showPhotosOfLevel = !this.showPhotosOfLevel
     },
     fnShowPhotosOfLevelConfirm(e) {
-      this.form.IS_LEVEL_THREE = e.value[0].id
-      this.form.IS_LEVEL_THREE_NAME = e.value[0].name
+      this.form.isLevelThree = e.value[0].id
+      this.form.isLevelThreeName = e.value[0].name
       this.fnShowPhotosOfLevel()
     },
     fnFloatingPersonnelConfirm(e) {
-      this.form.ISFLOW = e.value[0].id
-      this.form.ISFLOW_NAME = e.value[0].name
+      this.form.isflow = e.value[0].id
+      this.form.isflowName = e.value[0].name
       this.fnShowFloatingPersonnel()
     },
     fnBFConfirm(e) {
-      this.form.IS_BF = e.value[0].id
-      this.form.IS_BF_NAME = e.value[0].name
+      this.form.isBf = e.value[0].id
+      this.form.isBfName = e.value[0].name
       this.fnShowBf()
     },
     fnIsSignLaborConfirm(e) {
-      this.form.IS_SIGN_LABOR = e.value[0].id
-      this.form.IS_SIGN_LABOR_NAME = e.value[0].name
+      this.form.isSignLabor = e.value[0].id
+      this.form.isSignLaborName = e.value[0].name
       this.fnShowIsSignLabor()
     },
     fnShowIsSocial() {
       this.showIsSocial = !this.showIsSocial
     },
     fnIsSocialConfirm(e) {
-      this.form.IS_SOCIAL = e.value[0].id
-      this.form.IS_SOCIAL_NAME = e.value[0].name
+      this.form.isSocial = e.value[0].id
+      this.form.isSocialName = e.value[0].name
       this.fnShowIsSocial()
     },
-
     fnShowEmploymentInjuryInsurance() {
       this.showEmploymentInjuryInsurance = !this.showEmploymentInjuryInsurance
     },
     fnEmploymentInjuryInsuranceConfirm(e) {
-      this.form.IS_INJURIES_PAY = e.value[0].id
-      this.form.IS_INJURIES_PAY_NAME = e.value[0].name
+      this.form.isInjuriesPay = e.value[0].id
+      this.form.isInjuriesPayName = e.value[0].name
       this.fnShowEmploymentInjuryInsurance()
     },
-
     //工伤保险有效 凭证
     fnInjuriesPayTiemAttachmentsAfterRead(event) {
       for (let i = 0; i < event.file.length; i++) {
@@ -709,24 +806,23 @@ export default {
               duration: 2000
             });
             this.form.injuriesPayTiemFile.splice(event.index, 1)
+            this.form.deleteFileIds.push(event.file.id)
           } else if (res.cancel) {
             // console.log('用户点击取消');
           }
         }
       });
     },
-
     //工伤保险有效期 IS_INJURIES_PAY_TIME  InjuriesPayTiem
     fnShowInjuriesPayTiemEducation() {
       this.showInjuriesPayTiem = !this.showInjuriesPayTiem
     },
     fnShowInjuriesPayTiemConfirm(event) {
-      this.IS_INJURIES_PAY_TIME = event.value
+      this.form.isInjuriesPayTime = event.value
       this.fnShowInjuriesPayTiemEducation()
-      this.form.IS_INJURIES_PAY_TIME = uni.$u.timeFormat(event.value, 'yyyy-mm-dd')
+      this.form.isInjuriesPayTime = uni.$u.timeFormat(event.value, 'yyyy-mm-dd')
     },
-
-    async fnIDCardDeduplication(CARD_ID = this.form.CARD_ID) {
+    async fnIDCardDeduplication(CARD_ID = this.form.cardId) {
       let resData = await getIDCardDeduplication({
         CARD_ID
       })
@@ -736,7 +832,7 @@ export default {
       }
       return false
     },
-    async fnPhoneNumberDeduplication(PHONE = this.form.PHONE) {
+    async fnPhoneNumberDeduplication(PHONE = this.form.phone) {
       if (uni.$u.test.mobile(PHONE)) {
         let resData = await getPhoneNumberDeduplication({
           PHONE
@@ -751,14 +847,14 @@ export default {
     async fnCardIdDisassembly(event) {
       if (uni.$u.test.idCard(event)) {
         await this.fnIDCardDeduplication()
-        this.form.DATE_OF_BIRTH = event.substring(6, 10) + "-" + event.substring(10, 12) + "-" + event
+        this.form.dateOfBirth = event.substring(6, 10) + "-" + event.substring(10, 12) + "-" + event
             .substring(12, 14);
         if (parseInt(event.substring(17, 1)) % 2 === 1) {
-          this.form.SEX = "0";
-          this.form.SEX_NAME = "男";
+          this.form.sex = "0";
+          this.form.sexName = "男";
         } else {
-          this.form.SEX = "1";
-          this.form.SEX_NAME = "女";
+          this.form.sex = "1";
+          this.form.sexName = "女";
         }
         this.$forceUpdate()
         let myDate = new Date();
@@ -769,149 +865,121 @@ export default {
             14) <= day) {
           age++;
         }
-        this.form.AGE = age;
+        this.form.age = age;
       }
     },
     async fnGetData() {
-      //根据userId获取
-      let Employed = await getEmployedBy({
-        showCount: 10,
-        currentPage: 1,
-        DEPART_STATE: '0'
-      })
-      if (Employed.varList.length > 0) {
-        Employed.varList.forEach(item => {
-          console.log(item.EMPLOYMENT_APPLY_MANAGEMENT_ID);
-          this.EMPLOYMENT_APPLY_MANAGEMENT_ID = item.EMPLOYMENT_APPLY_MANAGEMENT_ID
-        })
-      }
-      console.log(this.EMPLOYMENT_APPLY_MANAGEMENT_ID);
-      let resData = await getUserInfo({
-        CORPINFO_ID: this.userInfo.CORPINFO_ID,
-        EMPLOYMENT_APPLY_MANAGEMENT_ID: this.EMPLOYMENT_APPLY_MANAGEMENT_ID
-      })
-      console.log(resData);
-      this.form = {
-        ...this.form,
-        ...resData.pd
-      }
-      this.form.PHONE = this.form.USERNAME
-      this.fnCardIdDisassembly(this.form.CARD_ID)
-      if (this.form.IS_SOCIAL === '1') {
-        this.form.IS_SOCIAL_NAME = '是'
-      } else {
-        this.form.IS_SOCIAL_NAME = '否'
-      }
-      if (this.form.IS_INJURIES_PAY === '1') {
-        this.form.IS_INJURIES_PAY_NAME = '是'
-      } else {
-        this.form.IS_INJURIES_PAY_NAME = '否'
-      }
-      if (this.form.SEX_NAME === '0') {
-        this.form.SEX_NAME = '男'
-      } else if (this.form.SEX_NAME === '1') {
-        this.form.SEX_NAME = '女'
-      }
-      if (this.form.ISFLOW === '1') {
-        this.form.ISFLOW_NAME = '是'
-      } else {
-        this.form.ISFLOW_NAME = '否'
-      }
-
-      if (this.form.ISPAY === '1') {
-        this.form.ISPAY_NAME = '是'
-      } else {
-        this.form.ISPAY_NAME = '否'
-      }
-
-      if (this.form.IS_LEVEL_THREE === '1') {
-        this.form.IS_LEVEL_THREE_NAME = '是'
-      } else {
-        this.form.IS_LEVEL_THREE_NAME = '否'
-      }
-
-      if (this.form.IS_BF === '1') {
-        this.form.IS_BF_NAME = '是'
-      } else {
-        this.form.IS_BF_NAME = '否'
-      }
-      if (this.form.IS_SIGN_LABOR === '1') {
-        this.form.IS_SIGN_LABOR_NAME = '是'
-      } else {
-        this.form.IS_SIGN_LABOR_NAME = '否'
-      }
-
-      if (resData.userPhotoFile.length > 0) {
-        this.$set(this.form, 'userPhoto', [{
-          url: this.$filePath + resData.userPhotoFile[0].FILEPATH,
-          FILEPATH: this.$filePath + resData.userPhotoFile[0].FILEPATH
-        }])
-      }
-      if (resData.userCardIDPhotoFile.length > 0) {
-        resData.userCardIDPhotoFile.forEach(item => {
-          const obj = {
-            id: item.IMGFILES_ID,
-            url: this.$filePath + item.FILEPATH
+      let data = await getUserInfoV1(
+          {
+            id: this.$store.getters.getUserInfo.USER_ID,
+            postMethod: 'application/json'
           }
-          this.form.userCardIDPhotoFile.push(obj)
+      )
+      this.form.xgfUserId = data.info.userId
+      this.form.userId = data.info.userId
+      this.form.postId = data.info.userDetails.postId
+      this.form.postName = data.info.userDetails.postName
+      this.form.name = data.info.userDetails.name
+      this.form.username = data.info.username
+      this.form.departmentId = data.info.userDetails.departmentId
+      if (data.info.userPhotoInfo.length > 0) {
+        this.form.userPhotoFile.push({
+          id: data.info.userPhotoInfo[0].imgfilesId,
+          url: this.$filePath + data.info.userPhotoInfo[0].filepath,
         })
       }
-      if (resData.socialPhotoFile.length > 0) {
-        resData.socialPhotoFile.forEach(item => {
-          const obj = {
-            id: item.IMGFILES_ID,
-            url: this.$filePath + item.FILEPATH
-          }
-          this.form.socialPhotoFile.push(obj)
-        })
+      this.form.maritalstatus = data.info.userDetails.maritalstatus
+      this.form.dateOfBirth = data.info.userDetails.dateOfBirth
+      this.form.age = data.info.userDetails.age
+      this.form.sexName = data.info.userDetails.sex === '0' ? '男' : '女'
+      this.form.cardId = data.info.userDetails.cardId
+      if (data.info.userCardInfo.length > 0) {
+        for (let i = 0; i < data.info.userCardInfo.length; i++){
+          this.form.userCardIDPhotoFile.push({
+            id: data.info.userCardInfo[i].imgfilesId,
+            url: this.$filePath + data.info.userCardInfo[i].filepath
+          })
+        }
       }
-      if (resData.workInsurancePhotoFile.length > 0) {
-        resData.workInsurancePhotoFile.forEach(item => {
-          const obj = {
-            id: item.IMGFILES_ID,
-            url: this.$filePath + item.FILEPATH
-          }
-          this.form.injuriesPayTiemFile.push(obj)
-        })
+      this.form.nationalityName = data.info.userDetails.nationalityName
+      this.form.nationality = data.info.userDetails.nationality
+      this.form.hklocal = data.info.userDetails.hklocal
+      this.form.address = data.info.userDetails.address
+      this.form.phone = data.info.userDetails.phone
+      this.form.degreeOfEducationName = data.info.userDetails.degreeOfEducationName
+      this.form.degreeOfEducation = data.info.userDetails.degreeOfEducation
+      this.form.maritalstatusName = data.info.userDetails.maritalstatus === '1'?'已婚':'未婚'
+      this.form.politicalStatusName = data.info.userDetails.politicalStatusName
+      this.form.politicalStatus = data.info.userDetails.politicalStatus
+      this.form.isSocial = data.info.userDetails.isSocial
+      this.form.socialNumber = data.info.userDetails.socialNumber
+      this.form.isSocialName = data.info.userDetails.isSocial === '1'?'是':'否'
+      if (data.info.socSecurityInfo.length > 0){
+        for (let i = 0; i < data.info.socSecurityInfo.length; i++) {
+          this.form.socialPhotoFile.push({
+            id: data.info.socSecurityInfo[i].imgfilesId,
+            url: this.$filePath + data.info.socSecurityInfo[i].filepath
+          })
+        }
       }
-      if (resData.photosOfLevel.length > 0) {
-        resData.photosOfLevel.forEach(item => {
-          const obj = {
-            id: item.IMGFILES_ID,
-            url: this.$filePath + item.FILEPATH
-          }
-          this.form.photosOfLevel.push(obj)
-        })
+      this.form.isBf = data.info.userDetails.isBf
+      this.form.isBfName = data.info.userDetails.isBf === '1'?'是':'否'
+      this.form.isSignLabor = data.info.userDetails.isSignLabor
+      this.form.isSignLaborName = data.info.userDetails.isSignLabor === '1'?'是':'否'
+      if (data.info.contractInfo.length > 0){
+        for (let i = 0; i < data.info.contractInfo.length; i++) {
+          this.form.contractFile.push({
+            id: data.info.contractInfo[i].imgfilesId,
+            url: this.$filePath + data.info.contractInfo[i].filepath
+          })
+        }
       }
-      if (resData.contractFile.length > 0) {
-        resData.contractFile.forEach(item => {
-          const obj = {
-            id: item.IMGFILES_ID,
-            url: this.$filePath + item.FILEPATH
-          }
-          this.form.contractFile.push(obj)
-        })
+      this.form.ispay = data.info.userDetails.ispay
+      this.form.ispayName = data.info.userDetails.ispay === '1'?'是':'否'
+      this.form.ispayNumber = data.info.userDetails.ispayNumber
+      if (data.info.insuranceInfo.length > 0){
+        for (let i = 0; i < data.info.insuranceInfo.length; i++) {
+          this.form.insuranceFile.push({
+            id: data.info.insuranceInfo[i].imgfilesId,
+            url: this.$filePath + data.info.insuranceInfo[i].filepath
+          })
+        }
       }
-      if (resData.insuranceFile.length > 0) {
-        resData.insuranceFile.forEach(item => {
-          const obj = {
-            id: item.IMGFILES_ID,
-            url: this.$filePath + item.FILEPATH
-          }
-          this.form.insuranceFile.push(obj)
-        })
+      this.form.isInjuriesPay = data.info.userDetails.isInjuriesPay
+      this.form.isInjuriesPayName = data.info.userDetails.isInjuriesPay === '1'?'是':'否'
+      this.form.isInjuriesPayTime = data.info.userDetails.isInjuriesPayTime
+      if (data.info.empInsuranceInfo.length > 0){
+        for (let i = 0; i < data.info.empInsuranceInfo.length; i++) {
+          this.form.injuriesPayTiemFile.push({
+            id: data.info.empInsuranceInfo[i].imgfilesId,
+            url: this.$filePath + data.info.empInsuranceInfo[i].filepath
+          })
+        }
       }
+      this.form.isLevelThree = data.info.userDetails.isLevelThree
+      this.form.isLevelThreeName = data.info.userDetails.isLevelThree === '1'?'是':'否'
+      if (data.info.threeLevelInfo.length > 0){
+        for (let i = 0; i < data.info.threeLevelInfo.length; i++) {
+          this.form.photosOfLevel.push({
+            id: data.info.threeLevelInfo[i].imgfilesId,
+            url: this.$filePath + data.info.threeLevelInfo[i].filepath
+          })
+        }
+      }
+      this.form.isflowName = data.info.emp.isflow === '1'?'是':'否'
+      this.form.deleteFileIds = []
     },
     fnAfterRead(event) {
-      this.form.userPhoto.push(event.file)
+      this.form.userPhotoFile.push(event.file)
     },
     fnDeletePic(event) {
-      this.form.userPhoto.splice(event.index, 1)
+      console.log(event)
+      this.form.userPhotoFile.splice(event.index, 1)
+      this.form.deleteFileIds.push(event.file.id)
     },
-    fnSubmit() {
+    async fnSubmit() {
       this.$refs.form.validate().then(async () => {
-        //校验社保和工伤保险必须有一个选是
-        if (this.form.IS_INJURIES_PAY === '0' && this.form.IS_SOCIAL === '0') {
+        if (this.form.isSocial === '0' && this.form.isSocial === '0') {
           uni.$u.toast('工商或社保全无人员,不可进入本系统相关方人员管理!');
           return;
         }
@@ -921,117 +989,89 @@ export default {
           uni.$u.toast('身份证照片需要两张')
           return
         }
-        if (this.form.IS_SOCIAL === '1') {
+        if (this.form.isSocial === '1') {
           if (this.form.socialPhotoFile.length !== 2) {
             uni.$u.toast('社保卡照片需要两张')
             return
           }
         }
-        let fileUrl = ''
-        // 删除点击删除的图片
-        for (let i = 0; i < this.prePhotoId.length; i++) {
-          await removeUploadAttachments({
-            IMGFILES_ID: this.prePhotoId[i]
-          })
-        }
-        // 保存图片
-        for (let i = 0; i < this.form.userPhoto.length; i++) {
-          if (!this.form.userPhoto[i].FILEPATH) {
-            let resData = await setUploadAttachments({
-              filePath: this.form.userPhoto[i].url,
-              name: 'files',
-              formData: {
-                TYPE: '13',
-                FOREIGN_KEY: this.userInfo.USER_ID,
-                CORPINFO_ID: this.userInfo.CORPINFO_ID,
-              }
-            })
-            fileUrl = resData.filePath
-          }
-        }
-        for (let i = 0; i < this.form.userCardIDPhotoFile.length; i++) {
-          await setUploadAttachments({
-            filePath: this.form.userCardIDPhotoFile[i].url,
-            name: 'files',
-            formData: {
-              TYPE: '14',
-              FOREIGN_KEY: this.userInfo.USER_ID,
-              CORPINFO_ID: this.userInfo.CORPINFO_ID,
-            }
-          })
-        }
-        for (let i = 0; i < this.form.socialPhotoFile.length; i++) {
-          await setUploadAttachments({
-            filePath: this.form.socialPhotoFile[i].url,
-            name: 'files',
-            formData: {
-              TYPE: '15',
-              FOREIGN_KEY: this.userInfo.USER_ID,
-              CORPINFO_ID: this.userInfo.CORPINFO_ID,
-            }
-          })
-        }
-        for (let i = 0; i < this.form.injuriesPayTiemFile.length; i++) {
-          await setUploadAttachments({
-            filePath: this.form.injuriesPayTiemFile[i].url,
-            name: 'files',
-            formData: {
-              TYPE: '16',
-              FOREIGN_KEY: this.form.EMPLOYMENT_APPLY_MANAGEMENT_ID,
-              CORPINFO_ID: this.userInfo.CORPINFO_ID,
-            }
-          })
-        }
-        for (let i = 0; i < this.form.photosOfLevel.length; i++) {
-          await setUploadAttachments({
-            filePath: this.form.photosOfLevel[i].url,
-            name: 'files',
-            formData: {
-              TYPE: '19',
-              FOREIGN_KEY: this.form.EMPLOYMENT_APPLY_MANAGEMENT_ID,
-              CORPINFO_ID: this.userInfo.CORPINFO_ID,
-            }
-          })
-        }
-        for (let i = 0; i < this.form.contractFile.length; i++) {
-          await setUploadAttachments({
-            filePath: this.form.contractFile[i].url,
-            name: 'files',
-            formData: {
-              TYPE: '10',
-              FOREIGN_KEY: this.form.EMPLOYMENT_APPLY_MANAGEMENT_ID,
-              CORPINFO_ID: this.userInfo.CORPINFO_ID,
-            }
-          })
-        }
-        for (let i = 0; i < this.form.insuranceFile.length; i++) {
-          await setUploadAttachments({
-            filePath: this.form.insuranceFile[i].url,
-            name: 'files',
-            formData: {
-              TYPE: '11',
-              FOREIGN_KEY: this.form.EMPLOYMENT_APPLY_MANAGEMENT_ID,
-              CORPINFO_ID: this.userInfo.CORPINFO_ID,
-            }
-          })
+        // 头像
+        this.form.userPhoto = Array.from(await this.uploadFiles(this.form.userPhotoFile, 3));
+        // 身份证
+        this.form.userCard = Array.from(await this.uploadFiles(this.form.userCardIDPhotoFile, 3));
+        // 社保照片
+        this.form.socSecurity = Array.from(await this.uploadFiles(this.form.socialPhotoFile, 3));
+        // 劳动合同图片
+        this.form.contract = Array.from(await this.uploadFiles(this.form.contractFile, 3));
+        // 保险图片
+        this.form.insurance = Array.from(await this.uploadFiles(this.form.insuranceFile, 3));
+        // 工商保险
+        this.form.empInsurance = Array.from(await this.uploadFiles(this.form.injuriesPayTiemFile, 3));
+        // 三级培训照片
+        this.form.threeLevel = Array.from(await this.uploadFiles(this.form.threeLevel, 3));
+        // 就职信息更新
+        this.form.emp = JSON.parse(JSON.stringify(this.emp));
+        this.form.emp.departmentId = this.form.departmentId;
+        this.form.emp.isSignLabor = this.form.isSignLabor;
+        this.form.emp.isInjuriesPay = this.form.isInjuriesPay;
+        this.form.emp.socialNumber = this.form.socialNumber;
+        this.form.emp.ispay = this.form.ispay;
+        this.form.emp.isLevelThree = this.form.isLevelThree;
+        this.form.emp.isSocial = this.form.isSocial;
+        this.form.emp.isBf = this.form.isBf;
+        this.form.emp.isflow = this.form.isflow;
+        this.form.emp.postId = this.form.postId;
+        this.form.emp.postName = this.form.postId;
+        // 用户信息更新
+        this.form.userDetails = JSON.parse(JSON.stringify(this.userDetails));
+        this.form.userDetails.name = this.form.name;
+        this.form.userDetails.phone = this.form.username;
+        this.form.userDetails.age = this.form.age;
+        this.form.userDetails.hklocal = this.form.hklocal;
+        this.form.userDetails.address = this.form.address;
+        this.form.userDetails.degreeOfEducation = this.form.degreeOfEducation;
+        this.form.userDetails.degreeOfEducationName = this.form.degreeOfEducationName;
+        if (this.form.userPhoto && this.form.userPhoto.length > 0) {
+          this.form.userDetails.photo = this.form.userPhoto[0];
         }
+        this.form.userDetails.dateOfBirth = this.form.dateOfBirth;
+        this.form.userDetails.ispay = this.form.ispay;
+        this.form.userDetails.ispayNumber = this.form.ispayNumber;
+        this.form.userDetails.isInjuriesPay = this.form.isInjuriesPay;
+        this.form.userDetails.isSignLabor = this.form.isSignLabor;
+        this.form.userDetails.sex = this.form.sex;
+        this.form.userDetails.nationality = this.form.nationality;
+        this.form.userDetails.nationalityName = this.form.nationalityName;
+        this.form.userDetails.maritalstatus = this.form.maritalstatus;
+        this.form.userDetails.politicalTime = this.form.politicalTime;
+        this.form.userDetails.politicalStatus = this.form.politicalStatus;
+        this.form.userDetails.politicalStatusName = this.form.politicalStatusName;
+        this.form.userDetails.isInjuriesPayTime = this.form.isInjuriesPayTime;
+        this.form.userDetails.isLevelThree = this.form.isLevelThree;
+        this.form.userDetails.isSpecialJob = this.form.isSpecialJob;
+        this.form.userDetails.cardId = this.form.cardId;
+        this.form.userDetails.isLevelThree = this.form.isLevelThree;
+        this.form.userDetails.isSocial = this.form.isSocial;
+        this.form.userDetails.isBf = this.form.isBf;
+        this.form.userDetails.socialNumber = this.form.socialNumber;
+        this.form.userDetails.postId = this.form.postId;
+        this.form.userDetails.postName = this.form.postId;
         // 保存人员信息
-        await setUserInfo({
-          ...this.form,
-          PHOTO: fileUrl
-        })
-        let result = await getUserInfo({
-          CORPINFO_ID: this.userInfo.CORPINFO_ID,
-          USER_ID: this.userInfo.USER_ID,
+        await setUserInitV1(this.form)
+        // 更新token
+        let result = await getUserInfoV1({
+          id: this.$store.getters.getUserInfo.USER_ID,
+          postMethod: 'application/json'
         })
+        let photo = result.info.userPhotoInfo[0].filepath
         await this.$store.dispatch('setUserInfo', {
-          CORPINFO_ID: result.pd.CORPINFO_ID,
-          DEPARTMENT_ID: result.pd.DEPARTMENT_ID,
-          NAME: result.pd.NAME,
-          USERNAME: result.pd.USERNAME,
-          USER_ID: result.pd.USER_ID,
-          PHOTO: this.$filePath + result.pd.PHOTO,
-          userPhoto: this.$filePath + result.pd.PHOTO,
+          CORPINFO_ID: result.info.corpinfoId,
+          DEPARTMENT_ID: result.info.departmentId,
+          NAME: result.info.name,
+          USERNAME: result.info.username,
+          USER_ID: result.info.userId,
+          PHOTO: this.$filePath + photo,
+          userPhoto: this.$filePath + photo,
           token: this.userInfo.token
         })
         uni.$u.toast('保存成功')
@@ -1044,13 +1084,30 @@ export default {
           uni.navigateBack()
         }, 2000)
       }).catch((e) => {
-        if (e.result == 'out') {
+        if (e.result === 'out') {
           uni.$u.toast(e.msg)
         } else {
           console.log(e)
           uni.$u.toast('请补全必填项')
         }
       })
+    },
+    async uploadFiles(list, type){
+      const res = [];
+      for (let i = 0; i < list.length; i++) {
+        if (!list[i].id) {
+          const req = await uploadFile({
+            filePath: list[i].url,
+            name: 'file',
+            formData: {
+              type: type,
+              uuid: Math.random()
+            }
+          });
+          res.push(req.path);
+        }
+      }
+      return res;
     }
   },
 }
diff --git a/utils/request.js b/utils/request.js
index 005c26c..5a9df20 100644
--- a/utils/request.js
+++ b/utils/request.js
@@ -1,4 +1,6 @@
-let requestPath = 'http://192.168.0.104:8059/xgf_gwj'; // 后台请求地址
+import refreshToken from "../api/refreshToken";
+
+let requestPath = 'http://192.168.0.102:8059/xgf_gwj_2.0/'; // 后台请求地址
 // let requestPath = 'https://skqhdg.porthebei.com:9006/qa-prevention-xgf/'; // 后台请求地址
 // let requestPath = 'https://qgxgf.qhdsafety.com/qa-prevention-xgf/'; // 外网地址
 import store from '../store/index'
@@ -35,6 +37,7 @@ function post(url, data) {
                     uni.hideLoading();
                 }
                 if (res.data.result === 'success') {
+                    refreshToken()
                     resolve(res.data)
                 } else {
                     uni.showToast({
diff --git a/utils/tools.js b/utils/tools.js
index 7290a38..f4f6997 100644
--- a/utils/tools.js
+++ b/utils/tools.js
@@ -22,9 +22,9 @@ export function formatDate(date, fmt) {
   }
 }
 
-//export const filePath = 'http://192.168.192.201:8991/file/'
+export const filePath = 'http://192.168.192.201:8991/file/'
 //export const filePath = 'https://qgqy.qhdsafety.com/file/'
-export const filePath = 'https://wwag.qhdsafety.com/file/'
+// export const filePath = 'https://wwag.qhdsafety.com/file/'
 
 function padLeftZero(str) {
   return ('00' + str).substr(str.length)