Skip to content

Commit d864d2d

Browse files
cssruphp-coder
authored andcommitted
/series/info: fix TemplateProcessingException when transaction doesn't have a price.
Mark first_price and first_currency fields in series_sales table as non-nullable. Fix #467
1 parent b0d0e4a commit d864d2d

File tree

2 files changed

+21
-0
lines changed

2 files changed

+21
-0
lines changed

src/main/resources/liquibase/version/0.4.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,5 +19,6 @@
1919
<include file="0.4/2016-08-22--series_sales.xml" relativeToChangelogFile="true" />
2020
<include file="0.4/2016-08-27--fix_series_sales_price.xml" relativeToChangelogFile="true" />
2121
<include file="0.4/2016-09-28--add_creator_data_to_series_sales.xml" relativeToChangelogFile="true" />
22+
<include file="0.4/2016-09-28--add_constraints_to_series-first-price.xml" relativeToChangelogFile="true" />
2223

2324
</databaseChangeLog>
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<databaseChangeLog
3+
xmlns="http://www.liquibase.org/xml/ns/dbchangelog"
4+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
5+
xsi:schemaLocation="http://www.liquibase.org/xml/ns/dbchangelog
6+
http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-3.0.xsd">
7+
8+
<changeSet id="add-not_null_constraints-to-first-price" author="cssru" context="scheme">
9+
10+
<addNotNullConstraint columnDataType="DECIMAL(19,2)"
11+
columnName="first_price"
12+
tableName="series_sales" />
13+
14+
<addNotNullConstraint columnDataType="VARCHAR(3)"
15+
columnName="first_currency"
16+
tableName="series_sales" />
17+
18+
</changeSet>
19+
20+
</databaseChangeLog>

0 commit comments

Comments
 (0)