Change path to Controller\Records

This commit is contained in:
Nicolas Le Goff
2012-10-19 16:51:01 +02:00
parent ae447cad96
commit 1859436cb2
4 changed files with 24 additions and 72 deletions

View File

@@ -33,11 +33,8 @@ function cancelCgus(id)
$.ajax({ $.ajax({
type: "POST", type: "POST",
url: "/prod/prodFeedBack.php", url: "/prod/TOU/deny/"+id+"/",
data: { data: {},
sbas_id:id,
action:'DENY_CGU'
},
success: function(data){ success: function(data){
if(data == '1') if(data == '1')
{ {

View File

@@ -7,22 +7,20 @@ $(document).ready(function(){
}); });
function getNewVideoToken(sbas_id, record_id, obj) function getNewVideoToken(lst, obj)
{ {
$.ajax({ $.ajax({
type: "POST", type: "POST",
url: "/prod/prodFeedBack.php", url: "/prod/records/renew-url/",
dataType: 'json', dataType: 'json',
data: { data: {
action:'VIDEOTOKEN', lst: lst
sbas_id : sbas_id,
record_id : record_id
}, },
success: function(data){ success: function(data){
if(!data.url) if(!data[lst])
return; return;
obj.unload(); obj.unload();
obj.setClip(data); obj.setClip({url:data[lst]});
obj.play(); obj.play();
return; return;
} }

View File

@@ -63,9 +63,8 @@ var p4 = p4 || {};
$.ajax({ $.ajax({
type: "POST", type: "POST",
url: "/prod/prodFeedBack.php", url: "/user/preferences/temporary/",
data: { data: {
action: "SAVETEMPPREF",
prop:name, prop:name,
value:value value:value
}, },

View File

@@ -1623,67 +1623,27 @@ function toggleRemoveReg(el)
function deleteThis(lst) function deleteThis(lst)
{ {
var n = lst.split(';').length; if(lst.split(';').length === 0 ) {
alert(langage.nodocselected);
return false;
}
var $dialog = p4.Dialog.Create({
size:'Small',
title: language.deleteRecords
});
$.ajax({ $.ajax({
type: "POST", type: "POST",
url: "/prod/prodFeedBack.php", url: "/prod/records/delete/what/",
dataType: 'json', dataType: 'html',
data: { data: {lst: lst},
action: "DELETE",
lst: lst
},
success: function(data){ success: function(data){
$dialog.setContent(data);
if(data.lst.length > 0)
{
if(data.lst.length != n)
{
alert(language.candeletesome);
}
var texte = '<p style="padding: 10px 0pt; background-color: red; color: black; font-weight: bold;">' + '<span class="ui-icon ui-icon-alert" style="float:left; margin:0 7px 20px 0;"></span>'+language.confirmDelete;
if(data.groupings > 0)
texte += '<div><input type="checkbox" id="del_children" /><label for="del_children">' + language.confirmGroup + '</label></div>';
texte += '</p>';
var buttons = {};
buttons[language.deleteTitle+' ('+data.lst.length+')'] = function() {
$("#DIALOG").dialog('close').dialog('destroy');
doDelete(data.lst);
};
buttons[language.annuler] = function() {
$("#DIALOG").dialog('close').dialog('destroy');
};
$("#DIALOG").dialog('destroy').attr('title',language.deleteTitle)
.empty()
.append(texte)
.dialog({
autoOpen:false,
closeOnEscape:true,
resizable:false,
draggable:false,
modal:true,
draggable:false,
overlay: {
backgroundColor: '#000',
opacity: 0.7
}
}).dialog('open').dialog('option','buttons',buttons);
$('#tooltip').hide();
}
else
{
alert(language.candeletedocuments);
}
} }
}); });
return false;
} }
function chgCollThis(datas) function chgCollThis(datas)
@@ -1897,7 +1857,6 @@ function activeIcons()
} }
} }
} }
if(type !== '') if(type !== '')
{ {
checkDeleteThis(type, el); checkDeleteThis(type, el);
@@ -2600,10 +2559,9 @@ function doDelete(lst)
children = '1'; children = '1';
$.ajax({ $.ajax({
type: "POST", type: "POST",
url: "/prod/prodFeedBack.php", url: "/prod/delete/",
dataType: 'json', dataType: 'json',
data: { data: {
action: "DODELETE",
lst: lst.join(';'), lst: lst.join(';'),
del_children: children del_children: children
}, },