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

ip address format and sorting #37

Open
Config13 opened this issue Dec 31, 2017 · 8 comments
Open

ip address format and sorting #37

Config13 opened this issue Dec 31, 2017 · 8 comments

Comments

@Config13
Copy link

sorting in the table by addresses. so that the devices are displayed in order changed addresses to 192.168.007.000. After the changes, if you click on the link to the web interface - the address of the device is not correct. As with the address 192.168.007.011, the interface opens 192.168.7.9. How can this be remedied?

@anselal
Copy link
Owner

anselal commented Jan 4, 2018

@Config13 I just replicated your issue with entering the IP 192.168.007.011 and you are right, the link points to 192.168.7.9. This is because for some reason the IP is translated as octal (011=>9, 012=>10, ...).

The strange thing is that the conversion only happens inside the href. I am trying to cast it to string but it won't work for some reason. This should be easy to resolve though. I will come back with a solution soon...

@anselal anselal changed the title ip address format ip address format and sorting Jan 4, 2018
@anselal
Copy link
Owner

anselal commented Jan 4, 2018

So, i did a research and I found that this is not a bug in my app. If you look at the source of the rendered html you'll see that the IP inside the <a href="..."> is correct. It seems that the browser handles it as octal.

I will have to add a script that properly sorts the IPs in the table.

@gnanet
Copy link

gnanet commented Jan 4, 2018

My workaround for this was to put a sortable NAME of the miner into the remark field, for example having 3 pcs of L3+ would be named L3P001 - L3P003 which is easily sortable ;)

@anselal
Copy link
Owner

anselal commented Jan 5, 2018

@gnanet This works but you will have to edit the source which is not possible for every user. I had tested a Javascript code for sorting some fields in the table. As it seems I'll have to merge it ;)

@anselal
Copy link
Owner

anselal commented Jan 29, 2018

I am working on a new table design which will include proper IP sorting.
Stay tuned !!!

@sergbere
Copy link

sergbere commented Mar 2, 2018

Would it be possible to implement a table sorting by any column? Would be beneficial to check not only by IP address, but by Hostnames, uptime, HW error count, etc.
Some ready solution here to give an idea: http://tablesorter.com/docs/

@anselal
Copy link
Owner

anselal commented Mar 2, 2018

I was gonna use datatables.net

@sergbere
Copy link

sergbere commented Mar 2, 2018

That one is also fine. Thanks!

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

No branches or pull requests

4 participants