";
246 | groot.pop.showPop($(html), function (element) {
247 | var reader = new FileReader();
248 | reader.onload = putImage2Canvas;
249 | reader.readAsDataURL(file);
250 | function putImage2Canvas(evnt) {
251 | var img = new Image();
252 | var src = evnt.target.result;
253 | img.src = src;
254 | img.onload = function () {
255 | var scale = 1;
256 | var scale0 = 1;
257 | var w = img.width;
258 | var h = img.height;
259 | if ((w / h) > 1) {
260 | if (w > 278) {
261 | scale = 278 / w;
262 | }
263 | } else {
264 | if (h > 278) {
265 | scale = 278 / h;
266 | }
267 | }
268 | w = w * scale;
269 | h = h * scale;
270 | var x = (278 - w) / 2;
271 | var y = (278 - h) / 2;
272 | var _scropw = cropw;
273 | var _scroph = croph;
274 | if ((_scropw / _scroph) > (w / h)) {
275 | _scropw = w;
276 | _scroph = (w / cropw) * croph;
277 | } else {
278 | _scroph = h;
279 | _scropw = (h / croph) * cropw;
280 | }
281 | var k = _scropw;
282 | var x2 = (278 - _scropw) / 2 - 1;
283 | var y2 = (278 - _scroph) / 2 - 1;
284 | var img1 = $(element).find(".img1");
285 | var img2 = $(element).find(".img2");
286 | var img3 = $(element).find(".img3");
287 | img1.width(w).height(h).css("left", x + "px").css("top", y + "px").attr("src", src);
288 | img2.width(_scropw).height(_scroph).css("left", x2 + "px").css("top", y2 + "px");
289 | img2.find("img").width(w).height(h).css("left", (x - x2 - 1) + "px").css("top", (y - y2 - 1) + "px").attr("src", src);
290 | img3.width(_scropw).height(_scroph).css("left", x2 + "px").css("top", y2 + "px");
291 | img3.find("img").width(w).height(h).css("left", (x - x2 - 1) + "px").css("top", (y - y2 - 1) + "px").attr("src", src);
292 | var _x2 = x2;
293 | var _y2 = y2;
294 | img2.bind("mousedown", function (event) {
295 | var mx0 = event.pageX;
296 | var my0 = event.pageY;
297 | img2.bind("mousemove", function (e) {
298 | var mx1 = e.pageX - mx0;
299 | var my1 = e.pageY - my0;
300 | if (mx1 > 0) {
301 | if (mx1 + x2 + _scropw > x + w - 1) {
302 | _x2 = x + w - 1 - _scropw;
303 |
304 | } else {
305 | _x2 = mx1 + x2;
306 | }
307 | } else {
308 | if (mx1 + x2 < x - 1) {
309 | _x2 = x - 1;
310 | } else {
311 | _x2 = mx1 + x2;
312 | }
313 | }
314 | if (my1 > 0) {
315 | if (my1 + y2 + _scroph > y + h - 1) {
316 | _y2 = y + h - 1 - _scroph;
317 |
318 | } else {
319 | _y2 = my1 + y2;
320 | }
321 | } else {
322 | if (my1 + y2 < y - 1) {
323 | _y2 = y - 1;
324 | } else {
325 | _y2 = my1 + y2;
326 | }
327 | }
328 | img2.css("left", _x2 + "px").css("top", _y2 + "px");
329 | img2.find("img").css("left", (x - _x2 - 1) + "px").css("top", (y - _y2 - 1) + "px");
330 | img3.find("img").css("left", (x - _x2 - 1) * scale0 + "px").css("top", (y - _y2 - 1) * scale0 + "px");
331 | });
332 | });
333 | img2.bind("mouseleave", function () {
334 | x2 = _x2;
335 | y2 = _y2;
336 | img2.unbind("mousemove");
337 | });
338 | img2.bind("mouseup", function () {
339 | x2 = _x2;
340 | y2 = _y2;
341 | img2.unbind("mousemove");
342 | });
343 | var _scropw0 = _scropw, _scroph0 = _scroph;
344 | var rightup = $(element).find(".rightup")
345 | rightup.bind("mousedown", function (event) {
346 | event.stopPropagation();
347 | var mx0 = event.pageX;
348 | $(element).bind("mousemove", function (e) {
349 | var mx1 = e.pageX - mx0;
350 | _scropw0 = mx1 + _scropw;
351 | _scroph0 = (mx1 + _scropw) * (_scroph / _scropw);
352 | if (_scropw0 + x2 > x + w - 1) {
353 | _scropw0 = x + w - 1 - x2;
354 | _scroph0 = _scropw0 * (_scroph / _scropw);
355 | }
356 | if (_scroph0 + y2 > y + h - 1) {
357 | _scroph0 = y + h - 1 - y2;
358 | _scropw0 = _scroph0 * (_scropw / _scroph);
359 | }
360 | if (_scropw0 < 50) {
361 | _scropw0 = 50;
362 | _scroph0 = _scropw0 * (_scroph / _scropw);
363 | }
364 | img2.width(_scropw0).height(_scroph0);
365 | scale0 = k / _scropw0;
366 | var imgtemp = img2.find("img");
367 | img3.find("img").width(imgtemp.width() * scale0).height(imgtemp.height() * scale0);
368 | var t = imgtemp.css("top").replace("px", "") * scale0;
369 | var l = imgtemp.css("left").replace("px", "") * scale0;
370 | img3.find("img").css("left", l + "px").css("top", t + "px");
371 | });
372 | });
373 | $(element).bind("mouseup", function () {
374 | _scropw = _scropw0;
375 | _scroph = _scroph0;
376 | $(element).unbind("mousemove");
377 | });
378 | $(element).find(".ok").bind("click", function () {
379 | //scale
380 | var x = -img2.find("img").css("left").replace("px", "") / scale;
381 | var y = -img2.find("img").css("top").replace("px", "") / scale;
382 | var w = img2.width() / scale;
383 | var h = img2.height() / scale;
384 | var canvas = $('
')[0],
385 | ctx = canvas.getContext('2d');
386 |
387 | ctx.drawImage(img, x, y, w, h, 0, 0, cropw, croph);
388 | var data = canvas.toDataURL().split(',')[1];
389 | $.ajax({
390 | "url": url,
391 | "type": "post",
392 | "data": {"base64Code": data},
393 | timeout: 10000,
394 | dataType: "json",
395 | beforeSend: function () {
396 | $(element).append("
");
397 | $(element).append("
图片上传中..
")
398 | },
399 | success: function (u) {
400 | imcrop.closePop();
401 | if (typeof callback == "function") {
402 | callback(u);
403 | }
404 | },
405 | error: function (xhr, status, err) {
406 | $(element).find(".ptext").html("图片上传失败");
407 | $(element).find(".ptext").css("color", "red")
408 | setTimeout(function () {
409 | $(element).find(".ptext").remove();
410 | $(element).find(".post").remove();
411 | }, 1500)
412 | }
413 | })
414 | });
415 | $(element).find(".cancel").bind("click", function () {
416 | groot.pop.closePop();
417 | });
418 | }
419 | }
420 |
421 | $(element).find(".close").on("click", function () {
422 | groot.pop.closePop();
423 | });
424 | }, false)
425 | }
426 | var popid = (function () {
427 | var url = location.search; //获取url中"?"符后的字串
428 | var theRequest = new Object();
429 | if (url.indexOf("?") != -1) {
430 | var str = url.substr(1);
431 | var strs = str.split("&");
432 | for (var i = 0; i < strs.length; i++) {
433 | theRequest[strs[i].split("=")[0]] = decodeURIComponent(strs[i].split("=")[1]);
434 | }
435 | }
436 | return theRequest["popid"];
437 | })()
438 | groot.msg = {};
439 | groot.msg.send = function (result) {
440 | try {
441 | if (window.parent !== window) {
442 | window.parent[popid].callback(result);
443 | } else {
444 | window[popid].callback(result);
445 | }
446 | } catch (e) {
447 | console.log("不是弹窗打开")
448 | }
449 | }
450 | groot.msg.close = function () {
451 | try {
452 | if (window.parent !== window) {
453 | delete window.parent[popid];
454 | window.parent.groot.pop.closePop();
455 | } else {
456 | delete window[popid];
457 | window.groot.pop.closePop();
458 | }
459 | } catch (e) {
460 | console.log("不是弹窗打开")
461 | }
462 | }
463 | groot.msg.render = function () {
464 | try {
465 | if (window.parent !== window) {
466 | window.parent[popid].render();
467 | } else {
468 | window[popid].render();
469 | }
470 | } catch (e) {
471 | console.log("不是弹窗打开")
472 | }
473 | }
474 | groot.msg.show = function () {
475 | try {
476 | if (window.parent !== window) {
477 | window.parent[popid].show();
478 | } else {
479 | window[popid].show();
480 | }
481 | } catch (e) {
482 | console.log("不是弹窗打开")
483 | }
484 | }
485 | groot.page = function (title, url, rev) {
486 | var html = "";
487 | var mid = new Date() - 1;
488 | html += "
";
489 | html += "
";
490 | html += "" + title + "";
491 | html += "
";
492 | html += "
";
493 | if (url.indexOf("?") > -1) {
494 | url = url + "&popid=" + mid;
495 | } else {
496 | url = url + "?popid=" + mid;
497 | }
498 | html += "";
499 | html += "
";
500 | html += "
";
501 | var draw;
502 | if (window.parent !== window) {
503 | window.parent[mid] = {};
504 | if (rev !== undefined && typeof rev === "function") {
505 | window.parent[mid].callback = function (result) {
506 | rev(result);
507 | }
508 | }
509 | window.parent[mid].render = function () {
510 | drawRender();
511 | }
512 | } else {
513 | window[mid] = {};
514 | if (rev !== undefined && typeof rev === "function") {
515 | window[mid].callback = function (result) {
516 | rev(result);
517 | }
518 | }
519 | window[mid].render = function (callback) {
520 | drawRender(callback);
521 | }
522 | }
523 | function drawRender(show) {
524 | if (draw !== undefined) {
525 | var wScreen = $(window).width() - 20;
526 | var hScreen = $(window).height() - 100;
527 | var inframeW = draw.contentDocument.body.scrollWidth + 20;
528 | var iframeH = draw.contentDocument.body.scrollHeight;
529 | if (inframeW > wScreen)inframeW = wScreen;
530 | if (iframeH > hScreen)iframeH = hScreen;
531 | $(draw).width(inframeW);
532 | $(draw).height(iframeH);
533 | //$(draw).parents(".open").height(iframeH);
534 | var pops = $(".pop-container");
535 | if (pops.length > 0) {
536 | pops.each(function () {
537 | var pop = $(this);
538 | var w = pop.width();
539 | var h = pop.height();
540 | var wScreen = $(window).width();
541 | var hScreen = $(window).height();
542 | var x = (wScreen - w) / 2;
543 | var y = (hScreen - h) / 2;
544 | pop.css("left", x + "px");
545 | pop.css("top", y + "px");
546 | });
547 | }
548 | if (show && typeof show === "function") {
549 | show();
550 | }
551 | } else {
552 | setTimeout(function () {
553 | drawRender();
554 | }, 10)
555 | }
556 | }
557 |
558 | groot.pop.showPop($(html), function (element, callback) {
559 | if (window[mid] !== undefined || window.parent[mid] !== undefined) {
560 | $(element).parent().attr("popmid", mid);
561 | }
562 | if (window.parent !== window) {
563 | window.parent[mid].show = function () {
564 | callback();
565 | }
566 | } else {
567 | window[mid].show = function () {
568 | callback();
569 | }
570 | }
571 | $(element).find("iframe").on("load", function () {
572 | draw = this;
573 | $(this.contentDocument.body).find(".element-remove").remove();
574 | })
575 | $(element).find(".close").click(groot.pop.closePop);
576 | return "wait"
577 | }, false);
578 | }
579 | })();
580 | /*日历组件*/
581 | (function () {
582 | groot.widget["calendar"] = function (element, id, data, value, upParent) {
583 | var _html = ["
",
584 | " ",
585 | " ",
586 | "
",
587 | "
",
588 | "
",
589 | " ",
590 | " ",
591 | " ",
592 | "
",
593 | "
",
594 | " 日",
595 | " 一",
596 | " 二",
597 | " 三",
598 | " 四",
599 | " 五",
600 | " 六",
601 | "
",
602 | "
",
603 | " ",
604 | "
",
605 | "
",
606 | " 时间:",
607 | " ",
633 | " :",
634 | " ",
695 | "
",
696 | "
",
697 | " 确定",
698 | " 今天",
699 | " 取消",
700 | "
",
701 | "
"].join("");
702 |
703 | var timer = false;
704 | if (data !== null) {
705 | timer = data.timer;
706 | }
707 | groot.createElement(_html, id, element);
708 |
709 | var hh = $(element).find(".hh");
710 | var mm = $(element).find(".mm");
711 | var days = $(element).find(".days");
712 | var dialog = $(element).find(".dialog");
713 | var month = $(element).find(".mouth");
714 | var timershow = $(element).find(".timer");
715 | if (timer) {
716 | timershow.show();
717 | } else {
718 | timershow.hide();
719 | }
720 | $(element).find("input").attr("placeholder", data.title);
721 | var calendar = {
722 | curDate: value === "" ? new Date() : new Date(Date.parse(value)),//当前的date对象
723 | secDate: value === "" ? new Date() : new Date(Date.parse(value)),//当前的date对象
724 | // 增加月 可以是负数
725 | addMouth: function (n) {
726 | this.curDate.setMonth((this.curDate.getMonth() + n));
727 | },
728 | //获取当前月是星期几
729 | getWeek: function () {
730 | return new Date(this.curDate.getFullYear(), this.curDate.getMonth(), 1).getDay();
731 | },
732 | //获取当前月最大天数
733 | getMaxDays: function () {
734 | return new Date(this.curDate.getFullYear(), this.curDate.getMonth() + 1, 0).getDate();
735 | },
736 | render: function () {
737 | var week = this.getWeek();
738 | var maxDay = this.getMaxDays();
739 | var start = week === 0 ? 7 : week;
740 | var end = start + maxDay;
741 | var _html = "";
742 | for (var i = 0; i < 42; i++) {
743 | var myd = new Date(this.curDate.getFullYear(), this.curDate.getMonth(), (i - start + 1));
744 | var day = myd.getDate();
745 | if (i >= start && i < end) {
746 | if (day === this.secDate.getDate() && myd.getFullYear() === this.secDate.getFullYear() && myd.getMonth() === this.secDate.getMonth()) {
747 | _html += "
" + day + "";
748 | } else {
749 | _html += "
" + day + "";
750 | }
751 | } else {
752 | _html += "
" + day + "";
753 | }
754 | }
755 | days.html(_html);
756 | month.html(this.curDate.getFullYear() + "年" + (this.curDate.getMonth() + 1) + "月");
757 | }
758 | }
759 | var moudle = groot.view(id, function (vm, ve) {
760 | var date;
761 | if (value === "") {
762 | vm.widgetvalue = "";
763 | date = new Date();
764 | } else {
765 | date = new Date(Date.parse(value));
766 | if (timer) {
767 | vm.widgetvalue = date.getFullYear() + "-" + (date.getMonth() + 1) + "-" + date.getDate() + " " + vm.hh + ":" + vm.mm;
768 | } else {
769 | vm.widgetvalue = date.getFullYear() + "-" + (date.getMonth() + 1) + "-" + date.getDate();
770 | }
771 | }
772 | ;
773 | hh.val(date.getHours() >= 10 ? date.getHours() + "" : "0" + date.getHours());
774 | mm.val(date.getMinutes() >= 10 ? date.getMinutes() + "" : "0" + date.getMinutes());
775 | calendar.curDate = new Date(date.getTime());//当前的date对象
776 | calendar.secDate = new Date(date.getTime());//当前的date对象
777 |
778 | });
779 |
780 | function dclick(e) {
781 | dialog.fadeOut("fast");
782 | $(document).off("click", dclick);
783 | }
784 |
785 | $(element).find(".input-group").on("click", function (e) {
786 | e.stopPropagation();
787 | if (dialog.is(":hidden")) {
788 | var date;
789 | if (moudle.widgetvalue === "") {
790 | date = new Date();
791 | } else {
792 | date = new Date(Date.parse(moudle.widgetvalue));
793 | }
794 | calendar.curDate = new Date(date.getTime());//当前的date对象
795 | calendar.secDate = new Date(date.getTime());//当前的date对象
796 | hh.val(date.getHours() >= 10 ? date.getHours() + "" : "0" + date.getHours());
797 | mm.val(date.getMinutes() >= 10 ? date.getMinutes() + "" : "0" + date.getMinutes());
798 | calendar.render();
799 | dialog.fadeIn("fast");
800 | } else {
801 | dialog.fadeOut("fast");
802 | }
803 | $(document).on("click", dclick);
804 | });
805 |
806 | $(element).find(".icon-arrow-left").on("click", function (e) {
807 | e.stopPropagation();
808 | calendar.addMouth(-1);
809 | calendar.render();
810 | });
811 | $(element).find(".icon-arrow-right").on("click", function (e) {
812 | e.stopPropagation();
813 | calendar.addMouth(1);
814 | calendar.render();
815 | });
816 | $(element).find(".days").on("click", "span", function (e) {
817 | e.stopPropagation();
818 | var d = new Date($(this).attr("data-value") * 1);
819 | calendar.secDate = d;
820 | days.find("span").removeClass("active")
821 | $(this).addClass("active");
822 | });
823 | $(element).find(".submit").on("click", function (e) {
824 | e.stopPropagation();
825 | if (timer) {
826 | moudle.widgetvalue = calendar.secDate.getFullYear() + "-" + (calendar.secDate.getMonth() + 1) + "-" + calendar.secDate.getDate() + " " + hh.val() + ":" + mm.val();
827 | } else {
828 | moudle.widgetvalue = calendar.secDate.getFullYear() + "-" + (calendar.secDate.getMonth() + 1) + "-" + calendar.secDate.getDate();
829 | }
830 | moudle.widgetvalueRender();
831 | upParent();
832 | dialog.fadeOut();
833 | });
834 | $(element).find(".today").on("click", function (e) {
835 | e.stopPropagation();
836 | var d = new Date();
837 | moudle.widgetvalue = d.getFullYear() + "-" + (d.getMonth() + 1) + "-" + d.getDate();
838 | if (timer) {
839 | moudle.widgetvalue = d.getFullYear() + "-" + (d.getMonth() + 1) + "-" + d.getDate() + " " + hh.val() + ":" + mm.val();
840 | } else {
841 | moudle.widgetvalue = d.getFullYear() + "-" + (d.getMonth() + 1) + "-" + d.getDate();
842 | }
843 | moudle.widgetvalueRender();
844 | upParent();
845 | dialog.fadeOut("fast");
846 | });
847 | $(element).find(".cancel").on("click", function (e) {
848 | e.stopPropagation();
849 | dialog.fadeOut("fast")
850 |
851 | });
852 | $(element).find(".dialog").on("click", function (e) {
853 | e.stopPropagation();
854 |
855 | })
856 | }
857 | })()
858 | ;
859 | /*分页组件*/
860 | (function () {
861 | groot.paging = function (element, callback) {
862 | var _html = [""].join("");
864 | $(element).html(_html);
865 | return function (curPage, totalPage) {
866 | var list = getPages(curPage, totalPage);
867 | var page = [];
868 | if (curPage === 1) {
869 | page.push("
");
870 | } else {
871 | page.push("");
872 | }
873 | page.push("«");
874 | page.push("");
875 | for (var i = 0; i < list.length; i++) {
876 | if (list[i] === "..") {
877 | page.push("
");
878 | } else if (list[i] === curPage) {
879 | page.push("");
880 | } else {
881 | page.push("");
882 | }
883 | page.push("" + list[i] + "");
884 | page.push("");
885 | }
886 | if (curPage == totalPage) {
887 | page.push("
");
888 | } else {
889 | page.push("");
890 | }
891 | page.push("»");
892 | page.push("");
893 | $(element).find("ul").html(page.join(""));
894 | $(element).find("li[page]").on("click", function () {
895 | callback($(this).attr("page") * 1);
896 | })
897 | }
898 | }
899 | function getPages(p, totalPages) {
900 | var list = [];
901 | for (var i = 1; i < totalPages + 1; i++) {
902 | list.push(i)
903 | }
904 | if (totalPages - p > 4) {
905 | list = list.splice(0, p + 4);
906 | list.push("..");
907 | }
908 | if (p > 5) {
909 | list.splice(0, p - 5);
910 | list.unshift("..");
911 | }
912 | return list;
913 | }
914 | })()
915 | ;
916 | (function () {
917 | function isTel(str) {
918 | var reg = /^([0-9]|[\-])+$/g;
919 | if (str.length18) {
920 | return false;
921 | }
922 | else {
923 | return reg.exec(str);
924 | }
925 | }
926 |
927 | function isEmail(str) {
928 | var reg = /^([a-zA-Z0-9_-])+@([a-zA-Z0-9_-])+((\.[a-zA-Z0-9_-]{2,3}){1,2})$/;
929 | return reg.test(str);
930 | }
931 |
932 | function isMobile(mobile) {
933 | if (mobile.length == 0) {
934 | return false;
935 | }
936 | if (mobile.length != 11) {
937 | return false;
938 | }
939 |
940 | var myreg = /^(1\d{10})$/;
941 | if (!myreg.test(mobile)) {
942 | return false;
943 | }
944 | }
945 |
946 | function isIdCardNo(num) {
947 | num = num.toUpperCase();
948 | //身份证号码为15位或者18位,15位时全为数字,18位前17位为数字,最后一位是校验位,可能为数字或字符X。
949 | if (!(/(^\d{15}$)|(^\d{17}([0-9]|X)$)/.test(num))) {
950 | return false;
951 | } else {
952 | return false;
953 | }
954 | }
955 |
956 | groot.validation = {
957 | isTel: isTel,
958 | isEmail: isEmail,
959 | isMobile: isMobile,
960 | isIdCardNo: isIdCardNo,
961 | validate: function (element) {
962 | function v(doc) {
963 | var _name = $(doc).addClass("error").attr("validate-name");
964 | $("[error-name='" + _name + "']").show();
965 | }
966 |
967 | function vr(doc) {
968 | var _name = $(doc).removeClass("error").attr("validate-name");
969 | $("[error-name='" + _name + "']").hide();
970 | }
971 |
972 | $(element).find("input,textarea").on("input propertychange", function () {
973 | if ($(this).attr("validate") != undefined) {
974 | var _v = $.parseJSON($(this).attr("validate"));
975 | var _exp = _v.exp;
976 | if (_exp === "tel") {
977 | if (!isTel($(this).val())) {
978 | if ($.trim($(this).val()) !== "") {
979 | v(this);
980 | } else {
981 |
982 | }
983 | }
984 | } else if (_exp === "email") {
985 | if (!isEmail($(this).val())) {
986 | if ($.trim($(this).val()) !== "") {
987 | v(this);
988 | } else {
989 |
990 | }
991 | }
992 | } else if (_exp === "mobile") {
993 | if (!isMobile($(this).val())) {
994 | if ($.trim($(this).val()) !== "") {
995 | v(this, _tip);
996 | } else {
997 |
998 | }
999 | }
1000 | }
1001 | else if (_exp === "card") {
1002 | if (!isIdCardNo($(this).val())) {
1003 | if ($.trim($(this).val()) !== "") {
1004 | v(this);
1005 | } else {
1006 |
1007 | }
1008 | }
1009 | }
1010 | }
1011 | })
1012 | return function () {
1013 | var ele;
1014 |
1015 | function v(doc) {
1016 | var _name = $(doc).addClass("error").attr("validate-name");
1017 | $("[error-name='" + _name + "']").show();
1018 | }
1019 |
1020 | $(element).find("input,textarea").each(function () {
1021 | if (ele != null) {
1022 | if ($(this).attr("validate") != undefined) {
1023 | var _v = $.parseJSON($(this).attr("validate"));
1024 | var _exp = _v.exp;
1025 | var _emp = _v.empt;
1026 | if (_exp === "tel") {
1027 | if (!isTel($(this).val())) {
1028 | if (!($.trim($(this).val()) === "" && _emp === false)) {
1029 | ele = this;
1030 | v(this);
1031 | }
1032 | }
1033 | } else if (_exp === "email") {
1034 | if (!isEmail($(this).val())) {
1035 | if (!($.trim($(this).val()) === "" && _emp === false)) {
1036 | ele = this;
1037 | v(this);
1038 | }
1039 | }
1040 | } else if (_exp === "mobile") {
1041 | if (!isMobile($(this).val())) {
1042 | if (!($.trim($(this).val()) === "" && _emp === false)) {
1043 | ele = this;
1044 | v(this);
1045 | }
1046 | }
1047 | }
1048 | else if (_exp === "card") {
1049 | if (!isIdCardNo($(this).val())) {
1050 | if (!($.trim($(this).val()) === "" && _emp === false)) {
1051 | ele = this;
1052 | v(this);
1053 | }
1054 | }
1055 | }
1056 | }
1057 | }
1058 | })
1059 | if (ele !== null) {
1060 | return false;
1061 | } else {
1062 | return true;
1063 | }
1064 | }
1065 | }
1066 | }
1067 | })
1068 | ()
--------------------------------------------------------------------------------