Files
luos/workflow/engine/xmlform/triggers/triggersCustom.xml

108 lines
3.3 KiB
XML
Raw Normal View History

<?xml version="1.0" encoding="UTF-8"?>
2010-12-02 23:34:41 +00:00
<dynaForm name="triggersProperties" type="xmlform" width="100%" labelWidth="20%" enableTemplate="1">
<PRO_UID type="hidden"/>
<FIELDS_REQUIRED type="hidden"/>
2010-12-02 23:34:41 +00:00
<TITLE type="title" group="1">
<en>Trigger Information</en>
</TITLE>
<TRI_UID type="hidden"/>
<TRI_TITLE type="text" size="80" maxlength="100">
<en>Title</en>
</TRI_TITLE>
<TRI_PARAM type="hidden" value=""/>
<TRI_TYPE type="hidden"/>
<TRI_DESCRIPTION type="textarea" rows="3" cols="77">
<en>Description</en>
</TRI_DESCRIPTION>
<TRI_WEBBOT type="textareapm" class="formLabel" cols="55" rows="13" width="100%" height="380px" showVars="1" process="@#PRO_UID">
2010-12-02 23:34:41 +00:00
</TRI_WEBBOT>
<SAVE type="button" onclick="document.getElementById('form[TRI_WEBBOT]').value = triggerEditor.getValue(); triggerSave1(this.form);">
2010-12-02 23:34:41 +00:00
<en>Save</en>
</SAVE>
<BTN_CANCEL type="button" onclick="cancel();triggerFromLibrary()">
<en>Cancel</en>
</BTN_CANCEL>
<JS type="JavaScript"><![CDATA[
/*var triggerEditor = CodeMirror.fromTextArea('form[TRI_WEBBOT]', {
height: "220px",
width: "80%",
parserfile: ["parsexml.js", "parsecss.js", "tokenizejavascript.js", "parsejavascript.js",
"../contrib/php/js/tokenizephp.js", "../contrib/php/js/parsephp.js",
"../contrib/php/js/parsephphtmlmixed.js"],
stylesheet: ["css/xmlcolors.css", "css/jscolors.css", "css/csscolors.css", "css/phpcolors.css" ],
path: "js/", lineNumbers: true, continuousScanning: 500, parserConfig: { phpOnly:true} });*/
CodeMirror.commands.autocomplete = function(cm) {
CodeMirror.showHint(cm, CodeMirror.phpHint);
}
var triggerEditor = CodeMirror.fromTextArea(document.getElementById("form[TRI_WEBBOT]"), {
lineNumbers: true,
matchBrackets: true,
mode: "application/x-httpd-php",
PMEnabled: true,
indentUnit: 2,
indentWithTabs: false,
extraKeys: {"Ctrl-Space": "autocomplete"}
});
triggerEditor.setSize(400,250);
2010-12-02 23:34:41 +00:00
getField('TRI_TITLE').form.onsubmit = function() {return false;};
var _oVarsPanel_;
var showDynaformsFormVars = function(sFieldName, sAjaxServer, sProcess, sSymbol) {
_oVarsPanel_ = new leimnud.module.panel();
_oVarsPanel_.options = {
limit : true,
size : {w:600,h:420},
2010-12-02 23:34:41 +00:00
position : {x:0,y:0,center:true},
title : '',
theme : 'processmaker',
statusBar: false,
control : {drag:false,resize:true,close:true},
fx : {opacity:true,rolled:false,modal:true}
};
_oVarsPanel_.make();
_oVarsPanel_.events = {
remove:function() {
delete _oVarsPanel_;
}.extend(this)
};
_oVarsPanel_.loader.show();
oRPC = new leimnud.module.rpc.xmlhttp({
url : sAjaxServer,
method: 'POST',
args : 'sFieldName=' + sFieldName + '&sProcess=' + sProcess + '&sSymbol=' + sSymbol
});
oRPC.callback = function(oRPC) {
_oVarsPanel_.loader.hide();
var scs = oRPC.xmlhttp.responseText.extractScript();
_oVarsPanel_.addContent(oRPC.xmlhttp.responseText);
scs.evalScript();
}.extend(this);
oRPC.make();
};
var insertFormVar = function(sFieldName, sValue) {
if (triggerEditor.getSelection() == "") {
triggerEditor.replaceRange(sValue, triggerEditor.getCursor());
} else {
triggerEditor.replaceSelection(sValue);
}
_oVarsPanel_.remove();
triggerEditor.focus();
2010-12-02 23:34:41 +00:00
};
function cancel(){
currentPopupWindow.remove();
}
]]></JS>
</dynaForm>