Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New contact: TEL, EMAIL and ADR cannot be removed together #1044

Closed
caugner opened this issue Apr 7, 2019 · 2 comments · Fixed by #1050
Closed

New contact: TEL, EMAIL and ADR cannot be removed together #1044

caugner opened this issue Apr 7, 2019 · 2 comments · Fixed by #1050

Comments

@caugner
Copy link

caugner commented Apr 7, 2019

Describe the bug

After creating a new contact in Nextcloud Contacts, the initial ADR, EMAIL and TEL can not be removed together, but only one at a time, requiring a reload after each removal.

(I noticed this when trying to create a birthday-only contact.)

To Reproduce
Steps to reproduce the behavior:

  1. Create a new contact and rename (e.g. Test):
BEGIN:VCARD
VERSION:4.0
PRODID:-//Nextcloud Contacts v3.0.5
UID:0ae196d4-bfaa-4756-a436-7ddad29d04a1
REV;VALUE=DATE-AND-OR-TIME:20190407T142905Z
FN:Test
ADR;TYPE=HOME:;;;;;;
EMAIL;TYPE=HOME:
TEL;TYPE="HOME,VOICE":
END:VCARD
  1. Notice that the new contact initially has phone (TEL), email (EMAIL) and address (ADR), as shown in the UI in this order.
  2. Delete the phone (TEL). [It works.]
  3. Delete the email (EMAIL). [Does not work.]
  4. Delete the address (ADR). [Does not work.]
  5. Reload the page. [Phone is gone as expected, but email and address are still there.]
  6. Delete the email (EMAIL). [It works.]
  7. Delete the address (ADR). [Does not work.]
  8. Reload the page again. [Email is gone as expected, but address is still there.]
  9. Delete the address (ADR) [It works.]

Expected behavior
It should be possible to delete phone, email and address in one go.

Actual behavior
Deleting more than one of phone, email and address requires a reload.

Screenshots
n/a

Server configuration

Operating system: Linux

Web server: Apache

Database: MySQL

PHP version: 7.2

Nextcloud version: 15.0.6

Contacts version: 3.0.5

Updated from an older Nextcloud or fresh install: Updated

Signing status:
n/a

List of activated apps:
n/a

Nextcloud configuration:
n/a

Client configuration

Browser: Firefox 66.0.2

Operating system: Linux

CardDAV-clients: n/a

Logs

Web server error log

(omitted)

Nextcloud log

data/nextcloud.log

(omitted)

Browser log

Content Security Policy: The page’s settings blocked the loading of a resource at eval (“script-src”).
Content Security Policy: The page’s settings blocked the loading of a resource at eval (“script-src”).

The network log includes a PUT for each deletion, but all PUTs have the same params and the successful return code 204.


Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.

@rponline
Copy link

rponline commented Apr 8, 2019

I can confirm this behavior on master branch.

It seems that the "localContact" variable in ContactDetails.vue:456 doesn't get updated by Vue.

I tried let localContact = contact instead. This is working.

But then - of course - we lose the abstraction of local and online contact data which brings a lot of other issues (i guess).

@rponline
Copy link

rponline commented Apr 9, 2019

I'm not very experienced in Vue, let's see if my pull request passes the review process :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants