q2rad 0.1.211__tar.gz → 0.1.213__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of q2rad might be problematic. Click here for more details.
- {q2rad-0.1.211 → q2rad-0.1.213}/PKG-INFO +1 -1
- {q2rad-0.1.211 → q2rad-0.1.213}/pyproject.toml +1 -1
- {q2rad-0.1.211 → q2rad-0.1.213}/q2rad/q2appmanager.py +5 -1
- {q2rad-0.1.211 → q2rad-0.1.213}/q2rad/q2modules.py +2 -0
- {q2rad-0.1.211 → q2rad-0.1.213}/q2rad/q2packages.py +2 -0
- {q2rad-0.1.211 → q2rad-0.1.213}/q2rad/q2queries.py +2 -0
- {q2rad-0.1.211 → q2rad-0.1.213}/q2rad/q2reports.py +1 -0
- {q2rad-0.1.211 → q2rad-0.1.213}/q2rad/q2utils.py +3 -0
- q2rad-0.1.213/q2rad/version.py +1 -0
- q2rad-0.1.211/q2rad/version.py +0 -1
- {q2rad-0.1.211 → q2rad-0.1.213}/LICENSE +0 -0
- {q2rad-0.1.211 → q2rad-0.1.213}/README.md +0 -0
- {q2rad-0.1.211 → q2rad-0.1.213}/q2rad/__init__.py +0 -0
- {q2rad-0.1.211 → q2rad-0.1.213}/q2rad/__main__.py +0 -0
- {q2rad-0.1.211 → q2rad-0.1.213}/q2rad/q2actions.py +0 -0
- {q2rad-0.1.211 → q2rad-0.1.213}/q2rad/q2appselector.py +0 -0
- {q2rad-0.1.211 → q2rad-0.1.213}/q2rad/q2constants.py +0 -0
- {q2rad-0.1.211 → q2rad-0.1.213}/q2rad/q2forms.py +0 -0
- {q2rad-0.1.211 → q2rad-0.1.213}/q2rad/q2lines.py +0 -0
- {q2rad-0.1.211 → q2rad-0.1.213}/q2rad/q2make.py +0 -0
- {q2rad-0.1.211 → q2rad-0.1.213}/q2rad/q2market.py +0 -0
- {q2rad-0.1.211 → q2rad-0.1.213}/q2rad/q2rad.py +0 -0
- {q2rad-0.1.211 → q2rad-0.1.213}/q2rad/q2raddb.py +0 -0
- {q2rad-0.1.211 → q2rad-0.1.213}/q2rad/q2stylesettings.py +0 -0
|
@@ -446,13 +446,14 @@ class AppManager(Q2Form):
|
|
|
446
446
|
db_tables = db.get_tables()
|
|
447
447
|
wait_table = Q2WaitShow(len(data))
|
|
448
448
|
errors = []
|
|
449
|
+
db.transaction()
|
|
449
450
|
for table in data:
|
|
450
451
|
wait_table.step(table)
|
|
451
452
|
if table not in db_tables:
|
|
452
453
|
continue
|
|
453
454
|
wait_row = Q2WaitShow(len(data[table]))
|
|
454
455
|
if table != "packages":
|
|
455
|
-
db.cursor(f'delete from `{table}` where name
|
|
456
|
+
db.cursor(f'delete from `{table}` where substr(name,1,1) <> "_"')
|
|
456
457
|
if db.last_sql_error:
|
|
457
458
|
errors.append(db.last_sql_error)
|
|
458
459
|
for row in data[table]:
|
|
@@ -469,6 +470,7 @@ class AppManager(Q2Form):
|
|
|
469
470
|
errors.append(db.last_sql_error)
|
|
470
471
|
errors.append(db.last_record)
|
|
471
472
|
wait_row.close()
|
|
473
|
+
db.commit()
|
|
472
474
|
wait_table.close()
|
|
473
475
|
if errors:
|
|
474
476
|
q2Mess("<br>".join(errors))
|
|
@@ -491,6 +493,7 @@ class AppManager(Q2Form):
|
|
|
491
493
|
db: Q2Db = q2app.q2_app.db_data
|
|
492
494
|
db_tables = db.get_tables()
|
|
493
495
|
wait_table = Q2WaitShow(len(data))
|
|
496
|
+
db.transaction()
|
|
494
497
|
errors = []
|
|
495
498
|
for table in data:
|
|
496
499
|
wait_table.step(table)
|
|
@@ -506,6 +509,7 @@ class AppManager(Q2Form):
|
|
|
506
509
|
errors.append(db.last_sql_error)
|
|
507
510
|
# print(db.last_sql_error)
|
|
508
511
|
wait_row.close()
|
|
512
|
+
db.commit()
|
|
509
513
|
wait_table.close()
|
|
510
514
|
if errors:
|
|
511
515
|
q2Mess("<br>".join(errors))
|
|
@@ -16,6 +16,7 @@
|
|
|
16
16
|
from q2db.cursor import Q2Cursor
|
|
17
17
|
from q2gui.q2model import Q2CursorModel
|
|
18
18
|
from q2gui.q2dialogs import q2AskYN
|
|
19
|
+
from q2gui import q2app
|
|
19
20
|
from q2rad.q2utils import Q2Form
|
|
20
21
|
from q2rad.q2utils import Q2_save_and_run
|
|
21
22
|
from q2gui.q2utils import num
|
|
@@ -34,6 +35,7 @@ class Q2Modules(Q2Form, Q2_save_and_run):
|
|
|
34
35
|
|
|
35
36
|
def on_init(self):
|
|
36
37
|
self.editor_actions = Q2Actions()
|
|
38
|
+
self.db = q2app.q2_app.db_logic
|
|
37
39
|
self.add_control(
|
|
38
40
|
"name",
|
|
39
41
|
_("Name"),
|
|
@@ -18,6 +18,7 @@ from q2gui.q2model import Q2CursorModel
|
|
|
18
18
|
from q2gui.q2dialogs import q2Mess, q2AskYN
|
|
19
19
|
|
|
20
20
|
from q2rad.q2utils import Q2Form
|
|
21
|
+
from q2gui import q2app
|
|
21
22
|
import gettext
|
|
22
23
|
|
|
23
24
|
|
|
@@ -30,6 +31,7 @@ class Q2Packages(Q2Form):
|
|
|
30
31
|
self.no_view_action = True
|
|
31
32
|
|
|
32
33
|
def on_init(self):
|
|
34
|
+
self.db = q2app.q2_app.db_logic
|
|
33
35
|
self.add_control("package_name", _("Name"), datatype="char", datalen=100, pk="*")
|
|
34
36
|
self.add_control("package_pipname", _("Pip name"), datatype="char", datalen=100)
|
|
35
37
|
self.add_control("package_version", _("Version"), datatype="char", datalen=10)
|
|
@@ -23,6 +23,7 @@ import json
|
|
|
23
23
|
import gettext
|
|
24
24
|
import re
|
|
25
25
|
from q2rad.q2utils import Q2Form
|
|
26
|
+
from q2gui import q2app
|
|
26
27
|
|
|
27
28
|
_ = gettext.gettext
|
|
28
29
|
re_find_param = re.compile(r"(?::\b\w+\b|\{.+\})")
|
|
@@ -35,6 +36,7 @@ class Q2Queries(Q2Form, Q2_save_and_run):
|
|
|
35
36
|
|
|
36
37
|
def on_init(self):
|
|
37
38
|
self.create_form()
|
|
39
|
+
self.db = q2app.q2_app.db_logic
|
|
38
40
|
|
|
39
41
|
cursor: Q2Cursor = self.q2_app.db_logic.table(table_name="queries")
|
|
40
42
|
model = Q2CursorModel(cursor)
|
|
@@ -233,6 +233,7 @@ class Q2Form(_Q2Form):
|
|
|
233
233
|
self.db,
|
|
234
234
|
)
|
|
235
235
|
form = Q2Form(f"Changelog ({self.title})")
|
|
236
|
+
form.db = self.db
|
|
236
237
|
form.add_control("/")
|
|
237
238
|
form.add_control("/h", "-")
|
|
238
239
|
form.add_control("q2_mode", "Mode", datalen=3)
|
|
@@ -290,12 +291,14 @@ class q2cursor(Q2Cursor):
|
|
|
290
291
|
def __init__(self, sql="", q2_db=None, data=[]):
|
|
291
292
|
if q2_db is None:
|
|
292
293
|
q2_db = q2app.q2_app.db_data
|
|
294
|
+
self._q2_db = q2_db
|
|
293
295
|
super().__init__(q2_db, sql, data=data)
|
|
294
296
|
if q2_db.last_sql_error:
|
|
295
297
|
print(q2_db.last_sql_error)
|
|
296
298
|
|
|
297
299
|
def q2form(self):
|
|
298
300
|
form = Q2Form(self.sql)
|
|
301
|
+
form.db = self._q2_db
|
|
299
302
|
for x in self.record(0):
|
|
300
303
|
form.add_control(x, x, datalen=250)
|
|
301
304
|
form.set_model(Q2CursorModel(self))
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
__version__ = "0.1.213"
|
q2rad-0.1.211/q2rad/version.py
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
__version__ = "0.1.211"
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|