radboy 0.0.771__py3-none-any.whl → 0.0.854__py3-none-any.whl

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 radboy might be problematic. Click here for more details.

Files changed (39) hide show
  1. radboy/Comm/RxTx.py +4 -493
  2. radboy/Comm/__pycache__/RxTx.cpython-313.pyc +0 -0
  3. radboy/CookBook/CookBook.py +4 -0
  4. radboy/DB/ExerciseTracker.py +64 -27
  5. radboy/DB/GEMINI.py +146 -0
  6. radboy/DB/Prompt.py +150 -7
  7. radboy/DB/__pycache__/ExerciseTracker.cpython-313.pyc +0 -0
  8. radboy/DB/__pycache__/Prompt.cpython-313.pyc +0 -0
  9. radboy/DB/__pycache__/db.cpython-313.pyc +0 -0
  10. radboy/DB/db.py +141 -10
  11. radboy/DayLog/DayLogger.py +1 -1
  12. radboy/DayLog/__pycache__/DayLogger.cpython-313.pyc +0 -0
  13. radboy/FB/FBMTXT.py +48 -1
  14. radboy/FB/__pycache__/FBMTXT.cpython-313.pyc +0 -0
  15. radboy/HowDoYouDefineMe/CoreEmotions.py +268 -9
  16. radboy/Lookup2/Lookup2.py +31 -1
  17. radboy/Lookup2/__pycache__/Lookup2.cpython-313.pyc +0 -0
  18. radboy/RNE/RNE.py +7 -0
  19. radboy/RNE/__pycache__/RNE.cpython-313.pyc +0 -0
  20. radboy/TasksMode/SetEntryNEU.py +16 -2
  21. radboy/TasksMode/Tasks.py +546 -101
  22. radboy/TasksMode/__pycache__/SetEntryNEU.cpython-313.pyc +0 -0
  23. radboy/TasksMode/__pycache__/Tasks.cpython-313.pyc +0 -0
  24. radboy/Unified/BACKUP.py +443 -0
  25. radboy/Unified/Unified.py +2 -321
  26. radboy/Unified/__pycache__/Unified.cpython-313.pyc +0 -0
  27. radboy/Unified/__pycache__/bareCA.cpython-313.pyc +0 -0
  28. radboy/Unified/__pycache__/clearalll.cpython-313.pyc +0 -0
  29. radboy/Unified/bareCA.py +26 -2
  30. radboy/Unified/clearalll.py +6 -0
  31. radboy/__init__.py +1 -1
  32. radboy/__pycache__/__init__.cpython-313.pyc +0 -0
  33. radboy/code.png +0 -0
  34. radboy/preloader/preloader.py +70 -0
  35. radboy/preloader/preloader_func.py +688 -2
  36. {radboy-0.0.771.dist-info → radboy-0.0.854.dist-info}/METADATA +1 -1
  37. {radboy-0.0.771.dist-info → radboy-0.0.854.dist-info}/RECORD +39 -37
  38. {radboy-0.0.771.dist-info → radboy-0.0.854.dist-info}/WHEEL +0 -0
  39. {radboy-0.0.771.dist-info → radboy-0.0.854.dist-info}/top_level.txt +0 -0
radboy/Lookup2/Lookup2.py CHANGED
@@ -235,6 +235,11 @@ class Lookup:
235
235
  'cmds':['14.1','sch spec sht','schspecsht','spec sch sht','search specific short','ssps','ssp-'],
236
236
  'exec':lambda self=self:self.searchSpec(short=True),
237
237
  'desc':f'{Fore.light_blue}Search For Product by Entry Data using prompted fields'
238
+ },
239
+ uuid1():{
240
+ 'cmds':['14.2','save eid to text','save eid txt'],
241
+ 'exec':lambda self=self:self.saveEID(),
242
+ 'desc':f'{Fore.light_blue}Save An Entry to Text'
238
243
  }
239
244
  }
240
245
  def mehelp(self):
@@ -261,7 +266,32 @@ class Lookup:
261
266
  else:
262
267
  self.cmds[i]['exec']()
263
268
  break
264
-
269
+ def saveEID(self):
270
+ try:
271
+ EntryTXT=Path('EntryTXT.txt')
272
+ with Session(ENGINE) as session:
273
+ eids=Control(func=FormBuilderMkText,ptext=f"EntryId's to save to '{EntryTXT}'?",helpText="EntryId is an Integer, separate them with commas",data="list")
274
+ if eids is None:
275
+ return
276
+ tmp=[]
277
+ for eid in eids:
278
+ if eid not in tmp:
279
+ tmp.append(eid)
280
+ eids=tmp
281
+ for num,eid in enumerate(eids):
282
+ try:
283
+ eid=int(eid)
284
+ result=session.query(Entry).filter(Entry.EntryId==eid).first()
285
+ if result is not None:
286
+ mode="w"
287
+ if num > 0:
288
+ mode="a"
289
+ with open(EntryTXT,mode) as out:
290
+ out.write(strip_colors(str(result)))
291
+ except Exception as ee:
292
+ print(ee)
293
+ except Exception as e:
294
+ print(e)
265
295
  def entryDataExtrasSearchExport(self,txt_export=False):
266
296
  with Session(ENGINE) as session:
267
297
  while True:
radboy/RNE/RNE.py CHANGED
@@ -461,6 +461,13 @@ class Expiration:
461
461
  print(e)
462
462
 
463
463
  def search_expo(self,returnable=False,code=None,group=True,past_due_only=False):
464
+ gtemp=group
465
+ group=Control(func=FormBuilderMkText,ptext="Group results?",helpText=f"default is {group}",data="boolean")
466
+ if group in [None,'NaN']:
467
+ return
468
+ elif group in ['d',]:
469
+ group=gtemp
470
+
464
471
  with Session(ENGINE) as session:
465
472
  while True:
466
473
  if code != None:
Binary file
@@ -279,6 +279,7 @@ class NEUSetter:
279
279
  'TaxNote',
280
280
  'CRV',
281
281
  'Name',
282
+ 'Note',
282
283
  'Location',
283
284
  'ALT_Barcode',
284
285
  'DUP_Barcode',
@@ -289,11 +290,18 @@ class NEUSetter:
289
290
  'PalletCount',
290
291
  'ShelfCount',
291
292
  'CaseCount',
293
+ 'Expiry',
294
+ 'BestBy',
295
+ 'AquisitionDate',
296
+ 'Tags',
292
297
  ]
293
298
  fields.extend(LOCATION_FIELDS)
299
+ fields=sorted(fields,key=str)
294
300
  fct=len(fields)
301
+ t={i.name:str(i.type).lower() for i in Entry.__table__.columns}
295
302
  for num,f in enumerate(fields):
296
- msg=f'{Fore.light_green}{num}/{Fore.light_yellow}{num+1} of {Fore.light_red}{fct} -> {Fore.turquoise_4}{f}{Style.reset}'
303
+
304
+ msg=std_colorize(f,num,fct)+f"{Fore.red}[{Fore.cyan}{t[f]}{Fore.red}]{Fore.light_yellow}!{Style.reset}"
297
305
  print(msg)
298
306
  fnames=[]
299
307
  which=Prompt.__init2__(None,func=FormBuilderMkText,ptext=f"which {Fore.light_green}index{Fore.light_red}({Fore.light_green}es{Fore.light_red}){Fore.light_yellow}?: ",helpText=f"which {Fore.light_green}index{Fore.light_red}({Fore.light_green}es{Fore.light_red}){Fore.light_yellow}, use comma to separate multiple fields{Style.reset}",data="list")
@@ -356,9 +364,15 @@ class NEUSetter:
356
364
  for fname in fnames:
357
365
  column=getattr(Entry,fname)
358
366
  oldprice=getattr(selected,'Price')
359
- newValue=Prompt.__init2__(None,func=FormBuilderMkText,ptext=f"[{Fore.medium_violet_red}old{Fore.light_yellow}] {Fore.light_magenta}{fname} = {Fore.light_red}{getattr(selected,fname)}{Fore.orange_red_1} to: {Style.reset}",helpText="new value",data=str(column.type))
367
+ if fname.lower() in ['tags','tag']:
368
+ TYPE="list"
369
+ else:
370
+ TYPE=str(column.type)
371
+ newValue=Prompt.__init2__(None,func=FormBuilderMkText,ptext=f"[{Fore.medium_violet_red}old{Fore.light_yellow}] {Fore.light_magenta}{fname} = {Fore.light_red}{getattr(selected,fname)}{Fore.orange_red_1} to: {Style.reset}",helpText="new value",data=TYPE)
360
372
  if newValue in [None,'d']:
361
373
  continue
374
+ if fname.lower() in ['tags','tag']:
375
+ newValue=json.dumps(newValue)
362
376
  if fname.lower() == 'tax':
363
377
  if not tax_adjusted:
364
378
  setattr(selected,fname,newValue)