Commit 2f0b3b78 authored by linxin's avatar linxin

Merge branch 'liuxin' into develop

parents 00fabd3c 7f91d205
...@@ -235,7 +235,7 @@ ...@@ -235,7 +235,7 @@
</div> </div>
</div> </div>
</div> </div>
<RentInfo v-show="tabNum==1" :rentInfo="rentInfo" /> <RentInfo v-show="tabNum==1"/>
<AccessoryInfo v-show="tabNum==2" @down="getDown" /> <AccessoryInfo v-show="tabNum==2" @down="getDown" />
</h-content> </h-content>
<bottom-tab class="footer-button"> <bottom-tab class="footer-button">
...@@ -287,7 +287,7 @@ export default { ...@@ -287,7 +287,7 @@ export default {
baseInfo: {}, baseInfo: {},
checkedImg: checkedImg, checkedImg: checkedImg,
isDown: false, isDown: false,
bp_class: this.$route.params.bp_class, bp_class: window.sessionStorage.bp_class,
rentInfo: {}, rentInfo: {},
bondsInfo: [], bondsInfo: [],
personInfo: { personInfo: {
...@@ -329,7 +329,7 @@ export default { ...@@ -329,7 +329,7 @@ export default {
} }
}, },
mounted () { mounted () {
this.getRent() // this.getRent()
this.getBonds() this.getBonds()
this.popProtocol() this.popProtocol()
}, },
...@@ -347,24 +347,11 @@ export default { ...@@ -347,24 +347,11 @@ export default {
confirm () { confirm () {
this.ischecked ? (this.isConfirm = true) : (this.isConfirm = false) this.ischecked ? (this.isConfirm = true) : (this.isConfirm = false)
}, },
getRent () {
let vm = this
let url = process.env.basePath + 'prj_lease_query'
let param = {
project_id: '46002',
}
vm.hlsHttp.post(url, param).then(function (res) {
vm.hlsPopup.hideLoading()
if (res.result === 'S') {
vm.rentInfo = res.info
}
})
},
getNPBase () { getNPBase () {
let vm = this let vm = this
let url = process.env.basePath + 'prj_np_info_query' let url = process.env.basePath + 'prj_np_info_query'
let param = { let param = {
project_id: this.$route.params.project_id, project_id: window.sessionStorage.project_id,
} }
vm.hlsHttp.post(url, param).then(function (res) { vm.hlsHttp.post(url, param).then(function (res) {
vm.hlsPopup.hideLoading() vm.hlsPopup.hideLoading()
...@@ -377,7 +364,7 @@ export default { ...@@ -377,7 +364,7 @@ export default {
let vm = this let vm = this
let url = process.env.basePath + 'prj_org_info_query' let url = process.env.basePath + 'prj_org_info_query'
let param = { let param = {
project_id: this.$route.params.project_id, project_id: window.sessionStorage.project_id,
} }
vm.hlsHttp.post(url, param).then(function (res) { vm.hlsHttp.post(url, param).then(function (res) {
vm.hlsPopup.hideLoading() vm.hlsPopup.hideLoading()
......
...@@ -9,26 +9,26 @@ ...@@ -9,26 +9,26 @@
</h-header> </h-header>
<div class="top-content"> <div class="top-content">
<span class="top-tittle">融资额(元)</span> <span class="top-tittle">融资额(元)</span>
<span class="num">190,000.00</span> <span class="num">{{ info.finance_amount|NumFormat }}</span>
<div class="top-detail"> <div class="top-detail">
<div class="left"> <div class="left">
<span class="line">保证金</span> <span class="line">保证金</span>
<span>5,000.00</span> <span>{{ info.deposit|NumFormat }}</span>
</div> </div>
<div class="right"> <div class="right">
<span class="line">首付款</span> <span class="line">首付款</span>
<span>20,000.00</span> <span>{{ info.down_payment|NumFormat }}</span>
</div> </div>
</div> </div>
<div class="clear" /> <div class="clear" />
<div class="top-detail"> <div class="top-detail">
<div class="left"> <div class="left">
<span class="line">手续费</span> <span class="line">手续费</span>
<span>5,000.00</span> <span>{{ info.lease_charge|NumFormat }}</span>
</div> </div>
<div class="right"> <div class="right">
<span class="line">合同期数</span> <span class="line">合同期数</span>
<span>20,000.00</span> <span>{{ info.lease_times }}</span>
</div> </div>
</div> </div>
</div> </div>
...@@ -41,24 +41,65 @@ ...@@ -41,24 +41,65 @@
<th>现金流项目</th> <th>现金流项目</th>
<th>应还金额</th> <th>应还金额</th>
</tr> </tr>
<tr> <tr v-for="(item,index) in lists" :key="index">
<td>1</td> <td>{{ index+1 }}</td>
<td>2019-01-01</td> <td>{{ item.due_date }}</td>
<td>租金</td>
<td>9,000.00</td>
</tr>
<tr>
<td>1</td>
<td>2019-01-01</td>
<td>租金</td> <td>租金</td>
<td>9,000.00</td> <td>{{ item.rental|NumFormat }}</td>
</tr> </tr>
</table> </table>
</h-content> </h-content>
</h-view> </h-view>
</template> </template>
<script> <script>
export default {} export default {
filters: {
NumFormat: function (value) {
if (!value) return '0.00'
var intPart = Number(value) | 0 // 获取整数部分
var intPartFormat = intPart.toString().replace(/(\d)(?=(?:\d{3})+$)/g, '$1,') // 将整数部分逢三一断
var floatPart = '.00' // 预定义小数部分
var value2Array = value.split('.')
// =2表示数据有小数位
if (value2Array.length === 2) {
floatPart = value2Array[1].toString() // 拿到小数部分
if (floatPart.length === 1) { // 补0,实际上用不着
return intPartFormat + '.' + floatPart + '0'
} else {
return intPartFormat + '.' + floatPart
}
} else {
return intPartFormat + floatPart
}
},
},
data () {
return {
info: {},
lists: [],
}
},
created () {
this.getInfo()
},
methods: {
getInfo () {
let vm = this
let url = process.env.basePath + 'prj_cashflow_query'
let param = {
project_id: window.sessionStorage.project_id,
}
vm.hlsHttp.post(url, param).then(function (res) {
vm.hlsPopup.hideLoading()
if (res.result === 'S') {
vm.lists = res.lists
vm.info = res.info
}
})
},
},
}
</script> </script>
<style lang="less" scoped> <style lang="less" scoped>
#refund { #refund {
...@@ -83,9 +124,9 @@ export default {} ...@@ -83,9 +124,9 @@ export default {}
} }
.top { .top {
width: 100%; width: 100%;
height: 265px; height: 285px;
background: url("../../../assets/intoApproval/backtop.png") no-repeat; background: url("../../../assets/intoApproval/backtop.png") no-repeat;
background-size: 375px 285px; background-size: 100% 285px;
.top-detail { .top-detail {
margin-top: 12px; margin-top: 12px;
width: 260px; width: 260px;
...@@ -94,13 +135,16 @@ export default {} ...@@ -94,13 +135,16 @@ export default {}
font-size: 12px; font-size: 12px;
height: 12px; height: 12px;
color: rgba(255, 255, 255, 0.6); color: rgba(255, 255, 255, 0.6);
padding-left: 10px;
} }
.line::before { .line::before {
content: "|"; content: "";
color: #ffffff; display:inline-block;
width:2px;
height:12px;
background-color: #ffffff;
position: relative; position: relative;
left: -10px; left: -5px;
top:2px;
} }
.left { .left {
float: left; float: left;
......
...@@ -101,23 +101,58 @@ export default { ...@@ -101,23 +101,58 @@ export default {
} }
}, },
}, },
props: { data () {
'rentInfo': { return {
default: {}, rentInfo: {
type: Object, finance_amount: '',
}, lease_charge: '',
annual_pay_times: '',
deposit_ratio_n: ' ',
lease_charge_ratio_n: ' ',
product_plan_id: '',
equip_price: '',
lease_charge_ratio: '',
int_rate_n: ' ',
product_num: '',
down_payment: '',
deposit_ratio: '',
division: '',
lease_times: '',
pre_pay_date: '',
product_id: '',
deposit: '',
int_rate: '',
product_plan_id_n: '',
},
}
}, },
computed: { computed: {
'time': function () { 'time': function () {
return this.rentInfo.pre_pay_date.substr(0, 10) return this.rentInfo.pre_pay_date.substr(0, 10)
}, },
}, },
created () {
this.getRent()
},
methods: { methods: {
changeRefund () { changeRefund () {
this.$router.push({ this.$router.push({
name: 'Refund', name: 'Refund',
}) })
}, },
getRent () {
let vm = this
let url = process.env.basePath + 'prj_lease_query'
let param = {
project_id: window.sessionStorage.project_id,
}
vm.hlsHttp.post(url, param).then(function (res) {
vm.hlsPopup.hideLoading()
if (res.result === 'S') {
vm.rentInfo = res.info
}
})
},
}, },
} }
......
...@@ -74,13 +74,10 @@ export default { ...@@ -74,13 +74,10 @@ export default {
this.tabNum = i this.tabNum = i
}, },
goDetails (item) { goDetails (item) {
console.log(item) window.sessionStorage.setItem('bp_class', item.bp_class)
window.sessionStorage.setItem('project_id', item.project_id)
this.$router.push({ this.$router.push({
name: 'Base', name: 'Base',
params: {
bp_class: item.bp_class,
project_id: item.project_id,
},
}) })
}, },
}, },
......
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