In striking turnabout from last year, the Maryland General Assembly today overwhelmingly enacted a measure reforming the pension system for state employes and teachers that was said to heading toward bankruptcy. The final legislative approval came in a 128-to-2 vote by the House of Delegates, which only 12 months ago, under heavy pressure from union lobbyists during an election year, had rejected the same measure. The bill, approved by the Senate on a 41-to-2 vote last week, now goes to Gov. Harry R. Hughes, who has said he will sign it. Although legislative leaders expectd the pension bill, to pass this year, the near-consensus that the measure received took everyone by surprise. "You could have made a bundle betting on the vote two months ago," said House Speaker Benjamin L. Cardin. "It was really unbelievable -- four negative votes in the whole legislature on a bill that once was so controversial." The sponsors of this year's legislation made a conscious effort to avoid that controversy by ensuring that the measure had the full support of Gov. Hughes and the General Assembly's two presiding officers -- Cardin and Senate President James Clark Jr. Once the three men developed a strategy for handling the bill, they invited representatives of the teachers and public employe unions to state their objections and the changes that would be acceptable to them. Last year, union officials complained they had not been consulted on the bill's provisions. The bill enacted today establishes a new companion pension system for teachers and state employes hired after this year. The new system differs from the existing one, whech covers about 70,000 state employees and teachers, in two main respects: It would reduce annual retirement payments by at least 20 percent for employes hired after Jan. 1, 1980. For an employe whose highest three-year average salary was $15,000, for example, the yearly benefits would drop from $14,100 to $10,800. It would limit the cost-of-living increases for pensioners to 3 percent annually, unlike the present system, which requires cost/of-living increases equal to the annual jump in the consumer price index. As an incentive for members of the existing pension system to join the new one, the new system drops the present requirement that employes contribute 5 percent of their salaries toward the pension fund.