1
0
mirror of https://github.com/processwire/processwire.git synced 2025-08-17 20:11:46 +02:00

Fix issue processwire/processwire-issues#66 where deleting item from 2 different repeater fields at same time resulted in only item from first repeater being deleted

This commit is contained in:
Ryan Cramer
2016-11-14 07:57:29 -05:00
parent facc671e8d
commit 8b1e5a3c41
3 changed files with 25 additions and 10 deletions

View File

@@ -1057,6 +1057,7 @@ class FieldtypeRepeater extends Fieldtype implements ConfigurableModule {
}
if(in_array($operator, array('*=', '~=', '^=', '$=', '%='))) {
/** @var DatabaseQuerySelectFulltext $ft */
$ft = $this->wire(new DatabaseQuerySelectFulltext($query));
$ft->match($table, $subfield, $operator, $value);
@@ -1221,7 +1222,7 @@ class FieldtypeRepeater extends Fieldtype implements ConfigurableModule {
if($value->has($p)) continue;
// $this->message("Deleted Repeater", Notice::debug);
// delete the repeater page
$this->wire('pages')->delete($p);
$this->wire('pages')->delete($p, $saveOptions);
}
$result = parent::___savePageField($page, $field);