Comments (12)
The track by
approach is more correct as the ngRepeat goes, but I'll try to get in and add logic to strip anything with a key name starting with $
. Or if you have a moment to adjust your tweak to check that instead of just the one key, I'd accept the PR. :-)
Thanks for the heads up. I suspect lots of use cases where Angular will pollute the template before ngDynForms actually sees it, so I'll need to be ready.
from angular-dynamic-forms.
Try it now; this should be fixed.
from angular-dynamic-forms.
Thanks.
One other thing, I think on line 444, you need a if(ctrl), because your ngModel has a '?' before it.
It's been giving me some errors.
from angular-dynamic-forms.
Hrm. ctrl
is the controller responsible for that element - it has nothing to do with the ng-model
attribute. Not sure of a situation where you could have an undefined ctrl
there...
from angular-dynamic-forms.
OK, I take that back. It's the controller for the ng-model
itself. Let me research this further...
from angular-dynamic-forms.
Maybe I'm wrong. I'm getting this on a screen that doesn't use dynamic-forms:
TypeError: Cannot set property '$render' of undefined
at link (http://localhost:8090/app/shared/vendor/angular-dynamic-forms/dynamic-forms.js:444:24)
If I add 'if (ctrl)' on line 444, it seems ok, but that's probably a terrible hack on my part. I just needed to hack something up to demo.
from angular-dynamic-forms.
You're right; it should be ignoring file
and range
input
elements that don't have ng-model
on them. Not sure what use cases would benefit from not being connected to a model (traditional file uploads, I imagine, though the expansions to file
handling make that easier to handle in less traditional ways - I should document those in the README sometime...), but I've pushed the fix anyway, because it is still a bug.
from angular-dynamic-forms.
One more question:
if (String.charAt(id, 0) == '$') {
this line is generating this error:
TypeError: undefined is not a function
at buildFields (http://localhost:8090/app/shared/vendor/angular-dynamic-forms/dynamic-forms.js:92:26)
Am I doing something wrong?
from angular-dynamic-forms.
No. I just got lazy and took advantage of a language construct that doesn't exist in every browser. I'll adjust the line so it will actually work and repush in a bit. Sorry about that.
from angular-dynamic-forms.
That should fix it. Sorry about that.
from angular-dynamic-forms.
Cool. Thanks!
from angular-dynamic-forms.
If that's everything, I'll close this. 😄
from angular-dynamic-forms.
Related Issues (20)
- Usage of file input unclear HOT 2
- Unknown provider: dynformProvider <- dynform <- LoginCtrl HOT 2
- test
- checklist is not rendering showing error at option portion HOT 1
- File Upload Issue...Last 1 for this project I hope HOT 2
- Multi Column Form HOT 3
- Auto complete HOT 3
- how to add required in checklist HOT 3
- Regarding dynamically loading the template from a response from $http service - question/issue HOT 12
- HTML-first (Accessible) Usage? HOT 1
- Adding entries into custom class HOT 1
- How to use ng-show?
- Does this actually work? HOT 3
- How to add custom components like autosuggest, uib-datepicker in dynamic form
- How to add custom validations in dynamic form
- How to use the value of the ng-model in dynamic-forms.js file
- Refresh directive upon attrs.template (stdFormTemplate) change HOT 1
- Using ADF with Jhispter HOT 3
- Want to run it after clone HOT 4
- HTTP POST HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from angular-dynamic-forms.