Add optional consultant parameter
This commit is contained in:
@@ -18,7 +18,7 @@
|
||||
faculty_id, faculty_color, language, assignment_document, citation_file,
|
||||
|
||||
// document info
|
||||
title, author, author_gender, supervisor, study_programme, study_branch, abstract_content,
|
||||
title, author, author_gender, supervisor, consultant, study_programme, study_branch, abstract_content,
|
||||
keywords,
|
||||
|
||||
content
|
||||
@@ -41,7 +41,7 @@
|
||||
assert_not_none(author_gender, "author gender");
|
||||
}
|
||||
|
||||
mainpage(faculty_id, language, "bp", title, author, supervisor, study_programme, study_branch);
|
||||
mainpage(faculty_id, language, "bp", title, author, supervisor, consultant, study_programme, study_branch);
|
||||
assignment(language, assignment_document);
|
||||
default_styling(false, faculty_color, {
|
||||
disclaimer(language, faculty_id, "bp", author, author_gender);
|
||||
|
@@ -12,7 +12,7 @@
|
||||
language, faculty_id, document_type, citation_file, assignment_document,
|
||||
|
||||
// document info
|
||||
title, author, author_gender, supervisor, study_programme, study_branch, abstract, keywords,
|
||||
title, author, author_gender, supervisor, consultant, study_programme, study_branch, abstract, keywords,
|
||||
|
||||
// content
|
||||
content,
|
||||
@@ -38,6 +38,7 @@
|
||||
author,
|
||||
author_gender,
|
||||
supervisor,
|
||||
consultant,
|
||||
study_programme,
|
||||
study_branch,
|
||||
abstract,
|
||||
|
@@ -96,7 +96,7 @@
|
||||
faculty_id,
|
||||
language,
|
||||
document_type,
|
||||
title, author, supervisor, study_programme, study_branch,
|
||||
title, author, supervisor, consultant, study_programme, study_branch,
|
||||
) = {
|
||||
let info_name_value_padding = 5em;
|
||||
let info_name_min_width = 10em;
|
||||
@@ -121,6 +121,7 @@
|
||||
("study_branch", study_branch, false),
|
||||
("author", author, true),
|
||||
("supervisor", supervisor, false),
|
||||
("consultant", consultant, false),
|
||||
)
|
||||
context {
|
||||
let max_field_name_width = calc.max(..info_fields.map((v) => {
|
||||
@@ -155,13 +156,13 @@
|
||||
faculty_id,
|
||||
language,
|
||||
document_type,
|
||||
title, author, supervisor, study_programme, study_branch
|
||||
title, author, supervisor, consultant, study_programme, study_branch
|
||||
) = {
|
||||
import "../utils.typ": has_all_none, map_none
|
||||
let nonetype = type(none);
|
||||
page({
|
||||
if has_all_none((
|
||||
document_type, title, author, supervisor, study_programme,
|
||||
document_type, title, author, supervisor, consultant, study_programme,
|
||||
)) {
|
||||
place(center + horizon, align(left, faculty_logotype(faculty_id, language)));
|
||||
} else {
|
||||
@@ -169,7 +170,7 @@
|
||||
align({
|
||||
info(
|
||||
faculty_id, language, document_type, map_none(title, (v) => v.at(language)),
|
||||
author, supervisor, map_none(study_programme, (v) => v.at(language)),
|
||||
author, supervisor, consultant, map_none(study_programme, (v) => v.at(language)),
|
||||
map_none(study_branch, (v) => v.at(language)),
|
||||
);
|
||||
v(5em);
|
||||
|
@@ -17,14 +17,14 @@
|
||||
faculty_id, faculty_color, language, assignment_document, citation_file,
|
||||
|
||||
// document info
|
||||
title, author, _, supervisor, study_programme, study_branch, abstract_content, keywords,
|
||||
title, author, _, supervisor, consultant, study_programme, study_branch, abstract_content, keywords,
|
||||
|
||||
content
|
||||
) = {
|
||||
assert_not_none(title, "title");
|
||||
assert_dict_has((language,), title, "title");
|
||||
|
||||
mainpage(faculty_id, language, none, title, author, supervisor, study_programme, study_branch);
|
||||
mainpage(faculty_id, language, none, title, author, supervisor, consultant, study_programme, study_branch);
|
||||
default_styling(true, faculty_color, {
|
||||
toc(language);
|
||||
abbrlist(language);
|
||||
|
@@ -3,6 +3,7 @@
|
||||
"author": "Autor",
|
||||
"authors": "Autoři",
|
||||
"supervisor": "Vedoucí práce",
|
||||
"consultant": "Konzultant práce",
|
||||
"study_programme": "Studijní program",
|
||||
"study_branch": "Studijní obor",
|
||||
|
||||
@@ -47,6 +48,7 @@
|
||||
"author": "Author",
|
||||
"authors": "Authors",
|
||||
"supervisor": "Supervisor",
|
||||
"consultant": "Consultant",
|
||||
"study_programme": "Study programme",
|
||||
"study_branch": "Study branch",
|
||||
|
||||
|
@@ -41,7 +41,7 @@
|
||||
|
||||
// document info
|
||||
title: none, keywords: none, abstract: none, author: none, author_gender: none,
|
||||
supervisor: none, programme: none, branch: none,
|
||||
supervisor: none, consultant: none, programme: none, branch: none,
|
||||
|
||||
// links
|
||||
assignment: none, citations: "citations.bib",
|
||||
@@ -64,6 +64,7 @@
|
||||
assert_type_signature(author, "string | none", "author argument");
|
||||
assert_type_signature(author_gender, "string | none", "author gender argument");
|
||||
assert_type_signature(supervisor, "string | none", "supervisor argument");
|
||||
assert_type_signature(consultant, "string | none", "consultant argument");
|
||||
assert_type_signature(
|
||||
programme, "dictionary[string : string] | none", "study programme argument"
|
||||
);
|
||||
@@ -86,8 +87,8 @@
|
||||
// template call
|
||||
templates.at(style)(
|
||||
lang, faculty, document, citations, assignment,
|
||||
title, author, author_gender, supervisor, programme, branch, abstract, keywords,
|
||||
content
|
||||
title, author, author_gender, supervisor, consultant,
|
||||
programme, branch, abstract, keywords, content
|
||||
);
|
||||
|
||||
import "prototyping.typ": assert_release_ready
|
||||
|
Reference in New Issue
Block a user