timelink.mhk package
Subpackages
- timelink.mhk.models package
- Submodules
- timelink.mhk.models.act module
- timelink.mhk.models.attribute module
- timelink.mhk.models.base module
- timelink.mhk.models.base_class module
- timelink.mhk.models.base_mappings module
- timelink.mhk.models.db module
- timelink.mhk.models.entity module
EntityEntity.containsEntity.get_entity()Entity.get_orm_entities_classes()Entity.get_orm_for_pom_class()Entity.get_orm_for_table()Entity.get_som_mapper_ids()Entity.get_som_mapper_to_orm_as_dict()Entity.get_subclasses()Entity.get_tables_to_orm_as_dict()Entity.groupnameEntity.idEntity.indexedEntity.insideEntity.pom_classEntity.the_levelEntity.the_lineEntity.the_orderEntity.updated
- timelink.mhk.models.object module
- timelink.mhk.models.person module
- timelink.mhk.models.pom_som_mapper module
PomClassAttributesPomSomMapperPomSomMapper.containsPomSomMapper.element_class_to_column()PomSomMapper.ensure_all_mappings()PomSomMapper.ensure_mapping()PomSomMapper.get_pom_class()PomSomMapper.get_pom_class_ids()PomSomMapper.get_pom_classes()PomSomMapper.groupnamePomSomMapper.idPomSomMapper.indexedPomSomMapper.insidePomSomMapper.kgroup_to_entity()PomSomMapper.pom_classPomSomMapper.the_levelPomSomMapper.the_linePomSomMapper.the_orderPomSomMapper.updated
- timelink.mhk.models.relation module
- timelink.mhk.models.source module
- timelink.mhk.models.system module
Submodules
timelink.mhk.utilities module
Utilities for interaction with and MHK installation.
MHK is the name of Java Webapp that preceded Timelink.
Joaquim Carvalho, 2021. MIT Licence.
- timelink.mhk.utilities.get_db_pwd() str[source]
Get the password of the database from the MHK environment
- timelink.mhk.utilities.get_dbnames()[source]
Get the names of MHK databases in MySQL
A search is made in the MySQL server running in the local host port 3307
- timelink.mhk.utilities.get_env_as_dict(filename: str) dict[source]
Reads environment variables from a file and return a SafeConfig object
Rationale: SafeConfig parser requires :param filename: Name of a file :return:
- timelink.mhk.utilities.get_mhk_app_env() Type[str | None][source]
Get the mhk app environment variables from mhk-home/app/.env
The .env filed contains information used by docker to create the MHK application and some running options, like header color and docker image tags used for updates.
The .env file is created by the MHK installation process. Its contents can be changed my mhk manager commands.
- timelink.mhk.utilities.get_mhk_db_pwd()[source]
Get the password of the database from the MHK environment
- timelink.mhk.utilities.get_mhk_env() Type[str | None][source]
Get the MHK environment variables from ~/.mhk
The .mhk file contains the path for the mhk-home of the current user. It is created by the MHK install process.
- timelink.mhk.utilities.is_mhk_installed() bool[source]
Returns true if a MHK instalation is found
Checks the existence of ~/.mhk
- timelink.mhk.utilities.remove_quotes(original)[source]
Removes quotes from quoted values in env variables See https://stackoverflow.com/a/50772706 :param original: dict with env variables :return: copy of the dict with the values unquoted