mirror of
https://github.com/Qortal/q-trade.git
synced 2025-06-19 04:31:21 +00:00
fix types
This commit is contained in:
parent
733c49e33c
commit
889a1e06da
@ -19,12 +19,15 @@ import {
|
|||||||
} from "qapp-core";
|
} from "qapp-core";
|
||||||
import { formatTimestampForum } from "../../utils/formatTime";
|
import { formatTimestampForum } from "../../utils/formatTime";
|
||||||
|
|
||||||
interface NameData {
|
interface AtData {
|
||||||
name: string;
|
qortAmount: number;
|
||||||
isSelling?: boolean;
|
foreignBlockchain: string;
|
||||||
|
foreignAmount: number;
|
||||||
|
qortalAtAddress: string;
|
||||||
|
timestamp: number
|
||||||
}
|
}
|
||||||
|
|
||||||
const VirtuosoTableComponents: TableComponents<NameData> = {
|
const VirtuosoTableComponents: TableComponents<AtData> = {
|
||||||
Scroller: forwardRef<HTMLDivElement>((props, ref) => (
|
Scroller: forwardRef<HTMLDivElement>((props, ref) => (
|
||||||
<TableContainer component={Paper} {...props} ref={ref} />
|
<TableContainer component={Paper} {...props} ref={ref} />
|
||||||
)),
|
)),
|
||||||
@ -53,8 +56,8 @@ function fixedHeaderContent() {
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
function rowContent(_index: number, row: NameData) {
|
function rowContent(_index: number, row: AtData) {
|
||||||
const cancelSell = async (name: string) => {
|
const cancelSell = async () => {
|
||||||
const loadId = showLoading("Attempting to cancel sell...please wait");
|
const loadId = showLoading("Attempting to cancel sell...please wait");
|
||||||
|
|
||||||
try {
|
try {
|
||||||
@ -90,7 +93,7 @@ function rowContent(_index: number, row: NameData) {
|
|||||||
<Button
|
<Button
|
||||||
variant="contained"
|
variant="contained"
|
||||||
size="small"
|
size="small"
|
||||||
onClick={() => cancelSell(row.name)}
|
onClick={() => cancelSell()}
|
||||||
>
|
>
|
||||||
Cancel sell
|
Cancel sell
|
||||||
</Button>
|
</Button>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user