Spaces:
Sleeping
Sleeping
Update templates/proposed-GUI.html
Browse files- templates/proposed-GUI.html +37 -5
templates/proposed-GUI.html
CHANGED
|
@@ -1686,7 +1686,7 @@ function getData(form) {
|
|
| 1686 |
|
| 1687 |
if (formvalues['selectprojs'].startsWith('1.0') || formvalues['selectprojs'].startsWith('3.2') || formvalues['selectprojs'].startsWith('2.8') || formvalues['selectprojs'].startsWith('3.3') )
|
| 1688 |
{// Set the interval in milliseconds
|
| 1689 |
-
const interval =
|
| 1690 |
const initialDelay = 0;
|
| 1691 |
console.log('Starting first AJAX request...');
|
| 1692 |
let delrows1=0; // Define delrows1 in a broader scope
|
|
@@ -1890,7 +1890,7 @@ function get3rddropdown(){
|
|
| 1890 |
|
| 1891 |
|
| 1892 |
if(( (inputs1.value=='ground beams' ) || (inputs1.value=='pile caps' ) ) & (!selections1.value))//& (selections.value.startsWith('Pile') || !selections.value )) || (inputs.children[0].value=='pile caps' & (selections.value.startsWith('Ground') || !selections.value )))
|
| 1893 |
-
{
|
| 1894 |
selections1.innerHTML='';
|
| 1895 |
|
| 1896 |
|
|
@@ -1906,7 +1906,7 @@ function get3rddropdown(){
|
|
| 1906 |
|
| 1907 |
}
|
| 1908 |
else if(( (inputs1.value=='Floor' ) || (inputs1.value=='Wall' ) ) & (!selections1.value))//& (selections.value.startsWith('Pile') || !selections.value )) || (inputs.children[0].value=='pile caps' & (selections.value.startsWith('Ground') || !selections.value )))
|
| 1909 |
-
{
|
| 1910 |
selections1.innerHTML='';
|
| 1911 |
|
| 1912 |
|
|
@@ -1920,7 +1920,23 @@ function get3rddropdown(){
|
|
| 1920 |
}
|
| 1921 |
console.log(section.value.toString())
|
| 1922 |
|
| 1923 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1924 |
|
| 1925 |
// if (inputs1.value.startsWith('Floor') & (selections1.value.startsWith('Wall') || !selections1.value )){
|
| 1926 |
// selections1.innerHTML='';
|
|
@@ -2033,6 +2049,20 @@ function get3rddropdown(){
|
|
| 2033 |
}
|
| 2034 |
|
| 2035 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 2036 |
|
| 2037 |
// if (inputs.value=='Floor' & (selections.value.startsWith('Wall') || !selections.value )){
|
| 2038 |
// selections.innerHTML='';
|
|
@@ -2518,6 +2548,7 @@ levelsin.addEventListener('click',function(){
|
|
| 2518 |
.success (function(data){
|
| 2519 |
document.getElementById("all").style.display = "none";
|
| 2520 |
var popup = window.open('');
|
|
|
|
| 2521 |
popup.document.write('<html><head><title>ADR Console:Draw on PDF tool</title><link rel="stylesheet" href="static/style.css"></head><body>');
|
| 2522 |
|
| 2523 |
var element = popup.document.createElement('div');
|
|
@@ -2534,6 +2565,7 @@ levelsin.addEventListener('click',function(){
|
|
| 2534 |
canvaswindow.removeAttribute('hidden');
|
| 2535 |
var imgDrawon =document.createElement("img");
|
| 2536 |
imgDrawon.src = 'data:image/gif;base64,' +data[0];
|
|
|
|
| 2537 |
imgDrawon.width=data[2];
|
| 2538 |
imgDrawon.style.width='700px';
|
| 2539 |
imgDrawon.id='imgcanvas';
|
|
@@ -2739,7 +2771,7 @@ $.get('/getAPITables/')
|
|
| 2739 |
table2=data[1]; //prj parts table
|
| 2740 |
table3=data[2]; //prj sections table
|
| 2741 |
|
| 2742 |
-
})
|
| 2743 |
.error(function(jqXHR, textStatus, errorThrown) {
|
| 2744 |
PopupElement.textContent='Error occured. Refresh and try again. If the error continues, please contact the ADR team to fix it. ';
|
| 2745 |
ShowPopUp();
|
|
|
|
| 1686 |
|
| 1687 |
if (formvalues['selectprojs'].startsWith('1.0') || formvalues['selectprojs'].startsWith('3.2') || formvalues['selectprojs'].startsWith('2.8') || formvalues['selectprojs'].startsWith('3.3') )
|
| 1688 |
{// Set the interval in milliseconds
|
| 1689 |
+
const interval = 6000;
|
| 1690 |
const initialDelay = 0;
|
| 1691 |
console.log('Starting first AJAX request...');
|
| 1692 |
let delrows1=0; // Define delrows1 in a broader scope
|
|
|
|
| 1890 |
|
| 1891 |
|
| 1892 |
if(( (inputs1.value=='ground beams' ) || (inputs1.value=='pile caps' ) ) & (!selections1.value))//& (selections.value.startsWith('Pile') || !selections.value )) || (inputs.children[0].value=='pile caps' & (selections.value.startsWith('Ground') || !selections.value )))
|
| 1893 |
+
{ //1.0
|
| 1894 |
selections1.innerHTML='';
|
| 1895 |
|
| 1896 |
|
|
|
|
| 1906 |
|
| 1907 |
}
|
| 1908 |
else if(( (inputs1.value=='Floor' ) || (inputs1.value=='Wall' ) ) & (!selections1.value))//& (selections.value.startsWith('Pile') || !selections.value )) || (inputs.children[0].value=='pile caps' & (selections.value.startsWith('Ground') || !selections.value )))
|
| 1909 |
+
{ //3.2
|
| 1910 |
selections1.innerHTML='';
|
| 1911 |
|
| 1912 |
|
|
|
|
| 1920 |
}
|
| 1921 |
console.log(section.value.toString())
|
| 1922 |
|
| 1923 |
+
}
|
| 1924 |
+
else if(( (inputs1.value=='Ceiling' ) ) & (!selections1.value))//& (selections.value.startsWith('Pile') || !selections.value )) || (inputs.children[0].value=='pile caps' & (selections.value.startsWith('Ground') || !selections.value )))
|
| 1925 |
+
{ //3.3
|
| 1926 |
+
selections1.innerHTML='';
|
| 1927 |
+
|
| 1928 |
+
|
| 1929 |
+
for (let m=0;m<MCTNames.length;m++)
|
| 1930 |
+
{
|
| 1931 |
+
var opt0 = document.createElement("OPTION") ;
|
| 1932 |
+
opt0.text= MCTNames[m][0];
|
| 1933 |
+
opt0.textContent= MCTNames[m][0];
|
| 1934 |
+
opt0.value= MCTNames[m][0];
|
| 1935 |
+
selections1.add(opt0);
|
| 1936 |
+
}
|
| 1937 |
+
console.log(section.value.toString())
|
| 1938 |
+
|
| 1939 |
+
}
|
| 1940 |
|
| 1941 |
// if (inputs1.value.startsWith('Floor') & (selections1.value.startsWith('Wall') || !selections1.value )){
|
| 1942 |
// selections1.innerHTML='';
|
|
|
|
| 2049 |
}
|
| 2050 |
|
| 2051 |
}
|
| 2052 |
+
else if(( (inputs.value=='Ceiling' ) ) & (!selections.value))//& (selections.value.startsWith('Pile') || !selections.value )) || (inputs.children[0].value=='pile caps' & (selections.value.startsWith('Ground') || !selections.value )))
|
| 2053 |
+
{
|
| 2054 |
+
selections.innerHTML='';
|
| 2055 |
+
|
| 2056 |
+
for (let m=0;m<MCTNames.length;m++)
|
| 2057 |
+
{
|
| 2058 |
+
var opt0 = document.createElement("OPTION") ;
|
| 2059 |
+
opt0.text= MCTNames[m][0];
|
| 2060 |
+
opt0.textContent= MCTNames[m][0];
|
| 2061 |
+
opt0.value= MCTNames[m][0];
|
| 2062 |
+
selections.add(opt0);
|
| 2063 |
+
}
|
| 2064 |
+
|
| 2065 |
+
}
|
| 2066 |
|
| 2067 |
// if (inputs.value=='Floor' & (selections.value.startsWith('Wall') || !selections.value )){
|
| 2068 |
// selections.innerHTML='';
|
|
|
|
| 2548 |
.success (function(data){
|
| 2549 |
document.getElementById("all").style.display = "none";
|
| 2550 |
var popup = window.open('');
|
| 2551 |
+
console.log(popup)
|
| 2552 |
popup.document.write('<html><head><title>ADR Console:Draw on PDF tool</title><link rel="stylesheet" href="static/style.css"></head><body>');
|
| 2553 |
|
| 2554 |
var element = popup.document.createElement('div');
|
|
|
|
| 2565 |
canvaswindow.removeAttribute('hidden');
|
| 2566 |
var imgDrawon =document.createElement("img");
|
| 2567 |
imgDrawon.src = 'data:image/gif;base64,' +data[0];
|
| 2568 |
+
console.log('srcc'+imgDrawon.src)
|
| 2569 |
imgDrawon.width=data[2];
|
| 2570 |
imgDrawon.style.width='700px';
|
| 2571 |
imgDrawon.id='imgcanvas';
|
|
|
|
| 2771 |
table2=data[1]; //prj parts table
|
| 2772 |
table3=data[2]; //prj sections table
|
| 2773 |
|
| 2774 |
+
})
|
| 2775 |
.error(function(jqXHR, textStatus, errorThrown) {
|
| 2776 |
PopupElement.textContent='Error occured. Refresh and try again. If the error continues, please contact the ADR team to fix it. ';
|
| 2777 |
ShowPopUp();
|