Skip to content

extraValues & readonly#3

Closed
tfforums wants to merge 2 commits intoshawnchin:masterfrom
tfforums:master
Closed

extraValues & readonly#3
tfforums wants to merge 2 commits intoshawnchin:masterfrom
tfforums:master

Conversation

@tfforums
Copy link

Hi - just added the abilty to specify custom top-level options. would be nice if this could be done for 2nd level options or ranges... ie add "5 minutes" etc... in options for the create:

extraValues:[["5 Minutes","/5 * * * *"],["15 Minutes","/15 * * * *"]]

note the format is nested arrays - less than ideal / could be better

Also added a brute-force readonly method... which converts the value to text without the controls... pretty harshe but works.

I just thought that this stuff may be the start of doing this properly rather than my hacks :)

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is horrible... but works... please make nice :)

@shawnchin
Copy link
Owner

Thanks for the changes. Allowing extra custom values is a great idea, but I'm not sure if that's the cleanest approach.

I'll digest your edits when I get a chance to and try to integrate the feature.

@shawnchin
Copy link
Owner

I'm just committed an implementation of this (bef27d9). Hopefully this meets your requirements as well. Do feel free to suggest improvements to updates.

I'll wrap the changes up and release it under a new version once it's properly tested.

Many thanks for your contribution.

@shawnchin shawnchin closed this Oct 18, 2011
@tfforums
Copy link
Author

yes - i just did this as a once off for myself... would be nice to have an
"other" period menu with configurable pre-set crons but I got to the point
of it doing what i needed... and then gave up... sorry.

Tom

On Wed, Oct 19, 2011 at 2:53 AM, Shawn Chin <
reply@reply.github.com>wrote:

Thanks for the changes. Allowing extra custom values is a great idea, but
I'm not sure if that's the cleanest approach.

I'll digest your edits when I get a chance to and try to integrate the
feature.

Reply to this email directly or view it on GitHub:
#3 (comment)

@shawnchin
Copy link
Owner

Yup. An "other" menu item with a secondary menu showing the custom entries would be also be nice, however that requires a much bigger change to the code.

The current scheme reads well ("Every [5 minutes]" instead of "Every [others] [5 minutes]") and requires only one selection. But this can get quite messy when you have lots of custom entries, so the other scheme would definitely scale better.

I can't decide on which is more user friendly so I'll stick to the simpler implementation for now. Will keep that in mind for future updates.

Many thanks.

Shawn

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants