I'd like the ability to make the live preview (which is awesome btw) less "live". One way this could be accomplished is by providing a checkbox (maybe below the Analyze button or to the right of the Delete button) that toggles whether the live preview is updated when a change is made.

My reason is that I'm using the Views UI on a slow server. The extra HTTP request(s) that are made when the live preview updates after making a change take a long time to return.

Thanks!

Comments

dawehner’s picture

StatusFileSize
new13.09 KB

Wouldn't it be better to place the button in the live preview form? See the attachment

ccrackerjack’s picture

I'd like to see this feature too which I think should be there from the beginning. Right now I have to wait for 5 to 10 secs for each field I edited (up to few mins when I'm at office with slower Internet connection) and its annoying and crazy time consuming.

tm01xx’s picture

Yes, me too. We should have a choice whether we want to live preview or not. For me, most of the time I dont need it really.

Thanks,

dawehner’s picture

Status: Active » Needs review
StatusFileSize
new899 bytes

Here is the patch

figover’s picture

Good work, This is working for me.

But when i import this patch, an error is coming on command line
"
(Stripping trailing CRs from patch.)
patching file includes/admin.inc
patch unexpectedly ends in middle of line
Hunk #2 succeeded at 502 with fuzz 1.

"

Why this error is coming?
If i am doing something wrong, please guide me.

dawehner’s picture

Status: Needs review » Needs work

The problem is that views has patched the full admin.inc file to unix line endings. I will rerole the patch for 2.x

merlinofchaos’s picture

Status: Needs work » Needs review

I can still apply the patch either way just by running it through a quick conversion, so sticking this back into the review queue.

merlinofchaos’s picture

Status: Needs review » Needs work

Disabling live preview should actually happen elsewhere. This disables live preview after the AJAX call has already been made. That seems very silly. It also means you can't live preview on request, so I would consider this actively harmful.

What you really want is to disable *automatic* live preview. That should be a general setting on the tools >> settings tab.

fabio84’s picture

I'd like this feature, too. I think live preview may be the cause of server slowdown I experienced sometimes.

I think you should be able to see the generated SQL code, without executing it. So you can check what query it's going to execute, check what may slow it down, and optimize it before it can bring down the server.

dawehner’s picture

Earl suggest to disable the preview request.

I let enabled the display of the request, but denied the querying and the rendering of the preview.

I like your idea to just disable the query/rendering but still display the query itself. Any other ideas?

dawehner’s picture

Status: Needs work » Needs review
StatusFileSize
new1.7 KB

Another try :)

This time there is no ajax request fired

stborchert’s picture

+++ includes/admin.inc
@@ -518,6 +518,13 @@ function views_ui_preview_form(&$form_state) {
+    '#title' => t('Automatic live preview'),

+++ includes/admin.inc
@@ -3490,6 +3497,13 @@ function views_ui_admin_tools() {
+    '#title' => t('Disable Automatic Live preview'),

Decide which one to use:
* Nearly all uppercase?
* First word uppercase?

Apart from that: looks really good (and nearly RTBC).

Powered by Dreditor.

dawehner’s picture

StatusFileSize
new1.7 KB

Next version

I used: * First word uppercase?

dawehner’s picture

StatusFileSize
new1.7 KB

Huch another try. I was in the wrong directory / uploaded the wrong file

stborchert’s picture

Status: Needs review » Reviewed & tested by the community

RTBC from me.

merlinofchaos’s picture

Version: 6.x-2.x-dev » 7.x-3.x-dev
Status: Reviewed & tested by the community » Patch (to be ported)

Committed to 6.x-2.x and 6.x-3.x

I admit I didn't try, as I assume this will not directly apply to 7.x-3.x =)

webel’s picture

Subscribe, very interested in this feature.

dawehner’s picture

Status: Patch (to be ported) » Fixed

Ported and fixed existing issues with the non-static form id.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.