根据excel刷新京西价
This commit is contained in:
@@ -1050,6 +1050,22 @@ func RefershStoreSkusMidPrice(db *DaoDB, storeIDs []int) (count int64, err error
|
||||
return ExecuteSQL(db, sql, sqlParams)
|
||||
}
|
||||
|
||||
func GetStoreSkuNamePrice(db *DaoDB) (storeSkuNamePriceList []*model.StoreSkuNamePrice, err error) {
|
||||
sql := `
|
||||
SELECT *
|
||||
FROM store_sku_name_price
|
||||
WHERE deleted_at = ?
|
||||
`
|
||||
sqlParams := []interface{}{
|
||||
utils.DefaultTimeValue,
|
||||
}
|
||||
err = GetRows(db, &storeSkuNamePriceList, sql, sqlParams...)
|
||||
if err != nil {
|
||||
return nil,err
|
||||
}
|
||||
return storeSkuNamePriceList, err
|
||||
}
|
||||
|
||||
func SetStoreSkuBindVendorPrice(storeSkuBind *model.StoreSkuBind, vendorID int, vendorPrice int) {
|
||||
switch vendorID {
|
||||
case model.VendorIDJD:
|
||||
|
||||
@@ -495,13 +495,13 @@ type StoreSkuNamePrice struct {
|
||||
|
||||
func (*StoreSkuNamePrice) TableUnique() [][]string {
|
||||
return [][]string{
|
||||
[]string{"Name", "NameIDGroup"},
|
||||
[]string{"OutSkuID", "Price", "NameIDGroup"},
|
||||
}
|
||||
}
|
||||
|
||||
func (*StoreSkuNamePrice) TableIndex() [][]string {
|
||||
return [][]string{
|
||||
[]string{"Name"},
|
||||
[]string{"OutSkuID"},
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user