Commit 0cfc2f1e authored by lshan's avatar lshan

合并

parents f00a14c4 420f553a
...@@ -60,8 +60,11 @@ const fetchList = () => { ...@@ -60,8 +60,11 @@ const fetchList = () => {
skeLoading.value = false; skeLoading.value = false;
ret.data.uuid.map((uuid) => { ret.data.uuid.map((uuid) => {
queryLoanProductInfo({ uuid }).then((ret) => { queryLoanProductInfo({ uuid }).then((ret) => {
const { rate_lower, max_amount, max_date, inst_name, product_name } = const { rate_lower, max_amount, max_date, inst_name, product_name,product_status } =
ret.data; ret.data;
console.log('status',product_status);
if( product_status == 3){
state.hotProductList.push({ state.hotProductList.push({
rate_lower, rate_lower,
max_amount, max_amount,
...@@ -69,11 +72,15 @@ const fetchList = () => { ...@@ -69,11 +72,15 @@ const fetchList = () => {
inst_name, inst_name,
product_name, product_name,
uuid, uuid,
product_status
}); });
}
}); });
}); });
} }
}); });
console.log('pro',state.hotProductList);
}; };
</script> </script>
......
...@@ -4,5 +4,6 @@ export interface hotProduct{ ...@@ -4,5 +4,6 @@ export interface hotProduct{
max_date:number max_date:number
inst_name:string inst_name:string
product_name:string, product_name:string,
uuid:string uuid:string,
product_status:number
} }
\ No newline at end of file
...@@ -30,8 +30,9 @@ ...@@ -30,8 +30,9 @@
</div> </div>
<div class="border border-blue-50"></div> <div class="border border-blue-50"></div>
<!-- 营业时间 --> <!-- 营业时间 -->
<div class="mt-2 pb-3"> <div class="mt-2 pb-3 flex justify-between items-center">
<template v-if="is_normal_work"> <div class="overflow-hidden mr-6">
<div v-if="is_normal_work" class="mb-2">
<icon <icon
name="icon-yingye" name="icon-yingye"
color="#1B1F37" color="#1B1F37"
...@@ -46,7 +47,24 @@ ...@@ -46,7 +47,24 @@
v-else v-else
class="text-app-blue border border-app-blue bg-indigo-100 text-xs px-2 rounded" class="text-app-blue border border-app-blue bg-indigo-100 text-xs px-2 rounded"
>休息中</span> >休息中</span>
</div>
<div v-if="is_normal_work">
<icon
name="icon-a-shijian"
color="#1B1F37"
size="14"
class="inline-block align-text-top mr-3"
/>
<span
class="text-gray-400 text-sm inline-block align-top"
>{{ weekDays }}{{ dailyTime }}</span>
</div>
<template v-else>
<!-- <div class="text-red">{{ error }}</div> -->
<div class="text-red">{{ errorReason }}</div>
</template> </template>
</div>
<div class="text-right h-3"> <div class="text-right h-3">
<icon <icon
name="icon-ditu" name="icon-ditu"
......
<template> <template>
<div class="navbar w-full" style="z-index: 300"> <div class="navbar w-full" style="z-index: 300">
<div <div
class="h-full theBar flex items-center px-5 justify-center relative " class="h-full theBar flex items-center px-5 justify-center relative"
style="background:#F7F7FA" style="background:#F7F7FA"
v-bind="$attrs" v-bind="$attrs"
> >
...@@ -30,7 +30,7 @@ ...@@ -30,7 +30,7 @@
@click="$router.push(path)" @click="$router.push(path)"
:color="iconColor" :color="iconColor"
/> />
<div class="title">{{ title }}</div> <div class="title whitespace-nowrap overflow-hidden overflow-ellipsis px-5">{{ title }}</div>
</div> </div>
</div> </div>
<div class="some-block" v-if="occupyPosition"></div> <div class="some-block" v-if="occupyPosition"></div>
......
import { reactive } from "vue"
import { eLoanMode } from "@/views/withMenu/Loan/types"
export const loanMode = {
state: reactive({
mode: eLoanMode.personal
}),
setModeAction(newV: eLoanMode) {
this.state.mode = newV
console.log('newV',newV);
}
}
\ No newline at end of file
import { simpleItemInfo } from "@/views/withMenu/Loan/types"
import { reactive } from "@vue/reactivity"
export const loanSearchState = reactive({ result: [] as simpleItemInfo[] })
export function setSearchResult(newV: simpleItemInfo) {
loanSearchState.result.push(newV)
}
export function clearSearchResult() {
loanSearchState.result = []
}
...@@ -51,7 +51,7 @@ export const getDisplayNamesFromAddress = async ( ...@@ -51,7 +51,7 @@ export const getDisplayNamesFromAddress = async (
return addressList.map((item) => { return addressList.map((item) => {
const msg = fullList.find((i: any) => i?.addr === item) const msg = fullList.find((i: any) => i?.addr === item)
if (msg?.out_let_name) { if (msg?.out_let_name) {
return msg?.out_let_name + '客服经理' return msg?.out_let_name + msg.user_name
} else { } else {
return msg?.phone return msg?.phone
} }
......
...@@ -58,6 +58,7 @@ import Icon from "@/components/common/Icon.vue"; ...@@ -58,6 +58,7 @@ import Icon from "@/components/common/Icon.vue";
import { useRoute } from "vue-router"; import { useRoute } from "vue-router";
import { getUserMsg } from "@/utils/userMsg"; import { getUserMsg } from "@/utils/userMsg";
import { eRole } from "@/types/roleType"; import { eRole } from "@/types/roleType";
import ChatDBService from "@/db/ChatDBService";
export default defineComponent({ export default defineComponent({
props: { props: {
...@@ -117,7 +118,6 @@ export default defineComponent({ ...@@ -117,7 +118,6 @@ export default defineComponent({
console.log('handle send'); console.log('handle send');
const isStaff = getUserMsg()?.role === eRole.staff; const isStaff = getUserMsg()?.role === eRole.staff;
const isUser = getUserMsg()?.role === eRole.user; const isUser = getUserMsg()?.role === eRole.user;
console.log(isStaff, 'isStaff');
if (isUser && props.serviceShowValue === "人工服务") { if (isUser && props.serviceShowValue === "人工服务") {
messageStore.displayNewMessage({ messageStore.displayNewMessage({
...@@ -131,6 +131,21 @@ export default defineComponent({ ...@@ -131,6 +131,21 @@ export default defineComponent({
datetime: new Date().getTime(), datetime: new Date().getTime(),
type: ChatMessageTypes.robot, type: ChatMessageTypes.robot,
}) })
ChatDBService.getInstance().handleEveryReceive({
msg: {
content: {
content: inputText.value
},
from: getFromId() as string,
target: target,
uuid: uuidv4(),
state: 'success',
datetime: new Date().getTime(),
type: ChatMessageTypes.robot,
},
masterId: getFromId() as string,
isChattingWithTargetId: true,
})
textInputStore.clearTextMessage(); textInputStore.clearTextMessage();
} else { } else {
sendChatMessage({ type: 1, content: { content: inputText.value } }) sendChatMessage({ type: 1, content: { content: inputText.value } })
......
...@@ -233,27 +233,30 @@ export default defineComponent({ ...@@ -233,27 +233,30 @@ export default defineComponent({
<span class="word8">产品详情</span> <span class="word8">产品详情</span>
<img class="label6" src={leftBg} /> <img class="label6" src={leftBg} />
</div> </div>
<div class="block10 flex"> <div class=" bg-white mx-5 rounded-2xl overflow-hidden mt-5">
<div class="group6 flex-col"> <div class="flex justify-between text-sm text-gray-800 border-b border-product-detail-bg">
<div class="wrap3 flex-col"> <span class=" w-100 align-center bg-product-detail-bg py-4 inline-block text-center">贷款机构</span>
<span class="txt11">贷款机构</span> <span class=" w-235 py-4 pr-5 inline-block break-words text-right">{inst_name.value}</span>
<span class="info15">产品名称</span>
<span class="word20">贷款利率</span>
<span class="txt12">贷款额度</span>
<span class="txt13">贷款期限</span>
<span class="txt14">担保方式</span>
</div> </div>
<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-235 py-4 pr-5 inline-block break-words text-right">{product_name.value}</span>
</div> </div>
<div class="section4 flex-row"> <div class="flex text-sm text-gray-800 border-b border-product-detail-bg justify-between">
<div class="mod1 flex-col" /> <span class=" w-100 align-center bg-product-detail-bg py-4 inline-block text-center">贷款利率</span>
<div class="mod2 flex-col w-full text-right"> <span class=" w-235 py-4 pr-5 inline-block break-words text-right">{rate_lower.value}%~{rate_upper.value}%</span>
<span class="info8">{inst_name.value}</span>
<span class="info9">{product_name.value}</span>
<span class="info10">{rate_lower.value}%~{rate_upper.value}%</span>
<span class="info11">{min_amount.value}~{max_amount.value}</span>
<span class="word9">{min_date.value}个月~{max_date.value}个月</span>
<span class="info12">{filterGuaranteeType(guarantee_type.value)}</span>
</div> </div>
<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-235 py-4 pr-5 inline-block break-words text-right">{min_amount.value}~{max_amount.value}</span>
</div>
<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-235 py-4 pr-5 inline-block break-words text-right">{min_date.value}个月~{max_date.value}个月</span>
</div>
<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-235 py-4 pr-5 inline-block break-words text-right">{filterGuaranteeType(guarantee_type.value)}</span>
</div> </div>
</div> </div>
<LoanDetailDescribe class=" mt-5" products={products.value} features={features.value} apply_to={apply_to.value} apply_cond={apply_cond.value} submit_cond={submit_cond.value} /> <LoanDetailDescribe class=" mt-5" products={products.value} features={features.value} apply_to={apply_to.value} apply_cond={apply_cond.value} submit_cond={submit_cond.value} />
...@@ -294,6 +297,7 @@ export default defineComponent({ ...@@ -294,6 +297,7 @@ export default defineComponent({
}, },
}); });
</script> </script>
<style lang="less" scoped> <style lang="less" scoped>
@import "./index.less"; @import "./index.less";
.title { .title {
...@@ -309,4 +313,11 @@ export default defineComponent({ ...@@ -309,4 +313,11 @@ export default defineComponent({
font-weight: 600; font-weight: 600;
color: #ffffff; color: #ffffff;
} }
.w-100{
width:100px;
}
.w-235{
width:235px;
}
</style> </style>
\ No newline at end of file
...@@ -18,7 +18,7 @@ ...@@ -18,7 +18,7 @@
@load="onLoad" @load="onLoad"
> >
<LoanCard <LoanCard
v-for="item in state.list" v-for="item in state"
:key="item.value" :key="item.value"
:max_amount="item.max_amount" :max_amount="item.max_amount"
:product_name="item.product_name" :product_name="item.product_name"
...@@ -67,9 +67,16 @@ import GroupTitle from "@/components/GroupTitle/index.vue"; ...@@ -67,9 +67,16 @@ import GroupTitle from "@/components/GroupTitle/index.vue";
import PopUp from "@/components/PopUp/index.vue"; import PopUp from "@/components/PopUp/index.vue";
import LoanFilter from "@/components/PopUpContent/LoanFilter/index.vue"; import LoanFilter from "@/components/PopUpContent/LoanFilter/index.vue";
import LoanCard from "@/components/Loan/LoanCard/index.vue"; import LoanCard from "@/components/Loan/LoanCard/index.vue";
import { defineComponent, ref, computed, onMounted, reactive } from "vue"; import {
defineComponent,
ref,
computed,
onMounted,
reactive,
onUnmounted,
} from "vue";
import { queryDirectLoanReq } from "@/service/LoanProductService/index"; import { queryDirectLoanReq } from "@/service/LoanProductService/index";
import { useRoute } from "vue-router"; import { useRoute, useRouter } from "vue-router";
import { import {
queryLoanProductList, queryLoanProductList,
queryLoanProductInfo, queryLoanProductInfo,
...@@ -78,6 +85,11 @@ import { ...@@ -78,6 +85,11 @@ import {
import { simpleItemInfo } from "@/views/withMenu/Loan/types"; import { simpleItemInfo } from "@/views/withMenu/Loan/types";
import { iLoanProdcutItem } from "@/service/LoanProductService/type"; import { iLoanProdcutItem } from "@/service/LoanProductService/type";
import { Skeleton } from "vant"; import { Skeleton } from "vant";
import {
loanSearchState,
setSearchResult,
clearSearchResult,
} from "@/store/loanSearchResultStore";
export default defineComponent({ export default defineComponent({
components: { components: {
...@@ -90,9 +102,20 @@ export default defineComponent({ ...@@ -90,9 +102,20 @@ export default defineComponent({
}, },
setup() { setup() {
const mode = ref(+useRoute().params.mode); const mode = ref(+useRoute().params.mode);
onMounted(() => { onMounted(() => {
/* 状态为空时获取list */
if (loanSearchState.result.length == 0) {
fetchList(); fetchList();
fetchBanks(); fetchBanks();
}
});
onUnmounted(() => {
/* 返回Loan主页时需清空list */
if (useRoute().name === "Loan") {
clearSearchResult()
}
}); });
const onLoad = () => { const onLoad = () => {
...@@ -112,8 +135,8 @@ export default defineComponent({ ...@@ -112,8 +135,8 @@ export default defineComponent({
const loading = ref(false); const loading = ref(false);
const finished = ref(false); const finished = ref(false);
const total = ref(0); const total = ref(0);
let state = reactive({ const state = computed(() => {
list: [] as simpleItemInfo[], return loanSearchState.result;
}); });
const bankList = computed(() => { const bankList = computed(() => {
...@@ -136,7 +159,7 @@ export default defineComponent({ ...@@ -136,7 +159,7 @@ export default defineComponent({
queryLoanProductInfo({ uuid }).then((ret) => { queryLoanProductInfo({ uuid }).then((ret) => {
const { max_amount, inst_name, uuid, features, product_name } = const { max_amount, inst_name, uuid, features, product_name } =
ret.data; ret.data;
state.list.push({ setSearchResult({
max_amount, max_amount,
product_name, product_name,
features, features,
...@@ -158,6 +181,7 @@ export default defineComponent({ ...@@ -158,6 +181,7 @@ export default defineComponent({
} }
}); });
}; };
return { return {
mode, mode,
state, state,
...@@ -262,10 +286,10 @@ export default defineComponent({ ...@@ -262,10 +286,10 @@ export default defineComponent({
queryList() { queryList() {
this.loading = true; this.loading = true;
queryDirectLoanReq({ queryDirectLoanReq({
rate_lower: +this.reqParams.min!, rate_lower: +this.reqParams.min! ? +this.reqParams.min! : 0,
rate_upper: +this.reqParams.max!, rate_upper: +this.reqParams.max! ? +this.reqParams.max! : 1000,
min_amount: +this.reqParams.min2!, min_amount: +this.reqParams.min2! ? +this.reqParams.min2! : 0,
max_amount: +this.reqParams.max2!, max_amount: +this.reqParams.max2! ? +this.reqParams.max2! : 9999,
bank_code: this.reqParams.selectedBanks[0], bank_code: this.reqParams.selectedBanks[0],
max_date: this.reqParams.selectedPerids[0] max_date: this.reqParams.selectedPerids[0]
? this.reqParams.selectedPerids[0].max_date ? this.reqParams.selectedPerids[0].max_date
...@@ -281,19 +305,18 @@ export default defineComponent({ ...@@ -281,19 +305,18 @@ export default defineComponent({
}).then((ret) => { }).then((ret) => {
if (ret.code == 200) { if (ret.code == 200) {
this.loading = false; this.loading = false;
this.state.list = []; clearSearchResult();
const list = ret.data.items.map((item) => { ret.data.items.map((item) => {
const { max_amount, inst_name, uuid, features, product_name } = const { max_amount, inst_name, uuid, features, product_name } =
item; item;
return { setSearchResult({
max_amount, max_amount,
product_name, product_name,
features, features,
inst_name, inst_name,
uuid, uuid,
};
}); });
this.state.list = list; });
} }
}); });
}, },
......
...@@ -21,7 +21,7 @@ ...@@ -21,7 +21,7 @@
:features="features" :features="features"
:inst_name="inst_name" :inst_name="inst_name"
class="mt-5" class="mt-5"
@click="$router.push({ name: 'LoanDetail', params: { uuid: uuid } })" @click="$router.push({ name: 'LoanDetail', params: { uuid: hotLoanUuid } })"
/> />
</Skeleton> </Skeleton>
<group-title class="mt-7" title="精彩直播" /> <group-title class="mt-7" title="精彩直播" />
...@@ -39,7 +39,7 @@ ...@@ -39,7 +39,7 @@
@click=" @click="
$router.push({ $router.push({
name: 'ActivityDetail', name: 'ActivityDetail',
params: { uuid: uuid }, params: { uuid: activityUuid },
}) })
" "
/> />
...@@ -121,11 +121,12 @@ export default defineComponent({ ...@@ -121,11 +121,12 @@ export default defineComponent({
constants: {}, constants: {},
hotNews: [], hotNews: [],
src: "", src: "",
uuid: "", activityUuid: "",
max_amount: 0, max_amount: 0,
product_name: "", product_name: "",
features: "", features: "",
inst_name: "", inst_name: "",
hotLoanUuid:""
}; };
}, },
mounted() { mounted() {
...@@ -166,7 +167,7 @@ export default defineComponent({ ...@@ -166,7 +167,7 @@ export default defineComponent({
if (ret.code === 200) { if (ret.code === 200) {
this.skeLoading = false; this.skeLoading = false;
this.src = getImageSrcFromFileHash(ret.data.items[0]?.file_name); this.src = getImageSrcFromFileHash(ret.data.items[0]?.file_name);
this.uuid = ret.data.items[0]?.uuid; this.activityUuid = ret.data.items[0]?.uuid;
} }
}, },
async fetchLoanProductList() { async fetchLoanProductList() {
...@@ -179,9 +180,11 @@ export default defineComponent({ ...@@ -179,9 +180,11 @@ export default defineComponent({
}); });
if (ret.code === 200) { if (ret.code === 200) {
this.skeLoading = false; this.skeLoading = false;
this.uuid = ret.data.uuid[0]; this.hotLoanUuid = ret.data.uuid[0];
const uuid = this.uuid; const uuid = this.hotLoanUuid;
queryLoanProductInfo({ uuid }).then((ret) => { queryLoanProductInfo( {uuid} ).then((ret) => {
console.log('uuid',uuid);
if (ret.code === 200) { if (ret.code === 200) {
this.max_amount = ret.data.max_amount; this.max_amount = ret.data.max_amount;
this.inst_name = ret.data.inst_name; this.inst_name = ret.data.inst_name;
......
...@@ -10,7 +10,7 @@ ...@@ -10,7 +10,7 @@
color: color:
eLoanMode.personal === mode ? 'rgba(62, 79, 175, 1)' : '', eLoanMode.personal === mode ? 'rgba(62, 79, 175, 1)' : '',
}" }"
@click="setMode(eLoanMode.personal)" @click="loanMode.setModeAction(eLoanMode.personal)"
>个人贷</span >个人贷</span
> >
<span <span
...@@ -18,7 +18,7 @@ ...@@ -18,7 +18,7 @@
:style="{ :style="{
color: eLoanMode.company === mode ? 'rgba(62, 79, 175, 1)' : '', color: eLoanMode.company === mode ? 'rgba(62, 79, 175, 1)' : '',
}" }"
@click="setMode(eLoanMode.company)" @click="loanMode.setModeAction(eLoanMode.company)"
>企业贷</span >企业贷</span
> >
</div> </div>
...@@ -60,7 +60,7 @@ ...@@ -60,7 +60,7 @@
</div> </div>
</div> </div>
<!-- 热门贷款 --> <!-- 热门贷款 -->
<GroupTitle title="热门贷款" class="mt-2.5" iconName="" /> <GroupTitle title="热门贷款" class="mt-2.5" v-if="count" iconName="" />
<LoanHotSwipe :loanMode="mode" class="mt-5" /> <LoanHotSwipe :loanMode="mode" class="mt-5" />
<!-- 非热门贷款 --> <!-- 非热门贷款 -->
<GroupTitle <GroupTitle
...@@ -68,7 +68,12 @@ ...@@ -68,7 +68,12 @@
v-if="state.allProductList" v-if="state.allProductList"
@seeMore="$router.push({ name: 'LoanList', params: { mode: mode } })" @seeMore="$router.push({ name: 'LoanList', params: { mode: mode } })"
/> />
<Skeleton :row="3" :loading="skeLoading" style="margin-top: 20px" v-if="state.allProductList"> <Skeleton
:row="3"
:loading="skeLoading"
style="margin-top: 20px"
v-if="state.allProductList"
>
<LoanCard <LoanCard
v-for="item in state.allProductList" v-for="item in state.allProductList"
:key="item.value" :key="item.value"
...@@ -125,7 +130,13 @@ import GroupTitle from "@/components/GroupTitle/index.vue"; ...@@ -125,7 +130,13 @@ import GroupTitle from "@/components/GroupTitle/index.vue";
import HotNews from "@/components/HotNews/index.vue"; import HotNews from "@/components/HotNews/index.vue";
import { queryActivityList } from "@/service/ActivityService"; import { queryActivityList } from "@/service/ActivityService";
import { getImageSrcFromFileHash } from "@/service/FileService"; import { getImageSrcFromFileHash } from "@/service/FileService";
import { onMounted, PropType, reactive, watch } from "@vue/runtime-core"; import {
computed,
onMounted,
PropType,
reactive,
watch,
} from "@vue/runtime-core";
import { getNewsList } from "@/service/NewsService/index"; import { getNewsList } from "@/service/NewsService/index";
import { simpleItemInfo } from "./types"; import { simpleItemInfo } from "./types";
import { Skeleton } from "vant"; import { Skeleton } from "vant";
...@@ -134,12 +145,10 @@ import { ...@@ -134,12 +145,10 @@ import {
queryLoanProductInfo, queryLoanProductInfo,
queryLimit, queryLimit,
} from "@/service/LoanProductService"; } from "@/service/LoanProductService";
import { loanMode } from "@/store/loanModeStore";
const mode = ref(eLoanMode.personal); import { clearSearchResult } from "@/store/loanSearchResultStore"
let skeLoading = ref(false); let skeLoading = ref(false);
const setMode = (v: eLoanMode) => {
mode.value = v;
};
let state = reactive({ allProductList: [] as Array<simpleItemInfo> }); let state = reactive({ allProductList: [] as Array<simpleItemInfo> });
const src = ref(""); const src = ref("");
const uuid = ref(""); const uuid = ref("");
...@@ -150,11 +159,20 @@ const limit = reactive({ ...@@ -150,11 +159,20 @@ const limit = reactive({
max_amount: "", max_amount: "",
state: false, state: false,
}); });
const count = ref(0);
const mode = computed(() => {
return loanMode.state.mode;
});
watch(mode, () => { watch(
() => loanMode.state.mode,
() => {
state.allProductList = []; state.allProductList = [];
clearSearchResult();
fetchList(); fetchList();
}); }
);
const getNews = () => { const getNews = () => {
getNewsList({ getNewsList({
...@@ -177,19 +195,28 @@ const fetchActivityList = () => { ...@@ -177,19 +195,28 @@ const fetchActivityList = () => {
skeLoading.value = false; skeLoading.value = false;
}; };
const fetchList = () => { const fetchList = () => {
// 取从四开始的贷款,即非热门贷款 // 取前7贷款产品遍历
skeLoading.value = true; skeLoading.value = true;
queryLoanProductList({ queryLoanProductList({
limit: 4, limit: 7,
loan_type: mode.value, loan_type: mode.value,
offset: 3, offset: 0,
}).then((ret) => { }).then((ret) => {
if (ret.code === 200) { if (ret.code === 200) {
skeLoading.value = false; skeLoading.value = false;
ret.data.uuid.map((uuid) => { ret.data.uuid.map((uuid) => {
queryLoanProductInfo({ uuid }).then((ret) => { queryLoanProductInfo({ uuid }).then((ret) => {
const { max_amount, inst_name, uuid, features, product_name } = const {
ret.data; max_amount,
inst_name,
uuid,
features,
product_name,
product_status,
} = ret.data;
if (count.value < 4) {
if (product_status == 2) {
count.value = count.value + 1;
state.allProductList.push({ state.allProductList.push({
max_amount, max_amount,
product_name, product_name,
...@@ -197,10 +224,13 @@ const fetchList = () => { ...@@ -197,10 +224,13 @@ const fetchList = () => {
inst_name, inst_name,
uuid, uuid,
}); });
}
}
}); });
}); });
} }
}); });
count.value = 0;
}; };
const formatLimit = (limit: string): string => { const formatLimit = (limit: string): string => {
......
...@@ -10,5 +10,6 @@ export interface simpleItemInfo{ ...@@ -10,5 +10,6 @@ export interface simpleItemInfo{
product_name:string, product_name:string,
features:string, features:string,
inst_name:string, inst_name:string,
uuid:string uuid:string,
product_status?:number
} }
\ No newline at end of file
...@@ -27,8 +27,8 @@ ...@@ -27,8 +27,8 @@
<!-- 附近网点 --> <!-- 附近网点 -->
<Skeleton :row="3" :loading="result.loading" class="-mt-20 mb-10"></Skeleton> <Skeleton :row="3" :loading="result.loading" class="-mt-20 mb-10"></Skeleton>
<Skeleton :row="3" :loading="result.loading" class="mt-5"> <Skeleton :row="3" :loading="result.loading" class="mt-5">
<div class="px-4 overflow-scroll -mt-10"> <div class="px-4 overflow-scroll -mt-8">
<p class="mt-8 mb-5 text-base font-semibold text-gray-800">附近的网点</p> <p class="mt-12 mb-3 text-base font-semibold text-gray-800">附近的网点</p>
<branch <branch
v-for="(item, index) in result.lists" v-for="(item, index) in result.lists"
:key="index" :key="index"
......
...@@ -64,6 +64,7 @@ module.exports = { ...@@ -64,6 +64,7 @@ module.exports = {
"app-btn-disabled": "#E7E7E7", "app-btn-disabled": "#E7E7E7",
"app-branch-deep-blue": "#2C3C92", "app-branch-deep-blue": "#2C3C92",
"branch-tab-bg":"#F9FBFF", "branch-tab-bg":"#F9FBFF",
"product-detail-bg":"#EAF0FF",
black: colors.black, black: colors.black,
white: colors.white, white: colors.white,
gray: colors.coolGray, gray: colors.coolGray,
......
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