The time dilation at any given instant depends solely on the the velocity in whatever frame you're using, the factor by which a moving clock is slowed down is always \sqrt{1 - v^2/c^2} where v is that clock's instantaneous velocity. However, if you have two worldlines that cross paths at two times t0 and t1, and you know the velocity as a function of time v(t) on each worldline, then you can do the integral \int_{t_0}^{t_1} \sqrt{1 - v(t)^2/c^2} \, dt for both of them to find the total time elapsed on each worldline between the two points where they cross. If one worldline is inertial (constant value for v(t)) and the other involves some acceleration (the value of v(t) changes with t), it will always work out that when you do the integral above, you'll find that the total time elapsed is greater on the inertial worldline than the worldline that involved an acceleration. That's just a property of the way the integral works, and it's totally compatible with the idea that the time dilation at each moment depends solely on the velocity at that moment, not the acceleration.
If it helps, there's a direct analogy for this in ordinary Euclidean geometry. Suppose we have two paths on a 2D plane which cross at two points, and one is a straight-line path while the other involves some bending. Since we know a straight line on a 2D plane is the shortest distance between points, we know the straight-line path will have a shorter total length. But suppose we want to measure the length of each path by driving cars along them with odometers running to measure how far the cars have travelled. Suppose we also have an x-y coordinate system on this 2D plane, so we can talk about "the rate a car is accumulating distance as a function of its x-coordinate"--if you think about it, it's not hard to show that this is solely a function of the slope of the path at that point in the coordinate system you're using. If you know the function for the path in this coordinate system y(x), then the slope at x is defined by looking at a small interval from x to (x + dx), and seeing the amount dy that the y-coordinate of the path changes between those points, with the slope defined as dy/dx. Since dx and dy are assumed to be arbitrarily small, the path can be assumed to be arbitrarily close to a straight line between the points (x,y) and (x+dx,y+dy), so the distance accumulated on the car's odometer as it travels between those points is just given by the pythagorean theorem, it'll be \sqrt{dx^2 + dy^2}, which is equal to dx*\sqrt{1 + dy^2/dx^2}, and since the "slope" at a given coordinate S(x) is defined to be dy/dx, this means the distance accumulated on the car's odometer as it travels between these points can be written as dx * \sqrt{1 + S(x)^2}.
So, the ratio of (increment odometer increases)/(increment x-coordinate increases), i.e. "the rate the car is accumulating distance as a function of its x-coordinate", will just be \frac{dx*\sqrt{1 + S(x)^2}}{dx} which is just \sqrt{1 + S(x)^2}, purely a function of the slope. On the other hand, if you want to know how much distance accumulates on the odometer over a non-incremental change in the x-coordinate, say from some value x_0 to x_1, then we have to integrate the amount the odometer increases over each increment over the entire range from x_0 to x_1, giving the integral \int_{x_0}^{x_1} \sqrt{1 + S(x)^2} \, dx. Since we know a straight path is the shortest distance between two points, and we know straight implies constant slope, this means that if we have two different paths which cross once at x_0 and then again at x_1, and one has a constant S(x) while the other has a varying S(x), that means if we do the above integral for both paths the answer for the constant-slope path is guaranteed to be smaller.
Obviously all this is very closely analogous to the situation in relativity, where the rate a clock accumulates time as a function of the t-coordinate is just \sqrt{1 - v^2} (in units where c=1, like seconds and light-seconds), while the total time accumulated on a path with a specific v(t) is \int_{t_0}^{t_1} \sqrt{1 - v(t)^2} \, dt, and a path with constant v is guaranteed to have a longer total time than a path with a v that changes (the reason a straight path in SR is guaranteed to have the largest time while a straight path in geometry is guaranteed to have the shortest distance has to do with the fact that there's a plus sign in front of the geometric slope but a minus sign in front of the velocity in the two square roots).