feat: update revolut order data
Some checks failed
continuous-integration/drone Build is failing

This commit is contained in:
2025-03-14 10:03:52 +00:00
parent 02d606d60c
commit 2d55392050
10 changed files with 540 additions and 289 deletions

View File

@ -0,0 +1,5 @@
alter table users
change column country_code country_code varchar (3);
-- assume country_code was not actually set until now
update users
set country_code = null;

View File

@ -22,7 +22,7 @@ pub struct User {
/// If user should be contacted via email for notifications
pub contact_email: bool,
/// Users country
pub country_code: String,
pub country_code: Option<String>,
}
#[derive(FromRow, Clone, Debug, Default)]

View File

@ -441,7 +441,8 @@ impl LNVpsDb for LNVpsDbMysql {
let mut tx = self.db.begin().await?;
sqlx::query("update vm_payment set is_paid = true where id = ?")
sqlx::query("update vm_payment set is_paid = true, external_data = ? where id = ?")
.bind(&vm_payment.external_data)
.bind(&vm_payment.id)
.execute(&mut *tx)
.await?;