Giter VIP home page Giter VIP logo

ngcrossfilter's Issues

Update Model

Hi,

First thanks a lot for this awesome angular module. I use it to create sortable and filterable grids.

I have an issue when trying to update a model. I assumed the way to do that was to remove the model and then add the new updated model.
I do something like
$scope.$ngc.deleteModel(model);
$scope.$ngc.addModel(updatedModel);

The model gets deleted correctly but it doesn't get added then. It seems I can't add a model which have been deleted before. Could you help with that ?

Many thanks

crossfilter is not available from dc.js

Hello,

I use ngCrossfilter with dc.js. It looks like dc can not render charts (called by a dc.renderall() ) because 'crossfilter' is not available :

angular.js:13920 TypeError: Cannot read property 'quicksort' of undefined
    at Object._chart._computeOrderedGroups (base-mixin.js:335)
    at Object.<anonymous> (cap-mixin.js:51)
    at Object._chart.data (base-mixin.js:261)
    at drawChart (row-chart.js:136)
    at Object._chart._doRender (row-chart.js:89)
    at Object._chart.render (base-mixin.js:645)
    at Object.dc.renderAll (core.js:230)
    at pages.controller.js:85
    at processQueue (angular.js:16383)
    at angular.js:16399

The base-mixin.js:335 is :
_orderSort = crossfilter.quicksort.by(_ordering);

And crossfilter is not available, because it is defined only into the new Crossfilter() object...

Is there a solution to have the crossfilter object available into dc.js ? Or did I misunderstood anything ?

Thanks.

Support AngularJS ver 1.3 and above

Currently the bower.json specify the angular dependency as "angular": "~1.2.1"
This should be updated to "angular": "~1.x.x" to support any all legit angularjs versions.

Identifying which crossfilter triggered an update

I was listening for updates in a crossfilter using the crossfilter/updated event, but I couldn't find a clean way to identify from which crossfilter the event originated when there's more than one.

Maybe I'm missing something, but I guess a backwards-compatible approach would be to optionally set a name/id for a crossfilter and pass that name along with the broadcasted event. It could look something like this:

$scope.ngc = new Crossfilter(response.data, 'id', 'persistent');
$scope.ngc.setCrossfilterName('myCrossfilter1');

$scope.$on('crossfilter/updated', function(event, collection, crossfilterName) {
  if ('myCrossfilter1' === crossfilterName) {
    // ...
  }
};

Thoughts? I'm happy to submit a PR if you think it's worth it!

Advantage over using crossfilter directly?

Hi, I like the idea, but I m not getting the clear benefits of using ngCrossfilter over crossfilter directly in the controller, like I use Lodash. Can you please clarify? Thanks.

Bower issue

your package could not be found and installed via bower
check it out please.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.