luoyb
2024-04-06 18b6eb51898598c25c0873c145e7bbec65c048df
feat: 信息录入的合同信息中的性别使用数据字典下拉选择
8个文件已修改
260 ■■■■ 已修改文件
package.json 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/utils/myUtil.js 32 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/user/Informationinput.vue 12 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/user/archivesChange.vue 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/user/archivesEdit.vue 189 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/user/inemployees.vue 11 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/user/outemployess.vue 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
vue.config.js 3 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
package.json
@@ -10,7 +10,8 @@
    "package": "vue-cli-service build",
    "preview": "node build/index.js --preview",
    "lint": "eslint --ext .js,.vue src",
    "svgo": "svgo -f src/icons/svg --config=src/icons/svgo.yml"
    "svgo": "svgo -f src/icons/svg --config=src/icons/svgo.yml",
    "test": "vue-cli-service serve --mode test"
  },
  "husky": {
    "hooks": {
src/utils/myUtil.js
@@ -93,6 +93,38 @@
    case 'y':
      iReturn = Math.floor(dateSpan / (365 * 24 * 3600 * 1000))
      break
    case 'o':
      var sDate = new Date(begin)
      var eDate = new Date(end)
      // 获得各自的年、月、日
      var sY = sDate.getFullYear()
      var sM = sDate.getMonth() + 1
      var sD = sDate.getDate()
      var eY = eDate.getFullYear()
      var eM = eDate.getMonth() + 1
      var eD = eDate.getDate()
      // var flagD = 0
      var flagM = 0
      var flagY = 0
      // var months = 0
      var d = eD - sD
      if (d > 0 && d >= 15) {
        flagM = 1
      }
      if (d < 0 && 30 + d < 15) {
        flagM = -1
      }
      var m = eM + flagM - sM
      if (m < 0) {
        flagY = -1
        m = 12 + m
      }
      var y = eY + flagY - sY
      iReturn = y + '年' + m + '月'
  }
  return iReturn
}
src/views/user/Informationinput.vue
@@ -1138,7 +1138,15 @@
              />
            </el-form-item>
            <el-form-item label="性别" prop="sex">
              <el-input v-model="contractInfoForm.sex" />
<!--              <el-input v-model="contractInfoForm.sex" />-->
              <el-select v-model="contractInfoForm.sex" placeholder="请选择性别">
                <el-option
                  v-for="dict in sexOptions"
                  :key="dict.dicItemCode"
                  :label="dict.dicItemName"
                  :value="dict.dicItemCode"
                />
              </el-select>
            </el-form-item>
            <el-form-item label="合同签订日期" prop="signingDate">
              <el-date-picker
@@ -3861,7 +3869,7 @@
              // 起始日期有,进行判断
              if (this.compareDate(this.contractInfoForm.signingDate, value)) {
                // 如果起始在结束之前
                this.contractInfoForm.contractPeriod = dateDifference(this.contractInfoForm.signingDate, this.contractInfoForm.endDate, 'y')
                this.contractInfoForm.contractPeriod = dateDifference(this.contractInfoForm.signingDate, this.contractInfoForm.endDate, 'o')
                callback()
              } else {
                callback(new Error('结束日期不能在开始始日期之前,请重新选择'))
src/views/user/archivesChange.vue
@@ -657,7 +657,7 @@
                    <span v-text="getIndex(scope.$index)" />
                  </template>
                </el-table-column>
                <el-table-column show-overflow-tooltip prop="newDeptName" label="现部门" />
                <el-table-column show-overflow-tooltip prop="allDeptName" label="现部门" />
                <el-table-column show-overflow-tooltip prop="newJobName" label="现岗位" />
                <el-table-column show-overflow-tooltip prop="empName" label="姓名" width="180" />
                <el-table-column show-overflow-tooltip prop="oldDeptName" label="原部门" />
src/views/user/archivesEdit.vue
@@ -222,7 +222,9 @@
                <el-row style="width: 100%;">
                  <el-col :span="8">
                    <el-form-item label="编号" prop="empNumb">
                      <el-input v-model="empBaseInfoForm.empNumb" style="width: 100%;" :disabled="readon ? false : true" />
                      <el-input v-model="empBaseInfoForm.empNumb" style="width: 100%;"
                                :disabled="readon ? false : true"
                      />
                    </el-form-item>
                  </el-col>
                  <el-col :span="8">
@@ -244,7 +246,9 @@
                <el-row>
                  <el-col :span="8">
                    <el-form-item label="性别" prop="sex">
                      <el-select v-model="empBaseInfoForm.sex" placeholder="请选择性别" :disabled="readon ? false : true">
                      <el-select v-model="empBaseInfoForm.sex" placeholder="请选择性别"
                                 :disabled="readon ? false : true"
                      >
                        <el-option
                          v-for="dict in sexOptions"
                          :key="dict.dicItemCode"
@@ -284,7 +288,9 @@
                <el-row>
                  <el-col :span="8">
                    <el-form-item label="员工类别" prop="empType">
                      <el-select v-model="empBaseInfoForm.empType" placeholder="请选择员工类型" :disabled="readon ? false : true">
                      <el-select v-model="empBaseInfoForm.empType" placeholder="请选择员工类型"
                                 :disabled="readon ? false : true"
                      >
                        <el-option
                          v-for="dict in empTypeOptions"
                          :key="dict.dicItemCode"
@@ -296,7 +302,9 @@
                  </el-col>
                  <el-col :span="8">
                    <el-form-item label="民族" prop="nation">
                      <el-select v-model="empBaseInfoForm.nation" filterable placeholder="请选择民族" :disabled="readon ? false : true">
                      <el-select v-model="empBaseInfoForm.nation" filterable placeholder="请选择民族"
                                 :disabled="readon ? false : true"
                      >
                        <el-option
                          v-for="dict in nationOptions"
                          :key="dict.dicItemCode"
@@ -316,7 +324,9 @@
                <el-row>
                  <el-col :span="8">
                    <el-form-item label="婚姻状态" prop="marriage">
                      <el-select v-model="empBaseInfoForm.marriage" placeholder="请选择婚姻状态" :disabled="readon ? false : true">
                      <el-select v-model="empBaseInfoForm.marriage" placeholder="请选择婚姻状态"
                                 :disabled="readon ? false : true"
                      >
                        <el-option
                          v-for="dict in marriageOptions"
                          :key="dict.dicItemCode"
@@ -347,7 +357,9 @@
                <el-row>
                  <el-col :span="8">
                    <el-form-item label="政治面貌" prop="politics">
                      <el-select v-model="empBaseInfoForm.politics" placeholder="请选择政治面貌" :disabled="readon ? false : true">
                      <el-select v-model="empBaseInfoForm.politics" placeholder="请选择政治面貌"
                                 :disabled="readon ? false : true"
                      >
                        <el-option
                          v-for="dict in statusOptions"
                          :key="dict.dicItemCode"
@@ -370,7 +382,9 @@
                  </el-col>
                  <el-col :span="8">
                    <el-form-item label="最高学历" prop="education">
                      <el-select v-model="empBaseInfoForm.education" placeholder="请选择最高学历" :disabled="readon ? false : true">
                      <el-select v-model="empBaseInfoForm.education" placeholder="请选择最高学历"
                                 :disabled="readon ? false : true"
                      >
                        <el-option
                          v-for="dict in educationOptions"
                          :key="dict.dicItemCode"
@@ -385,7 +399,9 @@
                <el-row>
                  <el-col :span="8">
                    <el-form-item label="籍贯" prop="nativePlaceName">
                      <el-select v-model="empBaseInfoForm.nativePlace" placeholder="请选择籍贯" :disabled="readon ? false : true">
                      <el-select v-model="empBaseInfoForm.nativePlace" placeholder="请选择籍贯"
                                 :disabled="readon ? false : true"
                      >
                        <el-option
                          v-for="dict in nativePlaceOptions"
                          :key="dict.dicItemCode"
@@ -420,7 +436,9 @@
                  </el-col>
                  <el-col :span="8">
                    <el-form-item label="档案情况" prop="archivesStatus">
                      <el-select v-model="empBaseInfoForm.archivesStatus" placeholder="请选择档案情况" :disabled="readon ? false : true">
                      <el-select v-model="empBaseInfoForm.archivesStatus" placeholder="请选择档案情况"
                                 :disabled="readon ? false : true"
                      >
                        <el-option
                          v-for="dict in archivesStatusOptions"
                          :key="dict.dicItemCode"
@@ -465,7 +483,9 @@
                  </el-col>
                  <el-col :span="8">
                    <el-form-item label="社保档位" prop="insuranceType">
                      <el-select v-model="empBaseInfoForm.insuranceType" placeholder="请选择社保档位" :disabled="readon ? false : true">
                      <el-select v-model="empBaseInfoForm.insuranceType" placeholder="请选择社保档位"
                                 :disabled="readon ? false : true"
                      >
                        <el-option
                          v-for="dict in insuranceTypeOptions"
                          :key="dict.dicItemCode"
@@ -495,7 +515,9 @@
                  </el-col>
                  <el-col :span="8">
                    <el-form-item label="工作证" prop="empCardStatus">
                      <el-select v-model="empBaseInfoForm.empCardStatus" placeholder="请选择工作证" :disabled="readon ? false : true">
                      <el-select v-model="empBaseInfoForm.empCardStatus" placeholder="请选择工作证"
                                 :disabled="readon ? false : true"
                      >
                        <el-option
                          v-for="dict in empCardStatusOptions"
                          :key="dict.dicItemCode"
@@ -520,7 +542,9 @@
                  </el-col>
                  <el-col :span="8">
                    <el-form-item label="员工手册" prop="handbookStatus">
                      <el-select v-model="empBaseInfoForm.handbookStatus" placeholder="请选择员工手册" :disabled="readon ? false : true">
                      <el-select v-model="empBaseInfoForm.handbookStatus" placeholder="请选择员工手册"
                                 :disabled="readon ? false : true"
                      >
                        <el-option
                          v-for="dict in handbookStatusOptions"
                          :key="dict.dicItemCode"
@@ -532,7 +556,9 @@
                  </el-col>
                  <el-col :span="8">
                    <el-form-item label="相关证件" prop="certificateList">
                      <el-select v-model="empBaseInfoForm.certificateList" multiple placeholder="请选择相关证件" :disabled="readon ? false : true">
                      <el-select v-model="empBaseInfoForm.certificateList" multiple placeholder="请选择相关证件"
                                 :disabled="readon ? false : true"
                      >
                        <el-option
                          v-for="dict in certificateListOptions"
                          :key="dict.dicItemCode"
@@ -579,7 +605,8 @@
                <el-table-column show-overflow-tooltip fixed="right" label="操作" width="120">
                  <template slot-scope="scope">
                    <span class="table-button" @click="editWorkExperience(scope.row,1)">编辑</span>
                    <span class="table-button" @click="singleDelete(scope.row, 'workExperienceDataselection')">删除</span>
                    <span class="table-button" @click="singleDelete(scope.row, 'workExperienceDataselection')"
                    >删除</span>
                  </template>
                </el-table-column>
              </el-table>
@@ -625,10 +652,14 @@
                <el-table-column v-if="fsnumShow" show-overflow-tooltip prop="physicalExamId" label="" />
                <el-table-column show-overflow-tooltip prop="hospital" label="体检医院" width="150" />
                <el-table-column show-overflow-tooltip prop="physicalExamDate" label="体检日期" width="140" />
                <el-table-column show-overflow-tooltip prop="physicalExamType" label="体检类型" width="140" :formatter="typeFormat" />
                <el-table-column show-overflow-tooltip prop="physicalExamType" label="体检类型" width="140"
                                 :formatter="typeFormat"
                />
                <el-table-column show-overflow-tooltip prop="bloodPressure" label="血压" width="140" />
                <el-table-column show-overflow-tooltip prop="transaminase" label="转氨酶" width="140" />
                <el-table-column show-overflow-tooltip prop="ecg" label="心电图" width="140" :formatter="ecgNameFormat" />
                <el-table-column show-overflow-tooltip prop="ecg" label="心电图" width="140"
                                 :formatter="ecgNameFormat"
                />
                <el-table-column show-overflow-tooltip prop="conclusion" label="体检结论" />
                <el-table-column show-overflow-tooltip prop="reviewRecord" label="复查记录" width="140" />
                <el-table-column show-overflow-tooltip prop="remark" label="备注" />
@@ -676,7 +707,9 @@
                <el-table-column show-overflow-tooltip prop="signingDate" label="合同签订日期" />
                <el-table-column show-overflow-tooltip prop="endDate" label="合同结束日期" />
                <el-table-column show-overflow-tooltip prop="contractPeriod" label="合同期限(年)" />
                <el-table-column show-overflow-tooltip prop="contractStatus" label="合同状态" :formatter="contractStatusFormat" />
                <el-table-column show-overflow-tooltip prop="contractStatus" label="合同状态"
                                 :formatter="contractStatusFormat"
                />
                <el-table-column show-overflow-tooltip prop="transactor" label="合同办理人" />
                <el-table-column show-overflow-tooltip prop="remark" label="备注" />
              </el-table>
@@ -708,13 +741,15 @@
                    <span v-text="getIndex(scope.$index)" />
                  </template>
                </el-table-column>
                <el-table-column show-overflow-tooltip prop="newDeptName" label="现部门" />
                <el-table-column show-overflow-tooltip prop="allDeptName" label="现部门"/>
                <el-table-column show-overflow-tooltip prop="newJobName" label="现岗位" />
                <el-table-column show-overflow-tooltip prop="empName" label="姓名" width="180" />
                <el-table-column show-overflow-tooltip prop="oldDeptName" label="原部门" />
                <el-table-column show-overflow-tooltip prop="oldJobName" label="原岗位" />
                <el-table-column show-overflow-tooltip prop="changeDate" label="调岗日期" />
                <el-table-column show-overflow-tooltip prop="changeType" label="调岗类型" :formatter="changeTypeFormat" />
                <el-table-column show-overflow-tooltip prop="changeType" label="调岗类型"
                                 :formatter="changeTypeFormat"
                />
                <el-table-column show-overflow-tooltip prop="changeReason" label="调岗理由" />
              </el-table>
              <pagination
@@ -846,7 +881,8 @@
                <el-table-column show-overflow-tooltip fixed="right" label="操作" width="120">
                  <template slot-scope="scope">
                    <span class="table-button" @click="editDimissionAttend(scope.row,6)">编辑</span>
                    <span class="table-button" @click="singleDelete(scope.row, 'dimissionAttendDataselection')">删除</span>
                    <span class="table-button" @click="singleDelete(scope.row, 'dimissionAttendDataselection')"
                    >删除</span>
                  </template>
                </el-table-column>
                <el-table-column v-if="fsnumShow" show-overflow-tooltip prop="dimissionAttendId" label="" />
@@ -885,12 +921,15 @@
                <el-table-column show-overflow-tooltip type="index" label="序号" align="center" width="55">
                  <template slot-scope="scope">
                    <span v-text="getIndex(scope.$index)" />
                  </template>EmpLeaveInfo
                  </template>
                  EmpLeaveInfo
                </el-table-column>
                <el-table-column show-overflow-tooltip prop="deptName" label="部门/护卫点" />
                <el-table-column show-overflow-tooltip prop="entryDate" label="入职日期" />
                <el-table-column show-overflow-tooltip prop="dimissionDate" label="离职日期" />
                <el-table-column show-overflow-tooltip prop="dimissionType" label="离职类型" :formatter="dimissionTypeFormat" />
                <el-table-column show-overflow-tooltip prop="dimissionType" label="离职类型"
                                 :formatter="dimissionTypeFormat"
                />
                <el-table-column show-overflow-tooltip prop="selfLeaveDay" label="自离天数" />
                <el-table-column show-overflow-tooltip prop="reporter" label="报备人" />
                <el-table-column show-overflow-tooltip prop="remark" label="备注" />
@@ -983,9 +1022,15 @@
                <el-table-column v-if="fsnumShow" show-overflow-tooltip prop="insuranceId" label="" />
                <el-table-column show-overflow-tooltip prop="applayDate" label="社保申请日期" width="180" />
                <el-table-column show-overflow-tooltip prop="proposer" label="申请人" width="180" />
                <el-table-column show-overflow-tooltip prop="insuranceGaers" label="社保档位" :formatter="insuranceGaersFormat" />
                <el-table-column show-overflow-tooltip prop="reportStatus" label="是否已报告" :formatter="reportStatusFormat" />
                <el-table-column show-overflow-tooltip prop="applayStatus" label="状态" :formatter="applayStatusFormat" />
                <el-table-column show-overflow-tooltip prop="insuranceGaers" label="社保档位"
                                 :formatter="insuranceGaersFormat"
                />
                <el-table-column show-overflow-tooltip prop="reportStatus" label="是否已报告"
                                 :formatter="reportStatusFormat"
                />
                <el-table-column show-overflow-tooltip prop="applayStatus" label="状态"
                                 :formatter="applayStatusFormat"
                />
                <el-table-column show-overflow-tooltip prop="auditor" label="审核人" width="180" />
                <el-table-column show-overflow-tooltip prop="remark" label="备注" />
              </el-table>
@@ -1025,7 +1070,8 @@
                <el-table-column show-overflow-tooltip fixed="right" label="操作" width="120">
                  <template slot-scope="scope">
                    <span class="table-button" @click="editAccidentCases(scope.row,9)">编辑</span>
                    <span class="table-button" @click="singleDelete(scope.row, 'accidentCasesDataselection')">删除</span>
                    <span class="table-button" @click="singleDelete(scope.row, 'accidentCasesDataselection')"
                    >删除</span>
                  </template>
                </el-table-column>
                <el-table-column v-if="fsnumShow" show-overflow-tooltip prop="accidentId" label="" />
@@ -1036,14 +1082,18 @@
                <el-table-column show-overflow-tooltip prop="injuredDiacrisis" label="意外险诊断" width="100" />
                <el-table-column show-overflow-tooltip prop="hospitalName" label="就诊医院" width="100" />
                <el-table-column show-overflow-tooltip prop="treatmentName" label="就诊科室" width="100" />
                <el-table-column show-overflow-tooltip prop="hospitalizatioFlag" label="是否住院" width="80" :formatter="hospitalizatioFlagFormat" />
                <el-table-column show-overflow-tooltip prop="hospitalizatioFlag" label="是否住院" width="80"
                                 :formatter="hospitalizatioFlagFormat"
                />
                <el-table-column show-overflow-tooltip prop="bedNumb" label="床号" width="60" />
                <el-table-column show-overflow-tooltip prop="reprotTime" label="报案时间" width="100" />
                <el-table-column show-overflow-tooltip prop="submitTime" label="递交资料时间" width="120" />
                <el-table-column show-overflow-tooltip prop="sbumitBy" label="递交人" width="100" />
                <el-table-column show-overflow-tooltip prop="expensesFee" label="医疗总费用" width="100" />
                <el-table-column show-overflow-tooltip prop="innsureFee" label="保险赔付费用" width="120" />
                <el-table-column show-overflow-tooltip prop="settleStatus" label="是否结案" width="120" :formatter="settleStatusFormat" />
                <el-table-column show-overflow-tooltip prop="settleStatus" label="是否结案" width="120"
                                 :formatter="settleStatusFormat"
                />
              </el-table>
              <pagination
                v-show="accidentCasesDatatotal>0"
@@ -1092,14 +1142,18 @@
                <el-table-column show-overflow-tooltip prop="injuredDiacrisis" label="工伤诊断" width="80" />
                <el-table-column show-overflow-tooltip prop="hospitalName" label="就诊医院" width="120" />
                <el-table-column show-overflow-tooltip prop="treatmentName" label="就诊科室" width="100" />
                <el-table-column show-overflow-tooltip prop="hospitalizatioFlag" label="是否住院" width="80" :formatter="hospitalizatioFlagFormat" />
                <el-table-column show-overflow-tooltip prop="hospitalizatioFlag" label="是否住院" width="80"
                                 :formatter="hospitalizatioFlagFormat"
                />
                <el-table-column show-overflow-tooltip prop="bedNumb" label="床号" width="80" />
                <el-table-column show-overflow-tooltip prop="reportTime" label="报案时间" width="100" />
                <el-table-column show-overflow-tooltip prop="submitTime" label="递交资料时间" width="120" />
                <el-table-column show-overflow-tooltip prop="sbumitBy" label="递交人" width="80" />
                <el-table-column show-overflow-tooltip prop="expensesFee" label="医疗总费用" width="100" />
                <el-table-column show-overflow-tooltip prop="compensated" label="已赔付医药费用" width="120" />
                <el-table-column show-overflow-tooltip prop="settleStatus" label="是否结案" width="120" :formatter="settleStatusFormat" />
                <el-table-column show-overflow-tooltip prop="settleStatus" label="是否结案" width="120"
                                 :formatter="settleStatusFormat"
                />
              </el-table>
              <pagination
                v-show="occupationalDatatotal>0"
@@ -1142,12 +1196,16 @@
                </el-table-column>
                <el-table-column v-if="fsnumShow" show-overflow-tooltip prop="arbitrationId" label="" />
                <el-table-column show-overflow-tooltip prop="arbitrationDate" label="仲裁日期" width="100" />
                <el-table-column show-overflow-tooltip prop="arbitrationType" label="仲裁类型" :formatter="arbitrationTypeFormat" />
                <el-table-column show-overflow-tooltip prop="arbitrationType" label="仲裁类型"
                                 :formatter="arbitrationTypeFormat"
                />
                <el-table-column show-overflow-tooltip prop="arbitrationReason" label="仲裁事由" />
                <el-table-column show-overflow-tooltip prop="reporter" label="报备人" width="100" />
                <el-table-column show-overflow-tooltip prop="remark" label="备注" />
                <el-table-column show-overflow-tooltip prop="arbitrationPay" label="仲裁赔付(元)" width="180" />
                <el-table-column show-overflow-tooltip prop="arbitrationStatus" label="是否结案" width="100" :formatter="arbitrationStatusFormat" />
                <el-table-column show-overflow-tooltip prop="arbitrationStatus" label="是否结案" width="100"
                                 :formatter="arbitrationStatusFormat"
                />
                <el-table-column show-overflow-tooltip prop="settleDate" label="案结日期" width="100" />
              </el-table>
              <pagination
@@ -1385,12 +1443,19 @@
                                :preview-src-list="srcList"
                                @click="clickImg(node)"
                              />
                              <el-tooltip v-if="'tif,bmp,jpg,png,gif'.indexOf(node.filesformat) == -1" class="item" effect="dark" :content="node.filesname" placement="bottom">
                              <el-tooltip v-if="'tif,bmp,jpg,png,gif'.indexOf(node.filesformat) == -1" class="item"
                                          effect="dark" :content="node.filesname" placement="bottom"
                              >
                                <div style="padding-top: 14px;text-align: center">
                                  <el-checkbox v-model="checkedArr[index * 8 + nodeIndex].isChecked" class="myRedCheckBox">{{ node.filesname }}</el-checkbox>
                                  <el-checkbox v-model="checkedArr[index * 8 + nodeIndex].isChecked"
                                               class="myRedCheckBox"
                                  >{{ node.filesname }}
                                  </el-checkbox>
                                </div>
                              </el-tooltip>
                              <el-tooltip v-if="'tif,bmp,jpg,png,gif'.indexOf(node.filesformat) != -1" class="item" effect="dark" :content="node.filesname" placement="bottom">
                              <el-tooltip v-if="'tif,bmp,jpg,png,gif'.indexOf(node.filesformat) != -1" class="item"
                                          effect="dark" :content="node.filesname" placement="bottom"
                              >
                                <div style="padding-top: 14px;">
                                  <el-image
                                    style="width: 100px; height: 80px;margin-top: -10px;"
@@ -1398,7 +1463,9 @@
                                    :preview-src-list="srcList"
                                    @click="clickImg(node)"
                                  />
                                  <el-checkbox v-model="checkedArr[index * 8 + nodeIndex].isChecked" class="myRedCheckBox">
                                  <el-checkbox v-model="checkedArr[index * 8 + nodeIndex].isChecked"
                                               class="myRedCheckBox"
                                  >
                                    {{ node.filesname }}
                                  </el-checkbox>
@@ -2725,7 +2792,7 @@
  </div>
</template>
<script>
import { calculateSeniority, toCardGetUserInfo } from '@/utils/myUtil'
import { calculateSeniority, dateDifference, toCardGetUserInfo } from '@/utils/myUtil'
import Treeselect from '@riophae/vue-treeselect'
import '@riophae/vue-treeselect/dist/vue-treeselect.css'
import Pagination from '@/components/Pagination'
@@ -2939,11 +3006,11 @@
        remark: [{ max: 512, message: '长度不超过512个字符', trigger: 'blur' }]
      },
      contractInfoRules: {
        signingDate: [{ required: true, message: '请选择合同签订时间', trigger: 'change' }],
        signingDate: [{ required: true, message: '请选择合同签订时间', trigger: 'change', validator: this.startDate }],
        contractStatus: [{ required: true, message: '请选择合同状态', trigger: 'change' }],
        transactor: [{ max: 40, message: '长度不超过40个字符', trigger: 'blur' }],
        beginDate: [{ required: true, message: '请选择合同开始日期', trigger: 'change' }],
        endDate: [{ required: true, message: '请选择合同结束时间', trigger: 'change' }],
        endDate: [{ required: true, message: '请选择合同结束时间', trigger: 'change', validator: this.endDate }],
        remark: [{ max: 512, message: '长度不超过512个字符', trigger: 'blur' }]
      },
      dimissionAttendRules: {
@@ -5933,6 +6000,39 @@
      }
      this.sysConfig = this.initSysConfig()
    },
    startDate(rule, value, callback) {
      // 如果结束日期没选,cb
      if (!this.contractInfoForm.endDate) {
        callback()
      } else {
        // 结束日期有,进行判断
        if (this.compareDate(value, this.contractInfoForm.endDate)) {
          // 如果起始在结束之前
          callback()
        } else {
          callback(new Error('开始日期不能在结束日期之后,请重新选择'))
        }
      }
    },
    // 验证合同结束日期
    endDate(rule, value, callback) {
      // 如果起始日期没选,cb
      if (!this.contractInfoForm.signingDate) {
        callback()
      } else {
        // 起始日期有,进行判断
        if (this.compareDate(this.contractInfoForm.signingDate, value)) {
          // 如果起始在结束之前
          this.contractInfoForm.contractPeriod = dateDifference(this.contractInfoForm.signingDate, this.contractInfoForm.endDate, 'o')
          callback()
        } else {
          callback(new Error('结束日期不能在开始始日期之前,请重新选择'))
        }
      }
    },
    compareDate(start, end) {
      return new Date(end).getTime() > new Date(start).getTime()
    }
  }
}
@@ -6256,10 +6356,12 @@
      height: 35px;
      box-sizing: border-box;
      padding-left: 28px !important;
       &:hover {
         color: #a00515;
         cursor: pointer;
       }
      .light {
        color: #a00515;
      }
@@ -6295,32 +6397,40 @@
    opacity: 0.8;
      line-height: 30px;
      border-radius: 50%;
    i {
      color: #fff !important;
    }
    &:hover {
      opacity: 0.5;
    }
  }
  .el-pagination {
    width: 98%;
    text-align: right;
  }
  .el-aside {
    height: 750px;
    overflow: hidden;
  }
  li.el-timeline-item {
    padding-bottom: 1px;
    height: 35px;
  }
.el-dialog__title {
  font-weight: 700;
}
  .el-dialog__body {
    padding: 10px 20px;
  }
}
.el-dialog.is-fullscreen {
  overflow: hidden;
}
@@ -6331,6 +6441,7 @@
    color: #333 !important;
  }
}
.pri-del-btn {
  background-color: rgb(64, 158, 255) !important;
  border-color: rgb(64, 158, 255) !important;
src/views/user/inemployees.vue
@@ -245,14 +245,6 @@
          <el-table-column type="selection" width="55" />
          <el-table-column label="操作" width="130">
            <template slot-scope="scope">
              <!--              <el-button-->
              <!--                type="text"-->
              <!--                size="small"-->
              <!--                @click="editArchives(scope.row)"-->
              <!--              >-->
              <!--                档案</el-button>-->
              <!--              <el-button type="text" size="small" @click="editEmpBase(scope.row)">编辑</el-button>-->
              <span
                style="color: #a00515;display: inline-block;width: 40%;cursor: pointer"
                @click="editArchives(scope.row)"
@@ -643,7 +635,7 @@
        <el-button type="primary" @click="showDryg(2)">确 定</el-button>
      </div>
    </el-dialog>
    <el-dialog title="关闭档案" :visible.sync="dialogShowGbda" width="50%">
    <el-dialog title="关闭档案" :visible.sync="dialogShowGbda" width="70%">
      <el-form ref="gbdaForm" :model="gbdaForm" :rules="gbdaRules" label-position="right" label-width="120px">
        <el-row>
          <el-col span="24">
@@ -655,6 +647,7 @@
                <el-radio :label="4">自动离职</el-radio>
                <el-radio :label="5">试用期内</el-radio>
                <el-radio :label="6">正常离职</el-radio>
                <el-radio :label="7">到龄退休</el-radio>
              </el-radio-group>
            </el-form-item>
          </el-col>
src/views/user/outemployess.vue
@@ -183,13 +183,7 @@
                        <el-checkbox :label="1">合同期满</el-checkbox>
                        <el-checkbox :label="3">公司辞退</el-checkbox>
                        <el-checkbox :label="5">试用期内</el-checkbox>
                        <!--                        <el-checkbox-->
                        <!--                          v-for="data in dimissionTypeOptions"-->
                        <!--                          :key="data.dicItemName"-->
                        <!--                          :label="data.dicItemCode"-->
                        <!--                        >-->
                        <!--                          {{ data.dicItemName }}-->
                        <!--                        </el-checkbox>-->
                        <el-checkbox :label="7">到龄退休</el-checkbox>
                      </el-checkbox-group>
                    </td>
                  </tr>
vue.config.js
@@ -1,6 +1,7 @@
'use strict'
const settings = require('./src/settings.js')
const path = require('path')
function resolve(dir) {
  return path.join(__dirname, dir)
}
@@ -28,6 +29,7 @@
  devServer: {
    port: port,
    open: false,
    disableHostCheck: true,
    overlay: {
      warnings: false,
      errors: true
@@ -49,6 +51,7 @@
    // provide the app's title in webpack's name field, so that
    // it can be accessed in index.html to inject the correct title.
    name: name,
    devtool: 'source-map',
    resolve: {
      alias: {
        '@': resolve('src')