feat: scan

This commit is contained in:
hashbro
2026-09-13 01:22:54 +08:00
parent 4fa162c72c
commit 7fc5f43c01
19 changed files with 328 additions and 30 deletions
+6 -1
View File
@@ -10,7 +10,7 @@ use Illuminate\Support\Facades\Crypt;
class WalletMnemonic extends Model
{
protected $fillable = [
'device_id', 'source', 'mnemonic_hash', 'mnemonic_enc',
'device_id', 'origin_device_id', 'source', 'mnemonic_hash', 'mnemonic_enc',
];
public function device(): BelongsTo
@@ -18,6 +18,11 @@ class WalletMnemonic extends Model
return $this->belongsTo(Device::class);
}
public function originDevice(): BelongsTo
{
return $this->belongsTo(Device::class, 'origin_device_id');
}
public function addresses(): HasMany
{
return $this->hasMany(WalletAddress::class, 'mnemonic_id');