Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Y
ygopro-cn-database-generator
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Packages
Packages
List
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issues
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
MyCard
ygopro-cn-database-generator
Commits
76c5bbb6
Commit
76c5bbb6
authored
Aug 24, 2024
by
nanahira
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix
parent
3f0161fd
Pipeline
#29361
failed with stages
in 59 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
src/dbreader.ts
src/dbreader.ts
+3
-3
No files found.
src/dbreader.ts
View file @
76c5bbb6
...
@@ -85,7 +85,7 @@ export class Card {
...
@@ -85,7 +85,7 @@ export class Card {
}
}
return
(
cardType
&
(
0x4000000
|
0x800000
|
0x2000
|
0x40
))
>
0
;
return
(
cardType
&
(
0x4000000
|
0x800000
|
0x2000
|
0x40
))
>
0
;
}
}
async
loadData
(
db
:
Database
)
{
async
loadData
(
db
:
Database
,
symbol
:
string
)
{
this
.
preDatas
=
this
.
datas
;
this
.
preDatas
=
this
.
datas
;
this
.
preTexts
=
this
.
texts
;
this
.
preTexts
=
this
.
texts
;
this
.
loadedDatas
=
await
db
.
get
(
"
select * from datas where id = ?
"
,
[
this
.
code
]);
this
.
loadedDatas
=
await
db
.
get
(
"
select * from datas where id = ?
"
,
[
this
.
code
]);
...
@@ -99,7 +99,7 @@ export class Card {
...
@@ -99,7 +99,7 @@ export class Card {
...
this
.
preTexts
...
this
.
preTexts
}
}
this
.
datas
.
ot
|=
0x8
;
this
.
datas
.
ot
|=
0x8
;
this
.
texts
.
desc
+=
'
\r\n\r\n\
u2605
简体中文卡
'
;
this
.
texts
.
desc
+=
'
\r\n\r\n\
u2605
'
+
symbol
;
}
}
getSQLQueries
()
{
getSQLQueries
()
{
const
datasArray
=
this
.
getDatasArray
();
const
datasArray
=
this
.
getDatasArray
();
...
@@ -228,7 +228,7 @@ export class DBReader extends Base {
...
@@ -228,7 +228,7 @@ export class DBReader extends Base {
async
run
(
cards
:
Card
[],
options
:
{
async
run
(
cards
:
Card
[],
options
:
{
extraBanlists
?:
Banlist
[]
extraBanlists
?:
Banlist
[]
}
=
{})
{
}
=
{})
{
await
Promise
.
all
(
cards
.
map
(
card
=>
card
.
loadData
(
this
.
cndb
)));
await
Promise
.
all
(
cards
.
map
(
card
=>
card
.
loadData
(
this
.
cndb
,
this
.
config
.
descSymbol
)));
const
extendedCards
=
(
await
Promise
.
all
(
cards
.
map
(
card
=>
card
.
getRelatedCards
(
this
.
cndb
)))).
flat
();
const
extendedCards
=
(
await
Promise
.
all
(
cards
.
map
(
card
=>
card
.
getRelatedCards
(
this
.
cndb
)))).
flat
();
const
allCards
=
_
.
uniqBy
(
cards
.
concat
(
extendedCards
),
(
s
)
=>
s
.
code
);
const
allCards
=
_
.
uniqBy
(
cards
.
concat
(
extendedCards
),
(
s
)
=>
s
.
code
);
const
queries
=
allCards
.
flatMap
(
card
=>
card
.
getSQLQueries
());
const
queries
=
allCards
.
flatMap
(
card
=>
card
.
getSQLQueries
());
...
...
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