Thanks for the info and feedback. I found the tab theme issue shortly after releasing 1.2.0.3. I have it fixed for 1.2.0.4. I will look into the other UI issue you bring up about the box theme. it comes down to the box theme setting the width much smaller than other themes, but this should be an easy fix. Testing in all these themes and styles is pretty labor intensive so thanks for your help spotting the issues I missed.
I have a question about the eSearch widget that I hope you can answer. Is there a way to show only the tabs in the attribute table that are defined in the 'Included Fields' configuration for the eSearch widget?
For example:
In the eSearch Configuration we have created a GPIN search and 'Included Fields' of PAR_GPIN as illustrated in the below screenshot.
The below screenshot is difficult to see:
Essentially we'd like to show the GPIN tab in the attribute window tab but not show any of the other tabs / field names. Just show the tabs/fieldnames that were selected in the 'Included Fields' selection in the above screenshot in the Attribute Table as illustrated in the below screenshot.
I am just using the Attribute Table Widget to display results from the eSearch. So I don't want to have the eSearch remove any layers that it did not put/enable in that widget. If you do not want other layers to appear in the Attribute Table widget then just configure the Attribute Table widget to not display those layers.
Is there any way that I can use the selection from my search By Shape and By Value in combination. For example, if I pick an area using the search By Shape and then apple a query from my By Value then can I get only those that meet both search criteria?
You can do this in the exact opposite of what you stated. You set your "by value" query on that tab (enter the search parameter do not click search) and then switch to the "by shape" and check the "Include text query in selection criteria" checkbox and do your map drawing. Hopefully in latter releases I will have an easier option for this.
I would like notify you a small issue. If I try to change the configuration of the "Edit Default Buffer Properties", in particular the order of the Buffer Units, the change is not saved in the configuration file.
I am trying to add a button to my selection results that would allow me to remove an individual record from the selection...has anybody accomplished this? I have created the button and can call a function from the onclick event, but I'm not sure what that function would need to do to remove the graphic from the map and remove the item from the list. Any help would be appreciated.
a question. I need to hide the options that are in the TAB graphics. I modified the file widget.html and I put in style = "visibility: hidden" in the DIV tag. It is the only solution? you can enter the options in the config file? Thanks a lot.
What options on the Graphics tab? Or are you talking about hiding the whole tab? If you are talking about hiding the whole tab then yes see the "edit disabled tab(s) link on the widgets config page.
Have you had any problems exporting results from the Attribute Table to .csv when using IE? I assume this is an IE issue and not an Attribute Table or Enhanced Search widget issue as Firefox and Chrome work as they should (and I've tested all three browsers on five different machines with only IE11 not working), but just want to check with you on that.
If it is an IE issue, do you think in your next release you could have a piece of text, button, etc. available that lets the user know it is best to not use IE if the goal is to export results to .csv? Or do you have a tip or two on how to add that to the widget? Or is there a setting in the current widget I should change?
I can add more details later on what happens with IE if you need them. For now I'm just curious to know if you've experienced any problems with IE and export to CSV.
The Internet should have a button saying not to use I.E.
If IE was a machine I would like to take it out back and go Office Space on it. I am working on stuff with jQuery today and it's being ornery in IE and I am grumpy...
Also GeoNet should have "First Page" and "Last Page" links to navigate thread pages.
There is a thread that acknowledges that the Attribute Table widget has an issue with IE and export to csv and a code workaround that has to be done to the Attribute Table widget.
I don't have any plans to add some warning to my widget. As WAB dev team is aware of this issue and likely have it fixed in the 1.3 release I would just wait or add something to website link page.
OK, currently there is no configuration for the item you are wanting. I will look at adding these options to the "Edit Graphical Search Options" dialog in a future release.
I apologize I wasn't very clear. I have used that configuration and attached an image of how the results come across. The link still shows even if the field is null, however it is purple and just opens the Web App in a new tab. So I was wondering if I could change the results in the config so the field shows as a link.
I am still not sure I follow 100% but if you don't want the Recoder's Plat 1: http://blah blah and a link in the record that links to the url then just remove the filed from the fields list and only have it in the links list. The is also the "Disable Link if Null" option in the link configuration dialog.
Hi Robert, thanks for the update to WAB 1.2. I am busy with some migrations from 1.1.
I noticed that when I use the Unique option it takes a while to go through the list of features to get the unique list. Before this was pretty much instant. I remember something about a change make this faster. Has this changed in the new 1.2 version? Would it be possible to either change it back or to have an option of which method to use.
I might have worked faster in older versions because it was inaccurate. It would only return unique vales of the servers max-records (which normally was 1000, based on server version). It also sometimes seemed to be faster because there was no indicator but if you tried to click on the drop down list to quick it would be empty. So bottom line is no.
Just a note on it, if someone is returning 1000 unique options in a dropdown list, they might need to have a re-look at their search .
We searching properties with around 100 000 features (and in another case around 240 000) and have a unique value on the area name (which is around 40 unique areas). I have noticed that if I search on a property number and hit search before it has returned all the unique values for my area names, it does not return anything. I presume this is normal as it cannot find the value for the second parameter in the search query.
It would be great if both options were available in the config for this.
If I misunderstood your reply, my apologies for that.
OK, I might better clarify. In the older version the unique values will only search the first 1000 records (or what ever the server max-records is) and only working with those 1000 it would look for unique values in those 1000. So in your case it would take the first 1000 records of the 100,000 and return the unique values for only the first 1000 records of your 100,000 (so it would only be sampling 0.01 of your data). Hope that is clearer now.
I see one of your enhancements for v1.2.0.3 is Date searches have been fixed or Oracle DB users. Can you give more information if anything has to be done differently on the configuration end? I've got your widget set up and it runs for all queries except fails or date ones. I am using a mapservice that originated from Oracle to a SDE feature class to a map service. Any ideas?
Great – thank you! I am looking for the seach_config.json file to send your way. I suspect my problem is how I am setting up the queries. I am having trouble finding the search_config.json.
I can find a config.json file in the C:\Web AppBuilder\arcgis-web-appbuilder-1.2\client\stemapp\widgets\eSearch folder.
Please excuse my ignorance in this as this is my first foray into customization for ArcGIS Online.
Got it – I am not sure it is worth looking at as I don’t remember what state I left it in last night when I left. Unfortunately, I have little time to play with it this morning, but will have time to return to it this afternoon. Basically, if you could help me set up a query using the dates in my data, I am confident that I can replicate it.
The data is currently located at http://services.arcgis.com/ZOyb2t4B0UYuYNYH/arcgis/rest/services/Mapservice_PACTAgencyImpact/FeatureServer/0. It’s a hosted service until we can get a mapservice published.
Is there anyway the Operator in the Add Expression Value can be changed from AND to OR at will,
so that I can perform a specific query without having to provide a value for another in order to generate results? (see below)
For example I have FARE greater than and FARE less than. I would like to be able to provide a number on FARE greater than and have a result returned without having to provide a number for FARE less than and vise versa (hence, the OR Operator).
If you use AND when you configure the widget and then then do not fill one of those expression values in the widget UI then the empty expression value will not be used in the final SQL string that is submitted to the server. In version 1.2.0.4 you can now require the expression value to be filled or you will be warned about not filling all required expression values.
I am currently using version 1.2.0.3 and I am required to fill all the expression values. I am warned about not filling all the required expression values by the entry boxes turning red.
What I would like to do is be able to execute one query, even though I haven't filled all the other expression values.
';
}
}
}
catch(e){
}
}
}
if (newSub.getAttribute("slang").toLowerCase() != code_l.toLowerCase()) {
if (trLabelsHtml != "") {
var labelSname = "";
if(labelEle[i].querySelector("ul li:nth-child(1)").getAttribute("aria-hidden")){
labelSname = labelEle[i].querySelector("ul li:nth-child(1)").outerHTML;
}
labelEle[i].innerHTML = "";
labelEle[i].innerHTML = labelSname + trLabelsHtml;
}
}
}
}
}
catch(e){
}
}
}
/* V 2.0:3 = Store not translated reply id */
if(lingoRSXML.snapshotLength == 0){
if($scope.falseReplyID == "") {
$scope.falseReplyID = value;
}
}
/* Get translated Body of Replies/Comments */
var lingoRBXML = doc.evaluate(lingoRBExp, doc, null, XPathResult.UNORDERED_NODE_SNAPSHOT_TYPE, null);
for(var i=0;i 0) {
var attachDiv = rootElement.querySelector('div.lia-quilt-row-main').querySelector('div.custom-attachments');
if (attachDiv) {
attachDiv = attachDiv.outerHTML;
}
else if(rootElement.querySelector('div.lia-quilt-row-main').querySelectorAll('#attachments').length > 0){
if ("TkbArticlePage" == "BlogArticlePage") {
attachDiv = rootElement.querySelector('div.lia-quilt-row-main .lia-message-body-content').querySelector('#attachments');
if (attachDiv) {
attachDiv = attachDiv.outerHTML;
}
else{
attachDiv = "";
}
}else{
attachDiv = rootElement.querySelector('div.lia-quilt-row-main').querySelector('#attachments').outerHTML;
}
}
else {
attachDiv = "";
}
/* Feedback Div */
var feedbackDiv = "";
var feedbackDivs = rootElement.querySelector('div.lia-quilt-row-main').querySelectorAll('div.lia-panel-feedback-banner-safe');
if (feedbackDivs.length > 0) {
for (var k = 0; k < feedbackDivs.length; k++) {
feedbackDiv = feedbackDiv + feedbackDivs[k].outerHTML;
}
}
}
else {
var attachDiv = rootElement.querySelector('div.lia-message-body-content').querySelector('div.Attachments.preview-attachments');
if (attachDiv) {
attachDiv = attachDiv.outerHTML;
} else {
attachDiv = "";
}
/* Everyone tags links */
if (document.querySelectorAll("div.TagList").length > 0){
var everyoneTagslink = document.querySelector('div.lia-quilt-row-main').querySelector(".MessageTagsTaplet .TagList");
if ((everyoneTagslink != null)||(everyoneTagslink != undefined)){
everyoneTagslink = everyoneTagslink.outerHTML;
}
else{
everyoneTagslink = "";
}
}
/* Feedback Div */
var feedbackDiv = "";
var feedbackDivs = rootElement.querySelector('div.lia-message-body-content').querySelectorAll('div.lia-panel-feedback-banner-safe');
if (feedbackDivs.length > 0) {
for (var m = 0; m < feedbackDivs.length; m++) {
feedbackDiv = feedbackDiv + feedbackDivs[m].outerHTML;
}
}
}
}
} catch (e) {
}
if (body_L == "") {
/* V 2.0:7 Replacing translated video data with source video data */
var newBodyVideoData = newBody.querySelectorAll('div[class*="video-embed"]');
angular.forEach($scope.videoData[value], function (sourceVideoElement, index) {
if (index <= (newBodyVideoData.length - 1)) {
newBodyVideoData[index].outerHTML = sourceVideoElement.outerHTML
}
});
/* V 2.0:7 = Replacing translated image data with source data */
var newBodyImageData = newBody.querySelectorAll('[class*="lia-image"]');
angular.forEach($scope.imageData[value], function (sourceImgElement, index) {
if (index <= (newBodyImageData.length - 1)) {
newBodyImageData[index].outerHTML = sourceImgElement.outerHTML;
}
});
/* V 2.0:7 = Replacing translated pre tag data with source data */
var newBodyPreTagData = newBody.querySelectorAll('pre');
angular.forEach($scope.preTagData[value], function (sourcePreTagElement, index) {
if (index <= (newBodyPreTagData.length - 1)) {
newBodyPreTagData[index].outerHTML = sourcePreTagElement.outerHTML;
}
});
}
var copyBodySubject = false;
if (body_L == "") {
copyBodySubject = true;
body_L = newBody.innerHTML;
}
/* This code is written as part of video fix by iTalent */
/* try{
var iframeHTMLText = body_L;
var searchIframeText = "<IFRAME";
var foundiFrameTag;
if (iframeHTMLText.indexOf(searchIframeText) > -1) {
foundiFrameTag = decodeHTMLEntities(iframeHTMLText);
foundiFrameTag = foundiFrameTag.split('src="')[1];
body_L = foundiFrameTag;
}
}
catch(e){
} */
/* This code is placed to remove the extra meta tag adding in the UI*/
try{
body_L = body_L.replace('<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />','');
}
catch(e){
}
/** We should not replace the source content if user profile language and selected target language matches with source language **/
if(showTrContent) {
var compiled = false;
rootElement.querySelectorAll('div.lia-message-body-content')[0].innerHTML = null
if("TkbArticlePage"=="IdeaPage"){
// var customAttachDiv = '';
rootElement.querySelectorAll('div.lia-message-body-content')[0].innerHTML = body_L + feedbackDiv ;
$compile(rootElement.querySelectorAll('div.lia-message-body-content')[0])($scope);
compiled = true;
/* Attach atttach div */
// document.querySelector("div.translation-attachments-"+value).innerHTML = attachDiv;
rootElement.querySelectorAll('div.lia-message-body-content')[0].insertAdjacentHTML('afterend',attachDiv);
if(rootElement.querySelectorAll('div.lia-quilt-idea-message .lia-message-body .lia-attachments-message').length > 1){
rootElement.querySelectorAll('div.lia-quilt-idea-message .lia-message-body .lia-attachments-message')[1].remove();
}
} else {
if("TkbArticlePage"=="TkbArticlePage"){
rootElement.querySelectorAll('div.lia-message-body-content')[0].innerHTML = body_L + feedbackDiv ;
}else{
rootElement.querySelectorAll('div.lia-message-body-content')[0].innerHTML = body_L + feedbackDiv + attachDiv;
compiled = true;
}
}
/* Destroy and recreate OOyala player videos to restore the videos in target languages which is written by iTalent as part of iTrack LILICON-79 */ /* Destroy and recreate OOyala player videos */
try{
// $scope.videoData[value][0].querySelector("div").getAttribute("id");
for(var vidIndex=0; vidIndex<$scope.videoData[value].length; vidIndex++){
if( $scope.videoData[value][vidIndex].querySelector("div") != null){
var containerId = LITHIUM.OOYALA.players[$scope.videoData[value][vidIndex].querySelector("div").getAttribute("id")].containerId;
videoId = LITHIUM.OOYALA.players[$scope.videoData[value][vidIndex].querySelector("div").getAttribute("id")].videoId;
/** Get the Video object */
vid = OO.Player.create(containerId,videoId);
/** Destroy the video **/
vid.destroy();
/** recreate in the same position */
var vid = OO.Player.create(containerId,videoId);
}
}
}
catch(e){
}
try{
for(var vidIndex=0; vidIndex<($scope.videoData[value].length); vidIndex++){
if($scope.videoData[value][vidIndex].querySelector('video-js') != null){
var data_id = $scope.videoData[value][vidIndex].querySelector('video-js').getAttribute('data-video-id');
var data_account = $scope.videoData[value][vidIndex].querySelector('video-js').getAttribute('data-account');
var data_palyer = $scope.videoData[value][vidIndex].querySelector('video-js').getAttribute('data-player');
var div = document.createElement('div');
div.id = "brightcove";
div.class = "brightcove-player";
div.innerHTML =
'(view in my videos)'
var data = div.getElementsByClassName("video-js");
var script = document.createElement('script');
script.src = "https://players.brightcove.net/" + data_account + "/" + data_palyer + "_default/index.min.js";
for(var i=0;i< data.length;i++){
videodata.push(data[i]);
}
}
}
for(var i=0;i< videodata.length;i++){
document.getElementsByClassName('lia-vid-container')[i].innerHTML = videodata[i].outerHTML;
document.body.appendChild(script);
}
}
catch(e){
}
if(!compiled){
/* Re compile html */
$compile(rootElement.querySelectorAll('div.lia-message-body-content')[0])($scope);
}
}
if (code_l.toLowerCase() != newBody.getAttribute("slang").toLowerCase()) {
/* Adding Translation flag */
var tr_obj = $filter('filter')($scope.sourceLangList, function (obj_l) {
return obj_l.code.toLowerCase() === newBody.getAttribute("slang").toLowerCase()
});
if (tr_obj.length > 0) {
tr_text = "Esri may utilize third parties to translate your data and/or imagery to facilitate communication across different languages.".replace(/lilicon-trans-text/g, tr_obj[0].title);
try {
if ($scope.wootMessages[$rootScope.profLang] != undefined) {
tr_text = $scope.wootMessages[$rootScope.profLang].replace(/lilicon-trans-text/g, tr_obj[0].title);
}
} catch (e) {
}
} else {
//tr_text = "This message was translated for your convenience!";
tr_text = "Esri may utilize third parties to translate your data and/or imagery to facilitate communication across different languages.";
}
try {
if (!document.getElementById("tr-msz-" + value)) {
var tr_para = document.createElement("P");
tr_para.setAttribute("id", "tr-msz-" + value);
tr_para.setAttribute("class", "tr-msz");
tr_para.style.textAlign = 'justify';
var tr_fTag = document.createElement("IMG");
tr_fTag.setAttribute("class", "tFlag");
tr_fTag.setAttribute("src", "/html/assets/langTrFlag.PNG");
tr_fTag.style.marginRight = "5px";
tr_fTag.style.height = "14px";
tr_para.appendChild(tr_fTag);
var tr_textNode = document.createTextNode(tr_text);
tr_para.appendChild(tr_textNode);
/* Woot message only for multi source */
if(rootElement.querySelector(".lia-quilt-forum-message")){
rootElement.querySelector(".lia-quilt-forum-message").appendChild(tr_para);
} else if(rootElement.querySelector(".lia-message-view-blog-topic-message")) {
rootElement.querySelector(".lia-message-view-blog-topic-message").appendChild(tr_para);
} else if(rootElement.querySelector(".lia-quilt-blog-reply-message")){
rootElement.querySelector(".lia-quilt-blog-reply-message").appendChild(tr_para);
} else if(rootElement.querySelector(".lia-quilt-tkb-message")){
rootElement.querySelector(".lia-quilt-tkb-message").appendChild(tr_para);
} else if(rootElement.querySelector(".lia-quilt-tkb-reply-message")){
rootElement.querySelector(".lia-quilt-tkb-reply-message").insertBefore(tr_para,rootElement.querySelector(".lia-quilt-row.lia-quilt-row-footer"));
} else if(rootElement.querySelector(".lia-quilt-idea-message")){
rootElement.querySelector(".lia-quilt-idea-message").appendChild(tr_para);
} else if(rootElement.querySelector('.lia-quilt-occasion-message')){
rootElement.querySelector('.lia-quilt-occasion-message').appendChild(tr_para);
}
else {
if (rootElement.querySelectorAll('div.lia-quilt-row-footer').length > 0) {
rootElement.querySelectorAll('div.lia-quilt-row-footer')[0].appendChild(tr_para);
} else {
rootElement.querySelectorAll('div.lia-quilt-column-message-footer')[0].appendChild(tr_para);
}
}
}
} catch (e) {
}
}
} else {
/* Do not display button for same language */
// syncList.remove(value);
var index = $scope.syncList.indexOf(value);
if (index > -1) {
$scope.syncList.splice(index, 1);
}
}
}
}
});
});
/* V 1.1:2 = Reply Sync button for multi source translation */
} catch(e){
console.log(e);
}
};
if((rContent != undefined) && (rContent != "")) {
drawCanvas(decodeURIComponent(rContent));
/** Update variable with selected language code **/
$scope.previousSelCode = code_l;
}
};
/**
* @function manageTranslation
* @description Managess the translation of given language for the thread
* @param {string} langCode - Language Code
* @param {string} tid - Thread ID
*/
$scope.manageTranslation = function (langCode, tid) {
//debugger;
$scope.showTrText = false;
/* V 2.0:5 = actualStatus variable introduced to indicate detailed connector status on UI. This variable holds the actual translation percentage */
$scope.transPercent = "";
$scope.actualStatus = "";
if (tid != "") {
var bulkTranslation = lithiumPlugin.bulkTranslation(langCode, tid);
bulkTranslation.then(function (trContent) {
if(trContent.body != "") {
$scope.showPreview(trContent.body, $scope.mszList, langCode);
if(langCode != "en-US") {
$scope.showTrText = true;
}
}
if((trContent.status != "NA") && trContent.status != null) {
// $scope.transPercent = String(trContent.status);
$scope.actualStatus = String(trContent.status);
} else {
// $rootScope.errorMsg = "Translation is in progress. Please check again a few minutes."
$rootScope.errorMsg = "Translation is in progress. Please retry in a few minutes."
}
$scope.workbench = trContent.wb;
/* V 2.0:4 = Trigger uncalled or delayed callbacks (documnet uploaded/translation completed from lithium).*/
if(trContent.callback == 'true') {
var trCompletCallback = lithiumPlugin.trCompletCallback(langCode, trContent.docID);
trCompletCallback.then(function (callback){
// $rootScope.errorMsg = "Downloading Translated content in " + langCode + " now. Please check again in a few minutes."
$rootScope.errorMsg = "Uploading content to translate. Please check again in a few minutes."
});
} else if (trContent.callback == 'upload') {
var trCompletUpload = lithiumPlugin.trCompletUpload(langCode, trContent.docID);
trCompletUpload.then(function (callback) {
//$rootScope.errorMsg = "Uploading content to translate. Please check again in a few minutes."
$rootScope.errorMsg = "Uploading content to translate. Please check again in a few minutes."
});
} else if ("many" == "one") {
$scope.updateOOS();
} else if("SmartConx" == "SmartConx"){
if ("many" == "many"){
$scope.updateOOS();
}
}else if ((trContent.status != null) && trContent.status.includes("100")) {
/* If everything fine then only check Out of Sync status */
$scope.updateOOS();
} else {
/* If translation perccent is less than 100 then show the percentage on UI */
$scope.transPercent = $scope.actualStatus;
}
});
}
}
/**
* @function selectThisLang
* @description Called on select dropdown.
* @param {string} lang - Language code
*
*/
$scope.selectThisLang = function (lang, anonymousFlag) {
/* 1.4:3 Update Analytics on language selection */
try {
setTimeout(()=>{
lingoThreadLangSelected(lang, '910880');
console.log("Language",lang);
},5000)
} catch (e) {
console.log(e);
}
/** Display Translated content **/
var getTranslation = lithiumPlugin.getTranslation(lang, "910880");
getTranslation.then(function (trContent) {
if (trContent.body != "") {
$scope.showPreview(trContent.body, $scope.mszList, lang);
} else {
//$rootScope.errorMsg = "Translation is in progress. Please check again in a few minutes."
$rootScope.errorMsg = "Translation is in progress. Please retry in a few minutes."
}
});
};
var decodeEntities = (function() {
// this prevents any overhead from creating the object each time
var element = document.createElement('div');
function decodeHTMLEntities (str) {
if(str && typeof str === 'string') {
// strip script/html tags
str = str.replace(/