Here is the NFC West playoff flowchart (as created by me in MS Paint).
If the 49ers beat the Rams this week, but lose to the Cardinals next week, then the winner of Rams vs Seahawks makes the playoffs.
If the 49ers beat the Rams this week AND the Cardinals next week, its more complicated. Here, the 49ers make the playoffs automatically if the Seahawks lost to the Bucs week 16. But if the Hawks won week 16, then the Seahawks make it if they beat the Rams week 17, and the 49ers make it if the Rams win.
The outcome of Seahawks versus Bucs only matters if the 49ers beat the Rams AND the 49ers beat the Cardinals. Otherwise it is irrelevant.
Note: If a game results in a tie then that could change things. I am assuming no ties here.
I have verified the accuracy of these scenarios using NFL Playoff Machine: