Javascript improvements

- Improve CRM.api to support a "context" param
- Improve CRM.confirm to allow passing params into jQuery dialog