Commit 0ebd9ebf authored by linxin's avatar linxin

Merge branch 'liuxin' into develop

parents 87825661 8c5bd18b
...@@ -14,19 +14,21 @@ ...@@ -14,19 +14,21 @@
<list-item :item-height="44"> <list-item :item-height="44">
<item> <item>
<div slot="name">车架号</div> <div slot="name">车架号</div>
<input slot="content" readonly placeholder="自动识别车架号" > <input slot="content" v-model="rentInfo.frame_number" readonly placeholder="自动识别车架号" >
</item> </item>
<item> <item>
<div slot="name">发动机号</div> <div slot="name">发动机号</div>
<input slot="content" readonly placeholder="自动识别发动机号" > <input slot="content" v-model="rentInfo.engine" readonly placeholder="自动识别发动机号" >
</item> </item>
<item> <item>
<div slot="name">厂商型号</div> <div slot="name">厂商型号</div>
<input slot="content" readonly class="write" placeholder="请输入厂商型号" > <input
slot="content" v-model="rentInfo.manufacturer" readonly class="write"
placeholder="请输入厂商型号" >
</item> </item>
<item> <item>
<div slot="name">车牌号</div> <div slot="name">车牌号</div>
<input slot="content" readonly placeholder="请输入车牌号" > <input slot="content" v-model="rentInfo.license_plate_number" readonly placeholder="请输入车牌号" >
</item> </item>
</list-item> </list-item>
</div> </div>
...@@ -73,7 +75,7 @@ ...@@ -73,7 +75,7 @@
</item> </item>
</list-item> </list-item>
<div class="userInfo">设备清单</div> <div class="userInfo">设备清单</div>
<div v-for="(item,index) in numInt" :key="index" class="equipment" @click="downNum=true"> <div v-for="(item,index) in numInt" :key="index" class="equipment" @click="downNum=true;getRent()">
<div class="left"> <div class="left">
<span> <span>
<img src="@/assets/contractStart/list.png" > <img src="@/assets/contractStart/list.png" >
...@@ -93,7 +95,7 @@ ...@@ -93,7 +95,7 @@
</div> </div>
</h-content> </h-content>
<bottom-tab> <bottom-tab>
<tab-button class="approve" @click.native="goAdd">发车申请</tab-button> <tab-button class="approve" @click.native="confirm">确定</tab-button>
</bottom-tab> </bottom-tab>
</h-view> </h-view>
...@@ -116,6 +118,12 @@ export default { ...@@ -116,6 +118,12 @@ export default {
'bp_agent_name': '上海汉得信息技术股份有限公司 ', 'bp_agent_name': '上海汉得信息技术股份有限公司 ',
'product_plan_id_n': 'PDJ', 'product_plan_id_n': 'PDJ',
}, },
rentInfo: {
'frame_number': '',
'engine': '',
'manufacturer': '',
'license_plate_number': '',
},
products: [], products: [],
equip: [{ equip: [{
'product_id': '3', 'product_id': '3',
...@@ -140,6 +148,24 @@ export default { ...@@ -140,6 +148,24 @@ export default {
}) })
}, },
methods: { methods: {
confirm () {
let vm = this
let url = process.env.basePath + 'do_car_confirm'
let param = {
'master': {
'contract_id': '123',
'confirm_status': 'APPROVED',
}}
hlsPopup.showLoading('请稍候')
vm.$post(url, param).then(function (res) {
vm.hlsPopup.hideLoading()
if (res.result === 'S') {
vm.equip = res.lists
} else {
hlsPopup.showLongCenter(res.message)
}
})
},
getEquipment () { getEquipment () {
let vm = this let vm = this
let url = process.env.basePath + 'car_equip_list_query' let url = process.env.basePath + 'car_equip_list_query'
...@@ -156,6 +182,23 @@ export default { ...@@ -156,6 +182,23 @@ export default {
} }
}) })
}, },
getRent () {
let vm = this
let url = process.env.basePath + 'leases_info_query'
let param = {
contract_id: vm.equip.contract_id,
}
hlsPopup.showLoading('请稍候')
vm.$post(url, param).then(function (res) {
vm.hlsPopup.hideLoading()
if (res.result === 'S') {
Object.assign(vm.rentInfo, res.info)
} else {
hlsPopup.showLongCenter(res.message)
}
})
},
getDetail () { getDetail () {
let vm = this let vm = this
let url = process.env.basePath + 'con_contract_detial' let url = process.env.basePath + 'con_contract_detial'
......
...@@ -16,7 +16,7 @@ ...@@ -16,7 +16,7 @@
:updateData="[contructs]" :updateData="[contructs]"
:pullUp="true" :pullUp="true"
> >
<div v-for="(item,index) in lists" :key="index" class="item" @click="changePage(item.project_id)"> <div v-for="(item,index) in showList" :key="index" class="item" @click="changePage(item.project_id)">
<div class="left"> <div class="left">
<span> <span>
<img src="@/assets/contractStart/icon.png" > <img src="@/assets/contractStart/icon.png" >
...@@ -50,7 +50,7 @@ ...@@ -50,7 +50,7 @@
</h-view> </h-view>
</template> </template>
<script> <script>
import Tab from '@/pages/contractStart/tab' import Tab from '@/pages/carConfirm/tab'
export default { export default {
components: { components: {
Tab, Tab,
...@@ -58,26 +58,64 @@ export default { ...@@ -58,26 +58,64 @@ export default {
data () { data () {
return { return {
contructs: [], contructs: [],
tabNum: 0,
lists: [{ lists: [{
'project_id': '48812', 'project_id': '48812',
'project_number': '', 'project_number': '',
'bp_name': '张三', 'bp_name': '张三',
'total_price': '51', 'total_price': '51',
'division_n': 'PDJ', 'division_n': 'PDJ',
'leases_status': '', 'confirm_status': 'SUBMIT',
}, },
{ {
'project_id': '48800', 'project_id': '48800',
'project_number': '', 'project_number': '',
'bp_name': '张三', 'bp_name': '李四',
'total_price': '51',
'division_n': 'PDJ',
'confirm_status': 'APPROVED',
},
{
'project_id': '48800',
'project_number': '',
'bp_name': '王五',
'total_price': '51', 'total_price': '51',
'division_n': 'PDJ', 'division_n': 'PDJ',
'leases_status': '', 'confirm_status': 'APPROVED',
}], }],
showList: [],
undo: [],
done: [],
} }
}, },
watch: {
'tabNum': {
handler (newVal, oldVal) {
if (newVal === 0) {
this.showList = this.undo
} else if (newVal === 1) {
this.showList = this.done
}
},
immediate: true,
},
},
created () {
this.selectShowList()
},
methods: { methods: {
selectShowList () {
let vm = this
this.lists.forEach(item => {
if (item.confirm_status === 'SUBMIT') {
vm.undo.push(item)
} else if (item.confirm_status === 'APPROVED') {
vm.done.push(item)
}
})
},
getTabNum (i) { getTabNum (i) {
this.tabNum = i
}, },
changePage (e) { changePage (e) {
this.$router.push({ this.$router.push({
......
<!--
* @Description: In User Settings Edit
* @Author: your name
* @Date: 2019-09-25 11:10:34
* @LastEditTime: 2019-09-25 21:05:24
* @LastEditors: Please set LastEditors
-->
<template>
<div class="tab-style">
<div :class="{'tab-content-bg':tabNum == 0}" class="tab-content" @click="tabNum = 0;sendTabNum()"><img :src="tabNum == 0?signed:sign"><span
:class="{'colored':tabNum == 0}">待确认</span></div>
<div :class="{'tab-content-bg':tabNum == 1}" class="tab-content" @click="tabNum = 1;sendTabNum()"><img :src="tabNum == 1?finished:finish"><span
:class="{'colored':tabNum == 1}">已确认</span></div>
</div>
</template>
<script>
import signed from '@/assets/contractStart/noY.png'
import finished from '@/assets/contractStart/confirmY.png'
import sign from '@/assets/contractStart/noN.png'
import finish from '@/assets/contractStart/confirmN.png'
export default {
data () {
return {
tabNum: 0,
signed: signed,
finished: finished,
sign: sign,
finish: finish,
}
},
methods: {
sendTabNum () {
this.$emit('getTabNum', this.tabNum)
},
},
}
</script>
<style lang="less" scoped>
.tab-style {
position: relative;
z-index: 50;
background-color: #fff;
display: flex;
justify-content: center;
padding-top: 12px;
padding-bottom: 8px;
align-items: center;
box-shadow: 0 2px 3px 0 rgba(220, 220, 221, 0.50);
.tab-content {
display: block;
width: 45.9%;
height: 32px;
background: rgba(220, 220, 221, 0.26);
border-radius: 16px;
display: flex;
justify-content: center;
align-items: center;
span {
margin-left: 2%;
font-size: 14px;
color: #383F45;
font-weight: 600;
font-family: PingFangSC-Semibold;
}
.colored {
color: #1D3FFF
}
}
.tab-content-bg{
background: rgba(0,70,156,0.10);
}
img {
width:16px;
height: 16px;
// margin-right:5.7px;
}
.tab-content:nth-of-type(2) {
margin-left: 7px;
}
}
</style>
...@@ -19,7 +19,7 @@ ...@@ -19,7 +19,7 @@
<div><span>合同金额</span><p>{{ item.total_price|currency }}</p></div> <div><span>合同金额</span><p>{{ item.total_price|currency }}</p></div>
<div><span>已还金额</span><p class="bold">{{ item.recivied_amount|currency }}</p></div> <div><span>已还金额</span><p class="bold">{{ item.recivied_amount|currency }}</p></div>
<span class="red">逾期{{ item.overdue_days }}</span> <span class="red">逾期{{ item.overdue_days }}</span>
<section @click="toRepayDetails"> <section @click="toRepayDetails(item.project_id)">
<img src="@/assets/contractRepayment/view.png" alt=""> <img src="@/assets/contractRepayment/view.png" alt="">
<span>查看合同明细</span> <span>查看合同明细</span>
</section> </section>
...@@ -75,7 +75,7 @@ export default { ...@@ -75,7 +75,7 @@ export default {
beforeRouteEnter (to, from, next) { beforeRouteEnter (to, from, next) {
next(vm => { next(vm => {
if (from.name === 'HomePage') { if (from.name === 'HomePage') {
// vm.getList() vm.getList()
} }
}) })
}, },
...@@ -96,9 +96,12 @@ export default { ...@@ -96,9 +96,12 @@ export default {
} }
}) })
}, },
toRepayDetails () { toRepayDetails (e) {
this.$router.push({ this.$router.push({
name: 'RepayDetails', name: 'RepayDetails',
params: {
project_id: e,
},
}) })
}, },
}, },
......
...@@ -81,8 +81,22 @@ export default { ...@@ -81,8 +81,22 @@ export default {
}, },
data () { data () {
return { return {
detailInfo: {}, detailInfo: {
lists: [], project_number: '',
agent_bp_name: '',
bp_name: '',
division_n: '',
total_price: '',
product_plan_id_n: '',
product_num: '',
},
lists: [{
'lease_item_car_num': 'GH',
'product_code': 'GTC389',
'lease_item_factory_num': 'EF',
'lease_item_engine_num': 'CD',
'contract_id': '123',
}],
} }
}, },
computed: {}, computed: {},
...@@ -100,7 +114,7 @@ export default { ...@@ -100,7 +114,7 @@ export default {
let vm = this let vm = this
let url = process.env.basePath + 'con_equip_list' let url = process.env.basePath + 'con_equip_list'
let param = { let param = {
project_id: 46002, project_id: this.$route.params.project_id,
} }
hlsPopup.showLoading('请稍候') hlsPopup.showLoading('请稍候')
vm.$post(url, param).then(function (res) { vm.$post(url, param).then(function (res) {
...@@ -116,7 +130,7 @@ export default { ...@@ -116,7 +130,7 @@ export default {
let vm = this let vm = this
let url = process.env.basePath + 'con_repayment_detial' let url = process.env.basePath + 'con_repayment_detial'
let param = { let param = {
project_id: 48818, project_id: this.$route.params.project_id,
} }
hlsPopup.showLoading('请稍候') hlsPopup.showLoading('请稍候')
vm.$post(url, param).then(function (res) { vm.$post(url, param).then(function (res) {
......
...@@ -12,8 +12,8 @@ ...@@ -12,8 +12,8 @@
<div class="plan-list"> <div class="plan-list">
<div v-for="(item,index) in lists" :key="index" class="plan-item"> <div v-for="(item,index) in lists" :key="index" class="plan-item">
<div class="left"> <div class="left">
<p>2019</p> <p>{{ selectYear(item.repayment_date) }}</p>
<span>01-01</span> <span>{{ selectMonth(item.repayment_date) }}</span>
</div> </div>
<div :class="{right:true,white:show!=='done'}"> <div :class="{right:true,white:show!=='done'}">
<div :class="{number:true,blue:show==='undone',orange:show==='doing'}">{{ index + 1 }}</div> <div :class="{number:true,blue:show==='undone',orange:show==='doing'}">{{ index + 1 }}</div>
...@@ -56,7 +56,7 @@ export default { ...@@ -56,7 +56,7 @@ export default {
'cf_item_name': '手续费', 'cf_item_name': '手续费',
'received_amount': '400', 'received_amount': '400',
'pay_method': '代扣', 'pay_method': '代扣',
'repayment_date': '2019/10/12', 'repayment_date': '2020/10/12',
}, },
{ {
'due_amount': '400', 'due_amount': '400',
...@@ -64,7 +64,7 @@ export default { ...@@ -64,7 +64,7 @@ export default {
'cf_item_name': 'gps费用', 'cf_item_name': 'gps费用',
'received_amount': '200', 'received_amount': '200',
'pay_method': '自主还款', 'pay_method': '自主还款',
'repayment_date': '2019/10/19', 'repayment_date': '2021/10/19',
}, },
], ],
} }
...@@ -73,10 +73,17 @@ export default { ...@@ -73,10 +73,17 @@ export default {
watch: {}, watch: {},
beforeRouteEnter (to, from, next) { beforeRouteEnter (to, from, next) {
next(vm => { next(vm => {
// vm.getRefund() vm.getRefund()
}) })
}, },
methods: { methods: {
selectMonth (e) {
let arr = e.split('/')
return `${arr[1]}-${arr[2]}`
},
selectYear (e) {
return e.substring(0, 4)
},
getRefund () { getRefund () {
let vm = this let vm = this
let url = process.env.basePath + 'con_equip_repayment_plan' let url = process.env.basePath + 'con_equip_repayment_plan'
......
This diff is collapsed.
...@@ -16,7 +16,7 @@ ...@@ -16,7 +16,7 @@
:updateData="[contructs]" :updateData="[contructs]"
:pullUp="true" :pullUp="true"
> >
<div v-for="(item,index) in lists" :key="index" class="item" @click="changePage"> <div v-for="(item,index) in showList" :key="index" class="item" @click="changePage(item.project_id)">
<div class="left"> <div class="left">
<span> <span>
<img src="@/assets/contractStart/icon.png" > <img src="@/assets/contractStart/icon.png" >
...@@ -62,14 +62,15 @@ export default { ...@@ -62,14 +62,15 @@ export default {
}, },
data () { data () {
return { return {
tabNum: 0,
contructs: [], contructs: [],
lists: [{ lists: [{
'project_id': '48812', 'project_id': '48812',
'project_number': '', 'project_number': '',
'bp_name': '张三', 'bp_name': '李四',
'total_price': '51', 'total_price': '51',
'division_n': 'PDJ', 'division_n': 'PDJ',
'leases_status': '', 'leases_status': 'Y',
}, },
{ {
'project_id': '48800', 'project_id': '48800',
...@@ -77,31 +78,67 @@ export default { ...@@ -77,31 +78,67 @@ export default {
'bp_name': '张三', 'bp_name': '张三',
'total_price': '51', 'total_price': '51',
'division_n': 'PDJ', 'division_n': 'PDJ',
'leases_status': '', 'leases_status': 'N',
}], }],
showList: [],
undo: [],
done: [],
} }
}, },
beforeRouteEnter (to, from, next) { beforeRouteEnter (to, from, next) {
next(vm => { next(vm => {
vm.getList() if (from.name === 'MyInfo') {
vm.getList()
}
}) })
}, },
watch: {
'tabNum': {
handler () {
if (this.tabNum === 0) {
this.showList = this.undo
} else if (this.tabNum === 1) {
this.showList = this.done
}
},
immediate: true,
},
},
created () {
this.selectShowList()
},
methods: { methods: {
selectShowList () {
let vm = this
this.lists.forEach(item => {
if (item.leases_status === 'Y') {
vm.undo.push(item)
} else if (item.leases_status === 'N') {
vm.done.push(item)
}
})
},
getTabNum (i) { getTabNum (i) {
this.tabNum = i
}, },
goAdd () { goAdd () {
this.$router.push({ hlsPopup.showLongCenter('暂不支持无关联进件的车辆发送')
name: 'AddCar',
}) // this.$router.push({
// name: 'AddCar',
// })
}, },
changePage () { changePage (e) {
this.$router.push({ this.$router.push({
name: 'AddCar', name: 'AddCar',
params: {
project_id: e,
},
}) })
}, },
getList () { getList () {
let vm = this let vm = this
let url = process.env.basePath + 'car_confirm_list_query' let url = process.env.basePath + 'car_apply_list_query'
let param = { let param = {
order_id: window.sessionStorage.getItem('user_phone'), order_id: window.sessionStorage.getItem('user_phone'),
} }
......
...@@ -219,7 +219,7 @@ export default new Router({ ...@@ -219,7 +219,7 @@ export default new Router({
{path: '/repay-plan', component: RepayPlan, name: 'RepayPlan', meta: {keepAlive: true}}, {path: '/repay-plan', component: RepayPlan, name: 'RepayPlan', meta: {keepAlive: true}},
// 发车申请 // 发车申请
{path: '/start-List', component: StartList, name: 'StartList', meta: {keepAlive: true}}, {path: '/start-List', component: StartList, name: 'StartList', meta: {keepAlive: true}},
{path: '/add-car', component: AddCar, name: 'AddCar', meta: {keepAlive: true}}, {path: '/add-car', component: AddCar, name: 'AddCar', meta: {keepAlive: false}},
// 发车确认 // 发车确认
{path: '/confirm-detail', component: ConfirmDetail, name: 'ConfirmDetail', meta: {keepAlive: true}}, {path: '/confirm-detail', component: ConfirmDetail, name: 'ConfirmDetail', meta: {keepAlive: true}},
{path: '/confirm-list', component: ConfirmList, name: 'ConfirmList', meta: {keepAlive: true}}, {path: '/confirm-list', component: ConfirmList, name: 'ConfirmList', meta: {keepAlive: true}},
......
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