Skip to content

Commit

Permalink
added status and order params to export
Browse files Browse the repository at this point in the history
  • Loading branch information
Tim Whitlock committed Jul 1, 2015
1 parent 786c5f7 commit c9b6a10
Show file tree
Hide file tree
Showing 7 changed files with 180 additions and 4 deletions.
2 changes: 2 additions & 0 deletions src/Console/Command/Generated/ExportAllCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@ protected function configure(){
->addOption('filter','',InputOption::VALUE_REQUIRED,'Comma-separated list of tags to filter subset of assets.',null)
->addOption('index','',InputOption::VALUE_REQUIRED,'Override default lookup key in language pack. Leave blank for auto.',null)
->addOption('fallback','',InputOption::VALUE_REQUIRED,'Fallback locale for untranslated assets, specified as short code. e.g. `en` or `en_GB`',null)
->addOption('order','',InputOption::VALUE_REQUIRED,'Export translations according to asset order',null)
->addOption('status','',InputOption::VALUE_REQUIRED,'Export only translations with a specific status or flag',null)
;
}

Expand Down
2 changes: 2 additions & 0 deletions src/Console/Command/Generated/ExportArchiveCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,8 @@ protected function configure(){
->addOption('index','',InputOption::VALUE_REQUIRED,'Override default lookup key in language pack. Leave blank for auto.',null)
->addOption('namespace','',InputOption::VALUE_REQUIRED,'Override the project name for some language packs that use it as a key prefix',null)
->addOption('fallback','',InputOption::VALUE_REQUIRED,'Fallback locale for untranslated assets, specified as short code. e.g. `en` or `en_GB`',null)
->addOption('order','',InputOption::VALUE_REQUIRED,'Export translations according to asset order',null)
->addOption('status','',InputOption::VALUE_REQUIRED,'Export only translations with a specific status or flag',null)
->addArgument('ext',InputArgument::OPTIONAL,'Target file type specified as a file extension','json')
;
}
Expand Down
2 changes: 2 additions & 0 deletions src/Console/Command/Generated/ExportLocaleCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,8 @@ protected function configure(){
->addOption('index','',InputOption::VALUE_REQUIRED,'Override default lookup key in language pack. Leave blank for auto.',null)
->addOption('namespace','',InputOption::VALUE_REQUIRED,'Override the project name for some language packs that use it as a key prefix',null)
->addOption('fallback','',InputOption::VALUE_REQUIRED,'Fallback locale for untranslated assets, specified as short code. e.g. `en` or `en_GB`',null)
->addOption('order','',InputOption::VALUE_REQUIRED,'Export translations according to asset order',null)
->addOption('status','',InputOption::VALUE_REQUIRED,'Export only translations with a specific status or flag',null)
->addArgument('locale',InputArgument::REQUIRED,'Locale to export, specified as short code. e.g. `en` or `en_GB`',null)
->addArgument('ext',InputArgument::OPTIONAL,'Target file type specified as a file extension','json')
;
Expand Down
2 changes: 2 additions & 0 deletions src/Console/Command/Generated/ExportTemplateCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,8 @@ protected function configure(){
->addOption('index','',InputOption::VALUE_REQUIRED,'Override default lookup key in language pack. Leave blank for auto.',null)
->addOption('namespace','',InputOption::VALUE_REQUIRED,'Override the project name for some language packs that use it as a key prefix',null)
->addOption('fallback','',InputOption::VALUE_REQUIRED,'Fallback locale for untranslated assets, specified as short code. e.g. `en` or `en_GB`',null)
->addOption('order','',InputOption::VALUE_REQUIRED,'Export translations according to asset order',null)
->addOption('status','',InputOption::VALUE_REQUIRED,'Export only translations with a specific status or flag',null)
->addArgument('ext',InputArgument::OPTIONAL,'Target file type specified as a file extension','json')
;
}
Expand Down
2 changes: 1 addition & 1 deletion src/Http/ApiClient.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
*/
class ApiClient extends Client {

const VERSION = '1.0.10';
const VERSION = '1.0.11';

/**
* Factory method to create a new Loco API client.
Expand Down
78 changes: 77 additions & 1 deletion src/Http/Resources/service.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "Loco",
"apiVersion": "1.0.10",
"apiVersion": "1.0.11",
"baseUrl": "https:\/\/localise.biz\/",
"description": "Loco REST API",
"operations": {
Expand Down Expand Up @@ -174,6 +174,25 @@
"description": "Fallback locale for untranslated assets, specified as short code. e.g. `en` or `en_GB`",
"type": "string",
"location": "query"
},
"order": {
"description": "Export translations according to asset order",
"type": "string",
"location": "query",
"enum": [
"created",
"id"
]
},
"status": {
"description": "Export only translations with a specific status or flag",
"type": "string",
"location": "query",
"enum": [
"translated",
"untranslated",
"<flag>"
]
}
},
"errorResponses": [
Expand Down Expand Up @@ -242,6 +261,25 @@
"type": "string",
"location": "query"
},
"order": {
"description": "Export translations according to asset order",
"type": "string",
"location": "query",
"enum": [
"created",
"id"
]
},
"status": {
"description": "Export only translations with a specific status or flag",
"type": "string",
"location": "query",
"enum": [
"translated",
"untranslated",
"<flag>"
]
},
"ext": {
"required": true,
"description": "Target file type specified as a file extension",
Expand Down Expand Up @@ -339,6 +377,25 @@
"type": "string",
"location": "query"
},
"order": {
"description": "Export translations according to asset order",
"type": "string",
"location": "query",
"enum": [
"created",
"id"
]
},
"status": {
"description": "Export only translations with a specific status or flag",
"type": "string",
"location": "query",
"enum": [
"translated",
"untranslated",
"<flag>"
]
},
"locale": {
"required": true,
"description": "Locale to export, specified as short code. e.g. `en` or `en_GB`",
Expand Down Expand Up @@ -442,6 +499,25 @@
"type": "string",
"location": "query"
},
"order": {
"description": "Export translations according to asset order",
"type": "string",
"location": "query",
"enum": [
"created",
"id"
]
},
"status": {
"description": "Export only translations with a specific status or flag",
"type": "string",
"location": "query",
"enum": [
"translated",
"untranslated",
"<flag>"
]
},
"ext": {
"required": true,
"description": "Target file type specified as a file extension",
Expand Down
96 changes: 94 additions & 2 deletions src/Http/Resources/service.php
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
<?php
/**
* Auto-generated with Swizzle at 2015-06-20 15:18:55 +0100
* Auto-generated with Swizzle at 2015-07-01 11:17:38 +0100
*/
return array (
'name' => 'Loco',
'apiVersion' => '1.0.10',
'apiVersion' => '1.0.11',
'baseUrl' => 'https://localise.biz/',
'description' => 'Loco REST API',
'operations' =>
Expand Down Expand Up @@ -217,6 +217,29 @@
'type' => 'string',
'location' => 'query',
),
'order' =>
array (
'description' => 'Export translations according to asset order',
'type' => 'string',
'location' => 'query',
'enum' =>
array (
0 => 'created',
1 => 'id',
),
),
'status' =>
array (
'description' => 'Export only translations with a specific status or flag',
'type' => 'string',
'location' => 'query',
'enum' =>
array (
0 => 'translated',
1 => 'untranslated',
2 => '&lt;flag&gt;',
),
),
),
'errorResponses' =>
array (
Expand Down Expand Up @@ -298,6 +321,29 @@
'type' => 'string',
'location' => 'query',
),
'order' =>
array (
'description' => 'Export translations according to asset order',
'type' => 'string',
'location' => 'query',
'enum' =>
array (
0 => 'created',
1 => 'id',
),
),
'status' =>
array (
'description' => 'Export only translations with a specific status or flag',
'type' => 'string',
'location' => 'query',
'enum' =>
array (
0 => 'translated',
1 => 'untranslated',
2 => '&lt;flag&gt;',
),
),
'ext' =>
array (
'required' => true,
Expand Down Expand Up @@ -411,6 +457,29 @@
'type' => 'string',
'location' => 'query',
),
'order' =>
array (
'description' => 'Export translations according to asset order',
'type' => 'string',
'location' => 'query',
'enum' =>
array (
0 => 'created',
1 => 'id',
),
),
'status' =>
array (
'description' => 'Export only translations with a specific status or flag',
'type' => 'string',
'location' => 'query',
'enum' =>
array (
0 => 'translated',
1 => 'untranslated',
2 => '&lt;flag&gt;',
),
),
'locale' =>
array (
'required' => true,
Expand Down Expand Up @@ -531,6 +600,29 @@
'type' => 'string',
'location' => 'query',
),
'order' =>
array (
'description' => 'Export translations according to asset order',
'type' => 'string',
'location' => 'query',
'enum' =>
array (
0 => 'created',
1 => 'id',
),
),
'status' =>
array (
'description' => 'Export only translations with a specific status or flag',
'type' => 'string',
'location' => 'query',
'enum' =>
array (
0 => 'translated',
1 => 'untranslated',
2 => '&lt;flag&gt;',
),
),
'ext' =>
array (
'required' => true,
Expand Down

0 comments on commit c9b6a10

Please sign in to comment.