Move to new API format for Settings.

refs #2606
- Use new API format when updating settings from the client side
- Add additional test to test new API format
- Adjust functional tests to work with the new format
Update users api canThis context

- Update api.users methods to pass the whole context to canThis instead
of just this.user
Sanitize models' attributes/options before passing to bookshelf/knex

closes #2653
- enforce strict whitelists for model methods
- create a class method that reports a model method's valid options
- create a class method that filters a model's valid attributes from data
- create a class method that filters valid options from a model method's options hash
Merge pull request #2700 from halfdan/settings-api

Move to new API format for Settings.
Merge pull request #2679 from appleYaks/sanitize-model-options

Sanitize models' attributes/options before passing to bookshelf/knex
ACL and strict rules for Settings API

Ref #2061

- Add canThis permission checks to settings api calls
- Add strict rules about accessing core settings without internal: true
- Omit core settings in browse() call unless internal: true
- Update unit tests to call api.settings with contexts
- Add a couple unit tests for new scenarios
- Update all api.settings calls in the app to call with internal context
- Re-arrange permissions.init in server startup so config.theme.update
can access settings without permissions error
Create GhostPopover component

issue #2418

- create ghost-popover component and template
- use it for the navigation popover
- still needs to handle global click event on the document
to close the popover
Ember settings/general

- Settings fixture that doesn't seem to work
- SettingsGeneralRoute with model function calling api
- SettingsGeneralModel with save method stubbed
- SettingsGeneralController with actions for save, uploadLogo and uploadCover
- Let ApplicationRoute handleValidationErrors
- Fix actions hash in controller and use bind-attr
- Refactor to use single SettingsModel
- Implement description word count
- Fix broken ajax reference by actually importing ajax method
- Refactor to use count-words helper
- Refactor isDatedPermalinks into controller
- Refactor the isDatedPermalinks to use a custom setter
- Remove isDatedPermalinks code from the model
Merge pull request #2702 from jgable/userCanThis

Update users api canThis context
Merge pull request #2569 from jgable/ember-settingsGeneral

[Ember.js] Ember settings/general
Merge pull request #2565 from hswolff/ember-popover

[Ember.js] Create GhostPopover component
Merge pull request #2618 from novaugust/post-settings

[Ember.js] Create Post Settings Menu and its functionality on the Post controller.
Fix link
Merge pull request #2701 from jgable/settingsACL2

ACL and strict rules for Settings API
Ported logic to settings: Debug Tab closes #2424

- Added file upload component
- Added import client logic
- Added e-mail sending client logic
- Added settings model
Merge pull request #2581 from szelpe/ember-debug
Merge pull request #2705 from davidblurton/patch-1

Fix link to wiki page on NPM
Merge branch 'ember'

Conflicts:
	Gruntfile.js
	core/client/models/post.js
	core/client/models/settings.js
	core/client/models/user.js
	core/client/router.js
	package.json
Adding READMEs to clarify the 2 client folders

- seemed like  a good idea.
DB API returns JSON-API compatible objects. Export triggers 'Save As' dialog.

closes #2647
- GET method returns { db: [exportedData] }
- POST, DELETE methods return { db: [] }
- 'delete all content' test updated
- Attach 'Content-Disposition' header on DB export for 'Save As' browser dialog
- Add DB API functional test for Export