| | |
| | | <!--表格渲染--> |
| | | <el-table ref="table" v-loading="crud.loading" :data="crud.data" size="small" style="width: 100%;" @selection-change="crud.selectionChangeHandler"> |
| | | <el-table-column type="selection" width="55" /> |
| | | <el-table-column prop="userId" label="员工ID" /> |
| | | <el-table-column prop="salaryYearMonth" label="工资年月" /> |
| | | <el-table-column prop="levelWage" label="级别工资" /> |
| | | <el-table-column prop="basicWageProportion" label="基本工资比例" /> |
| | | <el-table-column prop="basicWage" label="基本工资" /> |
| | | <el-table-column prop="fullDays" label="全勤小时数" /> |
| | | <el-table-column prop="absenceDays" label="缺勤小时数" /> |
| | | <el-table-column prop="actualBasicWage" label="实际基础工资" /> |
| | | <el-table-column prop="achievementsWageProportion" label="绩效工资比例" /> |
| | | <el-table-column prop="achievementsWage" label="绩效工资" /> |
| | | <el-table-column prop="needCompletedAchievementsHours" label="应完成绩效工时" /> |
| | | <el-table-column prop="alreadyCompletedAchievementsHours" label="已完成绩效工时" /> |
| | | <el-table-column prop="actualAchievementsWage" label="实际绩效工资" /> |
| | | <el-table-column prop="performanceWageProportion" label="业绩工资比例" /> |
| | | <el-table-column prop="performanceWage" label="业绩工资" /> |
| | | <el-table-column prop="personalPerformanceProportion" label="个人业绩比例" /> |
| | | <el-table-column prop="needCompletedPerformanceHours" label="应完成业绩工时" /> |
| | | <el-table-column prop="alreadyCompletedPerformanceHours" label="已完成业绩工时" /> |
| | | <el-table-column prop="actualPerformanceWage" label="实际业绩工资" /> |
| | | <el-table-column prop="teamWageProportion" label="团队工资比例" /> |
| | | <el-table-column prop="teamWage" label="团队工资" /> |
| | | <el-table-column prop="actualComplianceTeamHours" label="实达标团队工时" /> |
| | | <el-table-column prop="alreadyCompletedTeamHours" label="已完成团队工时" /> |
| | | <el-table-column prop="actualTeamWage" label="实际团队工资" /> |
| | | <el-table-column prop="accumulationRadix" label="公积金基数" /> |
| | | <el-table-column prop="accumulationPersonalProportion" label="公积金个人缴纳比例" /> |
| | | <el-table-column prop="accumulationPersonalAmount" label="公积金个人缴纳金额" /> |
| | | <el-table-column prop="accumulationCompanyProportion" label="公积金公司缴纳比例" /> |
| | | <el-table-column prop="accumulationCompanyAmount" label="公积金公司缴纳金额" /> |
| | | <el-table-column prop="pensionRadix" label="养老险基数" /> |
| | | <el-table-column prop="pensionPersonalProportion" label="养老险个人缴纳比例" /> |
| | | <el-table-column prop="pensionPersonalAmount" label="养老险个人缴纳金额" /> |
| | | <el-table-column prop="pensionCompanyProportion" label="养老险公司缴纳比例" /> |
| | | <el-table-column prop="pensionCompanyAmount" label="养老险公司缴纳金额" /> |
| | | <el-table-column prop="medicalRadix" label="医疗险基数" /> |
| | | <el-table-column prop="medicalPersonalProportion" label="医疗险个人缴纳比例" /> |
| | | <el-table-column prop="medicalPersonalAmount" label="医疗险个人缴纳金额" /> |
| | | <el-table-column prop="medicalCompanyProportion" label="医疗险公司缴纳比例" /> |
| | | <el-table-column prop="medicalCompanyAmount" label="医疗险公司缴纳金额" /> |
| | | <el-table-column prop="unemploymentRadix" label="失业险基数" /> |
| | | <el-table-column prop="unemploymentPersonalProportion" label="失业险个人缴纳比例" /> |
| | | <el-table-column prop="unemploymentPersonalAmount" label="失业险个人缴纳金额" /> |
| | | <el-table-column prop="unemploymentCompanyProportion" label="失业险公司缴纳比例" /> |
| | | <el-table-column prop="unemploymentCompanyAmount" label="失业险公司缴纳金额" /> |
| | | <el-table-column prop="maternityRadix" label="生育险基数" /> |
| | | <el-table-column prop="maternityPersonalProportion" label="生育险个人缴纳比例" /> |
| | | <el-table-column prop="maternityPersonalAmount" label="生育险个人缴纳金额" /> |
| | | <el-table-column prop="maternityCompanyProportion" label="生育险公司缴纳比例" /> |
| | | <el-table-column prop="maternityCompanyAmount" label="生育险公司缴纳金额" /> |
| | | <el-table-column prop="industrialInjuryRadix" label="工伤险基数" /> |
| | | <el-table-column prop="industrialInjuryPersonalProportion" label="工伤险个人缴纳比例" /> |
| | | <el-table-column prop="industrialInjuryPersonalAmount" label="工伤险个人缴纳金额" /> |
| | | <el-table-column prop="industrialInjuryCompanyProportion" label="工伤险公司缴纳比例" /> |
| | | <el-table-column prop="industrialInjuryCompanyAmount" label="工伤险公司缴纳金额" /> |
| | | <el-table-column prop="preTaxAmount" label="税前金额" /> |
| | | <el-table-column prop="individualIncomeTax" label="个人所得税" /> |
| | | <el-table-column prop="afterTaxAmount" label="税后金额" /> |
| | | <el-table-column prop="remarks" label="备注" /> |
| | | <el-table-column prop="createTime" label="创建时间" /> |
| | | <el-table-column v-if="checkPer(['admin','salary:edit','salary:del'])" label="操作" width="150px" align="center"> |
| | | <el-table-column :show-overflow-tooltip="true" prop="userNickName" label="所属员工" fixed="left" width="100"> |
| | | <template slot-scope="scope"> |
| | | <el-tag>{{ scope.row.userNickName }}</el-tag> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="salaryYearMonth" label="工资年月" fixed="left" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ crud.toMonth(scope.row.salaryYearMonth) }} |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="levelWage" label="级别工资" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ crud.toMoney(scope.row.levelWage) }} |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="基础工资"> |
| | | <el-table-column :show-overflow-tooltip="true" prop="basicWageProportion" label="工资比例" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ scope.row.basicWageProportion }}% |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="basicWage" label="预计工资" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ crud.toMoney(scope.row.basicWage) }} |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="fullDays" label="全勤小时数" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ scope.row.fullDays }}小时 |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="absenceDays" label="缺勤小时数" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ scope.row.absenceDays }}小时 |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="actualBasicWage" label="实际工资" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ crud.toMoney(scope.row.actualBasicWage) }} |
| | | </template> |
| | | </el-table-column> |
| | | </el-table-column> |
| | | <el-table-column label="绩效工资"> |
| | | <el-table-column :show-overflow-tooltip="true" prop="achievementsWageProportion" label="工资比例" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ scope.row.achievementsWageProportion }}% |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="achievementsWage" label="预计工资" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ crud.toMoney(scope.row.achievementsWage) }} |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="needCompletedAchievementsHours" label="应完成工时" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ scope.row.needCompletedAchievementsHours }}小时 |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="alreadyCompletedAchievementsHours" label="已完成工时" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ scope.row.alreadyCompletedAchievementsHours }}小时 |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="actualAchievementsWage" label="实际工资" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ crud.toMoney(scope.row.actualAchievementsWage) }} |
| | | </template> |
| | | </el-table-column> |
| | | </el-table-column> |
| | | <el-table-column label="业绩工资"> |
| | | <el-table-column :show-overflow-tooltip="true" prop="performanceWageProportion" label="工资比例" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ scope.row.performanceWageProportion }}% |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="performanceWage" label="预计工资" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ crud.toMoney(scope.row.performanceWage) }} |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="personalPerformanceProportion" label="个人业绩比例" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ scope.row.personalPerformanceProportion }}% |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="needCompletedPerformanceHours" label="应完成工时" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ scope.row.needCompletedPerformanceHours }}小时 |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="alreadyCompletedPerformanceHours" label="已完成工时" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ scope.row.alreadyCompletedPerformanceHours }}小时 |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="actualPerformanceWage" label="实际工资" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ crud.toMoney(scope.row.actualPerformanceWage) }} |
| | | </template> |
| | | </el-table-column> |
| | | </el-table-column> |
| | | <el-table-column label="团队工资"> |
| | | <el-table-column :show-overflow-tooltip="true" prop="teamWageProportion" label="工资比例" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ scope.row.teamWageProportion }}% |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="teamWage" label="预计工资" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ crud.toMoney(scope.row.teamWage) }} |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="actualComplianceTeamHours" label="实达标工时" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ scope.row.actualComplianceTeamHours }}小时 |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="alreadyCompletedTeamHours" label="已完成工时" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ scope.row.alreadyCompletedTeamHours }}小时 |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="actualTeamWage" label="实际工资" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ crud.toMoney(scope.row.actualTeamWage) }} |
| | | </template> |
| | | </el-table-column> |
| | | </el-table-column> |
| | | <el-table-column label="公积金"> |
| | | <el-table-column :show-overflow-tooltip="true" prop="accumulationRadix" label="基数" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ crud.toMoney(scope.row.accumulationRadix) }} |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="accumulationPersonalProportion" label="个人缴纳比例" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ scope.row.accumulationPersonalProportion }}% |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="accumulationPersonalAmount" label="个人缴纳金额" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ crud.toMoney(scope.row.accumulationPersonalAmount) }} |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="accumulationCompanyProportion" label="公司缴纳比例" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ scope.row.accumulationCompanyProportion }}% |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="accumulationCompanyAmount" label="公司缴纳金额" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ crud.toMoney(scope.row.accumulationCompanyAmount) }} |
| | | </template> |
| | | </el-table-column> |
| | | </el-table-column> |
| | | <el-table-column label="养老险"> |
| | | <el-table-column :show-overflow-tooltip="true" prop="pensionRadix" label="基数" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ crud.toMoney(scope.row.pensionRadix) }} |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="pensionPersonalProportion" label="个人缴纳比例" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ scope.row.pensionPersonalProportion }}% |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="pensionPersonalAmount" label="个人缴纳金额" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ crud.toMoney(scope.row.pensionPersonalAmount) }} |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="pensionCompanyProportion" label="公司缴纳比例" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ scope.row.pensionCompanyProportion }}% |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="pensionCompanyAmount" label="公司缴纳金额" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ crud.toMoney(scope.row.pensionCompanyAmount) }} |
| | | </template> |
| | | </el-table-column> |
| | | </el-table-column> |
| | | <el-table-column label="医疗险"> |
| | | <el-table-column :show-overflow-tooltip="true" prop="medicalRadix" label="基数" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ crud.toMoney(scope.row.medicalRadix) }} |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="medicalPersonalProportion" label="个人缴纳比例" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ scope.row.medicalPersonalProportion }}% |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="medicalPersonalAmount" label="个人缴纳金额" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ crud.toMoney(scope.row.medicalPersonalAmount) }} |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="medicalCompanyProportion" label="公司缴纳比例" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ scope.row.medicalCompanyProportion }}% |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="medicalCompanyAmount" label="公司缴纳金额" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ crud.toMoney(scope.row.medicalCompanyAmount) }} |
| | | </template> |
| | | </el-table-column> |
| | | </el-table-column> |
| | | <el-table-column label="失业险"> |
| | | <el-table-column :show-overflow-tooltip="true" prop="unemploymentRadix" label="基数" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ crud.toMoney(scope.row.unemploymentRadix) }} |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="unemploymentPersonalProportion" label="个人缴纳比例" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ scope.row.unemploymentPersonalProportion }}% |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="unemploymentPersonalAmount" label="个人缴纳金额" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ crud.toMoney(scope.row.unemploymentPersonalAmount) }} |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="unemploymentCompanyProportion" label="公司缴纳比例" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ scope.row.unemploymentCompanyProportion }}% |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="unemploymentCompanyAmount" label="公司缴纳金额" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ crud.toMoney(scope.row.unemploymentCompanyAmount) }} |
| | | </template> |
| | | </el-table-column> |
| | | </el-table-column> |
| | | <el-table-column label="生育险"> |
| | | <el-table-column :show-overflow-tooltip="true" prop="maternityRadix" label="基数" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ crud.toMoney(scope.row.maternityRadix) }} |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="maternityPersonalProportion" label="个人缴纳比例" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ scope.row.maternityPersonalProportion }}% |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="maternityPersonalAmount" label="个人缴纳金额" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ crud.toMoney(scope.row.maternityPersonalAmount) }} |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="maternityCompanyProportion" label="公司缴纳比例" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ scope.row.maternityCompanyProportion }}% |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="maternityCompanyAmount" label="公司缴纳金额" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ crud.toMoney(scope.row.maternityCompanyAmount) }} |
| | | </template> |
| | | </el-table-column> |
| | | </el-table-column> |
| | | <el-table-column label="工伤险"> |
| | | <el-table-column :show-overflow-tooltip="true" prop="industrialInjuryRadix" label="基数" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ crud.toMoney(scope.row.industrialInjuryRadix) }} |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="industrialInjuryPersonalProportion" label="个人缴纳比例" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ scope.row.industrialInjuryPersonalProportion }}% |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="industrialInjuryPersonalAmount" label="个人缴纳金额" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ crud.toMoney(scope.row.industrialInjuryPersonalAmount) }} |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="industrialInjuryCompanyProportion" label="公司缴纳比例" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ scope.row.industrialInjuryCompanyProportion }}% |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="industrialInjuryCompanyAmount" label="公司缴纳金额" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ crud.toMoney(scope.row.industrialInjuryCompanyAmount) }} |
| | | </template> |
| | | </el-table-column> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="preTaxAmount" label="税前金额" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ crud.toMoney(scope.row.preTaxAmount) }} |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="individualIncomeTax" label="个人所得税" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ crud.toMoney(scope.row.individualIncomeTax) }} |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="afterTaxAmount" label="税后金额" width="100"> |
| | | <template slot-scope="scope"> |
| | | {{ crud.toMoney(scope.row.afterTaxAmount) }} |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :show-overflow-tooltip="true" prop="remarks" label="备注" width="140" /> |
| | | <el-table-column :show-overflow-tooltip="true" prop="createTime" label="创建时间" width="140" /> |
| | | <el-table-column v-if="checkPer(['admin','salary:edit','salary:del'])" label="操作" width="150px" align="center" fixed="right"> |
| | | <template slot-scope="scope"> |
| | | <udOperation |
| | | :data="scope.row" |
| | |
| | | // 获取用户级别工资 |
| | | crudUserLevelWage.getTargetYearMonth({ userId: this.form.userId, targetYearMonth: this.form.salaryYearMonth }).then(res => { |
| | | // 级别工资 |
| | | this.form.levelWage = Number(res.levelWage) |
| | | this.form.levelWage = Number(res.levelWage.toFixed(2)) |
| | | // 基本工资比例 |
| | | this.form.basicWageProportion = Number(res.basicWageProportion) |
| | | this.form.basicWageProportion = Number(res.basicWageProportion.toFixed(2)) |
| | | // 预计基本工资 |
| | | this.form.basicWage = Number((res.levelWage * (res.basicWageProportion / 100)).toFixed(2)) |
| | | // 绩效工资比例 |
| | | this.form.achievementsWageProportion = Number(res.achievementsWageProportion) |
| | | this.form.achievementsWageProportion = Number(res.achievementsWageProportion.toFixed(2)) |
| | | // 预计绩效工资 |
| | | this.form.achievementsWage = Number((res.levelWage * (res.achievementsWageProportion / 100)).toFixed(2)) |
| | | // 业绩工资比例 |
| | | this.form.performanceWageProportion = Number(res.performanceWageProportion) |
| | | this.form.performanceWageProportion = Number(res.performanceWageProportion.toFixed(2)) |
| | | // 预计业绩工资 |
| | | this.form.performanceWage = Number((res.levelWage * (res.performanceWageProportion / 100)).toFixed(2)) |
| | | // 团队工资比例 |
| | | this.form.teamWageProportion = Number(res.teamWageProportion) |
| | | this.form.teamWageProportion = Number(res.teamWageProportion.toFixed(2)) |
| | | // 预计团队工资 |
| | | this.form.teamWage = Number((res.levelWage * (res.teamWageProportion / 100)).toFixed(2)) |
| | | // 随机数 |
| | |
| | | // 获取用户级别保险 |
| | | crudUserLevelInsurance.getTargetYearMonth({ userId: this.form.userId, targetYearMonth: this.form.salaryYearMonth }).then(res => { |
| | | // 公积金基数 |
| | | this.form.accumulationRadix = Number(res.accumulationRadix) |
| | | this.form.accumulationRadix = Number(res.accumulationRadix.toFixed(2)) |
| | | // 公积金个人缴纳比例 |
| | | this.form.accumulationPersonalProportion = Number(res.accumulationPersonalProportion) |
| | | this.form.accumulationPersonalProportion = Number(res.accumulationPersonalProportion.toFixed(2)) |
| | | // 公积金个人缴纳金额 |
| | | this.form.accumulationPersonalAmount = Number((res.accumulationRadix * (res.accumulationPersonalProportion / 100)).toFixed(2)) |
| | | // 公积金公司缴纳比例 |
| | | this.form.accumulationCompanyProportion = Number(res.accumulationCompanyProportion) |
| | | this.form.accumulationCompanyProportion = Number(res.accumulationCompanyProportion.toFixed(2)) |
| | | // 公积金公司缴纳金额 |
| | | this.form.accumulationCompanyAmount = Number((res.accumulationRadix * (res.accumulationCompanyProportion / 100)).toFixed(2)) |
| | | // 养老险基数 |
| | | this.form.pensionRadix = Number(res.pensionRadix) |
| | | this.form.pensionRadix = Number(res.pensionRadix.toFixed(2)) |
| | | // 养老险个人缴纳比例 |
| | | this.form.pensionPersonalProportion = Number(res.pensionPersonalProportion) |
| | | this.form.pensionPersonalProportion = Number(res.pensionPersonalProportion.toFixed(2)) |
| | | // 养老险个人缴纳金额 |
| | | this.form.pensionPersonalAmount = Number((res.pensionRadix * (res.pensionPersonalProportion / 100)).toFixed(2)) |
| | | // 养老险公司缴纳比例 |
| | | this.form.pensionCompanyProportion = Number(res.pensionCompanyProportion) |
| | | this.form.pensionCompanyProportion = Number(res.pensionCompanyProportion.toFixed(2)) |
| | | // 养老险公司缴纳金额 |
| | | this.form.pensionCompanyAmount = Number((res.pensionRadix * (res.pensionCompanyProportion / 100)).toFixed(2)) |
| | | // 医疗险基数 |
| | | this.form.medicalRadix = Number(res.medicalRadix) |
| | | this.form.medicalRadix = Number(res.medicalRadix.toFixed(2)) |
| | | // 医疗险个人缴纳比例 |
| | | this.form.medicalPersonalProportion = Number(res.medicalPersonalProportion) |
| | | this.form.medicalPersonalProportion = Number(res.medicalPersonalProportion.toFixed(2)) |
| | | // 医疗险个人缴纳金额 |
| | | this.form.medicalPersonalAmount = Number((res.medicalRadix * (res.medicalPersonalProportion / 100)).toFixed(2)) |
| | | // 医疗险公司缴纳比例 |
| | | this.form.medicalCompanyProportion = Number(res.medicalCompanyProportion) |
| | | this.form.medicalCompanyProportion = Number(res.medicalCompanyProportion.toFixed(2)) |
| | | // 医疗险公司缴纳金额 |
| | | this.form.medicalCompanyAmount = Number((res.medicalRadix * (res.medicalCompanyProportion / 100)).toFixed(2)) |
| | | // 失业险基数 |
| | | this.form.unemploymentRadix = Number(res.unemploymentRadix) |
| | | this.form.unemploymentRadix = Number(res.unemploymentRadix.toFixed(2)) |
| | | // 失业险个人缴纳比例 |
| | | this.form.unemploymentPersonalProportion = Number(res.unemploymentPersonalProportion) |
| | | this.form.unemploymentPersonalProportion = Number(res.unemploymentPersonalProportion.toFixed(2)) |
| | | // 失业险个人缴纳金额 |
| | | this.form.unemploymentPersonalAmount = Number((res.unemploymentRadix * (res.unemploymentPersonalProportion / 100)).toFixed(2)) |
| | | // 失业险公司缴纳比例 |
| | | this.form.unemploymentCompanyProportion = Number(res.unemploymentCompanyProportion) |
| | | this.form.unemploymentCompanyProportion = Number(res.unemploymentCompanyProportion.toFixed(2)) |
| | | // 失业险公司缴纳金额 |
| | | this.form.unemploymentCompanyAmount = Number((res.unemploymentRadix * (res.unemploymentCompanyProportion / 100)).toFixed(2)) |
| | | // 生育险基数 |
| | | this.form.maternityRadix = Number(res.maternityRadix) |
| | | this.form.maternityRadix = Number(res.maternityRadix.toFixed(2)) |
| | | // 生育险个人缴纳比例 |
| | | this.form.maternityPersonalProportion = Number(res.maternityPersonalProportion) |
| | | this.form.maternityPersonalProportion = Number(res.maternityPersonalProportion.toFixed(2)) |
| | | // 生育险个人缴纳金额 |
| | | this.form.maternityPersonalAmount = Number((res.maternityRadix * (res.maternityPersonalProportion / 100)).toFixed(2)) |
| | | // 生育险公司缴纳比例 |
| | | this.form.maternityCompanyProportion = Number(res.maternityCompanyProportion) |
| | | this.form.maternityCompanyProportion = Number(res.maternityCompanyProportion.toFixed(2)) |
| | | // 生育险公司缴纳金额 |
| | | this.form.maternityCompanyAmount = Number((res.maternityRadix * (res.maternityCompanyProportion / 100)).toFixed(2)) |
| | | // 工伤险基数 |
| | | this.form.industrialInjuryRadix = Number(res.industrialInjuryRadix) |
| | | this.form.industrialInjuryRadix = Number(res.industrialInjuryRadix.toFixed(2)) |
| | | // 工伤险个人缴纳比例 |
| | | this.form.industrialInjuryPersonalProportion = Number(res.industrialInjuryPersonalProportion) |
| | | this.form.industrialInjuryPersonalProportion = Number(res.industrialInjuryPersonalProportion.toFixed(2)) |
| | | // 工伤险个人缴纳金额 |
| | | this.form.industrialInjuryPersonalAmount = Number((res.industrialInjuryRadix * (res.industrialInjuryPersonalProportion / 100)).toFixed(2)) |
| | | // 工伤险公司缴纳比例 |
| | | this.form.industrialInjuryCompanyProportion = Number(res.industrialInjuryCompanyProportion) |
| | | this.form.industrialInjuryCompanyProportion = Number(res.industrialInjuryCompanyProportion.toFixed(2)) |
| | | // 工伤险公司缴纳金额 |
| | | this.form.industrialInjuryCompanyAmount = Number((res.industrialInjuryRadix * (res.industrialInjuryCompanyProportion / 100)).toFixed(2)) |
| | | // 随机数 |
| | |
| | | // 获取用户级别其他 |
| | | crudUserLevelOther.getTargetYearMonth({ userId: this.form.userId, targetYearMonth: this.form.salaryYearMonth }).then(res => { |
| | | // 个人业绩比例 |
| | | this.form.personalPerformanceProportion = Number(res.personalPerformanceProportion) |
| | | this.form.personalPerformanceProportion = Number(res.personalPerformanceProportion.toFixed(2)) |
| | | }) |
| | | }, |
| | | // 获取工作天数 |
| | |
| | | // 获取工作天数 |
| | | crudSalary.workDays({ targetYearMonth: this.form.salaryYearMonth }).then(res => { |
| | | // 全勤小时数 |
| | | this.form.fullDays = Number(res * 8) |
| | | this.form.fullDays = Number((res * 8).toFixed(2)) |
| | | // 应完成绩效工时 |
| | | this.form.needCompletedAchievementsHours = Number(res * 8) |
| | | this.form.needCompletedAchievementsHours = Number((res * 8).toFixed(2)) |
| | | // 定时器 |
| | | const interval = setInterval(() => { |
| | | // 判断个人业绩比例是否为空 |
| | | if (this.form.personalPerformanceProportion != null && this.form.personalPerformanceProportion !== '') { |
| | | // 应完成业绩工时 |
| | | this.form.needCompletedPerformanceHours = Number(res * 8 * (1 + Number(this.form.personalPerformanceProportion) / 100)) |
| | | this.form.needCompletedPerformanceHours = Number((res * 8 * (1 + this.form.personalPerformanceProportion / 100)).toFixed(2)) |
| | | // 清空定时器 |
| | | clearInterval(interval) |
| | | } |
| | |
| | | getAttendanceHours() { |
| | | // 获取出勤小时数 |
| | | crudAttendance.attendanceHours({ userId: this.form.userId, targetYearMonth: this.form.salaryYearMonth }).then(res => { |
| | | // console.log(res) |
| | | // 定时器 |
| | | const interval = setInterval(() => { |
| | | // 判断预计基础工资、全勤小时数是否为空 |
| | | if (this.form.basicWage != null && this.form.basicWage !== '' && this.form.fullDays != null && this.form.fullDays !== '') { |
| | | // 缺勤小时数 |
| | | this.form.absenceDays = Number((this.form.fullDays - res).toFixed(2)) |
| | | // 实际基础工资 |
| | | this.form.actualBasicWage = Number((this.form.basicWage - (this.form.basicWage / this.form.fullDays) * (this.form.fullDays - res)).toFixed(2)) |
| | | // 随机数 |
| | | this.random = Math.random() |
| | | // 清空定时器 |
| | | clearInterval(interval) |
| | | } |
| | | }, 500) |
| | | }) |
| | | }, |
| | | // 获取达标工时 |
| | |
| | | // 获取达标工时 |
| | | crudTaskDaliy.complianceWork({ userId: this.form.userId, targetYearMonth: this.form.salaryYearMonth }).then(res => { |
| | | // 实达标团队工时 |
| | | this.form.actualComplianceTeamHours = Number(res) |
| | | this.form.actualComplianceTeamHours = Number(res.toFixed(2)) |
| | | }) |
| | | }, |
| | | // 获取已完成工时 |
| | |
| | | // 获取已完成工时 |
| | | crudTaskDaliy.completedWork({ userId: this.form.userId, targetYearMonth: this.form.salaryYearMonth }).then(res => { |
| | | // 已完成绩效工时 |
| | | this.form.alreadyCompletedAchievementsHours = Number(res) |
| | | this.form.alreadyCompletedAchievementsHours = Number(res.toFixed(2)) |
| | | // 已完成业绩工时 |
| | | this.form.alreadyCompletedPerformanceHours = Number(res) |
| | | this.form.alreadyCompletedPerformanceHours = Number(res.toFixed(2)) |
| | | // 已完成团队工时 |
| | | this.form.alreadyCompletedTeamHours = Number(res) |
| | | this.form.alreadyCompletedTeamHours = Number(res.toFixed(2)) |
| | | // 绩效定时器 |
| | | const achievementsInterval = setInterval(() => { |
| | | // 判断预计绩效工资、应完成绩效工时是否为空 |
| | |
| | | // 判断预计业绩工资、应完成业绩工时是否为空 |
| | | if (this.form.performanceWage != null && this.form.performanceWage !== '' && this.form.needCompletedPerformanceHours != null && this.form.needCompletedPerformanceHours !== '') { |
| | | // 实际业绩工资 |
| | | this.form.actualPerformanceWage = Number(res >= this.form.needCompletedPerformanceHours ? this.form.performanceWage : 0) |
| | | this.form.actualPerformanceWage = Number((res >= this.form.needCompletedPerformanceHours ? this.form.performanceWage : 0).toFixed(2)) |
| | | // 随机数 |
| | | this.random = Math.random() |
| | | // 清空业绩定时器 |
| | |
| | | // 判断预计团队工资、实达标团队工时是否为空 |
| | | if (this.form.teamWage != null && this.form.teamWage !== '' && this.form.actualComplianceTeamHours != null && this.form.actualComplianceTeamHours !== '') { |
| | | // 实际团队工资 |
| | | this.form.actualTeamWage = Number((this.form.teamWage * (this.form.actualComplianceTeamHours / res)).toFixed(2)) |
| | | this.form.actualTeamWage = Number(this.form.actualComplianceTeamHours !== 0 ? (this.form.teamWage * (this.form.actualComplianceTeamHours / res)).toFixed(2) : 0) |
| | | // 随机数 |
| | | this.random = Math.random() |
| | | // 清空团队定时器 |
| | | clearInterval(teamInterval) |
| | | } |
| | | }, 500) |
| | | // 统计定时器 |
| | | const statisticsInterval = setInterval(() => { |
| | | // 判断 实际基础工资、实际绩效工资、实际业绩工资、实际团队工资、公积金个人缴纳金额、 |
| | | // 养老险个人缴纳金额、医疗险个人缴纳金额、失业险个人缴纳金额、生育险个人缴纳金额、工伤险个人缴纳金额 是否为空 |
| | | if ( |
| | | this.form.actualBasicWage != null && this.form.actualBasicWage !== '' && |
| | | this.form.actualAchievementsWage != null && this.form.actualAchievementsWage !== '' && |
| | | this.form.actualPerformanceWage != null && this.form.actualPerformanceWage !== '' && |
| | | this.form.actualTeamWage != null && this.form.actualTeamWage !== '' && |
| | | this.form.accumulationPersonalAmount != null && this.form.accumulationPersonalAmount !== '' && |
| | | this.form.pensionPersonalAmount != null && this.form.pensionPersonalAmount !== '' && |
| | | this.form.medicalPersonalAmount != null && this.form.medicalPersonalAmount !== '' && |
| | | this.form.unemploymentPersonalAmount != null && this.form.unemploymentPersonalAmount !== '' && |
| | | this.form.maternityPersonalAmount != null && this.form.maternityPersonalAmount !== '' && |
| | | this.form.industrialInjuryPersonalAmount != null && this.form.industrialInjuryPersonalAmount !== '' |
| | | ) { |
| | | // 税前金额 |
| | | // this.form.preTaxAmount = this.form.actualBasicWage + this.form.actualAchievementsWage + this.form.actualPerformanceWage + this.form.actualTeamWage - this.form.accumulationPersonalAmount - this.form.pensionPersonalAmount - this.form.medicalPersonalAmount - this.form.unemploymentPersonalAmount - this.form.maternityPersonalAmount - this.form.industrialInjuryPersonalAmount |
| | | this.form.preTaxAmount = 100 |
| | | // 个人所得税 |
| | | this.form.individualIncomeTax = 0 |
| | | // 税后金额 |
| | | this.form.afterTaxAmount = 100 |
| | | // 随机数 |
| | | this.random = Math.random() |
| | | // 清空统计定时器 |
| | | clearInterval(statisticsInterval) |
| | | } |
| | | }, 500) |
| | | }) |
| | | } |
| | | } |