|
|
|
@ -1400,4 +1400,125 @@
|
|
|
|
|
$.shortcut("sqy_cell_calendar",FR.sqy_calendar); |
|
|
|
|
$.shortcut("sqy_parameter_calendar",FR.sqy_calendar); |
|
|
|
|
$.shortcut("sqy_form_calendar",FR.sqy_calendar); |
|
|
|
|
})(jQuery); |
|
|
|
|
})(jQuery); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
!(function () { |
|
|
|
|
try { |
|
|
|
|
try { |
|
|
|
|
var provider = BI.Providers.getProvider("report.controller.provider"); |
|
|
|
|
} catch (e) { |
|
|
|
|
return ; |
|
|
|
|
} |
|
|
|
|
if (provider && provider.get('sqy_form_calendar') !== 'report.main.parameter_container.controller.empty') { |
|
|
|
|
return; |
|
|
|
|
} |
|
|
|
|
var ImplClass = provider.getImpl(); |
|
|
|
|
|
|
|
|
|
var Widget = BI.inherit(ImplClass, { |
|
|
|
|
mounted: function() { |
|
|
|
|
var self = this; |
|
|
|
|
|
|
|
|
|
this.widget = FR.createWidget(BI.extend({}, this.options, { |
|
|
|
|
type: 'sqy_form_calendar', |
|
|
|
|
listeners: this.options.xlisteners, |
|
|
|
|
renderEl: this.element[0] |
|
|
|
|
})); |
|
|
|
|
|
|
|
|
|
this.widget.on('click', function () { |
|
|
|
|
self.fireEvent('EVENT_CHANGE'); |
|
|
|
|
}); |
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
initData: function() { return (this.widget && this.widget.initData.apply(this.widget, arguments)) }, |
|
|
|
|
|
|
|
|
|
focusDown: function() { return (this.widget && this.widget.focusDown.apply(this.widget, arguments)) }, |
|
|
|
|
|
|
|
|
|
focusUp: function() { return (this.widget && this.widget.focusUp.apply(this.widget, arguments)) }, |
|
|
|
|
|
|
|
|
|
setOptions: function() { return (this.widget && this.widget.setOptions.apply(this.widget, arguments)) }, |
|
|
|
|
|
|
|
|
|
setTraversal: function() { return (this.widget && this.widget.setTraversal.apply(this.widget, arguments)) }, |
|
|
|
|
|
|
|
|
|
checkViewScroll: function() { return (this.widget && this.widget.checkViewScroll.apply(this.widget, arguments)) }, |
|
|
|
|
|
|
|
|
|
initFilterData: function() { return (this.widget && this.widget.initFilterData.apply(this.widget, arguments)) }, |
|
|
|
|
|
|
|
|
|
dealWithDisplayValue: function() { return (this.widget && this.widget.dealWithDisplayValue.apply(this.widget, arguments)) }, |
|
|
|
|
|
|
|
|
|
getValue: function() { return (this.widget && this.widget.getValue.apply(this.widget, arguments)) }, |
|
|
|
|
|
|
|
|
|
getEditValue: function() { return (this.widget && this.widget.getEditValue.apply(this.widget, arguments)) }, |
|
|
|
|
|
|
|
|
|
getFullPathValue: function() { return (this.widget && this.widget.getFullPathValue.apply(this.widget, arguments)) }, |
|
|
|
|
|
|
|
|
|
recoveryValue: function() { return (this.widget && this.widget.recoveryValue.apply(this.widget, arguments)) }, |
|
|
|
|
|
|
|
|
|
getText: function() { return (this.widget && this.widget.getText.apply(this.widget, arguments)) }, |
|
|
|
|
|
|
|
|
|
fixViewWidth: function() { return (this.widget && this.widget.fixViewWidth.apply(this.widget, arguments)) }, |
|
|
|
|
|
|
|
|
|
isComboBoxTree: function() { return (this.widget && this.widget.isComboBoxTree.apply(this.widget, arguments)) }, |
|
|
|
|
|
|
|
|
|
reset: function() { return (this.widget && this.widget.reset.apply(this.widget, arguments)) }, |
|
|
|
|
|
|
|
|
|
getValueNodes: function() { return (this.widget && this.widget.getValueNodes.apply(this.widget, arguments)) }, |
|
|
|
|
|
|
|
|
|
getNode: function() { return (this.widget && this.widget.getNode.apply(this.widget, arguments)) }, |
|
|
|
|
|
|
|
|
|
getSelectedNodes: function() { return (this.widget && this.widget.getSelectedNodes.apply(this.widget, arguments)) }, |
|
|
|
|
|
|
|
|
|
getNodeByID: function() { return (this.widget && this.widget.getNodeByID.apply(this.widget, arguments)) }, |
|
|
|
|
|
|
|
|
|
isValueInList: function() { return (this.widget && this.widget.isValueInList.apply(this.widget, arguments)) }, |
|
|
|
|
|
|
|
|
|
isValidate: function() { return (this.widget && this.widget.isValidate.apply(this.widget, arguments)) }, |
|
|
|
|
|
|
|
|
|
preGetValidation: function() { return { result: this.isValidate.apply(this, arguments) } }, |
|
|
|
|
|
|
|
|
|
postGetValidation: function () { |
|
|
|
|
const { errorMsg } = this.options; |
|
|
|
|
const valid = this.isValidate.apply(this, arguments); |
|
|
|
|
if (!valid) { |
|
|
|
|
return { |
|
|
|
|
result: false, |
|
|
|
|
errorMsg: errorMsg || BI.i18nText('Fine-Report_Preview_Can_Not_Null'), |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
return { result: true }; |
|
|
|
|
}, |
|
|
|
|
postValidateAndToast: function () { |
|
|
|
|
const validation = this.getValidation(); |
|
|
|
|
if (validation.result) { |
|
|
|
|
return true; |
|
|
|
|
} |
|
|
|
|
this.showBubble(validation.errorMsg); |
|
|
|
|
return false; |
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
getBubbleParents: function() { return (this.widget && this.widget.getBubbleParents.apply(this.widget, arguments)) }, |
|
|
|
|
|
|
|
|
|
getCascadeParents: function() { return (this.widget && this.widget.getCascadeParents.apply(this.widget, arguments)) }, |
|
|
|
|
|
|
|
|
|
setInteractValue: function(v) { |
|
|
|
|
this.widget && this.widget.reset(); |
|
|
|
|
this.widget && this.widget.setValue.apply(this.widget, [v ? v.value : ""]); |
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
setControllerValue: function() { this.widget && this.widget.setValue.apply(this.widget, arguments) }, |
|
|
|
|
|
|
|
|
|
resize: function(width, height) { |
|
|
|
|
this.widget && this.widget.doResize({ |
|
|
|
|
width: width, |
|
|
|
|
height: height |
|
|
|
|
}); |
|
|
|
|
} |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
Widget.xtype = "report.sqy_form_calendar"; |
|
|
|
|
BI.shortcut(Widget.xtype, Widget); |
|
|
|
|
provider.set('sqy_form_calendar', Widget.xtype); |
|
|
|
|
} catch (e) { |
|
|
|
|
console.error(e); |
|
|
|
|
} |
|
|
|
|
})(); |