Skip to content

Commit

Permalink
Merge branch 'master' of github.com:nursix/eden
Browse files Browse the repository at this point in the history
Conflicts:
	private/eden_deploy
  • Loading branch information
nursix committed Jul 15, 2020
2 parents 1948c51 + 7f7dafb commit bb9a580
Show file tree
Hide file tree
Showing 109 changed files with 6,132 additions and 2,507 deletions.
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
DRKCM-1.6.2 (2020-05-19 21:05:29)
DRKCM-1.6.2-1-g1948c51 (2020-07-15 23:07:39)
34 changes: 34 additions & 0 deletions controllers/admin.py
Original file line number Diff line number Diff line change
Expand Up @@ -1295,6 +1295,40 @@ def result():

return output

# =============================================================================
@auth.s3_requires_membership(1)
def task():
"""
Scheduler tasks: RESTful CRUD controller
"""

s3db.add_components("scheduler_task",
scheduler_run = "task_id",
)
def prep(r):

if r.component_name == "run":

component = r.component

ctable = component.table

field = ctable.traceback
from s3 import s3_text_represent
field.represent = s3_text_represent

component.configure(insertable = False,
editable = False,
)

s3task.configure_tasktable_crud(task="", status_writable=True)
return True
s3.prep = prep

return s3_rest_controller("scheduler", "task",
rheader = s3db.s3_scheduler_rheader,
)

# =============================================================================
# Configurations
# =============================================================================
Expand Down
4 changes: 3 additions & 1 deletion controllers/br.py
Original file line number Diff line number Diff line change
Expand Up @@ -478,7 +478,9 @@ def postp(r, output):
return output
s3.postp = postp

output = s3_rest_controller("pr", "person", rheader=s3db.br_rheader)
output = s3_rest_controller("pr", "person",
rheader = s3db.br_rheader,
)
return output

# -----------------------------------------------------------------------------
Expand Down
2 changes: 1 addition & 1 deletion controllers/default.py
Original file line number Diff line number Diff line change
Expand Up @@ -1415,7 +1415,7 @@ def user():
})''')

elif arg == "retrieve_password":
title = response.title = T("Retrieve Password")
title = response.title = T("Lost Password")
form = auth()

elif arg == "profile":
Expand Down
20 changes: 10 additions & 10 deletions controllers/deploy.py
Original file line number Diff line number Diff line change
Expand Up @@ -471,7 +471,7 @@ def alert_create_script():
# @ToDo: Port to _compose_form
table = s3db.msg_sms_webapi_channel
gateway = db(table.enabled == True).select(table.max_length,
limitby=(0, 1)
limitby = (0, 1)
).first()
if gateway:
max_length = gateway.max_length
Expand Down Expand Up @@ -593,7 +593,7 @@ def postp(r, output):
if r.component_name == "select":
s3.actions = [{"label": str(READ),
"url": URL(f="human_resource",
args=["[id]", "profile"],
args = ["[id]", "profile"],
),
"_class": "action-btn read",
}
Expand All @@ -602,8 +602,8 @@ def postp(r, output):
if r.component_name == "recipient":
# Open should open the HR profile, not the link
open_url = URL(f="human_resource",
args=["profile"],
vars={"alert_recipient.id": "[id]"},
args = ["profile"],
vars = {"alert_recipient.id": "[id]"},
)
# Delete should delete the link, not the HR profile
delete_url = URL(f="alert",
Expand Down Expand Up @@ -774,10 +774,10 @@ def postp(r, output):
if authorised:
s3.rfooter = s3base.S3CRUD.crud_button(
T("Link to Mission"),
_href=URL(f="email_inbox",
args=[r.id, "select"],
),
_class="action-btn link",
_href = URL(f="email_inbox",
args = [r.id, "select"],
),
_class = "action-btn link",
)
return output
s3.postp = postp
Expand Down Expand Up @@ -861,8 +861,8 @@ def postp(r, output):
if r.interactive and isinstance(output, dict) and \
not s3task._is_alive():
poll_btn = A(T("Poll"),
_class="action-btn",
_href=URL(args=[r.id, "poll"])
_class = "action-btn",
_href = URL(args=[r.id, "poll"])
)
output["rheader"] = poll_btn
return output
Expand Down
Loading

0 comments on commit bb9a580

Please sign in to comment.