Refactoring functionality into a custom Ext data store class

Now with Ivan's fixes!