|
|
@ -1,55 +1,4 @@ |
|
|
|
if (!window.BI) { |
|
|
|
/*! |
|
|
|
window.BI = {}; |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
BI.servletURL = "https://fanruan.coding.me/fineui/dist/"; |
|
|
|
|
|
|
|
BI.resourceURL = "https://fanruan.coding.me/fineui/dist/resource/"; |
|
|
|
|
|
|
|
BI.i18n = { |
|
|
|
|
|
|
|
"BI-Basic_OK": "确定", |
|
|
|
|
|
|
|
"BI-Basic_Sure": "确定", |
|
|
|
|
|
|
|
"BI-Basic_Clears": "清空", |
|
|
|
|
|
|
|
"BI-Basic_Cancel": "取消", |
|
|
|
|
|
|
|
"BI-Basic_Time": "时间", |
|
|
|
|
|
|
|
"BI-Basic_Simple_Sunday": "日", |
|
|
|
|
|
|
|
"BI-Basic_Simple_Monday": "一", |
|
|
|
|
|
|
|
"BI-Basic_Simple_Tuesday": "二", |
|
|
|
|
|
|
|
"BI-Basic_Simple_Wednesday": "三", |
|
|
|
|
|
|
|
"BI-Basic_Simple_Thursday": "四", |
|
|
|
|
|
|
|
"BI-Basic_Simple_Friday": "五", |
|
|
|
|
|
|
|
"BI-Basic_Simple_Saturday": "六", |
|
|
|
|
|
|
|
"BI-Multi_Date_Year": "年", |
|
|
|
|
|
|
|
"BI-Multi_Date_Month": "月", |
|
|
|
|
|
|
|
"BI-Multi_Date_Quarter": "季度", |
|
|
|
|
|
|
|
"BI-Basic_Unrestricted": "无限制", |
|
|
|
|
|
|
|
"BI-Quarter_1": "第1季度", |
|
|
|
|
|
|
|
"BI-Quarter_2": "第2季度", |
|
|
|
|
|
|
|
"BI-Quarter_3": "第3季度", |
|
|
|
|
|
|
|
"BI-Quarter_4": "第4季度", |
|
|
|
|
|
|
|
"BI-Basic_Value": "值", |
|
|
|
|
|
|
|
"BI-Load_More": "加载更多", |
|
|
|
|
|
|
|
"BI-Select_All": "全选", |
|
|
|
|
|
|
|
"BI-Basic_Auto": "自动", |
|
|
|
|
|
|
|
"BI-No_More_Data": "无更多数据", |
|
|
|
|
|
|
|
"BI-No_Selected_Value": "没有可选项", |
|
|
|
|
|
|
|
"BI-Basic_Clear": "清除", |
|
|
|
|
|
|
|
"BI-Multi_Date_Relative_Current_Time": "相对当前时间", |
|
|
|
|
|
|
|
"BI-Multi_Date_Year_Prev": "年前", |
|
|
|
|
|
|
|
"BI-Multi_Date_Year_Next": "年后", |
|
|
|
|
|
|
|
"BI-Multi_Date_Year_Begin": "年初", |
|
|
|
|
|
|
|
"BI-Multi_Date_Year_End": "年末", |
|
|
|
|
|
|
|
"BI-Multi_Date_Quarter_Prev": "个季度前", |
|
|
|
|
|
|
|
"BI-Multi_Date_Quarter_Next": "个季度后", |
|
|
|
|
|
|
|
"BI-Multi_Date_Quarter_Begin": "季度初", |
|
|
|
|
|
|
|
"BI-Multi_Date_Quarter_End": "季度末", |
|
|
|
|
|
|
|
"BI-Multi_Date_Month_Prev": "个月前", |
|
|
|
|
|
|
|
"BI-Multi_Date_Month_Next": "个月后", |
|
|
|
|
|
|
|
"BI-Multi_Date_Month_Begin": "月初", |
|
|
|
|
|
|
|
"BI-Multi_Date_Month_End": "月末", |
|
|
|
|
|
|
|
"BI-Multi_Date_Week_Prev": "周前", |
|
|
|
|
|
|
|
"BI-Multi_Date_Week_Next": "周后", |
|
|
|
|
|
|
|
"BI-Multi_Date_Day_Prev": "天前", |
|
|
|
|
|
|
|
"BI-Multi_Date_Day_Next": "天后", |
|
|
|
|
|
|
|
"BI-Multi_Date_Today": "今天" |
|
|
|
|
|
|
|
};/*! |
|
|
|
|
|
|
|
* jQuery JavaScript Library v1.9.1 |
|
|
|
* jQuery JavaScript Library v1.9.1 |
|
|
|
* http://jquery.com/
|
|
|
|
* http://jquery.com/
|
|
|
|
* |
|
|
|
* |
|
|
@ -20928,6 +20877,15 @@ Date.prototype.getBeforeMultiMonth = function (n) { |
|
|
|
return dt; |
|
|
|
return dt; |
|
|
|
}; |
|
|
|
}; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//获得当前时区对应指定时区的时间
|
|
|
|
|
|
|
|
Date.prototype.getTimeZoneTimeByTimezoneOffset = function (offset) { |
|
|
|
|
|
|
|
var dt = new Date(this.getTime()); |
|
|
|
|
|
|
|
var localTime = dt.getTime(); |
|
|
|
|
|
|
|
var localOffset = dt.getTimezoneOffset() * 60000; //获得当地时间偏移的毫秒数
|
|
|
|
|
|
|
|
var utc = localTime + localOffset; //utc即GMT时间标准时区
|
|
|
|
|
|
|
|
return new Date(utc + offset); |
|
|
|
|
|
|
|
}; |
|
|
|
|
|
|
|
|
|
|
|
/** Checks date and time equality */ |
|
|
|
/** Checks date and time equality */ |
|
|
|
Date.prototype.equalsTo = function (date) { |
|
|
|
Date.prototype.equalsTo = function (date) { |
|
|
|
return ((this.getFullYear() == date.getFullYear()) && |
|
|
|
return ((this.getFullYear() == date.getFullYear()) && |
|
|
@ -42050,68 +42008,68 @@ BI.RichEditorParamAction = BI.inherit(BI.RichEditorAction, { |
|
|
|
|
|
|
|
|
|
|
|
key: function (e) { |
|
|
|
key: function (e) { |
|
|
|
} |
|
|
|
} |
|
|
|
});/** |
|
|
|
});/** |
|
|
|
* 颜色选择 |
|
|
|
* 颜色选择 |
|
|
|
* |
|
|
|
* |
|
|
|
* Created by GUY on 2015/11/26. |
|
|
|
* Created by GUY on 2015/11/26. |
|
|
|
* @class BI.RichEditorTextToolbar |
|
|
|
* @class BI.RichEditorTextToolbar |
|
|
|
* @extends BI.Widget |
|
|
|
* @extends BI.Widget |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
BI.RichEditorTextToolbar = BI.inherit(BI.Widget, { |
|
|
|
BI.RichEditorTextToolbar = BI.inherit(BI.Widget, { |
|
|
|
_defaultConfig: function () { |
|
|
|
_defaultConfig: function () { |
|
|
|
return BI.extend(BI.RichEditorTextToolbar.superclass._defaultConfig.apply(this, arguments), { |
|
|
|
return BI.extend(BI.RichEditorTextToolbar.superclass._defaultConfig.apply(this, arguments), { |
|
|
|
baseCls: "bi-rich-editor-text-toolbar bi-background", |
|
|
|
baseCls: "bi-rich-editor-text-toolbar bi-background", |
|
|
|
buttons: [ |
|
|
|
buttons: [ |
|
|
|
{type: "bi.rich_editor_size_chooser"}, |
|
|
|
{type: "bi.rich_editor_size_chooser"}, |
|
|
|
{type: "bi.rich_editor_bold_button"}, |
|
|
|
{type: "bi.rich_editor_bold_button"}, |
|
|
|
{type: "bi.rich_editor_italic_button"}, |
|
|
|
{type: "bi.rich_editor_italic_button"}, |
|
|
|
{type: "bi.rich_editor_underline_button"}, |
|
|
|
{type: "bi.rich_editor_underline_button"}, |
|
|
|
{type: "bi.rich_editor_color_chooser"}, |
|
|
|
{type: "bi.rich_editor_color_chooser"}, |
|
|
|
{type: "bi.rich_editor_background_color_chooser"}, |
|
|
|
{type: "bi.rich_editor_background_color_chooser"}, |
|
|
|
{type: "bi.rich_editor_align_left_button"}, |
|
|
|
{type: "bi.rich_editor_align_left_button"}, |
|
|
|
{type: "bi.rich_editor_align_center_button"}, |
|
|
|
{type: "bi.rich_editor_align_center_button"}, |
|
|
|
{type: "bi.rich_editor_align_right_button"}, |
|
|
|
{type: "bi.rich_editor_align_right_button"}, |
|
|
|
{type: "bi.rich_editor_param_button"}, |
|
|
|
{type: "bi.rich_editor_param_button"}, |
|
|
|
], |
|
|
|
], |
|
|
|
height: 28 |
|
|
|
height: 28 |
|
|
|
}); |
|
|
|
}); |
|
|
|
}, |
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
_init: function () { |
|
|
|
_init: function () { |
|
|
|
BI.RichEditorTextToolbar.superclass._init.apply(this, arguments); |
|
|
|
BI.RichEditorTextToolbar.superclass._init.apply(this, arguments); |
|
|
|
var self = this, o = this.options; |
|
|
|
var self = this, o = this.options; |
|
|
|
BI.createWidget({ |
|
|
|
BI.createWidget({ |
|
|
|
type: "bi.left", |
|
|
|
type: "bi.left", |
|
|
|
element: this, |
|
|
|
element: this, |
|
|
|
items: BI.map(o.buttons, function (i, btn) { |
|
|
|
items: BI.map(o.buttons, function (i, btn) { |
|
|
|
return BI.extend(btn, { |
|
|
|
return BI.extend(btn, { |
|
|
|
editor: o.editor |
|
|
|
editor: o.editor |
|
|
|
}); |
|
|
|
}); |
|
|
|
}), |
|
|
|
}), |
|
|
|
hgap: 3, |
|
|
|
hgap: 3, |
|
|
|
vgap: 3 |
|
|
|
vgap: 3 |
|
|
|
}) |
|
|
|
}) |
|
|
|
}, |
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
mounted: function () { |
|
|
|
mounted: function () { |
|
|
|
var self = this; |
|
|
|
var self = this; |
|
|
|
if (BI.isIE9Below()) {//IE8下必须要设置unselectable才能不blur输入框
|
|
|
|
if (BI.isIE9Below()) {//IE8下必须要设置unselectable才能不blur输入框
|
|
|
|
this.element.mousedown(function () { |
|
|
|
this.element.mousedown(function () { |
|
|
|
self._noSelect(self.element[0]); |
|
|
|
self._noSelect(self.element[0]); |
|
|
|
}); |
|
|
|
}); |
|
|
|
this._noSelect(this.element[0]); |
|
|
|
this._noSelect(this.element[0]); |
|
|
|
} |
|
|
|
} |
|
|
|
}, |
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
_noSelect: function (element) { |
|
|
|
_noSelect: function (element) { |
|
|
|
if (element.setAttribute && element.nodeName.toLowerCase() != 'input' && element.nodeName.toLowerCase() != 'textarea') { |
|
|
|
if (element.setAttribute && element.nodeName.toLowerCase() != 'input' && element.nodeName.toLowerCase() != 'textarea') { |
|
|
|
element.setAttribute('unselectable', 'on'); |
|
|
|
element.setAttribute('unselectable', 'on'); |
|
|
|
} |
|
|
|
} |
|
|
|
for (var i = 0; i < element.childNodes.length; i++) { |
|
|
|
for (var i = 0; i < element.childNodes.length; i++) { |
|
|
|
this._noSelect(element.childNodes[i]); |
|
|
|
this._noSelect(element.childNodes[i]); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
}); |
|
|
|
}); |
|
|
|
BI.shortcut('bi.rich_editor_text_toolbar', BI.RichEditorTextToolbar);/** |
|
|
|
BI.shortcut('bi.rich_editor_text_toolbar', BI.RichEditorTextToolbar);/** |
|
|
|
* 富文本编辑器 |
|
|
|
* 富文本编辑器 |
|
|
|
* |
|
|
|
* |
|
|
@ -42392,57 +42350,57 @@ BI.shortcut('bi.rich_editor_text_toolbar', BI.RichEditorTextToolbar);/** |
|
|
|
} |
|
|
|
} |
|
|
|
}); |
|
|
|
}); |
|
|
|
}()); |
|
|
|
}()); |
|
|
|
/** |
|
|
|
/** |
|
|
|
* 颜色选择trigger |
|
|
|
* 颜色选择trigger |
|
|
|
* |
|
|
|
* |
|
|
|
* Created by GUY on 2015/11/26. |
|
|
|
* Created by GUY on 2015/11/26. |
|
|
|
* @class BI.RichEditorBackgroundChooserTrigger |
|
|
|
* @class BI.RichEditorBackgroundChooserTrigger |
|
|
|
* @extends BI.Widget |
|
|
|
* @extends BI.Widget |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
BI.RichEditorBackgroundChooserTrigger = BI.inherit(BI.Widget, { |
|
|
|
BI.RichEditorBackgroundChooserTrigger = BI.inherit(BI.Widget, { |
|
|
|
_defaultConfig: function () { |
|
|
|
_defaultConfig: function () { |
|
|
|
var conf = BI.RichEditorBackgroundChooserTrigger.superclass._defaultConfig.apply(this, arguments); |
|
|
|
var conf = BI.RichEditorBackgroundChooserTrigger.superclass._defaultConfig.apply(this, arguments); |
|
|
|
return BI.extend(conf, { |
|
|
|
return BI.extend(conf, { |
|
|
|
width: 20, |
|
|
|
width: 20, |
|
|
|
height: 20 |
|
|
|
height: 20 |
|
|
|
}); |
|
|
|
}); |
|
|
|
}, |
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
_init: function () { |
|
|
|
_init: function () { |
|
|
|
BI.RichEditorBackgroundChooserTrigger.superclass._init.apply(this, arguments); |
|
|
|
BI.RichEditorBackgroundChooserTrigger.superclass._init.apply(this, arguments); |
|
|
|
this.font = BI.createWidget({ |
|
|
|
this.font = BI.createWidget({ |
|
|
|
type: "bi.icon_button", |
|
|
|
type: "bi.icon_button", |
|
|
|
cls: "text-background-font" |
|
|
|
cls: "text-background-font" |
|
|
|
}); |
|
|
|
}); |
|
|
|
|
|
|
|
|
|
|
|
this.underline = BI.createWidget({ |
|
|
|
this.underline = BI.createWidget({ |
|
|
|
type: "bi.icon_button", |
|
|
|
type: "bi.icon_button", |
|
|
|
cls: "text-color-underline-font" |
|
|
|
cls: "text-color-underline-font" |
|
|
|
}); |
|
|
|
}); |
|
|
|
|
|
|
|
|
|
|
|
BI.createWidget({ |
|
|
|
BI.createWidget({ |
|
|
|
type: "bi.absolute", |
|
|
|
type: "bi.absolute", |
|
|
|
element: this, |
|
|
|
element: this, |
|
|
|
items: [{ |
|
|
|
items: [{ |
|
|
|
el: this.font, |
|
|
|
el: this.font, |
|
|
|
top: 2, |
|
|
|
top: 2, |
|
|
|
left: 2 |
|
|
|
left: 2 |
|
|
|
}, { |
|
|
|
}, { |
|
|
|
el: this.underline, |
|
|
|
el: this.underline, |
|
|
|
top: 7, |
|
|
|
top: 7, |
|
|
|
left: 2 |
|
|
|
left: 2 |
|
|
|
}] |
|
|
|
}] |
|
|
|
}) |
|
|
|
}) |
|
|
|
}, |
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
setValue: function (color) { |
|
|
|
setValue: function (color) { |
|
|
|
this.underline.element.css("color", color); |
|
|
|
this.underline.element.css("color", color); |
|
|
|
}, |
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
getValue: function () { |
|
|
|
getValue: function () { |
|
|
|
return this.font.element.css("color"); |
|
|
|
return this.font.element.css("color"); |
|
|
|
} |
|
|
|
} |
|
|
|
}); |
|
|
|
}); |
|
|
|
BI.shortcut('bi.rich_editor_background_color_chooser_trigger', BI.RichEditorBackgroundChooserTrigger);/** |
|
|
|
BI.shortcut('bi.rich_editor_background_color_chooser_trigger', BI.RichEditorBackgroundChooserTrigger);/** |
|
|
|
* |
|
|
|
* |
|
|
|
* Created by GUY on 2015/11/26. |
|
|
|
* Created by GUY on 2015/11/26. |
|
|
@ -42710,214 +42668,214 @@ BI.RichEditorUnderlineButton = BI.inherit(BI.RichEditorAction, { |
|
|
|
this.underline.setSelected(false); |
|
|
|
this.underline.setSelected(false); |
|
|
|
}, |
|
|
|
}, |
|
|
|
}); |
|
|
|
}); |
|
|
|
BI.shortcut("bi.rich_editor_underline_button", BI.RichEditorUnderlineButton)/** |
|
|
|
BI.shortcut("bi.rich_editor_underline_button", BI.RichEditorUnderlineButton)/** |
|
|
|
* 颜色选择trigger |
|
|
|
* 颜色选择trigger |
|
|
|
* |
|
|
|
* |
|
|
|
* Created by GUY on 2015/11/26. |
|
|
|
* Created by GUY on 2015/11/26. |
|
|
|
* @class BI.RichEditorColorChooserTrigger |
|
|
|
* @class BI.RichEditorColorChooserTrigger |
|
|
|
* @extends BI.Widget |
|
|
|
* @extends BI.Widget |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
BI.RichEditorColorChooserTrigger = BI.inherit(BI.Widget, { |
|
|
|
BI.RichEditorColorChooserTrigger = BI.inherit(BI.Widget, { |
|
|
|
_defaultConfig: function () { |
|
|
|
_defaultConfig: function () { |
|
|
|
var conf = BI.RichEditorColorChooserTrigger.superclass._defaultConfig.apply(this, arguments); |
|
|
|
var conf = BI.RichEditorColorChooserTrigger.superclass._defaultConfig.apply(this, arguments); |
|
|
|
return BI.extend(conf, { |
|
|
|
return BI.extend(conf, { |
|
|
|
width: 20, |
|
|
|
width: 20, |
|
|
|
height: 20 |
|
|
|
height: 20 |
|
|
|
}); |
|
|
|
}); |
|
|
|
}, |
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
_init: function () { |
|
|
|
_init: function () { |
|
|
|
BI.RichEditorColorChooserTrigger.superclass._init.apply(this, arguments); |
|
|
|
BI.RichEditorColorChooserTrigger.superclass._init.apply(this, arguments); |
|
|
|
this.font = BI.createWidget({ |
|
|
|
this.font = BI.createWidget({ |
|
|
|
type: "bi.icon_button", |
|
|
|
type: "bi.icon_button", |
|
|
|
cls: "text-color-font" |
|
|
|
cls: "text-color-font" |
|
|
|
}); |
|
|
|
}); |
|
|
|
|
|
|
|
|
|
|
|
this.underline = BI.createWidget({ |
|
|
|
this.underline = BI.createWidget({ |
|
|
|
type: "bi.icon_button", |
|
|
|
type: "bi.icon_button", |
|
|
|
cls: "text-color-underline-font" |
|
|
|
cls: "text-color-underline-font" |
|
|
|
}); |
|
|
|
}); |
|
|
|
|
|
|
|
|
|
|
|
BI.createWidget({ |
|
|
|
BI.createWidget({ |
|
|
|
type: "bi.absolute", |
|
|
|
type: "bi.absolute", |
|
|
|
element: this, |
|
|
|
element: this, |
|
|
|
items: [{ |
|
|
|
items: [{ |
|
|
|
el: this.font, |
|
|
|
el: this.font, |
|
|
|
top: 2, |
|
|
|
top: 2, |
|
|
|
left: 2 |
|
|
|
left: 2 |
|
|
|
}, { |
|
|
|
}, { |
|
|
|
el: this.underline, |
|
|
|
el: this.underline, |
|
|
|
top: 7, |
|
|
|
top: 7, |
|
|
|
left: 2 |
|
|
|
left: 2 |
|
|
|
}] |
|
|
|
}] |
|
|
|
}) |
|
|
|
}) |
|
|
|
}, |
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
setValue: function (color) { |
|
|
|
setValue: function (color) { |
|
|
|
this.underline.element.css("color", color); |
|
|
|
this.underline.element.css("color", color); |
|
|
|
}, |
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
getValue: function () { |
|
|
|
getValue: function () { |
|
|
|
return this.font.element.css("color"); |
|
|
|
return this.font.element.css("color"); |
|
|
|
} |
|
|
|
} |
|
|
|
}); |
|
|
|
}); |
|
|
|
BI.shortcut('bi.rich_editor_color_chooser_trigger', BI.RichEditorColorChooserTrigger);/** |
|
|
|
BI.shortcut('bi.rich_editor_color_chooser_trigger', BI.RichEditorColorChooserTrigger);/** |
|
|
|
* 颜色选择 |
|
|
|
* 颜色选择 |
|
|
|
* |
|
|
|
* |
|
|
|
* Created by GUY on 2015/11/26. |
|
|
|
* Created by GUY on 2015/11/26. |
|
|
|
* @class BI.RichEditorBackgroundColorChooser |
|
|
|
* @class BI.RichEditorBackgroundColorChooser |
|
|
|
* @extends BI.RichEditorAction |
|
|
|
* @extends BI.RichEditorAction |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
BI.RichEditorBackgroundColorChooser = BI.inherit(BI.RichEditorAction, { |
|
|
|
BI.RichEditorBackgroundColorChooser = BI.inherit(BI.RichEditorAction, { |
|
|
|
_defaultConfig: function () { |
|
|
|
_defaultConfig: function () { |
|
|
|
return BI.extend(BI.RichEditorBackgroundColorChooser.superclass._defaultConfig.apply(this, arguments), { |
|
|
|
return BI.extend(BI.RichEditorBackgroundColorChooser.superclass._defaultConfig.apply(this, arguments), { |
|
|
|
width: 20, |
|
|
|
width: 20, |
|
|
|
height: 20, |
|
|
|
height: 20, |
|
|
|
}); |
|
|
|
}); |
|
|
|
}, |
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
_init: function () { |
|
|
|
_init: function () { |
|
|
|
BI.RichEditorBackgroundColorChooser.superclass._init.apply(this, arguments); |
|
|
|
BI.RichEditorBackgroundColorChooser.superclass._init.apply(this, arguments); |
|
|
|
var self = this, o = this.options; |
|
|
|
var self = this, o = this.options; |
|
|
|
this.colorchooser = BI.createWidget({ |
|
|
|
this.colorchooser = BI.createWidget({ |
|
|
|
type: "bi.color_chooser", |
|
|
|
type: "bi.color_chooser", |
|
|
|
element: this, |
|
|
|
element: this, |
|
|
|
width: o.width, |
|
|
|
width: o.width, |
|
|
|
height: o.height, |
|
|
|
height: o.height, |
|
|
|
el: { |
|
|
|
el: { |
|
|
|
type: "bi.rich_editor_background_color_chooser_trigger", |
|
|
|
type: "bi.rich_editor_background_color_chooser_trigger", |
|
|
|
title: BI.i18nText("BI-Widget_Background_Colour"), |
|
|
|
title: BI.i18nText("BI-Widget_Background_Colour"), |
|
|
|
cls: "text-toolbar-button" |
|
|
|
cls: "text-toolbar-button" |
|
|
|
} |
|
|
|
} |
|
|
|
}); |
|
|
|
}); |
|
|
|
this.colorchooser.on(BI.ColorChooser.EVENT_CHANGE, function () { |
|
|
|
this.colorchooser.on(BI.ColorChooser.EVENT_CHANGE, function () { |
|
|
|
var backgroundColor = this.getValue(); |
|
|
|
var backgroundColor = this.getValue(); |
|
|
|
o.editor.element.css({ |
|
|
|
o.editor.element.css({ |
|
|
|
backgroundColor: backgroundColor, |
|
|
|
backgroundColor: backgroundColor, |
|
|
|
color: BI.DOM.getContrastColor(backgroundColor) |
|
|
|
color: BI.DOM.getContrastColor(backgroundColor) |
|
|
|
}); |
|
|
|
}); |
|
|
|
this.setValue(""); |
|
|
|
this.setValue(""); |
|
|
|
}); |
|
|
|
}); |
|
|
|
}, |
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
deactivate: function () { |
|
|
|
deactivate: function () { |
|
|
|
} |
|
|
|
} |
|
|
|
}); |
|
|
|
}); |
|
|
|
BI.shortcut('bi.rich_editor_background_color_chooser', BI.RichEditorBackgroundColorChooser);/** |
|
|
|
BI.shortcut('bi.rich_editor_background_color_chooser', BI.RichEditorBackgroundColorChooser);/** |
|
|
|
* 颜色选择 |
|
|
|
* 颜色选择 |
|
|
|
* |
|
|
|
* |
|
|
|
* Created by GUY on 2015/11/26. |
|
|
|
* Created by GUY on 2015/11/26. |
|
|
|
* @class BI.RichEditorColorChooser |
|
|
|
* @class BI.RichEditorColorChooser |
|
|
|
* @extends BI.RichEditorAction |
|
|
|
* @extends BI.RichEditorAction |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
BI.RichEditorColorChooser = BI.inherit(BI.RichEditorAction, { |
|
|
|
BI.RichEditorColorChooser = BI.inherit(BI.RichEditorAction, { |
|
|
|
_defaultConfig: function () { |
|
|
|
_defaultConfig: function () { |
|
|
|
return BI.extend(BI.RichEditorColorChooser.superclass._defaultConfig.apply(this, arguments), { |
|
|
|
return BI.extend(BI.RichEditorColorChooser.superclass._defaultConfig.apply(this, arguments), { |
|
|
|
width: 20, |
|
|
|
width: 20, |
|
|
|
height: 20, |
|
|
|
height: 20, |
|
|
|
command: "foreColor" |
|
|
|
command: "foreColor" |
|
|
|
}); |
|
|
|
}); |
|
|
|
}, |
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
_init: function () { |
|
|
|
_init: function () { |
|
|
|
BI.RichEditorColorChooser.superclass._init.apply(this, arguments); |
|
|
|
BI.RichEditorColorChooser.superclass._init.apply(this, arguments); |
|
|
|
var self = this, o = this.options; |
|
|
|
var self = this, o = this.options; |
|
|
|
this.colorchooser = BI.createWidget({ |
|
|
|
this.colorchooser = BI.createWidget({ |
|
|
|
type: "bi.color_chooser", |
|
|
|
type: "bi.color_chooser", |
|
|
|
element: this, |
|
|
|
element: this, |
|
|
|
width: o.width, |
|
|
|
width: o.width, |
|
|
|
height: o.height, |
|
|
|
height: o.height, |
|
|
|
el: { |
|
|
|
el: { |
|
|
|
type: "bi.rich_editor_color_chooser_trigger", |
|
|
|
type: "bi.rich_editor_color_chooser_trigger", |
|
|
|
title: BI.i18nText("BI-Font_Colour"), |
|
|
|
title: BI.i18nText("BI-Font_Colour"), |
|
|
|
cls: "text-toolbar-button" |
|
|
|
cls: "text-toolbar-button" |
|
|
|
} |
|
|
|
} |
|
|
|
}); |
|
|
|
}); |
|
|
|
this.colorchooser.on(BI.ColorChooser.EVENT_CHANGE, function () { |
|
|
|
this.colorchooser.on(BI.ColorChooser.EVENT_CHANGE, function () { |
|
|
|
self.doCommand(this.getValue()); |
|
|
|
self.doCommand(this.getValue()); |
|
|
|
}); |
|
|
|
}); |
|
|
|
|
|
|
|
|
|
|
|
}, |
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
deactivate: function () { |
|
|
|
deactivate: function () { |
|
|
|
this.colorchooser.setValue(""); |
|
|
|
this.colorchooser.setValue(""); |
|
|
|
} |
|
|
|
} |
|
|
|
}); |
|
|
|
}); |
|
|
|
BI.shortcut('bi.rich_editor_color_chooser', BI.RichEditorColorChooser);/** |
|
|
|
BI.shortcut('bi.rich_editor_color_chooser', BI.RichEditorColorChooser);/** |
|
|
|
* 字体大小选择 |
|
|
|
* 字体大小选择 |
|
|
|
* |
|
|
|
* |
|
|
|
* Created by GUY on 2015/11/26. |
|
|
|
* Created by GUY on 2015/11/26. |
|
|
|
* @class BI.RichEditorSizeChooser |
|
|
|
* @class BI.RichEditorSizeChooser |
|
|
|
* @extends BI.RichEditorAction |
|
|
|
* @extends BI.RichEditorAction |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
BI.RichEditorSizeChooser = BI.inherit(BI.RichEditorAction, { |
|
|
|
BI.RichEditorSizeChooser = BI.inherit(BI.RichEditorAction, { |
|
|
|
_defaultConfig: function () { |
|
|
|
_defaultConfig: function () { |
|
|
|
return BI.extend(BI.RichEditorSizeChooser.superclass._defaultConfig.apply(this, arguments), { |
|
|
|
return BI.extend(BI.RichEditorSizeChooser.superclass._defaultConfig.apply(this, arguments), { |
|
|
|
baseCls: "bi-rich-editor-size-chooser bi-border bi-card", |
|
|
|
baseCls: "bi-rich-editor-size-chooser bi-border bi-card", |
|
|
|
command: "FontSize", |
|
|
|
command: "FontSize", |
|
|
|
width: 50, |
|
|
|
width: 50, |
|
|
|
height: 20 |
|
|
|
height: 20 |
|
|
|
}); |
|
|
|
}); |
|
|
|
}, |
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
_items: [{ |
|
|
|
_items: [{ |
|
|
|
value: 1, |
|
|
|
value: 1, |
|
|
|
text: "1(8pt)" |
|
|
|
text: "1(8pt)" |
|
|
|
}, { |
|
|
|
}, { |
|
|
|
value: 2, |
|
|
|
value: 2, |
|
|
|
text: "2(10pt)" |
|
|
|
text: "2(10pt)" |
|
|
|
}, { |
|
|
|
}, { |
|
|
|
value: 3, |
|
|
|
value: 3, |
|
|
|
text: "3(12pt)" |
|
|
|
text: "3(12pt)" |
|
|
|
}, { |
|
|
|
}, { |
|
|
|
value: 4, |
|
|
|
value: 4, |
|
|
|
text: "4(14pt)" |
|
|
|
text: "4(14pt)" |
|
|
|
}, { |
|
|
|
}, { |
|
|
|
value: 5, |
|
|
|
value: 5, |
|
|
|
text: "5(18pt)" |
|
|
|
text: "5(18pt)" |
|
|
|
}, { |
|
|
|
}, { |
|
|
|
value: 6, |
|
|
|
value: 6, |
|
|
|
text: "6(24pt)" |
|
|
|
text: "6(24pt)" |
|
|
|
}], |
|
|
|
}], |
|
|
|
|
|
|
|
|
|
|
|
_init: function () { |
|
|
|
_init: function () { |
|
|
|
BI.RichEditorSizeChooser.superclass._init.apply(this, arguments); |
|
|
|
BI.RichEditorSizeChooser.superclass._init.apply(this, arguments); |
|
|
|
var self = this, o = this.options; |
|
|
|
var self = this, o = this.options; |
|
|
|
this.trigger = BI.createWidget({ |
|
|
|
this.trigger = BI.createWidget({ |
|
|
|
type: "bi.text_trigger", |
|
|
|
type: "bi.text_trigger", |
|
|
|
readonly: true, |
|
|
|
readonly: true, |
|
|
|
height: o.height, |
|
|
|
height: o.height, |
|
|
|
triggerWidth: 12, |
|
|
|
triggerWidth: 12, |
|
|
|
text: BI.i18nText("BI-Font_Size") |
|
|
|
text: BI.i18nText("BI-Font_Size") |
|
|
|
}); |
|
|
|
}); |
|
|
|
|
|
|
|
|
|
|
|
this.combo = BI.createWidget({ |
|
|
|
this.combo = BI.createWidget({ |
|
|
|
type: "bi.combo", |
|
|
|
type: "bi.combo", |
|
|
|
element: this, |
|
|
|
element: this, |
|
|
|
el: this.trigger, |
|
|
|
el: this.trigger, |
|
|
|
adjustLength: 1, |
|
|
|
adjustLength: 1, |
|
|
|
popup: { |
|
|
|
popup: { |
|
|
|
maxWidth: 70, |
|
|
|
maxWidth: 70, |
|
|
|
minWidth: 70, |
|
|
|
minWidth: 70, |
|
|
|
el: { |
|
|
|
el: { |
|
|
|
type: "bi.button_group", |
|
|
|
type: "bi.button_group", |
|
|
|
items: BI.createItems(this._items, { |
|
|
|
items: BI.createItems(this._items, { |
|
|
|
type: "bi.single_select_item" |
|
|
|
type: "bi.single_select_item" |
|
|
|
}), |
|
|
|
}), |
|
|
|
layouts: [{ |
|
|
|
layouts: [{ |
|
|
|
type: "bi.vertical" |
|
|
|
type: "bi.vertical" |
|
|
|
}] |
|
|
|
}] |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
}); |
|
|
|
}); |
|
|
|
this.combo.on(BI.Combo.EVENT_CHANGE, function () { |
|
|
|
this.combo.on(BI.Combo.EVENT_CHANGE, function () { |
|
|
|
var val = this.getValue()[0]; |
|
|
|
var val = this.getValue()[0]; |
|
|
|
self.doCommand(val); |
|
|
|
self.doCommand(val); |
|
|
|
this.hideView(); |
|
|
|
this.hideView(); |
|
|
|
this.setValue([]); |
|
|
|
this.setValue([]); |
|
|
|
}) |
|
|
|
}) |
|
|
|
} |
|
|
|
} |
|
|
|
}); |
|
|
|
}); |
|
|
|
BI.shortcut('bi.rich_editor_size_chooser', BI.RichEditorSizeChooser);/** |
|
|
|
BI.shortcut('bi.rich_editor_size_chooser', BI.RichEditorSizeChooser);/** |
|
|
|
* 富文本编辑器 |
|
|
|
* 富文本编辑器 |
|
|
|
* |
|
|
|
* |
|
|
@ -93279,4 +93237,125 @@ BI.ValueChooserPane = BI.inherit(BI.AbstractValueChooser, { |
|
|
|
} |
|
|
|
} |
|
|
|
}); |
|
|
|
}); |
|
|
|
BI.ValueChooserPane.EVENT_CHANGE = "ValueChooserPane.EVENT_CHANGE"; |
|
|
|
BI.ValueChooserPane.EVENT_CHANGE = "ValueChooserPane.EVENT_CHANGE"; |
|
|
|
BI.shortcut('bi.value_chooser_pane', BI.ValueChooserPane); |
|
|
|
BI.shortcut('bi.value_chooser_pane', BI.ValueChooserPane);BI.servletURL = "https://fanruan.coding.me/fineui/dist/"; |
|
|
|
|
|
|
|
BI.resourceURL = "https://fanruan.coding.me/fineui/dist/resource/"; |
|
|
|
|
|
|
|
BI.i18n = { |
|
|
|
|
|
|
|
"BI-Multi_Date_Quarter_End": "季度末", |
|
|
|
|
|
|
|
"BI-Multi_Date_Month_Begin": "月初", |
|
|
|
|
|
|
|
"BI-Multi_Date_YMD": "年/月/日", |
|
|
|
|
|
|
|
"BI-Custom_Color": "自定义颜色", |
|
|
|
|
|
|
|
"BI-Numerical_Interval_Input_Data": "请输入数值", |
|
|
|
|
|
|
|
"BI-Please_Input_Natural_Number": "请输入非负整数", |
|
|
|
|
|
|
|
"BI-No_More_Data": "无更多数据", |
|
|
|
|
|
|
|
"BI-Basic_Altogether": "共", |
|
|
|
|
|
|
|
"BI-Basic_Sunday": "星期日", |
|
|
|
|
|
|
|
"BI-Widget_Background_Colour": "组件背景", |
|
|
|
|
|
|
|
"BI-Color_Picker_Error_Text": "请输入0~255的正整数", |
|
|
|
|
|
|
|
"BI-Multi_Date_Month": "月", |
|
|
|
|
|
|
|
"BI-No_Selected_Item": "没有可选项", |
|
|
|
|
|
|
|
"BI-Multi_Date_Year_Begin": "年初", |
|
|
|
|
|
|
|
"BI-Quarter_1": "第1季度", |
|
|
|
|
|
|
|
"BI-Quarter_2": "第2季度", |
|
|
|
|
|
|
|
"BI-Quarter_3": "第3季度", |
|
|
|
|
|
|
|
"BI-Quarter_4": "第4季度", |
|
|
|
|
|
|
|
"BI-Multi_Date_Year_Next": "年后", |
|
|
|
|
|
|
|
"BI-Multi_Date_Month_Prev": "个月前", |
|
|
|
|
|
|
|
"BI-Month_Trigger_Error_Text": "请输入1~12的正整数", |
|
|
|
|
|
|
|
"BI-Less_And_Equal": "小于等于", |
|
|
|
|
|
|
|
"BI-Year_Trigger_Invalid_Text": "请输入有效时间", |
|
|
|
|
|
|
|
"BI-Multi_Date_Week_Next": "周后", |
|
|
|
|
|
|
|
"BI-Font_Size": "字号", |
|
|
|
|
|
|
|
"BI-Basic_Total": "共", |
|
|
|
|
|
|
|
"BI-Already_Selected": "已选择", |
|
|
|
|
|
|
|
"BI-Formula_Insert": "插入", |
|
|
|
|
|
|
|
"BI-Select_All": "全选", |
|
|
|
|
|
|
|
"BI-Basic_Tuesday": "星期二", |
|
|
|
|
|
|
|
"BI-Multi_Date_Month_End": "月末", |
|
|
|
|
|
|
|
"BI-Load_More": "点击加载更多数据", |
|
|
|
|
|
|
|
"BI-Basic_September": "九月", |
|
|
|
|
|
|
|
"BI-Current_Is_Last_Page": "当前已是最后一页", |
|
|
|
|
|
|
|
"BI-Basic_Auto": "自动", |
|
|
|
|
|
|
|
"BI-Basic_Count": "个", |
|
|
|
|
|
|
|
"BI-Basic_Value": "值", |
|
|
|
|
|
|
|
"BI-Basic_Unrestricted": "无限制", |
|
|
|
|
|
|
|
"BI-Quarter_Trigger_Error_Text": "请输入1~4的正整数", |
|
|
|
|
|
|
|
"BI-Basic_More": "更多", |
|
|
|
|
|
|
|
"BI-Basic_Wednesday": "星期三", |
|
|
|
|
|
|
|
"BI-Basic_Bold": "加粗", |
|
|
|
|
|
|
|
"BI-Basic_Simple_Saturday": "六", |
|
|
|
|
|
|
|
"BI-Multi_Date_Month_Next": "个月后", |
|
|
|
|
|
|
|
"BI-Basic_March": "三月", |
|
|
|
|
|
|
|
"BI-Current_Is_First_Page": "当前已是第一页", |
|
|
|
|
|
|
|
"BI-Basic_Thursday": "星期四", |
|
|
|
|
|
|
|
"BI-Basic_Prompt": "提示", |
|
|
|
|
|
|
|
"BI-Multi_Date_Today": "今天", |
|
|
|
|
|
|
|
"BI-Multi_Date_Quarter_Prev": "个季度前", |
|
|
|
|
|
|
|
"BI-Row_Header": "行表头", |
|
|
|
|
|
|
|
"BI-Date_Trigger_Error_Text": "日期格式示例:2015-3-11", |
|
|
|
|
|
|
|
"BI-Basic_Cancel": "取消", |
|
|
|
|
|
|
|
"BI-Basic_January": "一月", |
|
|
|
|
|
|
|
"BI-Basic_June": "六月", |
|
|
|
|
|
|
|
"BI-Basic_July": "七月", |
|
|
|
|
|
|
|
"BI-Basic_April": "四月", |
|
|
|
|
|
|
|
"BI-Multi_Date_Quarter_Begin": "季度初", |
|
|
|
|
|
|
|
"BI-Multi_Date_Week": "周", |
|
|
|
|
|
|
|
"BI-Click_Blank_To_Select": "点按\"空格键\"选中匹配项", |
|
|
|
|
|
|
|
"BI-Basic_August": "八月", |
|
|
|
|
|
|
|
"BI-Word_Align_Left": "文字居左", |
|
|
|
|
|
|
|
"BI-Basic_November": "十一月", |
|
|
|
|
|
|
|
"BI-Font_Colour": "字体颜色", |
|
|
|
|
|
|
|
"BI-Multi_Date_Day_Prev": "天前", |
|
|
|
|
|
|
|
"BI-Select_Part": "部分选择", |
|
|
|
|
|
|
|
"BI-Multi_Date_Day_Next": "天后", |
|
|
|
|
|
|
|
"BI-Less_Than": "小于", |
|
|
|
|
|
|
|
"BI-Basic_February": "二月", |
|
|
|
|
|
|
|
"BI-Multi_Date_Year": "年", |
|
|
|
|
|
|
|
"BI-Number_Index": "序号", |
|
|
|
|
|
|
|
"BI-Multi_Date_Week_Prev": "周前", |
|
|
|
|
|
|
|
"BI-Next_Page": "下一页", |
|
|
|
|
|
|
|
"BI-Right_Page": "向右翻页", |
|
|
|
|
|
|
|
"BI-Numerical_Interval_Signal_Value": "前后值相等,请将操作符改为“≤”", |
|
|
|
|
|
|
|
"BI-Basic_December": "十二月", |
|
|
|
|
|
|
|
"BI-Basic_Saturday": "星期六", |
|
|
|
|
|
|
|
"BI-Basic_Simple_Wednesday": "三", |
|
|
|
|
|
|
|
"BI-Multi_Date_Quarter_Next": "个季度后", |
|
|
|
|
|
|
|
"BI-Basic_October": "十月", |
|
|
|
|
|
|
|
"BI-Basic_Simple_Friday": "五", |
|
|
|
|
|
|
|
"BI-Primary_Key": "主键", |
|
|
|
|
|
|
|
"BI-Basic_Save": "保存", |
|
|
|
|
|
|
|
"BI-Numerical_Interval_Number_Value": "请保证前面的数值小于/等于后面的数值", |
|
|
|
|
|
|
|
"BI-Previous_Page": "上一页", |
|
|
|
|
|
|
|
"BI-No_Select": "搜索结果为空", |
|
|
|
|
|
|
|
"BI-Basic_Clears": "清空", |
|
|
|
|
|
|
|
"BI-Created_By_Me": "我创建的", |
|
|
|
|
|
|
|
"BI-Basic_Simple_Tuesday": "二", |
|
|
|
|
|
|
|
"BI-Word_Align_Right": "文字居右", |
|
|
|
|
|
|
|
"BI-Summary_Values": "汇总", |
|
|
|
|
|
|
|
"BI-Basic_Clear": "清除", |
|
|
|
|
|
|
|
"BI-Upload_File_Size_Error": "文件大小不支", |
|
|
|
|
|
|
|
"BI-Up_Page": "向上翻页", |
|
|
|
|
|
|
|
"BI-Basic_Simple_Sunday": "日", |
|
|
|
|
|
|
|
"BI-Multi_Date_Relative_Current_Time": "相对当前时间", |
|
|
|
|
|
|
|
"BI-Selected_Data": "已选数据:", |
|
|
|
|
|
|
|
"BI-Multi_Date_Quarter": "季度", |
|
|
|
|
|
|
|
"BI-Check_Selected": "查看已选", |
|
|
|
|
|
|
|
"BI-Basic_Search": "搜索", |
|
|
|
|
|
|
|
"BI-Basic_May": "五月", |
|
|
|
|
|
|
|
"BI-Continue_Select": "继续选择", |
|
|
|
|
|
|
|
"BI-Please_Input_Positive_Integer": "请输入正整数", |
|
|
|
|
|
|
|
"BI-Upload_File_Type_Error": "文件类型不支持", |
|
|
|
|
|
|
|
"BI-Basic_Friday": "星期五", |
|
|
|
|
|
|
|
"BI-Down_Page": "向下翻页", |
|
|
|
|
|
|
|
"BI-Basic_Monday": "星期一", |
|
|
|
|
|
|
|
"BI-Left_Page": "向左翻页", |
|
|
|
|
|
|
|
"BI-Transparent_Color": "透明", |
|
|
|
|
|
|
|
"BI-Basic_Simple_Monday": "一", |
|
|
|
|
|
|
|
"BI-Multi_Date_Year_End": "年末", |
|
|
|
|
|
|
|
"BI-Time_Interval_Error_Text": "请保证前面时间小于/等于后面的时间", |
|
|
|
|
|
|
|
"BI-Basic_Time": "时间", |
|
|
|
|
|
|
|
"BI-Basic_OK": "确定", |
|
|
|
|
|
|
|
"BI-Basic_Simple_Thursday": "四", |
|
|
|
|
|
|
|
"BI-Multi_Date_Year_Prev": "年前", |
|
|
|
|
|
|
|
"BI-Tiao_Data": "条数据", |
|
|
|
|
|
|
|
"BI-Basic_Italic": "斜体" |
|
|
|
|
|
|
|
}; |