De Confirmacion Ya Usado Verified - Monica 9 Modificar Codigo


  "success": true,
  "message": "Code reset successfully. The code is now verified and available.",
  "new_status": "available"

✅ Verified result: API method requires Monica 9 API version 2.1+.


-- Example pseudo-check
SELECT verified FROM confirmation_codes WHERE code = :input_code;
IF verified = true THEN
    RETURN error('CODE_ALREADY_USED');
ELSE
    -- Proceed with normal verification flow
END IF;

Categoría: Soporte Técnico / Preguntas Frecuentes

Cuerpo del mensaje:

Hola a todos,

He notado que varios usuarios se encuentran con el siguiente escenario en Monica 9: intentan modificar un asiento, una factura o un documento que ya ha sido procesado, pero el sistema les pide un "código de confirmación" o simplemente les arroja un error indicando que el registro ya está verificado (verified). monica 9 modificar codigo de confirmacion ya usado verified

Esto suele suceder porque Monica 9 bloquea los registros verificados para mantener la integridad de los datos contables. Sin embargo, si necesitas hacer un cambio, aquí te explico cómo hacerlo correctamente.

Implement a specific validation layer before any attempt to re-verify a code. "success": true, "message": "Code reset successfully

When an administrator executes the "Release Code" function:

-- Step 1: Check if the code is currently linked to a valid transaction
IF EXISTS (SELECT 1 FROM TRANSACTION_TABLE WHERE VERIFICATION_CODE = @TargetCode AND STATUS = 'ACTIVE')
BEGIN
    -- Block the action if the transaction is active
    RAISERROR('Cannot modify code: Transaction is currently active and linked.', 16, 1);
END
ELSE
BEGIN
    -- Step 2: Log the action
    INSERT INTO AUDIT_LOG (ACTION, DETAILS, USER_ID, TIMESTAMP)
    VALUES ('CODE_RELEASE', 'Released code: ' + @TargetCode, @CurrentUser, GETDATE());
-- Step 3: Reset the code
    UPDATE VERIF_CODES
    SET STATUS = 0,
        TRANSACTION_REF = NULL,
        DATE_USED = NULL
    WHERE CODE_ID = @TargetCode;
END
  • Mantener logs de auditoría (tabla audits) con: entidad, campo, valor_anterior, valor_nuevo, usuario, timestamp, motivo.
  • Transacción atómica al rotar código:
  • Even after modifying the code, you might still see "ya usado". Here is why: ✅ Verified result: API method requires Monica 9

    | Symptom | Likely Cause | Fix | |---------|--------------|-----| | Code still shows used after DB change | Cache layer (Redis/Memcached) | Flush cache | | Error: "Code not found" | You changed the code string but frontend uses old one | Update the code in the client request | | Modification reverts after some time | Cron job or anti-fraud script resets status | Check automation rules in Monica 9 | | "Verified" flag missing | Some versions require a verified timestamp column | Set verified_at = NOW() |