'use strict';

Object.defineProperty(exports, '__esModule', { value: true });

const index = require('./index-e0385008.js');

const appPaymodelListCss = "";

const AppPaymodelList = class {
  constructor(hostRef) {
    index.registerInstance(this, hostRef);
    this.paginationEl = undefined;
    this.query = undefined;
  }
  onSearchInput(event) {
    this.query = event.target.value;
  }
  componentDidLoad() {
    if (!(index.Build === null || index.Build === void 0 ? void 0 : index.Build.isBrowser))
      return;
  }
  render() {
    return [
      index.h("ion-content", { class: "ion-padding" }, index.h("floodteam-title-bar", null, index.h("ion-router-link", { href: "/paymodels" }, "Pay Models"), index.h("ion-buttons", { slot: "end" }, index.h("ion-button", { fill: "solid", color: "primary", href: "/paymodels/new" }, "Add"))), index.h("fireenjin-search-bar", { paginationEl: this.paginationEl, filters: [
          {
            name: "locationId",
            label: "Location",
            endpoint: "listLocations",
            icon: "business",
            resultsKey: "locations",
          },
        ] }), index.h("fireenjin-pagination", { name: "paymodels", display: "list", ref: (el) => (this.paginationEl = el), listEl: ({ result }) => (index.h("ion-item", { href: `/paymodels/${result.id}`, detail: true }, index.h("ion-label", null, index.h("h2", null, result.name ? result.name : "", " ")))), endpoint: "listPayModels", limit: 20, resultsKey: "payModels", query: this.query })),
      index.h("floodteam-navigation-footer", null),
    ];
  }
};
AppPaymodelList.style = appPaymodelListCss;

exports.app_paymodel_list = AppPaymodelList;
