Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding HTML through AJAX processing results #15

Open
abydahana opened this issue Nov 6, 2015 · 1 comment
Open

Adding HTML through AJAX processing results #15

abydahana opened this issue Nov 6, 2015 · 1 comment

Comments

@abydahana
Copy link

Hello.
I was downloaded and implementing this library into my own application. It's works until I got confused then. You know, my table results should adding options to handle any rows. For example there is "User" table. So it's row should have option to manage user such "Edit", "View" or "Delete".

How to implements my idea? Is it can be done from model?

Thank you,
Regards

@abydahana abydahana changed the title Adding HTML through AJAX proccessing results Adding HTML through AJAX processing results Nov 6, 2015
@abydahana
Copy link
Author

Ok, I'm done with this:

columns:[
  {
    data: null,
    defaultContent: '<span class="btn btn-info btn-edit btn-xs">Edit</span>',
    orderable: false,
    searchable: false
  },
  {data: "st_name"},
  {data: "st_address"},
  {data: "st_city"},
  {data: "st_state"},
  {data: "st_zip"},
  {data: "st_phone"}
]

But how to fetching a unique ID from database?

<a href="edit/st_phone"><span class="btn btn-info btn-edit btn-xs">Edit</span></a>

st_phone mean to getting unique phone from database results. It's should returning "edit/099123456". How do you can done with that?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant