For the affine vertex algebra Vk(g) at an admissible level k of g^, we prove that certain subcategory of weak Vk(g)-module category is semisimple. As a consequence, we show that Vk(g) is rational with respect to a family of Virasoro elements. We also prove that certain affine vertex operator superalgebras and minimal W-algebras are rational with respect to a family of Virasoro elements.