extends layout

block content
  .container
    h2 Welcome to the marketplace dashboard #{inventory.user}
    .card
      ul#market.nav.nav-tabs.card-header-tabs(role='tablist')
        li.nav-item
          a.nav-link.active.text-black(href='#purchases', role='tab', aria-controls='purchases', aria-selected='true') Purchases
        li.nav-item
          a.nav-link.text-black(href='#selling', role='tab', aria-controls='selling', aria-selected='false') Selling
      .tab-content.mt-3
        #purchases.tab-pane.active(role='tabpanel' aria-labelledby='purchases-tab')
          .row
            .col
              p itemID 
            .col 
              p Item Name 
            .col
              p Price 
            .col
              p Amount 
            .col 
              p Seller
          
          for i in inventory.purchases
            .row
              .col
                p #{i.itemId}-#{i.meta}
              .col
                p #{i.name}
              .col
                p #{i.price}
              .col
                p #{i.amount}
              .col
                p #{i.seller}
        #selling.tab-pane(role='tabpanel', aria-labelledby='selling-tab')
          .row
            .col
              p itemID 
            .col 
              p Item Name 
            .col
              p Price 
            .col
              p Amount 
            .col 
              p Seller
          
          for i in inventory.listings
            .row
              .col
                p #{i.itemId}-#{i.meta}
              .col
                p #{i.name}
              .col
                p #{i.price}
              .col
                p #{i.amount}
              .col
                p #{i.seller}
      
