test g stock
This commit is contained in:
parent
c8be19a56e
commit
943d3d9a6b
15
job.go
15
job.go
@ -795,26 +795,26 @@ func jobGStock(j Job) {
|
|||||||
item, err := getObjItem(v.ItemID64)
|
item, err := getObjItem(v.ItemID64)
|
||||||
logOnError(err, "jobGStock : getObjItem")
|
logOnError(err, "jobGStock : getObjItem")
|
||||||
if err == nil {
|
if err == nil {
|
||||||
totalSize = totalSize + item.Weight*v.Quantity
|
totalSize += item.Weight * v.Quantity
|
||||||
switch item.ItemTypeID {
|
switch item.ItemTypeID {
|
||||||
case objSubTypeItemResource:
|
case objSubTypeItemResource:
|
||||||
resSize += item.Weight * v.Quantity
|
resSize += item.Weight * v.Quantity
|
||||||
resCount += 1
|
resCount += v.Quantity
|
||||||
case objSubTypeItemAlch:
|
case objSubTypeItemAlch:
|
||||||
alchSize += item.Weight * v.Quantity
|
alchSize += item.Weight * v.Quantity
|
||||||
alchCount += 1
|
alchCount += v.Quantity
|
||||||
case objSubTypeItemMisc:
|
case objSubTypeItemMisc:
|
||||||
miscSize += item.Weight * v.Quantity
|
miscSize += item.Weight * v.Quantity
|
||||||
miscCount += 1
|
miscCount += v.Quantity
|
||||||
case objSubTypeItemRecipe:
|
case objSubTypeItemRecipe:
|
||||||
recSize += item.Weight * v.Quantity
|
recSize += item.Weight * v.Quantity
|
||||||
recCount += 1
|
recCount += v.Quantity
|
||||||
case objSubTypeItemPart:
|
case objSubTypeItemPart:
|
||||||
partSize += item.Weight * v.Quantity
|
partSize += item.Weight * v.Quantity
|
||||||
partCount += 1
|
partCount += v.Quantity
|
||||||
case objSubTypeItemOther:
|
case objSubTypeItemOther:
|
||||||
otherSize += item.Weight * v.Quantity
|
otherSize += item.Weight * v.Quantity
|
||||||
otherCount += 1
|
otherCount += v.Quantity
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -831,6 +831,7 @@ func jobGStock(j Job) {
|
|||||||
Text: txt,
|
Text: txt,
|
||||||
FromMsgID64: p.MsgID64,
|
FromMsgID64: p.MsgID64,
|
||||||
FromChatID64: p.ChatID64,
|
FromChatID64: p.ChatID64,
|
||||||
|
ParseMode: cmdParseModeHTML,
|
||||||
}
|
}
|
||||||
TGCmdQueue <- m
|
TGCmdQueue <- m
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user