Skip to content

Commit

Permalink
Merge remote-tracking branch 'si-origin/develop' into 154-dapp-refact…
Browse files Browse the repository at this point in the history
…or-23

# Conflicts:
#	.eslintrc.json
#	.prettierignore
#	packages/dapp/components/InvoiceDashboardTable.jsx
  • Loading branch information
scottrepreneur committed Feb 27, 2024
2 parents 7770a72 + 3adcca0 commit e48311b
Show file tree
Hide file tree
Showing 5 changed files with 14 additions and 12 deletions.
3 changes: 2 additions & 1 deletion .eslintrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,8 @@
"tmp/*",
".next",
"packages/subgraph/**",
"packages/contracts/test/*"
"packages/contracts/test/*",
"packages/subgraph/subgraph.template.yaml"
],
"settings": {
"import/resolver": {
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: 14.x
node-version: 18.x
- uses: actions/cache@v2
with:
path: '**/node_modules'
Expand Down
3 changes: 2 additions & 1 deletion .prettierignore
Original file line number Diff line number Diff line change
Expand Up @@ -68,4 +68,5 @@ packages/subgraph/src/types
/packages/dapp/.next/

# next.js
.next
.next
packages/subgraph/subgraph.template.yaml
6 changes: 6 additions & 0 deletions packages/subgraph/src/mappings/01/helpers/ipfs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,12 @@ export function handleIpfsDetails(
invoiceObject: InvoiceObject,
): InvoiceObject {
invoiceObject.details = details;
if (
details.toString() ==
'0x0000000000000000000000000000000000000000000000000000000000000000'
) {
return invoiceObject;
}

let hexHash = changetype<Bytes>(addQm(invoiceObject.details));
let base58Hash = hexHash.toBase58();
Expand Down
12 changes: 3 additions & 9 deletions packages/subgraph/subgraph.template.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,10 @@ dataSources:
{{#factories}}
- kind: ethereum/contract
name: SmartInvoiceFactory{{factoryName}}
# prettier-ignore
network: {{network}}
source:
address: '{{address}}'
abi: SmartInvoiceFactory{{factoryName}}
# prettier-ignore
startBlock: {{startBlock}}
mapping:
kind: ethereum/events
Expand Down Expand Up @@ -56,7 +54,6 @@ templates:
{{#v00}}
- kind: ethereum/contract
name: SmartInvoice{{factoryName}}
# prettier-ignore
network: {{network}}
source:
abi: SmartInvoice{{factoryName}}
Expand Down Expand Up @@ -99,7 +96,6 @@ templates:
{{#v01}}
- kind: ethereum/contract
name: SmartInvoiceEscrow{{factoryName}}
# prettier-ignore
network: {{network}}
source:
abi: SmartInvoiceEscrow{{factoryName}}
Expand Down Expand Up @@ -140,7 +136,6 @@ templates:
file: ./src/mappings/{{factoryName}}/invoice.ts
- kind: ethereum/contract
name: SmartInvoiceInstant{{factoryName}}
# prettier-ignore
network: {{network}}
source:
abi: SmartInvoiceInstant{{factoryName}}
Expand Down Expand Up @@ -172,7 +167,6 @@ templates:
file: ./src/mappings/{{factoryName}}/invoice.ts
- kind: ethereum/contract
name: SmartInvoiceSplitEscrow{{factoryName}}
# prettier-ignore
network: {{network}}
source:
abi: SmartInvoiceSplitEscrow{{factoryName}}
Expand Down Expand Up @@ -213,7 +207,6 @@ templates:
file: ./src/mappings/{{factoryName}}/invoice.ts
- kind: ethereum/contract
name: SmartInvoiceUpdatable{{factoryName}}
# prettier-ignore
network: {{network}}
source:
abi: SmartInvoiceUpdatable{{factoryName}}
Expand Down Expand Up @@ -262,7 +255,6 @@ templates:
{{/factories}}
- kind: ethereum/contract
name: ERC20
# prettier-ignore
network: {{network}}
source:
abi: ERC20
Expand All @@ -288,6 +280,8 @@ templates:
file: ./src/abis/{{factoryName}}/SmartInvoiceEscrow{{factoryName}}.json
- name: SmartInvoiceInstant{{factoryName}}
file: ./src/abis/{{factoryName}}/SmartInvoiceInstant{{factoryName}}.json
- name: SmartInvoiceUpdatable{{factoryName}}
file: ./src/abis/{{factoryName}}/SmartInvoiceUpdatable{{factoryName}}.json
- name: SmartInvoiceSplitEscrow{{factoryName}}
file: ./src/abis/{{factoryName}}/SmartInvoiceSplitEscrow{{factoryName}}.json
- name: SmartInvoiceUpdatable{{factoryName}}
Expand All @@ -299,4 +293,4 @@ templates:
eventHandlers:
- event: Transfer(indexed address,indexed address,uint256)
handler: handleTransfer
file: ./src/mappings/token.ts
file: ./src/mappings/token.ts

0 comments on commit e48311b

Please sign in to comment.