Skip to main content

Posts

Showing posts from August, 2016
Java script for downloading an attachment in a based on seach used in display template.   getAttachements: function (siteUrl, listId, itemId) {            console.log("siteUrl " + siteUrl);            console.log("listId " + listId);            console.log("itemId " + itemId);                        doSpAction(function() {                console.log("doing sp action");                               var clientContext = new SP.ClientContext(siteUrl); //                      var list = cx.get_web().get_lists().getByTitle("Bestillinger");               var productList = clientContext.get_web().get_lists().getById(listId)...

Upload dokument jsom notes

Code I used to upload a document into a list based on search context in a displaytemplate  upLoadDocument: function(itemId, produkt) {                doSpAction(function(){                   var inputFile = document.getElementById(itemId + "upload");                   var btnUpLoad = $("#" + itemId + "btnupload");                   var fileNameSpan = $("#" + itemId + "filename");                   var uploadPnl = $("#" + itemId + "uploadPnl");                   var doUpload = $("#" + itemId + "doUpload");                                                       console.log(btnUpLo...