Merge branch 'tibor' into 'master'
API 1.0.52 customer.phone See merge request bossanyit/aitrainer_server!76
This commit is contained in:
commit
4d7bd9b5aa
@ -11,7 +11,7 @@ plugins {
|
|||||||
}
|
}
|
||||||
|
|
||||||
group = "com.aitrainer"
|
group = "com.aitrainer"
|
||||||
version = "1.0.51"
|
version = "1.0.52"
|
||||||
java.sourceCompatibility = JavaVersion.VERSION_1_8
|
java.sourceCompatibility = JavaVersion.VERSION_1_8
|
||||||
|
|
||||||
repositories {
|
repositories {
|
||||||
|
10
data/db/update_1_0_52.sql
Normal file
10
data/db/update_1_0_52.sql
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
START TRANSACTION;
|
||||||
|
|
||||||
|
|
||||||
|
ALTER TABLE `customer`
|
||||||
|
ADD COLUMN `phone` CHAR(50) NULL DEFAULT NULL AFTER `lang`;
|
||||||
|
|
||||||
|
|
||||||
|
UPDATE configuration set config_value = "1.0.52", date_change=CURRENT_DATE WHERE config_key = "db_version";
|
||||||
|
|
||||||
|
COMMIT;
|
@ -30,6 +30,7 @@ data class Customer (
|
|||||||
@Expose var trialDate: String? = null,
|
@Expose var trialDate: String? = null,
|
||||||
@Expose var firebaseRegToken: String? = null,
|
@Expose var firebaseRegToken: String? = null,
|
||||||
@Expose var lang: String? = null,
|
@Expose var lang: String? = null,
|
||||||
|
@Expose var phone: String? = null,
|
||||||
|
|
||||||
@Id @GeneratedValue(strategy = GenerationType.IDENTITY) @Expose var customerId: Long = 0,
|
@Id @GeneratedValue(strategy = GenerationType.IDENTITY) @Expose var customerId: Long = 0,
|
||||||
)
|
)
|
||||||
|
@ -17,6 +17,6 @@ logging.config=classpath:logback-spring.xml
|
|||||||
logging.file=logs
|
logging.file=logs
|
||||||
|
|
||||||
# if the database structure has been changed, increment this version number
|
# if the database structure has been changed, increment this version number
|
||||||
application.version=1.0.51
|
application.version=1.0.52
|
||||||
|
|
||||||
jwt.secret=aitrainer
|
jwt.secret=aitrainer
|
@ -17,7 +17,7 @@ logging.config=classpath:logback-spring.xml
|
|||||||
logging.file=logs
|
logging.file=logs
|
||||||
|
|
||||||
# if the database structure has been changed, increment this version number
|
# if the database structure has been changed, increment this version number
|
||||||
application.version=1.0.51
|
application.version=1.0.52
|
||||||
|
|
||||||
jwt.secret=aitrainer
|
jwt.secret=aitrainer
|
||||||
jasypt.encryptor.password=Tibor
|
jasypt.encryptor.password=Tibor
|
||||||
|
@ -76,6 +76,7 @@ class AppCustomerPackageTest {
|
|||||||
assertEquals(customer.syncedDate, "2021-08-06 08:00:00")
|
assertEquals(customer.syncedDate, "2021-08-06 08:00:00")
|
||||||
assertEquals(customer.firebaseRegToken, "123456789asdfghjkl")
|
assertEquals(customer.firebaseRegToken, "123456789asdfghjkl")
|
||||||
assertEquals(customer.lang!!.uppercase(), "HU")
|
assertEquals(customer.lang!!.uppercase(), "HU")
|
||||||
|
assertEquals(customer.phone, "123456")
|
||||||
}
|
}
|
||||||
record[0] == Exercises::class.simpleName -> {
|
record[0] == Exercises::class.simpleName -> {
|
||||||
val exercisesJson: String = record[1]
|
val exercisesJson: String = record[1]
|
||||||
|
@ -115,6 +115,7 @@ class CustomerTests {
|
|||||||
customer.emailSubscription = 1
|
customer.emailSubscription = 1
|
||||||
customer.sportId = 2
|
customer.sportId = 2
|
||||||
customer.firebaseRegToken = "123456789asdfghjkl"
|
customer.firebaseRegToken = "123456789asdfghjkl"
|
||||||
|
customer.phone = "123456"
|
||||||
|
|
||||||
|
|
||||||
var updatedCustomer = customerRepository.save(customer)
|
var updatedCustomer = customerRepository.save(customer)
|
||||||
@ -126,6 +127,7 @@ class CustomerTests {
|
|||||||
assertEquals(updatedCustomer.dataPolicyAllowed, 1)
|
assertEquals(updatedCustomer.dataPolicyAllowed, 1)
|
||||||
assertEquals(updatedCustomer.emailSubscription, 1)
|
assertEquals(updatedCustomer.emailSubscription, 1)
|
||||||
assertEquals(updatedCustomer.firebaseRegToken, "123456789asdfghjkl")
|
assertEquals(updatedCustomer.firebaseRegToken, "123456789asdfghjkl")
|
||||||
|
assertEquals(updatedCustomer.phone, "123456")
|
||||||
|
|
||||||
|
|
||||||
customer.email = "sw@andio.biz"
|
customer.email = "sw@andio.biz"
|
||||||
|
Loading…
Reference in New Issue
Block a user