Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
modulesServer
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
standardized
modulesServer
Commits
1946b45c
Commit
1946b45c
authored
Nov 24, 2021
by
lixinming
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
no message
parent
50981b75
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
1 deletions
+7
-1
main.ts
src/main.ts
+7
-1
No files found.
src/main.ts
View file @
1946b45c
...
...
@@ -7,10 +7,12 @@ function rand(min,max) {
return
Math
.
floor
(
Math
.
random
()
*
(
max
-
min
))
+
min
;
}
// 除了 arr[0] = ["数据名称"];这里 其他的逻辑没啥问题 这个testArr可以封装成一个方法,记得改一下名字
//有了这个方法就可以改造一下你的键值模拟数据的地方了,也就是 dataModule.ts里面的 getKeyValueModule
export
function
testArr
(
x
,
y
,
xName
,
yName
,
min
,
max
)
{
var
arr
=
[];
for
(
var
i
=
1
;
i
<
x
;
i
++
){
arr
[
0
]
=
[
"数据名称"
];
arr
[
0
]
=
[
"数据名称"
];
//这里每个循环都会重复赋值
arr
[
i
]
=
[];
arr
[
i
][
0
]
=
xName
+
i
;
for
(
var
j
=
1
;
j
<
y
;
j
++
){
...
...
@@ -20,4 +22,7 @@ export function testArr(x, y, xName, yName, min, max) {
}
}
//除了以上之外,今天的任务是:还缺少一个接口,告诉他大类型的图表,和小类型的图表对应关系,具体说明,看我电脑里的图片说明
lanuch
();
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment