For a crane system, when the payload is too large to be seen as a mass point, or the hook mass cannot be directly ignored, it performs more like a double-pendulum crane system, instead of a single-pendulum crane system. Due to many factors, the working environment of the industrial crane system is complex. Obstacles sometimes appear in the movement path of the payload, which affects the normal operation of the crane system and may cause accidents like collisions. To handle this issue, we propose a time optimal trajectory planning method for the double-pendulum crane system with obstacle avoidance, which ensures the objective of obstacle avoidance by the payload hoisting/lowering. During the trajectory planning process, a series of physical constraints, including the trolley velocity constraints, the trolley acceleration constraints, the payload's swing angle constraints and the hook's swing angle constraints are considered. It can improve the safety of the crane system during the entire working process and the transportation efficiency is also improved at the same time. Finally, the effectiveness of the proposed method is verified by simulations.