Skip to content

Commit

Permalink
Merge pull request #41 from Hello-Kitchen/dev
Browse files Browse the repository at this point in the history
Dev
  • Loading branch information
JulesGresset authored Jul 5, 2024
2 parents 151cae8 + 21534c1 commit 36d9ddd
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/Components/CurrentCommand/CurrentCommand.js
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,8 @@ const Content = ({ orders, stop, config }) => (
function Footer({ config, orders, setOrders, setConfig, price, priceLess, payList }) {

async function sendFirstOrder() {
if (orders[1].length < 1)
return;
let stopCounter = 1;
let arrayId = [];

Expand Down Expand Up @@ -146,7 +148,7 @@ function Footer({ config, orders, setOrders, setConfig, price, priceLess, payLis
if (!config.payement) {
return (
<div className='w-full h-current-cmd-footer border-t border-kitchen-yellow flex flex-row gap-px bg-kitchen-yellow'>
<div className='w-1/2 h-full bg-kitchen-blue flex items-center justify-center text-white font-bold text-testpx text-center cursor-pointer' onClick={() => { const newOrders = [...orders]; newOrders[1] = [...newOrders[1], { stop: true }]; console.log(newOrders); setOrders(newOrders); }}>STOP</div>
<div className='w-1/2 h-full bg-kitchen-blue flex items-center justify-center text-white font-bold text-testpx text-center cursor-pointer' onClick={() => { if(orders[1].length < 1) return; const newOrders = [...orders]; newOrders[1] = [...newOrders[1], { stop: true }]; console.log(newOrders); setOrders(newOrders); }}>STOP</div>
{config.firstSend ? <div className='w-1/2 h-full bg-kitchen-blue flex items-center justify-center text-white font-bold text-testpx text-center cursor-pointer' onClick={sendFirstOrder}>Envoyer</div> : <div className='w-1/2 h-full bg-kitchen-blue flex items-center justify-center text-white font-bold text-testpx text-center cursor-pointer' onClick={sendOtherOrder}>Demander la suite</div>}
</div>
)
Expand Down

0 comments on commit 36d9ddd

Please sign in to comment.