From b5b699217a77eb20a80a6920594f37fd144df7b0 Mon Sep 17 00:00:00 2001 From: gazebo Date: Mon, 17 Sep 2018 12:27:21 +0800 Subject: [PATCH] - alpha config added. --- business/model/sku.go | 7 ++++++- conf/app.conf | 3 ++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/business/model/sku.go b/business/model/sku.go index dba95db8c..87e45d074 100644 --- a/business/model/sku.go +++ b/business/model/sku.go @@ -186,11 +186,16 @@ type Sku struct { func (*Sku) TableUnique() [][]string { return [][]string{ - []string{"NameID", "SpecQuality", "SpecUnit", "DeletedAt"}, []string{"JdID", "DeletedAt"}, } } +func (*Sku) TableIndex() [][]string { + return [][]string{ + []string{"NameID", "SpecQuality", "SpecUnit", "DeletedAt"}, // todo 先设置为索引,之后应改为唯一索引 + } +} + type SkuNamePlaceBind struct { ModelIDCUL diff --git a/conf/app.conf b/conf/app.conf index cedecb60e..89d5234bd 100644 --- a/conf/app.conf +++ b/conf/app.conf @@ -121,4 +121,5 @@ dadaSourceID = "73753" weixinAppID = "wxbf235770edaabc5c" weixinSecret = "ba32b269a068a5b72486a0beafd171e8" -dbConnectStr = "root:WebServer@1@tcp(127.0.0.1:3306)/jxstore_alpha?charset=utf8mb4&loc=Local&parseTime=true" \ No newline at end of file +dbConnectStr = "root:WebServer@1@tcp(127.0.0.1:3306)/jxstore_alpha?charset=utf8mb4&loc=Local&parseTime=true" +enableStoreWrite = true