Code Monkey home page Code Monkey logo

Comments (6)

green3g avatar green3g commented on August 22, 2024

So here's the problem, the relationship table renders itself as a table, not as a list. So in your example above, the popup content would look something like this:

  • ObjectID: 10
  • ADMIN_DEPT_CODE: DOI
  • ...Other feature class attributes
ID Related field 2 Related field 3 ...
1 Record Value Record Value ...
2 Record Value Record Value ...
3 Record Value Record Value ...

Is that what you're going for?

from cmv-widgets.

dfralia avatar dfralia commented on August 22, 2024

Yes the relationships do end up showing in the table format, however I was wanting them to be in the same format, or similar to the attribute list.
So, perhaps something like this (or similar):

  • ObjectID: 10
  • ADMIN_DEPT_CODE: DOI
  • .....ETC
  • Related Field 2: (Record 1) , Related Field 3: (Record 2) ---------Field 2 would be first name, field 3 is last name

from cmv-widgets.

green3g avatar green3g commented on August 22, 2024

That won't be easy to accomplish since the widget uses dgrid and doesn't actually do the table rendering itself. It just queries ArcGIS Server for data and loads it into a store. Dgrid does the rest by generating the rows. I suppose one hackish option would be to use CSS to override the look of the table and make it look like a list.

But why not just format your attributes into a table, and then have two tables, one for the attributes, one for the related records?

from cmv-widgets.

dfralia avatar dfralia commented on August 22, 2024

Those are some good ideas. I will see what if I can implement, or perhaps create a new widget somehow. I will post back here for reference if I can get something to work.

Thanks for the help and ideas. Much appreciated!

from cmv-widgets.

green3g avatar green3g commented on August 22, 2024

@dfralia did you get this figured out? I just added a complete example to the demo branch of this repo. You can see it here: https://github.com/roemhildtg/cmv-widgets/blob/demo-widgets/cmv-app/js/config/identify.js#L84

from cmv-widgets.

dfralia avatar dfralia commented on August 22, 2024

I had not been able to figure something else out yet. I actually got pulled into another project, and put this on the backburner for a little bit. I just implemented your new demo, and it looks very good. I think I will be able to work with this. Thank you for posting it.

from cmv-widgets.

Related Issues (20)

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.