0) {
if(maxFilesize > uploadMaxFilesize) {
new leimnud.module.app.alert().make({label: _("ID_INPUT_MAX_SIZE")});
getField("INP_DOC_MAX_FILESIZE").focus();
return false;
}
}
} else {
alert('@G::LoadTranslation(ID_INPUT_DOC_MAX_FILESIZE_REQUIRED)');
maxFilesize.focus();
return false;
}
return true;
}
function inputdocsSave( form ) {
var nameInput = getField('INP_DOC_TITLE').value;
var proUid = getField('PRO_UID').value;
if(getField('INP_DOC_UID').value==''){
if (validate_form()){
reqName=ajax_function(form.action,'lookForNameInput','NAMEINPUT='+encodeURIComponent(nameInput)+'&proUid='+encodeURIComponent(proUid),'POST') ;
if(reqName){
ajax_post( form.action, form, 'POST' );
currentPopupWindow.remove();
@#PAGED_TABLE_ID.refresh();
}else{
alert(G_STRINGS.ID_EXIST_INPUTDOCUMENT);return false;
}
}
}else{
if (validate_form()){
ajax_post( form.action, form, 'POST' );
currentPopupWindow.remove();
@#PAGED_TABLE_ID.refresh();
}
}
}
function inputdocsDelete( uid ) {
result = ajax_function('@G::encryptlink(@#inputdocsDelete)','getRelationInfDoc','INP_DOC_UID='+uid,'POST');
labelToshow = (result)?'@G::LoadTranslation(ID_MSG_CONFIRM_DELETE_IDOCUMENT)':'@G::LoadTranslation(ID_MSG_CONFIRM_DELETE_DOCUMENT)';
new leimnud.module.app.confirm().make({
label:labelToshow,
action:function()
{
ajax_function('@G::encryptlink(@#inputdocsDelete)','deleteInputDocument','INP_DOC_UID='+uid,'POST');
@#PAGED_TABLE_ID.refresh();
}.extend(this)
});
}
]]>