<?xml version="1.0" ?>
<schema xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:Setup/Declaration/Schema/etc/schema.xsd">
    <table name="reply_schedatecnica_schedatecnica" resource="default" engine="innodb" comment="reply_schedatecnica_schedatecnica Table">
        <column xsi:type="smallint" name="schedatecnica_id" padding="6" unsigned="true" nullable="false" identity="true" comment="Entity Id"/>
        <constraint xsi:type="primary" referenceId="PRIMARY">
            <column name="schedatecnica_id"/>
        </constraint>
        <column name="customer_id" padding="11" unsigned="false" nullable="false" xsi:type="int" comment="customer_id" />
        <column name="product_id" padding="11" unsigned="false" nullable="false" xsi:type="int" />
        <column name="order_id" padding="11" unsigned="false" xsi:type="int" />
        <column name="quote_id" padding="11" unsigned="false" xsi:type="int" />
        <!-- <index referenceId="REPLY_SCHEDATECNICA_SCHEDATECNICA_CUSTOMER_ID" indexType="btree">
            <column name="customer_id"/>
        </index> -->
        <column xsi:type="smallint" name="status" padding="6" unsigned="false" nullable="false" identity="false" default="0"
            comment="Scheda Tecnica Status (0: Da valutare / 1: Valida / 2: Invalida)" />
        <column xsi:type="text" name="response_json" nullable="false" comment="Response json"/>
        <column xsi:type="text" name="referer_url" nullable="false" comment="Referrer url of response"/>
        <column xsi:type="text" name="form_name" nullable="false" comment="Name of the form at the time of submitting the form"/>
        <column xsi:type="text" name="form_code" nullable="false" comment="Code of the form at the time of submitting the form"/>
        <column xsi:type="varchar" name="video_hash" nullable="true"  comment="Hash Video Id"  length="60"/>
        <column xsi:type="int" name="video_hash_callback_status" nullable="true"  comment="Hash Video Id"  unsigned="false" />
        <column xsi:type="int" name="authenticate_request_status" nullable="true"  comment="Authenticate Status"  unsigned="false" />
        <column xsi:type="int" name="provisioning_request_status" nullable="true"  comment="Provisioning Status"  unsigned="false" />
        <column xsi:type="int" name="send_mail" nullable="true"  comment="send Mail"  unsigned="false" />
        <column xsi:type="timestamp" name="created_at" on_update="false" nullable="false" default="CURRENT_TIMESTAMP" comment="Form Creation Time"/>
        <column xsi:type="datetime" name="updated_at" nullable="true" on_update="true" default="CURRENT_TIMESTAMP" comment="Date of last answer edit"/>

        <index referenceId="REPLY_SCHEDATECNICA_SCHEDATECNICA_PRODUCT_ID" indexType="btree">
            <column name="product_id"/>
        </index>
        <index referenceId="REPLY_SCHEDATECNICA_SCHEDATECNICA_ORDER_ID" indexType="btree">
            <column name="order_id"/>
        </index>
        <index referenceId="REPLY_SCHEDATECNICA_SCHEDATECNICA_CUSTOMER_ID" indexType="btree">
            <column name="customer_id"/>
        </index>
    </table>
</schema>
