
'),csrf_token=document.querySelector("meta[name=csrf_token]").getAttribute("content"),formData.append("excel_file",file,file.name),formData.append("csrf_token",csrf_token),formData.append("action","file_upload"),$.ajax({url:"",type:"POST",data:formData,processData:!1,contentType:!1,cache:!1,success:function(a,b,c){try{var d="string"==typeof a?JSON.parse(c.responseText):a}catch(a){var d=!1}if(d&&"success"==d.status)return $("#upload_result").html(get_alert(d.message,"success")).fadeIn("slow"),file_content=d.data,$("#upload_file a.goto-next").click(),$("#sheet_config .overlay").fadeOut("slow"),$("#db_config .overlay").fadeOut("slow"),void(null!=d.data&&(d.data.forEach(function(a,b){$("#excel_sheet").append(`
`)}),update_sheet_columns()));var e=d&&d.message?d.message:"فشل رفع الملف برجاء المحاولة مرّة أخرى";$("#upload_result").html(get_alert(e,"error")).fadeIn("slow")},error:function(){$("#upload_result").html(get_alert("فشل رفع الملف برجاء المحاولة مرّة أخرى!","error")).fadeIn("slow")},complete:function(){$("#file_upload").find(".overlay.form-loading").fadeOut("slow")}})}else $("#upload_result").html(get_alert("الملف الذي تحاول رفعه غير مسموح به... برجاء رفع ملفات Excel فقط.","error")).fadeIn("slow")}}function save_data_callback(a,b){try{result="string"==typeof a?JSON.parse(a):a}catch(a){result=!1}if(result&&"success"==result.status){var c=result.message;$("#finish").fadeIn("slow"),$("#db_config a.goto-next").fadeIn("fast").click()}else{console.log(result);var c=result&&result.message?result.message:"فشل حفظ البيانات برجاء المحاولة مرّة أخرى";$("#db_config .alert").remove(),$("#db_config .content").prepend(get_alert(c)),$("#sheet_config a.goto-next").click()}}var allowed_files=["xls","xlsx","xlsm","xlst","csv"],file_content=null;$("body").on("click","#excel_file",function(){this.value=null}),$("body").on("change","#excel_file",upload_file),$("body").on("change","#excel_sheet",update_sheet_columns);
--------------------------------------------------------------------------------
/templates/assets/js/jquery.scrollex.min.js:
--------------------------------------------------------------------------------
1 | /* jquery.scrollex v0.2.1 | (c) @ajlkn | github.com/ajlkn/jquery.scrollex | MIT licensed */
2 | !function(t){function e(t,e,n){return"string"==typeof t&&("%"==t.slice(-1)?t=parseInt(t.substring(0,t.length-1))/100*e:"vh"==t.slice(-2)?t=parseInt(t.substring(0,t.length-2))/100*n:"px"==t.slice(-2)&&(t=parseInt(t.substring(0,t.length-2)))),t}var n=t(window),i=1,o={};n.on("scroll",function(){var e=n.scrollTop();t.map(o,function(t){window.clearTimeout(t.timeoutId),t.timeoutId=window.setTimeout(function(){t.handler(e)},t.options.delay)})}).on("load",function(){n.trigger("scroll")}),jQuery.fn.scrollex=function(l){var s=t(this);if(0==this.length)return s;if(this.length>1){for(var r=0;r
=i&&o>=t};break;case"bottom":h=function(t,e,n,i,o){return n>=i&&o>=n};break;case"middle":h=function(t,e,n,i,o){return e>=i&&o>=e};break;case"top-only":h=function(t,e,n,i,o){return i>=t&&n>=i};break;case"bottom-only":h=function(t,e,n,i,o){return n>=o&&o>=t};break;default:case"default":h=function(t,e,n,i,o){return n>=i&&o>=t}}return c=function(t){var i,o,l,s,r,a,u=this.state,h=!1,c=this.$element.offset();i=n.height(),o=t+i/2,l=t+i,s=this.$element.outerHeight(),r=c.top+e(this.options.top,s,i),a=c.top+s-e(this.options.bottom,s,i),h=this.test(t,o,l,r,a),h!=u&&(this.state=h,h?this.options.enter&&this.options.enter.apply(this.element):this.options.leave&&this.options.leave.apply(this.element)),this.options.scroll&&this.options.scroll.apply(this.element,[(o-r)/(a-r)])},p={id:a,options:u,test:h,handler:c,state:null,element:this,$element:s,timeoutId:null},o[a]=p,s.data("_scrollexId",p.id),p.options.initialize&&p.options.initialize.apply(this),s},jQuery.fn.unscrollex=function(){var e=t(this);if(0==this.length)return e;if(this.length>1){for(var n=0;n1){for(o=0;o
8 |
9 |
16 |
17 |
18 |
19 |
20 |
21 |
31 |
32 | >= $subject_name;?> |
33 |
34 | = $std_data['data']['sub'.$i];?> |
35 |
36 |
37 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
--------------------------------------------------------------------------------
/templates/error.php:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | خطأ!!!
6 | حدث خطأ أثناء محاولتنا لتنفيذ طلبك.
7 | برجاء المحاولة مرّة أخرى
8 |
9 | بيانات الخطأ: = $_temp_vars['error_details'];?>
10 |
11 |
12 |
13 |

14 |
15 |
--------------------------------------------------------------------------------
/templates/footer.php:
--------------------------------------------------------------------------------
1 |
4 |
5 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 | =(isset($_temp_vars['extra_footer']))?$_temp_vars['extra_footer']:'';?>
29 |
39 |
40 |