feat: evaluation end date
This commit is contained in:
@@ -639,6 +639,7 @@
|
||||
let courses = {{ course_list | json }};
|
||||
const legends = {{ legends | json }};
|
||||
const allow_future = {{ batch_info.allow_future }}
|
||||
const evaluation_end_date = "{{ batch_info.evaluation_end_date if batch_info.evaluation_end_date else '' }}"
|
||||
</script>
|
||||
|
||||
<link rel="stylesheet" href="https://uicdn.toast.com/calendar/latest/toastui-calendar.min.css" />
|
||||
|
||||
@@ -503,6 +503,7 @@ const remove_assessment = (e) => {
|
||||
};
|
||||
|
||||
const open_evaluation_form = (e) => {
|
||||
console.log(evaluation_end_date);
|
||||
this.eval_form = new frappe.ui.Dialog({
|
||||
title: __("Schedule Evaluation"),
|
||||
fields: [
|
||||
@@ -530,6 +531,9 @@ const open_evaluation_form = (e) => {
|
||||
min_date: new Date(
|
||||
frappe.datetime.add_days(frappe.datetime.get_today(), 1)
|
||||
),
|
||||
max_date: evaluation_end_date
|
||||
? new Date(evaluation_end_date)
|
||||
: "",
|
||||
change: () => {
|
||||
if (this.eval_form.get_value("date")) get_slots();
|
||||
},
|
||||
|
||||
@@ -43,6 +43,7 @@ def get_context(context):
|
||||
"batch_details",
|
||||
"published",
|
||||
"allow_future",
|
||||
"evaluation_end_date",
|
||||
],
|
||||
as_dict=True,
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user