I'm trying to create unattended export with cron /drush / views data export. Everything is fine until I need to pass arguments to a view. Drush command for views data export doesn't provide an option for that, so I guess it's not implemented for now. Would be nice to have this possibility.

Files: 
CommentFileSizeAuthor
#12 views_data_export-a-way-to-set-view-1483118-12.patch1.46 KBSteven Jones
PASSED: [[SimpleTest]]: [MySQL] 0 pass(es). View
#11 views_data_export-a-way-to-set-view-1483118-11.patch1.74 KBSteven Jones
PASSED: [[SimpleTest]]: [MySQL] 0 pass(es). View
#8 views_data_export-a-way-to-set-view-1483118-8.patch1.66 KBSteven Jones
PASSED: [[SimpleTest]]: [MySQL] 92 pass(es). View
#4 views_data_export-allow_args_in_drush-1483118-3.patch1.55 KBblisteringherb
FAILED: [[SimpleTest]]: [MySQL] Unable to apply patch views_data_export-allow_args_in_drush-1483118-3.patch. Unable to apply patch. See the log in the details link for more information. View
#3 views_data_export-arguments-1483118-3.patch2.01 KBmikeryan
FAILED: [[SimpleTest]]: [MySQL] Unable to apply patch views_data_export-arguments-1483118-3.patch. Unable to apply patch. See the log in the details link for more information. View

Comments

amfriedman’s picture

I would add that this is imperative for wide-spread adoption of this module. Contextual arguments are one of the cornerstones of Views, as they assist in DRY programming practices.

Steven Jones’s picture

Version: 7.x-3.0-beta5 » 7.x-3.x-dev
Priority: Normal » Major

Agreed

mikeryan’s picture

Version: 7.x-3.x-dev » 6.x-2.x-dev
Status: Active » Needs review
FileSize
2.01 KB
FAILED: [[SimpleTest]]: [MySQL] Unable to apply patch views_data_export-arguments-1483118-3.patch. Unable to apply patch. See the log in the details link for more information. View

It's really not that challenging, here's a D6 patch...

blisteringherb’s picture

Version: 6.x-2.x-dev » 7.x-3.0-beta6
FileSize
1.55 KB
FAILED: [[SimpleTest]]: [MySQL] Unable to apply patch views_data_export-allow_args_in_drush-1483118-3.patch. Unable to apply patch. See the log in the details link for more information. View

Here's a patch for the D7 version.

Steven Jones’s picture

Version: 7.x-3.0-beta6 » 7.x-3.x-dev

Status: Needs review » Needs work

The last submitted patch, views_data_export-allow_args_in_drush-1483118-3.patch, failed testing.

windmaomao’s picture

anyone can give an example after this patch, what would be the syntax for calling ? thank you very much, yes this is must-have feature.

Steven Jones’s picture

Status: Needs work » Needs review
FileSize
1.66 KB
PASSED: [[SimpleTest]]: [MySQL] 92 pass(es). View

Re-roll

Steven Jones’s picture

Version: 7.x-3.x-dev » 6.x-3.x-dev
Status: Needs review » Patch (to be ported)

Committed to 7.x-3.x. Needs backporting.

Steven Jones’s picture

Version: 6.x-3.x-dev » 6.x-2.x-dev
Steven Jones’s picture

Status: Patch (to be ported) » Needs review
FileSize
1.74 KB
PASSED: [[SimpleTest]]: [MySQL] 0 pass(es). View

Initial attempt at a backport.

Steven Jones’s picture

FileSize
1.46 KB
PASSED: [[SimpleTest]]: [MySQL] 0 pass(es). View

This was the intended patch.

  • Steven Jones committed d80a2b5 on 7.x-4.x
    Issue #1483118 by Steven Jones, blisteringherb, mikeryan: A way to set...
LCM’s picture

Issue summary: View changes

The current implementation of the drush option --arguments only works if the Data Export display is set to "Batch". Otherwise it will not use the given arguments. (See views_data_export.drush.inc)

Is there a reason for this, or could one always read the arguments option an pass it to ->execute_display regardless of the display's batch setting.

kindly,

Lennart

amoebanath’s picture

Version: 6.x-2.x-dev » 7.x-4.x-dev
Status: Needs review » Closed (fixed)

As Drupal 6 nears the end of its life and support period, the 6.x version of Views Data Export will not be supported either. To that end, this issue has been closed, and will not be resolved in the 6.x branch of Views Data Export.

If this issue is still relevant to 7.x branch of Views Data Export, then please re-open and move to a relevant 7.x version.