Two men who operated a lucrative drug network – distributing large quantities of cocaine – have been jailed.