diff --git a/b/capital/change_ecs_name.dspy b/b/capital/change_ecs_name.dspy index 9da0230..4e9cf57 100644 --- a/b/capital/change_ecs_name.dspy +++ b/b/capital/change_ecs_name.dspy @@ -11,6 +11,8 @@ async def change_ecs_name(ns={}): "EcsId": ns.get("EcsId"), "Name": ns.get("Name") } + print(body) + print(get_signature(action, method, ecs_url, param)) url = get_signature(action, method, ecs_url, param) async with aiohttp.ClientSession() as session: async with session.request(method, url, json=body) as response: diff --git a/b/capital/delete_eip.dspy b/b/capital/delete_eip.dspy index e31a9a7..15b51c9 100644 --- a/b/capital/delete_eip.dspy +++ b/b/capital/delete_eip.dspy @@ -6,6 +6,10 @@ async def delete_eip(ns={}): param = {} url = get_signature(action, method, NETWORK_URL, param=param) body = {'EIPId': ns.get('EIPId')} + + print(body) + print(url) + async with aiohttp.ClientSession() as session: async with session.request(method, url, json=body) as response: resp = await response.text() diff --git a/b/customer/addinvitecode.dspy b/b/customer/addinvitecode.dspy index 909e802..854cef5 100644 --- a/b/customer/addinvitecode.dspy +++ b/b/customer/addinvitecode.dspy @@ -2,6 +2,12 @@ async def addinvitecode(ns): """ 生成邀请码 """ + import datetime + + now = datetime.datetime.now() + start_of_day = now.replace(hour=0, minute=0, second=0, microsecond=0) + end_of_day = now.replace(hour=23, minute=59, second=59, microsecond=999999) + db = DBPools() async with db.sqlorContext('kboss') as sor: if ns['promotingid'] and ns['iusserid']: diff --git a/b/customer/get_customer_mailcode.dspy b/b/customer/get_customer_mailcode.dspy index ea25b28..f57534a 100644 --- a/b/customer/get_customer_mailcode.dspy +++ b/b/customer/get_customer_mailcode.dspy @@ -1,4 +1,11 @@ async def get_customer_mailcode(ns): + + import datetime + now = datetime.datetime.now() + + if now.hour < 10: + print('now.hour < 10') + db = DBPools() async with db.sqlorContext('kboss') as sor: user = await sor.R('users', {'id': ns.get('user_id')})