added object.js
This commit is contained in:
parent
5174824b5f
commit
92c87ca9b8
1 changed files with 28 additions and 0 deletions
28
www/extras/wobject/Survey/editsurvey/object.js
Normal file
28
www/extras/wobject/Survey/editsurvey/object.js
Normal file
|
|
@ -0,0 +1,28 @@
|
|||
if (typeof Survey == "undefined") {
|
||||
var Survey = {};
|
||||
}
|
||||
|
||||
Survey.ObjectTemplate = new function(){
|
||||
|
||||
this.loadObject = function(html,type){
|
||||
|
||||
document.getElementById('edit').innerHTML = html;
|
||||
|
||||
var butts = [ { text:"Submit", handler:function(){this.submit();}, isDefault:true }, { text:"Cancel", handler:function(){this.cancel();}},
|
||||
{text:"Delete", handler:function(){document.getElementById('delete').value = 1; this.submit();}}
|
||||
];
|
||||
|
||||
var form = new YAHOO.widget.Dialog(type,
|
||||
{ width : "500px",
|
||||
fixedcenter : true,
|
||||
visible : false,
|
||||
constraintoviewport : true,
|
||||
buttons : butts
|
||||
} );
|
||||
|
||||
form.callback = Survey.Comm.callback;
|
||||
form.render();
|
||||
form.show();
|
||||
}
|
||||
}();
|
||||
|
||||
Loading…
Add table
Add a link
Reference in a new issue