Browse Source

Fix bake templates so they use current i18n markers.

Fixes #4321
mark_story 11 years ago
parent
commit
9f18e5451b

+ 1 - 1
src/Template/Bake/default/views/index.ctp

@@ -47,7 +47,7 @@ use Cake\Utility\Inflector;
 		echo "\t\t<td class=\"actions\">\n";
 		echo "\t\t\t<?= \$this->Html->link(__('View'), ['action' => 'view', {$pk}]); ?>\n";
 		echo "\t\t\t<?= \$this->Html->link(__('Edit'), ['action' => 'edit', {$pk}]); ?>\n";
-		echo "\t\t\t<?= \$this->Form->postLink(__('Delete'), ['action' => 'delete', {$pk}], ['confirm' => __('Are you sure you want to delete # %s?', {$pk})]); ?>\n";
+		echo "\t\t\t<?= \$this->Form->postLink(__('Delete'), ['action' => 'delete', {$pk}], ['confirm' => __('Are you sure you want to delete # {0}?', {$pk})]); ?>\n";
 		echo "\t\t</td>\n";
 	echo "\t</tr>\n";
 

+ 1 - 1
tests/bake_compare/Controller/Actions.ctp

@@ -56,7 +56,7 @@
 		$bakeArticle = $this->BakeArticles->get($id, [
 			'contain' => ['BakeTags']
 		]);
-		if ($this->request->is(['post', 'put'])) {
+		if ($this->request->is(['patch', 'post', 'put'])) {
 			$bakeArticle = $this->BakeArticles->patchEntity($bakeArticle, $this->request->data);
 			if ($this->BakeArticles->save($bakeArticle)) {
 				$this->Flash->success('The bake article has been saved.');