Commit fa7d0560 authored by Zhang Xiaojie's avatar Zhang Xiaojie

Merge branch 'dev' of gitlab.33.cn:chenqikuai/fns_front_2 into dev

parents 02d75fdb c60acfd1
tar -czf fns_front.tar fns_front
scp fns_front.tar root@124.70.190.110:/usr/share/nginx/html/fns_front.tar
rm -rf fns_front.tar
ssh root@124.70.190.110 'cd /usr/share/nginx/html && rm -rf fns_front && tar -xzf fns_front.tar && rm -rf fns_front.tar'
echo '👉 http://124.70.190.110:2048/'
\ No newline at end of file
...@@ -5,7 +5,8 @@ ...@@ -5,7 +5,8 @@
"scripts": { "scripts": {
"serve": "vue-cli-service serve", "serve": "vue-cli-service serve",
"build": "vue-cli-service build --report", "build": "vue-cli-service build --report",
"bd": "npm run build & bash ./deploy.sh" "bd": "npm run build & bash ./deploy.sh",
"bd_110": "npm run build & bash ./deploy_110.sh"
}, },
"dependencies": { "dependencies": {
"@amap/amap-jsapi-loader": "^1.0.1", "@amap/amap-jsapi-loader": "^1.0.1",
......
...@@ -5,6 +5,8 @@ ...@@ -5,6 +5,8 @@
<meta charset="utf-8"> <meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge"> <meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width,initial-scale=1.0"> <meta name="viewport" content="width=device-width,initial-scale=1.0">
<!-- <meta name="viewport" content="width=device-width; initial-scale=1; maximum-scale=1; minimum-scale=1; user-scalable=no;"> -->
<link rel="icon" href="<%= BASE_URL %>favicon.ico"> <link rel="icon" href="<%= BASE_URL %>favicon.ico">
<title> <title>
<%= htmlWebpackPlugin.options.title %> <%= htmlWebpackPlugin.options.title %>
......
...@@ -32,6 +32,12 @@ export default defineComponent({ ...@@ -32,6 +32,12 @@ export default defineComponent({
setup() { setup() {
onBeforeMount(() => { onBeforeMount(() => {
setTimeout(() => {
new Bridge().getNotchHeight(null, (height: any) => {
console.log('getNotchHeight', height);
})
}, 3000);
new Bridge().getNotchHeight(null, (height: any) => { new Bridge().getNotchHeight(null, (height: any) => {
height = Number(height) height = Number(height)
notchHeight.value = height; notchHeight.value = height;
......
<template> <template>
<div class="wrap18 flex mx-5 overflow-hidden"> <div class="wrap18 flex mx-5 overflow-hidden" @click="goto">
<div class="flex-shrink-0 block2 outer3" style="width: 44%"> <div class="flex-shrink-0 block2 outer3" style="width: 44%">
<div class="flex-col"> <div class="flex-col">
<div class="flex-col"> <div class="flex-col">
...@@ -15,19 +15,56 @@ ...@@ -15,19 +15,56 @@
</div> </div>
</div> </div>
<div class="flex flex-col justify-between items-center mx-2.5 py-5"> <div class="flex flex-col justify-between items-center mx-2.5 py-5">
<p class="word18"> <p class="word18">{{ title }}</p>
知名财经专家现场精彩讲座
</p>
<p class="word19">
建设银行财经专家分析
</p>
</div> </div>
</div> </div>
</template> </template>
<script lang="ts"> <script lang="ts">
import Vue, {defineComponent} from "vue"; import { defineComponent } from "vue";
import Icon from "../common/Icon.vue"; import Icon from "../common/Icon.vue";
export default defineComponent({ components: { Icon } }); import Bridge from "@/utils/jsBridge2"
import { Toast } from "vant";
import { enableLive } from "@/service/StaffService";
export default defineComponent({
components: { Icon },
props: {
title: String,
},
mounted() {
},
methods: {
goto() {
const USER_MSG = window.localStorage.getItem('USER_MSG')
if (!USER_MSG) {
Toast('请先登录')
return
}
let allow = false
let time_section = ''
enableLive().then(res => {
if (res.code === 200) {
allow = res.data.allow
time_section = res.data.time_section
}
new Bridge().bridge_gotoLiveRoom({
phone: JSON.parse(window.localStorage.getItem('USER_MSG') as string)?.userInfo.phone,
avatar: window.location.host + require('@/assets/icons/avatar.png'),
allow,
time_section
})
}).catch(() => {
new Bridge().bridge_gotoLiveRoom({
phone: JSON.parse(window.localStorage.getItem('USER_MSG') as string)?.userInfo.phone,
avatar: window.location.host + require('@/assets/icons/avatar.png'),
allow,
time_section
})
})
},
}
});
</script> </script>
<style scoped> <style scoped>
.wrap18 { .wrap18 {
......
...@@ -9,7 +9,7 @@ ...@@ -9,7 +9,7 @@
}" }"
> >
<div class="top-text text-center">最低{{rate_lower}}%</div> <div class="top-text text-center">最低{{rate_lower}}%</div>
<div class="bottom-text mt-2.5 text-center">贷款年利率</div> <div class="bottom-text mt-2.5 text-center">产品年利率</div>
</div> </div>
<div <div
class="box" class="box"
...@@ -18,7 +18,7 @@ ...@@ -18,7 +18,7 @@
}" }"
> >
<div class="top-text text-center">{{max_date}}个月</div> <div class="top-text text-center">{{max_date}}个月</div>
<div class="bottom-text mt-2.5 text-center">最长贷款期限</div> <div class="bottom-text mt-2.5 text-center">最长产品期限</div>
</div> </div>
<div <div
class="box" class="box"
......
...@@ -89,12 +89,17 @@ export default defineComponent({ ...@@ -89,12 +89,17 @@ export default defineComponent({
default: false default: false
} }
}, },
mounted(){
console.log(document.documentElement.clientWidth, window.screen.width, 'show width');
console.log(window.devicePixelRatio, 'show window.devicePixelRatio');
},
computed: { computed: {
isBangs() { isBangs() {
return true return true
}, },
heightOfNotch() { // 刘海屏的刘海高度 单位px heightOfNotch() { // 刘海屏的刘海高度 单位px
return notchHeight.value; return notchHeight.value / window.devicePixelRatio;
// return 103;
} }
} }
}); });
......
...@@ -551,4 +551,25 @@ jsBridge.prototype.getNotchHeight = function (params, success) { ...@@ -551,4 +551,25 @@ jsBridge.prototype.getNotchHeight = function (params, success) {
} }
} }
/* 获取直播信息 */
jsBridge.prototype.bridge_getliveInfo = function (params, success) {
if (this.curApp == ANDROID) {
dsBridge.call('bridge_getliveInfo', params, success)
}
else if (this.curApp == IOS) {
this.callHandler('bridge_getliveInfo', params, success)
}
}
/* 去直播间 */
jsBridge.prototype.bridge_gotoLiveRoom = function (params, success) {
if (this.curApp == ANDROID) {
dsBridge.call('bridge_gotoLiveRoom', params, success)
}
else if (this.curApp == IOS) {
this.callHandler('bridge_gotoLiveRoom', params, success)
}
}
export default jsBridge; export default jsBridge;
...@@ -208,7 +208,7 @@ export default defineComponent({ ...@@ -208,7 +208,7 @@ export default defineComponent({
</div> </div>
<div class=" bg-white mx-5 rounded-2xl overflow-hidden mt-5"> <div class=" bg-white mx-5 rounded-2xl overflow-hidden mt-5">
<div class="flex justify-between text-sm text-gray-800 border-b border-product-detail-bg"> <div class="flex justify-between text-sm text-gray-800 border-b border-product-detail-bg">
<span class=" w-100 align-center bg-product-detail-bg py-4 inline-block text-center">贷款机构</span> <span class=" w-100 align-center bg-product-detail-bg py-4 inline-block text-center">产品机构</span>
<span class=" w-235 py-4 pr-5 inline-block break-words text-right">{inst_name.value}</span> <span class=" w-235 py-4 pr-5 inline-block break-words text-right">{inst_name.value}</span>
</div> </div>
<div class="flex justify-between text-sm text-gray-800 border-b border-product-detail-bg"> <div class="flex justify-between text-sm text-gray-800 border-b border-product-detail-bg">
...@@ -220,7 +220,7 @@ export default defineComponent({ ...@@ -220,7 +220,7 @@ export default defineComponent({
<span class=" w-235 py-4 pr-5 inline-block break-words text-right">{rate.value}%</span> <span class=" w-235 py-4 pr-5 inline-block break-words text-right">{rate.value}%</span>
</div> </div>
<div class="flex text-sm text-gray-800 border-b border-product-detail-bg justify-between"> <div class="flex text-sm text-gray-800 border-b border-product-detail-bg justify-between">
<span class=" w-100 align-center bg-product-detail-bg py-4 inline-block text-center">贷款额度</span> <span class=" w-100 align-center bg-product-detail-bg py-4 inline-block text-center">产品额度</span>
<span class=" w-235 py-4 pr-5 inline-block break-words text-right">{min_amount.value}~{max_amount.value}</span> <span class=" w-235 py-4 pr-5 inline-block break-words text-right">{min_amount.value}~{max_amount.value}</span>
</div> </div>
<div class="flex text-sm text-gray-800 border-b border-product-detail-bg justify-between"> <div class="flex text-sm text-gray-800 border-b border-product-detail-bg justify-between">
......
<template> <template>
<div class="page"> <div class="page">
<NavBar title="全部贷款" /> <NavBar title="全部产品" />
<div class="layer1 flex-col"> <div class="layer1 flex-col">
<GroupTitle <GroupTitle
class="mt-4" class="mt-4"
title="贷款精选" title="产品精选"
iconName="icon-shaixuan" iconName="icon-shaixuan"
@filter="showFilter" @filter="showFilter"
/> />
</div> </div>
<!-- 贷款列表 --> <!-- 产品列表 -->
<van-list <van-list
v-model:loading="loading" v-model:loading="loading"
:finished="finished" :finished="finished"
......
...@@ -5,7 +5,7 @@ import {enableLive} from '@/service/StaffService/index' ...@@ -5,7 +5,7 @@ import {enableLive} from '@/service/StaffService/index'
export default [ export default [
{ {
name: '贷款服务', name: '产品服务',
icon: 'icon-daikuan', icon: 'icon-daikuan',
color: '#44D392', color: '#44D392',
routerName: 'Loan', routerName: 'Loan',
...@@ -51,6 +51,12 @@ export default [ ...@@ -51,6 +51,12 @@ export default [
} }
let allow = false let allow = false
let time_section = '' let time_section = ''
// new Bridge().bridge_live({
// phone: JSON.parse(window.localStorage.getItem('USER_MSG') as string)?.userInfo.phone,
// avatar: window.location.host + require('../../../assets/icons/avatar.png'),
// allow: true,
// time_section: '30000'
// })
enableLive().then(res => { enableLive().then(res => {
if (res.code === 200) { if (res.code === 200) {
allow = res.data.allow allow = res.data.allow
......
<template> <template>
<Navbar :bangsBlock="true"/> <Navbar :bangsBlock="true" />
<div class="page flex-col"> <div class="page flex-col">
<div class="outer1 flex-col"> <div class="outer1 flex-col">
<Banner class="w-full overflow-hidden" :bannerUrls="bannerList" /> <Banner class="w-full overflow-hidden" :bannerUrls="bannerList" />
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
<group-title <group-title
class="mt-7" class="mt-7"
v-if="product_name" v-if="product_name"
title="热门贷款" title="热门产品"
@click="$router.push({ name: 'Loan' })" @click="$router.push({ name: 'Loan' })"
/> />
<Skeleton :loading="skeLoading" :row="3" class="mt-2"> <Skeleton :loading="skeLoading" :row="3" class="mt-2">
...@@ -28,8 +28,8 @@ ...@@ -28,8 +28,8 @@
" "
/> />
</Skeleton> </Skeleton>
<group-title class="mt-7" title="精彩直播" /> <group-title class="mt-7" title="精彩直播" v-if="LiveRoomTitle" @seeMore="handleSeeMoreLive" />
<LiveCard class="mt-4" /> <LiveCard class="mt-4" :title="LiveRoomTitle" v-if="LiveRoomTitle" />
<group-title <group-title
class="mt-7" class="mt-7"
v-if="src" v-if="src"
...@@ -75,6 +75,7 @@ import { queryBannerList } from "@/service/BannerService"; ...@@ -75,6 +75,7 @@ import { queryBannerList } from "@/service/BannerService";
import { getImageSrcFromFileHash } from "@/service/FileService"; import { getImageSrcFromFileHash } from "@/service/FileService";
import { queryNotifyList } from "@/service/NotifyService"; import { queryNotifyList } from "@/service/NotifyService";
import { queryActivityList } from "@/service/ActivityService"; import { queryActivityList } from "@/service/ActivityService";
import Bridge from "@/utils/jsBridge2"
import { import {
queryLoanProductList, queryLoanProductList,
queryLoanProductInfo, queryLoanProductInfo,
...@@ -99,6 +100,7 @@ export default defineComponent({ ...@@ -99,6 +100,7 @@ export default defineComponent({
}, },
data() { data() {
return { return {
LiveRoomTitle: '',
appList, appList,
skeLoading: false, skeLoading: false,
bannerList: [] as string[], bannerList: [] as string[],
...@@ -140,8 +142,21 @@ export default defineComponent({ ...@@ -140,8 +142,21 @@ export default defineComponent({
this.fetchNotifyList(); this.fetchNotifyList();
this.fetchActivityList(); this.fetchActivityList();
this.fetchLoanProductList(); this.fetchLoanProductList();
this.initLiveRoomCard();
}, },
methods: { methods: {
handleSeeMoreLive() {
},
initLiveRoomCard() {
new Bridge().bridge_getliveInfo(getUserMsg()?.userInfo.phone, (msg: string) => {
if (msg) {
console.log(msg, 'getliveinfo');
this.LiveRoomTitle = msg;
}
})
},
getHotNews() { getHotNews() {
getNewsList({ getNewsList({
limit: 2, limit: 2,
...@@ -182,7 +197,7 @@ export default defineComponent({ ...@@ -182,7 +197,7 @@ export default defineComponent({
}, },
async fetchLoanProductList() { async fetchLoanProductList() {
this.skeLoading = true; this.skeLoading = true;
// 默认查询个人贷款的第一个贷款产品 // 默认查询个人产品的第一个产品产品
const ret = await queryLoanProductList({ const ret = await queryLoanProductList({
limit: 1, limit: 1,
offset: 0, offset: 0,
...@@ -193,7 +208,7 @@ export default defineComponent({ ...@@ -193,7 +208,7 @@ export default defineComponent({
this.skeLoading = false; this.skeLoading = false;
this.hotLoanUuid = ret.data.uuid[0]; this.hotLoanUuid = ret.data.uuid[0];
const uuid = this.hotLoanUuid; const uuid = this.hotLoanUuid;
if(uuid){ if (uuid) {
queryLoanProductInfo({ uuid }).then((ret) => { queryLoanProductInfo({ uuid }).then((ret) => {
console.log("uuid", uuid); console.log("uuid", uuid);
if (ret.code === 200) { if (ret.code === 200) {
......
...@@ -65,11 +65,11 @@ ...@@ -65,11 +65,11 @@
</div> --> </div> -->
<LoanHotSwipe :loanMode="mode" class=" absolute top-0 bottom-0" /> <LoanHotSwipe :loanMode="mode" class=" absolute top-0 bottom-0" />
</div> </div>
<!-- 热门贷款 --> <!-- 热门产品 -->
<!-- <GroupTitle title="热门贷款" class="mt-2.5" v-if="count" iconName="" /> --> <!-- <GroupTitle title="热门产品" class="mt-2.5" v-if="count" iconName="" /> -->
<!-- 非热门贷款 --> <!-- 非热门产品 -->
<GroupTitle <GroupTitle
title="贷款精选" title="产品精选"
v-if="state.allProductList" v-if="state.allProductList"
class=" mt-24" class=" mt-24"
@seeMore="$router.push({ name: 'LoanList', params: { mode: mode } })" @seeMore="$router.push({ name: 'LoanList', params: { mode: mode } })"
...@@ -116,10 +116,10 @@ ...@@ -116,10 +116,10 @@
/> />
</Skeleton> </Skeleton>
</template> </template>
<!-- 贷款资讯 --> <!-- 产品资讯 -->
<GroupTitle <GroupTitle
title="贷款资讯" title="产品资讯"
subtitle="最新贷款资讯展示" subtitle="最新产品资讯展示"
class="mt-2.5" class="mt-2.5"
iconName="" iconName=""
/> />
...@@ -207,7 +207,7 @@ const fetchActivityList = async () => { ...@@ -207,7 +207,7 @@ const fetchActivityList = async () => {
}; };
const fetchList = () => { const fetchList = () => {
// 取前7贷款产品遍历 // 取前7产品产品遍历
skeLoading.value = true; skeLoading.value = true;
queryLoanProductList({ queryLoanProductList({
limit: 4, limit: 4,
......
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
<h1 class=" h-4"> <h1 class=" h-4">
<img src="../../../assets/img/quotation.png" class=" w-8 h-7"> <img src="../../../assets/img/quotation.png" class=" w-8 h-7">
</h1> </h1>
<p class=" text-gray-800 font-semibold text-sm pl-1">给您提供值得信赖的贷款服务</p> <p class=" text-gray-800 font-semibold text-sm pl-1">给您提供值得信赖的产品服务</p>
<p class=" text-gray-400 text-xs mt-1 pl-1">解决广大中小企业融资难、融资贵的问题</p> <p class=" text-gray-400 text-xs mt-1 pl-1">解决广大中小企业融资难、融资贵的问题</p>
<!-- card1 --> <!-- card1 -->
<card title="专业的金融团队" :path="require('../../../assets/icons/team.png')"> <card title="专业的金融团队" :path="require('../../../assets/icons/team.png')">
......
...@@ -19,7 +19,7 @@ export default [ ...@@ -19,7 +19,7 @@ export default [
showNotLogin: true, showNotLogin: true,
}, },
{ {
name: '贷款', name: '产品',
routeName: 'Loan', routeName: 'Loan',
icon: 'icon-daikuan-tab-xuanze', icon: 'icon-daikuan-tab-xuanze',
icon1: 'icon-daikuan-tab', icon1: 'icon-daikuan-tab',
......
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