Merge pull request #2782 from brkcvn/master

Disabled contacts show in contact area
This commit is contained in:
Burak Civan 2022-11-29 14:53:05 +03:00 committed by GitHub
commit 62ed0a7344
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -310,26 +310,28 @@ export default {
let contacts = response.data.data;
contacts.forEach(function (contact, index) {
this.contact_list.push({
index: index,
key: contact.id,
value: (contact.title) ? contact.title : (contact.display_name) ? contact.display_name : contact.name,
type: (contact.type) ? contact.type : 'customer',
id: contact.id,
name: (contact.title) ? contact.title : (contact.display_name) ? contact.display_name : contact.name,
email: (contact.email) ? contact.email : '',
tax_number: (contact.tax_number) ? contact.tax_number : '',
currency_code: (contact.currency_code) ? contact.currency_code : '',
phone: (contact.phone) ? contact.phone : '',
website: (contact.website) ? contact.website : '',
address: (contact.address) ? contact.address : '',
city: (contact.city) ? contact.city : '',
zip_code: (contact.zip_code) ? contact.zip_code : '',
state: (contact.state) ? contact.state : '',
country: (contact.country) ? contact.country : '',
location: (contact.location) ? contact.location : '',
reference: (contact.reference) ? contact.reference : ''
});
if (contact.enabled) {
this.contact_list.push({
index: index,
key: contact.id,
value: (contact.title) ? contact.title : (contact.display_name) ? contact.display_name : contact.name,
type: (contact.type) ? contact.type : 'customer',
id: contact.id,
name: (contact.title) ? contact.title : (contact.display_name) ? contact.display_name : contact.name,
email: (contact.email) ? contact.email : '',
tax_number: (contact.tax_number) ? contact.tax_number : '',
currency_code: (contact.currency_code) ? contact.currency_code : '',
phone: (contact.phone) ? contact.phone : '',
website: (contact.website) ? contact.website : '',
address: (contact.address) ? contact.address : '',
city: (contact.city) ? contact.city : '',
zip_code: (contact.zip_code) ? contact.zip_code : '',
state: (contact.state) ? contact.state : '',
country: (contact.country) ? contact.country : '',
location: (contact.location) ? contact.location : '',
reference: (contact.reference) ? contact.reference : ''
});
}
}, this);
})
.catch(error => {