cityssm/lottery-licence-manager

View on GitHub
helpers/licencesDB/deleteOrganizationBankRecord.js

Summary

Maintainability
A
1 hr
Test Coverage
F
21%
import { runSQL_hasChanges } from "./_runSQL.js";
export const deleteOrganizationBankRecord = (organizationID, recordIndex, requestSession) => {
    return runSQL_hasChanges("update OrganizationBankRecords" +
        " set recordDelete_userName = ?," +
        " recordDelete_timeMillis = ?" +
        " where organizationID = ?" +
        " and recordIndex = ?" +
        " and recordDelete_timeMillis is null", [
        requestSession.user.userName,
        Date.now(),
        organizationID,
        recordIndex
    ]);
};