diff --git a/_server/css/editor_mode.css b/_server/css/editor_mode.css index 1985bd23..e260377c 100644 --- a/_server/css/editor_mode.css +++ b/_server/css/editor_mode.css @@ -19,37 +19,6 @@ width: 435px; } -/* -#left1 { - left: 5px; - top: 650px; - width: 435px; -} - -#left2 { - left: 448px; - top: 650px; - width: 440px; -} - -#left3 { - left: 900px; - top: 650px; - width: 440px; -} - -#left4 { - left: 5px; - top: 1290px; - width: 435px; -} - -#left5 { - left: 448px; - top: 1290px; - width: 440px; -} - */ #left6 { left: 5px; /* top: 1930px; */ @@ -81,13 +50,7 @@ height: 700px; width: 940px; } -/* -#left8 { - left: 900px; - top: 1290px; - width: 440px; -} - */ + .etable table, .etable table td { color: #000; @@ -133,25 +96,6 @@ overflow: visible; } -.etable tr:not(:first-child) :last-child { - margin: 0; - padding: 0; - height: 100%; - width: 100%; -} - -.etable tr:not(:first-child) input:last-child { - -} - -.etable tr:not(:first-child) select:last-child { - -} - -.etable tr:not(:first-child) textarea:last-child { - -} - .etable tr:not(:first-child) > :last-child:hover { border: 1px solid rgb(87, 198, 232); box-shadow: 0px 0px 3px rgb(87, 198, 232); @@ -161,4 +105,45 @@ .etable tr:not(:first-child) > :nth-child(1):hover { border: 1px solid rgb(87, 232, 198); box-shadow: 0px 0px 3px rgb(87, 232, 198); -} \ No newline at end of file +} + +.etable tr:not(:first-child) > :last-child { + margin: 0; + padding: 0; + height: 100%; + width: 100%; + position: relative; +} + +div.etableInputDiv { + position: absolute; + padding: 5px 0 0 5px; + top: 0; + bottom: 0; + left: 0; + right: 0; +} + +.etableInputDiv > * { + margin: 0; + padding: 0; + height: 100%; + width: 100%; + background-color: rgba(255, 255, 255, 0); + border: none; +} + +.etableInputDiv input { + +} + +.etableInputDiv select { + +} + +.etableInputDiv textarea { + resize: none; +} +.etableInputDiv textarea:hover { + margin: -5px; +} diff --git a/_server/editor_blockly.js b/_server/editor_blockly.js index 214fbb36..5348669e 100644 --- a/_server/editor_blockly.js +++ b/_server/editor_blockly.js @@ -302,7 +302,7 @@ editor_blockly.id=''; editor_blockly.import = function(id_){ var thisTr = document.getElementById(id_); - if(!thisTr)return; + if(!thisTr)return false; var input = thisTr.children[2].children[0].children[0]; var field = thisTr.children[0].getAttribute('title'); var type = { @@ -319,12 +319,13 @@ editor_blockly.import = function(id_){ "--point--未完成数据转移":'point', }[field]; - if(!type)return; + if(!type)return false; editor_blockly.id=id_; document.getElementById('codeArea').value = input.value; document.getElementById('entryType').value = type; editor_blockly.parse(); editor_blockly.show(); + return true; } editor_blockly.show = function(){document.getElementById('left6').style='';} diff --git a/_server/editor_mode.js b/_server/editor_mode.js index fa06fda7..22201e19 100644 --- a/_server/editor_mode.js +++ b/_server/editor_mode.js @@ -77,8 +77,9 @@ editor_mode.prototype.objToTable = function(obj,commentObj){ //现阶段这样会更实用,20180218 } input.ondblclick = function(){ - editor_blockly.import(guid); - editor_multi.import(guid); + if(!editor_blockly.import(guid)) + if(!editor_multi.import(guid)){} + } }); } @@ -119,7 +120,7 @@ editor_mode.prototype.objToTr = function(obj,commentObj,field){ var outstr=['