mirror of
https://github.com/lnbits/lnbits-legend.git
synced 2024-11-19 09:54:21 +01:00
add mock data and fix conv
This commit is contained in:
parent
a601e178ea
commit
56cac668ca
Binary file not shown.
@ -1,9 +1,8 @@
|
||||
import psycopg2
|
||||
import sqlite3
|
||||
import os
|
||||
import argparse
|
||||
import os
|
||||
import sqlite3
|
||||
|
||||
|
||||
import psycopg2
|
||||
from environs import Env # type: ignore
|
||||
|
||||
env = Env()
|
||||
@ -540,8 +539,8 @@ def migrate_ext(sqlite_db_file, schema, ignore_missing=True):
|
||||
# ITEMS
|
||||
res = sq.execute("SELECT * FROM items;")
|
||||
q = f"""
|
||||
INSERT INTO offlineshop.items (shop, id, name, description, image, enabled, price, unit)
|
||||
VALUES (%s, %s, %s, %s, %s, %s::boolean, %s, %s);
|
||||
INSERT INTO offlineshop.items (shop, id, name, description, image, enabled, price, unit, fiat_base_multiplier)
|
||||
VALUES (%s, %s, %s, %s, %s, %s::boolean, %s, %s, %s);
|
||||
"""
|
||||
items = res.fetchall()
|
||||
insert_to_pg(q, items)
|
||||
|
Loading…
Reference in New Issue
Block a user