Commit 3e92dc01 authored by linxin's avatar linxin

Merge branch 'liuin' into uat

parents 784d0e80 e2150d44
<template> <template>
<h-view v-if="showFlag" id="add-person"> <h-view id="add-person">
<h-header :proportion="[1,4,1]" class="bar-custom"> <h-header :proportion="[5,1,1]" class="bar-custom">
<span slot="center" style="color:#fff">添加担保人</span> <div slot="left" class="h-header-btn">
<span slot="right" style="color:#fff" @click="showFlag=false">取消</span> <img src="@/assets/userBind/arrow.png" @click="$routeGo()">
<span>合同创建</span>
</div>
</h-header> </h-header>
<div class="search has-header"> <div class="search has-header">
<input v-model="keyWord" placeholder="请输入担保人名称/证件号码" > <input v-model="keyWord" placeholder="请输入担保人名称/证件号码" >
...@@ -26,12 +28,12 @@ ...@@ -26,12 +28,12 @@
</template> </template>
<script> <script>
export default { export default {
props: { // props: {
bp_agent_id: { // bp_agent_id: {
type: String, // type: String,
default: '', // default: '',
}, // },
}, // },
data () { data () {
return { return {
undertakeList: [], // 担保人列表 undertakeList: [], // 担保人列表
...@@ -39,10 +41,17 @@ export default { ...@@ -39,10 +41,17 @@ export default {
pagenum: 1, pagenum: 1,
keyWord: '', keyWord: '',
showFlag: false, showFlag: false,
bp_agent_id: this.$route.params.bp_agent_id,
} }
}, },
watch: { watch: {
},
beforeRouteEnter (to, from, next) {
next(vm => {
vm.init()
vm.getUndertake()
})
}, },
methods: { methods: {
show () { show () {
...@@ -50,7 +59,7 @@ export default { ...@@ -50,7 +59,7 @@ export default {
}, },
init () { init () {
this.undertakeList = [] this.undertakeList = []
this.selectUdertake = [] this.selectUdertake = {}
this.pagenum = 1 this.pagenum = 1
this.keyWord = '' this.keyWord = ''
}, },
...@@ -105,10 +114,17 @@ export default { ...@@ -105,10 +114,17 @@ export default {
}) })
}, },
addUndertake (e) { addUndertake (e) {
let vm = this
this.selectUdertake = e this.selectUdertake = e
this.$emit('addUnder', this.selectUdertake) // this.$emit('addUnder', this.selectUdertake)
setTimeout(() => { setTimeout(() => {
this.showFlag = false vm.$router.replace({
name: 'CreateBaseInfo',
params: {
selectUdertake: vm.selectUdertake,
},
})
vm.$router.go(-1)
}, 100) }, 100)
}, },
getUndertake () { // 担保人查询 getUndertake () { // 担保人查询
......
...@@ -382,15 +382,15 @@ ...@@ -382,15 +382,15 @@
<tab-button class="before" @click.native="$routeGo()">上一步</tab-button> <tab-button class="before" @click.native="$routeGo()">上一步</tab-button>
<tab-button class="next" @click.native="save">下一步</tab-button> <tab-button class="next" @click.native="save">下一步</tab-button>
</bottom-tab> </bottom-tab>
<AddUnderTake ref="addperson" :bp_agent_id="bp_agent_id" @addUnder="addUnder" /> <!-- <AddUnderTake ref="addperson" :bp_agent_id="bp_agent_id" @addUnder="addUnder" /> -->
</h-view> </h-view>
</template> </template>
<script> <script>
import AddUnderTake from '../../pages/contractCreate/add-undertake' // import AddUnderTake from '../../pages/contractCreate/add-undertake'
export default { export default {
components: { // components: {
AddUnderTake, // AddUnderTake,
}, // },
data () { data () {
return { return {
salesEnter: '', // 页面进入标识,该字段作用:第一次创建时即从销售页面进入进本信息、租赁信息、附件信息。用于判断后面页面录入数据后未保存则点击上一步,再次进入该页面数据丢失问题 salesEnter: '', // 页面进入标识,该字段作用:第一次创建时即从销售页面进入进本信息、租赁信息、附件信息。用于判断后面页面录入数据后未保存则点击上一步,再次进入该页面数据丢失问题
...@@ -585,6 +585,10 @@ export default { ...@@ -585,6 +585,10 @@ export default {
vm.getSaveInfo() vm.getSaveInfo()
vm.getBaseInfo() vm.getBaseInfo()
}, 0) }, 0)
} else if (from.name === 'Addundertake') {
if (vm.$route.params.selectUdertake) {
vm.addUnder(vm.$route.params.selectUdertake)
}
} }
}) })
}, },
...@@ -664,17 +668,25 @@ export default { ...@@ -664,17 +668,25 @@ export default {
} }
}, },
addPerson () { addPerson () {
this.$refs.addperson.init() // this.$refs.addperson.init()
this.$refs.addperson.getUndertake() // this.$refs.addperson.getUndertake()
this.$refs.addperson.show() // this.$refs.addperson.show()
this.$router.push({
name: 'Addundertake',
params: {
bp_agent_id: this.bp_agent_id,
},
})
}, },
makeData () { makeData () {
let obj = {} let obj = {}
if (this.selectUdertake.length > 0) {
this.selectUdertake.forEach((i, index, arr) => { this.selectUdertake.forEach((i, index, arr) => {
obj[`bp_id_guta_${index + 1}`] = i.bp_guta_id obj[`bp_id_guta_${index + 1}`] = i.bp_guta_id
}) })
return obj return obj
}
}, },
getAgentInfo () { getAgentInfo () {
let vm = this let vm = this
......
...@@ -399,12 +399,12 @@ ...@@ -399,12 +399,12 @@
<div v-if="!laImg" @click="LaUpload()"> <div v-if="!laImg" @click="LaUpload()">
<img src="@/assets/userBind/camera.png"> <img src="@/assets/userBind/camera.png">
</div> </div>
<div v-if="laImg && !isApproved" class="licenseBox" @click="LaUpload('')"> <div v-if="laImg" class="licenseBox" @click="LaUpload()">
<img :src="laImg" style="width: 100%;height: 100%;margin: 0"> <img :src="laImg" style="width: 100%;height: 100%;margin: 0">
</div> </div>
<div v-if="isApproved" class="licenseBox"><!--v-if="licenseImg && isApproved"--> <!-- <div v-if="isApproved" class="licenseBox">
<img v-if="laImg" :src="laImg" style="width: 100%;height: 100%;margin: 0" @click="showBigPicture(laImg)"> <img v-if="laImg" :src="laImg" style="width: 100%;height: 100%;margin: 0" @click="showBigPicture(laImg)">
</div> </div> -->
</div> </div>
</div> </div>
<!-- <!--
......
...@@ -126,6 +126,7 @@ import CreateBaseInfo from '@/pages/contractCreate/create-base-info' ...@@ -126,6 +126,7 @@ import CreateBaseInfo from '@/pages/contractCreate/create-base-info'
import CreateRentInfo from '@/pages/contractCreate/creat-rent-info' import CreateRentInfo from '@/pages/contractCreate/creat-rent-info'
import CreateEnclosureInfo from '@/pages/contractCreate/create-enclosure-info' import CreateEnclosureInfo from '@/pages/contractCreate/create-enclosure-info'
import previewPdf from '@/pages/contractSigning/previewPdf' import previewPdf from '@/pages/contractSigning/previewPdf'
import Addundertake from '@/pages/contractCreate/add-undertake'
import About from '@/pages/myInfo/About' import About from '@/pages/myInfo/About'
import UserAgree from '@/pages/myInfo/UserAgreement' import UserAgree from '@/pages/myInfo/UserAgreement'
...@@ -302,6 +303,8 @@ export default new Router({ ...@@ -302,6 +303,8 @@ export default new Router({
{path: '/create-rent-info', component: CreateRentInfo, name: 'CreateRentInfo', meta: {keepAlive: true}}, {path: '/create-rent-info', component: CreateRentInfo, name: 'CreateRentInfo', meta: {keepAlive: true}},
{path: '/create-enclosure-info', component: CreateEnclosureInfo, name: 'CreateEnclosureInfo', meta: {keepAlive: true}}, {path: '/create-enclosure-info', component: CreateEnclosureInfo, name: 'CreateEnclosureInfo', meta: {keepAlive: true}},
{path: '/previewPdf', component: previewPdf, name: 'previewPdf', meta: {keepAlive: false}}, {path: '/previewPdf', component: previewPdf, name: 'previewPdf', meta: {keepAlive: false}},
{path: '/add-undertake', component: Addundertake, name: 'Addundertake', meta: {keepAlive: false}},
// 我的发票 // 我的发票
{path: '/invoice', component: MyInvoice, name: 'MyInvoice', meta: {keepAlive: false}}, {path: '/invoice', component: MyInvoice, name: 'MyInvoice', meta: {keepAlive: false}},
{ {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment