Hi idilbayar.
A key aspect of mastering GMAT SC is understanding the functions of the different types of modiifers.
In this case, we are dealing with the prepositional phrase "by being inspected" which introduces the clause "an entire order of finished goods can be found to be flawed."
When a prepositional phrase introduces a clause, the phrase modifies the predicate (verb) of the clause.
More specifically, when a prepositional phrase beginning with "by" introduces a clause, it describes HOW the action of the clause was accomplished.
For example:
By fixing old bicycles, John makes enough money to support his family.That sentence communicates that John accomplishes the action "makes enough money" BY "fixing old bicycles."
So, let's consider the example you mentioned.
by being inspected only after production, an entire order of finished goods can be found to be flawed.In this case, the phrase "by being inspected ..." describes how the action "can be found to be flawed" is accomplished.
Our next step in understanding the meaning is to look for the subject of "can be found to be flawed." We see it's "an entire order of finished goods."
So, the sentence meaning is that "an entire order of finished goods" accomplishes the action "can be found to be flawed" BY "being inspected ...," as if the order chooses to be "inspected only after production" in order to accomplish "can be found to be flawed."