-
Notifications
You must be signed in to change notification settings - Fork 9
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
P#48327(Task) Make contact selectable #88
Conversation
update unit test
make contact type selectable for form
…806-make-contact-selectable � Conflicts: � plugin/Installer/DatabaseChanges.php
Thanks! Is it possible to cover more lines with tests? |
…806-make-contact-selectable
Hi @jayay, |
@hungnc89 Thank you so much! The test is broken, would you please have a look? |
@jayay oh sorry. I fixed it |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you!
…806-make-contact-selectable � Conflicts: � tests/TestClassFormModelBuilderDBForm.php
Pull Request Test Coverage Report for Build 1920824450
💛 - Coveralls |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The migration doesn't look well and should be changed.
plugin/Installer/DatabaseChanges.php
Outdated
return $this->_pWPDB->query("ALTER TABLE $tableName | ||
ADD COLUMN `contact_type` varchar(255) NULL DEFAULT NULL | ||
"); | ||
return "CREATE TABLE $tableName ( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks unstable.
The best way to add a column to the table would be to add it to the CREATE TABLE
definition in the method getCreateQueryForms
.
Then change this block if ($dbversion == 20) {
to
if ($dbversion == 20) {
dbDelta($this->getCreateQueryForms());
$dbversion = 21;
}
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The new column literally needs to be added in the method getCreateQueryForms
.
@jayay I updated to INSERT IGNORE query |
@jayay sorry. I fixed it |
…806-make-contact-selectable � Conflicts: � languages/onoffice-for-wp-websites-de_DE.po � plugin/FormPostInterest.php � plugin/FormPostOwner.php � plugin/Gui/AdminPageFormSettingsContact.php � plugin/Installer/DatabaseChanges.php
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There's still a comment of mine, that's not resolved.
@hoangdoegs Could you please check the comments and resolve the conflict file? |
…o 13806-make-contact-selectable � Conflicts: � languages/onoffice-for-wp-websites-de_DE.mo
@hungnc89 Could you please improve the code coverage? |
…o 13806-make-contact-selectable
…o 13806-make-contact-selectable
I added more tests. Now the coverage has been improved |
@jayay please help to confirm that the last feedback from Robert is not the WP issue |
@nglelinh The screenshot appears to be correct, but sadly, is in German. It depicts the field kind of contact in the e-mail to be different than the kind of contact of the newly created address, which is the behavior @michaelarnold-dev is referring to here: #88 (comment). |
@jayay Please check again |
No description provided.