MADRID (Reuters) - A court in the Spanish region of Andalusia on Tuesday found a group of former senior members of the Socialist party guilty in a corruption case centred around the misuse of public funds.

Known as the ERE case - the Spanish term for a layoff program - the scandal embroiled several well-known figures of the Socialist old guard and had national repercussions, contributing to the party losing its 36-year grip on power in the southern region in December.

The group includes several former ministers and two ex-presidents of the Spanish Socialist Workers’ Party (PSOE), although the events took place years before acting Prime Minister Pedro Sanchez took over as party leader.

According to court documents, the politicians allowed hundreds of millions of euros in public funds destined to help companies in financial difficulties to be misdirected with a “total lack of control”.

The trial, which opened in 2011, focused on events that took place between 2000 and 2010, with deliberations taking almost a decade to complete. In total, 19 were found guilty in the trial.

Jose Antonio Grinan, who served as labour and health minister under prime minister Felipe Gonzalez in the 1990s, and was head of the Andalusian regional government from 2009 to 2013 received a prison sentence of six years and is disqualified from public office for 15 years.

Manuel Chaves, former deputy prime minister under Jose Luis Rodriguez Zapatero, was disqualified from holding public office for nine years. During the 1990s, Chaves was a key figure in the Socialist party, leading the Andalusian regional government for almost 20 years and rising to become the party’s national president.

Magdalena Alvarez, a former public works minister and vicepresident of the European Investment Bank was disqualified for nine years.

Reactions to the sentence from prominent Spanish politicians have highlighted the case as emblematic of the country’s old party system, where power oscillated for decades between the Socialists and the conservative People’s Party.

“The two-party system brought corruption and arrogance,” said Pablo Iglesias, leader of the left-wing Podemos party, which has entered a preliminary agreement to form a government with the Socialists.

“Spain has changed and will not tolerate coruption again,” he said.