(CNN) The gunman who killed three people this week at a Chicago hospital was dismissed from the city's fire academy in 2014 after "bullying" issues, a spokesman told CNN.

Juan Lopez was hired on to the Chicago Fire Department Academy on March 17, 2014, spokesman Larry Merritt said. The program lasts six months long.

Lopez disappeared from duty during a "discipline process" related to "issues dealing with bullying," Merritt said, adding he could not provide further details.

The department contacted Lopez and told him to report back to the academy. He did not show up and was fired on May 22, 2014, Merritt said

Lopez, 32, killed a Chicago police officer, a doctor and a pharmacy resident Monday at Mercy Hospital. Lopez was shot in the abdomen, and he also shot himself in the head, according to the medical examiner's daily case ledger. It's not clear which caused his death.

Shooter went to church with victim a day earlier

Lopez's former fiancée, Dr. Tamara O'Neal, was among the victims. She was killed in the Mercy Hospital parking lot.

Lopez confronted the physician and demanded an engagement ring back before shooting her, Chicago police spokesman Anthony Guglielmi told CNN.

The two were engaged until late September when she called it off, her father, Tom O'Neal, said in a phone interview Tuesday. The two were set to marry in October.

Dr. Tamara O'Neal was killed in the Mercy Hospital parking lot.

A day before the shooting, Tammy, as her relatives knew her, attended church services with Lopez and her family in Indiana, where she was from, her father said. Lopez couldn't accept the relationship was over, her father said.

He said his daughter was a strong believer and she and Lopez were not united in their faith.

"I just thank God for the 38 years we had with her. I was thinking we'd have a lot longer," the father said. "We were expecting being grandparents, spoiling the grandchildren."

How the shooting unfolded

O'Neal had just finished her emergency room shift at Mercy Hospital when Lopez approached her, began arguing and shot her, officials said.

Guglielmi told CNN that police believe Lopez went to the hospital with the intent to kill O'Neal, based on the amount of ammunition he was carrying, along with the 9mm handgun used in the attack. The gunman had a concealed-carry permit and bought about four weapons over the past five years, police said.

Police say Monday's shooting began in a parking lot at Mercy Hospital in Chicago.

Responding police officers pursued the gunman into the hospital, exchanging gunfire with him for several minutes.

Lopez fired about 40 shots from his handgun, Guglielmi said, and a Chicago SWAT unit returned fire four or five times with a rifle.

Lopez shot and killed two others -- Chicago police Officer Samuel Jimenez and 24-year-old pharmacy resident Dayna Less, police Superintendent Eddie T. Johnson said. A bullet also hit the holster of a second officer, who was uninjured, Johnson said.

Jimenez, 28, joined the department in February 2017. He had just become a full-fledged member of the force after completing a probationary training period, Johnson told reporters.

Jimenez and his partner went to the hospital when they heard dispatch traffic about the shooting. "They weren't assigned to that particular call, but they went," Johnson said, "because that's what we do."

Less was a first-year pharmacy resident training to be a pharmacist, the hospital said. She recently graduated from Purdue University and joined the hospital staff in July.

Lopez shot Less as she was getting off the elevator, Johnson said. She had no connection to the gunman.

Less was tenacious in all things, her father said, including her career. She initially had a severe headache disorder that left her largely unable to go to school, but she eventually found a doctor who performed two surgeries that addressed the symptoms, Brian Less said.

"Dayna was a very special person. She had unique gifts," her father said, according to CNN affiliate WLS. "She was intelligent, she was funny, she was kind, she was a good friend."

'Too close for comfort'

The hospital's emergency room department reopened Tuesday afternoon, and the facility was "functioning at near capacity," said Dr. Michael Davenport, the chief medical officer.

Monday's shooting drew large numbers of law enforcement and emergency responders. Vehicles with flashing lights cordoned off the blocks around the medical center.

When the gunman entered the facility, hospital worker Patricia Rinella and others barricaded themselves in a room, blocking a door with a copying machine, she told CNN affiliate WBBM.

"It was too close for comfort," Rinella said. "It just seemed like he was all over the place."