(20260218) Updating APIs
This commit is contained in:
+10
-5
@@ -51,7 +51,7 @@ import pandas as pd
|
||||
from cosec_web.cosec_web import CosecWeb
|
||||
|
||||
# TCAOFF-related:
|
||||
from helpers.async_tcaoff import AsyncTheCAOffice
|
||||
from tcaoff.async_tcaoff import AsyncTheCAOffice
|
||||
|
||||
# My utils:
|
||||
from utils_v2.system import files
|
||||
@@ -705,9 +705,14 @@ async def sync_attendance_to_tcaoff(
|
||||
over_time = wr["work_ot_hours"],
|
||||
attendance_date = wr["work_date"],
|
||||
json_notes = {
|
||||
"totHours": wr["work_hours"],
|
||||
"firstIn": wr["first_in"],
|
||||
"lastOut": wr["last_out"],
|
||||
"cosec": {
|
||||
"workSeconds": wr["work_seconds"],
|
||||
"totHours": wr["work_hours"],
|
||||
"firstIn": wr["first_in"],
|
||||
"firstInLoc": wr["first_in_loc"],
|
||||
"lastOut": wr["last_out"],
|
||||
"lastOutLoc": wr["last_out_loc"],
|
||||
}
|
||||
}
|
||||
)
|
||||
)
|
||||
@@ -743,4 +748,4 @@ async def sync_attendance_to_tcaoff(
|
||||
|
||||
if __name__ == "__main__":
|
||||
|
||||
pass
|
||||
print("SYS-PATH:", sys.path)
|
||||
|
||||
+3
-3
@@ -51,7 +51,7 @@ import pandas as pd
|
||||
from cosec_web.cosec_web import CosecWeb
|
||||
|
||||
# TCAOFF-related:
|
||||
from helpers.async_tcaoff import AsyncTheCAOffice
|
||||
from tcaoff.async_tcaoff import AsyncTheCAOffice
|
||||
|
||||
# My utils:
|
||||
from utils_v2.system import files
|
||||
@@ -284,12 +284,12 @@ async def set_scheduler(
|
||||
await yesterday_cron(
|
||||
cosec_creds = copy.deepcopy(cosec_creds),
|
||||
tcaoff_client = tcaoff_client,
|
||||
test_mode = test_mode
|
||||
# test_mode = test_mode
|
||||
)
|
||||
await today_cron(
|
||||
cosec_creds = copy.deepcopy(cosec_creds),
|
||||
tcaoff_client = tcaoff_client,
|
||||
test_mode = test_mode
|
||||
# test_mode = test_mode
|
||||
)
|
||||
printer("Test Done")
|
||||
return
|
||||
|
||||
Reference in New Issue
Block a user