添加会员系统相关静态页面
continuous-integration/drone/push Build is passing Details

pull/1/head
lvxiu_ext 3 years ago
parent 4ed91eaa78
commit 6ad28f9b23

@ -5,7 +5,7 @@
</template>
<script setup>
const url = ref('http://doc.ruoyi.vip/ruoyi-vue');
const url = ref('https://www.api2gpt.com/helper.html');
function goto() {
window.open(url.value)

@ -8,10 +8,6 @@
<template v-if="appStore.device !== 'mobile'">
<header-search id="header-search" class="right-menu-item" />
<el-tooltip content="源码地址" effect="dark" placement="bottom">
<ruo-yi-git id="ruoyi-git" class="right-menu-item hover-effect" />
</el-tooltip>
<el-tooltip content="文档地址" effect="dark" placement="bottom">
<ruo-yi-doc id="ruoyi-doc" class="right-menu-item hover-effect" />
</el-tooltip>
@ -55,7 +51,6 @@ import Hamburger from '@/components/Hamburger'
import Screenfull from '@/components/Screenfull'
import SizeSelect from '@/components/SizeSelect'
import HeaderSearch from '@/components/HeaderSearch'
import RuoYiGit from '@/components/RuoYi/Git'
import RuoYiDoc from '@/components/RuoYi/Doc'
import useAppStore from '@/store/modules/app'
import useUserStore from '@/store/modules/user'

@ -2,11 +2,9 @@
<div class="sidebar-logo-container" :class="{ 'collapse': collapse }" :style="{ backgroundColor: sideTheme === 'theme-dark' ? variables.menuBackground : variables.menuLightBackground }">
<transition name="sidebarLogoFade">
<router-link v-if="collapse" key="collapse" class="sidebar-logo-link" to="/">
<img v-if="logo" :src="logo" class="sidebar-logo" />
<h1 v-else class="sidebar-title" :style="{ color: sideTheme === 'theme-dark' ? variables.logoTitleColor : variables.logoLightTitleColor }">{{ title }}</h1>
<h1 class="sidebar-title" :style="{ color: sideTheme === 'theme-dark' ? variables.logoTitleColor : variables.logoLightTitleColor }">{{ title }}</h1>
</router-link>
<router-link v-else key="expand" class="sidebar-logo-link" to="/">
<img v-if="logo" :src="logo" class="sidebar-logo" />
<h1 class="sidebar-title" :style="{ color: sideTheme === 'theme-dark' ? variables.logoTitleColor : variables.logoLightTitleColor }">{{ title }}</h1>
</router-link>
</transition>
@ -25,7 +23,7 @@ defineProps({
}
})
const title = ref('Api2GPT');
const title = ref('Api2Gpt Console');
const settingsStore = useSettingsStore();
const sideTheme = computed(() => settingsStore.sideTheme);
</script>

@ -1,78 +1,86 @@
<template>
<div class="app-container home">
Welcome to API2GPT
<div class="main">
<el-card class="box-card">
<template #header>
<div class="card-header">
<span>帐户管理</span>
<router-link to="/money">
<el-button type="primary">去充值</el-button>
</router-link>
</div>
</template>
<el-row :gutter="20" class="info">
<el-col :span="8">帐户余额<el-text class="mx-1">100</el-text></el-col>
<el-col :span="8">本月消费<el-text class="mx-1">100</el-text></el-col>
<el-col :span="8">帐户等级<el-tag class="ml-2" type="success">1</el-tag></el-col>
</el-row>
</el-card>
<div class="main2">
<el-card class="box-card">
<template #header>
<div class="card-header">
<span>模型定价</span>
</div>
</template>
<el-table :data="tableData" height="250" style="width: 100%">
<el-table-column prop="name" label="模型" />
<el-table-column prop="price1" label="提问价格" width="180" />
<el-table-column prop="price2" label="回答价格" width="180"/>
<el-table-column prop="txt" label="备注" />
</el-table>
</el-card>
</div>
</div>
</template>
<script setup name="Index">
const version = ref('3.8.5')
function goTarget(url) {
window.open(url, '__blank')
}
const tableData = [
{
name: 'gpt-3.5-turbo',
price1: '¥0.028 /1k',
price2: '¥0.028 /1k',
txt: ''
},
{
name: 'text-davinci-003',
price1: '¥0.28 /1k',
price2: '¥0.28 /1k',
txt: ''
},
{
name: 'text-embedding-ada-002',
price1: '¥0.0056 /1k',
price2: '¥0.0056 /1k',
txt: ''
}
]
</script>
<style scoped lang="scss">
.home {
blockquote {
padding: 10px 20px;
margin: 0 0 20px;
font-size: 17.5px;
border-left: 5px solid #eee;
}
hr {
margin-top: 20px;
margin-bottom: 20px;
border: 0;
border-top: 1px solid #eee;
}
.col-item {
margin-bottom: 20px;
}
ul {
padding: 0;
margin: 0;
}
font-family: "open sans", "Helvetica Neue", Helvetica, Arial, sans-serif;
font-size: 13px;
color: #676a6c;
overflow-x: hidden;
ul {
list-style-type: none;
}
h4 {
margin-top: 0px;
}
h2 {
margin-top: 10px;
font-size: 26px;
font-weight: 100;
}
.main {
padding: 20px;
}
.main2 {
margin-top: 20px;
}
p {
margin-top: 10px;
.card-header {
display: flex;
justify-content: space-between;
align-items: center;
}
b {
font-weight: 700;
}
}
.text {
font-size: 14px;
}
.update-log {
ol {
display: block;
list-style-type: decimal;
margin-block-start: 1em;
margin-block-end: 1em;
margin-inline-start: 0;
margin-inline-end: 0;
padding-inline-start: 40px;
}
}
.item {
margin-bottom: 18px;
}
.info {
font-size: 15px;
color: #606266;
}
</style>

@ -0,0 +1,43 @@
<template>
<div class="main">
<el-card class="box-card">
<template #header>
<div class="card-header">
<span>服务设置</span>
</div>
</template>
<el-space direction="vertical" alignment="start" :size="30">
<div>
<el-input v-model="apiServer" size="large" style="width:500px">
<template #prepend>Api Server:</template>
</el-input>
</div>
<div>
<el-input v-model="apiKey" size="large" style="width:500px">
<template #prepend>Api Key:</template>
</el-input>
</div>
<div>
<el-input v-model="apiServer2" size="large" style="width:500px">
<template #prepend>Api Server备用:</template>
</el-input>
</div>
</el-space>
</el-card>
</div>
</template>
<script setup name="developer">
const apiServer = 'https://api.api2gpt.com'
const apiKey = 'aaaaaaaaaaaaaaaaaaaaaaa'
const apiServer2 = 'https://oa.api2gpt.com'
</script>
<style scoped lang="scss">
.main {
padding: 20px;
}
</style>

@ -0,0 +1,31 @@
<template>
<div class="main">
<el-card class="box-card">
<template #header>
<div class="card-header">
<span>使用文档</span>
</div>
</template>
<div class="info">
请先参考<a href="https://www.api2gpt.com/helper" target="_blank">api2gpt 文档</a>
</div>
</el-card>
</div>
</template>
<script setup name="doc">
</script>
<style scoped lang="scss">
.main {
padding: 20px;
}
.info {
font-size: 14px;
color: #606266;
}
</style>

@ -0,0 +1,72 @@
<template>
<div class="main">
<el-card shadow="always">
<el-space alignment="start" :size="30">
充值金值
<el-input-number v-model="num" :precision="2" :step="0.1" :max="500" :min="0.1" />
<el-button type="primary">充值</el-button>
</el-space>
</el-card>
<div style="margin-top:5px;">
<el-alert title="第一次充值建议先小额进行试用充值最高500元" type="warning" :closable="false" />
</div>
<div class="main2">
<el-card class="box-card">
<template #header>
<div class="card-header">
<span>充值历史</span>
</div>
</template>
<el-table :data="tableData" height="250" style="width: 100%">
<el-table-column prop="id" label="订单ID" />
<el-table-column prop="price" label="提问价格" />
<el-table-column prop="createTime" label="创建时间"/>
<el-table-column prop="payTime" label="付款时间" />
<el-table-column prop="op" label="操作" />
</el-table>
</el-card>
</div>
</div>
</template>
<script setup name="money">
import { ref } from 'vue'
const num = ref(1)
const tableData = [
{
id: 'aaaa',
price: 60,
createTime: '2022-01-01 12:00:00',
payTime: '2022-01-01 12:00:00',
op: '查看'
},
{
id: 'aaaa',
price: 60,
createTime: '2022-01-01 12:00:00',
payTime: '2022-01-01 12:00:00',
op: '查看'
},
{
id: 'aaaa',
price: 60,
createTime: '2022-01-01 12:00:00',
payTime: '2022-01-01 12:00:00',
op: '查看'
},
]
</script>
<style scoped lang="scss">
.main {
padding: 20px;
}
.main2 {
margin-top: 20px;
}
</style>

@ -0,0 +1,40 @@
<template>
<div class="main">
<el-card class="box-card">
<template #header>
<div class="card-header">
<span>联系方式</span>
</div>
</template>
<el-space direction="vertical" alignment="start" :size="30">
<div class="info">
微信客服请添加
</div>
<div class="info">
TG群组
</div>
<div class="info">
充值订单问题请发送邮件至客服邮箱: service@api2gpt.com
</div>
</el-space>
</el-card>
</div>
</template>
<script setup name="support">
</script>
<style scoped lang="scss">
.main {
padding: 20px;
}
.info {
font-size: 14px;
color: #606266;
}
</style>

@ -0,0 +1,42 @@
<template>
<div class="main">
<el-card class="box-card">
<template #header>
<div class="card-header">
<span>调用记录</span>
</div>
</template>
<el-table :data="tableData" height="250" style="width: 100%">
<el-table-column prop="requestTime" label="调用时间" />
<el-table-column prop="msgId" label="调用ID" />
<el-table-column prop="model" label="模型" />
<el-table-column prop="promptTotkens" label="prompt" />
<el-table-column prop="completionTokens" label="completion" />
<el-table-column prop="totalTokens" label="total" />
<el-table-column prop="price" label="花费" />
</el-table>
</el-card>
</div>
</template>
<script setup name="usage">
const tableData = [
{
requestTime: '2022-01-01 12:00:00',
msgId: '069e1032-8a68-4b27-ac8f-9ad8401d4df3',
model: 'gpt-3.5-turbo',
promptTotkens: 60,
completionTokens: 80,
totalTokens: 140,
price: 10
},
]
</script>
<style scoped lang="scss">
.main {
padding: 20px;
}
</style>
Loading…
Cancel
Save