-
Notifications
You must be signed in to change notification settings - Fork 17
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #2444 from DOAJ/feature/4031_journals_added_sheet_…
…duplicated Feature/4031 journals added sheet duplicated
- Loading branch information
Showing
9 changed files
with
199 additions
and
84 deletions.
There are no files selected for viewing
This file contains 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 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
10 changes: 10 additions & 0 deletions
10
portality/migrate/4031_journals_added_sheet_duplicated/README.md
This file contains 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,10 @@ | ||
# 2024-12-25; Issue 4031 - Journals added sheet duplicated | ||
|
||
## Execution | ||
|
||
Run the script to remove all records in DatalogJournalAdded | ||
|
||
python portality/migrate/4031_journals_added_sheet_duplicated/cleanup_4031_journals_added_sheet_duplicated.py | ||
|
||
|
||
* After running the script, manually **BACKUP** and remove all record in google sheet |
Empty file.
15 changes: 15 additions & 0 deletions
15
...rate/4031_journals_added_sheet_duplicated/cleanup_4031_journals_added_sheet_duplicated.py
This file contains 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,15 @@ | ||
from portality.models.datalog_journal_added import DatalogJournalAdded | ||
|
||
|
||
def main(): | ||
# remove all records | ||
query = { | ||
"query": { | ||
"match_all": {} | ||
}, | ||
} | ||
DatalogJournalAdded.delete_by_query(query) | ||
|
||
|
||
if __name__ == '__main__': | ||
main() |
This file contains 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 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 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
Oops, something went wrong.