Qwael 4.0.0.0.4__tar.gz → 4.0.0.0.6__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.
- {qwael-4.0.0.0.4 → qwael-4.0.0.0.6}/PKG-INFO +1 -1
- {qwael-4.0.0.0.4 → qwael-4.0.0.0.6}/Qwael/Multidata.py +37 -36
- {qwael-4.0.0.0.4 → qwael-4.0.0.0.6}/Qwael.egg-info/PKG-INFO +1 -1
- {qwael-4.0.0.0.4 → qwael-4.0.0.0.6}/setup.py +1 -1
- {qwael-4.0.0.0.4 → qwael-4.0.0.0.6}/LICENSE +0 -0
- {qwael-4.0.0.0.4 → qwael-4.0.0.0.6}/Qwael/DR/304/260VE.py" +0 -0
- {qwael-4.0.0.0.4 → qwael-4.0.0.0.6}/Qwael/DoIP.py +0 -0
- {qwael-4.0.0.0.4 → qwael-4.0.0.0.6}/Qwael/MultiDB.py +0 -0
- {qwael-4.0.0.0.4 → qwael-4.0.0.0.6}/Qwael/__init__.py +0 -0
- {qwael-4.0.0.0.4 → qwael-4.0.0.0.6}/Qwael/filesz.py +0 -0
- {qwael-4.0.0.0.4 → qwael-4.0.0.0.6}/Qwael.egg-info/SOURCES.txt +0 -0
- {qwael-4.0.0.0.4 → qwael-4.0.0.0.6}/Qwael.egg-info/dependency_links.txt +0 -0
- {qwael-4.0.0.0.4 → qwael-4.0.0.0.6}/Qwael.egg-info/requires.txt +0 -0
- {qwael-4.0.0.0.4 → qwael-4.0.0.0.6}/Qwael.egg-info/top_level.txt +0 -0
- {qwael-4.0.0.0.4 → qwael-4.0.0.0.6}/README.md +0 -0
- {qwael-4.0.0.0.4 → qwael-4.0.0.0.6}/setup.cfg +0 -0
|
@@ -221,51 +221,52 @@ class Admin:
|
|
|
221
221
|
# db.ID_Control("Users", name="Ali", ID=bura, Control=durum)
|
|
222
222
|
# ------------------------------------------------------
|
|
223
223
|
def ID_Control(self, table, **kwargs):
|
|
224
|
-
|
|
225
|
-
|
|
224
|
+
external_id_var = None
|
|
225
|
+
external_control = None
|
|
226
226
|
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
227
|
+
# Dış değişken referansı
|
|
228
|
+
if "ID" in kwargs:
|
|
229
|
+
external_id_var = kwargs["ID"]
|
|
230
|
+
kwargs.pop("ID")
|
|
230
231
|
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
232
|
+
if "Control" in kwargs:
|
|
233
|
+
external_control = kwargs["Control"]
|
|
234
|
+
kwargs.pop("Control")
|
|
234
235
|
|
|
235
|
-
|
|
236
|
+
filters = kwargs
|
|
236
237
|
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
238
|
+
if not filters:
|
|
239
|
+
print("ID_Control Error: name gibi filtre gerekli.")
|
|
240
|
+
if external_control is not None:
|
|
241
|
+
external_control.append(False)
|
|
242
|
+
return False
|
|
242
243
|
|
|
243
|
-
|
|
244
|
-
|
|
244
|
+
where_clause = " AND ".join([f"{k}=%s" for k in filters])
|
|
245
|
+
sql = f"SELECT ID FROM {table} WHERE {where_clause} LIMIT 1"
|
|
245
246
|
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
247
|
+
try:
|
|
248
|
+
self.cursor.execute(sql, tuple(filters.values()))
|
|
249
|
+
row = self.cursor.fetchone()
|
|
249
250
|
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
251
|
+
if not row:
|
|
252
|
+
print("ID_Control: Veri yok.")
|
|
253
|
+
if external_control is not None:
|
|
254
|
+
external_control.append(False)
|
|
255
|
+
return False
|
|
255
256
|
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
257
|
+
if external_id_var is not None:
|
|
258
|
+
external_id_var.clear()
|
|
259
|
+
external_id_var["value"] = row["ID"]
|
|
259
260
|
|
|
260
|
-
|
|
261
|
+
print("ID_Control: ID bulundu:", row["ID"])
|
|
261
262
|
|
|
262
|
-
|
|
263
|
-
|
|
263
|
+
if external_control is not None:
|
|
264
|
+
external_control.append(True)
|
|
264
265
|
|
|
265
|
-
|
|
266
|
+
return row["ID"]
|
|
266
267
|
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
268
|
+
except mysql.connector.Error as e:
|
|
269
|
+
print("ID_Control Error:", e)
|
|
270
|
+
if external_control is not None:
|
|
271
|
+
external_control.append(False)
|
|
272
|
+
return False
|
|
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
|