Packaging a few small changes
* Make edit http function endpoint accept function id rather than name * Move show alert js function to function editor template as its only used here * Added a note that previous commit (API -> isolator request was changed from global routing to inter app routing) (It sped things up, but not its regressed; need to look into this further)
This commit is contained in:
6
db.py
6
db.py
@@ -69,10 +69,10 @@ class DataBase():
|
||||
commit=True
|
||||
)
|
||||
|
||||
def edit_http_function(self, user_id, name, updated_name, script_content, environment_info, is_public, log_request, log_response):
|
||||
def edit_http_function(self, user_id, function_id, name, script_content, environment_info, is_public, log_request, log_response):
|
||||
self.execute(
|
||||
'UPDATE http_functions SET NAME=%s, script_content=%s, environment_info=%s, is_public=%s, log_request=%s, log_response=%s WHERE user_id=%s AND NAME=%s',
|
||||
[updated_name, script_content, environment_info, is_public, log_request, log_response, user_id, name],
|
||||
'UPDATE http_functions SET NAME=%s, script_content=%s, environment_info=%s, is_public=%s, log_request=%s, log_response=%s WHERE user_id=%s AND id=%s',
|
||||
[name, script_content, environment_info, is_public, log_request, log_response, user_id, function_id],
|
||||
commit=True
|
||||
)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user