module mokadi.mokadi_helper

Short summary

module botadi.mokadi.mokadi_helper

Small functions.

source on GitHub

Functions

function

truncated documentation

convert_into_days

Convert a date into the number of days from today.

parse_string_int

Converts a string into an integer. It can also be a string like ‘un’.

Documentation

Small functions.

source on GitHub

botadi.mokadi.mokadi_helper.convert_into_days(date, lang='fr', format='%Y-%m-%dT%H:%M:%S')

Convert a date into the number of days from today.

Parameters
  • date – str or datetime

  • lang – language

  • format – format to use

Returns

string

source on GitHub

botadi.mokadi.mokadi_helper.parse_string_int(text: str) int

Converts a string into an integer. It can also be a string like ‘un’.

Parameters

text – text to convert

Returns

number

source on GitHub