Treatments like extraction, scaling,filling and root canal can be done in 4-6 months. It is better to avoid treatments in first and last three months of pregnancy. Emergency treatments can be done at any stages of pregnancy if you experience severe pain and swelling.
Have a dental check up before planning for pregnancy. If not then do check up in first 3 months and do the treatments in second trimester.