generated from Kentico/repo-template
-
Notifications
You must be signed in to change notification settings - Fork 1
Code cleanup #20
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
Merged
Merged
Code cleanup #20
Changes from 5 commits
Commits
Show all changes
9 commits
Select commit
Hold shift + click to select a range
778f5d5
fix spacing, comments, remove unused code/files
kentico-ericd 39d8ac7
update README.md, add Usage-Guide.md
kentico-ericd 1cfb590
update UI strings, localization strings, screenshots, and docs
kentico-ericd d5c4cde
set version to prerelease-3
kentico-ericd 6201cfa
fix reference in tests
kentico-ericd b173af7
update installation instruction for prerelease
kentico-ericd 2a66eed
propogate cancellation tokens in ContactsImportMiddleware
kentico-ericd 35a2083
add localization resources
kentico-ericd 97c1e0a
update ImportService namespace
kentico-ericd File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,45 @@ | ||
| # Usage Guide | ||
|
|
||
| ## Screenshot | ||
|
|
||
|  | ||
|
|
||
| ## Importing and deleting contacts | ||
|
|
||
| 1. Open **Digital marketing > Contact importer** application | ||
|
|
||
|  | ||
|
|
||
| 1. Upload your CSV file. See [Supported CSV columns](#supported-csv-columns) for help with formatting the data | ||
| 1. In the **Import mode** field, choose the import mode: | ||
| - Insert: Imports new contacts while skipping existing contacts with matching ContactGUIDs from the CSV file | ||
| - Delete: Deletes existing contacts using the ContactGUIDs from the CSV file | ||
| 1. If you would like to assign newly-imported contacts _and_ existing contacts to a contact group, select the group from the **Assign to contact group** dropdown. You may leave this option empty if you don't wish to assign the contacts to a group | ||
| 1. The **Delimiter** field can generally be skipped as the default character `,` is most common. Change this value if your CSV file uses a different character- common examples are `;` or `\\t` | ||
| 1. Customize the **Batch size** as needed. For instances with limited resources this value should not exeed 5000. A batch size lower than 100 is not recommended | ||
| 1. Click **Run import** to begin the process. Degraded application performance is expected during import | ||
|
|
||
| > [!CAUTION] | ||
| > During the import process, do not: | ||
| > | ||
| > - Close the window | ||
| > - Shut down the application | ||
| > - Modify the CSV file | ||
|
|
||
| ## Supported CSV columns | ||
|
|
||
| | Column | .NET Type | Required | | ||
| | ----------------- | --------- | -------- | | ||
| | ContactGUID | Guid | yes | | ||
| | ContactCreated | DateTime | yes | | ||
| | ContactFirstName | string | no | | ||
| | ContactLastName | string | no | | ||
| | ContactEmail | string | no | | ||
| | ContactAddress1 | string | no | | ||
| | ContactMiddleName | string | no | | ||
|
|
||
| The first row of the CSV file should contain the header names of the individual columns. | ||
| Header validation is performed during the file upload. See the [sample file](https://github.com/Kentico/xperience-by-kentico-contacts-importer/blob/main/data/contact_sample.csv) for an example. | ||
|
|
||
| > [!IMPORTANT] | ||
| > For correct functionality, please make sure to add a newline at the end of the CSV file. |
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 1 addition & 2 deletions
3
src/Kentico.Xperience.Contacts.Importer/Admin/Client/src/entry.tsx
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,2 +1 @@ | ||
| // Exposes components from the module. All added components need to be exported. | ||
| export * from './import/ImportLayoutTemplate'; | ||
| export * from './templates/ImportLayoutTemplate'; |
42 changes: 36 additions & 6 deletions
42
src/Kentico.Xperience.Contacts.Importer/Admin/Client/src/localization/localization.json
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,11 +1,41 @@ | ||
| { | ||
| "integrations": { | ||
| "contactsimporter": { | ||
| "content": { | ||
| "headlines": { | ||
| "main": "Upload/Delete Contacts" | ||
| } | ||
| } | ||
| "contactsimporter": { | ||
| "messages": { | ||
| "noFile": "No file was selected.", | ||
| "errorUploading": "An error occurred while uploading the file.", | ||
| "headersValidated": "CSV headers validated. Starting import.", | ||
| "uploadComplete": "File upload complete.", | ||
| "importComplete": "Import complete.", | ||
| "sendingFile": "Sending file of length", | ||
| "errorReading": "An error occurred while reading the file.", | ||
| "unexpectedFile": "Unexpected file read result type.", | ||
| "serverError": "Unexpected server error.", | ||
| "readComplete": "Completed reading file.", | ||
| "uploadPaused": "Pausing upload while contacts are imported." | ||
| }, | ||
| "content": { | ||
| "headlines": { | ||
| "main": "Import contacts" | ||
| }, | ||
| "labels": { | ||
| "importMode": "Import mode", | ||
| "insert": "Insert", | ||
| "delete": "Delete", | ||
| "contactGroup": "Assign to contact group", | ||
| "uploadFileLine1": "Drag & drop CSV", | ||
| "uploadFileLine2": "or", | ||
| "uploadButton": "Browse", | ||
| "delimiter": "Delimiter", | ||
| "batchSize": "Batch size", | ||
| "run": "Run import" | ||
| }, | ||
| "explanations": { | ||
| "contactGroup": "Assigns all contacts in CSV file to the selected group. Leave empty to skip assignment.", | ||
| "delimiter": "The delimiter for CSV row data items.", | ||
| "batchSize": "The number of records that will be uploaded and processed at a time." | ||
| } | ||
| } | ||
| } | ||
| } | ||
| } |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.