Skip to content

Commit

Permalink
Merge pull request #135 from pinknetworkx/add-template-buyoffers
Browse files Browse the repository at this point in the history
Add template buyoffers tables, processors and API routes
  • Loading branch information
hugomspielworks authored Nov 28, 2023
2 parents c3e9aec + f2f0bc0 commit 0e78b1c
Show file tree
Hide file tree
Showing 28 changed files with 1,553 additions and 36 deletions.
63 changes: 63 additions & 0 deletions .github/workflows/main.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
name: Main workflow

on:
push:
branches:
- main

workflow_dispatch:
inputs:
namespace:
description: 'Namespace to run deployment against'
type: choice
options:
- eos-mainnet-1
- wax-mainnet-1
- wax-testnet-1
- proton-mainnet-1
- proton-testnet-1
required: true

jobs:
test:
name: Test
uses: Spielworks-Market/backend-workflows/.github/workflows/test.yaml@main
secrets: inherit
with:
run_test_e2e: false
run_unit_test: false

build:
if: contains(fromJSON('["eos-mainnet-1", "wax-mainnet-1", "wax-testnet-1", "proton-mainnet-1", "proton-testnet-1"]'), inputs.namespace)
name: Build
needs: test
uses: Spielworks-Market/backend-workflows/.github/workflows/docker.yaml@main
with:
repository: eosio-contract-api
permissions:
id-token: write
contents: read

deploy-filler:
if: contains(fromJSON('["eos-mainnet-1", "wax-mainnet-1", "wax-testnet-1", "proton-mainnet-1", "proton-testnet-1"]'), inputs.namespace) && github.ref == 'refs/heads/main'
name: Prod filler
needs: build
uses: Spielworks-Market/eosio-contract-api-deployment/.github/workflows/deployment.yaml@master
with:
helm-namespace: ${{ inputs.namespace }}
release: filler
permissions:
id-token: write
secrets: inherit

deploy-server:
if: contains(fromJSON('["eos-mainnet-1", "wax-mainnet-1", "wax-testnet-1", "proton-mainnet-1", "proton-testnet-1"]'), inputs.namespace) && github.ref == 'refs/heads/main'
name: Prod server
needs: build
uses: Spielworks-Market/eosio-contract-api-deployment/.github/workflows/deployment.yaml@master
with:
helm-namespace: ${{ inputs.namespace }}
release: server
permissions:
id-token: write
secrets: inherit
15 changes: 15 additions & 0 deletions .github/workflows/pull-request.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
name: PR workflow

on:
pull_request:
branches:
- main

jobs:
test:
name: Test
uses: Spielworks-Market/backend-workflows/.github/workflows/test.yaml@main
secrets: inherit
with:
run_test_e2e: false
run_unit_test: false
169 changes: 169 additions & 0 deletions definitions/hasura/atomicmarket.json
Original file line number Diff line number Diff line change
Expand Up @@ -1012,6 +1012,175 @@
}
]
},
{
"table": {
"schema": "public",
"name": "atomicmarket_template_buyoffers"
},
"object_relationships": [
{
"name": "atomicassets_collection",
"using": {
"manual_configuration": {
"remote_table": {
"schema": "public",
"name": "atomicassets_collections"
},
"column_mapping": {
"collection_name": "collection_name",
"assets_contract": "contract"
}
}
}
},
{
"name": "atomicassets_template",
"using": {
"manual_configuration": {
"remote_table": {
"schema": "public",
"name": "atomicassets_templates"
},
"column_mapping": {
"template_id": "template_id",
"assets_contract": "contract"
}
}
}
},
{
"name": "atomicmarket_marketplace",
"using": {
"manual_configuration": {
"remote_table": {
"schema": "public",
"name": "atomicmarket_marketplaces"
},
"column_mapping": {
"maker_marketplace": "marketplace_name",
"market_contract": "market_contract"
}
}
}
},
{
"name": "atomicmarketMarketplaceByMarketContractTakerMarketplace",
"using": {
"manual_configuration": {
"remote_table": {
"schema": "public",
"name": "atomicmarket_marketplaces"
},
"column_mapping": {
"taker_marketplace": "marketplace_name",
"market_contract": "market_contract"
}
}
}
},
{
"name": "atomicmarket_token",
"using": {
"manual_configuration": {
"remote_table": {
"schema": "public",
"name": "atomicmarket_tokens"
},
"column_mapping": {
"token_symbol": "token_symbol",
"market_contract": "market_contract"
}
}
}
}
],
"array_relationships": [
{
"name": "atomicmarket_template_buyoffers_assets",
"using": {
"manual_configuration": {
"remote_table": {
"schema": "public",
"name": "atomicmarket_template_buyoffers_assets"
},
"column_mapping": {
"buyoffer_id": "buyoffer_id",
"market_contract": "market_contract"
}
}
}
}
],
"select_permissions": [
{
"role": "anonymous",
"permission": {
"columns": [
"market_contract",
"buyoffer_id",
"buyer",
"seller",
"price",
"token_symbol",
"assets_contract",
"maker_marketplace",
"taker_marketplace",
"collection_name",
"collection_fee",
"template_id",
"state",
"updated_at_block",
"updated_at_time",
"created_at_block",
"created_at_time"
],
"filter": {},
"limit": 1000,
"allow_aggregations": true
}
}
]
},
{
"table": {
"schema": "public",
"name": "atomicmarket_template_buyoffers_assets"
},
"object_relationships": [
{
"name": "atomicassets_asset",
"using": {
"manual_configuration": {
"remote_table": {
"schema": "public",
"name": "atomicassets_assets"
},
"column_mapping": {
"asset_id": "asset_id",
"assets_contract": "contract"
}
}
}
}
],
"select_permissions": [
{
"role": "anonymous",
"permission": {
"columns": [
"market_contract",
"buyoffer_id",
"assets_contract",
"index",
"asset_id"
],
"filter": {},
"limit": 1000,
"allow_aggregations": true
}
}
]
},
{
"table": {
"schema": "public",
Expand Down
Loading

0 comments on commit 0e78b1c

Please sign in to comment.