update
This commit is contained in:
@@ -49,6 +49,7 @@ def lambda_handler(event: EventBridgeEvent, context: LambdaContext) -> bool | No
|
||||
'sk': f'MONTH#{report_sk}',
|
||||
'status': 'PENDING',
|
||||
'target_month': target_month,
|
||||
'created_at': now_,
|
||||
},
|
||||
cond_expr='attribute_not_exists(sk)',
|
||||
exc_cls=ReportingConflictError,
|
||||
@@ -59,6 +60,7 @@ def lambda_handler(event: EventBridgeEvent, context: LambdaContext) -> bool | No
|
||||
'sk': f'MONTH#{report_sk}#SCHEDULE#SEND_REPORT_EMAIL',
|
||||
'target_month': target_month,
|
||||
'ttl': ttl(start_dt=report_month),
|
||||
'created_at': now_,
|
||||
},
|
||||
)
|
||||
except Exception as exc:
|
||||
|
||||
@@ -99,7 +99,7 @@ def lambda_handler(event: EventBridgeEvent, context: LambdaContext) -> bool:
|
||||
|
||||
# Add enrollment entry to billing
|
||||
try:
|
||||
canceled_by = enrollment.get('author')
|
||||
created_by = enrollment.get('author')
|
||||
course_id = enrollment['course']['id']
|
||||
course = course_layer.collection.get_items(
|
||||
KeyPair(
|
||||
@@ -125,15 +125,15 @@ def lambda_handler(event: EventBridgeEvent, context: LambdaContext) -> bool:
|
||||
'enrolled_at': enrollment['created_at'],
|
||||
'created_at': now_,
|
||||
}
|
||||
# Add canceled_by if present
|
||||
# Add created_by if present
|
||||
| (
|
||||
{
|
||||
'author': {
|
||||
'id': canceled_by['user_id'],
|
||||
'name': canceled_by['name'],
|
||||
'id': created_by['user_id'],
|
||||
'name': created_by['name'],
|
||||
}
|
||||
}
|
||||
if canceled_by
|
||||
if created_by
|
||||
else {}
|
||||
),
|
||||
cond_expr='attribute_not_exists(sk)',
|
||||
|
||||
@@ -45,7 +45,7 @@ def lambda_handler(event: EventBridgeEvent, context: LambdaContext) -> bool:
|
||||
f'vacancies#{org_id}',
|
||||
new_image['id'],
|
||||
),
|
||||
limit=100,
|
||||
limit=150,
|
||||
)
|
||||
|
||||
logger.info(
|
||||
|
||||
Reference in New Issue
Block a user