A Virginia state lawmaker who is spending nights at a county jail after being convicted in a case tied to his relationship with a 17-year-old girl plans to run as an independent for his own seat. 

Democratic state Delegate Joseph Morrissey, of Richmond, earlier this month pleaded to a misdemeanor count of contributing to the delinquency of a minor, and agreed to resign. 

But he turned right around and vowed to run for that seat in the Jan. 13 special election. 

According to The Richmond Times-Dispatch, Morrissey said he filed a petition with hundreds of signatures before the Tuesday deadline, and will run as an independent. 

His campaign comes as Virginia Democrats are trying to push him out. In a process Morrissey objected to, local Democratic Party leaders picked their own candidate for the race on Monday, ex-union official Kevin Sullivan. 

Morrissey also will face a Republican, Matt Walton, in the race. 

Prosecutors claimed the 57-year-old Morrissey and a 17-year-old girl who worked for him as a receptionist had sex multiple times at his law office in August 2013 and texted their friends about it. Morrissey was sentenced to 12 months in jail with six suspended and will ultimately serve three months, according to one of his attorneys. 

Morrissey is now in a work-release program that allows him to work as a legislator and lawyer by day while spending nights in a county jail. 

Morrissey's bid to retain his seat, though, has angered Democratic Party leaders in the state. 

"We'll continue to weigh our options. It is truly disturbing how he has used his constituents for this political ploy," House Democratic Leader David Toscano said, according to the Times-Dispatch. 

As he pushes to return to office, Morrissey still has to serve out his jail time. And his work-release privileges could be revoked because Morrissey called a press conference to announce his re-elections plans without the required notice. 

Morrissey has a long history of courting controversy. 

A 1991 courthouse fistfight with a defense attorney earned Morrissey, then Richmond's chief prosecutor, a five-day jail sentence. 

After losing his re-election bid in 1993 under the cloud of bribery and perjury charges on which he was later acquitted, Morrissey went into private practice. He capitalized on the widely reported courthouse brawl by calling himself a "fighter" for his clients on ads plastered on city buses and decorating his office with boxing gloves. 

Fisticuffs with a building contractor led to a misdemeanor assault and battery conviction and suspension of Morrissey's law license in 2000. Three years later, the state bar revoked his license for failing to tell clients about the suspension. Unable to practice law, he taught in Ireland and then Australia before returning to Virginia in 2006 and winning four House elections in a row. 

The Associated Press contributed to this report.