Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
B
bridge-backend
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
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
movabridge
bridge-backend
Commits
6ebef55e
Commit
6ebef55e
authored
Nov 20, 2025
by
vicotor
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix bug
parent
e865d202
Changes
4
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
16 additions
and
37 deletions
+16
-37
sync.go
chain/sync.go
+3
-0
Bridge.go
contract/bridge/Bridge.go
+8
-34
bridge.json
contract/bridge/bridge.json
+3
-3
builder.go
dao/builder.go
+2
-0
No files found.
chain/sync.go
View file @
6ebef55e
...
...
@@ -212,6 +212,9 @@ func (s *ChainSync) SyncLogs(beginHeight, endHeight int64) error {
dao
.
TokenConfigChangedEvent
.
ID
.
Hex
(),
dao
.
SwapConfigChangedEvent
.
ID
.
Hex
(),
}
//for _, t := range topics {
// log.Println("monitor topic:", t)
//}
logs
,
err
:=
s
.
d
.
GetLogs
(
s
.
chain
,
beginHeight
,
endHeight
,
topics
,
[]
string
{
s
.
chain
.
BridgeContract
,
...
...
contract/bridge/Bridge.go
View file @
6ebef55e
This diff is collapsed.
Click to expand it.
contract/bridge/bridge.json
View file @
6ebef55e
...
...
@@ -260,19 +260,19 @@
"anonymous"
:
false
,
"inputs"
:
[
{
"indexed"
:
tru
e
,
"indexed"
:
fals
e
,
"internalType"
:
"uint256"
,
"name"
:
"outId"
,
"type"
:
"uint256"
},
{
"indexed"
:
tru
e
,
"indexed"
:
fals
e
,
"internalType"
:
"uint256"
,
"name"
:
"fromChainID"
,
"type"
:
"uint256"
},
{
"indexed"
:
tru
e
,
"indexed"
:
fals
e
,
"internalType"
:
"address"
,
"name"
:
"sender"
,
"type"
:
"address"
...
...
dao/builder.go
View file @
6ebef55e
...
...
@@ -60,6 +60,7 @@ func (s *Dao) HandleEvents(chain ChainInterface, logs []types.Log) error {
allTokenConfigChanged
=
append
(
allTokenConfigChanged
,
lg
)
case
SwapConfigChangedEvent
.
ID
.
Hex
()
:
allSwapConfigChanged
=
append
(
allSwapConfigChanged
,
lg
)
log
.
WithField
(
"tx"
,
lg
.
TxHash
)
.
Info
(
"got swap config changed event"
)
case
TransferInExecutionEvent
.
ID
.
Hex
()
:
allExecuted
=
append
(
allExecuted
,
lg
)
case
TransferInRejectionEvent
.
ID
.
Hex
()
:
...
...
@@ -413,6 +414,7 @@ func (s *Dao) filterSwapConfigChanged(chain ChainInterface, txLog *types.Log, ct
if
txLog
.
Topics
[
0
]
.
Hex
()
==
SwapConfigChangedEvent
.
ID
.
Hex
()
{
configure
,
err
:=
chain
.
ParseSwapConfigChanged
(
txLog
)
if
err
!=
nil
{
log
.
WithError
(
err
)
.
Error
(
"parse SwapConfigChanged log"
)
return
err
}
info
:=
&
dbModel
.
SwapTokenInfo
{
...
...
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