A.F....... [ZBX-8928] fixed macros {ITEM.VALUE}, {ITEM.LASTVALUE} and last() macro function to obey the ZBX_HISTORY_PERIOD