(scenario_key, action, username, message=None)
| 15 | |
| 16 | |
| 17 | def add_operation_record(scenario_key, action, username, message=None): |
| 18 | if isinstance(message, dict): |
| 19 | message = deepcopy(message) |
| 20 | for key in message.keys(): |
| 21 | if "password" in key or "pwd" in key: |
| 22 | message.update({key: "****"}) |
| 23 | OperationRecord.objects.create(scenario_key=scenario_key, |
| 24 | action=action, |
| 25 | creator=str(username), |
| 26 | message=message) |
| 27 | |
| 28 | |
| 29 | class OperationRecordHandler(object): |
no test coverage detected