Fixed a bug in the server.js
This commit is contained in:
parent
8f13c5d080
commit
6da68389f0
@ -7,7 +7,10 @@ import Button from "@/common/components/Button";
|
||||
|
||||
export const Dialog = ({onClose, open}) => {
|
||||
|
||||
const {rounds, updateRounds, demandTable, updateDemandTable} = useContext(SettingsContext);
|
||||
const {
|
||||
rounds, updateRounds, demandTable, updateDemandTable, startCapital, setStartCapital, costPerCake,
|
||||
setCostPerCake, costPerRound, setCostPerRound, maxProduction, setMaxProduction, maxPrice, setMaxPrice
|
||||
} = useContext(SettingsContext);
|
||||
|
||||
const deleteDemand = (key) => {
|
||||
let newDemandTable = {...demandTable};
|
||||
@ -59,6 +62,36 @@ export const Dialog = ({onClose, open}) => {
|
||||
onChange={(e) => updateRounds(parseInt(e.target.value))}/>
|
||||
</div>
|
||||
|
||||
<div className="dialog-item">
|
||||
<h2>Startkapital</h2>
|
||||
<input type="number" className="glassy input" value={startCapital}
|
||||
onChange={(e) => setStartCapital(parseInt(e.target.value))}/>
|
||||
</div>
|
||||
|
||||
<div className="dialog-item">
|
||||
<h2>Kosten pro Kochen</h2>
|
||||
<input type="number" className="glassy input" value={costPerCake}
|
||||
onChange={(e) => setCostPerCake(parseInt(e.target.value))}/>
|
||||
</div>
|
||||
|
||||
<div className="dialog-item">
|
||||
<h2>Kosten pro Runde</h2>
|
||||
<input type="number" className="glassy input" value={costPerRound}
|
||||
onChange={(e) => setCostPerRound(parseInt(e.target.value))}/>
|
||||
</div>
|
||||
|
||||
<div className="dialog-item">
|
||||
<h2>Absatzmenge</h2>
|
||||
<input type="number" className="glassy input" value={maxProduction}
|
||||
onChange={(e) => setMaxProduction(parseInt(e.target.value))}/>
|
||||
</div>
|
||||
|
||||
<div className="dialog-item">
|
||||
<h2>Absatzpreis</h2>
|
||||
<input type="number" className="glassy input" value={maxPrice}
|
||||
onChange={(e) => setMaxPrice(parseInt(e.target.value))}/>
|
||||
</div>
|
||||
|
||||
<div className="dialog-sub">
|
||||
<hr/>
|
||||
<h2>Nachfrage</h2>
|
||||
|
Loading…
x
Reference in New Issue
Block a user