mirror of
https://github.com/bitburner-official/bitburner-src.git
synced 2024-12-23 06:32:26 +01:00
cancelOrder Params
Why is this defined in so many places
This commit is contained in:
parent
4001b4cbb0
commit
2aca8476b6
@ -13,8 +13,8 @@ import { PositionTypes } from "../data/PositionTypes";
|
||||
|
||||
import { IPlayer } from "../../PersonObjects/IPlayer";
|
||||
import { EventEmitter } from "../../utils/EventEmitter";
|
||||
import { WorkerScript } from "../../Netscript/WorkerScript";
|
||||
import { ICancelOrderParams } from "../StockMarket";
|
||||
import { NetscriptContext } from "../../Netscript/APIWrapper";
|
||||
|
||||
type txFn = (stock: Stock, shares: number) => boolean;
|
||||
type placeOrderFn = (
|
||||
@ -28,7 +28,7 @@ type placeOrderFn = (
|
||||
type IProps = {
|
||||
buyStockLong: txFn;
|
||||
buyStockShort: txFn;
|
||||
cancelOrder: (params: ICancelOrderParams, workerScript?: WorkerScript) => void;
|
||||
cancelOrder: (params: ICancelOrderParams, ctx?: NetscriptContext) => void;
|
||||
eventEmitterForReset?: EventEmitter<[]>;
|
||||
initStockMarket: () => void;
|
||||
p: IPlayer;
|
||||
|
@ -32,7 +32,7 @@ import Collapse from "@mui/material/Collapse";
|
||||
import ExpandMore from "@mui/icons-material/ExpandMore";
|
||||
import ExpandLess from "@mui/icons-material/ExpandLess";
|
||||
import { ICancelOrderParams } from "../StockMarket";
|
||||
import { WorkerScript } from "../../Netscript/WorkerScript";
|
||||
import { NetscriptContext } from "../../Netscript/APIWrapper";
|
||||
|
||||
enum SelectorOrderType {
|
||||
Market = "Market Order",
|
||||
@ -52,7 +52,7 @@ type placeOrderFn = (
|
||||
type IProps = {
|
||||
buyStockLong: txFn;
|
||||
buyStockShort: txFn;
|
||||
cancelOrder: (params: ICancelOrderParams, workerScript?: WorkerScript) => void;
|
||||
cancelOrder: (params: ICancelOrderParams, ctx?: NetscriptContext) => void;
|
||||
orders: Order[];
|
||||
p: IPlayer;
|
||||
placeOrder: placeOrderFn;
|
||||
|
@ -12,10 +12,10 @@ import Typography from "@mui/material/Typography";
|
||||
import Button from "@mui/material/Button";
|
||||
import Box from "@mui/material/Box";
|
||||
import { ICancelOrderParams } from "../StockMarket";
|
||||
import { WorkerScript } from "../../Netscript/WorkerScript";
|
||||
import { NetscriptContext } from "../../Netscript/APIWrapper";
|
||||
|
||||
type IProps = {
|
||||
cancelOrder: (params: ICancelOrderParams, workerScript?: WorkerScript) => void;
|
||||
cancelOrder: (params: ICancelOrderParams, ctx?: NetscriptContext) => void;
|
||||
order: Order;
|
||||
};
|
||||
|
||||
|
@ -11,10 +11,10 @@ import { Stock } from "../Stock";
|
||||
|
||||
import { IPlayer } from "../../PersonObjects/IPlayer";
|
||||
import { ICancelOrderParams } from "../StockMarket";
|
||||
import { WorkerScript } from "../../Netscript/WorkerScript";
|
||||
import { NetscriptContext } from "../../Netscript/APIWrapper";
|
||||
|
||||
type IProps = {
|
||||
cancelOrder: (params: ICancelOrderParams, workerScript?: WorkerScript) => void;
|
||||
cancelOrder: (params: ICancelOrderParams, ctx?: NetscriptContext) => void;
|
||||
orders: Order[];
|
||||
p: IPlayer;
|
||||
stock: Stock;
|
||||
|
@ -15,8 +15,8 @@ import { PositionTypes } from "../data/PositionTypes";
|
||||
|
||||
import { IPlayer } from "../../PersonObjects/IPlayer";
|
||||
import { EventEmitter } from "../../utils/EventEmitter";
|
||||
import { WorkerScript } from "../../Netscript/WorkerScript";
|
||||
import { ICancelOrderParams } from "../StockMarket";
|
||||
import { NetscriptContext } from "../../Netscript/APIWrapper";
|
||||
|
||||
type txFn = (stock: Stock, shares: number) => boolean;
|
||||
type placeOrderFn = (
|
||||
@ -30,7 +30,7 @@ type placeOrderFn = (
|
||||
type IProps = {
|
||||
buyStockLong: txFn;
|
||||
buyStockShort: txFn;
|
||||
cancelOrder: (params: ICancelOrderParams, workerScript?: WorkerScript) => void;
|
||||
cancelOrder: (params: ICancelOrderParams, ctx?: NetscriptContext) => void;
|
||||
eventEmitterForReset?: EventEmitter<[]>;
|
||||
p: IPlayer;
|
||||
placeOrder: placeOrderFn;
|
||||
|
Loading…
Reference in New Issue
Block a user