Compare commits
58 Commits
30369077af
..
x-4
| Author | SHA1 | Date | |
|---|---|---|---|
| 1e1011b317 | |||
| d460f35007 | |||
| 79b6ce1136 | |||
| 23d94407c2 | |||
| 05a8cb58d7 | |||
| 778d318c7e | |||
| 8b6922cfbe | |||
| ff3640b062 | |||
| e5508fe898 | |||
| 9354840543 | |||
| 19a8d3c20a | |||
| 51e34e4a42 | |||
| dabaa18dfd | |||
| 6e330c698e | |||
| 6114c6442c | |||
| 3e5fc69c35 | |||
| 5c864a8c63 | |||
| 659dc92c90 | |||
| cf1900c5ed | |||
| cf54b39ad1 | |||
| 7159a3148f | |||
| 0024d0f4e1 | |||
| bfeb64196d | |||
| c3ff2e3f4f | |||
| cac565506d | |||
| 25c045418d | |||
| 7d8eb755f1 | |||
| 4be8749cf5 | |||
| 59d47ec9f5 | |||
| fb7552192b | |||
| 859bea7d0e | |||
| 23afc0fb91 | |||
| af8e85c483 | |||
| 348d06eadb | |||
| 17eb27bfa6 | |||
| 5da0adfab2 | |||
| a2a3c09731 | |||
| 7ad24e1444 | |||
| 246c28e5d0 | |||
| 8f089b4bbd | |||
| a3eeed7273 | |||
| 2a620b5a0f | |||
| 1f28b06a5c | |||
| 79debee112 | |||
| 4ee9f70fcc | |||
| 5ba0155b0b | |||
| ffb887f3bf | |||
| e70ca852d8 | |||
| 21d8f75f6a | |||
| dbb57f07c3 | |||
| ae8ec19ba8 | |||
| 4fa9dc4a36 | |||
| 2d19bbce4c | |||
| 0889d068a8 | |||
| 5095c16564 | |||
| fecf6535a8 | |||
| ecd30a2e82 | |||
| f8abb65023 |
@@ -97,7 +97,7 @@
|
|||||||
"useId": true,
|
"useId": true,
|
||||||
"useModel": true,
|
"useModel": true,
|
||||||
"useTemplateRef": true,
|
"useTemplateRef": true,
|
||||||
"useCaptcha": true,
|
"useListPageRequest": true,
|
||||||
"useListPageRequest": true
|
"useCaptcha": true
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -33,12 +33,6 @@ module.exports = {
|
|||||||
ignorePseudoClasses: ['global', 'export', 'v-deep', 'deep'],
|
ignorePseudoClasses: ['global', 'export', 'v-deep', 'deep'],
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
'unit-no-unknown': [
|
|
||||||
true,
|
|
||||||
{
|
|
||||||
ignoreUnits: ['rpx'],
|
|
||||||
},
|
|
||||||
],
|
|
||||||
// 处理小程序page标签不认识的问题
|
// 处理小程序page标签不认识的问题
|
||||||
'selector-type-no-unknown': [
|
'selector-type-no-unknown': [
|
||||||
true,
|
true,
|
||||||
|
|||||||
@@ -40,10 +40,12 @@
|
|||||||
"commitlint",
|
"commitlint",
|
||||||
"dcloudio",
|
"dcloudio",
|
||||||
"iconfont",
|
"iconfont",
|
||||||
|
"Kefu",
|
||||||
"qrcode",
|
"qrcode",
|
||||||
"refresherrefresh",
|
"refresherrefresh",
|
||||||
"scrolltolower",
|
"scrolltolower",
|
||||||
"tabbar",
|
"tabbar",
|
||||||
|
"unibest",
|
||||||
"uvui",
|
"uvui",
|
||||||
"WechatMiniprogram"
|
"WechatMiniprogram"
|
||||||
],
|
],
|
||||||
@@ -58,5 +60,6 @@
|
|||||||
"CHANGELOG.md": "CHANGELOG*",
|
"CHANGELOG.md": "CHANGELOG*",
|
||||||
"package.json": "pnpm-lock.yaml,pnpm-workspace.yaml,LICENSE,.gitattributes,.gitignore,.gitpod.yml,CNAME,.npmrc,.browserslistrc",
|
"package.json": "pnpm-lock.yaml,pnpm-workspace.yaml,LICENSE,.gitattributes,.gitignore,.gitpod.yml,CNAME,.npmrc,.browserslistrc",
|
||||||
".eslintrc.cjs": ".eslintignore,.prettierignore,.stylelintignore,.commitlintrc.*,.prettierrc.*,.stylelintrc.*,.eslintrc-auto-import.json,.editorconfig,.commitlint.cjs"
|
".eslintrc.cjs": ".eslintignore,.prettierignore,.stylelintignore,.commitlintrc.*,.prettierrc.*,.stylelintrc.*,.eslintrc-auto-import.json,.editorconfig,.commitlint.cjs"
|
||||||
}
|
},
|
||||||
|
"i18n-ally.localesPaths": ["src/locale"]
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -5,5 +5,5 @@
|
|||||||
</p>
|
</p>
|
||||||
|
|
||||||
<h1 align="center">
|
<h1 align="center">
|
||||||
<a href="https://github.com/feige996/unibest" target="_blank">unibest - 最好的 uniapp 开发框架</a>
|
<a href="https://github.com/feige996/unibest" target="_blank">x-4</a>
|
||||||
</h1>
|
</h1>
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
VITE_APP_TITLE = 'unibest'
|
VITE_APP_TITLE = 'unibest'
|
||||||
VITE_APP_PORT = 9000
|
VITE_APP_PORT = 9001
|
||||||
|
|
||||||
VITE_UNI_APPID = 'H57F2ACE4'
|
VITE_UNI_APPID = 'H57F2ACE4'
|
||||||
VITE_WX_APPID = 'wxa2abb91f64032a2b'
|
VITE_WX_APPID = 'wxa2abb91f64032a2b'
|
||||||
@@ -7,9 +7,9 @@ VITE_WX_APPID = 'wxa2abb91f64032a2b'
|
|||||||
# h5部署网站的base,配置到 manifest.config.ts 里的 h5.router.base
|
# h5部署网站的base,配置到 manifest.config.ts 里的 h5.router.base
|
||||||
VITE_APP_PUBLIC_BASE=/
|
VITE_APP_PUBLIC_BASE=/
|
||||||
|
|
||||||
VITE_SERVER_BASEURL = 'http://api.divine913.com'
|
VITE_SERVER_BASEURL = 'https://api.qmbz.cc'
|
||||||
VITE_UPLOAD_BASEURL = 'http://api.divine913.com/api/v1/UploadFile'
|
VITE_UPLOAD_BASEURL = 'https://api.qmbz.cc/api/common/upload'
|
||||||
|
|
||||||
# h5是否需要配置代理
|
# h5是否需要配置代理
|
||||||
VITE_APP_PROXY=true
|
VITE_APP_PROXY=false
|
||||||
VITE_APP_PROXY_PREFIX = '/api'
|
VITE_APP_PROXY_PREFIX = '/api'
|
||||||
|
|||||||
@@ -14,7 +14,7 @@
|
|||||||
'" />',
|
'" />',
|
||||||
)
|
)
|
||||||
</script>
|
</script>
|
||||||
<title></title>
|
<title>unibest</title>
|
||||||
<!--preload-links-->
|
<!--preload-links-->
|
||||||
<!--app-context-->
|
<!--app-context-->
|
||||||
</head>
|
</head>
|
||||||
|
|||||||
@@ -1,23 +1,9 @@
|
|||||||
{
|
{
|
||||||
"name": "中国经济",
|
"name": "全民参保",
|
||||||
"type": "commonjs",
|
"type": "commonjs",
|
||||||
"version": "2.5.3",
|
"version": "2.5.3",
|
||||||
"description": "unibest - 最好的 uniapp 开发模板",
|
"description": "全民参保",
|
||||||
"author": {
|
|
||||||
"name": "feige996",
|
|
||||||
"zhName": "菲鸽",
|
|
||||||
"email": "1020103647@qq.com",
|
|
||||||
"github": "https://github.com/feige996",
|
|
||||||
"gitee": "https://gitee.com/feige996"
|
|
||||||
},
|
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"repository": "https://github.com/feige996/unibest",
|
|
||||||
"repository-gitee": "https://gitee.com/feige996/unibest",
|
|
||||||
"repository-deprecated": "https://github.com/codercup/unibest",
|
|
||||||
"bugs": {
|
|
||||||
"url": "https://github.com/feige996/unibest/issues"
|
|
||||||
},
|
|
||||||
"homepage": "https://feige996.github.io/unibest/",
|
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": ">=18",
|
"node": ">=18",
|
||||||
"pnpm": ">=7.30"
|
"pnpm": ">=7.30"
|
||||||
@@ -108,6 +94,7 @@
|
|||||||
"pinia-plugin-persistedstate": "3.2.1",
|
"pinia-plugin-persistedstate": "3.2.1",
|
||||||
"qs": "6.5.3",
|
"qs": "6.5.3",
|
||||||
"vue": "3.4.21",
|
"vue": "3.4.21",
|
||||||
|
"vue-i18n": "9.1.9",
|
||||||
"wot-design-uni": "^1.4.0",
|
"wot-design-uni": "^1.4.0",
|
||||||
"z-paging": "^2.8.4"
|
"z-paging": "^2.8.4"
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -36,13 +36,13 @@ export default defineUniPages({
|
|||||||
iconPath: 'static/tabbar/invest.png',
|
iconPath: 'static/tabbar/invest.png',
|
||||||
selectedIconPath: 'static/tabbar/investHL.png',
|
selectedIconPath: 'static/tabbar/investHL.png',
|
||||||
pagePath: 'pages/invest/index',
|
pagePath: 'pages/invest/index',
|
||||||
text: '投资',
|
text: '保障',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
iconPath: 'static/tabbar/house.png',
|
iconPath: 'static/tabbar/house.png',
|
||||||
selectedIconPath: 'static/tabbar/houseHL.png',
|
selectedIconPath: 'static/tabbar/houseHL.png',
|
||||||
pagePath: 'pages/house/index',
|
pagePath: 'pages/invite/index',
|
||||||
text: '房屋',
|
text: '社区',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
iconPath: 'static/tabbar/personal.png',
|
iconPath: 'static/tabbar/personal.png',
|
||||||
|
|||||||
@@ -77,6 +77,9 @@ importers:
|
|||||||
vue:
|
vue:
|
||||||
specifier: 3.4.21
|
specifier: 3.4.21
|
||||||
version: 3.4.21(typescript@5.7.2)
|
version: 3.4.21(typescript@5.7.2)
|
||||||
|
vue-i18n:
|
||||||
|
specifier: 9.1.9
|
||||||
|
version: 9.1.9(vue@3.4.21(typescript@5.7.2))
|
||||||
wot-design-uni:
|
wot-design-uni:
|
||||||
specifier: ^1.4.0
|
specifier: ^1.4.0
|
||||||
version: 1.4.0(vue@3.4.21(typescript@5.7.2))
|
version: 1.4.0(vue@3.4.21(typescript@5.7.2))
|
||||||
@@ -5426,6 +5429,12 @@ packages:
|
|||||||
peerDependencies:
|
peerDependencies:
|
||||||
eslint: '>=6.0.0'
|
eslint: '>=6.0.0'
|
||||||
|
|
||||||
|
vue-i18n@9.1.9:
|
||||||
|
resolution: {integrity: sha512-JeRdNVxS2OGp1E+pye5XB6+M6BBkHwAv9C80Q7+kzoMdUDGRna06tjC0vCB/jDX9aWrl5swxOMFcyAr7or8XTA==}
|
||||||
|
engines: {node: '>= 10'}
|
||||||
|
peerDependencies:
|
||||||
|
vue: ^3.0.0
|
||||||
|
|
||||||
vue-router@4.5.0:
|
vue-router@4.5.0:
|
||||||
resolution: {integrity: sha512-HDuk+PuH5monfNuY+ct49mNmkCRK4xJAV9Ts4z9UFc4rzdDnxQLyCMGGc8pKhZhHTVzfanpNwB/lwqevcBwI4w==}
|
resolution: {integrity: sha512-HDuk+PuH5monfNuY+ct49mNmkCRK4xJAV9Ts4z9UFc4rzdDnxQLyCMGGc8pKhZhHTVzfanpNwB/lwqevcBwI4w==}
|
||||||
peerDependencies:
|
peerDependencies:
|
||||||
@@ -12238,6 +12247,14 @@ snapshots:
|
|||||||
transitivePeerDependencies:
|
transitivePeerDependencies:
|
||||||
- supports-color
|
- supports-color
|
||||||
|
|
||||||
|
vue-i18n@9.1.9(vue@3.4.21(typescript@5.7.2)):
|
||||||
|
dependencies:
|
||||||
|
'@intlify/core-base': 9.1.9
|
||||||
|
'@intlify/shared': 9.1.9
|
||||||
|
'@intlify/vue-devtools': 9.1.9
|
||||||
|
'@vue/devtools-api': 6.6.4
|
||||||
|
vue: 3.4.21(typescript@5.7.2)
|
||||||
|
|
||||||
vue-router@4.5.0(vue@3.4.21(typescript@5.7.2)):
|
vue-router@4.5.0(vue@3.4.21(typescript@5.7.2)):
|
||||||
dependencies:
|
dependencies:
|
||||||
'@vue/devtools-api': 6.6.4
|
'@vue/devtools-api': 6.6.4
|
||||||
|
|||||||
@@ -19,7 +19,7 @@ const dependencies = [
|
|||||||
'@dcloudio/uni-mp-xhs',
|
'@dcloudio/uni-mp-xhs',
|
||||||
'@dcloudio/uni-quickapp-webview',
|
'@dcloudio/uni-quickapp-webview',
|
||||||
// i18n模板要注释掉下面的
|
// i18n模板要注释掉下面的
|
||||||
'vue-i18n',
|
// 'vue-i18n',
|
||||||
]
|
]
|
||||||
|
|
||||||
// 使用exec执行命令
|
// 使用exec执行命令
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { onLaunch, onShow, onHide } from '@dcloudio/uni-app'
|
import { onLaunch, onHide } from '@dcloudio/uni-app'
|
||||||
import { useUserStore } from './store'
|
import { useUserStore } from './store'
|
||||||
import { checkWithRedirectLogin, loginRoute } from './interceptors/route'
|
import { checkWithRedirectLogin, loginRoute } from './interceptors/route'
|
||||||
|
|
||||||
@@ -12,8 +12,10 @@ onLaunch((options) => {
|
|||||||
// },
|
// },
|
||||||
})
|
})
|
||||||
} else {
|
} else {
|
||||||
|
if (userStore.isLogged) {
|
||||||
userStore.loadUserInfo()
|
userStore.loadUserInfo()
|
||||||
}
|
}
|
||||||
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
onPageNotFound(() => {
|
onPageNotFound(() => {
|
||||||
@@ -34,7 +36,7 @@ const userStore = useUserStore()
|
|||||||
/* 覆盖 uniapp 自带rpx效果 */
|
/* 覆盖 uniapp 自带rpx效果 */
|
||||||
html {
|
html {
|
||||||
font-family: 'PingFang SC', 'Helvetica Neue', Helvetica, Arial, sans-serif;
|
font-family: 'PingFang SC', 'Helvetica Neue', Helvetica, Arial, sans-serif;
|
||||||
font-size: 16px !important;
|
// font-size: 16px !important;
|
||||||
}
|
}
|
||||||
/* stylelint-disable-next-line selector-type-no-unknown */
|
/* stylelint-disable-next-line selector-type-no-unknown */
|
||||||
#app {
|
#app {
|
||||||
@@ -129,4 +131,7 @@ uni-modal {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
::-webkit-scrollbar {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
@@ -20,9 +20,10 @@ defineProps({
|
|||||||
block
|
block
|
||||||
overflow-hidden
|
overflow-hidden
|
||||||
rounded-full
|
rounded-full
|
||||||
style="background: linear-gradient(180deg, #96e517 0%, #8bc135 100%)"
|
bg-gray-100
|
||||||
class="h-full w-full"
|
class="h-full w-full"
|
||||||
:src="src ?? DefaultAavatar"
|
mode="aspectFill"
|
||||||
|
:src="src ? src : DefaultAavatar"
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|||||||
@@ -0,0 +1,222 @@
|
|||||||
|
<template>
|
||||||
|
<view
|
||||||
|
class="grid-lottery"
|
||||||
|
:style="{
|
||||||
|
height: gridLotteryHeight,
|
||||||
|
}"
|
||||||
|
>
|
||||||
|
<view class="lottery-list">
|
||||||
|
<view
|
||||||
|
v-for="(item, index) in formateList"
|
||||||
|
:key="item.id"
|
||||||
|
class="lottery-item"
|
||||||
|
:style="{
|
||||||
|
width: `${itemWidth}%`,
|
||||||
|
height: `${itemHeight}${itemHeightUnit}`,
|
||||||
|
transform: `translate(${place(index).x}%, ${place(index).y}${itemHeightUnit})`,
|
||||||
|
}"
|
||||||
|
>
|
||||||
|
<view class="relative">
|
||||||
|
<slot name="lottery-item" :data="item" :index="index" :currIndex="currIndex" />
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view
|
||||||
|
class="start-button"
|
||||||
|
:style="{
|
||||||
|
left: `${itemWidth}%`,
|
||||||
|
right: `${itemWidth}%`,
|
||||||
|
top: `${itemWidth}%`,
|
||||||
|
bottom: `${itemWidth}%`,
|
||||||
|
}"
|
||||||
|
@tap="onStart"
|
||||||
|
>
|
||||||
|
<slot name="start-button"></slot>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
export default {
|
||||||
|
name: 'GridLottery',
|
||||||
|
props: {
|
||||||
|
// 转盘转动间隔
|
||||||
|
interval: {
|
||||||
|
type: Number,
|
||||||
|
default: 50,
|
||||||
|
},
|
||||||
|
// 是否逐渐减速
|
||||||
|
isIntervalIncrease: {
|
||||||
|
type: Boolean,
|
||||||
|
default: true,
|
||||||
|
},
|
||||||
|
// 减速开始时间
|
||||||
|
intervalIncreaseStartTime: {
|
||||||
|
type: Number,
|
||||||
|
default: 3000,
|
||||||
|
},
|
||||||
|
// 最小速度
|
||||||
|
maxInterval: {
|
||||||
|
type: Number,
|
||||||
|
default: 500,
|
||||||
|
},
|
||||||
|
// 奖项外框高度
|
||||||
|
itemHeight: {
|
||||||
|
type: Number,
|
||||||
|
default: 100,
|
||||||
|
},
|
||||||
|
// 高度单位
|
||||||
|
itemHeightUnit: {
|
||||||
|
type: String,
|
||||||
|
default: 'rpx',
|
||||||
|
},
|
||||||
|
// 总数必须为>=8 且被4整除
|
||||||
|
list: {
|
||||||
|
type: Array,
|
||||||
|
default() {
|
||||||
|
// return [
|
||||||
|
// {
|
||||||
|
// id: string,
|
||||||
|
// sort: number
|
||||||
|
// }
|
||||||
|
// ];
|
||||||
|
return []
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
transform: {
|
||||||
|
x: 0,
|
||||||
|
y: 0,
|
||||||
|
},
|
||||||
|
currIndex: 0,
|
||||||
|
startFlag: false,
|
||||||
|
}
|
||||||
|
},
|
||||||
|
computed: {
|
||||||
|
gridLotteryHeight({ itemHeight, formateList, colunmCount, itemHeightUnit }) {
|
||||||
|
return `${itemHeight * ((formateList.length - colunmCount * 2) / 2 + 2)}${itemHeightUnit}`
|
||||||
|
},
|
||||||
|
itemWidth() {
|
||||||
|
return 100 / this.colunmCount
|
||||||
|
},
|
||||||
|
colunmCount() {
|
||||||
|
const len = this.list.length
|
||||||
|
if (len > 8) {
|
||||||
|
return 3 + Math.floor((len - 8) / 4)
|
||||||
|
}
|
||||||
|
return 3
|
||||||
|
},
|
||||||
|
|
||||||
|
formateList() {
|
||||||
|
const len = this.list.length
|
||||||
|
if (len > 7 && (len - 8) % 4 !== 0) {
|
||||||
|
console.warn(
|
||||||
|
'请检查数组,总数必须为>=8 且大余8部分部分能被4整除,如长度为8、12、16...的数组',
|
||||||
|
)
|
||||||
|
}
|
||||||
|
const _list = this.list || []
|
||||||
|
const formateList = _list.sort((a, b) => a.sort - b.sort)
|
||||||
|
return formateList
|
||||||
|
},
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
// 通过索引获取定位
|
||||||
|
place(index) {
|
||||||
|
const len = this.list.length
|
||||||
|
// 序号
|
||||||
|
const indexToOrder = index + 1
|
||||||
|
if (indexToOrder > this.colunmCount) {
|
||||||
|
// 去除上下行,总行数
|
||||||
|
const rowCount = (len - this.colunmCount * 2) / 2
|
||||||
|
// 非处于左侧
|
||||||
|
if (index > this.colunmCount + rowCount) {
|
||||||
|
// 处于右侧
|
||||||
|
if (indexToOrder > this.colunmCount * 2 + rowCount) {
|
||||||
|
return {
|
||||||
|
x: 0,
|
||||||
|
y: this.itemHeight * (rowCount * 2 + this.colunmCount * 2 - index),
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// 处于底部
|
||||||
|
return {
|
||||||
|
x: 100 * (this.colunmCount * 2 + rowCount - indexToOrder),
|
||||||
|
y: this.itemHeight * (rowCount + 1),
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// 处于右侧
|
||||||
|
return {
|
||||||
|
x: 100 * (this.colunmCount - 1),
|
||||||
|
y: this.itemHeight * (indexToOrder - this.colunmCount),
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// 处于顶部
|
||||||
|
return {
|
||||||
|
x: 100 * index,
|
||||||
|
y: 0,
|
||||||
|
}
|
||||||
|
},
|
||||||
|
/**
|
||||||
|
* 开始抽奖
|
||||||
|
* @param {string|number} id 获奖id
|
||||||
|
* @param {number} minTime 转盘最小持续时间
|
||||||
|
*/
|
||||||
|
async start(id, minTime) {
|
||||||
|
if (this.startFlag) return
|
||||||
|
const len = this.formateList.length
|
||||||
|
const activeIndex = this.formateList.findIndex((item) => item.id === id)
|
||||||
|
if (activeIndex === -1) {
|
||||||
|
const errorText = `没有找到该中奖id ${id}`
|
||||||
|
console.error(errorText)
|
||||||
|
return this.$emit('onError', errorText)
|
||||||
|
}
|
||||||
|
let time = minTime
|
||||||
|
// 动画速度
|
||||||
|
let interval = this.interval
|
||||||
|
const startRotate = () => {
|
||||||
|
this.startFlag = true
|
||||||
|
clearTimeout(this.timer)
|
||||||
|
this.timer = setTimeout(() => {
|
||||||
|
// 抽奖结束
|
||||||
|
if (time < 1 && this.currIndex === activeIndex) {
|
||||||
|
this.startFlag = false
|
||||||
|
clearTimeout(this.timer)
|
||||||
|
return this.$emit('onEnd', this.formateList[activeIndex])
|
||||||
|
}
|
||||||
|
time -= interval
|
||||||
|
if (time < 3000 && this.isIntervalIncrease) {
|
||||||
|
// 调整动画速度
|
||||||
|
interval = interval >= this.maxInterval ? this.maxInterval : interval + 20
|
||||||
|
}
|
||||||
|
this.currIndex = this.currIndex >= len - 1 ? 0 : this.currIndex + 1
|
||||||
|
this.transform = this.place(this.currIndex)
|
||||||
|
return startRotate()
|
||||||
|
}, interval)
|
||||||
|
}
|
||||||
|
startRotate()
|
||||||
|
},
|
||||||
|
onStart() {
|
||||||
|
this.$emit('onStart')
|
||||||
|
},
|
||||||
|
},
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style lang="scss" scoped>
|
||||||
|
.grid-lottery {
|
||||||
|
position: relative;
|
||||||
|
.start-button {
|
||||||
|
position: absolute;
|
||||||
|
}
|
||||||
|
.lottery-list {
|
||||||
|
display: flex;
|
||||||
|
flex-wrap: wrap;
|
||||||
|
.lottery-item {
|
||||||
|
position: absolute;
|
||||||
|
top: 0;
|
||||||
|
left: 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</style>
|
||||||
@@ -15,16 +15,27 @@
|
|||||||
|
|
||||||
<script lang="ts" setup>
|
<script lang="ts" setup>
|
||||||
import { getLastPage } from '@/utils'
|
import { getLastPage } from '@/utils'
|
||||||
const title = getLastPage().$page.meta.navigationBar.titleText
|
const props = defineProps({
|
||||||
|
titleColor: {
|
||||||
|
type: String,
|
||||||
|
default: '#fff',
|
||||||
|
},
|
||||||
|
title: {
|
||||||
|
type: String,
|
||||||
|
default: '',
|
||||||
|
},
|
||||||
|
})
|
||||||
|
const title = computed(() => {
|
||||||
|
return props.title || getLastPage().$page.meta.navigationBar.titleText
|
||||||
|
})
|
||||||
const showBack = getCurrentPages().length > 1
|
const showBack = getCurrentPages().length > 1
|
||||||
const handleClickLeft = () => {
|
const handleClickLeft = () => {
|
||||||
uni.navigateBack()
|
uni.navigateBack()
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="scss">
|
<style lang="scss" scoped>
|
||||||
:deep(.wd-navbar) {
|
:deep(.wd-navbar) {
|
||||||
--wot-navbar-title-font-size: 32rpx;
|
--wot-navbar-color: v-bind('titleColor');
|
||||||
// --wot-navbar-title-font-weight: 400;
|
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
@@ -1,11 +1,15 @@
|
|||||||
|
const baseUrl = import.meta.env.VITE_SERVER_BASEURL
|
||||||
export const useCaptcha = () => {
|
export const useCaptcha = () => {
|
||||||
const codeUrl = ref('')
|
const t = ref(Date.now())
|
||||||
|
|
||||||
|
const codeUrl = computed(() => {
|
||||||
|
return baseUrl + '/api/index/captcha?t=' + t.value
|
||||||
|
})
|
||||||
const refreshCode = () => {
|
const refreshCode = () => {
|
||||||
const baseUrl = import.meta.env.VITE_SERVER_BASEURL
|
t.value = Date.now()
|
||||||
codeUrl.value = baseUrl + '/api/v1/getCaptcha?t=' + Date.now()
|
|
||||||
}
|
}
|
||||||
onMounted(() => {
|
onMounted(() => {
|
||||||
refreshCode()
|
refreshCode()
|
||||||
})
|
})
|
||||||
return { codeUrl, refreshCode }
|
return { codeUrl, t, refreshCode }
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,9 +1,10 @@
|
|||||||
|
import { formatTime, getImageUrl } from '@/utils'
|
||||||
import { onPullDownRefresh, onReachBottom } from '@dcloudio/uni-app'
|
import { onPullDownRefresh, onReachBottom } from '@dcloudio/uni-app'
|
||||||
import { computed, onMounted, ref } from 'vue'
|
import { computed, onMounted, ref } from 'vue'
|
||||||
|
|
||||||
interface PaginationRequest {
|
interface PaginationRequest {
|
||||||
pageIndex?: number
|
page?: number
|
||||||
pageSize?: number
|
limit?: number
|
||||||
[key: string]: any
|
[key: string]: any
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -22,10 +23,10 @@ function useListPageRequest(
|
|||||||
const moreLoading = ref(false)
|
const moreLoading = ref(false)
|
||||||
// 全部数据加载完成
|
// 全部数据加载完成
|
||||||
const totalPage = ref(0)
|
const totalPage = ref(0)
|
||||||
const finished = computed(() => totalPage.value <= pagingParams.value.pageIndex)
|
const finished = computed(() => totalPage.value <= pagingParams.value.page)
|
||||||
const pagingParams = ref<PaginationRequest>({
|
const pagingParams = ref<PaginationRequest>({
|
||||||
pageIndex: 1,
|
page: 1,
|
||||||
pageSize: 10,
|
limit: 1000,
|
||||||
})
|
})
|
||||||
const getPagingParams = computed(() => {
|
const getPagingParams = computed(() => {
|
||||||
return {
|
return {
|
||||||
@@ -49,13 +50,28 @@ function useListPageRequest(
|
|||||||
...getPagingParams.value,
|
...getPagingParams.value,
|
||||||
...customParams,
|
...customParams,
|
||||||
})
|
})
|
||||||
totalPage.value = data.count ? Math.ceil(data.count / pagingParams.value.pageSize!) : 0
|
data.forEach((item: any) => {
|
||||||
list.value.push(...data.list)
|
if (String(item.createtime).length < 11) {
|
||||||
|
item.createtime = item.createtime * 1000
|
||||||
|
}
|
||||||
|
item.createtime = formatTime(item.createtime)
|
||||||
|
item.image = getImageUrl(item.image)
|
||||||
|
})
|
||||||
|
// totalPage.value = data.count ? Math.ceil(data.count / pagingParams.value.limit!) : 0
|
||||||
|
// 如果当前是第一页,则清空列表,否则追加数据
|
||||||
|
if (getPagingParams.value.page === 1) {
|
||||||
|
list.value = []
|
||||||
|
}
|
||||||
|
list.value.push(...data)
|
||||||
}
|
}
|
||||||
|
|
||||||
const onReload = async (params?: AnyObject) => {
|
const onReload = async (params?: AnyObject) => {
|
||||||
|
// 如果当前是第一页,则清空列表
|
||||||
|
if (getPagingParams.value.page === 1) {
|
||||||
|
list.value = []
|
||||||
|
}
|
||||||
loading.value = true
|
loading.value = true
|
||||||
pagingParams.value.pageIndex = 1
|
pagingParams.value.page = 1
|
||||||
if (params) {
|
if (params) {
|
||||||
customParams = params
|
customParams = params
|
||||||
}
|
}
|
||||||
@@ -69,7 +85,7 @@ function useListPageRequest(
|
|||||||
if (finished.value) {
|
if (finished.value) {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
pagingParams.value.pageIndex = pagingParams.value.pageIndex! + 1
|
pagingParams.value.page = pagingParams.value.page! + 1
|
||||||
moreLoading.value = true
|
moreLoading.value = true
|
||||||
try {
|
try {
|
||||||
await loadData()
|
await loadData()
|
||||||
|
|||||||
@@ -17,7 +17,7 @@ type IUseRequestOptions<T> = {
|
|||||||
*/
|
*/
|
||||||
export default function useRequest<T>(
|
export default function useRequest<T>(
|
||||||
func: () => Promise<IResData<T>>,
|
func: () => Promise<IResData<T>>,
|
||||||
options: IUseRequestOptions<T> = { immediate: true },
|
options: IUseRequestOptions<T> = { immediate: false },
|
||||||
) {
|
) {
|
||||||
const loading = ref(false)
|
const loading = ref(false)
|
||||||
const error = ref(false)
|
const error = ref(false)
|
||||||
|
|||||||
@@ -56,7 +56,12 @@ function uploadFile<T>({ tempFilePath, formData, data, error, loading }) {
|
|||||||
name: 'file',
|
name: 'file',
|
||||||
formData,
|
formData,
|
||||||
success: (uploadFileRes) => {
|
success: (uploadFileRes) => {
|
||||||
|
try {
|
||||||
|
data.value = JSON.parse(uploadFileRes.data).data.fullurl as T
|
||||||
|
} catch (e) {
|
||||||
|
console.log(e)
|
||||||
data.value = uploadFileRes.data as T
|
data.value = uploadFileRes.data as T
|
||||||
|
}
|
||||||
},
|
},
|
||||||
fail: (err) => {
|
fail: (err) => {
|
||||||
console.error('uni.uploadFile err->', err)
|
console.error('uni.uploadFile err->', err)
|
||||||
|
|||||||
@@ -1,3 +1,3 @@
|
|||||||
export { routerBeforeEachConfig } from './route'
|
export { routeInterceptor, routerBeforeEachConfig } from './route'
|
||||||
export { requestInterceptor } from './request'
|
export { requestInterceptor } from './request'
|
||||||
export { prototypeInterceptor } from './prototype'
|
export { prototypeInterceptor } from './prototype'
|
||||||
|
|||||||
@@ -51,9 +51,8 @@ const httpInterceptor = {
|
|||||||
}
|
}
|
||||||
// 3. 添加 token 请求头标识
|
// 3. 添加 token 请求头标识
|
||||||
const userStore = useUserStore()
|
const userStore = useUserStore()
|
||||||
const token = userStore.token
|
if (userStore.token) {
|
||||||
if (token) {
|
options.header.token = userStore.token
|
||||||
options.header.Authorization = token
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
* 可以设置路由白名单,或者黑名单,看业务需要选哪一个
|
* 可以设置路由白名单,或者黑名单,看业务需要选哪一个
|
||||||
* 我这里应为大部分都可以随便进入,所以使用黑名单
|
* 我这里应为大部分都可以随便进入,所以使用黑名单
|
||||||
*/
|
*/
|
||||||
import { getUserInfoAPI } from '@/service'
|
import { getRealNameAuthAPI, getUserInfoAPI } from '@/service'
|
||||||
import { useUserStore } from '@/store'
|
import { useUserStore } from '@/store'
|
||||||
import {
|
import {
|
||||||
getNotNeedLoginPages as _getNotNeedLoginPages,
|
getNotNeedLoginPages as _getNotNeedLoginPages,
|
||||||
|
|||||||
@@ -0,0 +1,12 @@
|
|||||||
|
# 注意事项
|
||||||
|
|
||||||
|
> 文件夹名字必须为 `locale`, 这是 `uniapp` 官方约定的,如果改为别的,标题将不能正常切换多语言(其他内容还是正常)。
|
||||||
|
>
|
||||||
|
> `xxx.json` 的 `xxx` 多语言标识必须与 `uniapp` 官方约定的一致,否则也会出现 BUG。
|
||||||
|
>
|
||||||
|
> 查看截图 `screenshots/i18n.png`。
|
||||||
|
|
||||||
|
## 参考文档
|
||||||
|
|
||||||
|
[uniapp 国际化开发指南](https://uniapp.dcloud.net.cn/tutorial/i18n.html)
|
||||||
|
[uniapp 国际化-注意事项](https://uniapp.dcloud.net.cn/api/ui/locale.html#onlocalechange) 最下面的注意事项
|
||||||
@@ -0,0 +1,8 @@
|
|||||||
|
{
|
||||||
|
"tabbar.home": "Home",
|
||||||
|
"tabbar.about": "About",
|
||||||
|
"app.name": "En Title",
|
||||||
|
"weight": "{heavy}KG",
|
||||||
|
"detail": "{0}cm, {1}KG",
|
||||||
|
"introduction": "I am {name},height:{detail.height},weight:{detail.weight}"
|
||||||
|
}
|
||||||
@@ -0,0 +1,80 @@
|
|||||||
|
import { createI18n } from 'vue-i18n'
|
||||||
|
|
||||||
|
import en from './en.json'
|
||||||
|
import zhHans from './zh-Hans.json' // 简体中文
|
||||||
|
|
||||||
|
const messages = {
|
||||||
|
en,
|
||||||
|
'zh-Hans': zhHans, // key 不能乱写,查看截图 screenshots/i18n.png
|
||||||
|
}
|
||||||
|
|
||||||
|
const i18n = createI18n({
|
||||||
|
locale: uni.getLocale(), // 获取已设置的语言,fallback 语言需要再 manifest.config.ts 中设置
|
||||||
|
messages,
|
||||||
|
allowComposition: true,
|
||||||
|
})
|
||||||
|
|
||||||
|
console.log(uni.getLocale())
|
||||||
|
console.log(i18n.global.locale)
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 可以拿到原始的语言模板,非 vue 文件使用这个方法,
|
||||||
|
* @param { string } key 多语言的key,eg: "app.name"
|
||||||
|
* @returns {string} 返回原始的多语言模板,eg: "{heavy}KG"
|
||||||
|
*/
|
||||||
|
export const getTemplateByKey = (key: string) => {
|
||||||
|
if (!key) {
|
||||||
|
console.error(`[i18n] Function getTemplateByKey(), key param is required`)
|
||||||
|
return ''
|
||||||
|
}
|
||||||
|
const locale = uni.getLocale()
|
||||||
|
console.log('locale:', locale)
|
||||||
|
|
||||||
|
const message = messages[locale] // 拿到某个多语言的所有模板(是一个对象)
|
||||||
|
if (Object.keys(message).includes(key)) {
|
||||||
|
return message[key]
|
||||||
|
}
|
||||||
|
|
||||||
|
try {
|
||||||
|
const keyList = key.split('.')
|
||||||
|
return keyList.reduce((pre, cur) => {
|
||||||
|
return pre[cur]
|
||||||
|
}, message)
|
||||||
|
} catch (error) {
|
||||||
|
console.error(`[i18n] Function getTemplateByKey(), key param ${key} is not existed.`)
|
||||||
|
return ''
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* formatI18n('我是{name},身高{detail.height},体重{detail.weight}',{name:'张三',detail:{height:178,weight:'75kg'}})
|
||||||
|
* 暂不支持数组
|
||||||
|
* @param template 多语言模板字符串,eg: `我是{name}`
|
||||||
|
* @param {Object|undefined} data 需要传递的数据对象,里面的key与多语言字符串对应,eg: `{name:'菲鸽'}`
|
||||||
|
* @returns
|
||||||
|
*/
|
||||||
|
function formatI18n(template: string, data?: any) {
|
||||||
|
return template.replace(/\{([^}]+)\}/g, function (match, key: string) {
|
||||||
|
// console.log( match, key) // => { detail.height } detail.height
|
||||||
|
const arr = key.trim().split('.')
|
||||||
|
let result = data
|
||||||
|
while (arr.length) {
|
||||||
|
const first = arr.shift()
|
||||||
|
result = result[first]
|
||||||
|
}
|
||||||
|
return result
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* t('introduction',{name:'张三',detail:{height:178,weight:'75kg'}})
|
||||||
|
* => formatI18n('我是{name},身高{detail.height},体重{detail.weight}',{name:'张三',detail:{height:178,weight:'75kg'}})
|
||||||
|
* 没有key的,可以不传 data;暂不支持数组
|
||||||
|
* @param template 多语言模板字符串,eg: `我是{name}`
|
||||||
|
* @param {Object|undefined} data 需要传递的数据对象,里面的key与多语言字符串对应,eg: `{name:'菲鸽'}`
|
||||||
|
* @returns
|
||||||
|
*/
|
||||||
|
export function t(key, data?) {
|
||||||
|
return formatI18n(getTemplateByKey(key), data)
|
||||||
|
}
|
||||||
|
export default i18n
|
||||||
@@ -0,0 +1,8 @@
|
|||||||
|
{
|
||||||
|
"tabbar.home": "首页",
|
||||||
|
"tabbar.about": "关于",
|
||||||
|
"app.name": "中文标题",
|
||||||
|
"weight": "{heavy}公斤",
|
||||||
|
"detail": "{0}cm, {1}公斤",
|
||||||
|
"introduction": "我是 {name},身高:{detail.height},体重:{detail.weight}"
|
||||||
|
}
|
||||||
@@ -0,0 +1,79 @@
|
|||||||
|
<route lang="json5">
|
||||||
|
{
|
||||||
|
style: {
|
||||||
|
navigationBarTitleText: '资金明细',
|
||||||
|
navigationBarBackgroundColor: '#fff',
|
||||||
|
navigationStyle: 'custom',
|
||||||
|
},
|
||||||
|
}
|
||||||
|
</route>
|
||||||
|
|
||||||
|
<script lang="ts" setup>
|
||||||
|
import NavBar from '@/components/NavBar.vue'
|
||||||
|
import { getMyAssetAPI } from '@/service'
|
||||||
|
import { useUserStore } from '@/store'
|
||||||
|
|
||||||
|
const { list: assetList } = useListPageRequest(getMyAssetAPI)
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<template>
|
||||||
|
<view class="asset-page pt-15 relative">
|
||||||
|
<NavBar />
|
||||||
|
<!-- <view class="flex justify-around">
|
||||||
|
<view
|
||||||
|
v-for="(tabItem, index) in tabList"
|
||||||
|
@click="tabIndex = index"
|
||||||
|
:key="tabItem.value"
|
||||||
|
class="flex items-center bg-#DEEBFF text-#3B81F3 rounded-full justify-center py-4 px-10"
|
||||||
|
:class="{ 'btn-gradient text-white': tabIndex === index }"
|
||||||
|
>
|
||||||
|
<view class="text-14">{{ tabItem.label }}</view>
|
||||||
|
</view>
|
||||||
|
</view> -->
|
||||||
|
<view class="relative z-1 mt-10 main-content pt-30 pb-30 rounded-t-15">
|
||||||
|
<view class="mb-15 px-25">资金明细</view>
|
||||||
|
<template v-if="assetList.length">
|
||||||
|
<view
|
||||||
|
class="flex px-25 py-12 border-b items-center border-#3333331A border-b-solid"
|
||||||
|
v-for="item in assetList"
|
||||||
|
:key="item.id"
|
||||||
|
>
|
||||||
|
<image src="/static/images/page-sub/invite-icon.png" class="w-48 h-48" />
|
||||||
|
<view class="flex flex-col flex-1 ml-15">
|
||||||
|
<view class="text-14 text-#333">{{ item.memo }}</view>
|
||||||
|
<view class="text-12 mt-4 text-#333">{{ item.createtime }}</view>
|
||||||
|
</view>
|
||||||
|
|
||||||
|
<view class="flex flex-col items-end">
|
||||||
|
<view class="text-17 font-bold text-gradient">{{ item.money }}</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
<template v-else>
|
||||||
|
<wd-status-tip image="content" tip="暂无数据" />
|
||||||
|
</template>
|
||||||
|
</view>
|
||||||
|
<!-- <view class="mx-15 text-16 font-bold text-#333">我的资产</view>
|
||||||
|
<view
|
||||||
|
class="mt-15 mx-15 rounded-20 text-#476FFF main-content p-15 rounded-10 shadow-[0_5px_30px_rgba(149,195,255,0.4)]"
|
||||||
|
>
|
||||||
|
<view class="text-14 text-#6784C7">总投资金</view>
|
||||||
|
<view class="text-35 mt-10 font-bold">{{ detailInfo.suminvest }}</view>
|
||||||
|
</view>
|
||||||
|
<view class="text-16 mx-15 mb-15 font-bold text-#333 mt-30">资产记录</view>
|
||||||
|
-->
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<style scoped>
|
||||||
|
.asset-page {
|
||||||
|
background-image: url('@/static/images/assets-bg.jpg');
|
||||||
|
background-repeat: no-repeat;
|
||||||
|
background-position: top center;
|
||||||
|
background-size: 100%;
|
||||||
|
}
|
||||||
|
.main-content {
|
||||||
|
background-color: #ffffff;
|
||||||
|
/* backdrop-filter: blur(60px); */
|
||||||
|
}
|
||||||
|
</style>
|
||||||
@@ -1,64 +1,110 @@
|
|||||||
<route lang="json5" type="page">
|
<route lang="json5">
|
||||||
{
|
{
|
||||||
style: {
|
style: {
|
||||||
navigationBarTitleText: '我的资产',
|
navigationBarTitleText: '资金明细',
|
||||||
navigationBarBackgroundColor: '#fff',
|
navigationBarBackgroundColor: '#fff',
|
||||||
|
navigationStyle: 'custom',
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
</route>
|
</route>
|
||||||
|
|
||||||
|
<script lang="ts" setup>
|
||||||
|
import NavBar from '@/components/NavBar.vue'
|
||||||
|
import { getMyAssetAPI } from '@/service'
|
||||||
|
import { useUserStore } from '@/store'
|
||||||
|
|
||||||
|
const userStore = useUserStore()
|
||||||
|
|
||||||
|
const tabList = computed(() => {
|
||||||
|
return [
|
||||||
|
{ label: '我的余额', value: 1, money: userStore.userInfo?.money },
|
||||||
|
{ label: '社保金余额', value: 2, money: userStore.userInfo?.moneyjiu },
|
||||||
|
{ label: '养老金余额', value: 3, money: userStore.userInfo?.moneyold },
|
||||||
|
{ label: '团队佣金余额', value: 4, money: userStore.userInfo?.moneyyong },
|
||||||
|
]
|
||||||
|
})
|
||||||
|
const tabIndex = ref(0)
|
||||||
|
|
||||||
|
const { list: assetList, onReload } = useListPageRequest(
|
||||||
|
(params) =>
|
||||||
|
getMyAssetAPI(params).then((res) => {
|
||||||
|
return res
|
||||||
|
}),
|
||||||
|
{
|
||||||
|
autoRequest: false,
|
||||||
|
},
|
||||||
|
)
|
||||||
|
|
||||||
|
onLoad((options) => {
|
||||||
|
tabIndex.value = Number(options.tabIndex ?? 0)
|
||||||
|
onReload({
|
||||||
|
flagdata: unref(tabList)[tabIndex.value].value,
|
||||||
|
})
|
||||||
|
})
|
||||||
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
<view class="min-h-screen py-15">
|
<view class="asset-page pt-15 relative">
|
||||||
<view class="mx-15 text-16 font-bold text-#333">我的资产</view>
|
<NavBar :title="tabList[tabIndex].label" />
|
||||||
|
<!-- <view class="flex justify-around">
|
||||||
<view
|
<view
|
||||||
class="mt-15 mx-15 text-white btn-gradient p-15 rounded-10 shadow-[0_5px_30px_rgba(55,230,236,0.4)]"
|
v-for="(tabItem, index) in tabList"
|
||||||
|
@click="tabIndex = index"
|
||||||
|
:key="tabItem.value"
|
||||||
|
class="flex items-center bg-#DEEBFF text-#3B81F3 rounded-full justify-center py-4 px-10"
|
||||||
|
:class="{ 'btn-gradient text-white': tabIndex === index }"
|
||||||
>
|
>
|
||||||
<view class="text-14">总投资金</view>
|
<view class="text-14">{{ tabItem.label }}</view>
|
||||||
<view class="text-35 mt-10 font-bold">{{ userStore.userInfo?.member_investment }}</view>
|
|
||||||
<view class="flex mt-15">
|
|
||||||
<view class="flex-1">
|
|
||||||
<view class="text-12 font-light">我的分红</view>
|
|
||||||
<view class="text-16 font-bold mt-5">{{ userStore.userInfo?.member_dividend }}</view>
|
|
||||||
</view>
|
</view>
|
||||||
<view class="flex-1">
|
</view> -->
|
||||||
<view class="text-12 font-light">数字人民币</view>
|
<view class="mt-30 p-15 text-white">
|
||||||
<view class="text-16 font-bold mt-5">{{ userStore.userInfo?.member_dividend }}</view>
|
<view class="text-17">{{ tabList[tabIndex].label }}</view>
|
||||||
|
<view class="text-30">¥{{ tabList[tabIndex].money }}</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="flex-1">
|
<view class="relative z-1 mt-10 main-content pt-30 pb-30 rounded-t-15">
|
||||||
<view class="text-12 font-light">认购点</view>
|
<view class="mb-15 px-25">【{{ tabList[tabIndex].label }}】明细</view>
|
||||||
<view class="text-16 font-bold mt-5">{{ userStore.userInfo?.member_point }}</view>
|
<template v-if="assetList.length">
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="text-16 mx-15 mb-15 font-bold text-#333 mt-30">资产记录</view>
|
|
||||||
<view
|
<view
|
||||||
class="flex px-15 py-8 border-b items-center border-#E5E5E5 border-b-solid"
|
class="flex px-25 py-12 border-b items-center border-#3333331A border-b-solid"
|
||||||
v-for="item in list"
|
v-for="item in assetList"
|
||||||
:key="item.id"
|
:key="item.id"
|
||||||
>
|
>
|
||||||
<image src="/static/images/page-sub/invite-icon.png" class="w-32 h-32 self-center" />
|
<image src="/static/images/page-sub/invite-icon.png" class="w-48 h-48" />
|
||||||
<view class="flex flex-col flex-1 ml-15">
|
<view class="flex flex-col flex-1 ml-15">
|
||||||
<view class="text-14 text-#333">{{ item.title }}</view>
|
<view class="text-14 text-#333">{{ item.memo }}</view>
|
||||||
<view class="text-12 mt-10 text-#999">奖励</view>
|
<view class="text-12 mt-4 text-#333">{{ item.createtime }}</view>
|
||||||
<view class="text-12 mt-10 text-#999">{{ item.create_time }}</view>
|
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view class="flex flex-col items-end">
|
<view class="flex flex-col items-end">
|
||||||
<view class="text-14 font-bold text-#FF5F5F">{{ item.money }}</view>
|
<view class="text-17 font-bold text-gradient">{{ item.money }}</view>
|
||||||
<!-- <view class="text-14 font-bold text-#FF5F5F">+2000 RMB</view> -->
|
|
||||||
<!-- <view class="text-14 font-bold text-#FF5F5F">+30 点</view> -->
|
|
||||||
<view class="text-14 mt-10 py-4 px-10 bg-#71C78A1A text-#71C78A" v-if="item.status === 1">
|
|
||||||
已到账
|
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
</template>
|
||||||
|
<template v-else>
|
||||||
|
<wd-status-tip image="content" tip="暂无数据" />
|
||||||
|
</template>
|
||||||
</view>
|
</view>
|
||||||
|
<!-- <view class="mx-15 text-16 font-bold text-#333">我的资产</view>
|
||||||
|
<view
|
||||||
|
class="mt-15 mx-15 rounded-20 text-#476FFF main-content p-15 rounded-10 shadow-[0_5px_30px_rgba(149,195,255,0.4)]"
|
||||||
|
>
|
||||||
|
<view class="text-14 text-#6784C7">总投资金</view>
|
||||||
|
<view class="text-35 mt-10 font-bold">{{ detailInfo.suminvest }}</view>
|
||||||
|
</view>
|
||||||
|
<view class="text-16 mx-15 mb-15 font-bold text-#333 mt-30">资产记录</view>
|
||||||
|
-->
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup lang="ts">
|
<style scoped>
|
||||||
import { getBalanceRecordsAPI } from '@/service'
|
.asset-page {
|
||||||
import { useUserStore } from '@/store'
|
background-image: url('@/static/images/assets-bg.jpg');
|
||||||
const userStore = useUserStore()
|
background-repeat: no-repeat;
|
||||||
|
background-position: top center;
|
||||||
const { list } = useListPageRequest(getBalanceRecordsAPI)
|
background-size: 100%;
|
||||||
</script>
|
}
|
||||||
|
.main-content {
|
||||||
|
background-color: #ffffff;
|
||||||
|
/* backdrop-filter: blur(60px); */
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
|||||||
@@ -0,0 +1,107 @@
|
|||||||
|
<route lang="json5">
|
||||||
|
{
|
||||||
|
style: {
|
||||||
|
navigationStyle: 'custom',
|
||||||
|
navigationBarTitleText: '转换',
|
||||||
|
},
|
||||||
|
}
|
||||||
|
</route>
|
||||||
|
<template>
|
||||||
|
<view class="min-h-screen pb-100">
|
||||||
|
<NavBar :title="title" title-color="#333">
|
||||||
|
<template #right>
|
||||||
|
<image
|
||||||
|
@click="onWithdrawalDetail"
|
||||||
|
src="/static/images/page-sub/recharge.png"
|
||||||
|
class="w-24 h-24"
|
||||||
|
/>
|
||||||
|
</template>
|
||||||
|
</NavBar>
|
||||||
|
<view
|
||||||
|
class="m-15 text-white flex rounded-tl-10 rounded-br-10 justify-between items-center p-15 bg-[linear-gradient(90deg,rgba(59,129,243,0.5),#3B81F3)]"
|
||||||
|
>
|
||||||
|
<view class="text-14">{{ type === 0 ? '养老金' : '团队佣金' }}余额</view>
|
||||||
|
<view class="text-17 font-bold">
|
||||||
|
{{ type === 0 ? userStore.userInfo?.moneyold : userStore.userInfo?.moneyyong }}
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view class="p-15 bg-white shadow-[0_-2px_3px_rgba(10,68,245,0.1)] rounded-10">
|
||||||
|
<view class="mt-15">
|
||||||
|
<view
|
||||||
|
class="flex items-center text-14 mt-15 text-#333 p-16 shadow-[0_0_10px_rgba(10,68,245,0.1)] rounded-10"
|
||||||
|
>
|
||||||
|
<input
|
||||||
|
v-model="convertNum"
|
||||||
|
type="number"
|
||||||
|
placeholder="转出金额"
|
||||||
|
class="text-14 text-#333 flex-1"
|
||||||
|
/>
|
||||||
|
<view
|
||||||
|
class="text-12 text-gradient"
|
||||||
|
@click="
|
||||||
|
convertNum = type === 0 ? userStore.userInfo?.moneyold : userStore.userInfo?.moneyyong
|
||||||
|
"
|
||||||
|
>
|
||||||
|
全部
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view class="text-14 text-#889BC6 mt-30">提现说明(TIPS)</view>
|
||||||
|
<view class="text-12 text-#889BC6 mt-15">
|
||||||
|
<view>1、如遇到系统结算繁忙,转换将会延迟到账</view>
|
||||||
|
<view class="mt-4">2、提现将会提现至您的工商银行卡;</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view
|
||||||
|
class="bg-white fixed bottom-0 left-0 right-0 px-15 py-10 shadow-[0_0_10px_rgba(10,68,245,0.1)]"
|
||||||
|
>
|
||||||
|
<view class="flex items-center pb-safe">
|
||||||
|
<view
|
||||||
|
class="btn-gradient flex-1 text-center text-white rounded-full text-14 px-30 py-10"
|
||||||
|
@click="onSubmit"
|
||||||
|
>
|
||||||
|
确认转换至{{ type === 0 ? '余额' : '养老金' }}
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script setup lang="ts">
|
||||||
|
import NavBar from '@/components/NavBar.vue'
|
||||||
|
import { convertScoreAPI, getOldMoneyTransferAPI, getYongMoneyTransferAPI } from '@/service'
|
||||||
|
import { useUserStore } from '@/store'
|
||||||
|
import { mergeStep, showModal } from '@/utils'
|
||||||
|
|
||||||
|
const userStore = useUserStore()
|
||||||
|
|
||||||
|
const convertNum = ref('')
|
||||||
|
|
||||||
|
const onWithdrawalDetail = () => {
|
||||||
|
uni.navigateTo({
|
||||||
|
url: `/pages-sub/asset/index?tabIndex=${type.value ? 3 : 2}`,
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
const onSubmit = mergeStep(async () => {
|
||||||
|
await showModal('确认转换?')
|
||||||
|
const request = type.value === 0 ? getOldMoneyTransferAPI : getYongMoneyTransferAPI
|
||||||
|
await request({
|
||||||
|
money: convertNum.value,
|
||||||
|
})
|
||||||
|
await showModal('转换成功')
|
||||||
|
userStore.loadUserInfo()
|
||||||
|
onWithdrawalDetail()
|
||||||
|
})
|
||||||
|
|
||||||
|
const type = ref(0)
|
||||||
|
onLoad((options) => {
|
||||||
|
type.value = Number(options.type ?? 0)
|
||||||
|
})
|
||||||
|
|
||||||
|
const title = computed(() => {
|
||||||
|
return type.value === 0 ? '养老金转余额' : '团队佣金转养老金'
|
||||||
|
})
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style scoped></style>
|
||||||
@@ -0,0 +1,46 @@
|
|||||||
|
<route lang="json5" type="page">
|
||||||
|
{
|
||||||
|
style: {
|
||||||
|
navigationBarTitleText: '热点新闻',
|
||||||
|
},
|
||||||
|
}
|
||||||
|
</route>
|
||||||
|
<template>
|
||||||
|
<view class="hot-news-page min-h-screen p-15">
|
||||||
|
<view class="bg-#fff rounded-10 px-15 py-15" v-if="newsList.length > 0">
|
||||||
|
<view
|
||||||
|
class="flex mb-15"
|
||||||
|
v-for="item in newsList"
|
||||||
|
:key="item.id"
|
||||||
|
@click="handleNewsDetail(item.id)"
|
||||||
|
>
|
||||||
|
<image class="w-85 h-85 rounded-10" :src="item.image" mode="aspectFill" />
|
||||||
|
<view class="ml-15 flex-1 flex flex-col justify-between">
|
||||||
|
<view text-14>{{ item.name }}</view>
|
||||||
|
<view class="text-12 text-#999">{{ formatTime(item.createtime) }}</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<wd-status-tip v-else image="content" tip="暂无内容" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script setup lang="ts">
|
||||||
|
import { getIntroductionAPI } from '@/service'
|
||||||
|
import { formatTime } from '@/utils'
|
||||||
|
|
||||||
|
const { list: newsList } = useListPageRequest((params) =>
|
||||||
|
getIntroductionAPI({ type: 1, ...params }),
|
||||||
|
)
|
||||||
|
|
||||||
|
const handleNewsDetail = (id: number) => {
|
||||||
|
uni.navigateTo({
|
||||||
|
url: `/pages-sub/news-detail/index?id=${id}`,
|
||||||
|
})
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
<style scoped>
|
||||||
|
.hot-news-page {
|
||||||
|
background: #f7f7f7;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
@@ -1,27 +1,34 @@
|
|||||||
<route lang="json5" type="page">
|
<route lang="json5">
|
||||||
{
|
{
|
||||||
style: {
|
style: {
|
||||||
navigationBarTitleText: '公司简介',
|
navigationBarTitleText: '公司简介',
|
||||||
|
navigationBarBackgroundColor: '#fff',
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
</route>
|
</route>
|
||||||
|
|
||||||
<script setup lang="ts">
|
|
||||||
import { getCompanyInfoAPI } from '@/service'
|
|
||||||
|
|
||||||
const { data: companyInfo } = useRequest(() => getCompanyInfoAPI())
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
<view class="pt-15 pb-50 min-h-screen">
|
<view class="pt-15 pb-50 min-h-screen" v-if="introductionDetail">
|
||||||
<view class="text-center text-16 font-bold">{{ companyInfo.title }}</view>
|
<view class="text-center text-16 font-bold">{{ introductionDetail.name }}</view>
|
||||||
<image
|
<image
|
||||||
class="w-345 h-170 rounded-10 mt-15 mx-auto block"
|
class="w-345 h-170 rounded-10 mt-15 mx-auto block"
|
||||||
:src="companyInfo.cover_image"
|
:src="introductionDetail.image"
|
||||||
mode="aspectFill"
|
mode="aspectFill"
|
||||||
/>
|
/>
|
||||||
<view class="text-gray-500 mx-16 text-14 mt-15">
|
<view class="text-gray-500 mx-16 text-14 mt-15 break-all">
|
||||||
{{ companyInfo.description }}
|
{{ introductionDetail.content }}
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
<script setup lang="ts">
|
||||||
|
import { getIntroductionAPI } from '@/service'
|
||||||
|
|
||||||
|
const { list: introductionList } = useListPageRequest((params) =>
|
||||||
|
getIntroductionAPI({ type: 3, ...params }),
|
||||||
|
)
|
||||||
|
|
||||||
|
const introductionDetail = computed(() => {
|
||||||
|
return introductionList.value[0]
|
||||||
|
})
|
||||||
|
</script>
|
||||||
|
|||||||
@@ -1,44 +1,52 @@
|
|||||||
<route lang="json5" type="page">
|
<route lang="json5">
|
||||||
{
|
{
|
||||||
style: {
|
style: {
|
||||||
navigationBarTitleText: '投资记录',
|
navigationBarTitleText: '投资记录',
|
||||||
navigationBarBackgroundColor: '#fff',
|
navigationBarBackgroundColor: '#fff',
|
||||||
|
navigationStyle: 'custom',
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
</route>
|
</route>
|
||||||
<script lang="ts" setup>
|
|
||||||
import { getBuyFundOrderListAPI } from '@/service'
|
|
||||||
import { useListPageRequest } from '@/hooks/useListPageRequest'
|
|
||||||
import { formatTime } from '@/utils'
|
|
||||||
|
|
||||||
const { list: fundList } = useListPageRequest(getBuyFundOrderListAPI)
|
<script setup lang="ts">
|
||||||
|
import NavBar from '@/components/NavBar.vue'
|
||||||
|
import { getInvestmentRecordAPI } from '@/service'
|
||||||
|
|
||||||
|
const { list: investmentRecordList } = useListPageRequest(getInvestmentRecordAPI)
|
||||||
|
function getType(item) {
|
||||||
|
return Number(item.typedata) === 2 ? '投保' : '投资'
|
||||||
|
}
|
||||||
</script>
|
</script>
|
||||||
<template>
|
<template>
|
||||||
<view class="min-h-screen pb-100">
|
|
||||||
<template v-if="fundList.length > 0">
|
|
||||||
<view
|
<view
|
||||||
class="flex px-15 py-8 border-b border-#E5E5E5 border-b-solid"
|
class="min-h-screen pb-100"
|
||||||
v-for="item in fundList"
|
style="background: linear-gradient(180deg, #3a90f2 0%, #f7f7f7 100%)"
|
||||||
|
>
|
||||||
|
<NavBar />
|
||||||
|
<view class="mt-15" v-if="investmentRecordList.length">
|
||||||
|
<view
|
||||||
|
class="flex px-15 py-8 mb-1 bg-#ffffff"
|
||||||
|
v-for="item in investmentRecordList"
|
||||||
:key="item.id"
|
:key="item.id"
|
||||||
>
|
>
|
||||||
<image src="/static/images/page-sub/money-icon.png" class="w-32 h-32 self-center" />
|
<image src="/static/images/page-sub/money-icon.png" class="w-32 h-32 self-center" />
|
||||||
<view class="flex flex-col flex-1 justify-between ml-15">
|
<view class="flex flex-col flex-1 justify-between ml-15">
|
||||||
<view class="text-14 text-#333">{{ item.fund_name }}</view>
|
<view class="text-14 text-#333">{{ item.name }}</view>
|
||||||
<view class="text-12 text-#999">投资</view>
|
<view class="text-12 text-#999">{{ getType(item) }}</view>
|
||||||
<view class="text-12 text-#999">{{ formatTime(item.create_time * 1000) }}</view>
|
<view class="text-12 text-#999">{{ item.createtime }}</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view class="flex flex-col items-end">
|
<view class="flex flex-col items-end">
|
||||||
<view class="text-16 text-#FF5F5F">+{{ item.buy_price }} RMB</view>
|
<view class="text-16 text-#FF5F5F">{{ item.money }}</view>
|
||||||
<view
|
<view
|
||||||
class="text-14 mt-18 py-4 px-10 bg-#71C78A1A text-#71C78A"
|
class="text-14 mt-18 py-4 px-10 bg-#71C78A1A text-#71C78A"
|
||||||
v-if="item.order_status === 1"
|
v-if="Number(item.status) === 1"
|
||||||
>
|
>
|
||||||
投资成功
|
{{ getType(item) }}成功
|
||||||
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
|
||||||
<template v-else>
|
<template v-else>
|
||||||
<wd-status-tip image="content" tip="暂无内容" />
|
<wd-status-tip image="content" tip="暂无内容" />
|
||||||
</template>
|
</template>
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
<route lang="json5" type="page">
|
<route lang="json5">
|
||||||
{
|
{
|
||||||
style: {
|
style: {
|
||||||
navigationStyle: 'custom',
|
navigationStyle: 'custom',
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
<route lang="json5" type="page">
|
<route lang="json5">
|
||||||
{
|
{
|
||||||
style: {
|
style: {
|
||||||
navigationBarTitleText: '充值成功',
|
navigationBarTitleText: '投资成功',
|
||||||
navigationBarBackgroundColor: '#fff',
|
navigationBarBackgroundColor: '#fff',
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
@@ -9,7 +9,7 @@
|
|||||||
<template>
|
<template>
|
||||||
<view class="min-h-screen flex flex-col items-center justify-center">
|
<view class="min-h-screen flex flex-col items-center justify-center">
|
||||||
<image mode="aspectFit" src="/static/images/page-sub/invest-success.png" class="w-150 h-150" />
|
<image mode="aspectFit" src="/static/images/page-sub/invest-success.png" class="w-150 h-150" />
|
||||||
<view class="text-17 text-#333">恭喜您!充值成功</view>
|
<view class="text-17 text-#333">恭喜您!投资成功</view>
|
||||||
<!-- 返回 -->
|
<!-- 返回 -->
|
||||||
<view class="mt-15">
|
<view class="mt-15">
|
||||||
<view @click="onBack" class="btn-gradient text-14 text-white rounded-full px-30 py-10">
|
<view @click="onBack" class="btn-gradient text-14 text-white rounded-full px-30 py-10">
|
||||||
|
|||||||
@@ -1,41 +1,52 @@
|
|||||||
<route lang="json5" type="page">
|
<route lang="json5">
|
||||||
{
|
{
|
||||||
style: {
|
style: {
|
||||||
navigationBarTitleText: '邀请好友',
|
navigationBarTitleText: '邀请好友',
|
||||||
navigationBarBackgroundColor: '#fff',
|
navigationBarBackgroundColor: '#fff',
|
||||||
|
navigationStyle: 'custom',
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
</route>
|
</route>
|
||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { useUserStore } from '@/store'
|
import NavBar from '@/components/NavBar.vue'
|
||||||
import VueQrcode from '@chenfengyuan/vue-qrcode'
|
import VueQrcode from '@chenfengyuan/vue-qrcode'
|
||||||
|
|
||||||
const userStore = useUserStore()
|
const qrcodeValue = '/pages/register/index?invite=888888'
|
||||||
|
|
||||||
const qrcodeValue =
|
|
||||||
location.origin + '/#/pages/register/index?invite=' + userStore.userInfo?.invitation_code
|
|
||||||
|
|
||||||
const onCopy = (code: string) => {
|
const onCopy = (code: string) => {
|
||||||
uni.setClipboardData({
|
uni.setClipboardData({
|
||||||
data: code,
|
data: code,
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const onLottery = () => {
|
||||||
|
uni.navigateTo({
|
||||||
|
url: '/pages-sub/lottery/index',
|
||||||
|
})
|
||||||
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
<view class="pt-250 pb-100 min-h-screen invite-page">
|
<view class="pb-100 min-h-screen invite-page">
|
||||||
<view class="flex flex-col items-center">
|
<NavBar />
|
||||||
|
<view class="flex justify-center mt-80">
|
||||||
|
<view class="text-white btn-gradient rounded-full px-30 py-10 text-14">邀请好友</view>
|
||||||
|
<view class="ml-15 bg-white rounded-full px-30 py-10 text-14" @click="onLottery">
|
||||||
|
<text class="text-gradient">幸运大转盘</text>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view class="flex flex-col items-center mt-180">
|
||||||
<view
|
<view
|
||||||
class="flex items-center text-16 text-#333 bg-[rgba(255,255,255,0.8)] rounded-full px-15 py-4 text-12 mt-8"
|
class="flex items-center text-16 text-#333 bg-[rgba(255,255,255,0.8)] rounded-full px-15 py-4 text-12 mt-8"
|
||||||
>
|
>
|
||||||
<view>
|
<view>
|
||||||
邀请码
|
邀请码
|
||||||
<text class="font-bold">{{ userStore.userInfo.invitation_code }}</text>
|
<text class="font-bold">9999999</text>
|
||||||
</view>
|
</view>
|
||||||
<view
|
<view
|
||||||
class="btn-gradient text-white rounded-full px-15 py-4 text-12 ml-10"
|
class="btn-gradient text-white rounded-full px-15 py-4 text-12 ml-10"
|
||||||
@click="onCopy(userStore.userInfo.invitation_code)"
|
@click="onCopy('99999')"
|
||||||
>
|
>
|
||||||
复制
|
复制
|
||||||
</view>
|
</view>
|
||||||
@@ -55,7 +66,7 @@ const onCopy = (code: string) => {
|
|||||||
|
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
.invite-page {
|
.invite-page {
|
||||||
background-image: url('@/static/images/page-sub/invite-bg.png');
|
background-image: url('@/static/images/page-sub/invite-bg.jpg');
|
||||||
background-repeat: no-repeat;
|
background-repeat: no-repeat;
|
||||||
background-position: top;
|
background-position: top;
|
||||||
background-size: 100%;
|
background-size: 100%;
|
||||||
|
|||||||
@@ -0,0 +1,146 @@
|
|||||||
|
<route lang="json5">
|
||||||
|
{
|
||||||
|
style: {
|
||||||
|
navigationBarTitleText: '转盘抽奖',
|
||||||
|
navigationBarBackgroundColor: '#fff',
|
||||||
|
navigationStyle: 'custom',
|
||||||
|
},
|
||||||
|
}
|
||||||
|
</route>
|
||||||
|
|
||||||
|
<script setup lang="ts">
|
||||||
|
import NavBar from '@/components/NavBar.vue'
|
||||||
|
import GridLottery from '@/components/GridLottery.vue'
|
||||||
|
|
||||||
|
import lotteryIcon from '@/static/images/home/nav-2.png'
|
||||||
|
|
||||||
|
const list = [
|
||||||
|
{
|
||||||
|
id: 1,
|
||||||
|
sort: 0,
|
||||||
|
title: '\u6BDB\u5DFE',
|
||||||
|
icon: lotteryIcon,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 2,
|
||||||
|
sort: 1,
|
||||||
|
title: '\u6BDB\u5DFE',
|
||||||
|
icon: lotteryIcon,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 3,
|
||||||
|
sort: 2,
|
||||||
|
title: '\u6BDB\u5DFE',
|
||||||
|
icon: lotteryIcon,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 4,
|
||||||
|
sort: 3,
|
||||||
|
title: '\u6BDB\u5DFE',
|
||||||
|
icon: lotteryIcon,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 5,
|
||||||
|
sort: 4,
|
||||||
|
title: '\u6BDB\u5DFE',
|
||||||
|
icon: lotteryIcon,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 6,
|
||||||
|
sort: 5,
|
||||||
|
title: '\u6BDB\u5DFE',
|
||||||
|
icon: lotteryIcon,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 7,
|
||||||
|
sort: 6,
|
||||||
|
title: '\u6BDB\u5DFE',
|
||||||
|
icon: lotteryIcon,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 8,
|
||||||
|
sort: 7,
|
||||||
|
title: '\u6BDB\u5DFE',
|
||||||
|
icon: lotteryIcon,
|
||||||
|
},
|
||||||
|
]
|
||||||
|
|
||||||
|
const gridLotteryRef = ref(null)
|
||||||
|
const onStart = () => {
|
||||||
|
// 中奖id,抽奖轮转时间毫秒
|
||||||
|
gridLotteryRef.value.start(3, 10000)
|
||||||
|
}
|
||||||
|
const onEnd = () => {
|
||||||
|
console.log('onEnd')
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<template>
|
||||||
|
<view class="min-h-screen lottery-page">
|
||||||
|
<NavBar />
|
||||||
|
<view class="mt-240 w-315 h-315 flex items-center justify-center mx-auto lottery-container">
|
||||||
|
<grid-lottery
|
||||||
|
:itemHeight="186"
|
||||||
|
ref="gridLotteryRef"
|
||||||
|
class="w-280 ml-8 mt-8"
|
||||||
|
:list="list"
|
||||||
|
@onStart="onStart"
|
||||||
|
@onEnd="onEnd"
|
||||||
|
>
|
||||||
|
<!-- <view slot="lottery-item" slot-scope="slotProps">{{ slotProps }}</view> -->
|
||||||
|
<template #lottery-item="{ data, index, currIndex }">
|
||||||
|
<view
|
||||||
|
class="overflow-hidden relative lottery-item flex flex-col items-center justify-center rounded-10 bg-[linear-gradient(180deg,#fffdf7,#fff1ca)] w-86 h-86"
|
||||||
|
:class="{
|
||||||
|
mask: currIndex !== index,
|
||||||
|
}"
|
||||||
|
>
|
||||||
|
<image :src="data.icon" class="w-30 h-30" />
|
||||||
|
<view class="text-14 text-#333 mt-8">{{ data.title }}</view>
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
<template #start-button>
|
||||||
|
<view
|
||||||
|
class="w-86 flex flex-col items-center justify-center h-86 bg-[linear-gradient(180deg,#FF8282,#D73434)] text-#FBEDC6 text-25 rounded-10"
|
||||||
|
>
|
||||||
|
<view>点击</view>
|
||||||
|
<view>抽奖</view>
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
<template #activity-box>
|
||||||
|
<view class="w-86 h-86 bg-red-500"></view>
|
||||||
|
</template>
|
||||||
|
</grid-lottery>
|
||||||
|
</view>
|
||||||
|
<view class="text-16 mx-auto w-315 mb-15 font-bold text-#fff mt-30">抽奖规则</view>
|
||||||
|
<view class="text-12 mx-auto w-315 mb-15 text-#fff mt-15">
|
||||||
|
1. 每轮抽奖消耗10000认购点,每轮抽奖次数为3次,每轮抽奖结束后,消耗的认购点将恢复为0。
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
<style scoped>
|
||||||
|
.lottery-item {
|
||||||
|
&.mask {
|
||||||
|
&::after {
|
||||||
|
position: absolute;
|
||||||
|
top: 0;
|
||||||
|
left: 0;
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
content: '';
|
||||||
|
background: rgba(0, 0, 0, 0.1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
.lottery-container {
|
||||||
|
background-image: url('@/static/images/lottery-bar.png');
|
||||||
|
background-size: 100% 100%;
|
||||||
|
}
|
||||||
|
.lottery-page {
|
||||||
|
background-color: #517aae;
|
||||||
|
background-image: url('@/static/images/lottery-bg.png');
|
||||||
|
background-repeat: no-repeat;
|
||||||
|
background-position: top;
|
||||||
|
background-size: 100%;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
@@ -7,22 +7,26 @@
|
|||||||
}
|
}
|
||||||
</route>
|
</route>
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { getNewsDetailAPI } from '@/service'
|
import { getIntroductionDetailAPI } from '@/service'
|
||||||
|
import { getImageUrl } from '@/utils'
|
||||||
|
import dayjs from 'dayjs'
|
||||||
|
|
||||||
const newsDetail = ref<any>({})
|
const newsDetail = ref<any>({})
|
||||||
onLoad(async (options) => {
|
onLoad(async (options) => {
|
||||||
const { data } = await getNewsDetailAPI({ news_id: options.id })
|
const { data } = await getIntroductionDetailAPI({ id: options.id })
|
||||||
newsDetail.value = data
|
newsDetail.value = data
|
||||||
})
|
})
|
||||||
</script>
|
</script>
|
||||||
<template>
|
<template>
|
||||||
<view class="min-h-screen pb-100 pt-30 px-15">
|
<view class="min-h-screen pb-100 pt-30 px-15">
|
||||||
<view class="text-20 text-black font-bold">{{ newsDetail.title }}</view>
|
<view class="text-20 text-black font-bold">{{ newsDetail.name }}</view>
|
||||||
<view class="flex justify-between py-10">
|
<view class="flex justify-between py-10">
|
||||||
<view class="text-14 text-gray-500">{{ newsDetail.auther }}</view>
|
<view class="text-14 text-gray-500">{{ newsDetail.source }}</view>
|
||||||
<view class="text-14 text-gray-500">{{ newsDetail.create_time }}</view>
|
<view class="text-14 text-gray-500">
|
||||||
|
{{ dayjs(newsDetail.createtime * 1000).format('YYYY-MM-DD HH:mm') }}
|
||||||
</view>
|
</view>
|
||||||
<image class="w-full mt-15" mode="widthFix" :src="newsDetail.cover_image" />
|
</view>
|
||||||
<view class="text-14 text-gray-600 mt-15">{{ newsDetail.description }}</view>
|
<image class="w-full mt-15" mode="widthFix" :src="getImageUrl(newsDetail.image)" />
|
||||||
|
<view class="text-14 text-gray-600 mt-15" v-html="newsDetail.content" />
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|||||||
@@ -0,0 +1,49 @@
|
|||||||
|
<route lang="json5" type="page">
|
||||||
|
{
|
||||||
|
style: {
|
||||||
|
navigationBarTitleText: '最新时讯',
|
||||||
|
navigationStyle: 'custom',
|
||||||
|
},
|
||||||
|
}
|
||||||
|
</route>
|
||||||
|
<template>
|
||||||
|
<view class="news-page">
|
||||||
|
<NavBar />
|
||||||
|
<view class="py-15" v-if="newsList.length > 0">
|
||||||
|
<view
|
||||||
|
class="bg-white rounded-10 overflow-hidden p-15 mx-15 mb-15"
|
||||||
|
v-for="item in newsList"
|
||||||
|
:key="item.id"
|
||||||
|
@click="handleNewsDetail(item.id)"
|
||||||
|
>
|
||||||
|
<image class="rounded-10 w-full h-160" :src="item.image" mode="aspectFill" />
|
||||||
|
<view class="mt-10 flex-1 flex flex-col justify-between">
|
||||||
|
<view class="text-14">{{ item.name }}</view>
|
||||||
|
<view class="text-12 text-#999 mt-10">{{ item.source }}</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<wd-status-tip v-else image="content" tip="暂无内容" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script setup lang="ts">
|
||||||
|
import NavBar from '@/components/NavBar.vue'
|
||||||
|
import { getIntroductionAPI } from '@/service'
|
||||||
|
|
||||||
|
const { list: newsList } = useListPageRequest((params) =>
|
||||||
|
getIntroductionAPI({ type: 1, ...params }),
|
||||||
|
)
|
||||||
|
|
||||||
|
const handleNewsDetail = (id: number) => {
|
||||||
|
uni.navigateTo({
|
||||||
|
url: `/pages-sub/news-detail/index?id=${id}`,
|
||||||
|
})
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style scoped>
|
||||||
|
.news-page {
|
||||||
|
background: linear-gradient(180deg, #3a90f2 0%, #f7f7f7 100%);
|
||||||
|
}
|
||||||
|
</style>
|
||||||
@@ -3,7 +3,7 @@ import NavBar from '@/components/NavBar.vue'
|
|||||||
import VueQrcode from '@chenfengyuan/vue-qrcode'
|
import VueQrcode from '@chenfengyuan/vue-qrcode'
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<route lang="json5" type="page">
|
<route lang="json5">
|
||||||
{
|
{
|
||||||
style: {
|
style: {
|
||||||
navigationBarTitleText: '官方社群',
|
navigationBarTitleText: '官方社群',
|
||||||
@@ -16,29 +16,40 @@ import VueQrcode from '@chenfengyuan/vue-qrcode'
|
|||||||
<template>
|
<template>
|
||||||
<view class="official-community-page">
|
<view class="official-community-page">
|
||||||
<NavBar />
|
<NavBar />
|
||||||
<view class="p-15 text-center bg-white rounded-10 m-15 shadow-[0_0_10px_rgba(0,0,0,0.1)]">
|
<view
|
||||||
<view class="text-16 font-bold text-#333">扫码进入</view>
|
class="relative px-15 text-center bg-white rounded-10 m-15 shadow-[0_0_10px_rgba(0,0,0,0.1)]"
|
||||||
<wd-icon name="arrow-down" color="#333" size="18px"></wd-icon>
|
>
|
||||||
<view class="btn-gradient rounded-full w-fit mx-auto text-16 text-white py-10 px-15">
|
<image
|
||||||
微聊总群:50101011
|
class="w-full mx-auto"
|
||||||
|
src="@/static/images/page-sub/official-community/image-1.jpg"
|
||||||
|
mode="widthFix"
|
||||||
|
/>
|
||||||
|
<a
|
||||||
|
href="https://doudlj.org/joinchat/Jol7Vt58a2aCrjsXm9D_LA"
|
||||||
|
class="absolute bottom-15 left-50% -translate-x-1/2"
|
||||||
|
>
|
||||||
|
点击进入
|
||||||
|
</a>
|
||||||
</view>
|
</view>
|
||||||
<VueQrcode class="!w-270 !h-270 mx-auto" :value="'qrcodeValue'" :options="{ size: 600 }" />
|
<view
|
||||||
</view>
|
class="relative px-15 text-center bg-white rounded-10 m-15 shadow-[0_0_10px_rgba(0,0,0,0.1)]"
|
||||||
<view class="p-15 text-center bg-white rounded-10 m-15 shadow-[0_0_10px_rgba(0,0,0,0.1)]">
|
>
|
||||||
<view class="text-16 font-bold text-#333">扫码进入</view>
|
<image
|
||||||
<wd-icon name="arrow-down" color="#333" size="18px"></wd-icon>
|
class="w-full mx-auto"
|
||||||
<view class="btn-gradient rounded-full w-fit mx-auto text-16 text-white py-10 px-15">
|
src="@/static/images/page-sub/official-community/image-2.jpg"
|
||||||
QQ群2群:1011101011
|
mode="widthFix"
|
||||||
</view>
|
/>
|
||||||
<VueQrcode class="!w-270 !h-270 mx-auto" :value="'qrcodeValue'" :options="{ size: 600 }" />
|
<a href="https://doudlj.org/NiPing95" class="absolute bottom-15 left-50% -translate-x-1/2">
|
||||||
|
点击进入
|
||||||
|
</a>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<style>
|
<style scoped>
|
||||||
.official-community-page {
|
.official-community-page {
|
||||||
min-height: 100vh;
|
min-height: 100vh;
|
||||||
padding-bottom: 100rpx;
|
padding-bottom: 50px;
|
||||||
background-image: url('@/static/images/bg.png');
|
background-image: url('@/static/images/bg.png');
|
||||||
background-position: top;
|
background-position: top;
|
||||||
background-size: cover;
|
background-size: cover;
|
||||||
|
|||||||
@@ -1,127 +0,0 @@
|
|||||||
<template>
|
|
||||||
<view class="min-h-screen pt-50 pb-100">
|
|
||||||
<view
|
|
||||||
class="w-345 mx-auto rounded-10 btn-gradient px-30 pb-20 relative shadow-[0_5px_30px_rgba(55,230,236,0.4)]"
|
|
||||||
>
|
|
||||||
<view class="relative -top-30px">
|
|
||||||
<view class="relative w-70">
|
|
||||||
<Avatar class="w-70 h-70 box-border" />
|
|
||||||
<view
|
|
||||||
class="text-center left-1/2 whitespace-nowrap -translate-x-1/2 py-2 px-10 absolute -bottom-6 bg-[linear-gradient(180deg,#FFD54B,#FFB99A)] rounded-full text-10 left-0 text-#fff"
|
|
||||||
>
|
|
||||||
黄金会员
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="text-16 mt-15 text-#fff">132***0101</view>
|
|
||||||
</view>
|
|
||||||
<view class="absolute -bottom-10 right-30 text-90 leading-80 font-bold text-#ffffff20">
|
|
||||||
VIP
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<view class="mt-30 w-345 mx-auto grid grid-cols-3 gap-10">
|
|
||||||
<view
|
|
||||||
class="bg-#fff py-40 rounded-10 text-center border border-#E5E5E5 border-solid"
|
|
||||||
v-for="(item, index) of vipList"
|
|
||||||
:key="item.id"
|
|
||||||
:class="{
|
|
||||||
'!bg-[linear-gradient(90deg,#3B81F320,#37E6EC20)]': currentVipIndex === index,
|
|
||||||
'!border-#3B81F3': currentVipIndex === index,
|
|
||||||
}"
|
|
||||||
@click="currentVipIndex = index"
|
|
||||||
>
|
|
||||||
<view class="text-14">{{ item.vip_name }}</view>
|
|
||||||
<view class="mt-10 text-20 font-bold">{{ item.buy_price }}</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<view class="text-center mt-30 mt-30 pt-30 border-t-8 border-#f7f7f7 border-t-solid">
|
|
||||||
<view class="text-18 font-500 text-#333">会员专属权益</view>
|
|
||||||
<view class="text-14 text-#666 mt-10">每日获得高收益分红</view>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<view class="mt-30 w-345 mx-auto grid grid-cols-3 gap-10">
|
|
||||||
<view class="bg-#fff py-20 rounded-10 text-center border border-#E5E5E5 border-solid">
|
|
||||||
<image
|
|
||||||
class="w-50 h-50"
|
|
||||||
src="@/static/images/page-sub/purchase-member/icon-1.png"
|
|
||||||
mode="scaleToFill"
|
|
||||||
/>
|
|
||||||
<view class="mt-10 text-12 text-#999">每日可以获取</view>
|
|
||||||
<view class="text-14 font-bold text-#FF5F5F">
|
|
||||||
{{ Number(vipList[currentVipIndex].award_investment) }}投资金
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="border border-#E5E5E5 border-solid py-20 rounded-10 text-center">
|
|
||||||
<image
|
|
||||||
class="w-50 h-50"
|
|
||||||
src="@/static/images/page-sub/purchase-member/icon-2.png"
|
|
||||||
mode="scaleToFill"
|
|
||||||
/>
|
|
||||||
<view class="mt-10 text-12 text-#999">数字人民币</view>
|
|
||||||
<view class="text-14 font-bold text-#FF5F5F">
|
|
||||||
{{ Number(vipList[currentVipIndex].award_currency) }}元
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="bg-#fff py-20 rounded-10 text-center border border-#E5E5E5 border-solid">
|
|
||||||
<image
|
|
||||||
class="w-50 h-50"
|
|
||||||
src="@/static/images/page-sub/purchase-member/icon-3.png"
|
|
||||||
mode="scaleToFill"
|
|
||||||
/>
|
|
||||||
<view class="mt-10 text-12 text-#999">AI智能</view>
|
|
||||||
<view class="text-14 font-bold text-#FF5F5F">
|
|
||||||
{{ vipList[currentVipIndex].dividend_multiple }}倍
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<view
|
|
||||||
class="bg-white fixed bottom-0 left-0 right-0 px-15 py-10 shadow-[0_0_10px_rgba(10,68,245,0.1)]"
|
|
||||||
>
|
|
||||||
<view class="flex items-center pb-safe">
|
|
||||||
<view
|
|
||||||
class="btn-gradient flex-1 text-center text-white rounded-full text-14 px-30 py-10"
|
|
||||||
@click="onSubmit"
|
|
||||||
>
|
|
||||||
立即购买
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script lang="ts" setup>
|
|
||||||
import Avatar from '@/components/Avatar.vue'
|
|
||||||
import { buyVIPAPI, getVipListAPI } from '@/service'
|
|
||||||
import { useUserStore } from '@/store'
|
|
||||||
import { mergeStep, showModal } from '@/utils'
|
|
||||||
|
|
||||||
const vipList = ref<any[]>([])
|
|
||||||
const currentVipIndex = ref(0)
|
|
||||||
onLoad(() => {
|
|
||||||
getVipListAPI().then((res) => {
|
|
||||||
vipList.value = res.data.list
|
|
||||||
})
|
|
||||||
})
|
|
||||||
|
|
||||||
const userStore = useUserStore()
|
|
||||||
const onSubmit = mergeStep(async () => {
|
|
||||||
console.log(vipList.value[currentVipIndex.value])
|
|
||||||
await showModal('确认购买吗?')
|
|
||||||
await buyVIPAPI({
|
|
||||||
fund_id: vipList.value[currentVipIndex.value].id,
|
|
||||||
})
|
|
||||||
await showModal('购买成功')
|
|
||||||
await userStore.loadUserInfo()
|
|
||||||
})
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<route lang="json5" type="page">
|
|
||||||
{
|
|
||||||
style: {
|
|
||||||
navigationBarTitleText: '购买会员',
|
|
||||||
navigationBarBackgroundColor: '#fff',
|
|
||||||
},
|
|
||||||
}
|
|
||||||
</route>
|
|
||||||
@@ -9,7 +9,7 @@
|
|||||||
|
|
||||||
<template>
|
<template>
|
||||||
<view class="withdrawal-type-edit-page pb-100 min-h-screen">
|
<view class="withdrawal-type-edit-page pb-100 min-h-screen">
|
||||||
<template v-if="Number(userStore.userInfo?.member_certification) === 0">
|
<template v-if="!realnameInfo">
|
||||||
<view class="p-15 m-15 shadow-[0_0_10px_rgba(10,68,245,0.1)] rounded-10">
|
<view class="p-15 m-15 shadow-[0_0_10px_rgba(10,68,245,0.1)] rounded-10">
|
||||||
<view class="flex items-center py-15 text-14">
|
<view class="flex items-center py-15 text-14">
|
||||||
<image src="@/static/images/page-sub/realname/realname-type.png" class="w-20 h-20" />
|
<image src="@/static/images/page-sub/realname/realname-type.png" class="w-20 h-20" />
|
||||||
@@ -24,7 +24,7 @@
|
|||||||
placeholder-class=" text-#889BC6 text-right"
|
placeholder-class=" text-#889BC6 text-right"
|
||||||
type="text"
|
type="text"
|
||||||
placeholder="请输入真实姓名"
|
placeholder="请输入真实姓名"
|
||||||
v-model="form.credentials_name"
|
v-model="form.realname"
|
||||||
/>
|
/>
|
||||||
</view>
|
</view>
|
||||||
<view class="flex items-center py-15 text-14">
|
<view class="flex items-center py-15 text-14">
|
||||||
@@ -35,9 +35,39 @@
|
|||||||
placeholder-class=" text-#889BC6 text-right"
|
placeholder-class=" text-#889BC6 text-right"
|
||||||
type="text"
|
type="text"
|
||||||
placeholder="请输入身份证号"
|
placeholder="请输入身份证号"
|
||||||
v-model="form.credentials_number"
|
v-model="form.cardnum"
|
||||||
/>
|
/>
|
||||||
</view>
|
</view>
|
||||||
|
<!-- <view class="py-15 text-14">
|
||||||
|
<view class="flex items-center">
|
||||||
|
<image src="@/static/images/page-sub/realname/realname-card.png" class="w-20 h-20" />
|
||||||
|
<view class="ml-8">证件照片</view>
|
||||||
|
</view>
|
||||||
|
<view
|
||||||
|
class="flex items-center justify-center mt-15 rounded-10 bg-#F1F9FC h-168 w-full"
|
||||||
|
@click="onUploadZCardImage"
|
||||||
|
>
|
||||||
|
<view v-if="!zcardimage" class="text-center">
|
||||||
|
<image src="@/static/images/page-sub/realname/upload-icon.png" class="w-40 h-40" />
|
||||||
|
<view class="text-14 text-#999 mt-10">点击上传身份证正面</view>
|
||||||
|
</view>
|
||||||
|
<view v-else class="flex items-center">
|
||||||
|
<image :src="zcardimage" class="w-315 h-168" mode="aspectFit" />
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view
|
||||||
|
class="flex items-center justify-center mt-15 rounded-10 bg-#F1F9FC h-168 w-full"
|
||||||
|
@click="onUploadFCardImage"
|
||||||
|
>
|
||||||
|
<view v-if="!fcardimage" class="text-center">
|
||||||
|
<image src="@/static/images/page-sub/realname/upload-icon.png" class="w-40 h-40" />
|
||||||
|
<view class="text-14 text-#999 mt-10">点击上传身份证反面</view>
|
||||||
|
</view>
|
||||||
|
<view v-else class="flex items-center">
|
||||||
|
<image :src="fcardimage" class="w-315 h-168" mode="aspectFit" />
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view> -->
|
||||||
</view>
|
</view>
|
||||||
<view class="fixed bottom-0 left-0 right-0 pb-safe">
|
<view class="fixed bottom-0 left-0 right-0 pb-safe">
|
||||||
<button class="btn-gradient text-white rounded-full m-15 text-16" @click="onSubmit">
|
<button class="btn-gradient text-white rounded-full m-15 text-16" @click="onSubmit">
|
||||||
@@ -45,67 +75,108 @@
|
|||||||
</button>
|
</button>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
<template v-else-if="Number(userStore.userInfo?.member_certification) === 2">
|
|
||||||
|
<view v-else class="flex flex-col items-center">
|
||||||
|
<template v-if="Number(realnameInfo.status) === 1">
|
||||||
<image
|
<image
|
||||||
src="@/static/images/page-sub/realname/realname-checking.png"
|
src="@/static/images/page-sub/realname/realname-checking.png"
|
||||||
class="w-150 mx-auto h-150 block"
|
class="w-150 mx-auto h-150 block"
|
||||||
mode="aspectFit"
|
mode="aspectFit"
|
||||||
/>
|
/>
|
||||||
<view class="text-center mt-15 text-14 text-#999">您的实名认证正在审核中,请耐心等待</view>
|
<view class="text-center mt-15 text-14 text-#999">您的实名认证正在审核中,请耐心等待</view>
|
||||||
<button class="btn-gradient px-30 text-white rounded-full m-15 text-16" @click="onBack">
|
<button
|
||||||
返回
|
class="btn-gradient px-30 text-white rounded-full m-15 text-16"
|
||||||
|
@click="userStore.logout"
|
||||||
|
>
|
||||||
|
退出登录
|
||||||
</button>
|
</button>
|
||||||
</template>
|
</template>
|
||||||
<template v-else-if="Number(userStore.userInfo?.member_certification) === 1">
|
<template v-else-if="Number(realnameInfo.status) === 2">
|
||||||
<view class="flex flex-col items-center" v-if="false">
|
|
||||||
<image
|
<image
|
||||||
src="@/static/images/page-sub/realname/realname-success.png"
|
src="@/static/images/page-sub/realname/realname-success.png"
|
||||||
class="w-150 h-150 block"
|
class="w-150 h-150 block"
|
||||||
mode="aspectFit"
|
mode="aspectFit"
|
||||||
/>
|
/>
|
||||||
<view class="text-center mt-15 text-14 text-#999">恭喜您,实名认证成功</view>
|
<view class="text-center mt-15 text-14 text-#999">恭喜您,实名认证成功</view>
|
||||||
<button class="btn-gradient px-30 text-white rounded-full m-15 text-16" @click="onBack">
|
<button class="btn-gradient px-30 text-white rounded-full m-15 text-16" @click="onGoHome">
|
||||||
返回
|
返回
|
||||||
</button>
|
</button>
|
||||||
<!--
|
</template>
|
||||||
|
<template v-else>
|
||||||
<image
|
<image
|
||||||
src="@/static/images/page-sub/realname/realname-checking.png"
|
src="@/static/images/page-sub/realname/realname-checking.png"
|
||||||
class="w-150 h-150 block"
|
class="w-150 h-150 block"
|
||||||
mode="aspectFit"
|
mode="aspectFit"
|
||||||
/>
|
/>
|
||||||
<view class="text-center mt-15 text-14 text-#999">您的实名认证审核未通过,请重新提交</view>
|
<view class="text-center mt-15 text-14 text-#999">您的实名认证审核未通过,请重新提交</view>
|
||||||
<button class="btn-gradient px-30 text-white rounded-full m-15 text-16">重新提交</button> -->
|
<button
|
||||||
</view>
|
@click="() => (realnameInfo = null)"
|
||||||
|
class="btn-gradient px-30 text-white rounded-full m-15 text-16"
|
||||||
|
>
|
||||||
|
重新提交
|
||||||
|
</button>
|
||||||
</template>
|
</template>
|
||||||
</view>
|
</view>
|
||||||
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { createAuthUser } from '@/service'
|
import { getRealNameAuthAPI, realNameAuthAPI } from '@/service'
|
||||||
import { useUserStore } from '@/store'
|
import { useUserStore } from '@/store'
|
||||||
import { showModal } from '@/utils'
|
import { mergeStep, showModal } from '@/utils'
|
||||||
import { ref } from 'vue'
|
import { ref } from 'vue'
|
||||||
|
|
||||||
const userStore = useUserStore()
|
const userStore = useUserStore()
|
||||||
const notSubmit = ref(true)
|
|
||||||
|
|
||||||
const form = ref({
|
const form = ref({
|
||||||
credentials_name: '',
|
realname: '',
|
||||||
credentials_number: '',
|
cardnum: '',
|
||||||
})
|
})
|
||||||
|
|
||||||
const onBack = () => {
|
const onBack = () => {
|
||||||
uni.navigateBack()
|
uni.navigateBack()
|
||||||
}
|
}
|
||||||
|
|
||||||
const onSubmit = async () => {
|
const onSubmit = mergeStep(async () => {
|
||||||
if (!form.value.credentials_name || !form.value.credentials_number) {
|
if (!/^[\u4e00-\u9fa5·]{2,8}$/.test(form.value.realname)) {
|
||||||
await showModal('请填写完整信息')
|
await showModal('姓名格式错误')
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
await createAuthUser(form.value)
|
|
||||||
notSubmit.value = false
|
if (!/^\d{17}[\d|x]$/i.test(form.value.cardnum)) {
|
||||||
|
await showModal('身份证号格式错误')
|
||||||
|
return
|
||||||
|
}
|
||||||
|
// if (!zcardimage.value || !fcardimage.value) {
|
||||||
|
// await showModal('请上传身份证照片')
|
||||||
|
// return
|
||||||
|
// }
|
||||||
|
await realNameAuthAPI({
|
||||||
|
...form.value,
|
||||||
|
// zcardimage: zcardimage.value,
|
||||||
|
// fcardimage: fcardimage.value,
|
||||||
|
})
|
||||||
|
await showModal('提交成功,请耐心等待审核!')
|
||||||
|
realnameInfo.value = await getRealNameAuthAPI().then((res) => {
|
||||||
|
return res.data
|
||||||
|
})
|
||||||
|
})
|
||||||
|
|
||||||
|
const onGoHome = () => {
|
||||||
|
uni.reLaunch({
|
||||||
|
url: '/',
|
||||||
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// const { data: zcardimage, run: onUploadZCardImage } = useUpload()
|
||||||
|
// const { data: fcardimage, run: onUploadFCardImage } = useUpload()
|
||||||
|
|
||||||
|
const realnameInfo = ref(null)
|
||||||
|
onLoad(async () => {
|
||||||
|
realnameInfo.value = await getRealNameAuthAPI().then((res) => {
|
||||||
|
return res.data
|
||||||
|
})
|
||||||
|
})
|
||||||
</script>
|
</script>
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
.withdrawal-type-edit-page {
|
.withdrawal-type-edit-page {
|
||||||
|
|||||||
@@ -1,86 +0,0 @@
|
|||||||
<route lang="json5" type="page">
|
|
||||||
{
|
|
||||||
style: {
|
|
||||||
navigationBarTitleText: '充值记录',
|
|
||||||
navigationBarBackgroundColor: '#fff',
|
|
||||||
},
|
|
||||||
}
|
|
||||||
</route>
|
|
||||||
<template>
|
|
||||||
<view class="min-h-screen pb-100">
|
|
||||||
<template v-if="list.length">
|
|
||||||
<view
|
|
||||||
class="flex px-15 py-8 border-b border-#E5E5E5 border-b-solid"
|
|
||||||
v-for="item in list"
|
|
||||||
:key="item.id"
|
|
||||||
>
|
|
||||||
<image
|
|
||||||
v-if="getCurrentWallet(item.wall_id).wallet_crad_type === 1"
|
|
||||||
src="/static/images/invest/unionpay-icon.png"
|
|
||||||
class="w-32 h-32 self-center"
|
|
||||||
/>
|
|
||||||
<image
|
|
||||||
v-if="getCurrentWallet(item.wall_id).wallet_crad_type === 2"
|
|
||||||
src="/static/images/invest/alipay-icon.png"
|
|
||||||
class="w-32 h-32 self-center"
|
|
||||||
/>
|
|
||||||
<image
|
|
||||||
v-if="getCurrentWallet(item.wall_id).wallet_crad_type === 3"
|
|
||||||
src="/static/images/invest/wechat-icon.png"
|
|
||||||
class="w-32 h-32 self-center"
|
|
||||||
/>
|
|
||||||
<view class="flex flex-col flex-1 justify-between ml-15">
|
|
||||||
<view class="text-14 text-#333">{{ getCurrentWallet(item.wall_id).wallet_name }}</view>
|
|
||||||
<view class="text-12 text-#999">充值</view>
|
|
||||||
<view class="text-12 text-#999">{{ item.create_time }}</view>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<view class="flex flex-col items-end">
|
|
||||||
<view class="text-16 text-#FF5F5F">+{{ item.change_money }} RMB</view>
|
|
||||||
<view
|
|
||||||
class="text-14 mt-18 py-4 px-10 bg-gray-400 text-white"
|
|
||||||
v-if="item.change_status === 0"
|
|
||||||
>
|
|
||||||
充值中
|
|
||||||
</view>
|
|
||||||
<view
|
|
||||||
class="text-14 mt-18 py-4 px-10 bg-#71C78A1A text-#71C78A"
|
|
||||||
v-else-if="item.change_status === 1"
|
|
||||||
>
|
|
||||||
充值成功
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<view
|
|
||||||
class="text-14 mt-18 py-4 px-10 bg-#FF5F5F text-white"
|
|
||||||
v-else-if="item.change_status === 2"
|
|
||||||
>
|
|
||||||
充值失败
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
<template v-else>
|
|
||||||
<wd-status-tip image="content" tip="暂无数据" />
|
|
||||||
</template>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script setup lang="ts">
|
|
||||||
import { getRechargeRecordAPI, getSystemRechargeAccountAPI } from '@/service'
|
|
||||||
|
|
||||||
const { list } = useListPageRequest(getRechargeRecordAPI)
|
|
||||||
|
|
||||||
const walletList = ref<any[]>([])
|
|
||||||
onMounted(async () => {
|
|
||||||
const {
|
|
||||||
data: { list },
|
|
||||||
} = await getSystemRechargeAccountAPI({
|
|
||||||
wallet_type: 1,
|
|
||||||
})
|
|
||||||
walletList.value = list
|
|
||||||
})
|
|
||||||
|
|
||||||
const getCurrentWallet = (id: string) => {
|
|
||||||
return walletList.value.find((item) => item.id === id)
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
@@ -1,224 +0,0 @@
|
|||||||
<route lang="json5">
|
|
||||||
{
|
|
||||||
style: {
|
|
||||||
navigationStyle: 'custom',
|
|
||||||
navigationBarTitleText: '充值',
|
|
||||||
},
|
|
||||||
}
|
|
||||||
</route>
|
|
||||||
<template>
|
|
||||||
<view class="recharge-page min-h-screen pb-100">
|
|
||||||
<NavBar>
|
|
||||||
<template #right>
|
|
||||||
<image @click="onRecharge" src="/static/images/page-sub/recharge.png" class="w-24 h-24" />
|
|
||||||
</template>
|
|
||||||
</NavBar>
|
|
||||||
<view class="p-15">
|
|
||||||
<view class="mt-15">
|
|
||||||
<view class="text-14 text-#333">充值金额</view>
|
|
||||||
<view class="text-14 mt-15 text-#333 p-16 shadow-[0_0_10px_rgba(10,68,245,0.1)] rounded-10">
|
|
||||||
<input
|
|
||||||
v-model="form.change_money"
|
|
||||||
type="number"
|
|
||||||
placeholder="请输入充值金额"
|
|
||||||
class="text-14 text-#333"
|
|
||||||
/>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<view class="mt-15">
|
|
||||||
<view class="text-14 text-#333">充值方式</view>
|
|
||||||
<view class="text-14 mt-15 text-#333 p-16 shadow-[0_0_10px_rgba(10,68,245,0.1)] rounded-10">
|
|
||||||
<wd-select-picker
|
|
||||||
type="radio"
|
|
||||||
custom-class="!p-0"
|
|
||||||
custom-value-class="text-14 text-#889BC6"
|
|
||||||
class="flex-1"
|
|
||||||
placeholder="请选择充值方式"
|
|
||||||
v-model="walletType"
|
|
||||||
:columns="columns"
|
|
||||||
></wd-select-picker>
|
|
||||||
|
|
||||||
<!-- 用卡片展示收款银行信息 -->
|
|
||||||
<view class="mt-15">
|
|
||||||
<!-- 银行卡信息 -->
|
|
||||||
<view class="mt-15" v-if="walletType === 1">
|
|
||||||
<view class="mt-15 flex items-center justify-between">
|
|
||||||
<view class="text-14 text-#333">银行名称</view>
|
|
||||||
<view class="text-14 text-#889BC6">{{ currentWallet.wallet_name }}</view>
|
|
||||||
</view>
|
|
||||||
<view class="mt-15 flex items-center justify-between">
|
|
||||||
<view class="text-14 text-#333">银行账号</view>
|
|
||||||
<view class="text-14 text-#889BC6">{{ currentWallet.wallet_account }}</view>
|
|
||||||
</view>
|
|
||||||
<view class="mt-15 flex items-center justify-between">
|
|
||||||
<view class="text-14 text-#333">银行户名</view>
|
|
||||||
<view class="text-14 text-#889BC6">{{ currentWallet.wallet_username }}</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<!-- 支付宝信息 -->
|
|
||||||
<view class="mt-15" v-if="walletType === 2">
|
|
||||||
<view class="mt-15 flex items-center justify-between">
|
|
||||||
<view class="text-14 text-#333">支付宝账号</view>
|
|
||||||
<view class="text-14 text-#889BC6">{{ currentWallet.wallet_account }}</view>
|
|
||||||
</view>
|
|
||||||
<view class="mt-15 flex items-center justify-between">
|
|
||||||
<view class="text-14 text-#333">支付宝户名</view>
|
|
||||||
<view class="text-14 text-#889BC6">{{ currentWallet.wallet_username }}</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<!-- 微信信息 -->
|
|
||||||
<view class="mt-15" v-if="walletType === 3">
|
|
||||||
<view class="mt-15 flex items-center justify-between">
|
|
||||||
<view class="text-14 text-#333">微信账号</view>
|
|
||||||
<view class="text-14 text-#889BC6">{{ currentWallet.wallet_account }}</view>
|
|
||||||
</view>
|
|
||||||
<view class="mt-15 flex items-center justify-between">
|
|
||||||
<view class="text-14 text-#333">微信户名</view>
|
|
||||||
<view class="text-14 text-#889BC6">{{ currentWallet.wallet_username }}</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<view class="mt-15">
|
|
||||||
<view class="text-14 text-#333">充值账号</view>
|
|
||||||
<view class="text-14 mt-15 text-#333 p-16 shadow-[0_0_10px_rgba(10,68,245,0.1)] rounded-10">
|
|
||||||
<input
|
|
||||||
v-model="form.bank_account"
|
|
||||||
type="number"
|
|
||||||
placeholder="请输入充值账号"
|
|
||||||
class="text-14 text-#333"
|
|
||||||
/>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="mt-15">
|
|
||||||
<view class="text-14 text-#333">付款截图</view>
|
|
||||||
<view class="text-14 mt-15 text-#333 p-16 shadow-[0_0_10px_rgba(10,68,245,0.1)] rounded-10">
|
|
||||||
<view @click="handleUpload" class="text-14 text-gradient">上传截图</view>
|
|
||||||
<image
|
|
||||||
v-if="form.change_image"
|
|
||||||
mode="aspectFill"
|
|
||||||
@click="handlePreview"
|
|
||||||
class="w-100 h-100 mt-15 rounded-10"
|
|
||||||
:src="form.change_image"
|
|
||||||
/>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="fixed bottom-0 left-0 right-0 px-15 pb-safe">
|
|
||||||
<view
|
|
||||||
class="btn-gradient mb-15 text-center text-white rounded-full text-16 px-30 py-10"
|
|
||||||
@click="onSubmit"
|
|
||||||
>
|
|
||||||
提交
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script setup lang="ts">
|
|
||||||
import NavBar from '@/components/NavBar.vue'
|
|
||||||
import { getSystemRechargeAccountAPI, rechargeAPI } from '@/service'
|
|
||||||
import { mergeStep, showModal } from '@/utils'
|
|
||||||
|
|
||||||
const walletType = ref(1)
|
|
||||||
const columns = [
|
|
||||||
{
|
|
||||||
label: '银行卡',
|
|
||||||
value: 1,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
label: '支付宝',
|
|
||||||
value: 2,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
label: '微信',
|
|
||||||
value: 3,
|
|
||||||
},
|
|
||||||
]
|
|
||||||
|
|
||||||
const form = ref({
|
|
||||||
change_money: '',
|
|
||||||
bank_account: '',
|
|
||||||
change_image: '',
|
|
||||||
wall_id: '',
|
|
||||||
})
|
|
||||||
|
|
||||||
const currentWallet = ref<any>(null)
|
|
||||||
|
|
||||||
watch(
|
|
||||||
() => columns[walletType.value - 1]?.value,
|
|
||||||
async (walletCradType) => {
|
|
||||||
const {
|
|
||||||
data: { list },
|
|
||||||
} = await getSystemRechargeAccountAPI({
|
|
||||||
wallet_type: 1,
|
|
||||||
wallet_crad_type: walletCradType,
|
|
||||||
})
|
|
||||||
currentWallet.value = list[0]
|
|
||||||
form.value.wall_id = list[0].id
|
|
||||||
},
|
|
||||||
{ immediate: true },
|
|
||||||
)
|
|
||||||
|
|
||||||
const { data, run } = useUpload<any>()
|
|
||||||
const handleUpload = () => {
|
|
||||||
run()
|
|
||||||
}
|
|
||||||
|
|
||||||
watch(data, async (newVal) => {
|
|
||||||
const path = JSON.parse(newVal)?.data?.path
|
|
||||||
form.value.change_image = path
|
|
||||||
})
|
|
||||||
|
|
||||||
const onRecharge = () => {
|
|
||||||
uni.navigateTo({
|
|
||||||
url: '/pages-sub/recharge-detail/index',
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
const onSubmit = mergeStep(async () => {
|
|
||||||
if (!form.value.change_image) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '请上传付款截图',
|
|
||||||
icon: 'none',
|
|
||||||
})
|
|
||||||
return
|
|
||||||
}
|
|
||||||
if (!form.value.bank_account) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '请输入充值账号',
|
|
||||||
icon: 'none',
|
|
||||||
})
|
|
||||||
return
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!form.value.change_money) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '请输入充值金额',
|
|
||||||
icon: 'none',
|
|
||||||
})
|
|
||||||
return
|
|
||||||
}
|
|
||||||
await rechargeAPI(form.value)
|
|
||||||
await showModal('充值成功')
|
|
||||||
uni.redirectTo({
|
|
||||||
url: '/pages-sub/invest-result/index',
|
|
||||||
})
|
|
||||||
})
|
|
||||||
const handlePreview = () => {
|
|
||||||
uni.previewImage({
|
|
||||||
urls: [form.value.change_image],
|
|
||||||
})
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
|
||||||
.recharge-page {
|
|
||||||
--wot-input-placeholder-color: #889bc6;
|
|
||||||
--wot-cell-wrapper-padding: 0;
|
|
||||||
--wot-cell-padding: 0;
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
<route lang="json5" type="page">
|
<route lang="json5">
|
||||||
{
|
{
|
||||||
style: {
|
style: {
|
||||||
navigationBarTitleText: '我的邀请',
|
navigationBarTitleText: '我的邀请',
|
||||||
@@ -15,15 +15,15 @@
|
|||||||
<view @click="handleRule" class="text-14 text-#333">邀请奖励规则</view>
|
<view @click="handleRule" class="text-14 text-#333">邀请奖励规则</view>
|
||||||
</template>
|
</template>
|
||||||
</NavBar>
|
</NavBar>
|
||||||
<view class="p-15 relative bg-white rounded-10 mt-50 w-345 mx-auto">
|
<view class="px-15 py-30 relative rounded-10 mt-50 w-345 mx-auto main-content">
|
||||||
<image
|
<image
|
||||||
class="w-186 h-122 rounded-10 mt-15 mx-auto block absolute right-0 bottom-0"
|
class="w-150 h-150 rounded-10 mt-15 mx-auto block absolute right-15 bottom-30"
|
||||||
src="@/static/images/page-sub/team/team-main-hero.png"
|
src="@/static/images/page-sub/team/team-main-hero.png"
|
||||||
mode="aspectFit"
|
mode="aspectFit"
|
||||||
/>
|
/>
|
||||||
<view class="flex flex-col">
|
<view class="flex flex-col">
|
||||||
<view class="text-14 text-gradient">看看人数</view>
|
<view class="text-14 text-#6784C7">邀请人数</view>
|
||||||
<view class="text-35 font-bold text-gradient mt-10 leading-35">{{ totalCount }}</view>
|
<view class="text-35 font-bold text-#476FFF mt-10 leading-35">{{ totalCount }}</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<image
|
<image
|
||||||
@@ -41,32 +41,28 @@
|
|||||||
}"
|
}"
|
||||||
@click="() => (currentLevelIndex = index)"
|
@click="() => (currentLevelIndex = index)"
|
||||||
>
|
>
|
||||||
<image class="w-42 h-52 rounded-10 mx-auto block" :src="item.icon" mode="aspectFill" />
|
<image class="w-30 h-30 rounded-10 mx-auto block" :src="item.icon" mode="aspectFill" />
|
||||||
<view class="text-14 text-center">{{ item.title }}</view>
|
<view class="text-14 mt-10 text-center">{{ item.title }}</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="mt-25 bg-white rounded-10 w-345 mx-auto" v-if="list.length > 0">
|
<view class="mt-25 bg-white rounded-10 w-345 mx-auto" v-if="list.length">
|
||||||
<view class="flex p-15 items-center" v-for="item in list" :key="item.id">
|
<view class="flex p-15 items-center" v-for="item in list" :key="item">
|
||||||
<Avatar class="w-40 h-40" :src="item.member_portrait" />
|
<Avatar class="w-40 h-40" :src="item.avatar" />
|
||||||
<view class="flex-1 flex flex-col ml-15">
|
<view class="flex-1 flex flex-col ml-15">
|
||||||
<view class="text-14 text-#333">{{ item.nickname }}</view>
|
<view class="text-14 text-#333">{{ item.nickname }}</view>
|
||||||
<view class="text-12 mt-10 text-#999">{{ item.member_username }}</view>
|
<view class="text-12 mt-10 text-#999">{{ item.username }}</view>
|
||||||
<view class="text-12 mt-10 text-#999">{{ item.create_time }}</view>
|
<view class="text-12 mt-10 text-#999">{{ item.jointime }}</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="bg-#71C78A80 text-white text-12 rounded-10 px-10 py-5">邀请成功</view>
|
<!-- <view class="bg-#71C78A80 text-white text-12 rounded-10 px-10 py-5">邀请成功</view> -->
|
||||||
|
<view class="text-14 font-bold text-#FF5F5F">+{{ item.score }} 股</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="mt-25 bg-white rounded-10 w-345 mx-auto p-15" v-else>
|
<view class="mt-25 bg-white rounded-10 w-345 mx-auto p-15" v-else>
|
||||||
<wd-status-tip image="content" tip="暂无内容" />
|
<wd-status-tip image="content" tip="暂无内容" />
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<wd-action-sheet v-model="showRule" title="邀请奖励规则">
|
<wd-action-sheet v-model="showRule" title="邀请奖励规则">
|
||||||
<view class="text-16 text-#333 p-15">
|
<view class="text-16 text-#333 p-15">
|
||||||
<view class="mb-10">1.每邀请一人可以获得1万投资金,2000数字人民币 1点认购点</view>
|
<view class="mb-10 text-center">每邀请一人可以获得20股马尔代夫股权</view>
|
||||||
<view class="mb-10">2.邀请满5人可以额外获得5万投资金。1万数字人民币 5点认购点</view>
|
|
||||||
<view class="mb-10">3.邀请满10人可以额外获得10万投资金。2万数字人民币 10点认购点</view>
|
|
||||||
<view class="mb-10">4.邀请满20人可以额外获得20万投资金。5万数字人民币 20点认购点</view>
|
|
||||||
<view class="mb-10">5.邀请满50人可以额外获得50万投资金。10万数字人民币 50点认购点</view>
|
|
||||||
</view>
|
</view>
|
||||||
</wd-action-sheet>
|
</wd-action-sheet>
|
||||||
</view>
|
</view>
|
||||||
@@ -75,13 +71,10 @@
|
|||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import Avatar from '@/components/Avatar.vue'
|
import Avatar from '@/components/Avatar.vue'
|
||||||
import NavBar from '@/components/NavBar.vue'
|
import NavBar from '@/components/NavBar.vue'
|
||||||
import { getMyTeamAPI } from '@/service'
|
import { getMyTeamAPI, getMyTeamApi } from '@/service'
|
||||||
import Level1 from '@/static/images/page-sub/team/level-1.png'
|
import Level1 from '@/static/images/page-sub/team/level-1.png'
|
||||||
import Level2 from '@/static/images/page-sub/team/level-2.png'
|
import Level2 from '@/static/images/page-sub/team/level-2.png'
|
||||||
import Level3 from '@/static/images/page-sub/team/level-3.png'
|
import Level3 from '@/static/images/page-sub/team/level-3.png'
|
||||||
import Level4 from '@/static/images/page-sub/team/level-4.png'
|
|
||||||
import Level5 from '@/static/images/page-sub/team/level-5.png'
|
|
||||||
import Level6 from '@/static/images/page-sub/team/level-6.png'
|
|
||||||
|
|
||||||
const showRule = ref(false)
|
const showRule = ref(false)
|
||||||
|
|
||||||
@@ -106,28 +99,14 @@ const levelList = ref([
|
|||||||
icon: Level3,
|
icon: Level3,
|
||||||
level: 3,
|
level: 3,
|
||||||
},
|
},
|
||||||
{
|
|
||||||
title: '四级用户',
|
|
||||||
icon: Level4,
|
|
||||||
level: 4,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
title: '五级用户',
|
|
||||||
icon: Level5,
|
|
||||||
level: 5,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
title: '六级用户',
|
|
||||||
icon: Level6,
|
|
||||||
level: 6,
|
|
||||||
},
|
|
||||||
])
|
])
|
||||||
|
|
||||||
const totalCount = ref(0)
|
const totalCount = ref(0)
|
||||||
const { list, onReload } = useListPageRequest((...rest) => {
|
const { list, onReload } = useListPageRequest((...rest) => {
|
||||||
return getMyTeamAPI(...rest).then((res) => {
|
return getMyTeamAPI(...rest).then((res) => {
|
||||||
totalCount.value = (res.data as any).total_count
|
totalCount.value = (res.data as any).num
|
||||||
return res
|
res.data.data = res.data.list
|
||||||
|
return res.data
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
|
|
||||||
@@ -144,9 +123,15 @@ watch(
|
|||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
.team-page {
|
.team-page {
|
||||||
min-height: 100vh;
|
min-height: 100vh;
|
||||||
padding-bottom: 100rpx;
|
padding-bottom: 50px;
|
||||||
background-image: url('@/static/images/bg.png');
|
background-image: url('@/static/images/bg.png');
|
||||||
background-position: top;
|
background-position: top;
|
||||||
background-size: cover;
|
background-size: cover;
|
||||||
}
|
}
|
||||||
|
.main-content {
|
||||||
|
background-image: url('@/static/images/page-sub/team/main-bg.png');
|
||||||
|
background-repeat: no-repeat;
|
||||||
|
background-position: center;
|
||||||
|
background-size: 100% 100%;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
<route lang="json5" type="page">
|
<route lang="json5">
|
||||||
{
|
{
|
||||||
style: {
|
style: {
|
||||||
navigationBarTitleText: '提现记录',
|
navigationBarTitleText: '提现记录',
|
||||||
@@ -8,36 +8,54 @@
|
|||||||
</route>
|
</route>
|
||||||
<template>
|
<template>
|
||||||
<view class="min-h-screen pb-100">
|
<view class="min-h-screen pb-100">
|
||||||
<template v-if="list.length">
|
<template v-if="list.length > 0">
|
||||||
<view
|
<view
|
||||||
class="flex px-15 py-8 border-b border-#E5E5E5 border-b-solid"
|
class="flex px-15 py-8 border-b border-#E5E5E5 border-b-solid"
|
||||||
v-for="item in list"
|
v-for="item in list"
|
||||||
:key="item.id"
|
:key="item.id"
|
||||||
>
|
>
|
||||||
<image
|
<image
|
||||||
v-if="item.cash_type === 1"
|
|
||||||
src="/static/images/invest/unionpay-icon.png"
|
|
||||||
class="w-32 h-32 self-center"
|
|
||||||
/>
|
|
||||||
<image
|
|
||||||
v-if="item.cash_type === 2"
|
|
||||||
src="/static/images/invest/alipay-icon.png"
|
src="/static/images/invest/alipay-icon.png"
|
||||||
class="w-32 h-32 self-center"
|
class="w-32 h-32 self-center"
|
||||||
|
v-if="item.typedata === '支付宝'"
|
||||||
/>
|
/>
|
||||||
<image
|
<image
|
||||||
v-if="item.cash_type === 3"
|
|
||||||
src="/static/images/invest/wechat-icon.png"
|
src="/static/images/invest/wechat-icon.png"
|
||||||
class="w-32 h-32 self-center"
|
class="w-32 h-32 self-center"
|
||||||
|
v-if="item.typedata === '微信'"
|
||||||
/>
|
/>
|
||||||
|
<image
|
||||||
|
src="/static/images/invest/unionpay-icon.png"
|
||||||
|
class="w-32 h-32 self-center"
|
||||||
|
v-if="item.typedata === '银联'"
|
||||||
|
/>
|
||||||
|
|
||||||
<view class="flex flex-col flex-1 justify-between ml-15">
|
<view class="flex flex-col flex-1 justify-between ml-15">
|
||||||
<view class="text-14 text-#333">{{ typeName(item.cash_type) }}</view>
|
<view class="text-14 text-#333">{{ item.typedata }}</view>
|
||||||
<view class="text-12 text-#999">提现</view>
|
<view class="text-12 text-#999">提现</view>
|
||||||
<view class="text-12 text-#999">{{ item.create_time }}</view>
|
<view class="text-12 text-#999">{{ item.createtime }}</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view class="flex flex-col items-end">
|
<view class="flex flex-col items-end">
|
||||||
<view class="text-16 text-#FF5F5F">-{{ item.cash_money }} RMB</view>
|
<view class="text-16 text-#FF5F5F">{{ item.money }}</view>
|
||||||
<view class="text-14 mt-18 py-4 px-10 bg-#71C78A1A text-#71C78A">{{ item.message }}</view>
|
<view
|
||||||
|
class="text-14 mt-18 py-4 px-10 bg-#99999990 text-#fff"
|
||||||
|
v-if="Number(item.status) === 1"
|
||||||
|
>
|
||||||
|
审核中
|
||||||
|
</view>
|
||||||
|
<view
|
||||||
|
class="text-14 mt-18 py-4 px-10 bg-#71C78A1A text-#71C78A"
|
||||||
|
v-if="Number(item.status) === 2"
|
||||||
|
>
|
||||||
|
提现成功
|
||||||
|
</view>
|
||||||
|
<view
|
||||||
|
class="text-14 mt-18 py-4 px-10 bg-#FF5F5F90 text-#fff"
|
||||||
|
v-if="Number(item.status) === 3"
|
||||||
|
>
|
||||||
|
提现失败
|
||||||
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
@@ -51,8 +69,4 @@
|
|||||||
import { getWithdrawalRecordAPI } from '@/service'
|
import { getWithdrawalRecordAPI } from '@/service'
|
||||||
|
|
||||||
const { list } = useListPageRequest(getWithdrawalRecordAPI)
|
const { list } = useListPageRequest(getWithdrawalRecordAPI)
|
||||||
|
|
||||||
const typeName = (item) => {
|
|
||||||
return ['银行卡', '支付宝', '微信'][Number(item.card_type) - 1]
|
|
||||||
}
|
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@@ -18,18 +18,18 @@
|
|||||||
custom-value-class="text-14 text-#889BC6 text-right"
|
custom-value-class="text-14 text-#889BC6 text-right"
|
||||||
class="flex-1"
|
class="flex-1"
|
||||||
placeholder="请选择收款类型"
|
placeholder="请选择收款类型"
|
||||||
v-model="form.card_type"
|
v-model="form.typedata"
|
||||||
:columns="columns"
|
:columns="columns"
|
||||||
></wd-select-picker>
|
></wd-select-picker>
|
||||||
</view>
|
</view>
|
||||||
<view class="flex items-center py-15 text-14" v-if="form.card_type === 1">
|
<view class="flex items-center py-15 text-14" v-if="form.typedata === 3">
|
||||||
<view>开户行</view>
|
<view>开户行</view>
|
||||||
<input
|
<input
|
||||||
class="flex-1 text-right text-14"
|
class="flex-1 text-right text-14"
|
||||||
placeholder-class=" text-#889BC6 text-right"
|
placeholder-class=" text-#889BC6 text-right"
|
||||||
type="text"
|
type="text"
|
||||||
placeholder="请输入开户行"
|
placeholder="请输入开户行"
|
||||||
v-model="form.bank_name"
|
v-model="form.kaihuhang"
|
||||||
/>
|
/>
|
||||||
</view>
|
</view>
|
||||||
<view class="flex items-center py-15 text-14">
|
<view class="flex items-center py-15 text-14">
|
||||||
@@ -39,17 +39,17 @@
|
|||||||
placeholder-class=" text-#889BC6 text-right"
|
placeholder-class=" text-#889BC6 text-right"
|
||||||
type="text"
|
type="text"
|
||||||
:placeholder="`请输入${typeName}账号`"
|
:placeholder="`请输入${typeName}账号`"
|
||||||
v-model="form.card_account"
|
v-model="form.banknum"
|
||||||
/>
|
/>
|
||||||
</view>
|
</view>
|
||||||
<view class="flex items-center py-15 text-14">
|
<view class="flex items-center py-15 text-14">
|
||||||
<view>{{ form.card_type === 1 ? '持卡人' : '' }}姓名</view>
|
<view>{{ form.typedata === 3 ? '持卡人' : '' }}姓名</view>
|
||||||
<input
|
<input
|
||||||
class="flex-1 text-right text-14"
|
class="flex-1 text-right text-14"
|
||||||
placeholder-class=" text-#889BC6 text-right"
|
placeholder-class=" text-#889BC6 text-right"
|
||||||
type="text"
|
type="text"
|
||||||
:placeholder="`请输入${form.card_type === 1 ? '持卡人' : ''}姓名`"
|
:placeholder="`请输入${form.typedata === 3 ? '持卡人' : ''}姓名`"
|
||||||
v-model="form.card_name"
|
v-model="form.name"
|
||||||
/>
|
/>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
@@ -73,59 +73,58 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { bindBankCardAPI } from '@/service'
|
import { addBankCardAPI } from '@/service'
|
||||||
import { mergeStep, showModal } from '@/utils'
|
import { mergeStep, showModal } from '@/utils'
|
||||||
import { ref } from 'vue'
|
import { ref } from 'vue'
|
||||||
|
|
||||||
const form = ref({
|
const form = ref({
|
||||||
card_type: 1,
|
typedata: 1,
|
||||||
bank_name: '',
|
kaihuhang: '',
|
||||||
bank_address: '',
|
name: '',
|
||||||
card_name: '',
|
banknum: '',
|
||||||
card_account: '',
|
|
||||||
})
|
})
|
||||||
const columns = [
|
const columns = [
|
||||||
{
|
{
|
||||||
label: '银行卡',
|
label: '支付宝',
|
||||||
value: 1,
|
value: 1,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: '支付宝',
|
label: '微信',
|
||||||
value: 2,
|
value: 2,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: '微信',
|
label: '银行卡',
|
||||||
value: 3,
|
value: 3,
|
||||||
},
|
},
|
||||||
]
|
]
|
||||||
|
|
||||||
const typeName = computed(() => {
|
const typeName = computed(() => {
|
||||||
return ['银行卡', '支付宝', '微信'][Number(form.value.card_type) - 1]
|
return ['支付宝', '微信', '银行卡'][Number(form.value.typedata) - 1]
|
||||||
})
|
})
|
||||||
|
|
||||||
const onAddType = mergeStep(async () => {
|
const onAddType = mergeStep(async () => {
|
||||||
if (form.value.card_type === 1) {
|
if (form.value.typedata === 3) {
|
||||||
if (!form.value.bank_name) {
|
if (!form.value.kaihuhang) {
|
||||||
return uni.showToast({
|
return uni.showToast({
|
||||||
title: '请输入开户行',
|
title: '请输入开户行',
|
||||||
icon: 'none',
|
icon: 'none',
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (!form.value.card_account) {
|
if (!form.value.banknum) {
|
||||||
return uni.showToast({
|
return uni.showToast({
|
||||||
title: '请输入账号',
|
title: '请输入账号',
|
||||||
icon: 'none',
|
icon: 'none',
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
if (!form.value.card_name) {
|
if (!form.value.name) {
|
||||||
return uni.showToast({
|
return uni.showToast({
|
||||||
title: '请输入姓名',
|
title: '请输入姓名',
|
||||||
icon: 'none',
|
icon: 'none',
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
await bindBankCardAPI(form.value)
|
await addBankCardAPI(form.value)
|
||||||
await showModal('添加成功')
|
await showModal('添加成功')
|
||||||
uni.navigateBack()
|
uni.navigateBack()
|
||||||
})
|
})
|
||||||
|
|||||||
@@ -10,38 +10,46 @@
|
|||||||
<template>
|
<template>
|
||||||
<view class="withdrawal-type-page min-h-screen pb-100">
|
<view class="withdrawal-type-page min-h-screen pb-100">
|
||||||
<template v-if="list.length > 0">
|
<template v-if="list.length > 0">
|
||||||
|
<wd-swipe-action v-for="item in list" :key="item.id">
|
||||||
<view
|
<view
|
||||||
class="flex items-center justify-between py-15 text-14 shadow-[0_0_10px_rgba(10,68,245,0.1)] rounded-10 m-15 p-15"
|
class="flex items-center justify-between py-15 text-14 shadow-[0_0_10px_rgba(10,68,245,0.1)] rounded-10 m-15 p-15"
|
||||||
v-for="item in list"
|
|
||||||
:key="item.id"
|
|
||||||
@click="onSelectType(item)"
|
@click="onSelectType(item)"
|
||||||
>
|
>
|
||||||
<image
|
<image
|
||||||
v-if="Number(item.card_type) === 1"
|
v-if="Number(item.typedata) === 3"
|
||||||
class="w-45 h-45"
|
class="w-45 h-45"
|
||||||
src="@/static/images/invest/unionpay-icon.png"
|
src="@/static/images/invest/unionpay-icon.png"
|
||||||
mode="aspectFit"
|
mode="aspectFit"
|
||||||
/>
|
/>
|
||||||
<image
|
<image
|
||||||
v-if="Number(item.card_type) === 2"
|
v-if="Number(item.typedata) === 1"
|
||||||
class="w-45 h-45"
|
class="w-45 h-45"
|
||||||
src="@/static/images/invest/alipay-icon.png"
|
src="@/static/images/invest/alipay-icon.png"
|
||||||
mode="aspectFit"
|
mode="aspectFit"
|
||||||
/>
|
/>
|
||||||
<image
|
<image
|
||||||
v-if="Number(item.card_type) === 3"
|
v-if="Number(item.typedata) === 2"
|
||||||
class="w-45 h-45"
|
class="w-45 h-45"
|
||||||
src="@/static/images/invest/wechat-icon.png"
|
src="@/static/images/invest/wechat-icon.png"
|
||||||
mode="aspectFit"
|
mode="aspectFit"
|
||||||
/>
|
/>
|
||||||
<view class="flex-1 ml-15">
|
<view class="flex-1 ml-15">
|
||||||
<view class="text-16 font-bold">
|
<view class="text-16 font-bold">
|
||||||
{{ ['银行卡', '支付宝', '微信'][Number(item.card_type) - 1] }}
|
{{ ['支付宝', '微信', '银行卡'][Number(item.typedata) - 1] }}
|
||||||
</view>
|
</view>
|
||||||
<view class="mt-10 text-14 text-#889BC6">{{ item.card_account }}</view>
|
<view class="mt-10 text-14 text-#889BC6">{{ item.banknum }}</view>
|
||||||
</view>
|
</view>
|
||||||
<wd-icon name="arrow-right" size="14px"></wd-icon>
|
<wd-icon v-if="isSelect" name="arrow-right" size="14px"></wd-icon>
|
||||||
</view>
|
</view>
|
||||||
|
<template #right>
|
||||||
|
<view
|
||||||
|
class="px-15 mr-15 rounded-10 bg-#ff000040 h-full flex items-center text-14 text-red-600"
|
||||||
|
@click="onDelete(item)"
|
||||||
|
>
|
||||||
|
删除
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
</wd-swipe-action>
|
||||||
</template>
|
</template>
|
||||||
<template v-else>
|
<template v-else>
|
||||||
<wd-status-tip image="content" tip="暂无内容" />
|
<wd-status-tip image="content" tip="暂无内容" />
|
||||||
@@ -55,24 +63,25 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { getBankCardListAPI } from '@/service'
|
import { deleteBankCardAPI, getBankCardAPI } from '@/service'
|
||||||
|
import { showModal } from '@/utils'
|
||||||
import { onLoad } from '@dcloudio/uni-app'
|
import { onLoad } from '@dcloudio/uni-app'
|
||||||
|
|
||||||
let isSelect = false
|
const isSelect = ref(false)
|
||||||
onLoad((options) => {
|
onLoad((options) => {
|
||||||
if (options.type === 'select') {
|
if (options.type === 'select') {
|
||||||
isSelect = true
|
isSelect.value = true
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
const onSelectType = (item) => {
|
const onSelectType = (item) => {
|
||||||
if (isSelect) {
|
if (isSelect.value) {
|
||||||
uni.$emit('withdrawal-type', item)
|
uni.$emit('withdrawal-type', item)
|
||||||
uni.navigateBack()
|
uni.navigateBack()
|
||||||
} else {
|
} else {
|
||||||
uni.navigateTo({
|
// uni.navigateTo({
|
||||||
url: '/pages-sub/withdrawal-type/edit?id=1',
|
// url: '/pages-sub/withdrawal-type/edit?id=1',
|
||||||
})
|
// })
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -82,5 +91,24 @@ const onAddType = () => {
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
const { list } = useListPageRequest(getBankCardListAPI)
|
const onDelete = async (item) => {
|
||||||
|
await showModal('确认删除?')
|
||||||
|
await deleteBankCardAPI({
|
||||||
|
id: item.id,
|
||||||
|
})
|
||||||
|
await showModal('删除成功')
|
||||||
|
loadData()
|
||||||
|
}
|
||||||
|
|
||||||
|
const loadData = async () => {
|
||||||
|
list.value = (await getBankCardAPI({
|
||||||
|
limit: 1000,
|
||||||
|
page: 1,
|
||||||
|
}).then((res) => res.data)) as any
|
||||||
|
}
|
||||||
|
|
||||||
|
const list = ref([])
|
||||||
|
onShow(async () => {
|
||||||
|
loadData()
|
||||||
|
})
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
<route lang="json5" type="page">
|
<route lang="json5">
|
||||||
{
|
{
|
||||||
style: {
|
style: {
|
||||||
navigationStyle: 'custom',
|
navigationStyle: 'custom',
|
||||||
@@ -8,7 +8,7 @@
|
|||||||
</route>
|
</route>
|
||||||
<template>
|
<template>
|
||||||
<view class="min-h-screen pb-100">
|
<view class="min-h-screen pb-100">
|
||||||
<NavBar>
|
<NavBar title-color="#333">
|
||||||
<template #right>
|
<template #right>
|
||||||
<image
|
<image
|
||||||
@click="onWithdrawalDetail"
|
@click="onWithdrawalDetail"
|
||||||
@@ -17,65 +17,44 @@
|
|||||||
/>
|
/>
|
||||||
</template>
|
</template>
|
||||||
</NavBar>
|
</NavBar>
|
||||||
<view class="p-15">
|
<view
|
||||||
|
class="m-15 text-white flex rounded-tl-10 rounded-br-10 justify-between items-center p-15 bg-[linear-gradient(90deg,rgba(59,129,243,0.5),#3B81F3)]"
|
||||||
|
>
|
||||||
|
<view class="text-14">钱包余额</view>
|
||||||
|
<view class="text-17 font-bold">{{ userStore.userInfo?.money }}</view>
|
||||||
|
</view>
|
||||||
|
<view class="p-15 bg-white shadow-[0_-2px_3px_rgba(10,68,245,0.1)] rounded-10">
|
||||||
<view class="mt-15">
|
<view class="mt-15">
|
||||||
<view class="text-14 text-#333">提现金额</view>
|
<view class="text-14 text-#333">提现金额</view>
|
||||||
<view
|
<view
|
||||||
class="flex items-center text-14 mt-15 text-#333 p-16 shadow-[0_0_10px_rgba(10,68,245,0.1)] rounded-10"
|
class="flex items-center text-14 mt-15 text-#333 p-16 shadow-[0_0_10px_rgba(10,68,245,0.1)] rounded-10"
|
||||||
>
|
>
|
||||||
<input
|
<input
|
||||||
v-model="form.cash_money"
|
v-model="form.money"
|
||||||
type="number"
|
type="number"
|
||||||
placeholder="请输入提现金额"
|
placeholder="请输入提现金额"
|
||||||
class="text-14 text-#333 flex-1"
|
class="text-14 text-#333 flex-1"
|
||||||
/>
|
/>
|
||||||
<view
|
<view class="text-12 text-#04A9F9" @click="form.money = userStore.userInfo?.money">
|
||||||
class="text-12 text-#04A9F9"
|
|
||||||
@click="form.cash_money = Number(userStore.userInfo.member_balance ?? 0)"
|
|
||||||
>
|
|
||||||
全部
|
全部
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
<view class="text-14 text-#889BC6 mt-30">提现说明(TIPS)</view>
|
||||||
<view class="text-12 text-#889BC6 mt-15">
|
<view class="text-12 text-#889BC6 mt-15">
|
||||||
当前余额:{{ userStore.userInfo.member_balance }}
|
<view>1、如遇到系统结算繁忙,结算将会延迟到账</view>
|
||||||
</view>
|
<view class="mt-4">2、提现将会提现至您的工商银行卡;</view>
|
||||||
</view>
|
|
||||||
|
|
||||||
<view class="mt-50">
|
|
||||||
<view class="text-14 text-#333">收款方式</view>
|
|
||||||
<view
|
|
||||||
class="flex items-center text-14 mt-15 text-#333 p-16 shadow-[0_0_10px_rgba(10,68,245,0.1)] rounded-10"
|
|
||||||
@click="onSelectPayType"
|
|
||||||
>
|
|
||||||
<view class="flex-1">
|
|
||||||
{{ typeName ? `${typeName}:${currentBank?.card_account}` : '请选择收款方式' }}
|
|
||||||
</view>
|
|
||||||
<wd-icon name="arrow-right" size="16px"></wd-icon>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<view class="mt-50">
|
|
||||||
<view class="text-14 text-#333">交易密码</view>
|
|
||||||
<view class="text-14 mt-15 text-#333 p-16 shadow-[0_0_10px_rgba(10,68,245,0.1)] rounded-10">
|
|
||||||
<input
|
|
||||||
type="password"
|
|
||||||
v-model="form.pay_password"
|
|
||||||
placeholder="请输入交易密码"
|
|
||||||
class="text-14 text-#333"
|
|
||||||
/>
|
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view
|
<view
|
||||||
class="bg-white fixed bottom-0 left-0 right-0 px-15 py-10 shadow-[0_0_10px_rgba(10,68,245,0.1)]"
|
class="bg-white fixed bottom-0 left-0 right-0 px-15 py-10 shadow-[0_0_10px_rgba(10,68,245,0.1)]"
|
||||||
>
|
>
|
||||||
<view class="flex items-center pb-safe">
|
<view class="pb-safe">
|
||||||
<view class="text-gradient flex-1 text-14">到账CNY:13123.00</view>
|
|
||||||
<view
|
<view
|
||||||
class="btn-gradient text-center text-white rounded-full text-14 px-30 py-10"
|
class="btn-gradient text-center text-white rounded-full text-14 px-30 py-10"
|
||||||
@click="onSubmit"
|
@click="onSubmit"
|
||||||
>
|
>
|
||||||
申请提现
|
提现
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
@@ -84,73 +63,34 @@
|
|||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import NavBar from '@/components/NavBar.vue'
|
import NavBar from '@/components/NavBar.vue'
|
||||||
import { applyWithdrawalAPI } from '@/service'
|
import { submitWithdrawalAPI } from '@/service'
|
||||||
import { useUserStore } from '@/store'
|
import { useUserStore } from '@/store'
|
||||||
import { showModal } from '@/utils'
|
import { showModal } from '@/utils'
|
||||||
import { ref } from 'vue'
|
|
||||||
|
|
||||||
const userStore = useUserStore()
|
const userStore = useUserStore()
|
||||||
|
|
||||||
const form = ref({
|
const form = ref({
|
||||||
cash_money: 0,
|
money: '',
|
||||||
cash_remark: '',
|
|
||||||
bank_id: '',
|
|
||||||
pay_password: '',
|
|
||||||
})
|
})
|
||||||
|
|
||||||
const typeName = computed(() => {
|
|
||||||
return ['银行卡', '支付宝', '微信'][Number(unref(currentBank)?.card_type) - 1]
|
|
||||||
})
|
|
||||||
|
|
||||||
const currentBank = ref<any>(null)
|
|
||||||
|
|
||||||
const onWithdrawalDetail = () => {
|
const onWithdrawalDetail = () => {
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: '/pages-sub/withdrawal-detail/index',
|
url: '/pages-sub/withdrawal-detail/index',
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
const onSelectPayType = () => {
|
|
||||||
uni.$once('withdrawal-type', (data: any) => {
|
|
||||||
form.value.bank_id = data.id
|
|
||||||
currentBank.value = data
|
|
||||||
})
|
|
||||||
uni.navigateTo({
|
|
||||||
url: '/pages-sub/withdrawal-type/index?type=select',
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
const onSubmit = async () => {
|
const onSubmit = async () => {
|
||||||
if (!form.value.bank_id) {
|
if (!form.value.money) {
|
||||||
return uni.showToast({
|
|
||||||
title: '请选择收款方式',
|
|
||||||
icon: 'none',
|
|
||||||
})
|
|
||||||
}
|
|
||||||
if (!form.value.bank_id) {
|
|
||||||
return uni.showToast({
|
|
||||||
title: '请选择收款方式',
|
|
||||||
icon: 'none',
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!form.value.pay_password) {
|
|
||||||
return uni.showToast({
|
|
||||||
title: '请输入交易密码',
|
|
||||||
icon: 'none',
|
|
||||||
})
|
|
||||||
}
|
|
||||||
if (!form.value.cash_money) {
|
|
||||||
return uni.showToast({
|
return uni.showToast({
|
||||||
title: '请输入提现金额',
|
title: '请输入提现金额',
|
||||||
icon: 'none',
|
icon: 'none',
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
await applyWithdrawalAPI(form.value)
|
|
||||||
await showModal('申请成功')
|
await showModal('确认提现?')
|
||||||
uni.redirectTo({
|
await submitWithdrawalAPI(form.value)
|
||||||
url: '/pages-sub/invest-result/index',
|
await showModal('提交成功')
|
||||||
})
|
onWithdrawalDetail()
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|||||||
@@ -33,13 +33,13 @@
|
|||||||
"iconPath": "static/tabbar/invest.png",
|
"iconPath": "static/tabbar/invest.png",
|
||||||
"selectedIconPath": "static/tabbar/investHL.png",
|
"selectedIconPath": "static/tabbar/investHL.png",
|
||||||
"pagePath": "pages/invest/index",
|
"pagePath": "pages/invest/index",
|
||||||
"text": "投资"
|
"text": "保障"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"iconPath": "static/tabbar/house.png",
|
"iconPath": "static/tabbar/house.png",
|
||||||
"selectedIconPath": "static/tabbar/houseHL.png",
|
"selectedIconPath": "static/tabbar/houseHL.png",
|
||||||
"pagePath": "pages/house/index",
|
"pagePath": "pages/invite/index",
|
||||||
"text": "房屋"
|
"text": "社区"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"iconPath": "static/tabbar/personal.png",
|
"iconPath": "static/tabbar/personal.png",
|
||||||
@@ -65,22 +65,23 @@
|
|||||||
"navigationBarTitleText": "忘记密码",
|
"navigationBarTitleText": "忘记密码",
|
||||||
"navigationStyle": "custom"
|
"navigationStyle": "custom"
|
||||||
},
|
},
|
||||||
"notNeedLogin": false
|
"notNeedLogin": true
|
||||||
},
|
|
||||||
{
|
|
||||||
"path": "pages/house/index",
|
|
||||||
"type": "page",
|
|
||||||
"style": {
|
|
||||||
"navigationStyle": "custom",
|
|
||||||
"navigationBarTitleText": "房屋"
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"path": "pages/invest/index",
|
"path": "pages/invest/index",
|
||||||
"type": "page",
|
"type": "page",
|
||||||
"style": {
|
"style": {
|
||||||
"navigationStyle": "custom",
|
"navigationStyle": "custom",
|
||||||
"navigationBarTitleText": "投资"
|
"navigationBarTitleText": "保障"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"path": "pages/invite/index",
|
||||||
|
"type": "page",
|
||||||
|
"style": {
|
||||||
|
"navigationBarTitleText": "社区",
|
||||||
|
"navigationBarBackgroundColor": "#fff",
|
||||||
|
"navigationStyle": "custom"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -90,7 +91,7 @@
|
|||||||
"navigationBarTitleText": "登录",
|
"navigationBarTitleText": "登录",
|
||||||
"navigationStyle": "custom"
|
"navigationStyle": "custom"
|
||||||
},
|
},
|
||||||
"notNeedLogin": false
|
"notNeedLogin": true
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"path": "pages/my/index",
|
"path": "pages/my/index",
|
||||||
@@ -107,7 +108,7 @@
|
|||||||
"navigationBarTitleText": "注册",
|
"navigationBarTitleText": "注册",
|
||||||
"navigationStyle": "custom"
|
"navigationStyle": "custom"
|
||||||
},
|
},
|
||||||
"notNeedLogin": false
|
"notNeedLogin": true
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"subPackages": [
|
"subPackages": [
|
||||||
@@ -118,8 +119,26 @@
|
|||||||
"path": "asset/index",
|
"path": "asset/index",
|
||||||
"type": "page",
|
"type": "page",
|
||||||
"style": {
|
"style": {
|
||||||
"navigationBarTitleText": "我的资产",
|
"navigationBarTitleText": "资金明细",
|
||||||
"navigationBarBackgroundColor": "#fff"
|
"navigationBarBackgroundColor": "#fff",
|
||||||
|
"navigationStyle": "custom"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"path": "asset-detail/index",
|
||||||
|
"type": "page",
|
||||||
|
"style": {
|
||||||
|
"navigationBarTitleText": "资金明细",
|
||||||
|
"navigationBarBackgroundColor": "#fff",
|
||||||
|
"navigationStyle": "custom"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"path": "convert/index",
|
||||||
|
"type": "page",
|
||||||
|
"style": {
|
||||||
|
"navigationStyle": "custom",
|
||||||
|
"navigationBarTitleText": "转换"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -129,11 +148,19 @@
|
|||||||
"navigationBarTitleText": "分包页面 标题"
|
"navigationBarTitleText": "分包页面 标题"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"path": "hot-news/index",
|
||||||
|
"type": "page",
|
||||||
|
"style": {
|
||||||
|
"navigationBarTitleText": "热点新闻"
|
||||||
|
}
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"path": "introduction/index",
|
"path": "introduction/index",
|
||||||
"type": "page",
|
"type": "page",
|
||||||
"style": {
|
"style": {
|
||||||
"navigationBarTitleText": "公司简介"
|
"navigationBarTitleText": "公司简介",
|
||||||
|
"navigationBarBackgroundColor": "#fff"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -141,7 +168,8 @@
|
|||||||
"type": "page",
|
"type": "page",
|
||||||
"style": {
|
"style": {
|
||||||
"navigationBarTitleText": "投资记录",
|
"navigationBarTitleText": "投资记录",
|
||||||
"navigationBarBackgroundColor": "#fff"
|
"navigationBarBackgroundColor": "#fff",
|
||||||
|
"navigationStyle": "custom"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -156,7 +184,7 @@
|
|||||||
"path": "invest-result/index",
|
"path": "invest-result/index",
|
||||||
"type": "page",
|
"type": "page",
|
||||||
"style": {
|
"style": {
|
||||||
"navigationBarTitleText": "充值成功",
|
"navigationBarTitleText": "投资成功",
|
||||||
"navigationBarBackgroundColor": "#fff"
|
"navigationBarBackgroundColor": "#fff"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@@ -165,7 +193,25 @@
|
|||||||
"type": "page",
|
"type": "page",
|
||||||
"style": {
|
"style": {
|
||||||
"navigationBarTitleText": "邀请好友",
|
"navigationBarTitleText": "邀请好友",
|
||||||
"navigationBarBackgroundColor": "#fff"
|
"navigationBarBackgroundColor": "#fff",
|
||||||
|
"navigationStyle": "custom"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"path": "lottery/index",
|
||||||
|
"type": "page",
|
||||||
|
"style": {
|
||||||
|
"navigationBarTitleText": "转盘抽奖",
|
||||||
|
"navigationBarBackgroundColor": "#fff",
|
||||||
|
"navigationStyle": "custom"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"path": "news/index",
|
||||||
|
"type": "page",
|
||||||
|
"style": {
|
||||||
|
"navigationBarTitleText": "最新时讯",
|
||||||
|
"navigationStyle": "custom"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -185,14 +231,6 @@
|
|||||||
"navigationStyle": "custom"
|
"navigationStyle": "custom"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"path": "purchase-member/index",
|
|
||||||
"type": "page",
|
|
||||||
"style": {
|
|
||||||
"navigationBarTitleText": "购买会员",
|
|
||||||
"navigationBarBackgroundColor": "#fff"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"path": "realname/index",
|
"path": "realname/index",
|
||||||
"type": "page",
|
"type": "page",
|
||||||
@@ -201,22 +239,6 @@
|
|||||||
"navigationBarBackgroundColor": "#fff"
|
"navigationBarBackgroundColor": "#fff"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"path": "recharge/index",
|
|
||||||
"type": "page",
|
|
||||||
"style": {
|
|
||||||
"navigationStyle": "custom",
|
|
||||||
"navigationBarTitleText": "充值"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"path": "recharge-detail/index",
|
|
||||||
"type": "page",
|
|
||||||
"style": {
|
|
||||||
"navigationBarTitleText": "充值记录",
|
|
||||||
"navigationBarBackgroundColor": "#fff"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"path": "team/index",
|
"path": "team/index",
|
||||||
"type": "page",
|
"type": "page",
|
||||||
|
|||||||
@@ -1,60 +1,60 @@
|
|||||||
<route lang="json5" type="page">
|
<route lang="json5">
|
||||||
{
|
{
|
||||||
style: {
|
style: {
|
||||||
navigationBarTitleText: '忘记密码',
|
navigationBarTitleText: '忘记密码',
|
||||||
navigationStyle: 'custom',
|
navigationStyle: 'custom',
|
||||||
},
|
},
|
||||||
notNeedLogin: false,
|
notNeedLogin: true,
|
||||||
}
|
}
|
||||||
</route>
|
</route>
|
||||||
<template>
|
<template>
|
||||||
<view class="login-container relative">
|
<view class="login-container pb-50 relative">
|
||||||
<NavBar />
|
<NavBar />
|
||||||
<view class="pt-45">
|
<view class="pt-45">
|
||||||
<view class="mx-15 px-15 shadow-[0_0_10px_rgba(10,68,245,0.1)] rounded-10">
|
<view class="mx-15 px-15 shadow-[0_0_10px_rgba(10,68,245,0.1)] rounded-10">
|
||||||
<view class="flex items-center py-15">
|
<view class="flex items-center py-15">
|
||||||
<image class="w-24 h-24" src="@/static/images/login/phone.png" mode="aspectFit" />
|
<image class="w-24 h-24" src="@/static/images/login/phone.png" mode="aspectFit" />
|
||||||
<input
|
<input
|
||||||
v-model="form.member_username"
|
|
||||||
type="text"
|
type="text"
|
||||||
placeholder-class="text-#889BC6"
|
placeholder-class="text-#889BC6"
|
||||||
class="text-right flex-1 text-14"
|
class="text-right flex-1 text-14"
|
||||||
placeholder="请输入用户名"
|
placeholder="请输入用户名"
|
||||||
/>
|
/>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view class="flex items-center py-15">
|
<view class="flex items-center py-15">
|
||||||
<image class="w-24 h-24" src="@/static/images/login/password.png" mode="aspectFit" />
|
<image class="w-24 h-24" src="@/static/images/login/message.png" mode="aspectFit" />
|
||||||
<input
|
<input
|
||||||
v-model="form.old_password"
|
type="text"
|
||||||
placeholder-class="text-#889BC6"
|
placeholder-class="text-#889BC6"
|
||||||
type="password"
|
|
||||||
class="text-right flex-1 text-14"
|
class="text-right flex-1 text-14"
|
||||||
placeholder="请输入旧登录密码"
|
placeholder="请输入短信验证码"
|
||||||
/>
|
/>
|
||||||
|
<view
|
||||||
|
class="py-6 rounded-full ml-15 px-15 text-12 text-white btn-gradient text-14 text-#889BC6"
|
||||||
|
@click="handleGetCode"
|
||||||
|
>
|
||||||
|
获取验证码
|
||||||
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view class="flex items-center py-15">
|
<view class="flex items-center py-15">
|
||||||
<image class="w-24 h-24" src="@/static/images/login/password.png" mode="aspectFit" />
|
<image class="w-24 h-24" src="@/static/images/login/password.png" mode="aspectFit" />
|
||||||
<input
|
<input
|
||||||
v-model="form.member_password"
|
|
||||||
placeholder-class="text-#889BC6"
|
placeholder-class="text-#889BC6"
|
||||||
type="password"
|
type="password"
|
||||||
class="text-right flex-1 text-14"
|
class="text-right flex-1 text-14"
|
||||||
placeholder="请再次新登录密码"
|
placeholder="请输入登录密码"
|
||||||
/>
|
/>
|
||||||
</view>
|
</view>
|
||||||
<view class="flex items-center py-15">
|
<view class="flex items-center py-15">
|
||||||
<image class="w-24 h-24" src="@/static/images/login/password.png" mode="aspectFit" />
|
<image class="w-24 h-24" src="@/static/images/login/password.png" mode="aspectFit" />
|
||||||
<input
|
<input
|
||||||
v-model="form.confirm_member_password"
|
|
||||||
placeholder-class="text-#889BC6"
|
placeholder-class="text-#889BC6"
|
||||||
type="password"
|
type="password"
|
||||||
class="text-right flex-1 text-14"
|
class="text-right flex-1 text-14"
|
||||||
placeholder="请再次输入新登录密码"
|
placeholder="请再次输入登录密码"
|
||||||
/>
|
/>
|
||||||
</view>
|
</view>
|
||||||
<!-- <view class="flex items-center py-15">
|
<view class="flex items-center py-15">
|
||||||
<image class="w-24 h-24" src="@/static/images/login/password.png" mode="aspectFit" />
|
<image class="w-24 h-24" src="@/static/images/login/password.png" mode="aspectFit" />
|
||||||
<input
|
<input
|
||||||
placeholder-class="text-#889BC6"
|
placeholder-class="text-#889BC6"
|
||||||
@@ -71,22 +71,11 @@
|
|||||||
class="text-right flex-1 text-14"
|
class="text-right flex-1 text-14"
|
||||||
placeholder="请再次输入支付密码"
|
placeholder="请再次输入支付密码"
|
||||||
/>
|
/>
|
||||||
</view> -->
|
|
||||||
<view class="flex items-center py-15">
|
|
||||||
<image class="w-24 h-24" src="@/static/images/login/message.png" mode="aspectFit" />
|
|
||||||
<input
|
|
||||||
v-model="form.verify_code"
|
|
||||||
type="text"
|
|
||||||
placeholder-class="text-#889BC6"
|
|
||||||
class="text-right flex-1 text-14"
|
|
||||||
placeholder="请输入图形验证码"
|
|
||||||
/>
|
|
||||||
<image :src="codeUrl" class="ml-10 w-80 h-30" @click="handleGetCode" />
|
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view
|
<view
|
||||||
class="mt-50 text-center py-12 rounded-full mx-15 text-15 text-white btn-gradient"
|
class="mt-50 text-center py-12 rounded-full mx-15 text-15 text-white btn-gradient"
|
||||||
@click="handleUpdatePassword"
|
@click="handleRegister"
|
||||||
>
|
>
|
||||||
确认
|
确认
|
||||||
</view>
|
</view>
|
||||||
@@ -96,84 +85,23 @@
|
|||||||
|
|
||||||
<script lang="ts" setup>
|
<script lang="ts" setup>
|
||||||
import NavBar from '@/components/NavBar.vue'
|
import NavBar from '@/components/NavBar.vue'
|
||||||
import { isLogged, loginRoute } from '@/interceptors/route'
|
import { isLogged } from '@/interceptors/route'
|
||||||
import { getCodeAPI, updateUserAPI } from '@/service'
|
|
||||||
import { useUserStore } from '@/store/user'
|
import { useUserStore } from '@/store/user'
|
||||||
|
|
||||||
const userStore = useUserStore()
|
const userStore = useUserStore()
|
||||||
const form = ref({
|
|
||||||
member_username: '',
|
|
||||||
member_password: '',
|
|
||||||
confirm_member_password: '',
|
|
||||||
verify_code: '',
|
|
||||||
old_password: '',
|
|
||||||
})
|
|
||||||
|
|
||||||
let redirect = '/'
|
let redirect = '/'
|
||||||
onLoad((options) => {
|
onLoad((options) => {
|
||||||
redirect = options.redirect ?? '/'
|
redirect = options.redirect ?? '/'
|
||||||
})
|
})
|
||||||
|
|
||||||
const { codeUrl, refreshCode: handleGetCode } = useCaptcha()
|
const handleRegister = () => {
|
||||||
|
userStore.setUserInfo({
|
||||||
onLoad(async () => {
|
token: '123456',
|
||||||
if (isLogged()) {
|
})
|
||||||
uni.reLaunch({
|
uni.reLaunch({
|
||||||
url: redirect,
|
url: redirect,
|
||||||
})
|
})
|
||||||
}
|
|
||||||
})
|
|
||||||
|
|
||||||
const handleUpdatePassword = async () => {
|
|
||||||
if (!form.value.member_username) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '请输入用户名',
|
|
||||||
icon: 'none',
|
|
||||||
})
|
|
||||||
return
|
|
||||||
}
|
|
||||||
if (!form.value.old_password) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '请输入旧登录密码',
|
|
||||||
icon: 'none',
|
|
||||||
})
|
|
||||||
return
|
|
||||||
}
|
|
||||||
if (!form.value.member_password) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '请输入新登录密码',
|
|
||||||
icon: 'none',
|
|
||||||
})
|
|
||||||
return
|
|
||||||
}
|
|
||||||
if (form.value.member_password !== form.value.confirm_member_password) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '两次输入的密码不一致',
|
|
||||||
icon: 'none',
|
|
||||||
})
|
|
||||||
return
|
|
||||||
}
|
|
||||||
if (!form.value.verify_code) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '请输入图形验证码',
|
|
||||||
icon: 'none',
|
|
||||||
})
|
|
||||||
return
|
|
||||||
}
|
|
||||||
// userStore.setUserInfo({
|
|
||||||
// token: '123456',
|
|
||||||
// })
|
|
||||||
await updateUserAPI(form.value)
|
|
||||||
uni.showToast({
|
|
||||||
title: '修改密码成功',
|
|
||||||
icon: 'none',
|
|
||||||
})
|
|
||||||
uni.redirectTo({
|
|
||||||
url: loginRoute,
|
|
||||||
})
|
|
||||||
// uni.reLaunch({
|
|
||||||
// url: redirect,
|
|
||||||
// })
|
|
||||||
}
|
}
|
||||||
onLoad(() => {
|
onLoad(() => {
|
||||||
if (isLogged()) {
|
if (isLogged()) {
|
||||||
@@ -184,11 +112,10 @@ onLoad(() => {
|
|||||||
})
|
})
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="scss">
|
<style lang="scss" scoped>
|
||||||
.login-container {
|
.login-container {
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
min-height: 100vh;
|
min-height: 100vh;
|
||||||
padding-bottom: 200rpx;
|
|
||||||
background-image: url('@/static/images/login-bg.png');
|
background-image: url('@/static/images/login-bg.png');
|
||||||
background-repeat: no-repeat;
|
background-repeat: no-repeat;
|
||||||
background-size: cover;
|
background-size: cover;
|
||||||
|
|||||||
@@ -1,78 +0,0 @@
|
|||||||
<!-- 使用 type="home" 属性设置首页,其他页面不需要设置,默认为page;推荐使用json5,更强大,且允许注释 -->
|
|
||||||
<route lang="json5" type="page">
|
|
||||||
{
|
|
||||||
style: {
|
|
||||||
navigationStyle: 'custom',
|
|
||||||
navigationBarTitleText: '房屋',
|
|
||||||
},
|
|
||||||
}
|
|
||||||
</route>
|
|
||||||
<template>
|
|
||||||
<view class="house-page">
|
|
||||||
<NavBar />
|
|
||||||
<view class="p-15" v-for="cityItem in cityList" :key="cityItem.id">
|
|
||||||
<view class="text-16 pl-15">{{ cityItem.region }}</view>
|
|
||||||
<view class="mt-15 bg-white p-15 rounded-10 grid grid-cols-2 gap-15">
|
|
||||||
<view v-for="houseItem in cityItem.house_list" :key="houseItem.id">
|
|
||||||
<image class="w-150 h-170" :src="houseItem.house_image" mode="aspectFill" />
|
|
||||||
<view class="flex items-center justify-between py-10">
|
|
||||||
<view
|
|
||||||
class="text-14 bg-[linear-gradient(to_right,#3B81F3,#37E6EC)] text-transparent"
|
|
||||||
style="background-clip: text"
|
|
||||||
>
|
|
||||||
{{ houseItem.size }}平
|
|
||||||
</view>
|
|
||||||
<view class="text-12 text-#999">认购点{{ houseItem.buy_price }}点</view>
|
|
||||||
</view>
|
|
||||||
<view
|
|
||||||
class="text-12 text-center bg-[linear-gradient(to_right,#3B81F3,#37E6EC)] text-white py-8 rounded-full"
|
|
||||||
@click="handleClick(houseItem)"
|
|
||||||
>
|
|
||||||
领取
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script lang="ts" setup>
|
|
||||||
import NavBar from '@/components/NavBar.vue'
|
|
||||||
import { buyHouseAPI, getHouseListAPI } from '@/service'
|
|
||||||
import { useUserStore } from '@/store'
|
|
||||||
import { showModal } from '@/utils'
|
|
||||||
|
|
||||||
defineOptions({
|
|
||||||
name: 'Home',
|
|
||||||
})
|
|
||||||
|
|
||||||
const userStore = useUserStore()
|
|
||||||
const handleClick = async (item: any) => {
|
|
||||||
await showModal('确认领取?')
|
|
||||||
await buyHouseAPI({
|
|
||||||
house_id: item.id,
|
|
||||||
})
|
|
||||||
await userStore.loadUserInfo()
|
|
||||||
uni.showToast({
|
|
||||||
title: '领取成功',
|
|
||||||
icon: 'none',
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
const cityList = ref<any[]>([])
|
|
||||||
|
|
||||||
onMounted(async () => {
|
|
||||||
const res = await getHouseListAPI()
|
|
||||||
cityList.value = res.data.list
|
|
||||||
})
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style>
|
|
||||||
.house-page {
|
|
||||||
min-height: 100vh;
|
|
||||||
padding-bottom: 100rpx;
|
|
||||||
background-image: url('@/static/images/bg.png');
|
|
||||||
background-position: top;
|
|
||||||
background-size: cover;
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
@@ -8,79 +8,151 @@
|
|||||||
}
|
}
|
||||||
</route>
|
</route>
|
||||||
<template>
|
<template>
|
||||||
<view class="home-page">
|
<view class="home-page pb-50">
|
||||||
<NavBar />
|
<NavBar />
|
||||||
<wd-swiper
|
<template v-if="userStore.userInfo?.banknum">
|
||||||
v-if="bannerList.length"
|
<view class="main-container w-345 h-185 mx-auto rounded-14 px-20 pt-70 text-12">
|
||||||
class="w-345 bg-#ffffff30 mx-auto mt-15 rounded-10 overflow-hidden"
|
<Avatar class="absolute right-45 top-100 w-70 h-70" />
|
||||||
height="min(45.333vw, 272px)"
|
<view>姓名:{{ userStore.userInfo?.realname }}</view>
|
||||||
value-key="swipe_image"
|
<view class="mt-10">社会保障号码:{{ userStore.userInfo?.banknum.substring(0, 4) }}</view>
|
||||||
:list="bannerList"
|
<view class="mt-15">中国工商银行卡号</view>
|
||||||
autoplay
|
<view class="mt-5 text-14 text-#333">
|
||||||
@click="handleClick"
|
<!-- 每四位数字插入空格 -->
|
||||||
></wd-swiper>
|
{{ userStore.userInfo?.banknum.replace(/(\d{4})(?=\d)/g, '$1 ') }}
|
||||||
|
|
||||||
<view class="flex bg-white py-15 rounded-10 m-15">
|
|
||||||
<view class="flex-1 flex flex-col items-center" @click="handleIntroduction">
|
|
||||||
<image class="w-30 h-30" src="@/static/images/home/nav-1.png" mode="aspectFill" />
|
|
||||||
<text class="mt-8 text-14 text-#333">简介</text>
|
|
||||||
</view>
|
|
||||||
<view class="flex-1 flex flex-col items-center" @click="handleInvite">
|
|
||||||
<image class="w-30 h-30" src="@/static/images/home/nav-2.png" mode="aspectFill" />
|
|
||||||
<text class="mt-8 text-14 text-#333">邀请好友</text>
|
|
||||||
</view>
|
|
||||||
<view class="flex-1 flex flex-col items-center" @click="handleOfficialCommunity">
|
|
||||||
<image class="w-30 h-30" src="@/static/images/home/nav-3.png" mode="aspectFill" />
|
|
||||||
<text class="mt-8 text-14 text-#333">官方社群</text>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<view class="bg-white py-15 px-15 rounded-10 m-15" v-if="newsList.length">
|
|
||||||
<view class="text-14 text-#333">热点新闻</view>
|
|
||||||
<view
|
|
||||||
class="flex mt-15"
|
|
||||||
v-for="(item, index) in newsList"
|
|
||||||
:key="item"
|
|
||||||
@click="handleNewsDetail(item)"
|
|
||||||
>
|
|
||||||
<template v-if="index === 0">
|
|
||||||
<view>
|
|
||||||
<image class="w-323 h-160" :src="item.cover_image" mode="aspectFill" />
|
|
||||||
<view class="text-14 text-#000 mt-8">
|
|
||||||
{{ item.title }}
|
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
<template v-else>
|
<template v-else>
|
||||||
<image class="w-85 h-85" :src="item.cover_image" mode="aspectFill" />
|
<view class="main-container w-345 h-185 mx-auto rounded-14 px-20 pt-70 text-12">
|
||||||
<view class="ml-10 flex-1 flex flex-col justify-between">
|
<view>姓名:***</view>
|
||||||
<view text-14>{{ item.title }}</view>
|
<view class="mt-15">社会保障号码:***</view>
|
||||||
<view class="text-12 text-#999">{{ item.auther }}</view>
|
<view class="mt-15">中国工商银行卡号:**************</view>
|
||||||
|
</view>
|
||||||
|
<view
|
||||||
|
class="mt-15 btn-gradient w-345 h-45 leading-45 mx-auto text-white rounded-full text-center"
|
||||||
|
@click="handleOpenAccount"
|
||||||
|
>
|
||||||
|
开通个人养老账号
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
<view class="flex bg-white py-15 rounded-10 m-15 border-2 border-white border-solid">
|
||||||
|
<view class="flex-1 flex flex-col items-center" @click="handleInvite">
|
||||||
|
<image class="w-30 h-30" src="@/static/images/home/nav-1.png" mode="aspectFill" />
|
||||||
|
<text class="mt-8 text-14 text-#333">社区</text>
|
||||||
|
</view>
|
||||||
|
<view class="flex-1 flex flex-col items-center" @click="handleDownload">
|
||||||
|
<image class="w-30 h-30" src="@/static/images/home/nav-4.png" mode="aspectFill" />
|
||||||
|
<text class="mt-8 text-14 text-#333">下载APP</text>
|
||||||
|
</view>
|
||||||
|
<view class="flex-1 flex flex-col items-center" @click="handleOfficialCommunity">
|
||||||
|
<image class="w-30 h-30" src="@/static/images/home/nav-2.png" mode="aspectFill" />
|
||||||
|
<text class="mt-8 text-14 text-#333">官方群聊</text>
|
||||||
|
</view>
|
||||||
|
<view class="flex-1 flex flex-col items-center" @click="handleOfficialCommunity">
|
||||||
|
<image class="w-30 h-30" src="@/static/images/home/nav-3.png" mode="aspectFill" />
|
||||||
|
<text class="mt-8 text-14 text-#333">在线客服</text>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
<view class="bg-white pt-15 px-15 rounded-10 m-15">
|
||||||
|
<view class="flex justify-between items-center">
|
||||||
|
<view class="text-14 text-#333">最新时讯</view>
|
||||||
|
<!-- <view class="text-12 text-#999" @click="handleNews">查看全部</view> -->
|
||||||
|
</view>
|
||||||
|
<swiper
|
||||||
|
indicator-active-color="#3B81F3"
|
||||||
|
indicator-color="rgba(0,0,0,0.1)"
|
||||||
|
indicator-dots
|
||||||
|
autoplay
|
||||||
|
circular
|
||||||
|
class="h-240 mt-10"
|
||||||
|
>
|
||||||
|
<swiper-item v-for="item in newsList" :key="item.id">
|
||||||
|
<video class="w-full h-160" :src="item.image" mode="aspectFill" />
|
||||||
|
</swiper-item>
|
||||||
|
</swiper>
|
||||||
|
</view>
|
||||||
|
|
||||||
|
<view class="bg-white py-15 px-15 rounded-10 m-15">
|
||||||
|
<view class="flex justify-between items-center">
|
||||||
|
<view class="text-14 text-#333">热点新闻</view>
|
||||||
|
<view class="text-12 text-#999" @click="handleHotNews">查看全部</view>
|
||||||
|
</view>
|
||||||
|
<view
|
||||||
|
class="flex mt-15"
|
||||||
|
v-for="item in hotNewsList"
|
||||||
|
:key="item.id"
|
||||||
|
@click="handleNewsDetail(item.id)"
|
||||||
|
>
|
||||||
|
<image class="w-85 h-85 rounded-10" :src="item.image" mode="aspectFill" />
|
||||||
|
<view class="ml-15 flex-1 flex flex-col justify-between">
|
||||||
|
<view text-14>{{ item.name }}</view>
|
||||||
|
<view class="text-12 text-#999">{{ item.source }}</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<wd-popup :lockScroll="false" v-model="showNotice" custom-style="border-radius:0.2rem;">
|
||||||
|
<view class="px-30 py-30 w-330 h-457 notice-container rounded-20 flex flex-col">
|
||||||
|
<view class="text-18 font-bold pb-15 text-center">系统公告</view>
|
||||||
|
<view class="py-15 flex-1 overflow-y-auto">
|
||||||
|
<view
|
||||||
|
v-for="(item, index) in announcementList"
|
||||||
|
:key="item.id"
|
||||||
|
class="border-b-1 border-b-gray-300 border-b-solid py-15"
|
||||||
|
>
|
||||||
|
<view class="whitespace-nowrap text-14 font-bold text-gradient text-center">
|
||||||
|
公告{{ ['一', '二', '三', '四', '五', '六', '七', '八', '九', '十'][index] }}
|
||||||
|
</view>
|
||||||
|
<view class="mt-12 text-14 text-#333 flex-1" v-html="item.content"></view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view
|
||||||
|
@click="showNotice = false"
|
||||||
|
class="btn-gradient rounded-full text-center text-14 text-white py-8 mt-15"
|
||||||
|
>
|
||||||
|
确定
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</wd-popup>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script lang="ts" setup>
|
<script lang="ts" setup>
|
||||||
|
import Avatar from '@/components/Avatar.vue'
|
||||||
import NavBar from '@/components/NavBar.vue'
|
import NavBar from '@/components/NavBar.vue'
|
||||||
import { useListPageRequest } from '@/hooks/useListPageRequest'
|
import {
|
||||||
import { getBannerListAPI, getNewsListAPI } from '@/service'
|
downloadAppAPI,
|
||||||
|
getIntroductionAPI,
|
||||||
|
getOpenPersonalAccountAPI,
|
||||||
|
getRealNameAuthAPI,
|
||||||
|
} from '@/service'
|
||||||
|
import { useUserStore } from '@/store'
|
||||||
|
import { showModal } from '@/utils'
|
||||||
|
|
||||||
defineOptions({
|
defineOptions({
|
||||||
name: 'Home',
|
name: 'Home',
|
||||||
})
|
})
|
||||||
|
|
||||||
|
// 热门咨询
|
||||||
|
const { list: hotNewsList } = useListPageRequest((params) =>
|
||||||
|
getIntroductionAPI({ type: 1, ...params }),
|
||||||
|
)
|
||||||
|
|
||||||
const handleIntroduction = () => {
|
const handleIntroduction = () => {
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: '/pages-sub/introduction/index',
|
url: '/pages-sub/introduction/index',
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
const handleInvite = () => {
|
const handleNewsDetail = (id: number) => {
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: '/pages-sub/invite/index',
|
url: `/pages-sub/news-detail/index?id=${id}`,
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
const handleInvite = () => {
|
||||||
|
uni.switchTab({
|
||||||
|
url: '/pages/invite/index',
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -90,33 +162,70 @@ const handleOfficialCommunity = () => {
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
const handleClick = (item) => {
|
const handleDownload = () => {
|
||||||
console.log(item)
|
downloadAppAPI()
|
||||||
}
|
}
|
||||||
|
|
||||||
const bannerList = ref<any[]>([])
|
const showNotice = ref(false)
|
||||||
const { list: newsList } = useListPageRequest(getNewsListAPI)
|
|
||||||
const handleNewsDetail = (item) => {
|
const handleNews = () => {
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: `/pages-sub/news-detail/index?id=${item.id}`,
|
url: '/pages-sub/news/index',
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
onLoad(async () => {
|
const handleHotNews = () => {
|
||||||
getBannerListAPI().then((res) => {
|
uni.navigateTo({
|
||||||
bannerList.value = res.data.map((item) => ({
|
url: '/pages-sub/hot-news/index',
|
||||||
...item,
|
|
||||||
type: 'image',
|
|
||||||
}))
|
|
||||||
})
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
// 系统公告
|
||||||
|
const { list: announcementList } = useListPageRequest((params) =>
|
||||||
|
getIntroductionAPI({ type: 2, ...params }),
|
||||||
|
)
|
||||||
|
// 最新时讯
|
||||||
|
const { list: newsList } = useListPageRequest((params) =>
|
||||||
|
getIntroductionAPI({ type: 3, ...params }),
|
||||||
|
)
|
||||||
|
watch(
|
||||||
|
() => announcementList.value.length,
|
||||||
|
(newVal) => {
|
||||||
|
if (newVal > 0) {
|
||||||
|
showNotice.value = true
|
||||||
|
}
|
||||||
|
},
|
||||||
|
)
|
||||||
|
|
||||||
|
onShow(() => {
|
||||||
|
if (announcementList.value.length) {
|
||||||
|
showNotice.value = true
|
||||||
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
|
const userStore = useUserStore()
|
||||||
|
const handleOpenAccount = async () => {
|
||||||
|
await getOpenPersonalAccountAPI()
|
||||||
|
await showModal('开通个人养老账户成功')
|
||||||
|
userStore.loadUserInfo()
|
||||||
|
// showModal('开通个人养老账户时,需邀请一名用户')
|
||||||
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style>
|
<style scoped>
|
||||||
.home-page {
|
.home-page {
|
||||||
min-height: 100vh;
|
min-height: 100vh;
|
||||||
padding-bottom: 100rpx;
|
background-image: url('@/static/images/home/bg.jpg');
|
||||||
background-image: url('@/static/images/bg.png');
|
background-position: top;
|
||||||
|
background-size: cover;
|
||||||
|
}
|
||||||
|
.main-container {
|
||||||
|
background-image: url('@/static/images/home/main-bg.jpg');
|
||||||
|
background-position: top;
|
||||||
|
background-size: cover;
|
||||||
|
}
|
||||||
|
.notice-container {
|
||||||
|
background-image: url('@/static/images/home/notice-bg.jpg');
|
||||||
background-position: top;
|
background-position: top;
|
||||||
background-size: cover;
|
background-size: cover;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,61 +1,141 @@
|
|||||||
<!-- 使用 type="home" 属性设置首页,其他页面不需要设置,默认为page;推荐使用json5,更强大,且允许注释 -->
|
<!-- 使用 type="home" 属性设置首页,其他页面不需要设置,默认为page;推荐使用json5,更强大,且允许注释 -->
|
||||||
<route lang="json5" type="page">
|
<route lang="json5">
|
||||||
{
|
{
|
||||||
style: {
|
style: {
|
||||||
navigationStyle: 'custom',
|
navigationStyle: 'custom',
|
||||||
navigationBarTitleText: '投资',
|
navigationBarTitleText: '保障',
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
</route>
|
</route>
|
||||||
<template>
|
<template>
|
||||||
<view class="invest-page">
|
<view class="invest-page">
|
||||||
<NavBar>
|
<NavBar />
|
||||||
<template #right>
|
<view class="py-20 flex flex-col mx-15 rounded-20 main-content text-white">
|
||||||
<view @click="onGoInvestDetail" class="text-14 text-#486CCF">投资明细</view>
|
<view class="text-14 pl-15">保险概览</view>
|
||||||
</template>
|
<view class="flex mt-30">
|
||||||
</NavBar>
|
<view class="flex-1 text-center">
|
||||||
<view
|
<view class="text-14">全部</view>
|
||||||
class="flex shadow-[0_1px_4px_rgba(255,255,255,0.8)] mt-100 pt-12 pb-8 flex-col mx-15 rounded-10 items-center bg-[linear-gradient(180deg,rgba(212,232,255,1),rgba(229,239,249,0.8))]"
|
<view class="text-16 font-bold mt-15">
|
||||||
>
|
{{ userStore.userInfo?.yanglao + userStore.userInfo?.yiliao }}份
|
||||||
<view class="text-15 text-#486CCF">我的投资金</view>
|
</view>
|
||||||
<view class="text-30 text-#333 font-bold">{{ userStore.userInfo.member_investment }}</view>
|
</view>
|
||||||
|
<view class="flex-1 text-center">
|
||||||
|
<view class="text-14">养老</view>
|
||||||
|
<view class="text-16 font-bold mt-15">{{ userStore.userInfo?.yanglao }}份</view>
|
||||||
|
</view>
|
||||||
|
<view class="flex-1 text-center">
|
||||||
|
<view class="text-14">医疗</view>
|
||||||
|
<view class="text-16 font-bold mt-15">{{ userStore.userInfo?.yiliao }}份</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view class="mt-60">
|
<view class="flex p-15 mt-15">
|
||||||
<view
|
<view
|
||||||
v-for="item in fundList"
|
v-for="item in tabList"
|
||||||
|
:key="item.value"
|
||||||
|
class="px-24 mr-15 bg-#DEEBFF text-#3B81F3 py-4 rounded-full text-14"
|
||||||
|
:class="{ 'btn-gradient text-white': item.value === tabValue }"
|
||||||
|
@click="tabValue = item.value"
|
||||||
|
>
|
||||||
|
{{ item.title }}
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
|
||||||
|
<view>
|
||||||
|
<template v-if="tabValue === 1">
|
||||||
|
<view
|
||||||
|
v-for="item in investmentList"
|
||||||
:key="item.id"
|
:key="item.id"
|
||||||
class="invest-item relative flex flex-col items-center pt-15"
|
class="p-15 bg-white rounded-20 mx-auto w-345 relative mb-15"
|
||||||
>
|
>
|
||||||
<view class="text-15 text-#3F88F6">{{ item.fund_name }}</view>
|
<view class="flex">
|
||||||
<view class="flex w-full mt-15">
|
<image
|
||||||
<view class="flex-1 text-center">
|
class="rounded-10 w-100 h-100"
|
||||||
<view class="text-22 text-#333 font-bold">{{ item.buy_price }}</view>
|
mode="aspectFill"
|
||||||
<view class="text-12 mt-4 text-#3B81F3">投资金额</view>
|
:src="getImageUrl(item.leftimage)"
|
||||||
</view>
|
/>
|
||||||
<view class="flex-1 text-center">
|
<view class="flex-1 ml-15">
|
||||||
<view class="text-22 text-#FF3B30 font-bold">{{ item.day_income }}</view>
|
<view class="text-15 text-#333 font-bold">{{ item.name }}</view>
|
||||||
<view class="text-12 mt-4 text-#3B81F3">每日分红</view>
|
<view class="w-200 flex flex-wrap items-center mt-5">
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view
|
<view
|
||||||
class="text-center px-50 absolute bottom-0 left-0 text-12 text-#fff rounded-full py-8 bg-[linear-gradient(80deg,rgba(59,129,243,1),rgba(55,230,236,1))]"
|
class="px-14 mr-5 mb-5 py-2 whitespace-nowrap text-12 text-#D6A165 rounded-2 bg-#FFEBD4"
|
||||||
@click="onInvest(item)"
|
v-for="(tag, index) in item.labeltag.split(',')"
|
||||||
>
|
:key="tag"
|
||||||
立即投资
|
|
||||||
</view>
|
|
||||||
<view
|
|
||||||
class="text-center px-16 absolute bottom-13 right-33 text-12 text-#fff rounded-br-10 rounded-tl-10 py-4 bg-[linear-gradient(80deg,rgba(59,129,243,1),rgba(55,230,236,1))]"
|
|
||||||
:class="{
|
:class="{
|
||||||
'!bg-[linear-gradient(80deg,#E2AF74,#FFCC40)]': item.is_ai,
|
'!text-#3B81F3 !bg-#D4E8FF': index % 2 === 1,
|
||||||
'!text-#9B6F33': item.is_ai,
|
|
||||||
}"
|
}"
|
||||||
>
|
>
|
||||||
{{ item.is_ai ? '会员产品' : '新手体验' }}
|
{{ tag }}
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
<view class="text-12 mt-15 text-#999" v-html="item.content"></view>
|
||||||
</view>
|
</view>
|
||||||
<wd-action-sheet v-model="showPayType" :panels="panels" @select="onSelectPayType" />
|
</view>
|
||||||
|
<view class="flex items-center mt-15">
|
||||||
|
<view class="flex-1 text-center">
|
||||||
|
<view class="text-15 text-#FF3B30">{{ item.dividend }}(%)</view>
|
||||||
|
<view class="text-14 text-#999">日收益</view>
|
||||||
|
</view>
|
||||||
|
<view class="text-#D9D9D9">|</view>
|
||||||
|
<view class="flex-1 text-center">
|
||||||
|
<view class="text-15 text-#FF3B30">{{ item.days }}(天)</view>
|
||||||
|
<view class="text-14 text-#999">周期</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view
|
||||||
|
class="mt-15 px-30 text-center text-15 text-white rounded-full py-8 btn-gradient"
|
||||||
|
@click="onInvest(item)"
|
||||||
|
>
|
||||||
|
购买({{ item.money }}元)
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template v-else>
|
||||||
|
<view
|
||||||
|
v-for="item in investmentList"
|
||||||
|
:key="item.id"
|
||||||
|
class="p-15 bg-white rounded-20 mx-auto w-345 relative mb-15"
|
||||||
|
>
|
||||||
|
<view class="flex">
|
||||||
|
<image
|
||||||
|
class="rounded-10 w-100 h-100"
|
||||||
|
mode="aspectFill"
|
||||||
|
:src="getImageUrl(item.leftimage)"
|
||||||
|
/>
|
||||||
|
<view class="flex-1 ml-15">
|
||||||
|
<view class="text-15 text-#333 font-bold">{{ item.name }}</view>
|
||||||
|
<view class="text-12 mt-15 text-#999" v-html="item.content" />
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view
|
||||||
|
class="text-center text-15 text-white rounded-full py-8 border-#3B81F3 border-1 border-solid mt-15"
|
||||||
|
>
|
||||||
|
<text class="text-gradient" @click="onShowRights(item)">查看权益</text>
|
||||||
|
</view>
|
||||||
|
<view
|
||||||
|
class="text-center text-15 text-white rounded-full py-8 btn-gradient mt-15"
|
||||||
|
@click="onInvest(item)"
|
||||||
|
>
|
||||||
|
我要投保({{ item.money }}元)
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
</view>
|
||||||
|
<wd-popup
|
||||||
|
v-model="showRightConfig.show"
|
||||||
|
:title="`${showRightConfig.data?.name}权益`"
|
||||||
|
custom-style="border-radius: 0.2rem"
|
||||||
|
>
|
||||||
|
<view>
|
||||||
|
<image
|
||||||
|
class="w-345 h-345"
|
||||||
|
:src="getImageUrl(showRightConfig.data?.rightimage)"
|
||||||
|
mode="widthFix"
|
||||||
|
/>
|
||||||
|
</view>
|
||||||
|
</wd-popup>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@@ -64,31 +144,41 @@ import NavBar from '@/components/NavBar.vue'
|
|||||||
import AlipayIcon from '@/static/images/invest/alipay-icon.png'
|
import AlipayIcon from '@/static/images/invest/alipay-icon.png'
|
||||||
import WechatIcon from '@/static/images/invest/wechat-icon.png'
|
import WechatIcon from '@/static/images/invest/wechat-icon.png'
|
||||||
import UnionpayIcon from '@/static/images/invest/unionpay-icon.png'
|
import UnionpayIcon from '@/static/images/invest/unionpay-icon.png'
|
||||||
import { buyFundAPI, getFundListAPI } from '@/service'
|
import { getInvestmentListAPI, submitInvestAPI } from '@/service'
|
||||||
import { useUserStore } from '@/store'
|
import { useUserStore } from '@/store'
|
||||||
import { mergeStep, showModal } from '@/utils'
|
import { getImageUrl, mergeStep, showModal } from '@/utils'
|
||||||
|
|
||||||
defineOptions({
|
defineOptions({
|
||||||
name: 'Home',
|
name: 'Home',
|
||||||
})
|
})
|
||||||
|
|
||||||
const userStore = useUserStore()
|
const tabList = [
|
||||||
|
{
|
||||||
|
value: 1,
|
||||||
|
title: '养老',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
value: 2,
|
||||||
|
title: '医疗',
|
||||||
|
},
|
||||||
|
]
|
||||||
|
const tabValue = ref(1)
|
||||||
|
|
||||||
const showPayType = ref(false)
|
const { list: investmentList, onReload } = useListPageRequest((params) =>
|
||||||
const panels = ref([
|
getInvestmentListAPI({
|
||||||
{
|
...params,
|
||||||
iconUrl: WechatIcon,
|
type: tabValue.value,
|
||||||
title: '微信支付',
|
}),
|
||||||
|
)
|
||||||
|
|
||||||
|
watch(
|
||||||
|
() => tabValue.value,
|
||||||
|
() => {
|
||||||
|
onReload()
|
||||||
},
|
},
|
||||||
{
|
)
|
||||||
iconUrl: AlipayIcon,
|
|
||||||
title: '支付宝支付',
|
const userStore = useUserStore()
|
||||||
},
|
|
||||||
{
|
|
||||||
iconUrl: UnionpayIcon,
|
|
||||||
title: '银联支付',
|
|
||||||
},
|
|
||||||
])
|
|
||||||
|
|
||||||
const onGoInvestDetail = () => {
|
const onGoInvestDetail = () => {
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
@@ -96,42 +186,64 @@ const onGoInvestDetail = () => {
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
const onSelectPayType = ({ item, index }: any) => {
|
const showRightConfig = ref({
|
||||||
console.log(item, index)
|
show: false,
|
||||||
alert(item.title)
|
data: null,
|
||||||
|
})
|
||||||
|
watch(
|
||||||
|
() => showRightConfig.value.show,
|
||||||
|
(val) => {
|
||||||
|
if (!val) {
|
||||||
|
showRightConfig.value.data = null
|
||||||
|
}
|
||||||
|
},
|
||||||
|
)
|
||||||
|
const onShowRights = (item: any) => {
|
||||||
|
showRightConfig.value = {
|
||||||
|
show: true,
|
||||||
|
data: item,
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
const onInvest = mergeStep(async (item: any) => {
|
const onInvest = mergeStep(async (item: any) => {
|
||||||
await showModal('确认投资?')
|
try {
|
||||||
await buyFundAPI({
|
await submitInvestAPI({
|
||||||
fund_id: item.id,
|
investid: item.id,
|
||||||
|
type: 3,
|
||||||
})
|
})
|
||||||
|
} catch (error) {
|
||||||
|
if (error?.data?.msg.includes('邀请')) {
|
||||||
|
return uni.switchTab({
|
||||||
|
url: '/pages/invite/index',
|
||||||
|
})
|
||||||
|
}
|
||||||
|
return
|
||||||
|
}
|
||||||
await userStore.loadUserInfo()
|
await userStore.loadUserInfo()
|
||||||
uni.showToast({
|
uni.showToast({
|
||||||
title: '投资成功',
|
title: tabValue.value === 2 ? '投保成功' : '投资成功',
|
||||||
icon: 'none',
|
icon: 'none',
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
const { list: fundList } = useListPageRequest(getFundListAPI)
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style>
|
<style scoped>
|
||||||
.invest-page {
|
.invest-page {
|
||||||
min-height: 100vh;
|
min-height: 100vh;
|
||||||
padding-bottom: 100px;
|
padding-bottom: 100px;
|
||||||
background-image: url('@/static/images/invest/bg.png');
|
background-image: url('@/static/images/home/bg.jpg');
|
||||||
background-repeat: no-repeat;
|
background-position: top;
|
||||||
background-attachment: fixed;
|
background-size: cover;
|
||||||
background-position: top -80rpx center;
|
|
||||||
background-size: 100%;
|
|
||||||
}
|
}
|
||||||
.invest-item {
|
.main-content {
|
||||||
width: 690rpx;
|
background: linear-gradient(90deg, #71a4f8 0%, #3b81f3 103.83%);
|
||||||
height: 352rpx;
|
}
|
||||||
margin: 0 auto 30rpx;
|
.bg-blue-red {
|
||||||
background-image: url('@/static/images/invest/item-bg.png');
|
background-image: linear-gradient(90.02deg, #8bb9ff 0.02%, #be4343 100.27%);
|
||||||
background-repeat: no-repeat;
|
}
|
||||||
background-position: center;
|
.text-blue-red {
|
||||||
background-size: 100%;
|
background-image: linear-gradient(90.02deg, #8bb9ff 0.02%, #be4343 100.27%);
|
||||||
|
background-clip: text;
|
||||||
|
-webkit-text-fill-color: transparent;
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
@@ -0,0 +1,218 @@
|
|||||||
|
<route lang="json5">
|
||||||
|
{
|
||||||
|
style: {
|
||||||
|
navigationBarTitleText: '社区',
|
||||||
|
navigationBarBackgroundColor: '#fff',
|
||||||
|
navigationStyle: 'custom',
|
||||||
|
},
|
||||||
|
}
|
||||||
|
</route>
|
||||||
|
|
||||||
|
<script setup lang="ts">
|
||||||
|
import NavBar from '@/components/NavBar.vue'
|
||||||
|
import VueQrcode from '@chenfengyuan/vue-qrcode'
|
||||||
|
import { useUserStore } from '@/store'
|
||||||
|
import Avatar from '@/components/Avatar.vue'
|
||||||
|
import {
|
||||||
|
getCommunityInviteFirstAPI,
|
||||||
|
getCommunityInviteRewardAPI,
|
||||||
|
getCommunityMyInviteAPI,
|
||||||
|
} from '@/service'
|
||||||
|
import { showModal } from '@/utils'
|
||||||
|
|
||||||
|
const userStore = useUserStore()
|
||||||
|
|
||||||
|
const qrcodeValue =
|
||||||
|
location.origin + '/#/pages/register/index?invite=' + userStore.userInfo?.invitecode
|
||||||
|
|
||||||
|
const onCopy = (code: string) => {
|
||||||
|
uni.setClipboardData({
|
||||||
|
data: code,
|
||||||
|
})
|
||||||
|
}
|
||||||
|
const inviteData = ref({
|
||||||
|
num: 0,
|
||||||
|
performance: 0,
|
||||||
|
})
|
||||||
|
const { list } = useListPageRequest((params) => {
|
||||||
|
return getCommunityMyInviteAPI(params).then((res) => {
|
||||||
|
inviteData.value.num = res.data.num
|
||||||
|
inviteData.value.performance = res.data.performance
|
||||||
|
res.data.data = res.data.list
|
||||||
|
return res.data
|
||||||
|
})
|
||||||
|
})
|
||||||
|
|
||||||
|
const inviteInfo = ref<any>(null)
|
||||||
|
const loadInviteInfo = async () => {
|
||||||
|
const { data } = await getCommunityInviteFirstAPI()
|
||||||
|
inviteInfo.value = data
|
||||||
|
// inviteInfo.value = {
|
||||||
|
// num: 10,
|
||||||
|
// isuserauth: 1,
|
||||||
|
// realrewards: '200',
|
||||||
|
// jianglitiaojian: {
|
||||||
|
// '10': '3000',
|
||||||
|
// '20': '5000',
|
||||||
|
// '30': '15000',
|
||||||
|
// '40': '30000',
|
||||||
|
// '50': '50000',
|
||||||
|
// },
|
||||||
|
// open: 1,
|
||||||
|
// }
|
||||||
|
}
|
||||||
|
|
||||||
|
onShow(async () => {
|
||||||
|
await loadInviteInfo()
|
||||||
|
})
|
||||||
|
const taskList = computed(() => {
|
||||||
|
if (!inviteInfo.value) return []
|
||||||
|
|
||||||
|
// const inviteTask = Object.keys(inviteInfo.value.jianglitiaojian)
|
||||||
|
// const inviteTaskList = inviteTask.map((key) => ({
|
||||||
|
// title: `邀请${key}人(${inviteInfo.value.num}/${key})`,
|
||||||
|
// desc: `每月额外领取${inviteInfo.value.jianglitiaojian[key]}元社保金`,
|
||||||
|
// level: key,
|
||||||
|
// status: Number(inviteInfo.value.num) >= Number(key),
|
||||||
|
// open: false,
|
||||||
|
// }))
|
||||||
|
// // 查找最后一个完成的任务,并设置open为true
|
||||||
|
// const lastCompletedTask = inviteTaskList.findLast((item) => item.status)
|
||||||
|
// if (lastCompletedTask) {
|
||||||
|
// lastCompletedTask.open = inviteInfo.value.open
|
||||||
|
// }
|
||||||
|
return [
|
||||||
|
{
|
||||||
|
title: '注册实名',
|
||||||
|
desc: `领取${inviteInfo.value.realrewards}元社保金`,
|
||||||
|
// status: inviteInfo.value.isuserauth,
|
||||||
|
status: false,
|
||||||
|
open: false,
|
||||||
|
},
|
||||||
|
// {
|
||||||
|
// title: '签到有礼',
|
||||||
|
// desc: `每日签到送${inviteInfo.value.qiandaojiang}元社保金`,
|
||||||
|
// status: false,
|
||||||
|
// open: false,
|
||||||
|
// },
|
||||||
|
{
|
||||||
|
title: '邀请有礼',
|
||||||
|
desc: `每邀请1人并实名认证获得${inviteInfo.value.yaoqingjiang}元养老金`,
|
||||||
|
status: 0,
|
||||||
|
open: false,
|
||||||
|
},
|
||||||
|
// ...inviteTaskList,
|
||||||
|
]
|
||||||
|
})
|
||||||
|
|
||||||
|
async function onGetReward(level) {
|
||||||
|
await getCommunityInviteRewardAPI({ level })
|
||||||
|
showModal('领取成功')
|
||||||
|
await loadInviteInfo()
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<template>
|
||||||
|
<view class="pb-100 min-h-screen invite-page">
|
||||||
|
<NavBar />
|
||||||
|
<view class="flex items-center mt-228 mx-auto w-345 bg-#FFFFFFE5 p-15 rounded-20">
|
||||||
|
<view class="text-center">
|
||||||
|
<view class="mt-15 rounded-10 overflow-hidden flex bg-#FFFFFF50 p-10 shadow">
|
||||||
|
<VueQrcode
|
||||||
|
class="!w-100 !h-100 rounded-10"
|
||||||
|
:value="qrcodeValue"
|
||||||
|
:options="{ size: 200 }"
|
||||||
|
/>
|
||||||
|
</view>
|
||||||
|
<view class="text-10 text-#333 mt-4">分享二维码给好友</view>
|
||||||
|
</view>
|
||||||
|
<view class="text-center p-15">
|
||||||
|
<view class="text-14 text-#333">邀请码:{{ userStore.userInfo?.invitecode }}</view>
|
||||||
|
<view
|
||||||
|
class="mt-8 btn-gradient text-white rounded-full px-15 w-160 py-8 text-14 text-center"
|
||||||
|
@click="onCopy(userStore.userInfo?.invitecode)"
|
||||||
|
>
|
||||||
|
复制邀请码
|
||||||
|
</view>
|
||||||
|
<view
|
||||||
|
class="mt-8 btn-gradient text-white rounded-full px-15 w-160 py-8 text-14 text-center"
|
||||||
|
@click="onCopy(qrcodeValue)"
|
||||||
|
>
|
||||||
|
复制推广链接
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view class="mt-70 w-345 mx-auto">
|
||||||
|
<view
|
||||||
|
class="bg-#F3F8FF rounded-10 border-#3B81F3 border-2 border-solid p-15 flex items-start"
|
||||||
|
v-for="item of taskList"
|
||||||
|
:key="item.title"
|
||||||
|
>
|
||||||
|
<view class="flex-1">
|
||||||
|
<view class="text-15 text-#333 font-500">{{ item.title }}</view>
|
||||||
|
<view class="text-12 text-#333 mt-8">{{ item.desc }}</view>
|
||||||
|
</view>
|
||||||
|
<view>
|
||||||
|
<view
|
||||||
|
class="w-fit ml-auto mr-0 bg-#C4F7C4 rounded-4 px-10 py-4 leading-12 text-#62C162 text-12 mb-8"
|
||||||
|
v-if="item.status"
|
||||||
|
>
|
||||||
|
已完成
|
||||||
|
</view>
|
||||||
|
<view
|
||||||
|
class="w-fit ml-auto mr-0 bg-#F3CB3B33 rounded-4 px-10 py-4 leading-12 text-#FFA600 text-12"
|
||||||
|
v-if="item.open"
|
||||||
|
@click="onGetReward(item.level)"
|
||||||
|
>
|
||||||
|
领取社保金
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view class="bg-#FFFFFFE5 rounded-20 mt-30 w-345 mx-auto p-15 flex">
|
||||||
|
<view class="flex-1 text-center">
|
||||||
|
<view class="text-18 text-#333">团队人数</view>
|
||||||
|
<view class="text-gradient text-18 mt-8">{{ inviteData.num }}</view>
|
||||||
|
<view class="font-500 text-14 mt-4">直推人数</view>
|
||||||
|
</view>
|
||||||
|
<view class="flex-1 text-center">
|
||||||
|
<!-- <view class="text-18 text-#333">我的佣金</view> -->
|
||||||
|
<view class="text-18 text-#333 h-25"></view>
|
||||||
|
<view class="text-gradient text-18 mt-8">{{ inviteData.performance }}</view>
|
||||||
|
<view class="font-500 text-14 mt-4">直推业绩</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view class="mt-15 w-345 mx-auto">
|
||||||
|
<view class="ml-15 text-18 text-white">团队成员({{ inviteData.num }}/人)</view>
|
||||||
|
<view class="mt-15 bg-white px-15 pt-15 pb-4 rounded-10" v-for="item of list" :key="item.id">
|
||||||
|
<view class="flex items-center">
|
||||||
|
<Avatar :src="item.avatar" class="w-50 h-50" mode="aspectFill" />
|
||||||
|
<view class="ml-15 flex-1">
|
||||||
|
<view class="text-15 text-#333">{{ item.nickname }}</view>
|
||||||
|
<view class="text-12 text-#333 mt-10">{{ item.jointime }}</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view class="flex mt-16 py-8">
|
||||||
|
<view class="flex-1 text-center">
|
||||||
|
<view class="text-gradient">{{ item.yiliao }}</view>
|
||||||
|
<view class="text-15 text-#333">医疗(份)</view>
|
||||||
|
</view>
|
||||||
|
<view class="flex-1 text-center">
|
||||||
|
<view class="text-gradient">{{ item.yanglao }}</view>
|
||||||
|
<view class="text-15 text-#333">养老(份)</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<style lang="scss" scoped>
|
||||||
|
.invite-page {
|
||||||
|
background-color: #000139;
|
||||||
|
background-image: url('@/static/images/page-sub/invite-bg.jpg');
|
||||||
|
background-repeat: no-repeat;
|
||||||
|
background-position: top -40px center;
|
||||||
|
background-size: 100%;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
@@ -1,45 +1,62 @@
|
|||||||
<route lang="json5" type="page">
|
<route lang="json5">
|
||||||
{
|
{
|
||||||
style: {
|
style: {
|
||||||
navigationBarTitleText: '登录',
|
navigationBarTitleText: '登录',
|
||||||
navigationStyle: 'custom',
|
navigationStyle: 'custom',
|
||||||
},
|
},
|
||||||
notNeedLogin: false,
|
notNeedLogin: true,
|
||||||
}
|
}
|
||||||
</route>
|
</route>
|
||||||
<template>
|
<template>
|
||||||
<view class="login-container relative">
|
<view class="login-container relative pt-44">
|
||||||
<NavBar />
|
<!-- <NavBar title-color="#333" /> -->
|
||||||
<view
|
<!-- <view class="text-28 pl-32 text-gradient" style="-webkit-background-clip: text">登录</view> -->
|
||||||
class="mt-44 text-28 pl-32 bg-[linear-gradient(180deg,#04A9F9,#23C0CF)] text-transparent"
|
<image
|
||||||
style="-webkit-background-clip: text"
|
class="w-100 mx-auto block h-100"
|
||||||
>
|
src="@/static/images/login/logo.png"
|
||||||
登录
|
mode="aspectFit"
|
||||||
</view>
|
/>
|
||||||
<view class="pt-45">
|
<view class="pt-45">
|
||||||
<view class="mx-15 px-15 shadow-[0_0_10px_rgba(10,68,245,0.1)] rounded-10">
|
<view class="mx-15 px-15 shadow-[0_0_10px_rgba(10,68,245,0.1)] rounded-10">
|
||||||
<view class="flex items-center py-15">
|
<view class="flex items-center py-15">
|
||||||
<image class="w-24 h-24" src="@/static/images/login/phone.png" mode="aspectFit" />
|
<view class="text-gradient">手机号</view>
|
||||||
<input
|
<input
|
||||||
type="text"
|
type="text"
|
||||||
v-model="formData.member_username"
|
v-model="formData.account"
|
||||||
placeholder-class="text-#889BC6"
|
placeholder-class="text-#889BC6"
|
||||||
class="text-right flex-1 text-14"
|
class="text-right flex-1 text-14"
|
||||||
placeholder="请输入用户名"
|
placeholder="请输入手机号"
|
||||||
/>
|
/>
|
||||||
</view>
|
</view>
|
||||||
<view class="flex items-center py-15">
|
<view class="flex items-center py-15">
|
||||||
<image class="w-24 h-24" src="@/static/images/login/password.png" mode="aspectFit" />
|
<view class="text-gradient">密码</view>
|
||||||
|
|
||||||
<input
|
<input
|
||||||
placeholder-class="text-#889BC6"
|
placeholder-class="text-#889BC6"
|
||||||
type="password"
|
type="password"
|
||||||
v-model="formData.member_password"
|
v-model="formData.password"
|
||||||
class="text-right flex-1 text-14"
|
class="text-right flex-1 text-14"
|
||||||
placeholder="请输入登录密码"
|
placeholder="请输入密码"
|
||||||
|
/>
|
||||||
|
</view>
|
||||||
|
<view class="flex items-center py-15">
|
||||||
|
<view class="text-gradient">验证码</view>
|
||||||
|
<input
|
||||||
|
v-model="formData.captcha"
|
||||||
|
placeholder-class="text-#889BC6"
|
||||||
|
type="text"
|
||||||
|
class="text-right flex-1 text-14"
|
||||||
|
placeholder="请输入验证码"
|
||||||
|
/>
|
||||||
|
<img
|
||||||
|
:src="codeUrl"
|
||||||
|
class="w-100 h-30 ml-15 bg-gray-400"
|
||||||
|
mode="widthFix"
|
||||||
|
@click="refreshCode"
|
||||||
/>
|
/>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<!-- <view class="ml-auto mr-0 w-fit text-#04A9F9 text-14 p-15" @click="handleEditPassword">
|
<!-- <view class="ml-auto mr-0 w-fit text-gradient text-14 p-15" @click="handleEditPassword">
|
||||||
忘记密码
|
忘记密码
|
||||||
</view> -->
|
</view> -->
|
||||||
<view
|
<view
|
||||||
@@ -50,7 +67,7 @@
|
|||||||
</view>
|
</view>
|
||||||
<view class="mt-30 text-center text-14 text-#999">
|
<view class="mt-30 text-center text-14 text-#999">
|
||||||
没有账号?
|
没有账号?
|
||||||
<text class="text-#04A9F9" @click="handleRegister">立即注册</text>
|
<text class="text-gradient" @click="handleRegister">立即注册</text>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="absolute bottom-15 left-50% -translate-x-50% text-#999 text-14">V1.0.0</view>
|
<view class="absolute bottom-15 left-50% -translate-x-50% text-#999 text-14">V1.0.0</view>
|
||||||
@@ -60,34 +77,50 @@
|
|||||||
<script lang="ts" setup>
|
<script lang="ts" setup>
|
||||||
import NavBar from '@/components/NavBar.vue'
|
import NavBar from '@/components/NavBar.vue'
|
||||||
import { isLogged } from '@/interceptors/route'
|
import { isLogged } from '@/interceptors/route'
|
||||||
import { loginAPI } from '@/service'
|
import { loginUserAPI } from '@/service'
|
||||||
import { useUserStore } from '@/store/user'
|
import { useUserStore } from '@/store/user'
|
||||||
|
|
||||||
const userStore = useUserStore()
|
const userStore = useUserStore()
|
||||||
const formData = ref({
|
const formData = ref({
|
||||||
member_username: '',
|
account: '',
|
||||||
member_password: '',
|
password: '',
|
||||||
|
captcha: '',
|
||||||
})
|
})
|
||||||
|
|
||||||
|
const { codeUrl, t: captchaT, refreshCode } = useCaptcha()
|
||||||
|
|
||||||
let redirect = '/'
|
let redirect = '/'
|
||||||
onLoad((options) => {
|
onLoad((options) => {
|
||||||
redirect = options.redirect ?? '/'
|
redirect = options.redirect ?? '/'
|
||||||
})
|
})
|
||||||
|
onShow(refreshCode)
|
||||||
|
|
||||||
const handleLogin = async () => {
|
const handleLogin = async () => {
|
||||||
if (!formData.value.member_username || !formData.value.member_password) {
|
if (!formData.value.account || !formData.value.password) {
|
||||||
return uni.showToast({
|
return uni.showToast({
|
||||||
title: '请输入用户名和密码',
|
title: '请输入用户名和密码',
|
||||||
icon: 'none',
|
icon: 'none',
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
if (!formData.value.captcha) {
|
||||||
|
return uni.showToast({
|
||||||
|
title: '请输入验证码',
|
||||||
|
icon: 'none',
|
||||||
|
})
|
||||||
|
}
|
||||||
|
try {
|
||||||
const {
|
const {
|
||||||
data: { token },
|
data: {
|
||||||
} = await loginAPI(formData.value)
|
userinfo: { token },
|
||||||
|
},
|
||||||
|
} = await loginUserAPI({ ...formData.value, t: captchaT.value })
|
||||||
userStore.setToken(token)
|
userStore.setToken(token)
|
||||||
uni.reLaunch({
|
uni.reLaunch({
|
||||||
url: redirect,
|
url: redirect,
|
||||||
})
|
})
|
||||||
|
} catch (error) {
|
||||||
|
refreshCode()
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
const handleRegister = () => {
|
const handleRegister = () => {
|
||||||
@@ -111,11 +144,11 @@ onLoad(() => {
|
|||||||
})
|
})
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="scss">
|
<style lang="scss" scoped>
|
||||||
.login-container {
|
.login-container {
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
min-height: 100vh;
|
min-height: 100vh;
|
||||||
padding-bottom: 200rpx;
|
padding-bottom: 50px;
|
||||||
background-image: url('@/static/images/login-bg.png');
|
background-image: url('@/static/images/login-bg.png');
|
||||||
background-repeat: no-repeat;
|
background-repeat: no-repeat;
|
||||||
background-size: cover;
|
background-size: cover;
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
<route lang="json5" type="page">
|
<route lang="json5">
|
||||||
{
|
{
|
||||||
layout: 'demo',
|
layout: 'demo',
|
||||||
style: {
|
style: {
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
<route lang="json5" type="page">
|
<route lang="json5">
|
||||||
{
|
{
|
||||||
style: {
|
style: {
|
||||||
navigationStyle: 'custom',
|
navigationStyle: 'custom',
|
||||||
@@ -10,136 +10,128 @@
|
|||||||
<template>
|
<template>
|
||||||
<view class="my-page">
|
<view class="my-page">
|
||||||
<NavBar />
|
<NavBar />
|
||||||
<view class="flex flex-col items-center justify-center mt-30">
|
<view class="flex mt-50 text-white px-15 items-center">
|
||||||
<Avatar
|
<!-- <Avatar class="w-60 h-60" :src="getImageUrl(userStore.userInfo?.avatar)" /> -->
|
||||||
class="w-80 h-80 mx-auto"
|
<Avatar class="w-60 h-60" />
|
||||||
:src="userStore.userInfo?.member_portrait"
|
<view class="ml-15 flex-1">
|
||||||
@click="uploadAvatar"
|
<view class="text-16">
|
||||||
/>
|
{{ userStore.userInfo?.realname ?? userStore.userInfo?.nickname }}
|
||||||
<view class="text-16 mt-10">{{ userStore.userInfo?.member_username }}</view>
|
|
||||||
<!-- <view class="text-12 mt-8">账号:{{ userStore.userInfo?.member_username }}</view> -->
|
|
||||||
</view>
|
</view>
|
||||||
<view class="flex justify-center text-center mt-15">
|
<view class="text-12 mt-8">账号:{{ userStore.userInfo?.username }}</view>
|
||||||
<view class="">
|
|
||||||
<view class="text-30 font-bold">{{ userStore.userInfo?.member_dividend }}</view>
|
|
||||||
<view class="text-14 mt-10 text-#3B81F3">我的分红</view>
|
|
||||||
</view>
|
</view>
|
||||||
<view class="ml-30">
|
<view
|
||||||
<view class="text-30 font-bold">{{ userStore.userInfo?.member_currency }}</view>
|
class="flex border-#50D0FF border-1 border-solid items-center justify-center h-32 w-100 btn-gradient rounded-full text-center text-14 text-white"
|
||||||
<view class="text-14 mt-10 text-#3B81F3">数字人民币</view>
|
@click="handleSignIn"
|
||||||
|
>
|
||||||
|
<image class="w-30 h-26 mt-5" src="@/static/images/my/sign-icon.png" mode="widthFix" />
|
||||||
|
<view class="ml-5">签到</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view class="flex px-15 mt-15">
|
<view class="grid grid-cols-2 gap-10 px-15 mt-15">
|
||||||
|
<view class="px-15 py-10 rounded-10 bg-#FFFFFF33" @click="handleAsset(0)">
|
||||||
|
<view class="flex text-white text-12">我的余额</view>
|
||||||
|
<view class="text-20 text-gradient font-bold">{{ userStore.userInfo?.money }}</view>
|
||||||
<view
|
<view
|
||||||
class="flex py-30 justify-center items-center rounded-tl-10 rounded-br-10 flex-1 bg-[linear-gradient(180deg,#D9EBFF,#9EDAFF)] border-1 border-#5FAEFF80 border-solid"
|
class="btn-gradient w-fit rounded-full text-center text-12 text-white py-2 px-15 mt-8"
|
||||||
@click="handleWithdrawal"
|
@click.stop="handleWithdrawal"
|
||||||
>
|
|
||||||
<image class="w-40 h-40" src="@/static/images/my/withdrawal.png" mode="aspectFit" />
|
|
||||||
<view
|
|
||||||
class="text-white text-14 px-15 py-5 ml-15 rounded-full bg-[linear-gradient(45deg,#3B81F3_0%,#37E6EC_100%)]"
|
|
||||||
>
|
>
|
||||||
提现
|
提现
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<!-- <view
|
<view class="px-15 py-10 rounded-10 bg-#FFFFFF33" @click="handleAsset(2)">
|
||||||
class="ml-10 flex py-30 justify-center items-center rounded-tl-10 rounded-br-10 flex-1 bg-[linear-gradient(180deg,#D9EBFF,#9EDAFF)] border-1 border-#5FAEFF80 border-solid"
|
<view class="flex text-white text-12">养老金余额</view>
|
||||||
@click="handleWithdrawalRecord"
|
<view class="text-20 text-gradient font-bold">{{ userStore.userInfo?.moneyold }}</view>
|
||||||
>
|
|
||||||
<image class="w-40 h-40" src="@/static/images/my/top-up.png" mode="aspectFit" />
|
|
||||||
<view
|
<view
|
||||||
class="text-white text-14 px-15 py-5 ml-15 rounded-full bg-[linear-gradient(45deg,#3B81F3_0%,#37E6EC_100%)]"
|
class="btn-gradient w-fit rounded-full text-center text-12 text-white py-2 px-15 mt-8"
|
||||||
|
@click.stop="handleConvert(0)"
|
||||||
>
|
>
|
||||||
提现记录
|
转至我的余额
|
||||||
</view>
|
</view>
|
||||||
</view> -->
|
</view>
|
||||||
|
<view class="px-15 py-10 rounded-10 bg-#FFFFFF33" @click="handleAsset(1)">
|
||||||
|
<view class="flex text-white text-12">社保金余额</view>
|
||||||
|
<view class="text-20 text-gradient font-bold">{{ userStore.userInfo?.moneyjiu }}</view>
|
||||||
|
</view>
|
||||||
|
<view class="px-15 py-10 rounded-10 bg-#FFFFFF33" @click="handleAsset(3)">
|
||||||
|
<view class="flex text-white text-12">团队佣金</view>
|
||||||
|
<view class="text-20 text-gradient font-bold">{{ userStore.userInfo?.moneyyong }}</view>
|
||||||
<view
|
<view
|
||||||
class="ml-10 flex py-30 justify-center items-center rounded-tl-10 rounded-br-10 flex-1 bg-[linear-gradient(180deg,#D9EBFF,#9EDAFF)] border-1 border-#5FAEFF80 border-solid"
|
class="btn-gradient w-fit rounded-full text-center text-12 text-white py-2 px-15 mt-8"
|
||||||
@click="handleRecharge"
|
@click.stop="handleConvert(1)"
|
||||||
>
|
>
|
||||||
<image class="w-40 h-40" src="@/static/images/my/top-up.png" mode="aspectFit" />
|
转至养老金
|
||||||
<view
|
|
||||||
class="text-white text-14 px-15 py-5 ml-15 rounded-full bg-[linear-gradient(45deg,#3B81F3_0%,#37E6EC_100%)]"
|
|
||||||
>
|
|
||||||
充值
|
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
|
<view class="mt-15 rounded-30 bg-white p-15">
|
||||||
<image
|
<image
|
||||||
class="w-330 h-123 mx-auto mt-15 block"
|
class="w-345 h-146 mx-auto block"
|
||||||
src="@/static/images/my/recommend.png"
|
src="@/static/images/my/recommend.jpg"
|
||||||
mode="aspectFill"
|
mode="widthFix"
|
||||||
@click="handlePurchaseMember"
|
@click="handleInvite"
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<view class="mt-15 grid grid-cols-2 gap-10 p-15">
|
<view class="mt-15 grid grid-cols-2 gap-10">
|
||||||
<view
|
<view
|
||||||
@click="handleTeam"
|
@click="item.handle"
|
||||||
class="flex justify-center rounded-tl-10 rounded-br-10 bg-[linear-gradient(45deg,#EFF7FF,#D1E8FF)] p-15 border border-#BEDCFF border-solid"
|
class="flex items-center justify-center rounded-tl-10 rounded-br-10 bg-[linear-gradient(45deg,#EFF7FF,#D1E8FF)] p-15 border border-#BEDCFF border-solid"
|
||||||
|
v-for="item in commonList"
|
||||||
|
:key="item.title"
|
||||||
>
|
>
|
||||||
<image class="w-24 h-24" src="@/static/images/my/team.png" mode="aspectFit" />
|
<image class="w-24 h-24" :src="item.icon" mode="aspectFit" />
|
||||||
<view class="text-14 text-#333 ml-10">我的邀请</view>
|
<view class="text-14 text-#333 ml-10">{{ item.title }}</view>
|
||||||
</view>
|
|
||||||
<view
|
|
||||||
@click="handleAsset"
|
|
||||||
class="flex justify-center rounded-tl-10 rounded-br-10 bg-[linear-gradient(45deg,#EFF7FF,#D1E8FF)] p-15 border border-#BEDCFF border-solid"
|
|
||||||
>
|
|
||||||
<image class="w-24 h-24" src="@/static/images/my/house.png" mode="aspectFit" />
|
|
||||||
<view class="text-14 text-#333 ml-10">我的资产</view>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<view
|
|
||||||
@click="handleRealName"
|
|
||||||
class="flex justify-center rounded-tl-10 rounded-br-10 bg-[linear-gradient(45deg,#EFF7FF,#D1E8FF)] p-15 border border-#BEDCFF border-solid"
|
|
||||||
>
|
|
||||||
<image class="w-24 h-24" src="@/static/images/my/realname.png" mode="aspectFit" />
|
|
||||||
<view class="text-14 text-#333 ml-10">实名认证</view>
|
|
||||||
</view>
|
|
||||||
<view
|
|
||||||
@click="handleBankCard"
|
|
||||||
class="flex justify-center rounded-tl-10 rounded-br-10 bg-[linear-gradient(45deg,#EFF7FF,#D1E8FF)] p-15 border border-#BEDCFF border-solid"
|
|
||||||
>
|
|
||||||
<image class="w-24 h-24" src="@/static/images/my/kefu.png" mode="aspectFit" />
|
|
||||||
<view class="text-14 text-#333 ml-10">我的银行卡</view>
|
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view
|
<view
|
||||||
class="mt-50 mx-auto w-294 bg-[linear-gradient(45deg,#3B81F3,#37E6EC)] rounded-full text-center text-14 text-white py-15 mt-15"
|
class="mt-50 mx-auto w-294 btn-gradient rounded-full text-center text-14 text-white py-15 mt-15"
|
||||||
@click="handleLogout"
|
@click="handleLogout"
|
||||||
>
|
>
|
||||||
退出登录
|
退出登录
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script lang="ts" setup>
|
<script lang="ts" setup>
|
||||||
import Avatar from '@/components/Avatar.vue'
|
import Avatar from '@/components/Avatar.vue'
|
||||||
import NavBar from '@/components/NavBar.vue'
|
import NavBar from '@/components/NavBar.vue'
|
||||||
import { loginRoute } from '@/interceptors/route'
|
import { loginRoute } from '@/interceptors/route'
|
||||||
import { logoutAPI, updateUserAPI } from '@/service'
|
import { downloadAppAPI, getCommunityInviteFirstAPI, getSignInAPI } from '@/service'
|
||||||
import { useUserStore } from '@/store/user'
|
import { useUserStore } from '@/store/user'
|
||||||
|
import { getImageUrl, showModal } from '@/utils'
|
||||||
|
|
||||||
|
import CommonIcon1 from '@/static/images/my/common-icon-1.png'
|
||||||
|
import CommonIcon2 from '@/static/images/my/common-icon-2.png'
|
||||||
|
import CommonIcon3 from '@/static/images/my/common-icon-3.png'
|
||||||
|
import CommonIcon4 from '@/static/images/my/common-icon-4.png'
|
||||||
|
import CommonIcon5 from '@/static/images/my/common-icon-5.png'
|
||||||
|
import CommonIcon6 from '@/static/images/my/common-icon-6.png'
|
||||||
|
import CommonIcon7 from '@/static/images/my/common-icon-7.png'
|
||||||
|
import CommonIcon8 from '@/static/images/my/common-icon-8.png'
|
||||||
|
import CommonIcon9 from '@/static/images/my/common-icon-9.png'
|
||||||
|
|
||||||
const userStore = useUserStore()
|
const userStore = useUserStore()
|
||||||
|
|
||||||
const handleLogout = async () => {
|
const handleLogout = () => {
|
||||||
logoutAPI()
|
|
||||||
userStore.logout()
|
userStore.logout()
|
||||||
uni.reLaunch({
|
uni.reLaunch({
|
||||||
url: loginRoute,
|
url: loginRoute,
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
const handleRecharge = () => {
|
const handleWithdrawalDetail = () => {
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: '/pages-sub/recharge/index',
|
url: '/pages-sub/withdrawal-detail/index',
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
const handleWithdrawal = () => {
|
const handleWithdrawal = () => {
|
||||||
uni.navigateTo({
|
return showModal('暂未开放')
|
||||||
url: '/pages-sub/withdrawal/index',
|
// uni.navigateTo({
|
||||||
})
|
// url: '/pages-sub/withdrawal/index',
|
||||||
|
// })
|
||||||
}
|
}
|
||||||
|
|
||||||
const handleTeam = () => {
|
const handleTeam = () => {
|
||||||
@@ -154,9 +146,15 @@ const handleRealName = () => {
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
const handleAsset = () => {
|
const handleAsset = (index = 0) => {
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: '/pages-sub/asset/index',
|
url: `/pages-sub/asset/index?tabIndex=${index}`,
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
const handleAssetDetail = () => {
|
||||||
|
uni.navigateTo({
|
||||||
|
url: '/pages-sub/asset-detail/index',
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -166,38 +164,88 @@ const handleBankCard = () => {
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
const handlePurchaseMember = () => {
|
const handleInvite = () => {
|
||||||
|
uni.switchTab({
|
||||||
|
url: '/pages/invite/index',
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
const handleConvert = (type) => {
|
||||||
|
if (type === 0) {
|
||||||
|
return showModal('提前申请领取养老金')
|
||||||
|
}
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: '/pages-sub/purchase-member/index',
|
url: `/pages-sub/convert/index?type=${type}`,
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
const handleWithdrawalRecord = () => {
|
const handleSignIn = async () => {
|
||||||
uni.navigateTo({
|
await getSignInAPI()
|
||||||
url: '/pages-sub/withdrawal-detail/index',
|
const { data } = await getCommunityInviteFirstAPI()
|
||||||
})
|
if (data.qiandaojiang) {
|
||||||
}
|
showModal('签到成功,获得' + data.qiandaojiang + '元社保金')
|
||||||
|
} else {
|
||||||
const { data, run } = useUpload<any>()
|
showModal('签到成功')
|
||||||
const uploadAvatar = () => {
|
}
|
||||||
run()
|
|
||||||
}
|
|
||||||
|
|
||||||
watch(data, async (newVal) => {
|
|
||||||
const path = JSON.parse(newVal)?.data?.path
|
|
||||||
await updateUserAPI({
|
|
||||||
member_portrait: path,
|
|
||||||
})
|
|
||||||
userStore.loadUserInfo()
|
userStore.loadUserInfo()
|
||||||
})
|
}
|
||||||
|
|
||||||
|
const handleKefu = () => {
|
||||||
|
uni.navigateTo({
|
||||||
|
url: '/pages-sub/official-community/index',
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
const handleInvestDetail = () => {
|
||||||
|
uni.navigateTo({
|
||||||
|
url: '/pages-sub/invest-detail/index',
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
const commonList = [
|
||||||
|
{
|
||||||
|
title: '投保记录',
|
||||||
|
icon: CommonIcon5,
|
||||||
|
handle: handleInvestDetail,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title: '资金明细',
|
||||||
|
icon: CommonIcon6,
|
||||||
|
handle: handleAssetDetail,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title: '申请理赔',
|
||||||
|
icon: CommonIcon7,
|
||||||
|
handle: handleKefu,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title: '我的社区',
|
||||||
|
icon: CommonIcon4,
|
||||||
|
handle: handleInvite,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title: '在线客服',
|
||||||
|
icon: CommonIcon9,
|
||||||
|
handle: handleKefu,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title: 'APP下载',
|
||||||
|
icon: CommonIcon3,
|
||||||
|
handle: downloadAppAPI,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title: '官方群聊',
|
||||||
|
icon: CommonIcon1,
|
||||||
|
handle: handleKefu,
|
||||||
|
},
|
||||||
|
]
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
.my-page {
|
.my-page {
|
||||||
min-height: 100vh;
|
min-height: 100vh;
|
||||||
padding-bottom: 100rpx;
|
background-image: url('@/static/images/my/my-bg.jpg');
|
||||||
background-image: url('@/static/images/bg.png');
|
background-position: top -40px center;
|
||||||
background-position: top;
|
|
||||||
background-size: cover;
|
background-size: cover;
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
@@ -4,28 +4,108 @@
|
|||||||
navigationBarTitleText: '注册',
|
navigationBarTitleText: '注册',
|
||||||
navigationStyle: 'custom',
|
navigationStyle: 'custom',
|
||||||
},
|
},
|
||||||
notNeedLogin: false,
|
notNeedLogin: true,
|
||||||
}
|
}
|
||||||
</route>
|
</route>
|
||||||
|
|
||||||
|
<script lang="ts" setup>
|
||||||
|
import NavBar from '@/components/NavBar.vue'
|
||||||
|
import { isLogged } from '@/interceptors/route'
|
||||||
|
import { registerUserAPI } from '@/service'
|
||||||
|
import { useUserStore } from '@/store/user'
|
||||||
|
import { mergeStep } from '@/utils'
|
||||||
|
|
||||||
|
const userStore = useUserStore()
|
||||||
|
const form = ref({
|
||||||
|
username: '',
|
||||||
|
// member_nickname: '',
|
||||||
|
password: '',
|
||||||
|
retpassword: '',
|
||||||
|
invitecode: '',
|
||||||
|
// tpassword: '',
|
||||||
|
// rettpassword: '',
|
||||||
|
})
|
||||||
|
|
||||||
|
let redirect = '/'
|
||||||
|
onLoad((options) => {
|
||||||
|
redirect = options.redirect ?? '/'
|
||||||
|
form.value.invitecode = options.invitecode ?? ''
|
||||||
|
})
|
||||||
|
|
||||||
|
const handleRegister = mergeStep(async () => {
|
||||||
|
if (!/^\d{11}$/.test(form.value.username)) {
|
||||||
|
uni.showToast({
|
||||||
|
title: '请输入正确手机号(11位)',
|
||||||
|
icon: 'none',
|
||||||
|
})
|
||||||
|
return
|
||||||
|
}
|
||||||
|
if (!form.value.password) {
|
||||||
|
uni.showToast({
|
||||||
|
title: '请输入登录密码',
|
||||||
|
icon: 'none',
|
||||||
|
})
|
||||||
|
return
|
||||||
|
}
|
||||||
|
if (form.value.password !== form.value.retpassword) {
|
||||||
|
uni.showToast({
|
||||||
|
title: '两次输入的密码不一致',
|
||||||
|
icon: 'none',
|
||||||
|
})
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!form.value.invitecode) {
|
||||||
|
uni.showToast({
|
||||||
|
title: '请输入邀请码',
|
||||||
|
icon: 'none',
|
||||||
|
})
|
||||||
|
return
|
||||||
|
}
|
||||||
|
const {
|
||||||
|
data: {
|
||||||
|
userinfo: { token },
|
||||||
|
},
|
||||||
|
} = await registerUserAPI(form.value)
|
||||||
|
userStore.setToken(token)
|
||||||
|
uni.reLaunch({
|
||||||
|
url: redirect,
|
||||||
|
})
|
||||||
|
})
|
||||||
|
onLoad(async (options) => {
|
||||||
|
if (isLogged()) {
|
||||||
|
uni.reLaunch({
|
||||||
|
url: redirect,
|
||||||
|
})
|
||||||
|
}
|
||||||
|
form.value.invitecode = options.invite ?? ''
|
||||||
|
})
|
||||||
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
<view class="login-container relative">
|
<view class="login-container relative">
|
||||||
<NavBar />
|
<NavBar />
|
||||||
|
<image
|
||||||
|
class="mt-30 w-86 rounded-full mx-auto block h-86"
|
||||||
|
src="@/static/images/login/logo.png"
|
||||||
|
mode="aspectFit"
|
||||||
|
/>
|
||||||
<view class="pt-45">
|
<view class="pt-45">
|
||||||
<view class="mx-15 px-15 shadow-[0_0_10px_rgba(10,68,245,0.1)] rounded-10">
|
<view class="mx-15 bg-white px-15 shadow-[0_0_10px_rgba(10,68,245,0.1)] rounded-10">
|
||||||
<view class="flex items-center py-15">
|
<view class="flex items-center py-15">
|
||||||
<image class="w-24 h-24" src="@/static/images/login/phone.png" mode="aspectFit" />
|
<view class="text-gradient">手机号</view>
|
||||||
<input
|
<input
|
||||||
v-model="form.member_username"
|
v-model="form.username"
|
||||||
type="text"
|
type="text"
|
||||||
placeholder-class="text-#889BC6"
|
placeholder-class="text-#889BC6"
|
||||||
class="text-right flex-1 text-14"
|
class="text-right flex-1 text-14"
|
||||||
placeholder="请输入用户名"
|
placeholder="请输入手机号"
|
||||||
/>
|
/>
|
||||||
</view>
|
</view>
|
||||||
<view class="flex items-center py-15">
|
<view class="flex items-center py-15">
|
||||||
<image class="w-24 h-24" src="@/static/images/login/password.png" mode="aspectFit" />
|
<view class="text-gradient">登录密码</view>
|
||||||
<input
|
<input
|
||||||
v-model="form.member_password"
|
v-model="form.password"
|
||||||
placeholder-class="text-#889BC6"
|
placeholder-class="text-#889BC6"
|
||||||
type="password"
|
type="password"
|
||||||
class="text-right flex-1 text-14"
|
class="text-right flex-1 text-14"
|
||||||
@@ -33,56 +113,36 @@
|
|||||||
/>
|
/>
|
||||||
</view>
|
</view>
|
||||||
<view class="flex items-center py-15">
|
<view class="flex items-center py-15">
|
||||||
<image class="w-24 h-24" src="@/static/images/login/password.png" mode="aspectFit" />
|
<view class="text-gradient">确认登录密码</view>
|
||||||
<input
|
<input
|
||||||
v-model="form.confirm_member_password"
|
v-model="form.retpassword"
|
||||||
placeholder-class="text-#889BC6"
|
placeholder-class="text-#889BC6"
|
||||||
type="password"
|
type="password"
|
||||||
class="text-right flex-1 text-14"
|
class="text-right flex-1 text-14"
|
||||||
placeholder="请再次输入登录密码"
|
placeholder="请再次输入登录密码"
|
||||||
/>
|
/>
|
||||||
</view>
|
</view>
|
||||||
<view class="flex items-center py-15">
|
<!-- <view class="flex items-center py-15">
|
||||||
<image class="w-24 h-24" src="@/static/images/login/password.png" mode="aspectFit" />
|
<view class="text-gradient">验证码</view>
|
||||||
<input
|
<input
|
||||||
v-model="form.pay_password"
|
v-model="form.invitecode"
|
||||||
placeholder-class="text-#889BC6"
|
placeholder-class="text-#889BC6"
|
||||||
type="password"
|
type="text"
|
||||||
class="text-right flex-1 text-14"
|
class="text-right flex-1 text-14"
|
||||||
placeholder="请输入支付密码"
|
placeholder="请输入验证码"
|
||||||
/>
|
/>
|
||||||
</view>
|
<image class="w-60 h-24 ml-15 bg-gray-400" mode="aspectFit" />
|
||||||
|
</view> -->
|
||||||
<view class="flex items-center py-15">
|
<view class="flex items-center py-15">
|
||||||
<image class="w-24 h-24" src="@/static/images/login/password.png" mode="aspectFit" />
|
<view class="text-gradient">邀请码</view>
|
||||||
<input
|
<input
|
||||||
v-model="form.confirm_pay_password"
|
v-model="form.invitecode"
|
||||||
placeholder-class="text-#889BC6"
|
|
||||||
type="password"
|
|
||||||
class="text-right flex-1 text-14"
|
|
||||||
placeholder="请再次输入支付密码"
|
|
||||||
/>
|
|
||||||
</view>
|
|
||||||
<view class="flex items-center py-15">
|
|
||||||
<image class="w-24 h-24" src="@/static/images/login/invite.png" mode="aspectFit" />
|
|
||||||
<input
|
|
||||||
v-model="form.invitation_code"
|
|
||||||
placeholder-class="text-#889BC6"
|
placeholder-class="text-#889BC6"
|
||||||
type="text"
|
type="text"
|
||||||
class="text-right flex-1 text-14"
|
class="text-right flex-1 text-14"
|
||||||
placeholder="请输入邀请码"
|
placeholder="请输入邀请码"
|
||||||
/>
|
/>
|
||||||
</view>
|
</view>
|
||||||
<view class="flex items-center py-15">
|
|
||||||
<image class="w-24 h-24" src="@/static/images/login/message.png" mode="aspectFit" />
|
|
||||||
<input
|
|
||||||
v-model="form.verify_code"
|
|
||||||
type="text"
|
|
||||||
placeholder-class="text-#889BC6"
|
|
||||||
class="text-right flex-1 text-14"
|
|
||||||
placeholder="请输入图形验证码"
|
|
||||||
/>
|
|
||||||
<image :src="codeUrl" class="ml-10 w-80 h-30" @click="handleGetCode" />
|
|
||||||
</view>
|
|
||||||
</view>
|
</view>
|
||||||
<view
|
<view
|
||||||
class="mt-50 text-center py-12 rounded-full mx-15 text-15 text-white btn-gradient"
|
class="mt-50 text-center py-12 rounded-full mx-15 text-15 text-white btn-gradient"
|
||||||
@@ -94,109 +154,12 @@
|
|||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script lang="ts" setup>
|
<style lang="scss" scoped>
|
||||||
import NavBar from '@/components/NavBar.vue'
|
|
||||||
import { isLogged } from '@/interceptors/route'
|
|
||||||
import { registerAPI } from '@/service'
|
|
||||||
import { useUserStore } from '@/store/user'
|
|
||||||
import { mergeStep } from '@/utils'
|
|
||||||
|
|
||||||
const userStore = useUserStore()
|
|
||||||
const form = ref({
|
|
||||||
member_username: '',
|
|
||||||
// member_nickname: '',
|
|
||||||
member_password: '',
|
|
||||||
confirm_member_password: '',
|
|
||||||
verify_code: '',
|
|
||||||
invitation_code: '',
|
|
||||||
pay_password: '',
|
|
||||||
confirm_pay_password: '',
|
|
||||||
})
|
|
||||||
|
|
||||||
let redirect = '/'
|
|
||||||
onLoad((options) => {
|
|
||||||
redirect = options.redirect ?? '/'
|
|
||||||
form.value.invitation_code = options.invitation_code ?? ''
|
|
||||||
})
|
|
||||||
|
|
||||||
const handleRegister = mergeStep(async () => {
|
|
||||||
if (!form.value.member_username) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '请输入用户名',
|
|
||||||
icon: 'none',
|
|
||||||
})
|
|
||||||
return
|
|
||||||
}
|
|
||||||
if (!form.value.verify_code) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '请输入图形验证码',
|
|
||||||
icon: 'none',
|
|
||||||
})
|
|
||||||
return
|
|
||||||
}
|
|
||||||
if (!form.value.member_password) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '请输入登录密码',
|
|
||||||
icon: 'none',
|
|
||||||
})
|
|
||||||
return
|
|
||||||
}
|
|
||||||
if (form.value.member_password !== form.value.confirm_member_password) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '两次输入的密码不一致',
|
|
||||||
icon: 'none',
|
|
||||||
})
|
|
||||||
return
|
|
||||||
}
|
|
||||||
if (!form.value.pay_password) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '请输入支付密码',
|
|
||||||
icon: 'none',
|
|
||||||
})
|
|
||||||
return
|
|
||||||
}
|
|
||||||
if (form.value.pay_password !== form.value.confirm_pay_password) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '两次输入的支付密码不一致',
|
|
||||||
icon: 'none',
|
|
||||||
})
|
|
||||||
return
|
|
||||||
}
|
|
||||||
// if (!form.value.invitation_code) {
|
|
||||||
// uni.showToast({
|
|
||||||
// title: '请输入邀请码',
|
|
||||||
// icon: 'none',
|
|
||||||
// })
|
|
||||||
// return
|
|
||||||
// }
|
|
||||||
const {
|
|
||||||
data: { token },
|
|
||||||
} = await registerAPI(form.value).catch(() => {
|
|
||||||
handleGetCode()
|
|
||||||
throw new Error('注册失败')
|
|
||||||
})
|
|
||||||
userStore.setToken(token)
|
|
||||||
uni.reLaunch({
|
|
||||||
url: redirect,
|
|
||||||
})
|
|
||||||
})
|
|
||||||
const { codeUrl, refreshCode: handleGetCode } = useCaptcha()
|
|
||||||
onLoad(async (options) => {
|
|
||||||
if (isLogged()) {
|
|
||||||
uni.reLaunch({
|
|
||||||
url: redirect,
|
|
||||||
})
|
|
||||||
}
|
|
||||||
form.value.invitation_code = options.invite ?? ''
|
|
||||||
})
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style lang="scss">
|
|
||||||
.login-container {
|
.login-container {
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
min-height: 100vh;
|
min-height: 100vh;
|
||||||
padding-bottom: 200rpx;
|
padding-bottom: 50px;
|
||||||
background-image: url('@/static/images/login-bg.png');
|
background-image: url('@/static/images/register-bg.jpg');
|
||||||
background-repeat: no-repeat;
|
background-repeat: no-repeat;
|
||||||
background-size: cover;
|
background-size: cover;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,134 +1,208 @@
|
|||||||
import { http } from '@/utils/http'
|
import { http } from '@/utils/http'
|
||||||
|
|
||||||
/** 账号登录 */
|
// 注册用户
|
||||||
export const loginAPI = (data) => {
|
export const registerUserAPI = (data) =>
|
||||||
return http.post<{ token: string }>('/api/v1/LoginUser', data)
|
http({
|
||||||
|
url: '/api/user/register',
|
||||||
|
method: 'POST',
|
||||||
|
data,
|
||||||
|
})
|
||||||
|
|
||||||
|
// 登录
|
||||||
|
export const loginUserAPI = (data) =>
|
||||||
|
http({
|
||||||
|
url: '/api/user/login',
|
||||||
|
method: 'POST',
|
||||||
|
data,
|
||||||
|
})
|
||||||
|
|
||||||
|
// 获取用户信息
|
||||||
|
export const getUserInfoAPI = () =>
|
||||||
|
http({
|
||||||
|
url: '/api/user/index',
|
||||||
|
method: 'GET',
|
||||||
|
})
|
||||||
|
|
||||||
|
// 退出登录
|
||||||
|
export const logoutUserAPI = () =>
|
||||||
|
http({
|
||||||
|
url: '/api/user/logout',
|
||||||
|
method: 'POST',
|
||||||
|
})
|
||||||
|
|
||||||
|
// 简介、公告、新闻
|
||||||
|
export const getIntroductionAPI = (data) =>
|
||||||
|
http({
|
||||||
|
url: '/api/index/articlelist',
|
||||||
|
method: 'POST',
|
||||||
|
data,
|
||||||
|
})
|
||||||
|
|
||||||
|
// 新闻详情
|
||||||
|
export const getIntroductionDetailAPI = (data) =>
|
||||||
|
http({
|
||||||
|
url: '/api/index/articledetails',
|
||||||
|
method: 'POST',
|
||||||
|
data,
|
||||||
|
})
|
||||||
|
|
||||||
|
// 投资理财列表
|
||||||
|
export const getInvestmentListAPI = (data) =>
|
||||||
|
http({
|
||||||
|
url: '/api/index/investlist',
|
||||||
|
method: 'POST',
|
||||||
|
data,
|
||||||
|
})
|
||||||
|
|
||||||
|
// 提交投资
|
||||||
|
export const submitInvestAPI = (data) =>
|
||||||
|
http({
|
||||||
|
url: '/api/user/submitinvest',
|
||||||
|
method: 'POST',
|
||||||
|
data,
|
||||||
|
})
|
||||||
|
|
||||||
|
// 获取投资记录
|
||||||
|
export const getInvestmentRecordAPI = (data) =>
|
||||||
|
http({
|
||||||
|
url: '/api/user/myinvestlist',
|
||||||
|
method: 'POST',
|
||||||
|
data,
|
||||||
|
})
|
||||||
|
|
||||||
|
// 查询实名认证
|
||||||
|
export const getRealNameAuthAPI = () =>
|
||||||
|
http({
|
||||||
|
url: '/api/user/finduserauth',
|
||||||
|
method: 'POST',
|
||||||
|
})
|
||||||
|
|
||||||
|
// 实名认证
|
||||||
|
export const realNameAuthAPI = (data) =>
|
||||||
|
http({
|
||||||
|
url: '/api/user/userauth',
|
||||||
|
method: 'POST',
|
||||||
|
data,
|
||||||
|
})
|
||||||
|
|
||||||
|
// 我的邀请
|
||||||
|
export const getMyTeamAPI = (data) =>
|
||||||
|
http({
|
||||||
|
url: '/api/user/inviteelist',
|
||||||
|
method: 'POST',
|
||||||
|
data,
|
||||||
|
})
|
||||||
|
|
||||||
|
// 我的资产
|
||||||
|
export const getMyAssetAPI = (data) =>
|
||||||
|
http({
|
||||||
|
url: '/api/user/moneyloglist',
|
||||||
|
method: 'POST',
|
||||||
|
data,
|
||||||
|
})
|
||||||
|
|
||||||
|
// 股数转换
|
||||||
|
export const convertScoreAPI = (data) =>
|
||||||
|
http({
|
||||||
|
url: '/api/user/conversion',
|
||||||
|
method: 'POST',
|
||||||
|
data,
|
||||||
|
})
|
||||||
|
|
||||||
|
// 添加银行卡
|
||||||
|
export const addBankCardAPI = (data) =>
|
||||||
|
http({
|
||||||
|
url: '/api/user/addbank',
|
||||||
|
method: 'POST',
|
||||||
|
data,
|
||||||
|
})
|
||||||
|
|
||||||
|
// 获取银行卡
|
||||||
|
export const getBankCardAPI = (data) =>
|
||||||
|
http({
|
||||||
|
url: '/api/user/banklist',
|
||||||
|
method: 'POST',
|
||||||
|
data,
|
||||||
|
})
|
||||||
|
|
||||||
|
// 删除银行卡
|
||||||
|
export const deleteBankCardAPI = (data) =>
|
||||||
|
http({
|
||||||
|
url: '/api/user/delbank',
|
||||||
|
method: 'POST',
|
||||||
|
data,
|
||||||
|
})
|
||||||
|
|
||||||
|
// 提交提现
|
||||||
|
export const submitWithdrawalAPI = (data) =>
|
||||||
|
http({
|
||||||
|
url: '/api/user/withdrawal',
|
||||||
|
method: 'POST',
|
||||||
|
data,
|
||||||
|
})
|
||||||
|
|
||||||
|
// 获取提现记录
|
||||||
|
export const getWithdrawalRecordAPI = (data) =>
|
||||||
|
http({
|
||||||
|
url: '/api/user/withdrawallist',
|
||||||
|
method: 'POST',
|
||||||
|
data,
|
||||||
|
})
|
||||||
|
|
||||||
|
// 下载APP
|
||||||
|
export const downloadAppAPI = () => {
|
||||||
|
location.href = 'https://r2.maldiveswallet.vip/app/qmbz-3.apk'
|
||||||
}
|
}
|
||||||
|
|
||||||
/** 修改密码 */
|
// 社区我的邀请
|
||||||
export const updateUserAPI = (data) => {
|
export const getCommunityMyInviteAPI = (data) =>
|
||||||
return http.post('/api/v1/UpgradeUser', data)
|
http({
|
||||||
}
|
url: '/api/user/inviteelist',
|
||||||
|
method: 'POST',
|
||||||
|
data,
|
||||||
|
})
|
||||||
|
|
||||||
/** 注册账号 */
|
// 领取奖励第一步
|
||||||
export const registerAPI = (data) => {
|
export const getCommunityInviteFirstAPI = () =>
|
||||||
return http.post<{ token: string }>('/api/v1/RegisterUser', data)
|
http({
|
||||||
}
|
url: '/api/user/rewardone',
|
||||||
/** 用户信息 */
|
method: 'POST',
|
||||||
export const getUserInfoAPI = () => {
|
})
|
||||||
return http.post<IUserInfo>('/api/v1/getUserInfo')
|
|
||||||
}
|
|
||||||
|
|
||||||
/** 退出登录 */
|
// 领取救济金
|
||||||
export const logoutAPI = () => {
|
export const getCommunityInviteRewardAPI = (data) =>
|
||||||
return http.post('/api/v1/Logiout')
|
http({
|
||||||
}
|
url: '/api/user/rewardtwo',
|
||||||
|
method: 'POST',
|
||||||
|
data,
|
||||||
|
})
|
||||||
|
|
||||||
/** 实名认证 */
|
// 签到功能
|
||||||
export const createAuthUser = (data) => {
|
export const getSignInAPI = () =>
|
||||||
return http.post('/api/v1/CreateAuthUser', data)
|
http({
|
||||||
}
|
url: '/api/user/signin',
|
||||||
|
method: 'POST',
|
||||||
|
})
|
||||||
|
|
||||||
/** 轮播列表 */
|
// 开通个人养老账户
|
||||||
export const getBannerListAPI = () => {
|
export const getOpenPersonalAccountAPI = () =>
|
||||||
return http.post<any[]>('/api/v1/getSwipeList')
|
http({
|
||||||
}
|
url: '/api/user/activateold',
|
||||||
|
method: 'POST',
|
||||||
|
})
|
||||||
|
|
||||||
/** 新闻列表 */
|
// 养老金转入余额
|
||||||
export const getNewsListAPI = (data) => {
|
export const getOldMoneyTransferAPI = (data) =>
|
||||||
return http.post<any[]>('/api/v1/getNewsList', data)
|
http({
|
||||||
}
|
url: '/api/user/yangout',
|
||||||
|
method: 'POST',
|
||||||
|
data,
|
||||||
|
})
|
||||||
|
|
||||||
/** 新闻详情 */
|
// 佣金转入养老金
|
||||||
export const getNewsDetailAPI = (data) => {
|
export const getYongMoneyTransferAPI = (data) =>
|
||||||
return http.post<any>('/api/v1/getNewsDetail', data, data)
|
http({
|
||||||
}
|
url: '/api/user/tuanduiout',
|
||||||
|
method: 'POST',
|
||||||
/** 公司简介 */
|
data,
|
||||||
export const getCompanyInfoAPI = () => {
|
})
|
||||||
return http.post<any>('/api/v1/getCompanyProfile')
|
|
||||||
}
|
|
||||||
|
|
||||||
/** 基金列表 */
|
|
||||||
export const getFundListAPI = () => {
|
|
||||||
return http.post<any[]>('/api/v1/getFundList')
|
|
||||||
}
|
|
||||||
/** 购买基金 */
|
|
||||||
export const buyFundAPI = (data) => {
|
|
||||||
return http.post('/api/v1/buyFundOrder', data)
|
|
||||||
}
|
|
||||||
|
|
||||||
/** 购买基金订单列表 */
|
|
||||||
export const getBuyFundOrderListAPI = (data) => {
|
|
||||||
return http.post<any[]>('/api/v1/getFundOrderList', data)
|
|
||||||
}
|
|
||||||
|
|
||||||
/** 房屋列表 */
|
|
||||||
export const getHouseListAPI = () => {
|
|
||||||
return http.post<{ list: any[] }>('/api/v1/getHouseList')
|
|
||||||
}
|
|
||||||
|
|
||||||
/** 购买房屋 */
|
|
||||||
export const buyHouseAPI = (data) => {
|
|
||||||
return http.post('/api/v1/buyHouseOrder', data)
|
|
||||||
}
|
|
||||||
|
|
||||||
/** VIP列表 */
|
|
||||||
export const getVipListAPI = () => {
|
|
||||||
return http.post<{ list: any[] }>('/api/v1/getVipList')
|
|
||||||
}
|
|
||||||
|
|
||||||
/** 购买VIP */
|
|
||||||
export const buyVIPAPI = (data) => {
|
|
||||||
return http.post('/api/v1/buyFundOrder', data)
|
|
||||||
}
|
|
||||||
|
|
||||||
/** 我的团队 */
|
|
||||||
export const getMyTeamAPI = (data) => {
|
|
||||||
return http.post<{ list: any[] }>('/api/v1/getMyTeam', data)
|
|
||||||
}
|
|
||||||
|
|
||||||
/** 绑定收款卡号 */
|
|
||||||
export const bindBankCardAPI = (data) => {
|
|
||||||
return http.post('/api/v1/CreateCardUser', data)
|
|
||||||
}
|
|
||||||
|
|
||||||
/** 删除收款卡号 */
|
|
||||||
export const deleteBankCardAPI = (data) => {
|
|
||||||
return http.post('/api/v1/CannelUserCard', data)
|
|
||||||
}
|
|
||||||
|
|
||||||
/** 获取银行卡列表 */
|
|
||||||
export const getBankCardListAPI = (data) => {
|
|
||||||
return http.post<{ list: any[] }>('/api/v1/getCardList', data)
|
|
||||||
}
|
|
||||||
|
|
||||||
/** 申请提现 */
|
|
||||||
export const applyWithdrawalAPI = (data) => {
|
|
||||||
return http.post('/api/v1/CreateWithdrawal', data)
|
|
||||||
}
|
|
||||||
|
|
||||||
/** 提现记录 */
|
|
||||||
export const getWithdrawalRecordAPI = (data) => {
|
|
||||||
return http.post<{ list: any[] }>('/api/v1/WithdrawalOrder', data)
|
|
||||||
}
|
|
||||||
|
|
||||||
/** 余额明细 */
|
|
||||||
export const getBalanceRecordsAPI = (data) => {
|
|
||||||
return http.post<{ list: any[] }>('/api/v1/getBalanceRecords', data)
|
|
||||||
}
|
|
||||||
|
|
||||||
/** 系统充收款账号列表 */
|
|
||||||
export const getSystemRechargeAccountAPI = (data) => {
|
|
||||||
return http.post<{ list: any[] }>('/api/v1/getWalletList', data)
|
|
||||||
}
|
|
||||||
|
|
||||||
/** 充值 */
|
|
||||||
export const rechargeAPI = (data) => {
|
|
||||||
return http.post('/api/v1/CreateRechangeOrder', data)
|
|
||||||
}
|
|
||||||
|
|
||||||
/** 充值记录 */
|
|
||||||
export const getRechargeRecordAPI = (data) => {
|
|
||||||
return http.post<{ list: any[] }>('/api/v1/getRechangeOrder', data)
|
|
||||||
}
|
|
||||||
|
|||||||
|
After Width: | Height: | Size: 29 KiB |
|
Before Width: | Height: | Size: 304 KiB After Width: | Height: | Size: 525 KiB |
|
Before Width: | Height: | Size: 27 KiB After Width: | Height: | Size: 74 KiB |
|
After Width: | Height: | Size: 21 KiB |
|
After Width: | Height: | Size: 24 KiB |
|
Before Width: | Height: | Size: 201 KiB |
|
After Width: | Height: | Size: 10 KiB |
|
Before Width: | Height: | Size: 466 KiB After Width: | Height: | Size: 195 KiB |
|
Before Width: | Height: | Size: 2.8 KiB After Width: | Height: | Size: 6.9 KiB |
|
After Width: | Height: | Size: 51 KiB |
|
Before Width: | Height: | Size: 149 KiB After Width: | Height: | Size: 120 KiB |
|
Before Width: | Height: | Size: 1.0 KiB After Width: | Height: | Size: 2.4 KiB |
|
After Width: | Height: | Size: 74 KiB |
|
Before Width: | Height: | Size: 2.0 KiB After Width: | Height: | Size: 3.6 KiB |
|
Before Width: | Height: | Size: 960 B After Width: | Height: | Size: 2.7 KiB |
|
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 3.2 KiB |
|
After Width: | Height: | Size: 26 KiB |
|
After Width: | Height: | Size: 412 KiB |
|
After Width: | Height: | Size: 2.3 KiB |
|
After Width: | Height: | Size: 1.9 KiB |
|
After Width: | Height: | Size: 1.4 KiB |
|
After Width: | Height: | Size: 1.6 KiB |
|
After Width: | Height: | Size: 1.9 KiB |
|
After Width: | Height: | Size: 1.2 KiB |
|
After Width: | Height: | Size: 951 B |
|
After Width: | Height: | Size: 867 B |
|
After Width: | Height: | Size: 1.3 KiB |
|
After Width: | Height: | Size: 1.6 KiB |
|
After Width: | Height: | Size: 4.4 KiB |
|
Before Width: | Height: | Size: 1.4 KiB After Width: | Height: | Size: 2.9 KiB |
|
Before Width: | Height: | Size: 1.3 KiB |
|
After Width: | Height: | Size: 42 KiB |
|
Before Width: | Height: | Size: 1.3 KiB After Width: | Height: | Size: 2.9 KiB |
|
After Width: | Height: | Size: 55 KiB |
|
Before Width: | Height: | Size: 57 KiB |
|
After Width: | Height: | Size: 3.2 KiB |
|
Before Width: | Height: | Size: 2.1 KiB After Width: | Height: | Size: 3.8 KiB |
|
After Width: | Height: | Size: 16 KiB |
|
After Width: | Height: | Size: 734 KiB |
|
Before Width: | Height: | Size: 442 KiB |
|
After Width: | Height: | Size: 55 KiB |
|
After Width: | Height: | Size: 50 KiB |