graceguo-supercat commented on a change in pull request #6286: [annotation]
Only allow override whole time_range
URL:
https://github.com/apache/incubator-superset/pull/6286#discussion_r231343020
##########
File path: superset/assets/src/explore/components/controls/AnnotationLayer.jsx
##########
@@ -427,31 +427,15 @@ export default class AnnotationLayer extends
React.PureComponent {
<div style={{ marginTop: '1rem' }}>
<CheckboxControl
hovered
- name="annotation-override-since"
- label="Override 'Since'"
- description={`This controls whether the "Since" field from the
current
+ name="annotation-override-time_range"
+ label="Override time range"
+ description={`This controls whether the "time_range" field
from the current
view should be passed down to the chart containing the
annotation data.`}
- value={!!Object.keys(overrides).find(x => x === 'since')}
+ value={!!Object.keys(overrides).find(x => x === 'time_range'
|| x === 'since' || x === 'until')}
Review comment:
this line is to backward compatible with old override options: since or
until. now we only allow override whole time_range, so either since or until
will be treated like override time_range.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]