Build package / php-lint (8.4) (push) Successful in 1m33s
Build package / php-lint (8.5) (push) Successful in 49s
Build package / xml-lint (push) Successful in 13s
Build package / unit-tests (push) Successful in 38s
Build package / package (push) Successful in 1m44s
Workflows now move every overdue card of their source stack. A new migration drops filter_user_ids and filter_label_ids; workflows that had a filter keep running unfiltered. The version goes to 35.1.0 so the migration runs on update. Removed along with the filters: the labels and participants endpoints and their Deck lookups, the dead-filter warnings and markers, and CardService::enrichCards() in the card read. enrichCards() only added labels, assignees and comment counts, and ran a permission check against Deck's frozen uid.
41 lines
1.1 KiB
PHP
41 lines
1.1 KiB
PHP
<?php
|
|
|
|
declare(strict_types=1);
|
|
|
|
namespace OCA\WorkflowDeckAutomation\Migration;
|
|
|
|
use Closure;
|
|
use OCP\DB\ISchemaWrapper;
|
|
use OCP\Migration\IOutput;
|
|
use OCP\Migration\SimpleMigrationStep;
|
|
|
|
/**
|
|
* Drops the assigned-user and label filters. Workflows that had one keep
|
|
* running, now unfiltered — that was an explicit product decision.
|
|
*
|
|
* The columns have to go rather than just be ignored: Entity::fromRow()
|
|
* calls a setter for every selected column, and the Workflow entity no
|
|
* longer has these properties.
|
|
*/
|
|
class Version1001Date20260930120000 extends SimpleMigrationStep {
|
|
public function changeSchema(IOutput $output, Closure $schemaClosure, array $options): ?ISchemaWrapper {
|
|
/** @var ISchemaWrapper $schema */
|
|
$schema = $schemaClosure();
|
|
|
|
if (!$schema->hasTable('wfda_workflows')) {
|
|
return null;
|
|
}
|
|
|
|
$table = $schema->getTable('wfda_workflows');
|
|
$changed = false;
|
|
foreach (['filter_user_ids', 'filter_label_ids'] as $column) {
|
|
if ($table->hasColumn($column)) {
|
|
$table->dropColumn($column);
|
|
$changed = true;
|
|
}
|
|
}
|
|
|
|
return $changed ? $schema : null;
|
|
}
|
|
}
|