1
0
mirror of https://shylinux.com/x/volcanos synced 2025-04-25 16:58:06 +08:00
This commit is contained in:
shylinux 2021-08-31 15:24:24 +08:00
parent dc242594a7
commit e5c70c0ba8
2 changed files with 3 additions and 1 deletions

View File

@ -279,7 +279,7 @@ Volcanos("onappend", {help: "渲染引擎", list: [], _init: function(can, meta,
},
tree: function(can, list, field, split, cb, target, node) {
node = node || {"": target}; can.core.List(list, function(item) {
item[field] && can.core.List(item[field].split(split), function(value, index, array) {
item[field] && can.core.List(item[field].split(split), function(value, index, array) { if (!value) { return }
var last = array.slice(0, index).join(split), name = array.slice(0, index+1).join(split)
node[name] || (node[name] = can.page.Append(can, node[last], [{view: ["item", html.DIV, value+(index==array.length-1?"":split)], onclick: function(event) {

View File

@ -1,5 +1,7 @@
<!DOCTYPE html>
<head>
<meta name="viewport" content="width=device-width,initial-scale=0.8,user-scalable=no">
<meta charset="utf-8">
<link rel="stylesheet" type="text/css" href="/page/cmd.css">
</head>
<body>