Compare commits

...

17 Commits
main ... v1.7.0

Author SHA1 Message Date
Julius Härtl
5e3ddd83fc Bump version to 1.7.0
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2022-05-02 16:43:48 +02:00
Julius Härtl
6b985463d8 Merge pull request #3769 from nextcloud/bugfix/noid/stable24-psalm
Handle qb mapper exception messages properly
2022-04-29 17:28:20 +02:00
Julius Härtl
25e0ae2670 Bump version to 1.7.0-rc.1
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2022-04-29 16:17:24 +02:00
Julius Härtl
614c6fbdba Handle qb mapper exception messages properly
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2022-04-29 15:45:07 +02:00
Julius Härtl
8efe415558 Merge pull request #3765 from nextcloud/backport/3761/stable24
[stable24] Fix text selection in dark mode and modal view
2022-04-29 15:41:06 +02:00
Julius Härtl
f3ad2a3709 Fix text selection in dark mode and modal view
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2022-04-29 09:33:06 +00:00
Julius Härtl
25dd71ba04 Merge pull request #3764 from nextcloud/backport/3762/stable24
[stable24] Adapt the card modal to upstream changes
2022-04-29 11:09:08 +02:00
Julius Härtl
a514e6e168 Adapt modal size to viewer upstream changes
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2022-04-29 08:47:21 +00:00
Julius Härtl
cb5553ea94 Merge pull request #3754 from nextcloud/backport/3745/stable24
[stable24] Add missing indices
2022-04-28 10:10:31 +02:00
Julius Härtl
335ee31c7c Add missing indices
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2022-04-26 16:26:17 +00:00
Julius Härtl
9b4379727d Merge pull request #3736 from nextcloud/backport/3681/stable24
[stable24] Show cards after moving into another list
2022-04-20 18:14:34 +02:00
Julius Härtl
a5fe2f59be Merge pull request #3733 from nextcloud/backport/3692/stable24
[stable24] Fix hidden attachment icon on archived cards
2022-04-20 18:14:13 +02:00
Luka Trovic
1b58f7854e fix: feedback
Signed-off-by: Luka Trovic <luka@nextcloud.com>
2022-04-20 14:24:24 +00:00
Luka Trovic
b6effa468f fix: show card after moving into another list
Signed-off-by: Luka Trovic <luka@nextcloud.com>
2022-04-20 14:24:24 +00:00
Luka Trovic
2b512b88c4 fix: hidden attachment icon on archived cards
Signed-off-by: Luka Trovic <luka@nextcloud.com>
2022-04-20 14:22:23 +00:00
Julius Härtl
5cb61cba90 Merge pull request #3723 from nextcloud/update-stable24-target-versions
Update stable24 target versions
2022-04-19 15:38:37 +02:00
Joas Schilling
0657efe239 Update stable24 target versions
Signed-off-by: Joas Schilling <coding@schilljs.com>
2022-04-14 22:09:00 +02:00
16 changed files with 149 additions and 42 deletions

View File

@@ -19,7 +19,7 @@ jobs:
matrix:
php-versions: ['7.4']
databases: ['sqlite', 'mysql', 'pgsql']
server-versions: ['master']
server-versions: ['stable24']
name: php${{ matrix.php-versions }}-${{ matrix.databases }}-${{ matrix.server-versions }}

View File

@@ -20,7 +20,7 @@ jobs:
matrix:
php-versions: ['7.4', '8.0', '8.1']
databases: ['sqlite', 'mysql', 'pgsql']
server-versions: ['master']
server-versions: ['stable24']
name: php${{ matrix.php-versions }}-${{ matrix.databases }}-${{ matrix.server-versions }}

View File

@@ -12,7 +12,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
ocp-version: [ 'dev-master' ]
ocp-version: [ 'dev-stable24' ]
name: Nextcloud ${{ matrix.ocp-version }}
steps:
- name: Checkout

View File

@@ -1,8 +1,7 @@
# Changelog
All notable changes to this project will be documented in this file.
## 1.7.0-beta.1
## 1.7.0
### Added
@@ -46,6 +45,13 @@ All notable changes to this project will be documented in this file.
- Properly check for the stack AND setting board permissions @juliushaertl [#3670](https://github.com/nextcloud/deck/pull/3670)
- Replace deprecated String.prototype.substr() @CommanderRoot [#3669](https://github.com/nextcloud/deck/pull/3669)
- Dependency updates
- Show cards after moving into another list [#3736](https://github.com/nextcloud/deck/pull/3736)
- Fix paramter replacements when creating deck cards from talk messages @nickvergessen [#3683](https://github.com/nextcloud/deck/pull/3683)
- Fix hidden attachment icon on archived cards [#3733](https://github.com/nextcloud/deck/pull/3733)
- Adapt the card modal to upstream changes [#3764](https://github.com/nextcloud/deck/pull/3764)
- Fix text selection in dark mode and modal view [#3765](https://github.com/nextcloud/deck/pull/3765)
- Add missing indices [#3754](https://github.com/nextcloud/deck/pull/3754)
- Handle qb mapper exception messages properly @juliushaertl [#3769](https://github.com/nextcloud/deck/pull/3769)
## 1.6.0-beta1

View File

@@ -16,7 +16,7 @@
- 🚀 Get your project organized
</description>
<version>1.7.0-beta.1</version>
<version>1.7.0</version>
<licence>agpl</licence>
<author>Julius Härtl</author>
<namespace>Deck</namespace>

View File

@@ -67,13 +67,13 @@ class AttachmentMapper extends DeckMapper implements IPermissionMapper {
$row = $cursor->fetch(PDO::FETCH_ASSOC);
if ($row === false) {
$cursor->closeCursor();
throw new DoesNotExistException('Did expect one result but found none when executing' . $qb);
throw new DoesNotExistException('Did expect one result but found none when executing query: ' . $qb->getSQL());
}
$row2 = $cursor->fetch();
$cursor->closeCursor();
if ($row2 !== false) {
throw new MultipleObjectsReturnedException('Did not expect more than one result when executing' . $query);
throw new MultipleObjectsReturnedException('Did not expect more than one result when executing query: ' . $qb->getSQL());
}
return $this->mapRowToEntity($row);
@@ -89,7 +89,7 @@ class AttachmentMapper extends DeckMapper implements IPermissionMapper {
$row = $cursor->fetch(PDO::FETCH_ASSOC);
if ($row === false) {
$cursor->closeCursor();
throw new DoesNotExistException('Did expect one result but found none when executing' . $qb);
throw new DoesNotExistException('Did expect one result but found none when executing query: ' . $qb->getSQL());
}
$cursor->closeCursor();
return $this->mapRowToEntity($row);

View File

@@ -0,0 +1,99 @@
<?php
declare(strict_types=1);
/**
* @copyright Copyright (c) 2022 Your name <your@email.com>
*
* @author Your name <your@email.com>
*
* @license GNU AGPL version 3 or any later version
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as
* published by the Free Software Foundation, either version 3 of the
* License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*
*/
namespace OCA\Deck\Migration;
use Closure;
use Doctrine\DBAL\Schema\SchemaException;
use OCP\DB\ISchemaWrapper;
use OCP\Migration\IOutput;
use OCP\Migration\SimpleMigrationStep;
class Version10800Date20220422061816 extends SimpleMigrationStep {
/**
* @param IOutput $output
* @param Closure(): ISchemaWrapper $schemaClosure The `\Closure` returns a `ISchemaWrapper`
* @param array $options
* @return null|ISchemaWrapper
* @throws SchemaException
*/
public function changeSchema(IOutput $output, Closure $schemaClosure, array $options): ?ISchemaWrapper {
$schema = $schemaClosure();
$indexAdded = $this->addIndex($schema,
'deck_boards',
'idx_owner_modified',
[ 'owner', 'last_modified' ]
);
$indexAdded = $this->addIndex($schema,
'deck_board_acl',
'idx_participant_type',
[ 'participant', 'type']
) || $indexAdded;
$indexAdded = $this->addIndex($schema,
'deck_cards',
'idx_due_notified_archived_deleted', [
'duedate', 'notified', 'archived', 'deleted_at'
],
) || $indexAdded;
$indexAdded = $this->addIndex($schema,
'deck_cards',
'idx_last_editor', [
'last_editor', 'description_prev'
], [],
// Adding a partial index on the description_prev as it is only used for a NULL check
['lengths' => [null, 1]]
) || $indexAdded;
$indexAdded = $this->addIndex($schema,
'deck_attachment',
'idx_cardid_deletedat',
[ 'card_id', 'deleted_at']
) || $indexAdded;
$indexAdded = $this->addIndex($schema,
'deck_assigned_users',
'idx_card_participant',
[ 'card_id', 'participant']
) || $indexAdded;
return $indexAdded ? $schema : null;
}
private function addIndex(ISchemaWrapper $schema, string $table, string $indexName, array $columns, array $flags = [], array $options = []): bool {
$table = $schema->getTable($table);
if (!$table->hasIndex($indexName)) {
$table->addIndex($columns, $indexName, $flags, $options);
return true;
}
return false;
}
}

View File

@@ -181,6 +181,7 @@ class StackService {
if (array_key_exists($card->id, $labels)) {
$cards[$cardIndex]->setLabels($labels[$card->id]);
}
$cards[$cardIndex]->setAttachmentCount($this->attachmentService->count($card->getId()));
}
$stacks[$stackIndex]->setCards($cards);
}

2
package-lock.json generated
View File

@@ -1,6 +1,6 @@
{
"name": "deck",
"version": "1.7.0-beta1",
"version": "1.7.0",
"lockfileVersion": 2,
"requires": true,
"packages": {

View File

@@ -1,7 +1,7 @@
{
"name": "deck",
"description": "",
"version": "1.7.0-beta.1",
"version": "1.7.0",
"authors": [
{
"name": "Julius Härtl",

View File

@@ -31,6 +31,7 @@
v-if="cardDetailsInModal && $route.params.cardId"
:clear-view-delay="0"
:title="t('deck', 'Card details')"
size="large"
@close="hideModal()">
<div class="modal__content modal__card">
<router-view name="sidebar" />
@@ -154,14 +155,6 @@ export default {
}
}
}
.modal__card {
min-width: 320px;
width: 50vw;
max-width: 800px;
min-height: 200px;
height: 80vh;
}
</style>
<style lang="scss">

View File

@@ -225,6 +225,10 @@ export default {
max-width: calc(100% - #{$modal-padding*2});
padding: 0 14px;
max-height: 100%;
overflow: initial;
user-select: text;
-webkit-user-select: text;
&::v-deep {
.app-sidebar-header {
position: sticky;
@@ -240,6 +244,10 @@ export default {
background-color: var(--color-main-background);
}
.app-sidebar__tab {
overflow: initial;
}
#emptycontent, .emptycontent {
margin-top: 88px;
}

View File

@@ -324,6 +324,12 @@ h5 {
border-left: 1px solid var(--color-main-text);
}
.CodeMirror-selected,
.CodeMirror-line::selection, .CodeMirror-line>span::selection, .CodeMirror-line>span>span::selection {
background: var(--color-primary-element) !important;
color: var(--color-primary-text) !important;
}
.editor-preview,
.editor-statusbar {
display: none;

View File

@@ -135,6 +135,10 @@ export default {
},
activeBoards() {
return this.$store.getters.boards.filter((item) => item.deletedAt === 0 && item.archived === false)
},
boardId() {
return this.card?.boardId ? this.card.boardId : this.$route.params.id
}
},
methods: {
@@ -167,10 +171,13 @@ export default {
},
})
},
moveCard() {
async moveCard() {
this.copiedCard = Object.assign({}, this.card)
this.copiedCard.stackId = this.selectedStack.id
this.$store.dispatch('moveCard', this.copiedCard)
if (parseInt(this.boardId) === parseInt(this.selectedStack.boardId)) {
await this.$store.commit('addNewCard', { ...this.copiedCard })
}
this.modalShow = false
},
async loadStacksFromBoard(board) {

View File

@@ -264,6 +264,9 @@ export default {
Vue.set(state.cards[existingIndex], 'attachmentCount', state.cards[existingIndex].attachmentCount - 1)
}
},
addNewCard(state, card) {
state.cards.push(card)
},
},
actions: {
async addCard({ commit }, card) {

View File

@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
<files psalm-version="4.16.1@aa7e400908833b10c0333861f86cd48c510b60eb">
<files psalm-version="4.22.0@fc2c6ab4d5fa5d644d8617089f012f3bb84b8703">
<file src="lib/Activity/ActivityManager.php">
<TypeDoesNotContainType occurrences="1">
<code>$message !== null</code>
@@ -10,17 +10,6 @@
<code>(int)$subjectParams['comment']</code>
</InvalidScalarArgument>
</file>
<file src="lib/AppInfo/Application.php">
<InvalidArgument occurrences="7">
<code>registerEventListener</code>
<code>registerEventListener</code>
<code>registerEventListener</code>
<code>registerEventListener</code>
<code>registerEventListener</code>
<code>registerEventListener</code>
<code>registerEventListener</code>
</InvalidArgument>
</file>
<file src="lib/Command/UserExport.php">
<ImplementedReturnTypeMismatch occurrences="1">
<code>void</code>
@@ -49,11 +38,6 @@
<code>$this-&gt;userId</code>
</UndefinedThisPropertyFetch>
</file>
<file src="lib/Controller/BoardController.php">
<UndefinedDocblockClass occurrences="1">
<code>\OCP\Deck\DB\Board</code>
</UndefinedDocblockClass>
</file>
<file src="lib/Controller/CommentsApiController.php">
<InvalidScalarArgument occurrences="6">
<code>$cardId</code>
@@ -107,11 +91,6 @@
<code>$cardId</code>
</ParamNameMismatch>
</file>
<file src="lib/Db/AttachmentMapper.php">
<UndefinedVariable occurrences="1">
<code>$query</code>
</UndefinedVariable>
</file>
<file src="lib/Db/BoardMapper.php">
<ParamNameMismatch occurrences="1">
<code>$boardId</code>
@@ -184,6 +163,11 @@
<code>$stackId</code>
</ParamNameMismatch>
</file>
<file src="lib/Migration/Version10800Date20220422061816.php">
<MoreSpecificImplementedParamType occurrences="1">
<code>$schemaClosure</code>
</MoreSpecificImplementedParamType>
</file>
<file src="lib/Notification/Notifier.php">
<RedundantCast occurrences="4">
<code>(string) $l-&gt;t('%s has mentioned you in a comment on "%s".', [$dn, $params[0]])</code>