const { DataTypes, BOOLEAN } = require('sequelize');
const bcrypt = require('bcryptjs');
const db = require('../config/db.config');
const DocumentVerification = db.define('DocumentVerification', {
    id: {
        type: DataTypes.INTEGER,
        allowNull: false,
        autoIncrement: true,
        primaryKey: true
    },
    person_ref: {
        type: DataTypes.STRING,
        allowNull: true
    },
    document_image_path: {
        type: DataTypes.STRING,
        allowNull: true
    },
    document_back_image_path: {
        type: DataTypes.STRING,
        allowNull: true
    },
    extracted_name: {
        type: DataTypes.STRING,
        allowNull: true
    },
    extracted_dob: {
        type: DataTypes.STRING,
        allowNull: true
    },
    extracted_document_number: {
        type: DataTypes.STRING,
        allowNull: true
    },
    document_image_url: {
        type: DataTypes.STRING,
        allowNull: true
    },
    document_back_image_url: {
        type: DataTypes.STRING,
        allowNull: true
    },
    face_match: {
        type: DataTypes.BOOLEAN,
        allowNull: true
    },
}, {
    tableName: 'rc_document_verifications',
    timestamps: true,
    createdAt: 'created_at',
    updatedAt: 'updated_at'
});



module.exports = DocumentVerification;