Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
PELUQAZ committed Dec 20, 2024
2 parents 9429e2e + 78dbf37 commit 22d98db
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 7 deletions.
10 changes: 5 additions & 5 deletions test/front/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Interactuar con el Contrato</title>
<!--<link rel="stylesheet" href="https://workmarketcap.myshopify.com/cdn/shop/t/5/assets/app.css">-->
<!--<link rel="stylesheet" href="https://workmarketcap.com/cdn/shop/t/5/assets/app.css">-->
<style>
/* Ajusta el ancho de los campos de wallet para que las direcciones se vean completas */
.wallet-input {
Expand All @@ -15,7 +15,6 @@
font-family: monospace;
/* Opcional, para mejorar la visibilidad de direcciones largas */
}

.fee-input {
width: 100%;
max-width: 50px;
Expand All @@ -38,7 +37,8 @@ <h3 class="titulo" id="titulo">Datos del Acuerdo</h3>
<input type="text" id="serviceProvider" placeholder="Wallet freelancer" class="wallet-input"><br><br>

<label for="arbitrator">Wallet árbitro:</label>
<input type="text" id="arbitrator" placeholder="Wallet árbitro" class="wallet-input"><br><br>
<input type="text" id="arbitrator" value="0x31e331E751e490ef39e8B269399a76f483b2b5Af" placeholder="Wallet árbitro"
class="wallet-input"><br><br>

<label for="startDate">Fecha inicio:</label>
<input type="date" id="startDate"><br><br>
Expand Down Expand Up @@ -75,8 +75,8 @@ <h3 class="titulo" id="titulo">Datos del Acuerdo</h3>

</br></br></br>

<button id="disagreement">Desacuerdo (SPA y SPR) ... En construcción</button>
<button id="agreement">Acuerdo (SPA y SPR) ... En construcción</button>
<button id="disagreement">Desacuerdo (SPA y SPR) ... En construcción</button></br></br>
<button id="agreement">Acuerdo (SPA y SPR) ... En construcción</button></br></br>
<button id="resolveDisagreement">Resolver desacuerdo (ARB) ... En construcción</button>

<script src="ethers.umd.min.js"></script>
Expand Down
2 changes: 0 additions & 2 deletions test/front/wmc-front-script.js
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,6 @@ async function connectWallet() {
signer = provider.getSigner();
ethereum.request({ method: "eth_requestAccounts" })
.then(async (accounts) => {
console.log("accounts = ", accounts);
const userAddress = accounts[0];
// Guarda la dirección en localStorage para usarla luego
localStorage.setItem('userAddress', userAddress);
Expand Down Expand Up @@ -141,7 +140,6 @@ async function createAgreement() {
const arbitrateFee = parseFloat(document.getElementById("arbitrateFee").value) || 0;
const daoFee = parseFloat(document.getElementById("daoFee").value) || 0;
const totalAmount = (hourlyRate * numHours) + arbitrateFee + daoFee;

// Formatear el monto total a la cantidad de decimales para USDC (6 decimales)
const amount = ethers.utils.parseUnits(totalAmount.toString(), 6);

Expand Down

0 comments on commit 22d98db

Please sign in to comment.