IMHO there is a difference between the artificial gravity and the Inertial Dampening Field (IDF) that reduces the effects of the ship acceleration, deceleration, and shaking.
Suppose that you were standing on the ground on Earth under one gravity acceleration due to Earth's gravity, and a one thousand mile per hour wind struck you. The force of the wind would blow you away at a speed great enough that hitting the ground occasionally would really hurt, despite the fact that the acceleration of one gravity from Earth's gravity was still working.
And suppose that you were standing on the surface of Earth under one gravity acceleration due to Earth's gravity, and you were struck by a large moving vehicle at a speed of 200 miles per hour. You would be sent flying, suddenly accelerated by the vehicle, and probably at an acceleration of several Earth gravitys, despite the fact that the acceleration of one gravity from Earth's gravity was still working.
And suppose that you were riding in an airplane at a speed of hundreds of miles per hour near the surface of the Earth, under a steady one gravity of acceleration due to Earth's gravity, and the airplane suddenly hit an obstacle, like the World Trade Center, at a speed of hundreds of miles per hour. Clearly the sudden deceleration would kill you and destroy the airplane despite Earth's gravity remaining constant at one gravity.
So clearly the IDF is necessary to prevent the crew from being tossed around in all directions and injured or killed whenever a starship rapidly accelerates, decelerates, or is shaken.
In the Sector General stories by James White there are weapons called rattlers that shoot alternating tractor and pressor beams at their targets to shake them to pieces.
I once read that powerful enough laser weapons could be used to destroy targets without vaporizing them. Instead the laser weapons would be turned on and off and would hit the targets so hard that it would be like hammering them with giant hammers. Successive blows form the laser beams would be enough to smash in the parts of the target they hit, or if the target was solid enough to shake it until it fell to pieces.
So possibly Star Trek weapons do have a component that hits and pushes their targets hard.
If such a beam hit an unprotected starship the beam would push in the hull section hit by the beam hard enough to detach it and push it back into the starship, smashing through bulkheads and decks and coming out the other side, leaving the starship with a tunnel through it leaking air out into space as well as damaged and destroyed equipment and crew members.
But if a starship has its energy shields up the shields will intercept the beam and transfer it's kinetic energy to the shields as a whole, which in turn will transfer the kinetic energy to their generators which in turn will transfer the kinetic energy to the ship as a whole. Thus the amount of kinetic energy sufficient to punch a narrow tunnel though the starship will instead push the entire starship back.
And since the entire starship has many times the mass of the section that would have been punched out of it by the energy beam the entire starship will be pushed back with much less force than the section would have been pushed out of the starship.
But the acceleration that the energy beam gives to the entire starship as it pushes it back might still equal tens, hundreds, or thousands of gravities, enough to smash up equipment and kill crew members as they fly into bulkheads.
So the job of the IDF is to reduce the acceleration the energy beam gives to the starship down to zero so the crew doesn't feel anything.
When such an energy beam hits a star ship, there are two possibilities that are highly probable.
The first possibility is that the starship's IDF will be able to compensate for the acceleration the beam gives to the ship perfectly, so that no force is felt by the equipment or the crew.
The second possibility is that the staship's IDF will be able to compensate for the acceleration the beam gives to the ship almost perfectly, so that only a tiny fraction of that acceleration force will be felt, and that tiny fraction will be enough to give every part of the ship an acceleration of at least several gravities and all equipment will be smashed and all crew members splattered against bulkheads and killed instantly.
And in the history of space war in Star Trek weapons designers constantly seek to increase the power of their beams so that IDFs will fail and the second possibility will happen to the target starships, while designers of force shields and IDFs work to improve them so that no force will be felt in a starship when hit by such a beam, the first possibility.
And in TOS space battles starships fired their weapons when the targets were tens of thousands or hundred of thousands of kilometers away, indicating that it would be suicidal to fight at closer distances where the first hit would destroy a starship.
But in space battles in the TOS movies starships got really close to each other to fire their weapons, implying that defenses had improved vastly and weapons not as much, so that starships had to get very close to have any chance of damaging their enemies.
So in a Star Trek space battle, either the weapons should be pretty much useless against their enemies, as in the first possibility, or else the weapons should usually destroy the enemy ships with the first shot, as in the second possibility.
There is a third possibility, one that exists on a "knife's edge" between the other two, that the IDF will be almost totally successful in neutralizing the forces of acceleration when a starship is hit by an energy beam, but enough force will be felt to shake the ship and throw people around without killing them.
And it seems that every Star Trek movie and series with a space battle has been set in an era of weapons development where the third possibility is in effect, despite the fact that it should be an extremely rare situation, on an extremely improbable "knife's edge" between the two main possibilities.
But perhaps the commanders in Star Trek space battles seek to fight at distances where their weapons have a chance to damage the enemy, but their own ships have a chance to survive being hit by enemy weapons. Maybe they always plan to fight at distances were the third possibility, the extremely narrow "knife's edge" between the first and the second possibility, is in effect.