Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Copying survey #13

Open
DenFin opened this issue May 23, 2019 · 10 comments
Open

Copying survey #13

DenFin opened this issue May 23, 2019 · 10 comments
Labels
enhancement New feature or request

Comments

@DenFin
Copy link

DenFin commented May 23, 2019

It would be very handy to be able to copy a survey from the mysurveys view. So one could create a survey as a template and then copy it when needed.

@tsv2013 tsv2013 added the enhancement New feature or request label May 23, 2019
@tsv2013
Copy link
Member

tsv2013 commented May 23, 2019

Thank you for the feedback! I've added this task to our backlog.

@DenFin
Copy link
Author

DenFin commented May 23, 2019

Cool! Thank your for your quick reply. Can you tell when you will come around to this? More like sometime in the undefined future or more like in a month or so?

@tsv2013
Copy link
Member

tsv2013 commented May 23, 2019

More likely in a month or so. We'll collect a set of enchancements and then implement them.

@DenFin
Copy link
Author

DenFin commented Aug 7, 2019

Hi there! Is there any news about this?

@tsv2013
Copy link
Member

tsv2013 commented Aug 8, 2019

Hi @DenFin ! Unfortunately no, at this moment we have other task related to SurveyJS Library and SurveyJS Creator products.

@DenFin
Copy link
Author

DenFin commented Aug 27, 2019

Hi there! It's me again 😅. I have created a fork and implemented the feature that allows users to duplicate an existing survey. However this would be my first public pull request on GitHub, so I thought I might share my solution first before making a pull request to the official repository. It would be great if you could have a look at the code and provide some short feedback.

@tsv2013
Copy link
Member

tsv2013 commented Aug 31, 2019

@DenFin Yous code looks ok for me

@mozesj
Copy link

mozesj commented Jun 21, 2023

@DenFin how is this achieved? I can't seem to find any reference of the same

@DenFin
Copy link
Author

DenFin commented Jun 21, 2023

@mozesj Sorry, I deleted my fork some time ago. I have no expertise in PHP and back when I forked the repo I just copy pasted parts from the create_survey logic, edited it and from there on it was just trial and error. But looking at the code, it seems like this has been implemented. Maybe have a look at this file or this commit

@andyg2
Copy link

andyg2 commented Jun 21, 2023

@DenFin how is this achieved? I can't seem to find any reference of the same

You can do this from the My Surveys Page in WordPress. Look for the green "clone" button.

<span class="sv_button_link" onclick="cloneSurvey(<?php echo sanitize_key($surveyDefinition->id) ?>)">Clone</span>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

4 participants