Qwael 4.0.0.1.0__tar.gz → 4.0.0.1.1__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.1.0 → qwael-4.0.0.1.1}/PKG-INFO +1 -1
- {qwael-4.0.0.1.0 → qwael-4.0.0.1.1}/Qwael/Multidata.py +30 -35
- {qwael-4.0.0.1.0 → qwael-4.0.0.1.1}/Qwael.egg-info/PKG-INFO +1 -1
- {qwael-4.0.0.1.0 → qwael-4.0.0.1.1}/setup.py +1 -1
- {qwael-4.0.0.1.0 → qwael-4.0.0.1.1}/LICENSE +0 -0
- {qwael-4.0.0.1.0 → qwael-4.0.0.1.1}/Qwael/DR/304/260VE.py" +0 -0
- {qwael-4.0.0.1.0 → qwael-4.0.0.1.1}/Qwael/DoIP.py +0 -0
- {qwael-4.0.0.1.0 → qwael-4.0.0.1.1}/Qwael/MultiDB.py +0 -0
- {qwael-4.0.0.1.0 → qwael-4.0.0.1.1}/Qwael/__init__.py +0 -0
- {qwael-4.0.0.1.0 → qwael-4.0.0.1.1}/Qwael/filesz.py +0 -0
- {qwael-4.0.0.1.0 → qwael-4.0.0.1.1}/Qwael.egg-info/SOURCES.txt +0 -0
- {qwael-4.0.0.1.0 → qwael-4.0.0.1.1}/Qwael.egg-info/dependency_links.txt +0 -0
- {qwael-4.0.0.1.0 → qwael-4.0.0.1.1}/Qwael.egg-info/requires.txt +0 -0
- {qwael-4.0.0.1.0 → qwael-4.0.0.1.1}/Qwael.egg-info/top_level.txt +0 -0
- {qwael-4.0.0.1.0 → qwael-4.0.0.1.1}/README.md +0 -0
- {qwael-4.0.0.1.0 → qwael-4.0.0.1.1}/setup.cfg +0 -0
|
@@ -221,47 +221,42 @@ 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
|
-
external_control = None
|
|
224
|
+
external_control = None
|
|
226
225
|
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
226
|
+
# Control değişkeni ayrı alınır
|
|
227
|
+
if "Control" in kwargs:
|
|
228
|
+
external_control = kwargs["Control"]
|
|
229
|
+
kwargs.pop("Control")
|
|
230
230
|
|
|
231
|
-
|
|
232
|
-
external_control = kwargs["Control"]
|
|
233
|
-
kwargs.pop("Control")
|
|
231
|
+
filters = kwargs
|
|
234
232
|
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
if not
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
external_control.append(False)
|
|
241
|
-
return False
|
|
242
|
-
|
|
243
|
-
where_clause = " AND ".join([f"{k}=%s" for k in filters])
|
|
244
|
-
sql = f"SELECT ID FROM {table} WHERE {where_clause} LIMIT 1"
|
|
245
|
-
|
|
246
|
-
try:
|
|
247
|
-
self.cursor.execute(sql, tuple(filters.values()))
|
|
248
|
-
row = self.cursor.fetchone()
|
|
233
|
+
if not filters:
|
|
234
|
+
print("ID_Control Error: name gibi filtre gerekli.")
|
|
235
|
+
if external_control is not None:
|
|
236
|
+
external_control.append(False)
|
|
237
|
+
return None
|
|
249
238
|
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
if external_control is not None:
|
|
253
|
-
external_control.append(False)
|
|
254
|
-
return False
|
|
239
|
+
where_clause = " AND ".join([f"{k}=%s" for k in filters])
|
|
240
|
+
sql = f"SELECT ID FROM {table} WHERE {where_clause} LIMIT 1"
|
|
255
241
|
|
|
256
|
-
|
|
242
|
+
try:
|
|
243
|
+
self.cursor.execute(sql, tuple(filters.values()))
|
|
244
|
+
row = self.cursor.fetchone()
|
|
257
245
|
|
|
246
|
+
if not row:
|
|
247
|
+
print("ID_Control: Veri yok.")
|
|
258
248
|
if external_control is not None:
|
|
259
|
-
external_control.append(
|
|
249
|
+
external_control.append(False)
|
|
250
|
+
return None
|
|
260
251
|
|
|
261
|
-
|
|
252
|
+
if external_control is not None:
|
|
253
|
+
external_control.append(True)
|
|
262
254
|
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
255
|
+
print("ID_Control: ID bulundu:", row["ID"])
|
|
256
|
+
return row["ID"] # 🔥 Sadece ID döner
|
|
257
|
+
|
|
258
|
+
except mysql.connector.Error as e:
|
|
259
|
+
print("ID_Control Error:", e)
|
|
260
|
+
if external_control is not None:
|
|
261
|
+
external_control.append(False)
|
|
262
|
+
return None
|
|
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
|