mirror of
https://github.com/pds-nest/nest.git
synced 2024-11-22 04:54:18 +00:00
Add commit
This commit is contained in:
parent
b713be87d5
commit
9645b7d007
2 changed files with 3 additions and 3 deletions
|
@ -1,7 +1,6 @@
|
|||
from flask import Flask
|
||||
import os
|
||||
|
||||
|
||||
app = Flask(__name__)
|
||||
if os.getenv('COOKIE_SECRET'):
|
||||
app.secret_key = os.getenv('COOKIE_SECRET')
|
||||
|
|
|
@ -40,9 +40,10 @@ def page_repository_conditions(rid):
|
|||
|
||||
condition = Condition(content=content, type=type_)
|
||||
Base.session.add(condition)
|
||||
Base.session.commit()
|
||||
|
||||
use = Uses(cid=condition.id, rid=repository.id)
|
||||
Base.session.merge(use)
|
||||
|
||||
Base.session.commit()
|
||||
|
||||
return json_success(condition.to_json()), 200
|
||||
|
|
Loading…
Reference in a new issue