Skip to content
Snippets Groups Projects
Commit 0442e5e1 authored by vincent.steinman's avatar vincent.steinman Committed by michael.minelli
Browse files

remove tag from gitignore

parent 591514d4
No related branches found
No related tags found
No related merge requests found
Pipeline #32713 failed
...@@ -350,6 +350,6 @@ Sessionx.vim ...@@ -350,6 +350,6 @@ Sessionx.vim
.netrwhist .netrwhist
*~ *~
# Auto-generated tag files # Auto-generated tag files
tags # tags
# Persistent undo # Persistent undo
[._]*.un~ [._]*.un~
import CommanderCommand from '../CommanderCommand';
import TagAdd from './subcommands/TagAdd';
import TagDelete from './subcommands/TagDelete';
import TagGetPropose from './subcommands/TagGetPropose';
import TagPostPropose from './subcommands/TagPostPropose';
import TagAnswerPropose from './subcommands/TagAnswerPropose';
class AddTagCommand extends CommanderCommand {
protected commandName: string = 'tag';
protected defineCommand() {
this.command
.description('Manages tags');
}
protected defineSubCommands() {
TagAdd.registerOnCommand(this.command);
TagDelete.registerOnCommand(this.command);
TagGetPropose.registerOnCommand(this.command);
TagPostPropose.registerOnCommand(this.command);
TagAnswerPropose.registerOnCommand(this.command);
}
protected async commandAction(): Promise<void> { }
}
export default new AddTagCommand();
\ No newline at end of file
import CommanderCommand from '../../CommanderCommand';
import SessionManager from '../../../managers/SessionManager';
import DojoBackendManager from "../../../managers/DojoBackendManager";
import Tags from '../../../sharedByClients/models/Tag';
class TagAddCommand extends CommanderCommand {
protected commandName: string = 'add';
protected defineCommand() {
this.command
.description('Add a tag')
.argument('<tagName>', 'name of the tag') //test
.argument('<tagType>', 'type of the tag')
.action(this.commandAction.bind(this));
}
protected async commandAction(name : string, type: string): Promise<void> {
let tag : Tags | undefined;
{
if ( !await SessionManager.testSession(true, null) ) {
return;
}
tag = await DojoBackendManager.addTag(name, type);
if ( !tag ) {
return;
}
}
}
}
export default new TagAddCommand();
\ No newline at end of file
import CommanderCommand from '../../CommanderCommand';
import SessionManager from '../../../managers/SessionManager';
import TagSubmit from '../../../sharedByClients/models/TagSubmit';
import DojoBackendManager from "../../../managers/DojoBackendManager";
class TagAnswerProposeCommand extends CommanderCommand {
protected commandName: string = 'answer';
protected defineCommand() {
this.command
.description('Answer to a tag proposition')
.argument('<tagProposalName>', 'name of the tag')
.argument('<tagType>', 'name of the tag')
.argument('<tagState>', 'name of the tag')
.argument('<tagDetail>', 'name of the tag')
.action(this.commandAction.bind(this));
}
protected async commandAction(tagProposalName: string, type: string, state: string, detail: string): Promise<void> {
let tag : TagSubmit | undefined;
{
if ( !await SessionManager.testSession(true, null) ) {
return;
}
tag = await DojoBackendManager.answerProposeTag(tagProposalName, type, state, detail);
if ( !tag ) {
return;
}
}
}
}
export default new TagAnswerProposeCommand();
\ No newline at end of file
import CommanderCommand from '../../CommanderCommand';
import SessionManager from '../../../managers/SessionManager';
import DojoBackendManager from "../../../managers/DojoBackendManager";
import Tags from "../../../sharedByClients/models/Tag";
class TagDeleteCommand extends CommanderCommand {
protected commandName: string = 'delete';
protected defineCommand() {
this.command
.description('Delete a tag')
.argument('<tagName>', 'name of the tag')
.action(this.commandAction.bind(this));
}
protected async commandAction(name : string): Promise<void> {
let tag : Tags;
{
if ( !await SessionManager.testSession(true, null) ) {
return;
}
tag = await DojoBackendManager.deleteTag(name);
if ( !tag ) {
return;
}
}
}
}
export default new TagDeleteCommand();
\ No newline at end of file
import CommanderCommand from '../../CommanderCommand';
import SessionManager from '../../../managers/SessionManager';
import TagSubmit from '../../../sharedByClients/models/TagSubmit';
import DojoBackendManager from "../../../managers/DojoBackendManager";
class TagGetProposeCommand extends CommanderCommand {
protected commandName: string = 'get-propose';
protected defineCommand() {
this.command
.description('Get a tag proposition')
.argument('<stateTag>', 'state of the tags')
.action(this.commandAction.bind(this));
}
protected async commandAction(state : string): Promise<void> {
let tag : TagSubmit | undefined;
if(state == null){
state = "PendingApproval";
}
{
if ( !await SessionManager.testSession(true, null) ) {
return;
}
tag = await DojoBackendManager.getProposeTag(state);
if ( !tag ) {
return;
}
}
}
}
export default new TagGetProposeCommand();
\ No newline at end of file
import CommanderCommand from '../../CommanderCommand';
import SessionManager from '../../../managers/SessionManager';
import DojoBackendManager from "../../../managers/DojoBackendManager";
import TagSubmit from '../../../sharedByClients/models/TagSubmit';
class TagPostProposeCommand extends CommanderCommand {
protected commandName: string = 'post-propose';
protected defineCommand() {
this.command
.description('Propose a tag')
.argument('<tagName>', 'name of the tag')
.argument('<tagType>', 'type of the tag')
.action(this.commandAction.bind(this));
}
protected async commandAction(name : string, type: string): Promise<void> {
let tag : TagSubmit | undefined;
{
if ( !await SessionManager.testSession(true, null) ) {
return;
}
tag = await DojoBackendManager.postProposeTag(name, type);
if ( !tag ) {
return;
}
}
}
}
export default new TagPostProposeCommand();
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment