Even before President Carter threatened retaliation against congressional Democrats who displease him, the White House established a system that will allow it to reward its friends and penalize its enemies in doling out patronage jobs involved in taking the 1980 census.

The immediate stakes in what has become a dispute between the White House and Capitol Hill are the top supervisory jobs in the Census Bureau's 409 district offices. But beyond those jobs there is an even larger patronage pool of about 275,000 temporary jobs that will be necessary to conduct the census next year.

Under the White House plan, a presidential assistant candidly admitted, Carter loyalists in Congress can expect to see their recommendations followed on who should get the top jobs, which pay about $400 a week. Just the opposite, he said, can be expected by some other Democratic legislators, particularly those who have been most active in urging a challenge to the president by Sen. Edward M. Kennedy (D-Mass.).

Democratic members of Congress were informed of the White House plan earlier this week, shortly before Carter's Thursday night comments at a dinner for congressional Democrats at which he complained about lack of support and promised retribution.

Word of the plan was dispatched to Capitol Hill in a letter from Mikel Miller, a former official of the pro-Carter Communications Workers of America union, who since June has been the director of recruiting for the 1980 census.

Miller's letter said that, as usual, Democratic House members and senators will be invited to recommend people to fill the top supervisory positions in the Census Bureau's district offices. Those supervisors, in turn, will play important roles in filling the 275,000 lower-level jobs.

But, Miller added in his letter, the members of Congress no longer will serve as the sole source of names for the top census jobs. Instead, he said, before filling the jobs, the administration also will consult with a variety of other sources, including state and local Democratic officials, local civic leaders and the head of ethnic and neighborhood organizations.

The White House plan has outraged a number of the congressional Democrats who expected to exercise their usual patronage perogatives on a census year and who argue that they know who is best equipped to assure an accurate count.

The White House and the Census Bureau have countered by asserting that consultation with a broad base of officials is necessary if they are to produce a pool of candidates large enough to fill all the jobs. They also argue that this process is more likely to produce people who know their local area best and are therefore best equipped to survey it.

The census dispute took on added interest after Thursday night's complaint by the president at a White House dinner for the United Democrats of Congress, a group of about 60 moderate to conservative House Democrats.

Carter seemed most upset over the House's rejection only hours earlier of legislation to implement the Panama Canal treaties. "I,llbe damned if I'll send my wife into your district for a fund-raiser," one congressman quoted Carter as saying of Democrats who consistantly oppose him.

The president did not specifically mention the census jobs during his outburst but he did reportedly cite the withholding of patronage as a potential form of White House retaliation.

There are clear advantages for Carter in the way the census recruiting system has been established. In the districts of friendly congressmen, in most cases it should be no problem to hire the people recommended by the congressmen. As for pro-Kennedy and other Democrats who are on the outs with the White House, their recommendations can be rejected on the grounds that others who were consulted produced better-qualified applicants for the jobs.

Moreover, by opening up the system to state and local Democrats such as mayors and governors, the president has something to offer to Democratic officials he is heavily relying on for support of a large part of the congressional wing of the party.

A White House official familiar with the dispute said entirely too much has been made of it on Capitol Hill.

"In most cases, we will be more than happy to deal with the member", he said.The purpose of the White House plan is to "represent the interest of Congress without having to take people who are openly hostile to us" in filling the census jobs, he said.

For example, the official said, one name that came up frequently during the negotiations with Congress over the census recruiting system was that of Rep. Fortney H. (Pete) Stark Jr. of California, one of the first House Democrats to break openly with Carter and urge a Kennedy candidacy.

"We were not willing at the front end to give away the whole patronage package," particularly to acknowledged political opponents such as Stark, the official said.

"The members have been saying there is no penalty for being against the president," he added, suggesting that the census fobs offer one means to change that.

Assurances that Carter friends will be taken care of are not enough for some Democrats, especially if they're not sure they fall into that category. "There are some of us who haven't been loyal to Carter because he hasn't been loyal to us," said Rep. Ray Kogovsek (D-Colo.).

But the message is slowly seeping through to others. The other day census recruiting chief Miller explained the White House plans to a pro-Carter Democrat in this way: "Christmas is coming and this year the role of Santa Claus will be played by the president. I and my staff are Santa's elves who work in Santa's workshop. We open the mail addressed to Santa.We check to see who has been naughty and nice, and then we load the sleigh."

Miller said the congressman understood immediately.