From 0b15f032dcd39c269668f57006f6d399d4d0e999 Mon Sep 17 00:00:00 2001 From: username@email.com <yzy2002yzy@163.com> Date: 星期三, 25 十二月 2024 08:42:46 +0800 Subject: [PATCH] 修改页面按钮权限的验证 --- CY_ECommercePlatform/CY.WebForm/Pages/common/CMSHead.ascx | 54 +++++++++++++++++++++++++++++++----------------------- 1 files changed, 31 insertions(+), 23 deletions(-) diff --git a/CY_ECommercePlatform/CY.WebForm/Pages/common/CMSHead.ascx b/CY_ECommercePlatform/CY.WebForm/Pages/common/CMSHead.ascx index 32bb9cd..90f7940 100644 --- a/CY_ECommercePlatform/CY.WebForm/Pages/common/CMSHead.ascx +++ b/CY_ECommercePlatform/CY.WebForm/Pages/common/CMSHead.ascx @@ -128,9 +128,16 @@ <!--begin--> <script type="text/javascript"> $(function () { + + var url = window.location.href; + var j = ""; + if (url.indexOf('?') >= 0) { + j = url.substring(url.indexOf('?')); + } + var tempPathName = window.location.pathname; var tempContext = tempPathName.substring(1, tempPathName.length); - var TruePath = tempContext.replace("Pages/", "../"); + var TruePath = tempContext.replace("Pages/", "../") + j; $.ajax({ url: "/Pages/common/CommonAjax.aspx", type: "POST", @@ -154,27 +161,28 @@ }); </script> <script type="text/javascript"> - $(function () { - // menu_member_case_id="case_" menu_member_case_name="" - var tempPathName = window.location.pathname; - var tempContext = tempPathName.substring(1, tempPathName.length); - var TruePath = tempContext.replace("Pages/", "../").replace("pages/", "../"); - var attrs = ""; - var texts = ""; - $("*[menu_member_case_id^='case_']").each(function (ii, vv) { - attrs += ("," + $(vv).attr("menu_member_case_id")); - texts += ("," + $(vv).attr("menu_member_case_name")); - }); - $.ajax({ - url: "/Pages/common/CommonAjax.aspx", - type: "POST", - dataType: "html", - data: { dateType: "creat_menu_case", menupath: TruePath, attrs: attrs, texts: texts }, - global: false, - cache: false, - success: function (data) { + //$(function () { + // // menu_member_case_id="case_" menu_member_case_name="" + + // var tempPathName = window.location.pathname; + // var tempContext = tempPathName.substring(1, tempPathName.length); + // var TruePath = tempContext.replace("Pages/", "../").replace("pages/", "../"); + // var attrs = ""; + // var texts = ""; + // $("*[menu_member_case_id^='case_']").each(function (ii, vv) { + // attrs += ("," + $(vv).attr("menu_member_case_id")); + // texts += ("," + $(vv).attr("menu_member_case_name")); + // }); + // $.ajax({ + // url: "/Pages/common/CommonAjax.aspx", + // type: "POST", + // dataType: "html", + // data: { dateType: "creat_menu_case", menupath: TruePath, attrs: attrs, texts: texts }, + // global: false, + // cache: false, + // success: function (data) { - } - }); - }); + // } + // }); + //}); </script> -- Gitblit v1.9.1