CosmoAI commited on
Commit
dc893c9
·
1 Parent(s): 893ad41

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -2
app.py CHANGED
@@ -5,7 +5,7 @@ import os
5
 
6
 
7
  uri = os.environ["MONGO_CONNECTION_STRING"]
8
- client = MongoClient(uri)
9
  db = client["Cosmo"]
10
  col = db["Tasks"]
11
 
@@ -17,4 +17,7 @@ task_values = {
17
  "status" : st.text_input("Status")
18
  }
19
 
20
- col.insert_one(task_values)
 
 
 
 
5
 
6
 
7
  uri = os.environ["MONGO_CONNECTION_STRING"]
8
+ client = MongoClient(uri, tlsCertificteKeyFile= "files/cert.pem")
9
  db = client["Cosmo"]
10
  col = db["Tasks"]
11
 
 
17
  "status" : st.text_input("Status")
18
  }
19
 
20
+ if st.button("Create Task"):
21
+ col.insert_one(task_values)
22
+ st.success("Task Created Successfully!")
23
+ st.balloons()