|
@@ -79,7 +79,7 @@ func (r *Goods) calc() {
|
|
|
func (r *Goods) buildSql() string {
|
|
func (r *Goods) buildSql() string {
|
|
|
var sqlId utils.SQLVal = `
|
|
var sqlId utils.SQLVal = `
|
|
|
select t.goodsid,
|
|
select t.goodsid,
|
|
|
- t.goodscode,
|
|
|
|
|
|
|
+ upper(t.goodscode) goodscode,
|
|
|
t.goodsname,
|
|
t.goodsname,
|
|
|
t.marketid,
|
|
t.marketid,
|
|
|
t.goodsgroupid,
|
|
t.goodsgroupid,
|
|
@@ -130,10 +130,10 @@ func GetGoods(goodsCode string) (Goods, bool) {
|
|
|
|
|
|
|
|
// GetGoodsDecimalplace 获取商品小数位
|
|
// GetGoodsDecimalplace 获取商品小数位
|
|
|
func GetGoodsDecimalplace(goodsCode string) int {
|
|
func GetGoodsDecimalplace(goodsCode string) int {
|
|
|
- if d, ok := GetGoods(goodsCode); ok {
|
|
|
|
|
|
|
+ if d, ok := GetGoods(strings.ToUpper(goodsCode)); ok {
|
|
|
return int(d.DECIMALPLACE)
|
|
return int(d.DECIMALPLACE)
|
|
|
}
|
|
}
|
|
|
- if d, ok := GetGoods(strings.ToUpper(goodsCode)); ok {
|
|
|
|
|
|
|
+ if d, ok := GetGoods(goodsCode); ok {
|
|
|
return int(d.DECIMALPLACE)
|
|
return int(d.DECIMALPLACE)
|
|
|
}
|
|
}
|
|
|
return 0
|
|
return 0
|