Mail and Booking
This commit is contained in:
parent
62e84637b6
commit
5daea268f7
250 changed files with 5377 additions and 1473 deletions
|
|
@ -151,7 +151,7 @@ $(function () {
|
|||
'X-CSRF-TOKEN': $('meta[name="csrf-token"]').attr('content')
|
||||
},
|
||||
success: function(data) {
|
||||
console.log(data);
|
||||
// console.log(data);
|
||||
$(data.response.target).find('.modal-dialog').html(data.html);
|
||||
$(data.response.target + '.selectpicker').selectpicker('refresh');
|
||||
initModalInner();
|
||||
|
|
@ -170,6 +170,41 @@ $(function () {
|
|||
|
||||
});
|
||||
|
||||
function ajax_object_action(event, object, callback) {
|
||||
event.preventDefault();
|
||||
var data = {};
|
||||
$.each(object.data(), function(index, value){
|
||||
data[index] = value;
|
||||
});
|
||||
var url = data['url'];
|
||||
/*console.log(data);
|
||||
console.log(url);*/
|
||||
$.ajax({
|
||||
url: url,
|
||||
data: data,
|
||||
type: "POST",
|
||||
dataType: "json",
|
||||
cache: false,
|
||||
contentType: 'application/x-www-form-urlencoded; charset=UTF-8',
|
||||
encode: true,
|
||||
headers: {
|
||||
'X-CSRF-TOKEN': $('meta[name="csrf-token"]').attr('content')
|
||||
},
|
||||
success: function(data) {
|
||||
//data will send data to callback function
|
||||
callback(data);
|
||||
},
|
||||
error: function(xhr, status, errorThrown) {
|
||||
console.log(xhr);
|
||||
console.log(xhr.responseText);
|
||||
console.log(status);
|
||||
console.log(errorThrown);
|
||||
console.log("Sorry, there was a problem!");
|
||||
}
|
||||
});
|
||||
return false;
|
||||
}
|
||||
|
||||
function update_modal_data_show(e, $ele) {
|
||||
e.preventDefault();
|
||||
|
||||
|
|
@ -178,8 +213,8 @@ function update_modal_data_show(e, $ele) {
|
|||
data = {id:ele.data('data')} ,
|
||||
contentType = 'application/x-www-form-urlencoded; charset=UTF-8';
|
||||
|
||||
console.log(data);
|
||||
console.log(url);
|
||||
/* console.log(data);
|
||||
console.log(url);*/
|
||||
$.ajax({
|
||||
url: url,
|
||||
data: data,
|
||||
|
|
@ -381,25 +416,5 @@ $(function() {
|
|||
e.preventDefault();
|
||||
$('.messages-wrapper, .messages-card').toggleClass('messages-sidebox-open');
|
||||
});
|
||||
|
||||
// New message
|
||||
// {
|
||||
|
||||
if (!window.Quill) {
|
||||
$('#message-editor,#message-editor-toolbar').remove();
|
||||
$('#message-editor-fallback').removeClass('d-none');
|
||||
} else {
|
||||
$('#message-editor-fallback').remove();
|
||||
new Quill('#message-editor', {
|
||||
modules: {
|
||||
toolbar: '#message-editor-toolbar'
|
||||
},
|
||||
placeholder: 'Type your message...',
|
||||
theme: 'snow'
|
||||
});
|
||||
}
|
||||
|
||||
// }
|
||||
|
||||
});
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue