Toggle navigation
Toggle navigation
This project
Loading...
Sign in
fe
/
yohobuy-portal-fe
·
Commits
Go to a project
GitLab
Go to group
Project
Activity
Files
Commits
Pipelines
0
Builds
0
Graphs
Milestones
Issues
0
Merge Requests
0
Members
Labels
Wiki
Forks
Network
Create a new issue
Download as
Email Patches
Plain Diff
Browse Files
Authored by
陶雨
9 years ago
Commit
32166c75814ea1e6a2728dd4ccbdcc97fd043074
1 parent
b83d3b28
解决分类管理编辑页跳转链接没有渲染的问题
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
4 deletions
client/js/operations/categoryManageAdd.js
server/views/pages/operations/categoryManageAdd.html
client/js/operations/categoryManageAdd.js
View file @
32166c7
...
...
@@ -75,7 +75,12 @@ $(document).on("change", ".observe", function() {
});
$
(
document
).
on
(
"click"
,
"#addUrl"
,
function
()
{
common
.
dialog
.
confirm
(
"添加链接"
,
common
.
util
.
__template2
(
$
(
"#template2"
).
html
(),
{}),
function
()
{
var
urlIndex
=
'","url":"'
;
var
val
=
$
(
"#sortUrl"
).
val
();
var
action
=
val
.
substring
(
'{"action":"'
.
length
,
val
.
indexOf
(
urlIndex
));
console
.
log
(
action
);
var
url
=
val
.
substring
(
val
.
indexOf
(
urlIndex
)
+
urlIndex
.
length
,
val
.
length
-
2
);
common
.
dialog
.
confirm
(
"添加链接"
,
common
.
util
.
__template2
(
$
(
"#template2"
).
html
(),
{
action
:
action
,
url
:
url
}),
function
()
{
var
url
=
JSON
.
stringify
({
action
:
$
(
"#goTo"
).
val
(),
url
:
$
(
"#goToUrl"
).
val
()
...
...
@@ -83,6 +88,7 @@ $(document).on("click", "#addUrl", function () {
$
(
"#sortUrl"
).
val
(
url
);
Category
.
sortUrl
=
url
;
});
new
common
.
edit2
(
"#action-row"
).
init
();
});
$
(
document
).
on
(
"click"
,
"#saveBtn"
,
function
()
{
...
...
server/views/pages/operations/categoryManageAdd.html
View file @
32166c7
...
...
@@ -156,12 +156,12 @@
</script>
<script
type=
"text/template"
id=
"template2"
>
<
div
class
=
"rows"
>
<
div
id
=
"action-row"
class
=
"rows"
>
<
div
class
=
"form-group"
>
<
label
class
=
"col-sm-2 control-label"
>
选择跳转目的地:
<
/label
>
<
div
class
=
"col-sm-8"
>
<
select
name
=
"goTo"
id
=
"goTo"
class
=
"form-control"
>
<
select
name
=
"goTo"
id
=
"goTo"
class
=
"form-control"
value
=
"[[action]]"
>
[[
layout
action_template
]]
<
/select
>
...
...
@@ -172,7 +172,7 @@
<
label
class
=
"col-sm-2 control-label"
>
跳转地址:
<
/label
>
<
div
class
=
"col-sm-8"
>
<
textarea
rows
=
"2"
id
=
"goToUrl"
class
=
"form-control"
placeholder
=
"跳转地址"
><
/textarea
>
<
textarea
rows
=
"2"
id
=
"goToUrl"
class
=
"form-control"
placeholder
=
"跳转地址"
>
[[
url
]]
<
/textarea
>
<
/div
>
<
/div
>
...
...
Please
register
or
login
to post a comment