# raise InvenioWebJournalNoArticleTemplateError(journal_name) # todo: new exception
# except InvenioWebJournalNoArticleTemplateError:
# register_exception(req=req)
# return webjournal_error_box(req,
# "Search Page Template not found",
# "Problem with the configuration for this journal.",
# "The system couldn't find the template for the search result page of this journal. This is a mandatory file and thus indicates that the journal was setup wrong or produced an internal error. If you are neither admin nor developer there is nothing you can do at this point, but send an email request. We apologize for the inconvenience.")
# title_msg="Problem with the configuration of this journal",
# msg="The system couldn't find a definition for an issue numbering system. Issue numbers conrol the date of the publication you are seing. This indicates that there is an error in the setup of this journal or the Software itself. There is nothing you can do at the moment. If you wish you can send an inquiry to the responsible developers. We apologize for the inconvenience.")
# rule_list = config_strings["rule"]
# try:
# if len(rule_list) == 0:
# raise InvenioWebJournalNoArticleRuleError()
# except InvenioWebJournalNoArticleRuleError, e:
# register_exception(req=req)
# return webjournal_error_box(req,
# "No searchable Articles",
# "Problem with the configuration of this journal",
# "The system couldn't find the definitions for different article kinds (e.g. News, Sports, etc.). If there is nothing defined, nothing can be shown and it thus indicates that there is either a problem with the setup of this journal or in the Software itself. There is nothing you can do at this moment. If you wish you can send an inquiry to the responsible developers. We apologize for the inconvenience.")
# category_rules = []
# if argd['category'] == []:
# # append all categories
# for rule_string in rule_list:
# marc = {}
# marc["category"] = rule_string.split(",")[0]
# rule = rule_string.split(",")[1]
# marc_datafield = rule.split(":")[0]
# marc["rule_match"] = rule.split(":")[1]
# marc["marc_tag"] = marc_datafield[1:4]
# marc["marc_ind1"] = (marc_datafield[4] == "_") and " " or marc_datafield[4]
# marc["marc_ind2"] = (marc_datafield[5] == "_") and " " or marc_datafield[5]