How to use the portofino.Button function in portofino

To help you get started, we’ve selected a few portofino examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github ManyDesigns / Portofino / demo-tt / src / main / frontend / src / app / app.module.ts View on Github external
);
  }
}

@PortofinoComponent({ name: 'customcrud' })
export class CustomCrud extends CrudComponent {

  initialize(): void {
    console.log("Custom crud");
    super.initialize();
    this.configuration.title = 'Custom CRUD';
    this.searchComponent = CustomSearch;
    this.searchComponentContext = { customInput: "works!" };
  }

  @Button({
    list: 'search-results', text: 'Custom button', icon: 'save', color: "warn", enabledIf: CustomCrud.buttonEnabled
  })
  hello() {
    console.log("Custom button", this.configuration);
  }

  static buttonEnabled() {
    return true;
  }
}

export class CustomSearch extends SearchComponent {
  @Input()
  customInput;
  ngOnInit(): void {
    console.log("Custom search with input", this.customInput);

portofino

The Angular UI component of the Java/Groovy web application maker tool Portofino by ManyDesigns

LGPL-3.0-or-later
Latest version published 9 months ago

Package Health Score

68 / 100
Full package analysis