1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
| <template>
| <div class="wrapper table-chart2-cont" >
| <div class="panel-box">
| <div class="panel-title clearfix">
| <div class="detail-box pull-left">
| <span class="name">{{detail.name}}</span>
| <span class="code">{{detail.code}}</span>
| </div>
| <ul class="chart-title pull-right">
| <li v-for='(navItem,idx) in NarBarArry' :key='idx' :class="navIndex == idx ? 'on li-type':'li-type'">
| <a class="chart-type" href="javascript:;" @click='ChangeChartByNav(idx,$event)'>{{navItem}}</a>
| </li>
| </ul>
| </div>
| <div class="panel-body">
| <!-- <chart2sub :ucode="ucode" :idx="navIndex" :event="event"></chart2sub> -->
| </div>
| </div>
| <div class="table">
| <div class="panel">
| </div>
| </div>
| </div>
| </template>
|
| <script>
| // import chart2sub from "./chart2sub";
|
| export default {
| // components: {chart2sub},
| watch: {},
| props: {
| code: {
| type: String,
| default() {
|
| }
| },
| ucode: {
| type: String,
| default() {
|
| }
| },
| detail: {
| type: Object,
| default() {
|
| }
| }
| },
| data() {
| return {
| NarBarArry: ['分时', '五日', '日K', '周K', '月K', '年K', '1分钟', '5分钟', '15分钟', '30分钟', '60分钟'],
| navIndex: 0,
| event: {},
| emptyShow: true,
| ChartsTime: [], // 分时图时间
| ChartstFuturesTime: [], // 分时图时间
| timer: null,
| isOptionOpt: false, // 是否自选
| type: '0', // 类型
| styleName: 'red',
| k_top_closing: 99999999999
| }
| },
| computed: {
| change() {
| return this.$route.query.code
| }
| },
| created() {
| },
| beforeDestroy() {
| },
| mounted() {
| this.styleName = window.localStorage.getItem('styleName')
| },
| methods: {
| ChangeChartByNav(idx, event) {
| this.navIndex = idx
| this.event = event
| console.log(idx, event)
| }
| }
| }
| </script>
| <style lang="less" scoped>
| .panel-box {
| // background: #1a202c;
| // padding: 0 5px;
|
| .panel-title {
| padding: 3px 10px;
| }
|
| .panel-body {
| // background: #171e2a;
| position: relative;
|
| .chart-box {
| height: 480px;
| }
| }
| }
|
| .chart-title {
| line-height: 35px;
|
| .li-type {
| float: left;
|
| &.on {
| .chart-type {
| color: #efbb53;
| }
| }
| }
|
| .chart-type {
| color: #5a657e;
| font-size: 12px;
| padding: 7px 5px;
| height: 14px;
| font-weight: 800;
| }
| }
|
| .detail-box {
| height: 40px;
| line-height: 40px;
|
| .name {
| color: #efbb53;
| font-size: 16px;
| margin-left: 8px;
| }
|
| .code {
| color: #9e9e9e;
| margin-left: 6px;
| }
| }
|
| .empty {
| padding-top: 100px;
| color: #5a657e;
|
| .iconfont {
| display: block;
| font-size: 120px;
| color: #5a657e;
| margin-bottom: 20px;
| }
| }
| </style>
|
|