提交 acf404cb 编写于 作者: U unknown

视图中增加可以选择行的条件

上级 17c289bc
......@@ -321,6 +321,10 @@ MWF.xApplication.cms.Module.QueryViewer = new Class({
this.viewJson.firstTdHidden = true;
if( this.json.defaultSelectedScript )this.json.defaultSelectedScript = "";
if( this.viewJson.defaultSelectedScript )this.viewJson.defaultSelectedScript = "";
if( this.json.selectedAbleScript )this.json.selectedAbleScript = "";
if( this.viewJson.selectedAbleScript )this.viewJson.selectedAbleScript = "";
if( this.isSelectTdHidden() ){
this.selectTitleCell.hide();
}
......
......@@ -98,7 +98,7 @@
<tr>
<td class="editTableTitle">选择文件</td>
<td class="editTableValue">
<select name="select">
<select name="select" onchange="$('text{$.pid}selectedAbleScript').setStyle('display', this.options[this.selectedIndex].value === 'no' ? 'none' : 'block');">
<option text{($.select!='single' && $.select!='multi')?'selected':''} value="no">不允许</option>
<option text{($.select=='single')?'selected':''} value="single">单选</option>
<option text{($.select=='multi')?'selected':''} value="multi">多选</option>
......@@ -197,6 +197,8 @@
<div class="fieldListAreaNode_vf" style="display:none; min-height: 56px; border-bottom:1px solid #CCCCCC; overflow: hidden;"></div>
</div>
<div class="MWFScriptArea" name="defaultSelectedScript" title="默认选中行脚本"></div>
<div class="MWFScriptArea" name="selectedAbleScript" title="允许选择行脚本" id="text{$.pid}selectedAbleScript"
style="display: text{($.select=='single' || $.select=='multi')?'':'none'}"></div>
</div>
<div title="事件" class="MWFTab">
<div class="MWFEventsArea" name="events"></div>
......
......@@ -159,7 +159,7 @@
<tr>
<td class="editTableTitle">选择文件</td>
<td class="editTableValue">
<select name="select">
<select name="select" onchange="$('text{$.pid}selectedAbleScript').setStyle('display', this.options[this.selectedIndex].value === 'no' ? 'none' : 'block');">
<option text{($.select!='single' && $.select!='multi')?'selected':''} value="no">不允许</option>
<option text{($.select=='single')?'selected':''} value="single">单选</option>
<option text{($.select=='multi')?'selected':''} value="multi">多选</option>
......@@ -258,6 +258,8 @@
<div class="fieldListAreaNode_vf" style="display:none; min-height: 56px; border-bottom:1px solid #CCCCCC; overflow: hidden;"></div>
</div>
<div class="MWFScriptArea" name="defaultSelectedScript" title="默认选中行脚本"></div>
<div class="MWFScriptArea" name="selectedAbleScript" title="允许选择行脚本" id="text{$.pid}selectedAbleScript"
style="display: text{($.select=='single' || $.select=='multi')?'':'none'}"></div>
</div>
<div title="事件" class="MWFTab">
......
......@@ -108,6 +108,7 @@
<div class="MWFScriptArea" name="selectedScript" title="选择结果 (S)"></div>
</div>
<div class="MWFScriptArea" name="defaultSelectedScript" title="默认选中行脚本"></div>
<div class="MWFScriptArea" name="selectedAbleScript" title="允许选择行脚本"></div>
</div>
<div title="过滤" class="MWFTab">
<div class="MWFViewFilter">
......
......@@ -63,7 +63,8 @@ MWF.xApplication.process.Xform.View = MWF.APPView = new Class({
"isExpand": this.json.isExpand || "no",
"showActionbar" : this.json.actionbar === "show",
"filter": filter,
"defaultSelectedScript" : this.json.defaultSelectedScript ? this.json.defaultSelectedScript.code : null
"defaultSelectedScript" : this.json.defaultSelectedScript ? this.json.defaultSelectedScript.code : null,
"selectedAbleScript" : this.json.selectedAbleScript ? this.json.selectedAbleScript.code : null
};
//MWF.xDesktop.requireApp("query.Query", "Viewer", function(){
......
......@@ -284,7 +284,8 @@ MWF.xApplication.process.Xform.ViewSelector = MWF.APPViewSelector = new Class({
"isExpand": this.json.isExpand || "no",
"showActionbar" : this.json.actionbar === "show",
"filter": filter,
"defaultSelectedScript" : this.json.defaultSelectedScript ? this.json.defaultSelectedScript.code : null
"defaultSelectedScript" : this.json.defaultSelectedScript ? this.json.defaultSelectedScript.code : null,
"selectedAbleScript" : this.json.selectedAbleScript ? this.json.selectedAbleScript.code : null
};
var options = {};
var width = options.width || "850";
......
......@@ -69,16 +69,19 @@
if (this.checked){
$('text{$.id}selectBoxShowTr').setStyle('display', 'none');
$('text{$.id}allowSelectAllTr').setStyle('display', 'none');
$('text{$.id}selectedAbleScript').setStyle('display', 'none');
}"/>
<input class="editTableRadio" name="data.select" text{($.data.select==='single')?'checked':''} type="radio" value="single" onclick="
if (this.checked){
$('text{$.id}selectBoxShowTr').setStyle('display', 'table-row');
$('text{$.id}allowSelectAllTr').setStyle('display', 'none');
$('text{$.id}selectedAbleScript').setStyle('display', 'block');
}"/>单选
<input class="editTableRadio" name="data.select" text{($.data.select==='multi')?'checked':''} type="radio" value="multi" onclick="
if (this.checked){
$('text{$.id}selectBoxShowTr').setStyle('display', 'table-row');
$('text{$.id}allowSelectAllTr').setStyle('display', 'table-row');
$('text{$.id}selectedAbleScript').setStyle('display', 'block');
}"/>多选
</td>
</tr>
......@@ -144,7 +147,8 @@
</table>
<div class="MWFFormulaArea" name="data.defaultSelectedScript" title="默认选中行脚本"></div>
<div class="MWFFormulaArea" name="data.selectedAbleScript" title="允许选择行脚本"></div>
<div class="MWFFormulaArea" name="data.selectedAbleScript" title="允许选择行脚本" id="text{$.id}selectedAbleScript"
style="display: text{($.data.select=='single' || $.data.select=='multi')?'':'none'}"></div>
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册