keystone-classic: LocalFile Field Type Format not working
image: { type: Types.LocalFile,dest: '/home/veda/ks/public/img', prefix: '/img',
format: function(item, file){
return '<img src="/img/'+file.path.replace('/home/ks/admin/public/img','')+'/'+file.filename+'" style="max-width: 200px"\>';
}
},
It show an image on keystone version 0.2.36 but when I update to keystone 0.2.40 it show file name instead.
About this issue
- Original URL
- State: closed
- Created 9 years ago
- Comments: 20 (9 by maintainers)
just want to bring this PR to attention. #2484 i merged it into my fork and everything works as expected.
As noted in earlier comments, the File API has been rewritten using pluggable storage for Keystone 4 (née 0.4).
For more information, see the File Field API documentation and API File and image Uploads Guide in the Keystone 4 documentation.
For specific File adapters, see:
Regards, Stennie
Can you please keep the docs updated? It is really frustrating. I am having trouble working with local files in my project.