diff --git a/src/base/single/input/file.js b/src/base/single/input/file.js index e9b1a5a2a..50ec58bdc 100644 --- a/src/base/single/input/file.js +++ b/src/base/single/input/file.js @@ -333,11 +333,10 @@ if (isFunction(handler.onloadstart)) { handler.onloadstart(rpe, {}); } - with (document.body || document.documentElement) { - appendChild(iframe); - appendChild(form); - form.submit(); - } + var d = document.body || document.documentElement; + d.appendChild(iframe); + d.appendChild(form); + form.submit(); return handler; }; @@ -652,7 +651,7 @@ }); }, - setMaxFileLength: function(v) { + setMaxFileLength: function (v) { this.options.maxLength = v; if (this.wrap) { this.wrap.maxLength = v; diff --git a/src/core/func/function.js b/src/core/func/function.js index 05c8fe78a..2d3f9a3e8 100644 --- a/src/core/func/function.js +++ b/src/core/func/function.js @@ -40,16 +40,14 @@ _.extend(BI.Func, { * @param items * @param keyword * @param param 搜索哪个属性 - * @param clone 是否需要deepClone */ - getSearchResult: function (items, keyword, param, clone) { + getSearchResult: function (items, keyword, param) { var isArray = BI.isArray(items); items = isArray ? BI.flatten(items) : items; param || (param = "text"); - BI.isNull(clone) && (clone = true); if (!BI.isKey(keyword)) { return { - find: clone ? BI.deepClone(items) : items, + find: items, match: isArray ? [] : {} }; } @@ -61,7 +59,6 @@ _.extend(BI.Func, { if (BI.isNull(item)) { return; } - clone && (item = BI.deepClone(item)); t = BI.stripEL(item); text = BI.find([t[param], t.text, t.value, t.name, t], function (index, val) { return BI.isNotNull(val); diff --git a/typescript/base/combination/combo.ts b/typescript/base/combination/combo.ts index bec2a7b75..249e7e6f2 100644 --- a/typescript/base/combination/combo.ts +++ b/typescript/base/combination/combo.ts @@ -34,6 +34,7 @@ export declare class Combo extends Widget { adjustYOffset?: number; hideChecker?: Function; offsetStyle?: 'left' | 'right' | 'center'; + value?:any; el?: any; popup?: any; comboClass?: string; diff --git a/typescript/core/utils/tree.ts b/typescript/core/utils/tree.ts index c300ad100..643d99cd0 100644 --- a/typescript/core/utils/tree.ts +++ b/typescript/core/utils/tree.ts @@ -43,8 +43,8 @@ export declare class Tree { postOrderTraverse(callback: Function): void; nrPostOrderTraverse(callback: Function): void; static transformToArrayFormat(nodes: T | T[], pId: any, childKey?: string): T[]; - static arrayFormat(nodes: Node | Node[], pId: any): Node[]; - static transformToTreeFormat(sNodes: T[]): Node[]; - static treeFormat(sNodes: Node | Node[]): Node[]; - static traversal(array: Node[], callback: Function, pNode: Node): void; + static arrayFormat(nodes: T | T[], pId: any): T[]; + static transformToTreeFormat(sNodes: T[]): T[]; + static treeFormat(sNodes: T | T[]): T[]; + static traversal(array: T[], callback: (index:number,node:T,pNode?:T)=> boolean | void, pNode?: T): void; } diff --git a/typescript/core/wrapper/layout/sticky/sticky.horizontal.ts b/typescript/core/wrapper/layout/sticky/sticky.horizontal.ts new file mode 100644 index 000000000..900be7c45 --- /dev/null +++ b/typescript/core/wrapper/layout/sticky/sticky.horizontal.ts @@ -0,0 +1,5 @@ +import { Layout } from "../../layout"; + +export declare class HorizontalStickyLayout extends Layout { + static xtype: string; +} diff --git a/typescript/core/wrapper/layout/sticky/sticky.vertical.ts b/typescript/core/wrapper/layout/sticky/sticky.vertical.ts new file mode 100644 index 000000000..f5a07b44e --- /dev/null +++ b/typescript/core/wrapper/layout/sticky/sticky.vertical.ts @@ -0,0 +1,5 @@ +import { Layout } from "../../layout"; + +export declare class VerticalStickyLayout extends Layout { + static xtype: string; +} diff --git a/typescript/index.ts b/typescript/index.ts index 619ab72ce..fa18bc8da 100644 --- a/typescript/index.ts +++ b/typescript/index.ts @@ -181,6 +181,8 @@ import { TdLayout } from './core/wrapper/layout/layout.td'; import { MultiLayerSelectLevelTree } from './widget/multilayerselecttree/multilayerselecttree.leveltree'; import { SelectTreeExpander } from './widget/selecttree/selecttree.expander'; import { DownListGroupItem } from "./widget/downlist/item.downlistgroup"; +import { VerticalStickyLayout } from "./core/wrapper/layout/sticky/sticky.vertical"; +import { HorizontalStickyLayout } from "./core/wrapper/layout/sticky/sticky.horizontal"; import './shims-tsx'; @@ -370,6 +372,8 @@ export interface BI extends _func, _i18n, _base, _inject, _var, _web, _utils { MultiLayerSelectLevelTree: typeof MultiLayerSelectLevelTree; SelectTreeExpander: typeof SelectTreeExpander; DownListGroupItem: typeof DownListGroupItem; + VerticalStickyLayout: typeof VerticalStickyLayout; + HorizontalStickyLayout: typeof HorizontalStickyLayout; } export default { @@ -558,4 +562,6 @@ export { SelectTreeExpander, DirectionPager, DownListGroupItem, + HorizontalStickyLayout, + VerticalStickyLayout, };