| | |
| | | export function applyChagneDetailList (data) { |
| | | return request.post('/business/applyChagneDetail/list', data) |
| | | } |
| | | |
| | | // ä¿®æ¹ |
| | | export function update (data) { |
| | | return request.post('/business/applyChange/update', data) |
| | | } |
| | |
| | | <div class="desc_item_label_left"> |
| | | <span>æä¿ä¼ä¸ï¼{{ apply.companyName }}</span> |
| | | <span v-if="model.status === 0">ä¿åç¶æï¼å¾
ç¾ç½²</span> |
| | | <span v-if="model.status === 1">ä¿åç¶æï¼å·²ç¾ç« </span> |
| | | <span v-if="model.status === 1">ä¿åç¶æï¼å¾
å®¡æ ¸</span> |
| | | <span v-if="model.status === 2">ä¿åç¶æï¼å·²ä¸ä¼ æ¹å</span> |
| | | <span v-if="model.status === 3 || model.status === 4">ä¿åç¶æï¼éåç³è¯·</span> |
| | | <span v-if="model.status === 5 || model.status === 8">ä¿åç¶æï¼å·²éå</span> |
| | | <span v-if="model.status ===7">ä¿åç¶æï¼å·²å
³é</span> |
| | | <span v-if="model.status === 7 || model.status === 6">ä¿åç¶æï¼å·²å
³é</span> |
| | | <span>æäº¤æ¶é´ï¼{{ model.createDate }}</span> |
| | | </div> |
| | | <div class="desc_item_label_right"> |
| | | <template v-if="userInfo.type === 1"> |
| | | <el-button type="primary" @click="$refs.ApplyChangeDetails.open('å åä¿è¯¦å',apply,model)">导åºè¯¦å</el-button> |
| | | <el-button v-if="[5, 8].includes(model.status)" type="primary" @click="$refs.additionSubtractionApplication.open('å åä¿ç³è¯·', {id: dataId})">忬¡æä¿</el-button> |
| | | <el-button v-if="[5, 8].includes(model.status)" type="primary" @click="$refs.reinsurance.open('å åä¿ç³è¯·', {id: dataId, applyChangId: modelId})">忬¡æä¿</el-button> |
| | | <el-button type="primary" v-if="model.status == 0" @click="goSign">ç¾ç½²ç³è¯·å</el-button> |
| | | <el-button v-if="[2, 3, 7].includes(model.status)" type="primary">ç³è¯·éå</el-button> |
| | | <el-button v-if="[0, 1, 2, 3, 7].includes(model.status)" type="primary" @click="$refs.add_subtract_return.open('ç³è¯·éå', { id: modelId })">ç³è¯·éå</el-button> |
| | | <el-button v-if="model.status == 5" type="primary" @click="viewApplyFile">æ¥çç³è¯·å</el-button> |
| | | <el-button v-if="model.status == 5" type="primary" @click="viewPidan">æ¥çæ¹å</el-button> |
| | | <el-button v-if="model.status == 2" type="primary" @click="viewPidan">æ¥çæ¹å</el-button> |
| | | <el-button v-if="[5, 8].includes(model.status)" type="primary" @click="closeOrder">å
³é订å</el-button> |
| | | </template> |
| | | <template v-else> |
| | |
| | | <ApplyChangeDetails ref="ApplyChangeDetails" @success="successEvent" /> |
| | | <OperaApplyChangeCheckWindow ref="OperaApplyChangeCheckWindow" @success="successEvent" /> |
| | | <!-- ä¼ä¸ç³è¯·éå --> |
| | | <applyReturn ref="applyReturn" @success="successEvent" /> |
| | | <!-- <applyReturn ref="applyReturn" @success="successEvent" />--> |
| | | <add_subtract_return ref="add_subtract_return" @success="successEvent" /> |
| | | <!-- æ°å¢æä¿ --> |
| | | <OperaInsuranceApply ref="OperaInsuranceApply" @success="successEvent" /> |
| | | <!-- å åä¿ç³è¯· --> |
| | | <additionSubtractionApplication ref="additionSubtractionApplication" @success="successEvent" /> |
| | | <reinsurance ref="reinsurance" @success="successEvent" /> |
| | | <!-- æ¢åç³è¯· --> |
| | | <factoryChange ref="factoryChange" @success="successEvent" /> |
| | | </GlobalWindow> |
| | |
| | | import GlobalWindow from '@/components/common/GlobalWindow' |
| | | import ApplyChangeDetails from '@/components/business/ApplyChangeDetails' |
| | | import OperaApplyChangeCheckWindow from '@/components/business/OperaApplyChangeCheckWindow' |
| | | import additionSubtractionApplication from '@/components/enterprise/additionSubtractionApplication' |
| | | import reinsurance from '@/components/enterprise/reinsurance' |
| | | import factoryChange from '@/components/enterprise/factoryChange' |
| | | import applyReturn from '@/components/enterprise/applyReturn' |
| | | import add_subtract_return from '@/components/enterprise/add_subtract_return' |
| | | import { |
| | | getDetail, |
| | | getChangeDetail, |
| | |
| | | GlobalWindow, |
| | | ApplyChangeDetails, |
| | | OperaApplyChangeCheckWindow, |
| | | applyReturn, |
| | | add_subtract_return, |
| | | OperaInsuranceApply, |
| | | additionSubtractionApplication, |
| | | reinsurance, |
| | | factoryChange |
| | | }, |
| | | data () { |
| | |
| | | this.search() |
| | | }, |
| | | closeOrder() { |
| | | this.$confirm('确认å
³é次ä¿åå?', 'æç¤º', { |
| | | this.$confirm('确认å
³éæ¤è®¢åå?', 'æç¤º', { |
| | | confirmButtonText: 'ç¡®å®', |
| | | cancelButtonText: 'åæ¶', |
| | | type: 'warning' |
| | |
| | | <div class="desc_item_label_left"> |
| | | <span>æä¿ä¼ä¸ï¼{{ apply.companyName }}</span> |
| | | <span v-if="model.status === 0">ä¿åç¶æï¼å¾
ç¾ç½²</span> |
| | | <span v-if="model.status === 1">ä¿åç¶æï¼å·²ç¾ç« </span> |
| | | <span v-if="model.status === 1">ä¿åç¶æï¼å¾
å®¡æ ¸</span> |
| | | <span v-if="model.status === 2">ä¿åç¶æï¼å·²ä¸ä¼ æ¹å</span> |
| | | <span v-if="model.status === 3 || model.status === 4">ä¿åç¶æï¼éåç³è¯·</span> |
| | | <span v-if="model.status ===5 || model.status === 8">ä¿åç¶æï¼å·²éå</span> |
| | |
| | | </div> |
| | | <div class="desc_item_label_right"> |
| | | <template v-if="userInfo.type === 1"> |
| | | <el-button v-if="[0, 2, 3, 10].includes(model.status)" type="danger" @click="$refs.applyReturn.open('ç³è¯·éå', {id: dataId})">ç³è¯·éå</el-button> |
| | | <el-button v-if="model.status == 4" type="primary" @click="$refs.OperaInsuranceApply.open('æä¿ç³è¯·', {id: dataId})">忬¡æä¿</el-button> |
| | | <el-button type="primary" @click="$refs.InsuranceDetails.open('æä¿è¯¦æ
å',model,0)">ç¾ç½²ç³è¯·å</el-button> |
| | | <el-button v-if="[2, 3, 5, 7, 8].includes(model.status)" type="primary" @click="viewToubaodan">ç³è¯·éå</el-button> |
| | | <el-button v-if="model.status == 5" type="primary" @click="viewBaoxiandan">æ¥çç³è¯·å</el-button> |
| | | <el-button v-if="model.status == 5" type="primary" @click="viewBaoxiandan">æ¥çæ¹å</el-button> |
| | | <el-button v-if="model.status == 2" type="primary" @click="goSign">å
³é订å</el-button> |
| | | <el-button type="primary" @click="$refs.ApplyChangeDetails.open('æ¢åç³è¯·è¯¦å',apply,model)">导åºè¯¦å</el-button> |
| | | <!-- <el-button v-if="[0, 2, 3, 10].includes(model.status)" type="danger" @click="$refs.applyReturn.open('ç³è¯·éå', {id: dataId})">ç³è¯·éå</el-button>--> |
| | | <el-button v-if="[5, 8].includes(model.status)" type="primary" @click="$refs.editFactoryChange.open('æ¢åç³è¯·', {id: dataId, applyChangId: modelId})">忬¡æä¿</el-button> |
| | | <el-button type="primary" v-if="model.status == 0" @click="goSign">ç¾ç½²ç³è¯·å</el-button> |
| | | <el-button v-if="[0, 1, 2, 3, 7].includes(model.status)" type="primary" @click="$refs.add_subtract_return.open('ç³è¯·éå', { id: modelId })">ç³è¯·éå</el-button> |
| | | <el-button v-if="model.status == 5" type="primary" @click="viewApplyFile">æ¥çç³è¯·å</el-button> |
| | | <el-button v-if="model.status == 5" type="primary" @click="viewPidan">æ¥çæ¹å</el-button> |
| | | <el-button v-if="[5, 8].includes(model.status)" type="primary" @click="closeOrder">å
³é订å</el-button> |
| | | </template> |
| | | <template v-else> |
| | | <el-button type="primary" @click="$refs.ApplyChangeDetails.open('æ¢åç³è¯·è¯¦å',apply,model)">导åºè¯¦å</el-button> |
| | |
| | | <OperaApplyChangeUnitCheckWindow ref="OperaApplyChangeCheckWindow" @success="successEvent" /> |
| | | <!-- ä¼ä¸ç³è¯·éå --> |
| | | <applyReturn ref="applyReturn" @success="successEvent" /> |
| | | <add_subtract_return ref="add_subtract_return" @success="successEvent" /> |
| | | <!-- æ°å¢æä¿ --> |
| | | <OperaInsuranceApply ref="OperaInsuranceApply" @success="successEvent" /> |
| | | <!-- å åä¿ç³è¯· --> |
| | | <additionSubtractionApplication ref="additionSubtractionApplication" @success="successEvent" /> |
| | | <!-- æ¢åç³è¯· --> |
| | | <factoryChange ref="factoryChange" @success="successEvent" /> |
| | | |
| | | <editFactoryChange ref="editFactoryChange" @success="successEvent" /> |
| | | </GlobalWindow> |
| | | </template> |
| | | |
| | |
| | | import OperaApplyChangeUnitCheckWindow from '@/components/business/OperaApplyChangeUnitCheckWindow' |
| | | import additionSubtractionApplication from '@/components/enterprise/additionSubtractionApplication' |
| | | import factoryChange from '@/components/enterprise/factoryChange' |
| | | import editFactoryChange from '@/components/enterprise/editFactoryChange' |
| | | import applyReturn from '@/components/enterprise/applyReturn' |
| | | import add_subtract_return from '@/components/enterprise/add_subtract_return' |
| | | import { |
| | | getDetail, |
| | | getChangeDetail, |
| | | applyChagneDetailPage, |
| | | getChangeUnitSignLink |
| | | } from '@/api/business/insuranceApply' |
| | | import { applyChangeOpt } from '@/api/business/applyChange' |
| | | import OperaInsuranceApply from '@/components/enterprise/OperaInsuranceApplyWindow' |
| | | import { mapState } from 'vuex' |
| | | |
| | |
| | | applyReturn, |
| | | OperaInsuranceApply, |
| | | additionSubtractionApplication, |
| | | factoryChange |
| | | factoryChange, |
| | | add_subtract_return, |
| | | editFactoryChange |
| | | }, |
| | | data () { |
| | | return { |
| | |
| | | this.getDetail() |
| | | this.getList() |
| | | }, |
| | | closeOrder() { |
| | | this.$confirm('确认å
³éæ¤è®¢åå?', 'æç¤º', { |
| | | confirmButtonText: 'ç¡®å®', |
| | | cancelButtonText: 'åæ¶', |
| | | type: 'warning' |
| | | }).then(() => { |
| | | applyChangeOpt({ |
| | | optType: 6, |
| | | applyId: this.model.id |
| | | }).then(res => { |
| | | this.getDetail() |
| | | }).catch(e => { |
| | | this.$message.error(e) |
| | | }) |
| | | }).catch(() => { |
| | | |
| | | }); |
| | | }, |
| | | resetting() { |
| | | this.search() |
| | | }, |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <template> |
| | | <GlobalWindow |
| | | :title="title" |
| | | width="40%" |
| | | :visible.sync="visible" |
| | | :confirm-working="isWorking" |
| | | @confirm="confirm" |
| | | > |
| | | <el-form ref="form" :model="form" label-width="130px"> |
| | | <el-form-item label="å¡«åç³è¯·è¯´æ"> |
| | | <el-input type="textarea" v-model="form.remark"></el-input> |
| | | </el-form-item> |
| | | </el-form> |
| | | </GlobalWindow> |
| | | </template> |
| | | |
| | | <script> |
| | | import BaseOpera from '@/components/base/BaseOpera' |
| | | import GlobalWindow from '@/components/common/GlobalWindow' |
| | | import { applyChangeOpt } from '@/api/business/applyChange' |
| | | |
| | | export default { |
| | | name: 'add_subtract_return', |
| | | extends: BaseOpera, |
| | | components: { GlobalWindow }, |
| | | data () { |
| | | return { |
| | | // è¡¨åæ°æ® |
| | | form: { |
| | | id: null, |
| | | remark: '' |
| | | } |
| | | } |
| | | }, |
| | | created () { |
| | | this.config({ |
| | | api: '/business/insurance', |
| | | 'field.id': 'id' |
| | | }) |
| | | }, |
| | | methods: { |
| | | open (title, target) { |
| | | this.title = title |
| | | this.visible = true |
| | | this.$nextTick(() => { |
| | | this.$refs.form.resetFields() |
| | | this.form[this.configData['field.id']] = null |
| | | }) |
| | | this.$nextTick(() => { |
| | | for (const key in this.form) { |
| | | this.form[key] = target[key] |
| | | } |
| | | }) |
| | | }, |
| | | confirm() { |
| | | this.isWorking = true |
| | | applyChangeOpt({ applyId: this.form.id, optIllustration: this.form.remark, optType: 3 }) |
| | | .then(res => { |
| | | this.visible = false |
| | | this.$tip.apiSuccess('æä½æå') |
| | | this.$emit('success') |
| | | }) |
| | | .catch(e => { |
| | | this.$tip.apiFailed(e) |
| | | }) |
| | | .finally(() => { |
| | | this.isWorking = false |
| | | }) |
| | | } |
| | | } |
| | | } |
| | | </script> |
| | |
| | | import confirmJobType from '@/components/enterprise/confirmJobType' |
| | | import { all } from '@/api/business/solutions' |
| | | import { getDetail } from '@/api/business/insuranceApply' |
| | | import { create, getChangeCountCyclePriceVO, applyChagneDetailList } from '@/api/business/applyChange' |
| | | import { create, getChangeCountCyclePriceVO } from '@/api/business/applyChange' |
| | | export default { |
| | | name: 'additionSubtractionApplication', |
| | | extends: BaseOpera, |
| | |
| | | }, |
| | | handleClick(e) { |
| | | this.activeName = e.index |
| | | }, |
| | | getApplyChagneDetailList() { |
| | | applyChagneDetailList({ |
| | | |
| | | }) |
| | | }, |
| | | // è·åæä¿è¯¦æ
|
| | | getDetails() { |
| | |
| | | methods: { |
| | | open (title, arr) { |
| | | this.title = title |
| | | this.dw = '' |
| | | this.gz = '' |
| | | this.form.solutionId = arr.solutionId |
| | | this.data = arr.seleData |
| | | this.visible = true |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <template> |
| | | <GlobalWindow |
| | | :title="title" |
| | | width="100%" |
| | | text="æä¿ç³è¯·" |
| | | :visible.sync="visible" |
| | | :confirm-working="isWorking" |
| | | @confirm="confirm" |
| | | > |
| | | <div class="list"> |
| | | <el-form :inline="true" ref="form" :model="form" :rules="rules" class="demo-form-inline"> |
| | | <el-form-item label="ä¿é©æ¹æ¡"> |
| | | <span>{{form.solutionsName}}</span> |
| | | </el-form-item> |
| | | <el-form-item label="æ¹åçæèµ·æ" prop="applyStartTime"> |
| | | <div style="display: flex; flex-direction: column;"> |
| | | <el-date-picker |
| | | v-model="form.applyStartTime" |
| | | type="datetime" |
| | | :picker-options="pickerOptions" |
| | | value-format="yyyy-MM-dd hh:mm:ss" |
| | | format="yyyy-MM-dd hh:mm:ss" |
| | | placeholder="éæ©æ¥æ"> |
| | | </el-date-picker> |
| | | <span style="color: #F95601; font-size: 14px;">ï¼æ¬¡æ¥çææä¿è¯·äº17:30åæäº¤ï¼è¶
æ¶æäº¤ä»¥ä¿é©å为åï¼</span> |
| | | </div> |
| | | </el-form-item> |
| | | <el-form-item label="æä¿å¹´é¾" v-if="item"> |
| | | <span>{{item.minAge}} è³ {{item.maxAge}}</span> |
| | | </el-form-item> |
| | | <el-form-item label="è´¹ç¨" v-if="item"> |
| | | <span>{{item.price}}å
</span> |
| | | <span v-if="item.timeUnit === 0">/天</span> |
| | | <span v-if="item.timeUnit === 1">/åæ</span> |
| | | <span v-if="item.timeUnit === 2">/æ</span> |
| | | <span v-if="item.timeUnit === 3">/å¹´</span> |
| | | <span>/人</span> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | | <div class="desc_item_from"> |
| | | <el-table |
| | | :data="list" |
| | | border |
| | | style="width: 100%"> |
| | | <el-table-column |
| | | prop="code" |
| | | align="center" |
| | | label="å
³èä¿åå·"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="solutionsName" |
| | | label="ä¿é©æ¹æ¡" |
| | | align="center" |
| | | width="180"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="startTime" |
| | | align="center" |
| | | label="ä¿é©çæèµ·æ"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="endTime" |
| | | align="center" |
| | | label="ä¿é©çææ¢æ"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="insureNum" |
| | | align="center" |
| | | label="æä¿äººæ°"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="serviceDays" |
| | | align="center" |
| | | label="å¨ä¿æ¶é¿ï¼å¤©ï¼"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="currentFee" |
| | | align="center" |
| | | label="å½åè´¹ç¨(å
)"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="fee" |
| | | align="center" |
| | | label="æ»è´¹ç¨(å
)"> |
| | | </el-table-column> |
| | | </el-table> |
| | | </div> |
| | | <div class="btns"> |
| | | <div class="btns_item"> |
| | | <el-button type="primary" @click="seleUser">éååå·¥</el-button> |
| | | <el-button type="danger" @click="deleItem">å é¤</el-button> |
| | | </div> |
| | | <div class="btns_item"> |
| | | <el-button type="primary" @click="sele">éåæ´¾é£åä½</el-button> |
| | | </div> |
| | | </div> |
| | | <el-table |
| | | :data="form.factory" |
| | | border |
| | | ref="multipleTable" |
| | | @selection-change="handleSelectionChange" |
| | | style="width: 100%;margin-bottom: 15px;"> |
| | | <el-table-column |
| | | type="selection" |
| | | width="55"> |
| | | </el-table-column> |
| | | <el-table-column label="åºå·" width="80px"> |
| | | <template slot-scope="scope"> |
| | | <span>{{scope.$index + 1}}</span> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="memberName" |
| | | label="å§å"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="idCard" |
| | | label="身份è¯å·"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="oldDuName" |
| | | label="åæ´¾é£åä½"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="oldWorkTypeName" |
| | | label="åæå±å·¥ç§"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="duName" |
| | | label="åæ´åæ´¾é£åä½"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="workTypeName" |
| | | label="åæ´åæå±å·¥ç§"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | label="æä½"> |
| | | <template slot-scope="scope"> |
| | | <el-button type="text" style="color: red;" @click="dele(scope.$index)">å é¤</el-button> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | | <div class="info" v-if="item"> |
| | | <span v-if="item.specialAgreement">{{item.specialAgreement}}</span> |
| | | <span v-if="item.specialInfo">{{item.specialInfo}}</span> |
| | | <span v-if="item.ortherInfo">{{item.ortherInfo}}</span> |
| | | </div> |
| | | <!-- éæ©åå·¥ --> |
| | | <selectEmployees ref="selectEmployees" @result="getValue" /> |
| | | <!-- æ·»å åå·¥ --> |
| | | <addEmployee ref="addEmployee" @result="getValue" /> |
| | | <!-- 导å
¥åå --> |
| | | <importEmployees ref="importEmployees" @result="getValue" /> |
| | | <!-- ç¡®è®¤å·¥ç§ --> |
| | | <confirmJobType ref="confirmJobType" @result="getUser" /> |
| | | </GlobalWindow> |
| | | </template> |
| | | |
| | | <script> |
| | | import BaseOpera from '@/components/base/BaseOpera' |
| | | import GlobalWindow from '@/components/common/GlobalWindow' |
| | | import selectEmployees from '@/components/enterprise/selectEmployees' |
| | | import addEmployee from '@/components/enterprise/addEmployee' |
| | | import importEmployees from '@/components/enterprise/importEmployees' |
| | | import confirmJobType from '@/components/enterprise/confirmJobType' |
| | | import { all } from '@/api/business/solutions' |
| | | import { getDetail, findList } from '@/api/business/insuranceApply' |
| | | import { create, update, applyChagneDetailList } from '@/api/business/applyChange' |
| | | export default { |
| | | name: 'editFactoryChange', |
| | | extends: BaseOpera, |
| | | components: { GlobalWindow, selectEmployees, addEmployee, importEmployees, confirmJobType }, |
| | | data () { |
| | | return { |
| | | form: { |
| | | id: null, |
| | | applyChangId: '', |
| | | solutionId: '', |
| | | solutionsName: '', |
| | | applyStartTime: '', |
| | | applyEndTime: '', |
| | | factory: [] |
| | | }, |
| | | pickerOptions: {}, |
| | | price: '', |
| | | endTime: '', // å®é
ä¿é©çææ¢æ |
| | | company: [], |
| | | seleData: [], |
| | | item: null, |
| | | // éªè¯è§å |
| | | rules: { |
| | | applyStartTime: [ |
| | | { required: true, message: 'è¯·éæ©æ¹åçæèµ·æ' } |
| | | ] |
| | | }, |
| | | list: [] |
| | | } |
| | | }, |
| | | created () { |
| | | this.config({ |
| | | api: '/business/insuranceApply', |
| | | 'field.id': 'id' |
| | | }) |
| | | }, |
| | | methods: { |
| | | open (title, target) { |
| | | this.title = title |
| | | this.form.addDetailList = [] |
| | | this.form.delDetailList = [] |
| | | this.list = [] |
| | | this.form.id = null |
| | | this.item = null |
| | | this.form.solutionId = '' |
| | | this.form.solutionsName = '' |
| | | this.form.applyStartTime = '' |
| | | this.form.applyEndTime = '' |
| | | if (target && target.id) { |
| | | this.$nextTick(() => { |
| | | this.$refs.form.resetFields() |
| | | this.form.id = target.id |
| | | this.form.applyChangId = target.applyChangId |
| | | this.getDetails() |
| | | this.getapplyChagneDetailList() |
| | | }) |
| | | } else { |
| | | this.$nextTick(() => { |
| | | this.$refs.form.resetFields() |
| | | this.form[this.configData['field.id']] = null |
| | | }) |
| | | } |
| | | this.getCompany() |
| | | this.visible = true |
| | | // this.updatePickerOptions() |
| | | }, |
| | | // è·åæ¢å人å |
| | | getapplyChagneDetailList() { |
| | | applyChagneDetailList({ |
| | | applyChangId: this.form.applyChangId, |
| | | types: [2] |
| | | }).then(res => { |
| | | res.forEach(item => { |
| | | item.idCard = item.memberIdcardNo |
| | | item.oldDuId = item.duId |
| | | item.oldDuName = item.duName |
| | | item.oldWorkTypeName = item.workTypeName |
| | | item.oldWorktypeId = item.worktypeId |
| | | item.workTypeName = '' |
| | | item.worktypeId = '' |
| | | item.duId = '' |
| | | item.duName = '' |
| | | }) |
| | | this.form.factory = res |
| | | }) |
| | | }, |
| | | // è·åæä¿è¯¦æ
|
| | | getDetails() { |
| | | findList({ applyId: this.form.id }) |
| | | .then(res => { |
| | | res.forEach(item => { |
| | | item.idCard = item.idcardNo |
| | | item.fee = '' |
| | | }) |
| | | res.forEach(item => { |
| | | item.oldDuId = item.duId |
| | | item.oldDuName = item.duName |
| | | item.oldWorkTypeName = item.workTypeName |
| | | item.oldWorktypeId = item.worktypeId |
| | | item.workTypeName = '' |
| | | item.worktypeId = '' |
| | | item.duId = '' |
| | | item.duName = '' |
| | | }) |
| | | // this.form.factory = res |
| | | }) |
| | | getDetail(this.form.id) |
| | | .then(res => { |
| | | this.list.push(res) |
| | | this.endTime = res.endTime |
| | | this.form.solutionId = res.solutionId |
| | | this.form.solutionsName = res.solutionsName |
| | | this.pickerOptions = { |
| | | disabledDate(time) { |
| | | // - 8.64e7 |
| | | return time.getTime() > new Date(res.endTime).getTime() || time.getTime() < new Date().getTime() |
| | | } |
| | | }; |
| | | this.changeSolution1(res.solutionId) |
| | | }) |
| | | }, |
| | | deleItem() { |
| | | if (this.seleData.length === 0) { |
| | | this.$message.warning('è³å°éæ©ä¸é¡¹å
容') |
| | | return |
| | | } |
| | | this.seleData.forEach(item => { |
| | | this.form.factory.forEach((row, index) => { |
| | | if (item === row.memberName) { |
| | | this.form.factory.splice(index, 1) |
| | | } |
| | | }) |
| | | }) |
| | | }, |
| | | confirm() { |
| | | this.$refs.form.validate((valid) => { |
| | | if (valid) { |
| | | // if (this.form.addDetailList.length === 0) { |
| | | // this.$message.warning('è³å°æ·»å ä¸é¡¹åå·¥') |
| | | // return |
| | | // } |
| | | for (let i = 0; i < this.form.factory.length; i++) { |
| | | if (!this.form.factory[i].worktypeId || !this.form.factory[i].duId) { |
| | | this.$message.warning('请å®åæ´¾é£åä½åå·¥ç§ä¿¡æ¯') |
| | | return |
| | | } |
| | | } |
| | | this.form.factory.forEach(item => { |
| | | item.idcardNo = item.idCard |
| | | }) |
| | | // let arr = JSON.parse(JSON.stringify(this.form.factory)) |
| | | // arr.forEach(item => { |
| | | // item.idcardNo = item.idCard |
| | | // }) |
| | | this.isWorking = true |
| | | update({ |
| | | id: this.form.applyChangId, |
| | | applyId: this.form.id, |
| | | changeDetailList: this.form.factory, |
| | | validTime: this.form.applyStartTime, |
| | | type: 1 |
| | | }).then(() => { |
| | | this.visible = false |
| | | this.$tip.apiSuccess('æä½æå') |
| | | this.$emit('success') |
| | | }).catch(e => { |
| | | this.$tip.apiFailed(e) |
| | | }).finally(() => { |
| | | this.isWorking = false |
| | | }) |
| | | } |
| | | }) |
| | | }, |
| | | seleUser() { |
| | | if (!this.form.solutionId) { |
| | | this.$message.warning('请å
éæ©ä¿é©æ¹æ¡') |
| | | return |
| | | } |
| | | this.$refs.selectEmployees.open('éååå·¥', { arr: this.form.delDetailList, price: this.price, insuranceApplyId: this.form.id }) |
| | | }, |
| | | addUser() { |
| | | if (!this.form.solutionId) { |
| | | this.$message.warning('请å
éæ©ä¿é©æ¹æ¡') |
| | | return |
| | | } |
| | | this.$refs.addEmployee.open('æ·»å åå·¥', { arr: this.form.factory, price: this.price }) |
| | | }, |
| | | uploadUser() { |
| | | if (!this.form.solutionId) { |
| | | this.$message.warning('请å
éæ©ä¿é©æ¹æ¡') |
| | | return |
| | | } |
| | | this.$refs.importEmployees.open('ä¸ä¼ åå', { arr: this.form.factory, price: this.price }) |
| | | }, |
| | | // åæ¢æ¹æ¡ |
| | | changeSolution1(e) { |
| | | this.company.forEach(item => { |
| | | if (item.id === e) { |
| | | this.item = item |
| | | } |
| | | }) |
| | | // this.tableData.forEach(item => { |
| | | // item.fee = this.price |
| | | // }) |
| | | }, |
| | | dele(index) { |
| | | this.form.factory.splice(index, 1) |
| | | }, |
| | | getUser(obj) { |
| | | console.log(obj) |
| | | this.seleData.forEach(item => { |
| | | this.form.factory.forEach(row => { |
| | | if (item === row.memberName) { |
| | | row.workTypeName = obj.workTypeName |
| | | row.worktypeId = obj.worktypeId |
| | | row.duName = obj.duName |
| | | row.duId = obj.duId |
| | | } |
| | | }) |
| | | }) |
| | | this.seleData = [] |
| | | this.$refs.multipleTable.clearSelection(); |
| | | }, |
| | | // éæ©åå·¥ |
| | | sele() { |
| | | if (!this.form.solutionId) { |
| | | this.$message.warning('è¯·éæ©ä¿é©æ¹æ¡') |
| | | return |
| | | } |
| | | if (this.seleData.length === 0) { |
| | | this.$message.warning('è¯·éæ©åå·¥') |
| | | return |
| | | } |
| | | this.$refs.confirmJobType.open('确认工ç§', { solutionId: this.form.solutionId }) |
| | | }, |
| | | // æ¥è¯¢å
¨é¨æ¹æ¡ |
| | | getCompany() { |
| | | all({}) |
| | | .then(res => { |
| | | this.company = res |
| | | }) |
| | | }, |
| | | getAgeByIdCard(idCard){ |
| | | const sexAndAge = {} |
| | | //è·åç¨æ·èº«ä»½è¯å·ç |
| | | const userCard = idCard |
| | | //å¦æç¨æ·èº«ä»½è¯å·ç 为undefinedåè¿å空 |
| | | if (!userCard) { |
| | | return sexAndAge |
| | | } |
| | | // è·ååºçæ¥æ |
| | | const yearBirth = userCard.substring(6, 10) |
| | | const monthBirth = userCard.substring(10, 12) |
| | | const dayBirth = userCard.substring(12, 14) |
| | | // è·åå½åå¹´ææ¥å¹¶è®¡ç®å¹´é¾ |
| | | const myDate = new Date() |
| | | const monthNow = myDate.getMonth() + 1 |
| | | const dayNow = myDate.getDate() |
| | | let age = myDate.getFullYear() - yearBirth |
| | | if (monthNow < monthBirth || (monthNow == monthBirth && dayNow < dayBirth)) { |
| | | age-- |
| | | } |
| | | // å¾å°å¹´é¾ |
| | | sexAndAge.age = age |
| | | return sexAndAge.age |
| | | }, |
| | | handleSelectionChange (e) { |
| | | this.seleData = e.map(item => item.memberName) |
| | | }, |
| | | getValue(list) { |
| | | let arr = JSON.parse(JSON.stringify(list)) |
| | | |
| | | arr.forEach(item => { |
| | | item.oldDuId = item.duId |
| | | item.oldDuName = item.duName |
| | | item.oldWorkTypeName = item.workTypeName |
| | | item.oldWorktypeId = item.worktypeId |
| | | |
| | | item.duId = '' |
| | | item.duName = '' |
| | | item.workTypeName = '' |
| | | item.worktypeId = '' |
| | | }) |
| | | this.form.factory.push(...arr) |
| | | } |
| | | } |
| | | } |
| | | </script> |
| | | |
| | | <style lang="scss" scoped> |
| | | .list { |
| | | width: 100%; |
| | | } |
| | | .btns { |
| | | width: 100%; |
| | | margin-bottom: 15px; |
| | | display: flex; |
| | | align-items: center; |
| | | justify-content: space-between; |
| | | .btns_item { |
| | | display: flex; |
| | | align-items: center; |
| | | } |
| | | } |
| | | .submit { |
| | | width: 100%; |
| | | display: flex; |
| | | align-items: center; |
| | | justify-content: center; |
| | | margin-bottom: 15px; |
| | | } |
| | | .desc_item_from { |
| | | width: 100%; |
| | | margin-bottom: 10px; |
| | | .desc_item_from_page { |
| | | width: 100%; |
| | | display: flex; |
| | | align-items: center; |
| | | justify-content: end; |
| | | margin-top: 10px; |
| | | } |
| | | } |
| | | .desc_item_cate { |
| | | width: 100%; |
| | | margin-bottom: 10px; |
| | | } |
| | | .info { |
| | | width: 100%; |
| | | font-size: 14px; |
| | | color: black; |
| | | } |
| | | </style> |
| | |
| | | <div style="display: flex; flex-direction: column;"> |
| | | <el-date-picker |
| | | v-model="form.applyStartTime" |
| | | type="date" |
| | | type="datetime" |
| | | :picker-options="pickerOptions" |
| | | value-format="yyyy-MM-dd" |
| | | format="yyyy å¹´ MM æ dd æ¥" |
| | | value-format="yyyy-MM-dd hh:mm:ss" |
| | | format="yyyy-MM-dd hh:mm:ss" |
| | | placeholder="éæ©æ¥æ"> |
| | | </el-date-picker> |
| | | <span style="color: #F95601; font-size: 14px;">ï¼æ¬¡æ¥çææä¿è¯·äº17:30åæäº¤ï¼è¶
æ¶æäº¤ä»¥ä¿é©å为åï¼</span> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <template> |
| | | <GlobalWindow |
| | | :title="title" |
| | | width="100%" |
| | | text="æä¿ç³è¯·" |
| | | :visible.sync="visible" |
| | | :confirm-working="isWorking" |
| | | @confirm="confirm" |
| | | > |
| | | <div class="list"> |
| | | <el-form :inline="true" ref="form" :model="form" :rules="rules" class="demo-form-inline"> |
| | | <el-form-item label="ä¿é©æ¹æ¡"> |
| | | <span>{{form.solutionsName}}</span> |
| | | </el-form-item> |
| | | <el-form-item label="æ¹åçæèµ·æ" prop="applyStartTime"> |
| | | <div style="display: flex; flex-direction: column;"> |
| | | <el-date-picker |
| | | @change="changeApplyStartTime" |
| | | v-model="form.applyStartTime" |
| | | type="date" |
| | | :picker-options="pickerOptions" |
| | | value-format="yyyy-MM-dd" |
| | | format="yyyy å¹´ MM æ dd æ¥" |
| | | placeholder="éæ©æ¥æ"> |
| | | </el-date-picker> |
| | | <span style="color: #F95601; font-size: 14px;">ï¼æ¬¡æ¥çææä¿è¯·äº17:30åæäº¤ï¼è¶
æ¶æäº¤ä»¥ä¿é©å为åï¼</span> |
| | | </div> |
| | | </el-form-item> |
| | | <el-form-item label="æä¿å¹´é¾" v-if="item"> |
| | | <span>{{item.minAge}} è³ {{item.maxAge}}</span> |
| | | </el-form-item> |
| | | <el-form-item label="è´¹ç¨" v-if="item"> |
| | | <span>{{item.price}}å
</span> |
| | | <span v-if="item.timeUnit === 0">/天</span> |
| | | <span v-if="item.timeUnit === 1">/åæ</span> |
| | | <span v-if="item.timeUnit === 2">/æ</span> |
| | | <span v-if="item.timeUnit === 3">/å¹´</span> |
| | | <span>/人</span> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | | <div class="desc_item_from"> |
| | | <el-table |
| | | :data="list" |
| | | border |
| | | style="width: 100%"> |
| | | <el-table-column |
| | | prop="code" |
| | | align="center" |
| | | label="å
³èä¿åå·"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="solutionsName" |
| | | label="ä¿é©æ¹æ¡" |
| | | align="center" |
| | | width="180"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="startTime" |
| | | align="center" |
| | | label="ä¿é©çæèµ·æ"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="endTime" |
| | | align="center" |
| | | label="ä¿é©çææ¢æ"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="insureNum" |
| | | align="center" |
| | | label="æä¿äººæ°"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="serviceDays" |
| | | align="center" |
| | | label="å¨ä¿æ¶é¿ï¼å¤©ï¼"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="currentFee" |
| | | align="center" |
| | | label="å½åè´¹ç¨(å
)"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="fee" |
| | | align="center" |
| | | label="æ»è´¹ç¨(å
)"> |
| | | </el-table-column> |
| | | </el-table> |
| | | </div> |
| | | <div class="desc_item_cate"> |
| | | <el-tabs v-model="activeName" @tab-click="handleClick"> |
| | | <el-tab-pane label="å ä¿åå·¥" name="0"></el-tab-pane> |
| | | <el-tab-pane label="åä¿åå·¥" name="1"></el-tab-pane> |
| | | </el-tabs> |
| | | </div> |
| | | <div class="btns"> |
| | | <div class="btns_item"> |
| | | <el-button type="primary" @click="seleUser">éååå·¥</el-button> |
| | | <el-button type="primary" @click="uploadUser" v-if="activeName !== '1'">导å
¥åå·¥</el-button> |
| | | <el-button type="primary" @click="addUser" v-if="activeName !== '1'">æ·»å åå·¥</el-button> |
| | | <el-button type="danger" @click="deleItem">å é¤</el-button> |
| | | </div> |
| | | <div class="btns_item" v-if="activeName !== '1'"> |
| | | <el-button type="primary" @click="sele">éåæ´¾é£åä½</el-button> |
| | | </div> |
| | | </div> |
| | | <el-table |
| | | :data="activeName === '0' ? form.addDetailList : form.delDetailList" |
| | | border |
| | | show-summary |
| | | :summary-method="getSummaries" |
| | | ref="multipleTable" |
| | | @selection-change="handleSelectionChange" |
| | | style="width: 100%;margin-bottom: 15px;"> |
| | | <el-table-column |
| | | type="selection" |
| | | width="55"> |
| | | </el-table-column> |
| | | <el-table-column label="åºå·" width="80px"> |
| | | <template slot-scope="scope"> |
| | | <span>{{scope.$index + 1}}</span> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="memberName" |
| | | label="å§å"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="idCard" |
| | | label="身份è¯å·"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | label="å¹´é¾"> |
| | | <template slot-scope="{row}"> |
| | | <template v-if="item"> |
| | | <span style="color: red;" v-if="(getAgeByIdCard(row.idCard) < item.minAge) || (getAgeByIdCard(row.idCard) > item.maxAge)">{{getAgeByIdCard(row.idCard)}}</span> |
| | | <span v-else>{{ getAgeByIdCard(row.idCard) }}</span> |
| | | </template> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="duName" |
| | | label="æ´¾é£åä½"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="workTypeName" |
| | | label="æå±å·¥ç§"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | label="è´¹ç¨"> |
| | | <template slot-scope="{row}"> |
| | | <span v-if="activeName === '0'">{{row.fee}}</span> |
| | | <span v-else>-{{row.fee}}</span> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column |
| | | label="æä½"> |
| | | <template slot-scope="scope"> |
| | | <el-button type="text" style="color: red;" @click="dele(scope.$index)">å é¤</el-button> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | | <div class="info" v-if="item"> |
| | | <span v-if="item.specialAgreement">{{item.specialAgreement}}</span> |
| | | <span v-if="item.specialInfo">{{item.specialInfo}}</span> |
| | | <span v-if="item.ortherInfo">{{item.ortherInfo}}</span> |
| | | </div> |
| | | <!-- éæ©åå·¥ --> |
| | | <selectEmployees ref="selectEmployees" @result="getValue" /> |
| | | <!-- æ·»å åå·¥ --> |
| | | <addEmployee ref="addEmployee" @result="getValue" /> |
| | | <!-- 导å
¥åå --> |
| | | <importEmployees ref="importEmployees" @result="getValue" /> |
| | | <!-- ç¡®è®¤å·¥ç§ --> |
| | | <confirmJobType ref="confirmJobType" @result="getUser" /> |
| | | </GlobalWindow> |
| | | </template> |
| | | |
| | | <script> |
| | | import BaseOpera from '@/components/base/BaseOpera' |
| | | import GlobalWindow from '@/components/common/GlobalWindow' |
| | | import selectEmployees from '@/components/enterprise/selectEmployees' |
| | | import addEmployee from '@/components/enterprise/addEmployee' |
| | | import importEmployees from '@/components/enterprise/importEmployees' |
| | | import confirmJobType from '@/components/enterprise/confirmJobType' |
| | | import { all } from '@/api/business/solutions' |
| | | import { getDetail } from '@/api/business/insuranceApply' |
| | | import { update, getChangeCountCyclePriceVO, applyChagneDetailList } from '@/api/business/applyChange' |
| | | export default { |
| | | name: 'reinsurance', |
| | | extends: BaseOpera, |
| | | components: { GlobalWindow, selectEmployees, addEmployee, importEmployees, confirmJobType }, |
| | | data () { |
| | | return { |
| | | form: { |
| | | id: null, |
| | | applyChangId: '', |
| | | solutionId: '', |
| | | solutionsName: '', |
| | | applyStartTime: '', |
| | | applyEndTime: '', |
| | | addDetailList: [], |
| | | delDetailList: [], |
| | | }, |
| | | activeName: '0', |
| | | pickerOptions: {}, |
| | | price: '', |
| | | endTime: '', // å®é
ä¿é©çææ¢æ |
| | | company: [], |
| | | seleData: [], |
| | | item: null, |
| | | // éªè¯è§å |
| | | rules: { |
| | | applyStartTime: [ |
| | | { required: true, message: 'è¯·éæ©æ¹åçæèµ·æ' } |
| | | ] |
| | | }, |
| | | list: [] |
| | | } |
| | | }, |
| | | created () { |
| | | this.config({ |
| | | api: '/business/insuranceApply', |
| | | 'field.id': 'id' |
| | | }) |
| | | }, |
| | | methods: { |
| | | open (title, target) { |
| | | this.title = title |
| | | this.form.addDetailList = [] |
| | | this.form.delDetailList = [] |
| | | this.list = [] |
| | | this.form.id = null |
| | | this.item = null |
| | | this.form.solutionId = '' |
| | | this.form.solutionsName = '' |
| | | this.form.applyStartTime = '' |
| | | this.form.applyEndTime = '' |
| | | if (target && target.id) { |
| | | this.$nextTick(() => { |
| | | this.$refs.form.resetFields() |
| | | this.form.id = target.id |
| | | this.form.applyChangId = target.applyChangId |
| | | this.getDetails() |
| | | }) |
| | | } else { |
| | | this.$nextTick(() => { |
| | | this.$refs.form.resetFields() |
| | | this.form[this.configData['field.id']] = null |
| | | }) |
| | | } |
| | | this.getCompany() |
| | | this.visible = true |
| | | // this.updatePickerOptions() |
| | | }, |
| | | changeApplyStartTime(e) { |
| | | getChangeCountCyclePriceVO({ |
| | | applyId: this.form.id, |
| | | validTime: e |
| | | }).then(res => { |
| | | this.price = res.cyclePrice |
| | | this.form.addDetailList.forEach(item => { |
| | | item.fee = res.cyclePrice |
| | | }) |
| | | this.form.delDetailList.forEach(item => { |
| | | item.fee = res.cyclePrice |
| | | }) |
| | | }) |
| | | }, |
| | | handleClick(e) { |
| | | this.activeName = e.index |
| | | }, |
| | | // è·åæä¿è¯¦æ
|
| | | getDetails() { |
| | | applyChagneDetailList({ |
| | | applyChangId: this.form.applyChangId, |
| | | types: [0] |
| | | }).then(res => { |
| | | res.forEach(item => { |
| | | item.fee = '' |
| | | item.idCard = item.memberIdcardNo |
| | | item.workTypeName = '' |
| | | item.worktypeId = '' |
| | | item.duName = '' |
| | | item.duId = '' |
| | | }) |
| | | this.form.addDetailList = res |
| | | }) |
| | | applyChagneDetailList({ |
| | | applyChangId: this.form.applyChangId, |
| | | types: [1] |
| | | }).then(res => { |
| | | res.forEach(item => { |
| | | item.fee = '' |
| | | item.idCard = item.memberIdcardNo |
| | | item.workTypeName = '' |
| | | item.worktypeId = '' |
| | | item.duName = '' |
| | | item.duId = '' |
| | | }) |
| | | this.form.delDetailList = res |
| | | }) |
| | | getDetail(this.form.id) |
| | | .then(res => { |
| | | this.list.push(res) |
| | | this.endTime = res.endTime |
| | | this.form.solutionId = res.solutionId |
| | | this.form.solutionsName = res.solutionsName |
| | | this.pickerOptions = { |
| | | disabledDate(time) { |
| | | // - 8.64e7 |
| | | return time.getTime() > new Date(res.endTime).getTime() || time.getTime() < new Date().getTime() |
| | | } |
| | | }; |
| | | this.changeSolution1(res.solutionId) |
| | | }) |
| | | }, |
| | | getSummaries(param) { |
| | | const { columns, data } = param |
| | | const sums = [] |
| | | columns.forEach((column, index) => { |
| | | if (index === 0) { |
| | | sums[index] = 'æ»ä»·' |
| | | return |
| | | } else if (index === 7) { |
| | | let total = 0 |
| | | if (this.activeName === '0') { |
| | | this.form.addDetailList.forEach(item => { |
| | | total += item.fee |
| | | }) |
| | | sums[index] = total |
| | | return |
| | | } else { |
| | | this.form.delDetailList.forEach(item => { |
| | | total += item.fee |
| | | }) |
| | | sums[index] = '-' + total |
| | | return |
| | | } |
| | | sums[index] = '' |
| | | } |
| | | }) |
| | | return sums |
| | | }, |
| | | deleItem() { |
| | | if (this.seleData.length === 0) { |
| | | this.$message.warning('è³å°éæ©ä¸é¡¹å
容') |
| | | return |
| | | } |
| | | if (this.activeName === '0') { |
| | | this.seleData.forEach(item => { |
| | | this.form.addDetailList.forEach((row, index) => { |
| | | if (item === row.name) { |
| | | this.form.addDetailList.splice(index, 1) |
| | | } |
| | | }) |
| | | }) |
| | | } else { |
| | | this.seleData.forEach(item => { |
| | | this.form.delDetailList.forEach((row, index) => { |
| | | if (item === row.name) { |
| | | this.form.delDetailList.splice(index, 1) |
| | | } |
| | | }) |
| | | }) |
| | | } |
| | | }, |
| | | confirm() { |
| | | this.$refs.form.validate((valid) => { |
| | | if (valid) { |
| | | // if (this.form.addDetailList.length === 0) { |
| | | // this.$message.warning('è³å°æ·»å ä¸é¡¹åå·¥') |
| | | // return |
| | | // } |
| | | for (let i = 0; i < this.form.addDetailList.length; i++) { |
| | | if (!this.form.addDetailList[i].worktypeId || !this.form.addDetailList[i].duId) { |
| | | this.$message.warning('请å®åå ä¿æ´¾é£åä½åå·¥ç§ä¿¡æ¯') |
| | | return |
| | | } |
| | | } |
| | | for (let i = 0; i < this.form.delDetailList.length; i++) { |
| | | if (!this.form.delDetailList[i].worktypeId || !this.form.delDetailList[i].duId) { |
| | | this.$message.warning('请å®ååä¿æ´¾é£åä½åå·¥ç§ä¿¡æ¯') |
| | | return |
| | | } |
| | | } |
| | | this.form.addDetailList.forEach(item => { |
| | | item.idcardNo = item.idCard |
| | | }) |
| | | this.form.delDetailList.forEach(item => { |
| | | item.idcardNo = item.idCard |
| | | }) |
| | | // let arr = JSON.parse(JSON.stringify(this.form.addDetailList)) |
| | | // arr.forEach(item => { |
| | | // item.idcardNo = item.idCard |
| | | // }) |
| | | this.isWorking = true |
| | | update({ |
| | | id: this.form.applyChangId, |
| | | applyId: this.form.id, |
| | | addDetailList: this.form.addDetailList, |
| | | delDetailList: this.form.delDetailList, |
| | | validTime: this.form.applyStartTime, |
| | | type: 0 |
| | | }).then(() => { |
| | | this.visible = false |
| | | this.$tip.apiSuccess('æä½æå') |
| | | this.$emit('success') |
| | | }).catch(e => { |
| | | this.$tip.apiFailed(e) |
| | | }).finally(() => { |
| | | this.isWorking = false |
| | | }) |
| | | } |
| | | }) |
| | | }, |
| | | seleUser() { |
| | | if (!this.form.solutionId) { |
| | | this.$message.warning('请å
éæ©ä¿é©æ¹æ¡') |
| | | return |
| | | } |
| | | if (this.activeName === '0') { |
| | | this.$refs.selectEmployees.open('éååå·¥', { arr: this.form.addDetailList, price: this.price, notInInsuranceApplyId: this.form.id }) |
| | | } else { |
| | | this.$refs.selectEmployees.open('éååå·¥', { arr: this.form.delDetailList, price: this.price, insuranceApplyId: this.form.id }) |
| | | } |
| | | }, |
| | | addUser() { |
| | | if (!this.form.solutionId) { |
| | | this.$message.warning('请å
éæ©ä¿é©æ¹æ¡') |
| | | return |
| | | } |
| | | if (this.activeName === '0') { |
| | | this.$refs.addEmployee.open('æ·»å åå·¥', { arr: this.form.addDetailList, price: this.price }) |
| | | } else { |
| | | this.$refs.addEmployee.open('æ·»å åå·¥', { arr: this.form.delDetailList, price: this.price }) |
| | | } |
| | | }, |
| | | uploadUser() { |
| | | if (!this.form.solutionId) { |
| | | this.$message.warning('请å
éæ©ä¿é©æ¹æ¡') |
| | | return |
| | | } |
| | | if (this.activeName === '0') { |
| | | this.$refs.importEmployees.open('ä¸ä¼ åå', { arr: this.form.addDetailList, price: this.price }) |
| | | } else { |
| | | this.$refs.importEmployees.open('ä¸ä¼ åå', { arr: this.form.delDetailList, price: this.price }) |
| | | } |
| | | }, |
| | | // åæ¢æ¹æ¡ |
| | | changeSolution1(e) { |
| | | this.company.forEach(item => { |
| | | if (item.id === e) { |
| | | this.item = item |
| | | } |
| | | }) |
| | | // this.tableData.forEach(item => { |
| | | // item.fee = this.price |
| | | // }) |
| | | }, |
| | | dele(index) { |
| | | if (this.activeName === '0') { |
| | | this.form.addDetailList.splice(index, 1) |
| | | } else { |
| | | this.form.delDetailList.splice(index, 1) |
| | | } |
| | | }, |
| | | getUser(obj) { |
| | | this.seleData.forEach(item => { |
| | | if (this.activeName === '0') { |
| | | this.form.addDetailList.forEach(row => { |
| | | if (item === row.name) { |
| | | row.workTypeName = obj.workTypeName |
| | | row.worktypeId = obj.worktypeId |
| | | row.duName = obj.duName |
| | | row.duId = obj.duId |
| | | } |
| | | }) |
| | | } else { |
| | | this.form.delDetailList.forEach(row => { |
| | | if (item === row.name) { |
| | | row.workTypeName = obj.workTypeName |
| | | row.worktypeId = obj.worktypeId |
| | | row.duName = obj.duName |
| | | row.duId = obj.duId |
| | | } |
| | | }) |
| | | } |
| | | }) |
| | | this.seleData = [] |
| | | this.$refs.multipleTable.clearSelection(); |
| | | }, |
| | | // éæ©åå·¥ |
| | | sele() { |
| | | if (!this.form.solutionId) { |
| | | this.$message.warning('è¯·éæ©ä¿é©æ¹æ¡') |
| | | return |
| | | } |
| | | if (this.seleData.length === 0) { |
| | | this.$message.warning('è¯·éæ©åå·¥') |
| | | return |
| | | } |
| | | this.$refs.confirmJobType.open('确认工ç§', { solutionId: this.form.solutionId }) |
| | | }, |
| | | // æ¥è¯¢å
¨é¨æ¹æ¡ |
| | | getCompany() { |
| | | all({}) |
| | | .then(res => { |
| | | this.company = res |
| | | }) |
| | | }, |
| | | getAgeByIdCard(idCard){ |
| | | if (!idCard) return '' |
| | | const sexAndAge = {} |
| | | //è·åç¨æ·èº«ä»½è¯å·ç |
| | | const userCard = idCard |
| | | //å¦æç¨æ·èº«ä»½è¯å·ç 为undefinedåè¿å空 |
| | | if (!userCard) { |
| | | return sexAndAge |
| | | } |
| | | // è·ååºçæ¥æ |
| | | const yearBirth = userCard.substring(6, 10) |
| | | const monthBirth = userCard.substring(10, 12) |
| | | const dayBirth = userCard.substring(12, 14) |
| | | // è·åå½åå¹´ææ¥å¹¶è®¡ç®å¹´é¾ |
| | | const myDate = new Date() |
| | | const monthNow = myDate.getMonth() + 1 |
| | | const dayNow = myDate.getDate() |
| | | let age = myDate.getFullYear() - yearBirth |
| | | if (monthNow < monthBirth || (monthNow == monthBirth && dayNow < dayBirth)) { |
| | | age-- |
| | | } |
| | | // å¾å°å¹´é¾ |
| | | sexAndAge.age = age |
| | | return sexAndAge.age |
| | | }, |
| | | handleSelectionChange (e) { |
| | | this.seleData = e.map(item => item.name) |
| | | }, |
| | | getValue(list) { |
| | | console.log(list) |
| | | if (this.activeName === '0') { |
| | | this.form.addDetailList.push(...list) |
| | | } else { |
| | | this.form.delDetailList.push(...list) |
| | | } |
| | | } |
| | | } |
| | | } |
| | | </script> |
| | | |
| | | <style lang="scss" scoped> |
| | | .list { |
| | | width: 100%; |
| | | } |
| | | .btns { |
| | | width: 100%; |
| | | margin-bottom: 15px; |
| | | display: flex; |
| | | align-items: center; |
| | | justify-content: space-between; |
| | | .btns_item { |
| | | display: flex; |
| | | align-items: center; |
| | | } |
| | | } |
| | | .submit { |
| | | width: 100%; |
| | | display: flex; |
| | | align-items: center; |
| | | justify-content: center; |
| | | margin-bottom: 15px; |
| | | } |
| | | .desc_item_from { |
| | | width: 100%; |
| | | margin-bottom: 10px; |
| | | .desc_item_from_page { |
| | | width: 100%; |
| | | display: flex; |
| | | align-items: center; |
| | | justify-content: end; |
| | | margin-top: 10px; |
| | | } |
| | | } |
| | | .desc_item_cate { |
| | | width: 100%; |
| | | margin-bottom: 10px; |
| | | } |
| | | .info { |
| | | width: 100%; |
| | | font-size: 14px; |
| | | color: black; |
| | | } |
| | | </style> |
| | |
| | | import {all as solutionAll, all} from '@/api/business/solutions' |
| | | import {pageAll as companyAll} from "@/api/business/company"; |
| | | export default { |
| | | name: 'add_subtract', |
| | | name: 'switchCourt', |
| | | extends: BaseTable, |
| | | components: { TableLayout, Pagination, OperaApplyChangeUnitDetailWindow }, |
| | | data () { |
| | |
| | | <el-table-column prop="status" label="ä¿åç¶æ" min-width="100px"> |
| | | <template slot-scope="{row}"> |
| | | <span v-if="row.status === 0">å¾
ç¾ç½²</span> |
| | | <span v-if="row.status === 1">å·²ç¾ç« </span> |
| | | <span v-if="row.status === 2">å·²ä¸ä¼ æ¹å</span> |
| | | <span v-if="row.status === 3">éåç³è¯·</span> |
| | | <span v-if="row.status === 1">å¾
å®¡æ ¸</span> |
| | | <span v-if="row.status === 2">å·²çæ</span> |
| | | <span v-if="row.status === 3 || row.status === 4">ç³è¯·éå</span> |
| | | <span v-if="row.status === 5 || row.status === 8">å·²éå</span> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column prop="applyCode" label="å
³èä¿åå·" min-width="100px"></el-table-column> |
| | |
| | | <TableLayout :permissions="['business:applychange:query']"> |
| | | <!-- æç´¢è¡¨å --> |
| | | <el-form ref="searchForm" slot="search-form" :model="searchForm" label-width="100px" inline> |
| | | <el-form-item label="ä¿åç¶æ" prop="status"> |
| | | <el-form-item label="ç¶æ" prop="status"> |
| | | <el-select v-model="searchForm.status" placeholder="è¯·éæ©" @change="search"> |
| | | <el-option label="å
¨é¨" value=""></el-option> |
| | | <el-option label="å¾
ç¾ç½²" value="0"></el-option> |
| | | <el-option label="å·²ç¾ç« " value="1"></el-option> |
| | | <el-option label="å·²ä¸ä¼ æ¹å" value="2"></el-option> |
| | | <el-option label="éåç³è¯·" value="3"></el-option> |
| | | <el-option label="å¾
å®¡æ ¸" value="1"></el-option> |
| | | <el-option label="å·²çæ" value="2"></el-option> |
| | | <el-option label="ç³è¯·éå" value="3"></el-option> |
| | | <!-- 3 4 齿¯éåç³è¯·ä¸--> |
| | | <el-option label="å·²éå" value="5"></el-option> |
| | | <el-option label="å·²å
³é" value="6"></el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item label="æä¿ä¼ä¸" prop="status"> |
| | | <el-select v-model="searchForm.status" placeholder="è¯·éæ©"> |
| | | <el-form-item label="ä¿é©æ¹æ¡" prop="baseSolutionsId"> |
| | | <el-select v-model="searchForm.baseSolutionsId" placeholder="è¯·éæ©" @change="search"> |
| | | <el-option |
| | | v-for="item in options" |
| | | :key="item.value" |
| | | :label="item.label" |
| | | :value="item.value"> |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item label="ä¿é©æ¹æ¡" prop="status"> |
| | | <el-select v-model="searchForm.status" placeholder="è¯·éæ©"> |
| | | <el-option |
| | | v-for="item in options" |
| | | :key="item.value" |
| | | :label="item.label" |
| | | :value="item.value"> |
| | | v-for="item in solutionList" |
| | | :key="item.baseId" |
| | | :label="item.name" |
| | | :value="item.baseId"> |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item label="æäº¤æ¥æ" prop="status"> |
| | | <el-date-picker |
| | | v-model="searchForm.status" |
| | | @change="changeTime" |
| | | v-model="searchForm.time" |
| | | type="daterange" |
| | | value-format="yyyy-MM-dd" |
| | | range-separator="è³" |
| | | start-placeholder="å¼å§æ¥æ" |
| | | end-placeholder="ç»ææ¥æ"> |
| | |
| | | <span>{{scope.$index + 1}}</span> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column prop="status" label="ä¿åç¶æ" min-width="100px"> |
| | | <el-table-column prop="status" label="ç¶æ" min-width="100px"> |
| | | <template slot-scope="{row}"> |
| | | <span v-if="row.status === 0">å¾
ç¾ç½²</span> |
| | | <span v-if="row.status === 1">å·²ç¾ç« </span> |
| | | <span v-if="row.status === 2">å·²ä¸ä¼ æ¹å</span> |
| | | <span v-if="row.status === 3">éåç³è¯·</span> |
| | | <span v-if="row.status === 1">å¾
å®¡æ ¸</span> |
| | | <span v-if="row.status === 2">å·²çæ</span> |
| | | <span v-if="row.status === 3 || row.status === 4">ç³è¯·éå</span> |
| | | <span v-if="row.status === 5 || row.status === 8">å·²éå</span> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column prop="code" label="æä¿ä¼ä¸" min-width="100px"></el-table-column> |
| | | <el-table-column prop="validCode" label="æ¹åå·" min-width="100px"></el-table-column> |
| | | <el-table-column prop="code" label="å
³èä¿åå·" min-width="100px"></el-table-column> |
| | | <el-table-column prop="code" label="ä¿é©æ¹æ¡" min-width="100px"></el-table-column> |
| | | <el-table-column prop="code" label="å ä¿äººæ°ï¼äººï¼" min-width="100px"></el-table-column> |
| | | <el-table-column prop="code" label="åä¿äººæ°ï¼äººï¼" min-width="100px"></el-table-column> |
| | | <el-table-column prop="code" label="è´¹ç¨åæ´" min-width="100px"></el-table-column> |
| | | <el-table-column prop="solutionsName" label="ä¿é©æ¹æ¡" min-width="100px"></el-table-column> |
| | | <el-table-column prop="changeNum" label="æ¢å人æ°ï¼äººï¼" min-width="100px"></el-table-column> |
| | | <el-table-column prop="createDate" label="æäº¤æ¶é´" min-width="100px"></el-table-column> |
| | | <el-table-column prop="startTime" label="æ¹åçæèµ·æ" min-width="100px"></el-table-column> |
| | | <el-table-column |
| | | label="æä½" |
| | | min-width="120" |
| | |
| | | import TableLayout from '@/layouts/TableLayout' |
| | | import Pagination from '@/components/common/Pagination' |
| | | import OperaApplyChangeUnitDetailWindow from '@/components/business/OperaApplyChangeUnitDetailWindow' |
| | | import {all as solutionAll} from "@/api/business/solutions"; |
| | | import {all as solutionAll, all} from '@/api/business/solutions' |
| | | import {pageAll as companyAll} from "@/api/business/company"; |
| | | export default { |
| | | name: 'switchCourt', |
| | |
| | | // æç´¢ |
| | | searchForm: { |
| | | status: '', |
| | | type: '' |
| | | type: '1', |
| | | solutionsId: '', |
| | | createDateE: '', |
| | | createDateS: '', |
| | | time: [] |
| | | }, |
| | | options: [] |
| | | solutionList:[], |
| | | companyList:[] |
| | | } |
| | | }, |
| | | created () { |
| | |
| | | 'field.main': 'id' |
| | | }) |
| | | this.search() |
| | | this.loadSelectList() |
| | | }, |
| | | methods:{ |
| | | // handlePageChange() { |
| | | // this.search() |
| | | // }, |
| | | loadSelectList() { |
| | | solutionAll({dataType:2}).then(res => { |
| | | this.solutionList = res |
| | | }).catch(err => { |
| | | }) |
| | | companyAll({}).then(res => { |
| | | this.companyList = res |
| | | }).catch(err => { |
| | | }) |
| | | methods: { |
| | | loadSelectList() { |
| | | solutionAll({dataType:2}).then(res => { |
| | | this.solutionList = res |
| | | }).catch(err => { |
| | | }) |
| | | companyAll({}).then(res => { |
| | | this.companyList = res |
| | | }).catch(err => { |
| | | }) |
| | | }, |
| | | changeTime(e) { |
| | | if (e.length > 0) { |
| | | this.searchForm.createDateS = e[0] |
| | | this.searchForm.createDateE = e[1] |
| | | } else { |
| | | this.searchForm.createDateS = '' |
| | | this.searchForm.createDateE = '' |
| | | } |
| | | this.search() |
| | | }, |
| | | reset() { |
| | | this.searchForm.createDateS = '' |
| | | this.searchForm.createDateE = '' |
| | | this.searchForm.time = [] |
| | | this.$refs.searchForm.resetFields(); |
| | | this.search() |
| | | } |
| | | } |
| | | |
| | | } |
| | | } |
| | | </script> |