///////////////////////////////////////////////////////////////////////////////////////////////////
/////////////////////////////////////// TAG FUNCTIONS ///////////////////////////////////////////
/**
* Resets the state of the application back to the start
*
* @returns -empty object
*/
export function clear() {
return {};
}
/**
* Get a list of all tags
*
* @returns {object} - returns array of tags
*/
export function tagList() {
return {
tags: [
{
tagId: 1,
name: 'Example String'
},
]
};
}
/**
* Retrives the name of an associated tagId
*
* @param tagId - number
* @returns {object} - name of tag
*/
export function tagName(tagId: number) {
return {
name: 'Name'
}
}
/**
* Deletes a tag with the given tagId
*
* @param tagId - number
* @returns {object} - empty object
*/
export function tagDelete(tagId: number) {
return {}
}
/**
* Creates a tag
*
* @param name - string
* @returns {object} - tagId
*/
export function tageCreate(name: string) {
return {
tagId: 1
}
}
///////////////////////////////////////////////////////////////////////////////////////////////////
/////////////////////////////////////// TODO FUNCTIONS ////////////////////////////////////////////
/**
* Get details about a todo Item.
*
* @param todoItemId - number
* @returns {object} - details of a given todoItem
*/
export function todoDetails(todoItemId: number) {
return {
description: 'Description',
tagIds: [
1
],
status: 'TODO',
parentId: 1,
score: 'HIGH'
}
}
/**
* Delete a todo item
*
* @param todoItemId - number
* @returns {Object} - empty object
*/
export function todoDelete(todoItemId: number) {
return {};
}