Any ideas why pancreatitis cause an ileus?

Adynamic ileus. Is caused by different things, including inflammation. Pancreatitis, or inflammation of pancreas, causes irritation of peritoneal cavity, causing intestinal motility to slow down or stop, which is the cause of adynamic ileus. Typically, ileus caused by pancreatitis persists longer than the pancreatitis itself.
Inflammation. Any intraabdominal inflammation will slow the bowels.