mirror of
				https://github.com/avatao-content/frontend-tutorial-framework
				synced 2025-11-04 13:52:55 +00:00 
			
		
		
		
	Implement changing rewriteContentWith.. config from console API
This commit is contained in:
		@@ -5,4 +5,5 @@ export class ConsoleCommand {
 | 
			
		||||
  command: string;
 | 
			
		||||
  content?: string;
 | 
			
		||||
  showLiveLogs?: boolean;
 | 
			
		||||
  rewriteContentWithProcessLogsOnDeploy?: string;
 | 
			
		||||
}
 | 
			
		||||
 
 | 
			
		||||
@@ -17,9 +17,10 @@ export class ConsoleComponent implements OnInit {
 | 
			
		||||
  rewriteContentWithProcessLogsOnDeploy: string = config.console.rewriteContentWithProcessLogsOnDeploy;
 | 
			
		||||
 | 
			
		||||
  command_handlers = {
 | 
			
		||||
    'write':        this.writeHandler.bind(this),
 | 
			
		||||
    'read':         this.readHandler.bind(this),
 | 
			
		||||
    'showLiveLogs': this.showLiveLogsHandler.bind(this)
 | 
			
		||||
    'write':                                 this.writeHandler.bind(this),
 | 
			
		||||
    'read':                                  this.readHandler.bind(this),
 | 
			
		||||
    'showLiveLogs':                          this.showLiveLogsHandler.bind(this),
 | 
			
		||||
    'rewriteContentWithProcessLogsOnDeploy': this.rewriteContentWithProcessLogsOnDeployHandler.bind(this)
 | 
			
		||||
  };
 | 
			
		||||
 | 
			
		||||
  constructor(private webSocketService: WebSocketService,
 | 
			
		||||
@@ -54,6 +55,10 @@ export class ConsoleComponent implements OnInit {
 | 
			
		||||
    this.processLogService.showLiveLogs = data.showLiveLogs;
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
  rewriteContentWithProcessLogsOnDeployHandler(data: ConsoleCommand) {
 | 
			
		||||
    this.rewriteContentWithProcessLogsOnDeploy = data.rewriteContentWithProcessLogsOnDeploy;
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
  setContent(content: string) {
 | 
			
		||||
    this.console_content = content;
 | 
			
		||||
  }
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user