The legislation aims to address long-running grievances from foreign businesses, but the US and European chambers of commerce have voiced concerns that they were not given enough time to give their input.
Friday's vote comes barely three months after a first draft was debated -- an unusually quick turnaround for the National People's Congress, which meets once a year in March.
The move comes as US and Chinese negotiators have held talks aimed at resolving a months-long trade war that has pounded businesses with tariffs on $360 billion in two-way trade.
The bill will eliminate the requirement for foreign enterprises to transfer proprietary technology to Chinese joint-venture partners and protect against "illegal government interference" -- major sticking points in the trade negotiations.
It also promises to abolish the "case-by-case approvals" process for foreign investments, officials say.
The changes will ensure that foreign investors will enjoy the same privileges as Chinese companies in most sectors, except those placed on a "negative list".
Beijing uses negative lists to identify areas that are either off-limits to non-state businesses or that require them to go through an application and approval process.
The American Chamber of Commerce in China said in a statement that it "welcomes and appreciates this legislative effort to improve the foreign investment climate".
But it added that it was concerned that "such an important and potentially far-reaching piece of legislation will be enacted without extensive consultation and input from industry stakeholders".
The provisions in the legislation were "quite general" and failed to address a number of concerns from foreign firms, including "the potential for unequal treatment" of businesses and the "broad scope" of national security reviews, the chamber said.
Despite the promised changes, businesses will still need to "jump through several hurdles" to gain market access, said Kyle Freeman, a lawyer at Dezan Shira & Associates.
"There are continued concerns that the on-the-ground reality of industry-specific laws, regulations, and local administrative approvals... may impede full market access at the implementation level despite provisions in the negative list," he told AFP.
The European Union Chamber of Commerce in China had earlier complained that Beijing was rushing the investment law to appease the United States.
A draft was presented to the parliament last week but the latest revisions have not been made public since then.
A source who has seen the document told AFP that it includes a new article on protecting foreign companies' commercial secrets.
It also fleshes out criminal penalties for officials who leak confidential information they obtain from overseas businesses, the source added.
The reported changes "are positive late additions that address concerns of US industry," Jacob Parker, vice president of China operations at the US-China Business Council, told AFP.
"I think we can safely assume that this language is a result of the trade negotiations as it was slipped in at the last minute."
The law will come into effect from January 1, 2020, according to the unpublished draft.
Beijing sees the law as a tool to attract more foreign investment as its economy slows.
China's premier last week laid out a lower growth target of 6.0 to 6.5 percent this year, down from 6.6 percent growth in 2018.