Skip to content

Commit

Permalink
MCS fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
vovayatsyuk committed Jan 24, 2022
1 parent b5fa96d commit 96b6eb7
Show file tree
Hide file tree
Showing 3 changed files with 78 additions and 99 deletions.
99 changes: 0 additions & 99 deletions Setup/InstallSchema.php

This file was deleted.

39 changes: 39 additions & 0 deletions etc/db_schema.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
<?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="swissup_testimonials_data" resource="default" engine="innodb" comment="Swissup Testimonials Data Table">
<column xsi:type="smallint" name="testimonial_id" padding="6" unsigned="false" nullable="false" identity="true" comment="Testimonial ID"/>
<column xsi:type="smallint" name="status" padding="6" unsigned="false" nullable="false" identity="false" default="1" comment="Testimonial status"/>
<column xsi:type="datetime" name="date" on_update="false" nullable="false" comment="Testimonial creation time"/>
<column xsi:type="varchar" name="name" nullable="false" length="100" comment="User name"/>
<column xsi:type="varchar" name="email" nullable="false" length="100" comment="User email"/>
<column xsi:type="text" name="message" nullable="false" comment="User message"/>
<column xsi:type="varchar" name="company" nullable="true" length="255" comment="User company"/>
<column xsi:type="varchar" name="website" nullable="true" length="255" comment="User website"/>
<column xsi:type="varchar" name="twitter" nullable="true" length="255" comment="User twitter"/>
<column xsi:type="varchar" name="facebook" nullable="true" length="255" comment="User facebook"/>
<column xsi:type="varchar" name="image" nullable="true" length="100" comment="User image path"/>
<column xsi:type="smallint" name="rating" padding="6" unsigned="false" nullable="true" identity="false" comment="User rating"/>
<column xsi:type="smallint" name="widget" padding="6" unsigned="false" nullable="true" identity="false" default="1" comment="Show testimonial in widget"/>
<constraint xsi:type="primary" referenceId="PRIMARY">
<column name="testimonial_id"/>
</constraint>
<index referenceId="SWISSUP_TESTIMONIALS_DATA_NAME_EMAIL_MESSAGE" indexType="fulltext">
<column name="name"/>
<column name="email"/>
<column name="message"/>
</index>
</table>
<table name="swissup_testimonials_store" resource="default" engine="innodb" comment="Swissup Testimonial To Store Linkage Table">
<column xsi:type="smallint" name="testimonial_id" padding="6" unsigned="false" nullable="false" identity="false" comment="Testimonial ID"/>
<column xsi:type="smallint" name="store_id" padding="5" unsigned="true" nullable="false" identity="false" comment="Store ID"/>
<constraint xsi:type="primary" referenceId="PRIMARY">
<column name="testimonial_id"/>
<column name="store_id"/>
</constraint>
<constraint xsi:type="foreign" referenceId="FK_6075F59DE8F3F62A95A3F8371EA6D77D" table="swissup_testimonials_store" column="testimonial_id" referenceTable="swissup_testimonials_data" referenceColumn="testimonial_id" onDelete="CASCADE"/>
<constraint xsi:type="foreign" referenceId="SWISSUP_TESTIMONIALS_STORE_STORE_ID_STORE_STORE_ID" table="swissup_testimonials_store" column="store_id" referenceTable="store" referenceColumn="store_id" onDelete="CASCADE"/>
<index referenceId="SWISSUP_TESTIMONIALS_STORE_STORE_ID" indexType="btree">
<column name="store_id"/>
</index>
</table>
</schema>
39 changes: 39 additions & 0 deletions etc/db_schema_whitelist.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
{
"swissup_testimonials_data": {
"column": {
"testimonial_id": true,
"status": true,
"date": true,
"name": true,
"email": true,
"message": true,
"company": true,
"website": true,
"twitter": true,
"facebook": true,
"image": true,
"rating": true,
"widget": true
},
"index": {
"SWISSUP_TESTIMONIALS_DATA_NAME_EMAIL_MESSAGE": true
},
"constraint": {
"PRIMARY": true
}
},
"swissup_testimonials_store": {
"column": {
"testimonial_id": true,
"store_id": true
},
"index": {
"SWISSUP_TESTIMONIALS_STORE_STORE_ID": true
},
"constraint": {
"PRIMARY": true,
"FK_6075F59DE8F3F62A95A3F8371EA6D77D": true,
"SWISSUP_TESTIMONIALS_STORE_STORE_ID_STORE_STORE_ID": true
}
}
}

1 comment on commit 96b6eb7

@ci-swissuplabs
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good job! All tests are passed!

Please sign in to comment.