学生端页面基本完成

main
qzp 2 years ago
parent 9412111c02
commit 23307921af

@ -21,8 +21,8 @@ router.beforeEach((to, from, next) => {
if (to.path === '/login') {
// console.log(getToken(),"getToken()")
// next({ path: '/' })
router.push({path:'/'})
}
router.push({ path: '/' })
}
next()
// to.meta.title && store.dispatch('settings/setTitle', "外汇模拟交易")
/* has token*/

@ -111,7 +111,7 @@ export const dynamicRoutes = [{
component: () => import('@/views/index'),
name: 'Index',
meta: { title: '首页', icon: 'dashboard', affix: true }
},
}
]
},
{
@ -140,7 +140,7 @@ export const dynamicRoutes = [{
component: () => import('@/views/training/index'),
name: 'training',
meta: { title: '实训任务', icon: 'dashboard', affix: true }
},
}
// {
// path: 'homepage',
// component: () => import('@/views/homepage/index.vue'),
@ -159,7 +159,7 @@ export const dynamicRoutes = [{
path: 'home',
component: () => import('@/views/homepage/index.vue'),
name: 'Index',
meta: { title: '首页', icon: 'dashboard', affix: true, activeMenu: "/training/List" }
meta: { title: '首页', icon: 'dashboard', affix: true, activeMenu: '/training/List' }
}
]
},
@ -173,7 +173,7 @@ export const dynamicRoutes = [{
path: 'index',
component: () => import('@/views/PracticeZone/index.vue'),
name: 'Index',
meta: { title: '练习专区', icon: 'dashboard', affix: true, activeMenu: "/training/List" }
meta: { title: '练习专区', icon: 'dashboard', affix: true, activeMenu: '/training/List' }
}
]
},
@ -187,7 +187,35 @@ export const dynamicRoutes = [{
path: 'index',
component: () => import('@/views/trade/index.vue'),
name: 'Index',
meta: { title: '练习专区', icon: 'dashboard', affix: true, activeMenu: "/training/List" }
meta: { title: '练习专区', icon: 'dashboard', affix: true, activeMenu: '/training/List' }
}
]
},
{
path: '/teachingPlan',
component: Layout,
hidden: false,
permissions: ['system:user:edit'],
children: [
{
path: 'case',
component: () => import('@/views/teachingpan/index.vue'),
name: 'teachingPlan',
meta: { title: '实训教案', icon: 'dashboard', affix: true, activeMenu: '/teachingPlan/case' }
}
]
},
{
path: '/quotation',
component: Layout,
hidden: false,
permissions: ['system:user:edit'],
children: [
{
path: 'lowcore',
component: () => import('@/views/quotation/index.vue'),
name: 'lowcore',
meta: { title: '行情中心', icon: 'dashboard', affix: true, activeMenu: '/teachingPlan/case' }
}
]
},
@ -266,8 +294,8 @@ export const dynamicRoutes = [{
}
]
// 防止连续点击多次路由报错
let routerPush = Router.prototype.push;
let routerReplace = Router.prototype.replace;
const routerPush = Router.prototype.push
const routerReplace = Router.prototype.replace
// push
Router.prototype.push = function push(location) {
return routerPush.call(this, location).catch(err => err)

@ -1,9 +1,9 @@
import defaultSettings from '@/settings'
const { sideTheme, showSettings, topNav, tagsView, fixedHeader, sidebarLogo, dynamicTitle } = defaultSettings
const storageSetting = JSON.parse(localStorage.getItem('layout-setting')) || ''
// const storageSetting = ''
// tagsView
// const storageSetting = JSON.parse(localStorage.getItem('layout-setting')) || ''
const storageSetting = ''
const state = {
title: '',
theme: storageSetting.theme || '#409EFF',
@ -27,7 +27,7 @@ const actions = {
// 修改布局设置
changeSetting({ commit }, data) {
commit('CHANGE_SETTING', data)
},
}
// 设置网页标题
// setTitle({ commit }, title) {
// state.title = title

@ -14,8 +14,8 @@ axios.defaults.headers['Content-Type'] = 'application/json;charset=utf-8'
// 创建axios实例
const service = axios.create({
// axios中请求配置有baseURL选项表示请求URL公共部分
// baseURL:"http://118.31.7.2:8800",
baseURL:"http://192.168.2.14:8800",
baseURL: "http://118.31.7.2:8800",
// baseURL:"http://192.168.2.14:8800",
// baseURL: process.env.VUE_APP_BASE_API,
// 超时
timeout: 200000
@ -61,46 +61,46 @@ service.interceptors.request.use(config => {
}
return config
}, error => {
console.log(error)
Promise.reject(error)
console.log(error)
Promise.reject(error)
})
// 响应拦截器
service.interceptors.response.use(res => {
// 未设置状态码则默认成功状态
const code = res.data.code || 200;
// 获取错误信息
const msg = errorCode[code] || res.data.msg || errorCode['default']
// 二进制数据则直接返回
if (res.request.responseType === 'blob' || res.request.responseType === 'arraybuffer') {
return res.data
}
if (code === 401) {
if (!isRelogin.show) {
isRelogin.show = true;
MessageBox.confirm('登录状态已过期,您可以继续留在该页面,或者重新登录', '系统提示', { confirmButtonText: '重新登录', cancelButtonText: '取消', type: 'warning' }).then(() => {
isRelogin.show = false;
// store.dispatch('LogOut').then(() => {
// location.href = '/index';
// })
// 未设置状态码则默认成功状态
const code = res.data.code || 200;
// 获取错误信息
const msg = errorCode[code] || res.data.msg || errorCode['default']
// 二进制数据则直接返回
if (res.request.responseType === 'blob' || res.request.responseType === 'arraybuffer') {
return res.data
}
if (code === 401) {
if (!isRelogin.show) {
isRelogin.show = true;
MessageBox.confirm('登录状态已过期,您可以继续留在该页面,或者重新登录', '系统提示', { confirmButtonText: '重新登录', cancelButtonText: '取消', type: 'warning' }).then(() => {
isRelogin.show = false;
// store.dispatch('LogOut').then(() => {
// location.href = '/index';
// })
}).catch(() => {
isRelogin.show = false;
});
}
return Promise.reject('无效的会话,或者会话已过期,请重新登录。')
} else if (code === 500) {
Message({ message: msg, type: 'error' })
return Promise.reject(new Error(msg))
} else if (code === 601) {
Message({ message: msg, type: 'warning' })
return Promise.reject('error')
} else if (code !== 200) {
Notification.error({ title: msg })
return Promise.reject('error')
} else {
return res.data
}
},
return Promise.reject('无效的会话,或者会话已过期,请重新登录。')
} else if (code === 500) {
Message({ message: msg, type: 'error' })
return Promise.reject(new Error(msg))
} else if (code === 601) {
Message({ message: msg, type: 'warning' })
return Promise.reject('error')
} else if (code !== 200) {
Notification.error({ title: msg })
return Promise.reject('error')
} else {
return res.data
}
},
error => {
console.log('err' + error)
let { message } = error;

@ -1,17 +1,17 @@
<template>
<div class="app-container">
<div class="overview-title" v-show="activeName !== 'tabs2'">
<div v-show="activeName !== 'tabs2'" class="overview-title">
<el-button size="medium" @click="progress"></el-button>
</div>
<div class="overview-title-right" v-show="activeName !== 'tabs1'">
<div v-show="activeName !== 'tabs1'" class="overview-title-right">
<el-button type="primary"> </el-button>
<el-button type="warning"> </el-button>
</div>
<el-tabs
v-model="activeName"
type="card"
@tab-click="handleClick"
class="tabs-btn"
@tab-click="handleClick"
>
<el-tab-pane
v-for="(item, index) in tabsArr"
@ -21,46 +21,46 @@
>
<components
:is="item.name"
:id="id"
v-if="item.name == nowName"
></components>
:id="id"
/>
</el-tab-pane>
</el-tabs>
</div>
</template>
<script>
import tabs1 from "../homepage/overview.vue";
<script>
import tabs1 from '../homepage/overview.vue'
// import tabs2 from "./report.vue";
export default {
name: "",
name: '',
components: {
tabs1,
tabs1
},
data() {
return {
activeName: "tabs1",
nowName: "tabs1",
activeName: 'tabs1',
nowName: 'tabs1',
tabsArr: [
{
label: "当前持仓",
name: "tabs1",
},
],
};
label: '当前持仓',
name: 'tabs1'
}
]
}
},
created() {},
computed: {},
created() {},
methods: {
handleClick(tab) {
tab.name == "tabs1"
tab.name == 'tabs1'
? (this.nowName = tab.name)
: (this.nowName = tab.name);
: (this.nowName = tab.name)
},
progress() {
this.$tab.openPage("进行中", "/trade/index");
},
},
};
this.$tab.openPage('进行中', '/trade/index')
}
}
}
</script>
<style lang='scss' scoped>
.app-container {
@ -105,4 +105,4 @@ export default {
}
}
}
</style>
</style>

@ -1,18 +1,20 @@
<template>
<div class="app-mian">
<el-row type="flex" class="row-bg">
<el-col :span="4.1"
><div class="grid-content bg-purple"></div>
<img src="../assets/images/bg.png" alt="" />
<el-col
:span="4.1"
><div class="grid-content bg-purple" />
<img src="../assets/images/bg.png" alt="">
</el-col>
<el-col :span="8.1"
><div class="grid-content bg-purple-light">
<img src="../assets/images/1.png" alt="" @click="skip" /></div
></el-col>
<el-col :span="8"
><div class="grid-content bg-purple">
<img src="../assets/images/3.png" alt="" @click="lianxi" />
</div>
<el-col
:span="8.1"
><div class="grid-content bg-purple-light">
<img src="../assets/images/1.png" alt="" @click="skip"></div></el-col>
<el-col
:span="8"
><div class="grid-content bg-purple">
<img src="../assets/images/3.png" alt="" @click="lianxi">
</div>
</el-col>
</el-row>
<!-- 搜索栏 -->
@ -29,26 +31,24 @@
</el-select>
</el-form-item>
<el-form-item label="日期" prop="cateId">
<el-date-picker type="date" placeholder="选择日期"> </el-date-picker>
<el-date-picker type="date" placeholder="选择日期" />
</el-form-item>
<el-form-item label="搜索" prop="status">
<el-input placeholder="学号 / 姓名" clearable> </el-input>
<el-input placeholder="学号 / 姓名" clearable />
</el-form-item>
<el-form-item>
<el-button type="primary" icon="el-icon-search" size="mini"
>搜索</el-button
>
<el-button
type="primary"
icon="el-icon-search"
size="mini"
>搜索</el-button>
</el-form-item>
</el-form>
<el-table :data="tableData" style="width: 100%">
<el-table-column prop="ranking" label="排名" width="100" align="center">
</el-table-column>
<el-table-column prop="class" label="班级" width="140" align="center">
</el-table-column>
<el-table-column prop="name" label="姓名" align="center">
</el-table-column>
<el-table-column prop="StudentID" label="学号" align="center">
</el-table-column>
<el-table-column prop="ranking" label="排名" width="100" align="center" />
<el-table-column prop="class" label="班级" width="140" align="center" />
<el-table-column prop="name" label="姓名" align="center" />
<el-table-column prop="StudentID" label="学号" align="center" />
<el-table-column label="累计盈亏" align="center">
<template slot-scope="scope">
<span v-if="scope.row.profit > 0" style="color: #f98133">{{
@ -59,24 +59,21 @@
}}</span>
</template>
</el-table-column>
<el-table-column prop="income" label="收益率" align="center">
</el-table-column>
<el-table-column prop="number" label="开仓次数" align="center">
</el-table-column>
<el-table-column prop="income" label="收益率" align="center" />
<el-table-column prop="number" label="开仓次数" align="center" />
<el-table-column
prop="Simulation"
label="模拟交易实训成绩"
align="center"
>
</el-table-column>
<el-table-column prop="experiment" label="实验报告成绩" align="center">
</el-table-column>
<el-table-column prop="address" label="总成绩" align="center">
</el-table-column>
/>
<el-table-column prop="experiment" label="实验报告成绩" align="center" />
<el-table-column prop="address" label="总成绩" align="center" />
<el-table-column prop="address" label="交易记录" align="center">
<el-button size="mini" type="primary" @click="trade"
>交易记录</el-button
>
<el-button
size="mini"
type="primary"
@click="trade"
>交易记录</el-button>
</el-table-column>
</el-table>
<pagination :total="10" />
@ -84,136 +81,136 @@
</div>
</template>
<script>
import * as home from "@/api/index.js";
import * as home from '@/api/index.js'
export default {
name: "Index",
name: 'Index',
data() {
return {
tableData: [
{
ranking: "2",
class: "王小虎",
name: "王小虎",
StudentID: "2003001",
profit: "+20000",
income: "50%",
number: "8",
Simulation: "80",
experiment: "70",
ranking: '2',
class: '王小虎',
name: '王小虎',
StudentID: '2003001',
profit: '+20000',
income: '50%',
number: '8',
Simulation: '80',
experiment: '70'
},
{
ranking: "2",
class: "王小虎",
name: "王小虎",
StudentID: "2003001",
profit: "+20000",
income: "20%",
number: "8",
Simulation: "80",
experiment: "70",
ranking: '2',
class: '王小虎',
name: '王小虎',
StudentID: '2003001',
profit: '+20000',
income: '20%',
number: '8',
Simulation: '80',
experiment: '70'
},
{
ranking: "2",
class: "王小虎",
name: "王小虎",
StudentID: "2003001",
profit: "+20000",
income: "20%",
number: "8",
Simulation: "80",
experiment: "70",
ranking: '2',
class: '王小虎',
name: '王小虎',
StudentID: '2003001',
profit: '+20000',
income: '20%',
number: '8',
Simulation: '80',
experiment: '70'
},
{
ranking: "2",
class: "王小虎",
name: "王小虎",
StudentID: "2003001",
profit: "+20000",
income: "20%",
number: "8",
Simulation: "80",
experiment: "70",
ranking: '2',
class: '王小虎',
name: '王小虎',
StudentID: '2003001',
profit: '+20000',
income: '20%',
number: '8',
Simulation: '80',
experiment: '70'
},
{
ranking: "2",
class: "王小虎",
name: "王小虎",
StudentID: "2003001",
profit: "+20000",
income: "20%",
number: "8",
Simulation: "80",
experiment: "70",
ranking: '2',
class: '王小虎',
name: '王小虎',
StudentID: '2003001',
profit: '+20000',
income: '20%',
number: '8',
Simulation: '80',
experiment: '70'
},
{
ranking: "2",
class: "王小虎",
name: "王小虎",
StudentID: "2003001",
profit: "+20000",
income: "20%",
number: "8",
Simulation: "80",
experiment: "70",
ranking: '2',
class: '王小虎',
name: '王小虎',
StudentID: '2003001',
profit: '+20000',
income: '20%',
number: '8',
Simulation: '80',
experiment: '70'
},
{
ranking: "2",
class: "王小虎",
name: "王小虎",
StudentID: "2003001",
profit: "-20000",
income: "40%",
number: "8",
Simulation: "80",
experiment: "70",
},
ranking: '2',
class: '王小虎',
name: '王小虎',
StudentID: '2003001',
profit: '-20000',
income: '40%',
number: '8',
Simulation: '80',
experiment: '70'
}
],
queryParams: {
trainingName: null,
classGrade: "",
classGrade: '',
index: 1,
name: "",
name: '',
size: 10,
startTime: "",
studentNumber: "",
},
};
startTime: '',
studentNumber: ''
}
}
},
computed: {},
created() {
this.getlist();
this.taskname();
this.classGrade();
this.getlist()
this.taskname()
this.classGrade()
},
computed: {},
methods: {
getlist() {
home.findAll(this.queryParams).then((res) => {
console.log(res);
});
console.log(res)
})
},
taskname() {
home.getTrainingName().then((res) => {
console.log(res);
});
console.log(res)
})
},
classGrade() {
home.getClassGrade().then((res) => {
console.log(res);
});
console.log(res)
})
},
trade() {
this.$tab.openPage("交易记录", "/index/list");
this.$tab.openPage('交易记录', '/index/list')
},
lianxi() {
this.$tab.openPage("实训任务", "/training/list");
this.$tab.openPage('实训任务', '/training/list')
},
skip() {
this.$tab.openPage("练习专区", "/PracticeZone/index");
},
},
};
this.$tab.openPage('练习专区', '/PracticeZone/index')
}
}
}
</script>
<style lang='scss' scoped>
.row-bg {
@ -228,4 +225,4 @@ export default {
img {
cursor: pointer;
}
</style>
</style>

@ -3,52 +3,52 @@
<div class="login-header">
<div class="login-centen">
<div class="logo">
<a href="#" ></a>
<a href="#" />
</div>
</div>
</div>
<div class="login-mian">
<el-form ref="loginForm" :model="loginForm" :rules="loginRules" class="login-form">
<h3 class="title">外汇模拟交易系统</h3>
<el-form-item prop="username">
<el-input
v-model="loginForm.username"
type="text"
auto-complete="off"
placeholder="账号"
>
<svg-icon slot="prefix" icon-class="user" class="el-input__icon input-icon" />
</el-input>
</el-form-item>
<el-form-item prop="password">
<el-input
v-model="loginForm.password"
type="password"
auto-complete="off"
placeholder="密码"
@keyup.enter.native="handleLogin"
>
<svg-icon slot="prefix" icon-class="password" class="el-input__icon input-icon" />
</el-input>
</el-form-item>
<div class="login-mian">
<el-form ref="loginForm" :model="loginForm" :rules="loginRules" class="login-form">
<h3 class="title">外汇模拟交易系统</h3>
<el-form-item prop="username">
<el-input
v-model="loginForm.username"
type="text"
auto-complete="off"
placeholder="账号"
>
<svg-icon slot="prefix" icon-class="user" class="el-input__icon input-icon" />
</el-input>
</el-form-item>
<el-form-item prop="password">
<el-input
v-model="loginForm.password"
type="password"
auto-complete="off"
placeholder="密码"
@keyup.enter.native="handleLogin"
>
<svg-icon slot="prefix" icon-class="password" class="el-input__icon input-icon" />
</el-input>
</el-form-item>
<el-form-item style="width:100%;">
<el-button
:loading="loading"
size="medium"
type="primary"
style="width:100%;"
@click.native.prevent="handleLogin"
>
<span v-if="!loading"> </span>
<span v-else> ...</span>
</el-button>
<div style="float: right;" v-if="register">
<router-link class="link-type" :to="'/register'">立即注册</router-link>
</div>
</el-form-item>
</el-form>
</div>
<el-form-item style="width:100%;">
<el-button
:loading="loading"
size="medium"
type="primary"
style="width:100%;"
@click.native.prevent="handleLogin"
>
<span v-if="!loading"> </span>
<span v-else> ...</span>
</el-button>
<div v-if="register" style="float: right;">
<router-link class="link-type" :to="'/register'">立即注册</router-link>
</div>
</el-form-item>
</el-form>
</div>
<!-- 底部 -->
<div class="el-login-footer">
<span>Copyright © 2018-2023 ruoyi.vip All Rights Reserved.</span>
@ -58,29 +58,29 @@
<script>
// import { getCodeImg } from "@/api/login";
import Cookies from "js-cookie";
import Cookies from 'js-cookie'
import { encrypt, decrypt } from '@/utils/jsencrypt'
export default {
name: "Login",
name: 'Login',
data() {
return {
codeUrl: "",
codeUrl: '',
loginForm: {
username: "",
password: "",
username: '',
password: '',
rememberMe: false,
code: "",
uuid: ""
code: '',
uuid: ''
},
loginRules: {
username: [
{ required: true, trigger: "blur", message: "请输入您的账号" }
{ required: true, trigger: 'blur', message: '请输入您的账号' }
],
password: [
{ required: true, trigger: "blur", message: "请输入您的密码" }
{ required: true, trigger: 'blur', message: '请输入您的密码' }
],
code: [{ required: true, trigger: "change", message: "请输入验证码" }]
code: [{ required: true, trigger: 'change', message: '请输入验证码' }]
},
loading: false,
//
@ -88,19 +88,19 @@ export default {
//
register: false,
redirect: undefined
};
}
},
watch: {
$route: {
handler: function(route) {
this.redirect = route.query && route.query.redirect;
this.redirect = route.query && route.query.redirect
},
immediate: true
}
},
created() {
// this.getCode();
this.getCookie();
this.getCookie()
},
methods: {
getCode() {
@ -113,46 +113,46 @@ export default {
// });
},
getCookie() {
const username = Cookies.get("username");
const password = Cookies.get("password");
const username = Cookies.get('username')
const password = Cookies.get('password')
this.loginForm = {
username: username === undefined ? this.loginForm.username : username,
password: password === undefined ? this.loginForm.password : decrypt(password),
};
password: password === undefined ? this.loginForm.password : decrypt(password)
}
},
handleLogin() {
this.$refs.loginForm.validate(valid => {
if (valid) {
this.loading = true;
this.loading = true
if (this.loginForm.rememberMe) {
Cookies.set("username", this.loginForm.username, { expires: 30 });
Cookies.set("password", encrypt(this.loginForm.password), { expires: 30 });
Cookies.set('username', this.loginForm.username, { expires: 30 })
Cookies.set('password', encrypt(this.loginForm.password), { expires: 30 })
} else {
Cookies.remove("username");
Cookies.remove("password");
Cookies.remove('username')
Cookies.remove('password')
}
const username = Cookies.get("username");
const password = Cookies.get("password");
const loginForm={
const username = Cookies.get('username')
const password = Cookies.get('password')
const loginForm = {
username: username === undefined ? this.loginForm.username : username,
passwordEncode: password === undefined ? encrypt(this.loginForm.password) : password ,
passwordEncode: password === undefined ? encrypt(this.loginForm.password) : password
}
this.$store.dispatch("Login", loginForm).then(() => {
console.log('loginForm',loginForm);
this.$router.push({ path: this.redirect || "/" })
this.$store.dispatch('Login', loginForm).then(() => {
console.log('loginForm', loginForm)
this.$router.push({ path: this.redirect || '/' })
}).catch(() => {
console.log('dsdsdsd');
this.loading = false;
console.log('dsdsdsd')
this.loading = false
// if (this.captchaEnabled) {
// this.getCode();
// }
});
})
}
});
})
}
}
};
}
</script>
<style rel="stylesheet/scss" lang="scss">

@ -0,0 +1,81 @@
<template>
<div class="app-container">
<el-row>
<el-col :span="24">
<div class="grid-content">
<img src="../../assets/images/已结束bg.png" style="height: 110px;" alt="">
<div class="center"> <span>新浪财经</span></div>
<div class="right"> <el-button type="primary">查看 >></el-button>
</div>
</div>
</el-col>
<el-col :span="24">
<div class="grid-content">
<img src="../../assets/images/已结束bg.png" style="height: 110px;" alt="">
<div class="center"> <span>东方财富</span></div>
<div class="right"> <el-button type="primary">查看 >></el-button>
</div>
</div>
</el-col>
<el-col :span="24">
<div class="grid-content">
<img src="../../assets/images/已结束bg.png" style="height: 110px;" alt="">
<div class="center"> <span>中国证监会</span></div>
<div class="right"> <el-button type="primary">查看 >></el-button>
</div>
</div>
</el-col>
<el-col :span="24">
<div class="grid-content">
<img src="../../assets/images/已结束bg.png" style="height: 110px;" alt="">
<div class="center"> <span>外汇模拟交易</span></div>
<div class="right"> <el-button type="primary"> 查看 >></el-button>
</div>
</div>
</el-col>
</el-row>
</div>
</template>
<script>
export default {
name: '',
data() {
return {
}
},
computed: {
},
created() {
},
methods: {
}
}
</script>
<style lang='scss' scoped>
.grid-content {
border-radius: 4px;
margin-bottom: 30px;
background: pink;
min-height: 170px;
padding: 30px 30px;
display: flex;
justify-content: space-between;
align-content: center;
.center{
display: flex;
align-items: center;
font-size: 24px;
font-family: Microsoft YaHei;
font-weight: 400;
color: #333333;
}
.right{
display: flex;
align-items: center;
}
}
</style>

@ -0,0 +1,62 @@
<template>
<div class="app-container">
<el-form ref="ruleForm" :inline="true" label-width="100px" class="el-form-lable" cell-style="{ display: flex;}">
<el-form-item>
<el-input placeholder="资源名称" />
</el-form-item>
<el-form-item>
<el-button type="primary">查询</el-button>
</el-form-item>
</el-form>
<!-- -->
<el-table :data="tableData" style="width:100%">
<el-table-column prop="date" label="日期" align="center" width="200" />
<el-table-column prop="name" label="姓名" align="center" />
<el-table-column label="地址" align="center" width="300">
<el-button type="primary" size="mini">下载</el-button>
</el-table-column>
</el-table>
<pagination :total="10" />
</div>
</template>
<script>
export default {
name: '',
data() {
return {
tableData: [{
date: '2016-05-02',
name: '王小虎上海市普陀区金沙江路 1518 弄上海市普陀区金沙江路 1518 弄',
address: '上海市普陀区金沙江路 1518 弄'
}, {
date: '2016-05-04',
name: '王小虎',
address: '上海市普陀区'
}, {
date: '2016-05-01',
name: '王小虎',
address: '上海市普陀区'
}, {
date: '2016-05-03',
name: '王小虎',
address: '上海市普'
}]
}
},
computed: {},
created() {},
methods: {}
}
</script>
<style lang='scss' scoped>
.app-container {
.el-form-lable {
.el-input {
width: calc(100vw / 3);
}
::v-deep.el-input__inner{
background: #EAEAEA !important;
}
}
}
</style>

@ -1,144 +1,132 @@
<template>
<div class="homepage-current">
<el-table
:data="tableData"
style="width: 100%"
>
<el-table-column
prop="ranking"
label="账号"
width="100"
align="center"
>
</el-table-column>
<el-table-column prop="class" label="姓名" width="140" align="center">
</el-table-column>
<el-table-column label="已用保证金" align="center" prop="profit">
</el-table-column>
<el-table-column prop="StudentID" label="净值" align="center">
</el-table-column>
<el-table-column label="保证金水平" align="center" prop="profit">
</el-table-column>
<el-table-column prop="income" label="保证金报警水平" align="center">
</el-table-column>
<el-table-column prop="number" label="状态" align="center">
<template slot-scope="scope">
<el-tag v-if="scope.row.number >0" type="danger"></el-tag>
<el-tag v-else></el-tag>
</template>
</el-table-column>
<el-table-column prop="class" label="设置时间" align="center">
</el-table-column>
<el-table-column prop="address" label="操作" align="center" width="200">
<el-button size="mini" @click="centerDialogVisible = true">删除</el-button>
<el-button size="mini" type="primary" @click="colseDialogVisible = true" >启用</el-button
>
</el-table-column>
</el-table>
<!-- 分页 -->
<pagination :total="10" />
<el-row>
<el-col :span="24"><div class="grid-content bg-purple-dark">预警</div></el-col>
</el-row>
<el-table :data="tableData" style="width: 100%" >
<el-table-column prop="ranking" label="账号" width="100" align="center" >
</el-table-column>
<el-table-column prop="class" label="姓名" width="140" align="center">
</el-table-column>
<el-table-column label="已用保证金" align="center" prop="profit">
</el-table-column>
<el-table-column prop="StudentID" label="净值" align="center">
</el-table-column>
<el-table-column label="保证金水平" align="center" prop="profit">
</el-table-column>
<el-table-column prop="income" label="保证金报警水平" align="center">
</el-table-column>
<el-table-column prop="number" label="状态" align="center">
<template slot-scope="scope">
<el-tag v-if="scope.row.number >0" type="danger"></el-tag>
<el-tag v-else></el-tag>
</template>
</el-table-column>
<el-table-column prop="class" label="设置时间" align="center">
</el-table-column>
<el-table-column prop="address" label="操作" align="center" width="200">
<el-button size="mini" @click="centerDialogVisible = true">删除</el-button>
</el-table-column>
</el-table>
<pagination :total="10" />
</div>
</template>
<script>
export default {
data() {
return {
tableData: [
{
ranking: "euresd",
class: "1612167713",
name: 1,
StudentID: "2003001",
profit: "+20000",
income: "50%",
number: "8",
Simulation: "80",
experiment: "70",
},
{
ranking: "euresd",
class: "1612167713",
name: 1,
StudentID: "2003001",
profit: "+20000",
income: "50%",
number: "8",
Simulation: "80",
experiment: "70",
},
{
ranking: "euresd",
class: "1612167713",
name: 0,
StudentID: "2003001",
profit: "+20000",
income: "20%",
number: "-8",
Simulation: "80",
experiment: "70",
},
{
ranking: "euresd",
class: "1612167713",
name: 0,
StudentID: "2003001",
profit: "+20000",
income: "20%",
number: "8",
Simulation: "80",
experiment: "-70",
},
{
ranking: "euresd",
class: "1612167713",
name: 1,
StudentID: "2003001",
profit: "+20000",
income: "20%",
number: "-8",
Simulation: "80",
experiment: "70",
},
],
};
},
};
</script>
<div class="trade-cdeposit">
<el-table
:data="tableData"
style="width: 100%"
>
<el-table-column
prop="ranking"
label="账号"
width="100"
align="center"
/>
<el-table-column prop="class" label="姓名" width="140" align="center" />
<el-table-column label="已用保证金" align="center" prop="profit" />
<el-table-column prop="StudentID" label="净值" align="center" />
<el-table-column label="保证金水平" align="center" prop="profit" />
<el-table-column prop="income" label="保证金报警水平" align="center" />
<el-table-column prop="number" label="状态" align="center">
<template slot-scope="scope">
<el-tag v-if="scope.row.number >0" type="danger"></el-tag>
<el-tag v-else></el-tag>
</template>
</el-table-column>
<el-table-column prop="class" label="设置时间" align="center" />
<el-table-column prop="address" label="操作" align="center" width="200">
<el-button type="danger" size="mini" @click="centerDialogVisible = true">删除</el-button>
<el-button size="mini" type="primary" @click="colseDialogVisible = true">启用</el-button>
</el-table-column>
</el-table>
<!-- 分页 -->
<pagination :total="10" />
<el-row>
<el-col :span="24"><div class="record">预警记录:</div></el-col>
</el-row>
<el-table :data="tableData" style="width: 100%">
<el-table-column prop="ranking" label="账号" width="100" align="center" />
<el-table-column prop="class" label="姓名" width="400" align="center" />
<el-table-column prop="income" label="保证金报警水平" align="center" />
<el-table-column prop="number" label="预警水平" align="center" />
<el-table-column prop="class" label="预警时间" align="center" />
<el-table-column prop="address" label="操作" align="center" width="200">
<el-button type="danger" size="mini" @click="centerDialogVisible = true">删除</el-button>
</el-table-column>
</el-table>
<pagination :total="10" />
</div>
</template>
<script>
export default {
data() {
return {
tableData: [
{
ranking: 'euresd',
class: '1612167713',
name: 1,
StudentID: '2003001',
profit: '+20000',
income: '50%',
number: '8',
Simulation: '80',
experiment: '70'
},
{
ranking: 'euresd',
class: '1612167713',
name: 1,
StudentID: '2003001',
profit: '+20000',
income: '50%',
number: '8',
Simulation: '80',
experiment: '70'
},
{
ranking: 'euresd',
class: '1612167713',
name: 0,
StudentID: '2003001',
profit: '+20000',
income: '20%',
number: '-8',
Simulation: '80',
experiment: '70'
},
{
ranking: 'euresd',
class: '1612167713',
name: 0,
StudentID: '2003001',
profit: '+20000',
income: '20%',
number: '8',
Simulation: '80',
experiment: '-70'
},
{
ranking: 'euresd',
class: '1612167713',
name: 1,
StudentID: '2003001',
profit: '+20000',
income: '20%',
number: '-8',
Simulation: '80',
experiment: '70'
}
]
}
}
}
</script>
<style lang="scss" scoped>
.trade-cdeposit{
background: #fff;
.record{
height: 60px;
line-height: 60px;
border-top: 1px solid #EAEAEA;
font-size: 18px;
font-family: Microsoft YaHei;
font-weight: bold;
color: #333333;
}
}
.pagination-container {
background: #f5f6f6;
background: #fff;
margin-bottom: 20px;
}
</style>
</style>

@ -10,39 +10,29 @@
label="交易品种"
width="100"
align="center"
>
</el-table-column>
<el-table-column prop="class" label="订单号" width="140" align="center">
</el-table-column>
/>
<el-table-column prop="class" label="订单号" width="140" align="center" />
<el-table-column label="类型" align="center">
<template slot-scope="scope">
<el-tag v-if="scope.row.profit >0" type="danger"></el-tag>
<el-tag v-else></el-tag>
</template>
</el-table-column>
<el-table-column prop="StudentID" label="交易量(手)" align="center">
</el-table-column>
<el-table-column label="交易价位" align="center" prop="profit">
</el-table-column>
<el-table-column prop="income" label="止损" align="center">
</el-table-column>
<el-table-column prop="number" label="止盈" align="center">
</el-table-column>
<el-table-column prop="Simulation" label="当前价位" align="center">
</el-table-column>
<el-table-column label="持仓盈亏" align="center">
<el-table-column prop="StudentID" label="交易量(手)" align="center" />
<el-table-column label="交易价位" align="center" prop="profit" />
<el-table-column prop="income" label="止损" align="center" />
<el-table-column prop="number" label="止盈" align="center" />
<el-table-column prop="Simulation" label="当前价位" align="center" />
<el-table-column label="持仓盈亏" align="center">
<template slot-scope="scope">
<span v-if="scope.row.experiment > 0" style="color: #EC6C01;">{{ scope.row.experiment}}</span>
<span v-else style="color: #2CB7B0;">{{ scope.row.experiment}}</span>
<span v-if="scope.row.experiment > 0" style="color: #EC6C01;">{{ scope.row.experiment }}</span>
<span v-else style="color: #2CB7B0;">{{ scope.row.experiment }}</span>
</template>
</el-table-column>
<el-table-column prop="class" label="交易时间" align="center">
</el-table-column>
<el-table-column prop="class" label="交易时间" align="center" />
<el-table-column prop="address" label="操作" align="center" width="200">
<el-button size="mini" type="primary" @click="centerDialogVisible = true">修改</el-button>
<el-button size="mini" type="warning" @click="colseDialogVisible = true" >平仓</el-button
>
<el-button size="mini" type="primary" @click="centerDialogVisible = true">修改</el-button>
<el-button size="mini" type="warning" @click="colseDialogVisible = true">平仓</el-button>
</el-table-column>
</el-table>
<!-- 分页 -->
@ -57,32 +47,34 @@
<el-form ref="ruleForm" label-width="100px" class="demo-ruleForm">
<el-form-item label="交易品种:">
<el-select placeholder="活动区域" style="width: 100%">
<el-option label="区域一" value="shanghai"></el-option>
<el-option label="区域二" value="beijing"></el-option>
<el-option label="区域一" value="shanghai" />
<el-option label="区域二" value="beijing" />
</el-select>
</el-form-item>
<el-form-item label="名称:">
<el-input type="password" autocomplete="off"></el-input>
<el-input type="password" autocomplete="off" />
</el-form-item>
<el-form-item label="类型:">
<el-input></el-input>
<el-input />
</el-form-item>
<div class="dialog-inline" style="display: flex">
<el-form-item label="止损:">
<el-input></el-input>
<el-input />
</el-form-item>
<el-form-item label="止盈:">
<el-input></el-input>
<el-input />
</el-form-item>
</div>
</el-form>
<span slot="footer" class="dialog-footer">
<el-button type="primary" @click="centerDialogVisible = false"
> </el-button
>
<el-button @click="centerDialogVisible = false" type="info"
> </el-button
>
<el-button
type="primary"
@click="centerDialogVisible = false"
> </el-button>
<el-button
type="info"
@click="centerDialogVisible = false"
> </el-button>
</span>
</el-dialog>
<!-- 平仓 -->
@ -95,23 +87,23 @@
<el-form ref="ruleForm" label-width="100px" class="demo-ruleForm">
<el-form-item label="交易品种:">
<el-select placeholder="活动区域" style="width: 100%">
<el-option label="区域一" value="shanghai"></el-option>
<el-option label="区域二" value="beijing"></el-option>
<el-option label="区域一" value="shanghai" />
<el-option label="区域二" value="beijing" />
</el-select>
</el-form-item>
<el-form-item label="名称:">
<el-input type="password" autocomplete="off"></el-input>
<el-input type="password" autocomplete="off" />
</el-form-item>
<div class="dialog-inline" style="display: flex">
<el-form-item label="订 单 号:">
<el-input></el-input>
<el-input />
</el-form-item>
<el-form-item label="持仓方向:">
<el-input></el-input>
<el-input />
</el-form-item>
</div>
<el-form-item label="交 易 量:">
<el-input></el-input>
<el-input />
</el-form-item>
<el-form-item label="开仓价位:">
<template>
@ -122,19 +114,20 @@
font-family: Microsoft YaHei;
color: #1d2129;
"
>9661.00</span
>
>9661.00</span>
<div class="price">6.90494 / 6.90498</div>
</template>
</el-form-item>
</el-form>
<span slot="footer" class="dialog-footer">
<el-button type="primary" @click="colseDialogVisible = false"
> </el-button
>
<el-button @click="colseDialogVisible = false" type="info"
> </el-button
>
<el-button
type="primary"
@click="colseDialogVisible = false"
> </el-button>
<el-button
type="info"
@click="colseDialogVisible = false"
> </el-button>
</span>
</el-dialog>
</div>
@ -149,53 +142,53 @@ export default {
colseDialogVisible: false,
tableData: [
{
ranking: "euresd",
class: "1612167713",
ranking: 'euresd',
class: '1612167713',
name: 1,
StudentID: "2003001",
profit: "+20000",
income: "50%",
number: "8",
Simulation: "80",
experiment: "70",
StudentID: '2003001',
profit: '+20000',
income: '50%',
number: '8',
Simulation: '80',
experiment: '70'
},
{
ranking: "euresd",
class: "1612167713",
ranking: 'euresd',
class: '1612167713',
name: 0,
StudentID: "2003001",
profit: "+20000",
income: "20%",
number: "8",
Simulation: "80",
experiment: "70",
StudentID: '2003001',
profit: '+20000',
income: '20%',
number: '8',
Simulation: '80',
experiment: '70'
},
{
ranking: "euresd",
class: "1612167713",
ranking: 'euresd',
class: '1612167713',
name: 0,
StudentID: "2003001",
profit: "+20000",
income: "20%",
number: "8",
Simulation: "80",
experiment: "-70",
StudentID: '2003001',
profit: '+20000',
income: '20%',
number: '8',
Simulation: '80',
experiment: '-70'
},
{
ranking: "euresd",
class: "1612167713",
ranking: 'euresd',
class: '1612167713',
name: 1,
StudentID: "2003001",
profit: "+20000",
income: "20%",
number: "8",
Simulation: "80",
experiment: "70",
},
],
};
},
};
StudentID: '2003001',
profit: '+20000',
income: '20%',
number: '8',
Simulation: '80',
experiment: '70'
}
]
}
}
}
</script>
<style lang="scss" scoped>
.pagination-container {
@ -214,4 +207,4 @@ export default {
font-weight: bold;
color: #1d2129;
}
</style>
</style>

@ -1,114 +1,127 @@
<template>
<div>
<div class="trade-cdeposit">
<el-table
:data="tableData"
style="width: 100%"
:cell-style="{ background: '#f8f8f9' }"
>
<el-table-column prop="ranking" label="时间" width="150" align="center">
<el-table-column
prop="ranking"
label="交易品种"
width="100"
align="center"
/>
<el-table-column label="预警时长" align="center" prop="profit" />
<el-table-column prop="StudentID" label="状态" align="center" />
<el-table-column prop="class" label="设置时间" align="center" />
<el-table-column prop="address" label="操作" align="center" width="200">
<el-button type="danger" size="mini" @click="centerDialogVisible = true">删除</el-button>
<el-button size="mini" type="primary" @click="colseDialogVisible = true">启用</el-button>
</el-table-column>
<el-table-column prop="class" label="交易品种" width="140" align="center">
</el-table-column>
<el-table-column prop="StudentID" label="订单号" align="center">
</el-table-column>
<el-table-column prop="profit" label="类型" align="center">
<template slot-scope="scope">
<el-tag v-if="scope.row.profit >0"></el-tag>
<el-tag v-else></el-tag>
</template>
</el-table-column>
<el-table-column prop="income" label="交易量" align="center">
</el-table-column>
<el-table-column prop="income" label="交易价位" align="center">
</el-table-column>
<el-table-column prop="number" label="止损" align="center">
</el-table-column>
<el-table-column prop="Simulation" label="止盈" align="center">
</el-table-column>
<el-table-column prop="experiment" label="平仓时间" align="center">
</el-table-column>
<el-table-column prop="address" label="平仓价位" align="center">
</el-table-column>
<el-table-column prop="address" label="盈利" align="center">
</el-table>
<!-- 分页 -->
<pagination :total="10" />
<el-row>
<el-col :span="24"><div class="record">预警记录:</div></el-col>
</el-row>
<!-- 行情预警记录 -->
<el-table :data="tableData" style="width: 100%">
<el-table-column prop="ranking" label="交易记录" width="100" align="center" />
<el-table-column prop="class" label="买卖方向" width="300" align="center" />
<el-table-column prop="income" label="上破价" align="center" />
<el-table-column prop="number" label="下破价" align="center" />
<el-table-column prop="class" label="预警价" align="center" />
<el-table-column prop="class" label="预警时间" align="center" />
<el-table-column prop="address" label="操作" align="center" width="200">
<el-button type="danger" size="mini" @click="centerDialogVisible = true">删除</el-button>
</el-table-column>
</el-table>
<pagination :total="10" />
<div class="transaction-footer">
<span>累计盈亏: <i>+8999.22</i> </span>
</div>
</div>
</template>
<script>
<script>
export default {
data() {
return {
tableData: [
{
ranking: "2023-06-13 22:22:21",
class: "eurusd",
ranking: 'euresd',
class: '1612167713',
name: 1,
StudentID: "2003001",
profit: "+20000",
income: "50%",
number: "8",
Simulation: "80",
experiment: "70",
StudentID: '2003001',
profit: '+20000',
income: '50%',
number: '8',
Simulation: '80',
experiment: '70'
},
{
ranking: "2023-06-13 22:22:21",
class: "eurusd",
name: 0,
StudentID: "2003001",
profit: "+20000",
income: "20%",
number: "8",
Simulation: "80",
experiment: "70",
ranking: 'euresd',
class: '1612167713',
name: 1,
StudentID: '2003001',
profit: '+20000',
income: '50%',
number: '8',
Simulation: '80',
experiment: '70'
},
{
ranking: "2023-06-13 22:22:21",
class: "eurusd",
ranking: 'euresd',
class: '1612167713',
name: 0,
StudentID: "2003001",
profit: "+20000",
income: "20%",
number: "8",
Simulation: "80",
experiment: "70",
StudentID: '2003001',
profit: '+20000',
income: '20%',
number: '-8',
Simulation: '80',
experiment: '70'
},
{
ranking: "2023-06-13 22:22:21",
class: "eurusd",
ranking: 'euresd',
class: '1612167713',
name: 0,
StudentID: "2003001",
profit: "+20000",
income: "20%",
number: "8",
Simulation: "80",
experiment: "70",
StudentID: '2003001',
profit: '+20000',
income: '20%',
number: '8',
Simulation: '80',
experiment: '-70'
},
{
ranking: 'euresd',
class: '1612167713',
name: 1,
StudentID: '2003001',
profit: '+20000',
income: '20%',
number: '-8',
Simulation: '80',
experiment: '70'
}
],
};
},
};
</script>
<style lang="scss" scoped>
.transaction-footer {
height: 25px;
display: flex;
justify-content: flex-end;
margin-bottom: 16px;
& span {
margin-right: 51px;
& i {
color: pink;
font-size: 24px;
font-weight: bold;
]
}
}
}
.pagination-container {
background: #f5f6f6;
}
</style>
</script>
<style lang="scss" scoped>
.trade-cdeposit{
background: #fff;
.record{
height: 60px;
line-height: 60px;
border-top: 1px solid #EAEAEA;
font-size: 18px;
font-family: Microsoft YaHei;
font-weight: bold;
color: #333333;
}
}
.pagination-container {
background: #fff;
margin-bottom: 20px;
}
</style>

@ -0,0 +1,130 @@
<template>
<div class="trade-cdeposit">
<el-table
:data="tableData"
style="width: 100%"
>
<el-table-column
prop="ranking"
label="交易品种"
width="100"
align="center"
/>
<el-table-column prop="class" label="买家方向" width="300" align="center" />
<el-table-column label="上破价" align="center" prop="profit" />
<el-table-column prop="StudentID" label="下破价" align="center" />
<el-table-column label="状态" align="center" prop="profit" />
<el-table-column prop="class" label="时间" align="center" />
<el-table-column prop="address" label="操作" align="center" width="200">
<el-button type="danger" size="mini" @click="centerDialogVisible = true">删除</el-button>
<el-button size="mini" type="primary" @click="colseDialogVisible = true">启用</el-button>
</el-table-column>
</el-table>
<!-- 分页 -->
<pagination :total="10" />
<el-row>
<el-col :span="24"><div class="record">预警记录:</div></el-col>
</el-row>
<!-- 行情预警记录 -->
<el-table :data="tableData" style="width: 100%">
<el-table-column prop="ranking" label="交易品种" width="100" align="center" />
<el-table-column prop="class" label="买卖方向" width="300" align="center" />
<el-table-column prop="income" label="交易时间" align="center" />
<el-table-column prop="number" label="持仓时长" align="center" />
<el-table-column prop="class" label="预警持仓时长" align="center" />
<el-table-column prop="class" label="预警时间" align="center" />
<el-table-column prop="address" label="操作" align="center" width="200">
<el-button type="danger" size="mini" @click="centerDialogVisible = true">删除</el-button>
</el-table-column>
</el-table>
<pagination :total="10" />
</div>
</template>
<script>
export default {
data() {
return {
tableData: [
{
ranking: 'euresd',
class: '1612167713',
name: 1,
StudentID: '2003001',
profit: '+20000',
income: '50%',
number: '8',
Simulation: '80',
experiment: '70'
},
{
ranking: 'euresd',
class: '1612167713',
name: 1,
StudentID: '2003001',
profit: '+20000',
income: '50%',
number: '8',
Simulation: '80',
experiment: '70'
},
{
ranking: 'euresd',
class: '1612167713',
name: 0,
StudentID: '2003001',
profit: '+20000',
income: '20%',
number: '-8',
Simulation: '80',
experiment: '70'
},
{
ranking: 'euresd',
class: '1612167713',
name: 0,
StudentID: '2003001',
profit: '+20000',
income: '20%',
number: '8',
Simulation: '80',
experiment: '-70'
},
{
ranking: 'euresd',
class: '1612167713',
name: 1,
StudentID: '2003001',
profit: '+20000',
income: '20%',
number: '-8',
Simulation: '80',
experiment: '70'
}
]
}
},
created() {
console.log(1111111, '交易')
}
}
</script>
<style lang="scss" scoped>
.trade-cdeposit{
background: #fff;
.record{
height: 60px;
line-height: 60px;
border-top: 1px solid #EAEAEA;
font-size: 18px;
font-family: Microsoft YaHei;
font-weight: bold;
color: #333333;
}
}
.pagination-container {
background: #fff;
margin-bottom: 20px;
}
</style>

@ -1,165 +1,153 @@
<template>
<div class="homepage-current">
<el-table
:data="tableData"
style="width: 100%"
:cell-style="{ background: '#f8f8f9' }"
>
<el-table-column
prop="ranking"
label="委托时间"
width="100"
align="center"
>
</el-table-column>
<el-table-column prop="class" label="交易品种" width="140" align="center">
</el-table-column>
<el-table-column label="委托单号" align="center" prop="profit">
</el-table-column>
<el-table-column prop="StudentID" label="类型" align="center">
</el-table-column>
<el-table-column label="交易量 (手)" align="center" prop="profit">
</el-table-column>
<el-table-column prop="income" label="委托价位" align="center">
</el-table-column>
<el-table-column prop="number" label="止损" align="center">
</el-table-column>
<el-table-column prop="Simulation" label="止盈" align="center">
</el-table-column>
<el-table-column label="当前价位" align="center">
<template slot-scope="scope">
<span v-if="scope.row.experiment > 0" style="color: #EC6C01;">{{ scope.row.experiment}}</span>
<span v-else style="color: #2CB7B0;">{{ scope.row.experiment}}</span>
</template>
</el-table-column>
<el-table-column prop="class" label="持仓盈亏" align="center">
</el-table-column>
<el-table-column prop="class" label="有效期" align="center">
</el-table-column>
<el-table-column prop="address" label="操作" align="center" width="200">
<el-button size="mini" type="warning" @click="colseDialogVisible = true" >撤单</el-button
>
</el-table-column>
</el-table>
<!-- 分页 -->
<pagination :total="10" />
<!-- 修改 -->
<div class="homepage-current">
<el-table
:data="tableData"
style="width: 100%"
:cell-style="{ background: '#f8f8f9' }"
>
<el-table-column
prop="ranking"
label="委托时间"
width="100"
align="center"
/>
<el-table-column prop="class" label="交易品种" width="140" align="center" />
<el-table-column label="委托单号" align="center" prop="profit" />
<el-table-column prop="StudentID" label="类型" align="center" />
<el-table-column label="交易量 (手)" align="center" prop="profit" />
<el-table-column prop="income" label="委托价位" align="center" />
<el-table-column prop="number" label="止损" align="center" />
<el-table-column prop="Simulation" label="止盈" align="center" />
<el-table-column label="当前价位" align="center">
<template slot-scope="scope">
<span v-if="scope.row.experiment > 0" style="color: #EC6C01;">{{ scope.row.experiment }}</span>
<span v-else style="color: #2CB7B0;">{{ scope.row.experiment }}</span>
</template>
</el-table-column>
<el-table-column prop="class" label="持仓盈亏" align="center" />
<el-table-column prop="class" label="有效期" align="center" />
<!-- 平仓 -->
<el-dialog
title="平仓"
:visible.sync="colseDialogVisible"
width="30%"
append-to-body
>
<el-form ref="ruleForm" label-width="100px" class="demo-ruleForm">
<el-form-item label="交易品种:">
<el-select placeholder="活动区域" style="width: 100%">
<el-option label="区域一" value="shanghai"></el-option>
<el-option label="区域二" value="beijing"></el-option>
</el-select>
</el-form-item>
<el-form-item label="名称:">
<el-input type="password" autocomplete="off"></el-input>
<el-table-column prop="address" label="操作" align="center" width="200">
<el-button size="mini" type="warning" @click="colseDialogVisible = true">撤单</el-button>
</el-table-column>
</el-table>
<!-- 分页 -->
<pagination :total="10" />
<!-- 修改 -->
<!-- 平仓 -->
<el-dialog
title="平仓"
:visible.sync="colseDialogVisible"
width="30%"
append-to-body
>
<el-form ref="ruleForm" label-width="100px" class="demo-ruleForm">
<el-form-item label="交易品种:">
<el-select placeholder="活动区域" style="width: 100%">
<el-option label="区域一" value="shanghai" />
<el-option label="区域二" value="beijing" />
</el-select>
</el-form-item>
<el-form-item label="名称:">
<el-input type="password" autocomplete="off" />
</el-form-item>
<div class="dialog-inline" style="display: flex">
<el-form-item label="订 单 号:">
<el-input />
</el-form-item>
<div class="dialog-inline" style="display: flex">
<el-form-item label="订 单 号:">
<el-input></el-input>
</el-form-item>
<el-form-item label="持仓方向:">
<el-input></el-input>
</el-form-item>
</div>
<el-form-item label="交 易 量:">
<el-input></el-input>
<el-form-item label="持仓方向:">
<el-input />
</el-form-item>
<el-form-item label="开仓价位:">
<template>
<span
style="
</div>
<el-form-item label="交 易 量:">
<el-input />
</el-form-item>
<el-form-item label="开仓价位:">
<template>
<span
style="
font-size: 18px;
font-weight: bold;
font-family: Microsoft YaHei;
color: #1d2129;
"
>9661.00</span
>
<div class="price">6.90494 / 6.90498</div>
</template>
</el-form-item>
</el-form>
<span slot="footer" class="dialog-footer">
<el-button type="primary" @click="colseDialogVisible = false"
> </el-button
>
<el-button @click="colseDialogVisible = false" type="info"
> </el-button
>
</span>
</el-dialog>
</div>
</template>
<script>
export default {
data() {
return {
//
colseDialogVisible: false,
tableData: [
{
ranking: "euresd",
class: "1612167713",
name: 1,
StudentID: "2003001",
profit: "+20000",
income: "50%",
number: "8",
Simulation: "80",
experiment: "70",
},
{
ranking: "euresd",
class: "1612167713",
name: 0,
StudentID: "2003001",
profit: "+20000",
income: "20%",
number: "8",
Simulation: "80",
experiment: "70",
},
{
ranking: "euresd",
class: "1612167713",
name: 0,
StudentID: "2003001",
profit: "+20000",
income: "20%",
number: "8",
Simulation: "80",
experiment: "-70",
},
{
ranking: "euresd",
class: "1612167713",
name: 1,
StudentID: "2003001",
profit: "+20000",
income: "20%",
number: "8",
Simulation: "80",
experiment: "70",
},
],
};
},
};
</script>
>9661.00</span>
<div class="price">6.90494 / 6.90498</div>
</template>
</el-form-item>
</el-form>
<span slot="footer" class="dialog-footer">
<el-button
type="primary"
@click="colseDialogVisible = false"
> </el-button>
<el-button
type="info"
@click="colseDialogVisible = false"
> </el-button>
</span>
</el-dialog>
</div>
</template>
<script>
export default {
data() {
return {
//
colseDialogVisible: false,
tableData: [
{
ranking: 'euresd',
class: '1612167713',
name: 1,
StudentID: '2003001',
profit: '+20000',
income: '50%',
number: '8',
Simulation: '80',
experiment: '70'
},
{
ranking: 'euresd',
class: '1612167713',
name: 0,
StudentID: '2003001',
profit: '+20000',
income: '20%',
number: '8',
Simulation: '80',
experiment: '70'
},
{
ranking: 'euresd',
class: '1612167713',
name: 0,
StudentID: '2003001',
profit: '+20000',
income: '20%',
number: '8',
Simulation: '80',
experiment: '-70'
},
{
ranking: 'euresd',
class: '1612167713',
name: 1,
StudentID: '2003001',
profit: '+20000',
income: '20%',
number: '8',
Simulation: '80',
experiment: '70'
}
]
}
}
}
</script>
<style lang="scss" scoped>
.pagination-container {
background: #f5f6f6;
@ -177,4 +165,4 @@
font-weight: bold;
color: #1d2129;
}
</style>
</style>

@ -0,0 +1,128 @@
<template>
<div class="trade-cdeposit">
<el-table
:data="tableData"
style="width: 100%"
>
<el-table-column
prop="ranking"
label="交易品种"
width="100"
align="center"
/>
<el-table-column prop="class" label="买家方向" width="300" align="center" />
<el-table-column label="上破价" align="center" prop="profit" />
<el-table-column prop="StudentID" label="下破价" align="center" />
<el-table-column label="状态" align="center" prop="profit" />
<el-table-column prop="class" label="时间" align="center" />
<el-table-column prop="address" label="操作" align="center" width="200">
<el-button type="danger" size="mini" @click="centerDialogVisible = true">删除</el-button>
<el-button size="mini" type="primary" @click="colseDialogVisible = true">启用</el-button>
</el-table-column>
</el-table>
<!-- 分页 -->
<pagination :total="10" />
<el-row>
<el-col :span="24"><div class="record">预警记录:</div></el-col>
</el-row>
<!-- 行情预警记录 -->
<el-table :data="tableData" style="width: 100%">
<el-table-column prop="ranking" label="交易品种" width="100" align="center" />
<el-table-column prop="class" label="买卖方向" width="300" align="center" />
<el-table-column prop="income" label="交易时间" align="center" />
<el-table-column prop="number" label="持仓时长" align="center" />
<el-table-column prop="class" label="预警持仓时长" align="center" />
<el-table-column prop="class" label="预警时间" align="center" />
<el-table-column prop="address" label="操作" align="center" width="200">
<el-button type="danger" size="mini" @click="centerDialogVisible = true">删除</el-button>
</el-table-column>
</el-table>
<pagination :total="10" />
</div>
</template>
<script>
export default {
data() {
return {
tableData: [
{
ranking: 'euresd',
class: '1612167713',
name: 1,
StudentID: '2003001',
profit: '+20000',
income: '50%',
number: '8',
Simulation: '80',
experiment: '70'
},
{
ranking: 'euresd',
class: '1612167713',
name: 1,
StudentID: '2003001',
profit: '+20000',
income: '50%',
number: '8',
Simulation: '80',
experiment: '70'
},
{
ranking: 'euresd',
class: '1612167713',
name: 0,
StudentID: '2003001',
profit: '+20000',
income: '20%',
number: '-8',
Simulation: '80',
experiment: '70'
},
{
ranking: 'euresd',
class: '1612167713',
name: 0,
StudentID: '2003001',
profit: '+20000',
income: '20%',
number: '8',
Simulation: '80',
experiment: '-70'
},
{
ranking: 'euresd',
class: '1612167713',
name: 1,
StudentID: '2003001',
profit: '+20000',
income: '20%',
number: '-8',
Simulation: '80',
experiment: '70'
}
]
}
}
}
</script>
<style lang="scss" scoped>
.trade-cdeposit{
background: #fff;
.record{
height: 60px;
line-height: 60px;
border-top: 1px solid #EAEAEA;
font-size: 18px;
font-family: Microsoft YaHei;
font-weight: bold;
color: #333333;
}
}
.pagination-container {
background: #fff;
margin-bottom: 20px;
}
</style>

@ -6,30 +6,24 @@
label="交易品种"
width="100"
align="center"
>
</el-table-column>
<el-table-column prop="class" label="名称" align="center">
</el-table-column>
<el-table-column label="卖价" align="center"> </el-table-column>
/>
<el-table-column prop="class" label="名称" align="center" />
<el-table-column label="卖价" align="center" />
<el-table-column
prop="StudentID"
label="最高卖价/最低卖价"
align="center"
>
</el-table-column>
<el-table-column label="买价" align="center"> </el-table-column>
<el-table-column prop="income" label="最高买价/最低买价" align="center">
</el-table-column>
<el-table-column prop="number" label="日变化" align="center">
</el-table-column>
<el-table-column prop="Simulation" label="日变化" align="center">
</el-table-column>
/>
<el-table-column label="买价" align="center" />
<el-table-column prop="income" label="最高买价/最低买价" align="center" />
<el-table-column prop="number" label="日变化" align="center" />
<el-table-column prop="Simulation" label="日变化" align="center" />
<el-table-column prop="Simulation" label="操作" align="center">
<el-button type="primary" size="mini">交易</el-button>
<el-button type="primary" size="mini" @click="colseDialogVisible=true"></el-button>
</el-table-column>
</el-table>
<pagination :total="10" />
<el-tabs class="tabs" v-model="activeName" @tab-click="handleClick">
<el-tabs v-model="activeName" class="tabs" @tab-click="handleClick">
<el-tab-pane
v-for="(item, index) in tabsArr"
:key="index"
@ -38,119 +32,188 @@
>
<components
:is="item.name"
:id="id"
v-if="item.name == nowName"
></components>
:id="id"
/>
</el-tab-pane>
</el-tabs>
<!-- 交易 -->
<el-dialog
title="交易"
:visible.sync="colseDialogVisible"
width="30%"
append-to-body
>
<el-form ref="ruleForm" label-width="100px" class="demo-ruleForm">
<el-form-item label="交易品种:">
<el-select placeholder="活动区域" style="width: 100%">
<el-option label="区域一" value="shanghai" />
<el-option label="区域二" value="beijing" />
</el-select>
</el-form-item>
<el-form-item label="名 称:">
<el-input type="password" autocomplete="off" />
</el-form-item>
<el-form-item label="类 型:">
<el-select placeholder="活动区域" style="width: 100%">
<el-option label="区域一" value="shanghai" />
<el-option label="区域二" value="beijing" />
</el-select>
</el-form-item>
<el-form-item label="买 卖">
<el-radio-group>
<el-radio label="买入" />
<el-radio label="卖出" />
</el-radio-group>
</el-form-item>
<el-form-item label="交 易 量:">
<el-input />
</el-form-item>
<div class="dialog-inline" style="display: flex">
<el-form-item label="止 损:">
<el-input />
</el-form-item>
<el-form-item label="止 盈:">
<el-input />
</el-form-item>
</div>
<el-form-item label="可用资金:">
<template>
<span
style="
font-size: 18px;
font-weight: bold;
font-family: Microsoft YaHei;
color: #1d2129;
"
>9661.00美元</span>
<div class="price">6.90494 / 6.90498</div>
</template>
</el-form-item>
</el-form>
<span slot="footer" class="dialog-footer">
<el-button
type="primary"
@click="colseDialogVisible = false"
>确定</el-button>
<el-button
type="info"
@click="colseDialogVisible = false"
>取消</el-button>
</span>
</el-dialog>
</div>
</template>
<script>
import tabs1 from "./components/current.vue";
import tabs3 from "./components/deals.vue";
import tabs2 from "./components/orders.vue";
import tabs1 from './components/current.vue'
import tabs3 from './components/deals.vue'
import tabs2 from './components/orders.vue'
export default {
components: {
tabs1,
tabs2,
tabs3,
tabs3
},
data() {
return {
activeName: "tabs1",
nowName: "tabs1",
activeName: 'tabs1',
nowName: 'tabs1',
colseDialogVisible: false,
tabsArr: [
{
label: "当前持仓",
name: "tabs1",
label: '当前持仓',
name: 'tabs1'
},
{
label: "现有挂单",
name: "tabs2",
label: '现有挂单',
name: 'tabs2'
},
{
label: "历史成交",
name: "tabs3",
},
label: '历史成交',
name: 'tabs3'
}
],
tableData: [
{
ranking: "euresd",
class: "1612167713",
ranking: 'euresd',
class: '1612167713',
name: 1,
StudentID: "2003001",
profit: "+20000",
income: "50%",
number: "8",
Simulation: "80",
experiment: "70",
StudentID: '2003001',
profit: '+20000',
income: '50%',
number: '8',
Simulation: '80',
experiment: '70'
},
{
ranking: "euresd",
class: "1612167713",
ranking: 'euresd',
class: '1612167713',
name: 0,
StudentID: "2003001",
profit: "+20000",
income: "20%",
number: "8",
Simulation: "80",
experiment: "70",
StudentID: '2003001',
profit: '+20000',
income: '20%',
number: '8',
Simulation: '80',
experiment: '70'
},
{
ranking: "euresd",
class: "1612167713",
ranking: 'euresd',
class: '1612167713',
name: 0,
StudentID: "2003001",
profit: "+20000",
income: "20%",
number: "8",
Simulation: "80",
experiment: "70",
StudentID: '2003001',
profit: '+20000',
income: '20%',
number: '8',
Simulation: '80',
experiment: '70'
},
{
ranking: "euresd",
class: "1612167713",
ranking: 'euresd',
class: '1612167713',
name: 1,
StudentID: "2003001",
profit: "+20000",
income: "20%",
number: "8",
Simulation: "80",
experiment: "70",
StudentID: '2003001',
profit: '+20000',
income: '20%',
number: '8',
Simulation: '80',
experiment: '70'
},
{
ranking: "euresd",
class: "1612167713",
ranking: 'euresd',
class: '1612167713',
name: 0,
StudentID: "2003001",
profit: "+20000",
income: "20%",
number: "8",
Simulation: "80",
experiment: "70",
StudentID: '2003001',
profit: '+20000',
income: '20%',
number: '8',
Simulation: '80',
experiment: '70'
},
{
ranking: "euresd",
class: "1612167713",
ranking: 'euresd',
class: '1612167713',
name: 1,
StudentID: "2003001",
profit: "+20000",
income: "20%",
number: "8",
Simulation: "80",
experiment: "70",
},
],
};
StudentID: '2003001',
profit: '+20000',
income: '20%',
number: '8',
Simulation: '80',
experiment: '70'
}
]
}
},
methods: {
handleClick(tab) {
tab.name == "tabs1" ? this.nowName = tab.name: ( tab.name = "tabs2" ? this.nowName = tab.name : this.nowName = tab.name)
},
},
};
tab.name == 'tabs1' ? this.nowName = tab.name : (tab.name = 'tabs2' ? this.nowName = tab.name : this.nowName = tab.name)
}
}
}
</script>
<style lang="scss" scoped>
.el-radio {
margin-right: 70px;
}
::v-deep.el-tabs {
background: #f8f8f9;
padding: 0 20px;
@ -169,4 +232,17 @@ export default {
.pagination-container {
margin-bottom: 20px !important;
}
</style>
::v-deep .price {
max-width: calc(100% - 136px);
min-height: 60px;
background: #f2f3f4;
border-radius: 4px;
margin-left: 20px;
text-align: center;
line-height: 60px;
font-size: 18px;
font-family: Microsoft YaHei;
font-weight: bold;
color: #1d2129;
}
</style>

@ -1,62 +1,61 @@
<template>
<div class="app-transaction">
<el-tabs class="tabs-btn" v-model="activeName" type="card" lazy="true" @tab-click="handleClick">
<el-tabs v-model="activeName" class="tabs-btn" type="card" lazy="true" @tab-click="handleClick">
<el-tab-pane
v-for="(item,index) in tabsArr"
:key="index"
:label="item.label"
:name="item.name"
v-for="(item,index) in tabsArr"
:key="index"
:label="item.label"
:name="item.name"
>
<components
<components
:is="item.name"
:id="id"
v-if="item.name == nowName"
></components>
:id="id"
/>
</el-tab-pane>
</el-tabs>
<el-button class="el-back" icon="el-icon-arrow-left" @click="back"></el-button>
</div>
</template>
<script>
import tabs1 from "./holding.vue"
import tabs2 from "./strike.vue"
import tabs1 from './holding.vue'
import tabs2 from './strike.vue'
export default {
components:{
tabs1,
tabs2
},
name: "",
name: '',
components: {
tabs1,
tabs2
},
data() {
return {
activeName: "tabs1",
nowName:"tabs1",
activeName: 'tabs1',
nowName: 'tabs1',
tabsArr: [
{
label: "模拟交易",
name: "tabs1",
label: '模拟交易',
name: 'tabs1'
},
{
label: "系统预警",
name: "tabs2",
},]
label: '系统预警',
name: 'tabs2'
}]
};
}
},
created() {},
computed: {},
created() {},
mounted() {
console.log(this.$route, '/user/profile')
},
methods: {
handleClick(tab){
tab.name == "tabs1" ? this.nowName = tab.name: this.nowName = tab.name;
handleClick(tab) {
tab.name == 'tabs1' ? this.nowName = tab.name : this.nowName = tab.name
},
back(){
this.$router.back()
back() {
this.$router.back()
}
},
mounted(){
console.log(this.$route,"/user/profile");
}
};
}
</script>
<style lang='scss' scoped>
.app-transaction {
@ -90,4 +89,4 @@ export default {
}
}
}
</style>
</style>

@ -1,6 +1,6 @@
<template>
<div>
<el-tabs class="tabs" v-model="activeName" @tab-click="handleClick">
<div class="trade-strike">
<el-tabs v-model="activeName" class="tabs" @tab-click="handleClick">
<el-tab-pane
v-for="(item, index) in tabsArr"
:key="index"
@ -9,127 +9,141 @@
>
<components
:is="item.name"
:id="id"
v-if="item.name == nowName"
></components>
:id="id"
/>
</el-tab-pane>
</el-tabs>
</div>
</div>
</template>
<script>
import tabs1 from "./components/Deposit.vue";
import tabs3 from "./components/deals.vue";
import tabs2 from "./components/orders.vue";
import tabs1 from './components/Deposit.vue'
import tabs3 from './components/deals.vue'
import tabs2 from './components/quotation.vue'
import tabs4 from './components/numberTransactions.vue'
export default {
components: {
tabs1,
tabs2,
tabs3,
tabs4
},
data() {
return {
activeName: "tabs1",
nowName: "tabs1",
activeName: 'tabs1',
nowName: 'tabs1',
tabsArr: [
{
label: "保证金预警",
name: "tabs1",
label: '保证金预警',
name: 'tabs1'
},
{
label: "行情预警",
name: "tabs2",
label: '行情预警',
name: 'tabs2'
},
{
label: "持仓时长预警",
name: "tabs3",
label: '持仓时长预警',
name: 'tabs3'
},
{
label: '交易次数预警',
name: 'tabs4'
}
],
tableData: [
{
ranking: "euresd",
class: "1612167713",
ranking: 'euresd',
class: '1612167713',
name: 1,
StudentID: "2003001",
profit: "+20000",
income: "50%",
number: "8",
Simulation: "80",
experiment: "70",
StudentID: '2003001',
profit: '+20000',
income: '50%',
number: '8',
Simulation: '80',
experiment: '70'
},
{
ranking: "euresd",
class: "1612167713",
ranking: 'euresd',
class: '1612167713',
name: 0,
StudentID: "2003001",
profit: "+20000",
income: "20%",
number: "8",
Simulation: "80",
experiment: "70",
StudentID: '2003001',
profit: '+20000',
income: '20%',
number: '8',
Simulation: '80',
experiment: '70'
},
{
ranking: "euresd",
class: "1612167713",
ranking: 'euresd',
class: '1612167713',
name: 0,
StudentID: "2003001",
profit: "+20000",
income: "20%",
number: "8",
Simulation: "80",
experiment: "70",
StudentID: '2003001',
profit: '+20000',
income: '20%',
number: '8',
Simulation: '80',
experiment: '70'
},
{
ranking: "euresd",
class: "1612167713",
ranking: 'euresd',
class: '1612167713',
name: 1,
StudentID: "2003001",
profit: "+20000",
income: "20%",
number: "8",
Simulation: "80",
experiment: "70",
StudentID: '2003001',
profit: '+20000',
income: '20%',
number: '8',
Simulation: '80',
experiment: '70'
},
{
ranking: "euresd",
class: "1612167713",
ranking: 'euresd',
class: '1612167713',
name: 0,
StudentID: "2003001",
profit: "+20000",
income: "20%",
number: "8",
Simulation: "80",
experiment: "70",
StudentID: '2003001',
profit: '+20000',
income: '20%',
number: '8',
Simulation: '80',
experiment: '70'
},
{
ranking: "euresd",
class: "1612167713",
ranking: 'euresd',
class: '1612167713',
name: 1,
StudentID: "2003001",
profit: "+20000",
income: "20%",
number: "8",
Simulation: "80",
experiment: "70",
},
],
};
StudentID: '2003001',
profit: '+20000',
income: '20%',
number: '8',
Simulation: '80',
experiment: '70'
}
]
}
},
methods: {
handleClick(tab) {
tab.name == "tabs1" ? this.nowName = tab.name: ( tab.name = "tabs2" ? this.nowName = tab.name : this.nowName = tab.name)
},
},
};
// tab.name == 'tabs1' ? this.nowName = tab.name : (tab.name = 'tabs2' ? this.nowName = tab.name : this.nowName = tab.name)
// if(tab.name)
// console.log(tab.name, 'tab')
if (this.nowName) {
this.nowName = tab.name
}
}
}
}
</script>
<style lang="scss" scoped>
.trade-strike{
background: #fff;
}
::v-deep.el-tabs {
background: #f8f8f9;
background: #fff;
padding: 0 20px;
.el-tabs__nav-wrap::after {
background: transparent;
}
.el-tabs__item {
background: #f8f8f9 !important;
background: #fff !important;
margin-right: 0px !important;
&.is-active {
background-color: #3c9cf5;
@ -140,4 +154,4 @@ export default {
.pagination-container {
margin-bottom: 20px !important;
}
</style>
</style>

Loading…
Cancel
Save