Vijayakrishnan 3 жил өмнө
parent
commit
25ea908c43
2 өөрчлөгдсөн 11 нэмэгдсэн , 0 устгасан
  1. 0 0
      public/js/yemi.js
  2. 11 0
      yemi.js

Файлын зөрүү хэтэрхий том тул дарагдсан байна
+ 0 - 0
public/js/yemi.js


+ 11 - 0
yemi.js

@@ -321,6 +321,7 @@ var initMoes = function() {
         var redir = $(form).attr('redir'); // OPTIONAL
         var target = $(form).attr('target'); // OPTIONAL
         var noreload = $(form).is('[noreload]'); // OPTIONAL
+        var hook = $(form).attr('hook'); // OPTIONAL
         var submit = moe.find('[submit]'); // REQUIRED
         var cancel = moe.find('[cancel]')[0]; // OPTIONAL
 
@@ -507,6 +508,11 @@ var initMoes = function() {
                         }
                         if (justLog) { // this is to test!
                             console.log('RETURNED', data);
+                        } else if (hook) {
+                            $(cancel).trigger('click.moe');
+                            hideMoeFormMask();
+                            hideMask();
+                            runMCHook(hook);
                         } else if(isDynamicStagPopupPresent()) {
                             refreshDynamicStagPopup();
                         } else if (redir) {
@@ -548,6 +554,11 @@ var initMoes = function() {
                         }
                         if (justLog) { // this is to test!
                             console.log('RETURNED', data);
+                        } else if (hook) {
+                            $(cancel).trigger('click.moe');
+                            hideMoeFormMask();
+                            hideMask();
+                            runMCHook(hook);
                         } else if(isDynamicStagPopupPresent()) {
                             refreshDynamicStagPopup();
                         } else if (redir) {

Энэ ялгаанд хэт олон файл өөрчлөгдсөн тул зарим файлыг харуулаагүй болно