I just tried the above on http://demo.mayan-edms.com/ and got the same described behavior. This is a good place to test on a remote server.
On Tuesday, April 19, 2016 at 11:30:53 PM UTC-7, kyle graves wrote: > > Hey everybody, > > I'm having a really weird issue I haven't been able to figure out. Locally > everything works as expected, but on two (remote) production servers I have > issues. > Just a note, I installed mayan from pip, via the deploy > <https://mayan.readthedocs.org/en/latest/topics/deploying.html> guide, and > I haven't made any code changes to Mayan. > > Here are steps to recreate: > 1) obtain token from '/api/rest/auth/token/obtain/' via GET request > 2) use the token along with tag data (label, color) to send a POST request. > > NOTE: I have sent one request with a node.js script I hacked together and > one with the following javascript in browser with jquery: > > > > $.ajax({ > > url: '/api/tags/tags/', > > method: 'POST', > > dataType: 'json', > > data: { > > label: 'Testing', > > color: '#123456' > > }, > > headers: {'Authorization': 'token [INSERT TOKEN HERE]'} > > }).then(function(data, status, req) { > > console.log(data); > > console.log(status); > > }).fail(function(req, status, error) { > > console.log(error); > > }) > > 3) note that you get a 201 CREATED response, but the json that is returned > is missing the label and color attributes. See the following: > > > {"color":"","documents":"[REDACTED]/api/tags/tags/63/documents/","documents_count":0,"id":63,"label":"","url":"http://[REDACTED]/api/tags/tags/63/"} > > > 4) Checking the actual page you can see that the tag is missing the same > data (label, color): > > > <https://lh3.googleusercontent.com/-SO1fLgCfylk/VxcglPjWszI/AAAAAAAAC2U/TyIb_3olefo8CEmAg-UCx_BVr4C3YnaSwCLcB/s1600/mayan_error.png> > > > I've searched around the internet, as well as this group, and haven't > found any info on this. > > Has anyone else experienced this? Or is anyone else able to reproduce > this? (remember it only occurs on remote servers; it works fine on > localhost) > -- --- You received this message because you are subscribed to the Google Groups "Mayan EDMS" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
