Skip to content

Commit

Permalink
Rename Set funtion to SetSelected
Browse files Browse the repository at this point in the history
  • Loading branch information
Wayne-KTCSZ committed Jan 16, 2024
1 parent 60f43f8 commit b8f42ed
Show file tree
Hide file tree
Showing 8 changed files with 11 additions and 20 deletions.
2 changes: 1 addition & 1 deletion src/ZKEACMS.Article/Views/Article/Select.cshtml
Expand Up @@ -24,7 +24,7 @@
<script type="text/javascript">
$(function () {
$(document).on("click", ".select", function () {
Set({ value: $(this).data("title"), additional: { ArticleID: $(this).val() } });
SetSelected({ value: $(this).data("title"), additional: { ArticleID: $(this).val() } });
});
});
</script>
Expand Down
2 changes: 1 addition & 1 deletion src/ZKEACMS.Article/Views/ArticleType/Select.cshtml
Expand Up @@ -15,7 +15,7 @@
{
<script type="text/javascript">
function Select(node, selected, e) {
Set(selected.node.a_attr.id);
SetSelected(selected.node.a_attr.id);
}
function loaded() {
@if (ViewBag.Selected != null)
Expand Down
2 changes: 1 addition & 1 deletion src/ZKEACMS.Product/Views/Product/Select.cshtml
Expand Up @@ -24,7 +24,7 @@
<script type="text/javascript">
$(function () {
$(document).on("click", ".select", function () {
Set({ value: $(this).data("title"), additional: { ProductID: $(this).val() } });
SetSelected({ value: $(this).data("title"), additional: { ProductID: $(this).val() } });
});
});
</script>
Expand Down
2 changes: 1 addition & 1 deletion src/ZKEACMS.Product/Views/ProductCategory/Select.cshtml
Expand Up @@ -15,7 +15,7 @@
{
<script type="text/javascript">
function Select(node, selected, e) {
Set(selected.node.a_attr.id);
SetSelected(selected.node.a_attr.id);
}
function loaded() {
@if (ViewBag.Selected != null)
Expand Down
2 changes: 1 addition & 1 deletion src/ZKEACMS.WebHost/Views/Layout/SelectZone.cshtml
Expand Up @@ -45,7 +45,7 @@
$(document).on("click", ".panel", function () {
$(".panel").removeClass("active");
$(this).addClass("active");
Set($(this).data("zoneid"));
SetSelected($(this).data("zoneid"));
});
</script>
}
2 changes: 1 addition & 1 deletion src/ZKEACMS.WebHost/Views/Navigation/Select.cshtml
Expand Up @@ -17,7 +17,7 @@
{
<script type="text/javascript">
function Select(node, selected, e) {
Set(selected.node.a_attr.id);
SetSelected(selected.node.a_attr.id);
}
function loaded() {
@if (ViewBag.Selected != null)
Expand Down
2 changes: 1 addition & 1 deletion src/ZKEACMS.WebHost/Views/Page/Select.cshtml
Expand Up @@ -14,7 +14,7 @@
{
<script type="text/javascript">
function Select(node, selected, e) {
Set(selected.node.a_attr.url);
SetSelected(selected.node.a_attr.url);
}
</script>
}
17 changes: 4 additions & 13 deletions src/ZKEACMS.WebHost/Views/Shared/_PopUpLayout.cshtml
Expand Up @@ -35,26 +35,17 @@
@StyleAtFoot()
@ScriptAtFoot()
<script type="text/javascript">
var selected = "";
var selectedArray = [];
var _innerPopSelectedOptions = null;
$(".popUpToolBar .btn-default").click(function () {
$(window.parent.document).find(".WeiWindow.BoxShadow:last").find(".CloseWindow").click();
});
function Set(obj) {
selected = obj;
}
function SetArray(obj) {
selectedArray = obj;
function SetSelected(obj) {
_innerPopSelectedOptions = obj;
}
function GetSelected() {
return selected;
}
function GetSelectedArray() {
return selectedArray;
return _innerPopSelectedOptions;
}
</script>
</body>
Expand Down

0 comments on commit b8f42ed

Please sign in to comment.