mirror of
https://github.com/nextcloud/passman.git
synced 2025-09-10 06:54:25 +08:00
Added folderpath to database
Signed-off-by: fnuesse <felix.nuesse@t-online.de>
This commit is contained in:
parent
0751fbf2c6
commit
89ea63aef4
7 changed files with 25 additions and 5 deletions
|
@ -166,6 +166,11 @@
|
|||
<type>clob</type>
|
||||
<notnull>false</notnull>
|
||||
</field>
|
||||
<field>
|
||||
<name>folderpath</name>
|
||||
<type>clob</type>
|
||||
<notnull>false</notnull>
|
||||
</field>
|
||||
<field>
|
||||
<name>email</name>
|
||||
<type>clob</type>
|
||||
|
|
|
@ -19,7 +19,7 @@ Features:
|
|||
- Import from various password managers (KeePass, LastPass, DashLane, ZOHO, Clipperz.is )
|
||||
For an demo of this app visit [https://demo.passman.cc](https://demo.passman.cc)
|
||||
]]></description>
|
||||
<version>2.2.1</version>
|
||||
<version>2.3.0</version>
|
||||
<licence>agpl</licence>
|
||||
<author homepage="https://github.com/brantje">Sander Brand</author>
|
||||
<author homepage="https://github.com/animalillo">Marcos Zuriaga</author>
|
||||
|
@ -42,8 +42,8 @@ For an demo of this app visit [https://demo.passman.cc](https://demo.passman.cc)
|
|||
<database>pgsql</database>
|
||||
<database min-version="5.5">mysql</database>
|
||||
<lib>openssl</lib>
|
||||
<nextcloud min-version="14" max-version="15"/>
|
||||
<owncloud min-version="14" max-version="15"/>
|
||||
<nextcloud min-version="14" max-version="17"/>
|
||||
<owncloud min-version="14" max-version="17"/>
|
||||
</dependencies>
|
||||
|
||||
<background-jobs>
|
||||
|
|
|
@ -70,7 +70,7 @@ class CredentialController extends ApiController {
|
|||
$credential_id, $custom_fields, $delete_time,
|
||||
$description, $email, $expire_time, $favicon, $files, $guid,
|
||||
$hidden, $label, $otp, $password, $renew_interval,
|
||||
$tags, $url, $username, $vault_id) {
|
||||
$tags, $url, $username, $vault_id, $folderpath) {
|
||||
$credential = array(
|
||||
'credential_id' => $credential_id,
|
||||
'guid' => $guid,
|
||||
|
@ -93,6 +93,7 @@ class CredentialController extends ApiController {
|
|||
'custom_fields' => $custom_fields,
|
||||
'otp' => $otp,
|
||||
'hidden' => $hidden,
|
||||
'folderpath' => $folderpath,
|
||||
|
||||
);
|
||||
|
||||
|
@ -125,7 +126,7 @@ class CredentialController extends ApiController {
|
|||
$credential_id, $custom_fields, $delete_time, $credential_guid,
|
||||
$description, $email, $expire_time, $icon, $files, $guid,
|
||||
$hidden, $label, $otp, $password, $renew_interval,
|
||||
$tags, $url, $username, $vault_id, $revision_created, $shared_key, $acl, $unshare_action, $set_share_key, $skip_revision) {
|
||||
$tags, $url, $username, $vault_id, $revision_created, $shared_key, $acl, $unshare_action, $set_share_key, $skip_revision, $folderpath) {
|
||||
|
||||
|
||||
$storedCredential = $this->credentialService->getCredentialByGUID($credential_guid);
|
||||
|
@ -150,6 +151,7 @@ class CredentialController extends ApiController {
|
|||
'custom_fields' => $custom_fields,
|
||||
'delete_time' => $delete_time,
|
||||
'hidden' => $hidden,
|
||||
'folderpath' => $folderpath,
|
||||
'otp' => $otp,
|
||||
'user_id' => $storedCredential->getUserId()
|
||||
);
|
||||
|
|
|
@ -119,6 +119,8 @@
|
|||
});
|
||||
}
|
||||
});
|
||||
console.log("creds");
|
||||
console.log(_credentials);
|
||||
});
|
||||
};
|
||||
|
||||
|
|
|
@ -68,6 +68,8 @@ use \OCP\AppFramework\Db\Entity;
|
|||
* @method string getOtp()
|
||||
* @method void setHidden(bool $value)
|
||||
* @method string getHidden()
|
||||
* @method void setFolderpath(string $value)
|
||||
* @method string getFolderpath()
|
||||
* @method void setSharedKey(string $value)
|
||||
* @method string getSharedKey()
|
||||
|
||||
|
@ -101,6 +103,7 @@ class Credential extends Entity implements \JsonSerializable{
|
|||
protected $otp;
|
||||
protected $hidden;
|
||||
protected $sharedKey;
|
||||
protected $folderpath;
|
||||
|
||||
public function __construct() {
|
||||
// add types in constructor
|
||||
|
@ -141,6 +144,7 @@ class Credential extends Entity implements \JsonSerializable{
|
|||
'custom_fields' => $this->getCustomFields(),
|
||||
'otp' => $this->getOtp(),
|
||||
'hidden' => $this->getHidden(),
|
||||
'folderpath' => $this->getFolderpath(),
|
||||
'shared_key' => $this->getSharedKey(),
|
||||
];
|
||||
}
|
||||
|
|
|
@ -138,6 +138,7 @@ class CredentialMapper extends Mapper {
|
|||
$credential->setCustomFields($raw_credential['custom_fields']);
|
||||
$credential->setOtp($raw_credential['otp']);
|
||||
$credential->setHidden($raw_credential['hidden']);
|
||||
$credential->setFolderpath($raw_credential['folderpath']);
|
||||
if (isset($raw_credential['shared_key'])) {
|
||||
$credential->setSharedKey($raw_credential['shared_key']);
|
||||
}
|
||||
|
@ -176,6 +177,7 @@ class CredentialMapper extends Mapper {
|
|||
$credential->setCustomFields($raw_credential['custom_fields']);
|
||||
$credential->setOtp($raw_credential['otp']);
|
||||
$credential->setHidden($raw_credential['hidden']);
|
||||
$credential->setFolderpath($raw_credential['folderpath']);
|
||||
$credential->setDeleteTime($raw_credential['delete_time']);
|
||||
|
||||
if (isset($raw_credential['shared_key'])) {
|
||||
|
|
|
@ -5,6 +5,11 @@
|
|||
value="credential.label"></span></div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-xs-4 col-md-3 col-lg-3">{{ 'folderpath' | translate }}</div>
|
||||
<div class="col-xs-8 col-md-9 col-lg-9"><span>{{credential.folderpath}}</span></div>
|
||||
</div>
|
||||
|
||||
<div class="row" ng-show="credential.username">
|
||||
<div class="col-xs-4 col-md-3 col-lg-3">{{ 'account' | translate }}</div>
|
||||
<div class="col-xs-8 col-md-9 col-lg-9"><span credential-field
|
||||
|
|
Loading…
Add table
Reference in a new issue