Open MHerbst opened 7 years ago
The LINK button should not be active if "create new item" is chosen. Instead you should be able to either create an item yourself or to link an existing one here.
@aounhaider1 Could you please have a look?
That's right, but if you select "create new item" it should be somehow possible to "jump" to the item definition page. After I selecte "Create new item" the blue text "item" appeared above the selection. Becaue of its colour it looks like a hyperlink, but it has no function. So the meaning of this text is also not clear.
Could you try to clear your browser cache? I just tested it and it correctly opens a "create item" dialog:
That's it. After cleaning the cache it worked as expected. This solution apparently was too easy for me ...
Maybe it would be a good idea to prevent these pages from caching as long as it is in beta state. Or at least to set short expiry dates, e.g. maximum 1 day.
@MHerbst Is there still something missing or could the issue be closed?
I was waiting for @aounhaider1 to comment whether there can be anything enhanced wrt cache expiry.
@maggu2810 My particular problem was solved by cleaning the browser cache, but the general problem remain. @kaikreuzer The https protocol allows to configure a cache expiry for each file that is transferred. So in general it is possible to limit the cache time to e.g. 1 day by settings in the http header that is sent with each file. If the files are served by a web server like NGINS or Apache the configuration is quite easy but I don't know how I can be done e.g. with Ajax requests. Another way to solve the problem would be to add a version number the the javascript files and increment the version each time it is changed.
For JS files we can use an auto incrementing version number. There are libraries like https://www.npmjs.com/package/gulp-rev that can be used. For html files we can set the cache-control header with max-age. What do you think?
@aounhaider1 Sounds good. I know the technique with incremented version numbers from CMS like Wordpress where it is working perfectly.
I just adapted the issue title to reflect the underlying root-cause
I made a fresh install of build 634 (on Windows 10) and installed only the Yahoo binding.
In the first test I did not create any items. Instead I opened the thing configuration and selected the option "+Create New Item" When I press the "Link" button I get an error message "Error 405 Method not allowed" (the log shows nothing).
Then I created manually a new item of type "Number" (I entered a name, label and selected the type "Number"). When I try to assign this item to the temperature channel I only get this selection: The entry marked in yellow seems to be my newly created item. But linking is not possible (also error 405).
The I switched to "Simple mode" and activated the "Temperature" channel. This works fine and the automatically created item is linked.