Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
niquola
@niquola
Do you need select/combo or list?
nsrivaradhan
@nsrivaradhan
Combo
niquola
@niquola
in select you have magic item variable to bind
  div fs-select="" items="toolBarVals" ng-disabled="" ng-model="svalue">
<span ng-show="item"> <b>{{item.locations}}</b> </span>
<span ng-hide="item"> Any weapon </span>
nsrivaradhan
@nsrivaradhan
should i use item variable to bind it to the service?
niquola
@niquola
yes
nsrivaradhan
@nsrivaradhan
I tried using item variable. But still its not working. Should I add something to the controller?
blob
blob
niquola
@niquola
Try this: <span ng-show="item"> <b>{{item | json}}</b> </span>.
Is toolBarVals array of objects?
nsrivaradhan
@nsrivaradhan
Yes it is.
This message was deleted
blob
Sorry its not an array. Its an object. Contains both arrays and objects in it
nsrivaradhan
@nsrivaradhan
blob
I tried it. it gives me the above output
niquola
@niquola
select items is expected to be an array, please bind to items array of options
niquola
@niquola
Could you share some sample on jsfiddle or something like this?
nsrivaradhan
@nsrivaradhan
These are the modules related to this section. I have created a service and Trying to get the data for the select from the service. toolBarVals contains all the data from the service. The output of the toolBarVals will be similar to the one shown in the screenshot above
niquola
@niquola
Example does not work - a lot of errors in console. You could hardcode data sample into jsfiddle - just save result as json and assign variable in angular; remove all modules not related to this problem
nsrivaradhan
@nsrivaradhan
This message was deleted
I just tried with a json object.
But its still not working. Can you please hardcode the values as in the snapshort and create a jsfiddle?
nsrivaradhan
@nsrivaradhan
Is there any way to implement the formstamp select for a json object
I am receiving a json object through services and I would like to use this object in the formstamp select to display the options for select
nsrivaradhan
@nsrivaradhan
No solution for this?
niquola
@niquola
You can transform object to array and pass to formstamp
Marek Święcicki
@4rlekin
hi there, i wonder if there is any way to utilize formstamp without installing it through bower
Marek Święcicki
@4rlekin
ok nvm, i got it working (used bower - i will live with that) but i have another question
im trying to build form and i hit problem from the start - i included formstamp.css and .js to my project and it seems like fs-input isn't showing in form
it is in DOM, but there is no effect visible
Marek Święcicki
@4rlekin
anyone ?
Marek Święcicki
@4rlekin
nvm, i must've had some kind of brainfart - i forgot to include formstamp module in my controller
niquola
@niquola
;)
Marek Święcicki
@4rlekin
hi, i wonder is there any way to change placeholders in, say, selects ? it seems there is no exposed property to do that, and i'd rather not modify directive by hand (it effectively cuts me off any further updates)
Marek Święcicki
@4rlekin
oh well... i did change directive by hand after all, i will post commit request to expose such possibility when i find some spare time - i really think it is useful, especially when one is writing app for non-english group of end-users
niquola
@niquola
This message was deleted
 <fs-row label="Select country">
      <div class="col-xs-4">
        <div fs-select="" items="countries" ng-model="country">
          <span ng-show="item"><span class="flag flag-{{ item['alpha-2'].toLowerCase() }}"></span>&nbsp;{{item.name}}</span>
          <span ng-hide="item"> No country </span>
        </div>
      </div>
    </fs-row>
<span ng-hide="item"> No country </span> does not it look like placeholder?
Marek Święcicki
@4rlekin
Well, actually i did come up with that as a solution, and while it is fine for having communicate when nothing is selected (freshly opened form for instance), when user clicks on it list of possible options drops down and there is input field for searching such list in which there is normal (coming from <input> 'placeholder' attribute) placeholder defaulting to "Search..." - i changed that since it made for inconsistent interface (item on ng-hide showing message in local language, and placeholder for search field in english)
im not trying to be annoying - it is minor problem, im first to agree with that, but it is important for my project to have user-friendly, consistent interface - hence my tinkering
niquola
@niquola
That's ok - send pull request :)
Marek Święcicki
@4rlekin
should be ready by today's evening ;)
niquola
@niquola
:+1:
Marek Święcicki
@4rlekin
is by any chance anybody here ?
Marek Święcicki
@4rlekin
nvm - i did pull request with both mentioned changes, hope i helped ;)
niquola
@niquola
thx, i've added some comments
Marek Święcicki
@4rlekin
likewise
wiryoputro
@wiryoputro
Hi, I've follow the installation instruction, but i always get error when installing the formstamp using "npm install && cd demo && npm install && cd .."
is there something I should update before the installation? i've missing the nvm 0.10.. maybe it doesn't exist anymore .
can anybody help me to install this formstamp?