Martino Vallara
    • Create new note
    • Create a note from template
      • Sharing URL Link copied
      • /edit
      • View mode
        • Edit mode
        • View mode
        • Book mode
        • Slide mode
        Edit mode View mode Book mode Slide mode
      • Customize slides
      • Note Permission
      • Read
        • Only me
        • Signed-in users
        • Everyone
        Only me Signed-in users Everyone
      • Write
        • Only me
        • Signed-in users
        • Everyone
        Only me Signed-in users Everyone
      • Engagement control Commenting, Suggest edit, Emoji Reply
    • Invite by email
      Invitee

      This note has no invitees

    • Publish Note

      Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note

      Your note will be visible on your profile and discoverable by anyone.
      Your note is now live.
      This note is visible on your profile and discoverable online.
      Everyone on the web can find and read all notes of this public team.
      See published notes
      Unpublish note
      Please check the box to agree to the Community Guidelines.
      View profile
    • Commenting
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
      • Everyone
    • Suggest edit
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
    • Emoji Reply
    • Enable
    • Versions and GitHub Sync
    • Note settings
    • Note Insights New
    • Engagement control
    • Make a copy
    • Transfer ownership
    • Delete this note
    • Save as template
    • Insert from template
    • Import from
      • Dropbox
      • Google Drive
      • Gist
      • Clipboard
    • Export to
      • Dropbox
      • Google Drive
      • Gist
    • Download
      • Markdown
      • HTML
      • Raw HTML
Menu Note settings Note Insights Versions and GitHub Sync Sharing URL Create Help
Create Create new note Create a note from template
Menu
Options
Engagement control Make a copy Transfer ownership Delete this note
Import from
Dropbox Google Drive Gist Clipboard
Export to
Dropbox Google Drive Gist
Download
Markdown HTML Raw HTML
Back
Sharing URL Link copied
/edit
View mode
  • Edit mode
  • View mode
  • Book mode
  • Slide mode
Edit mode View mode Book mode Slide mode
Customize slides
Note Permission
Read
Only me
  • Only me
  • Signed-in users
  • Everyone
Only me Signed-in users Everyone
Write
Only me
  • Only me
  • Signed-in users
  • Everyone
Only me Signed-in users Everyone
Engagement control Commenting, Suggest edit, Emoji Reply
  • Invite by email
    Invitee

    This note has no invitees

  • Publish Note

    Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note

    Your note will be visible on your profile and discoverable by anyone.
    Your note is now live.
    This note is visible on your profile and discoverable online.
    Everyone on the web can find and read all notes of this public team.
    See published notes
    Unpublish note
    Please check the box to agree to the Community Guidelines.
    View profile
    Engagement control
    Commenting
    Permission
    Disabled Forbidden Owners Signed-in users Everyone
    Enable
    Permission
    • Forbidden
    • Owners
    • Signed-in users
    • Everyone
    Suggest edit
    Permission
    Disabled Forbidden Owners Signed-in users Everyone
    Enable
    Permission
    • Forbidden
    • Owners
    • Signed-in users
    Emoji Reply
    Enable
    Import from Dropbox Google Drive Gist Clipboard
       Owned this note    Owned this note      
    Published Linked with GitHub
    • Any changes
      Be notified of any changes
    • Mention me
      Be notified of mention me
    • Unsubscribe
    # Direct Link - modifiche per mail in lingua ENG da backoffice ## Credenziali backoffice merchant: 001111111 username: TestUser password: password ## TODO - [x] salvare la lingua della mail scelta da utente nel db (tabella `direct_link_init`) - [x] creare nuovo script sql che aggiunga colonna `mailLanguage` in tabella `direct_link_init` - [x] verificare che il nuovo script `282` di phoenix sia corretto: deve aggiungere la colonna, assegnare un default a TUTTI i record (compresi quelli esistenti) - [x] i valori possibili per la colonna `MailLanguage` saranno `ITA_ENG` (default) e `ENG` - [x] Rinominare nel codice i punti in cui la mail language è valorizzata IT oppure EN in ITA_ENG oppure ENG - [x] testare `DirectLinkMailTemplateFactoryTest` per i casi di language `IT` e `EN` - [x] creare template per mail direct link in inglese (test in classe `DirectLinkMailMessageTest`) - [x] in `DirectLinkInit` il `mailLanguage` è assegnato a `ITA_ENG` nel costruttore. Quel valore dovrà invece essergli passato dal mate, che lo recupererà a sua volta dalla UI. - [x] Modificare classe `DirectLinkInitFactory` per fargli creare `DirectLinkInit` col `mailLanguage` letto dal blueprint - [x] modificare UI di pagina insert direct link, aggiungere una checkBox per selezionare la lingua della mail - [x] la classe `CsvDirectLinkInitUploadParser` deve leggere il valore di `MailLanguage` dal csv (quando si lavorerà la storia sull'import da CSV?) - [x] riscrivere test `RealDirectLinkMailManTest.throwExceptionDuringSendingEmail` con mockito - [x] rifattorizzare `RealDirectLinkMailMan`, fare in modo che non occorra creare `DirectLinkMailMessage` e `DispatchedDirectLinkInit` dentro il metodo `sendEmailToCardHolder` - [x] dopo il refactoring di `RealDirectLinkMailMan` eliminare classe test jmock `RealDirectLinkMailManTest` - [x] scrivere test unitari per la view di Direct Link Search? ## Analisi flusso ### Collaboratori `DirectLinkInitController`: controller invocato nella submit del pulsante "send link": /backoffice/directlink/init e nel resend `FactoryForResubmit` <-- /backoffice/directlink/resubmit_action `DirectLinkInitController` usa `DirectLinkInitObserver` per persistere i dati del form che compone la mail. `RealDirectLinkMailMan` : contiene il template del body Tabella: `direct_link_init` dove esiste un campo token utilizzato per individiare il singolo invio e poterlo reinviare. MailTemplate: classe di static che restituiscono i template delle e-mail `DirectLinkInitController ` ## Domande * dove salvare l'informazione della lingua scelta per il direct link? Nella tabella `direct_link_init`? (più flessibile) * come creare un template per le mail piuttosto che un altro? * dove ho l'opzione per re-inviare la mail? * nella pagina di ricerca di direct link * nella pagina di ricerca direct link sono mostrati i directlink inviati via mail. Per ogni record dove vengono letti i dati? Dalla tabella `direct_link_init`? * sì, la query per ecuperare i dati è in `DbDirectLinkInitFinder` * perchè viene usato un token (salvato nella colonna `Token` su `direct_link_init`)? ## Steps di realizzazione * invio via form (EN / default (IT/EN )) * resend * Upload ## Possibili scenari * attuale: ITA_ENG * con DirectLink in Inglese: ITA_ENG, ENG * futuro1: ITA_ENG, ENG, ITA * futuro2: ENG, ITA ## Problemi https://discourse.xpeppers.com/t/eseguire-gli-at-di-phoenix-da-intellij/7602 ## journal 9-03-2020 Oggi con @Edo abbiamo terminato la prima carta relativa alla possibilità di inviare una mail in sola lingua inglese. gli ultimi passi per concludere la carta sono stati: * definita la colonna `MailLanguage` in tabella `direct_link_init` * ridefinito i valori del enum MailLanguage in * `ITA_ENG` (default) * `ENG` * Rinominato tutti i riferimenti a IT e EN rispettivamente in ITA_ENG e ENG. * Modificato i nomi degli ftl in: * direct_link_init_eng.ftl * direct_link_init_ita_eng.ftl * Implementato nella classe DbDirectLinkInitRepository il nuovo campo MailLanguage * Modificato la DirectLinkView in modo che visualizzasse il nuovo option con i valori possibili di lingua. ### Problemi Vari test erano stati "corretti" (con valori hard-coded) temporaneamente per farli diventare verdi ma a distanza di un weekend ci hanno nascosto la mancanza dell'implementazione della parte del repository. --- ['Tutto è bene ciò che finisce bene e l'ultimo chiude la porta'](https://www.youtube.com/watch?v=C8__3Q85_lk) ## journal 10-03-2020 Terminata la carta del resubmit della mail. L'invio era già pronto con l'implementazione della carta precedente. Abbiamo dovuto aggiungere nella tabella degli invii il nuovo campo Mail Language. Terminta la carta dell'invio massivo. Abbiamo garantito la retrocompatibilità del formato CSV (in assenza di colonna o di valore del campo Mail Language viene considerato il valore di default ITA_ENG) e aggiornato il file CSV di esempio con anche i valori validi per il campo mail Language (ITA_ENG e ENG). Fortunamente la libreria CommonsCSV offriva la possibilità configurare il formato CSV permettendo l'assenza di colonne e anche di verificare sia se un colonna è presente e sia se posside un valore. Questi i metodi della libreria utilizzati: ``` CSVFormat.DEFAULT.withAllowMissingColumnNames() next.isSet("MailLanguage") ```

    Import from clipboard

    Paste your markdown or webpage here...

    Advanced permission required

    Your current role can only read. Ask the system administrator to acquire write and comment permission.

    This team is disabled

    Sorry, this team is disabled. You can't edit this note.

    This note is locked

    Sorry, only owner can edit this note.

    Reach the limit

    Sorry, you've reached the max length this note can be.
    Please reduce the content or divide it to more notes, thank you!

    Import from Gist

    Import from Snippet

    or

    Export to Snippet

    Are you sure?

    Do you really want to delete this note?
    All users will lose their connection.

    Create a note from template

    Create a note from template

    Oops...
    This template has been removed or transferred.
    Upgrade
    All
    • All
    • Team
    No template.

    Create a template

    Upgrade

    Delete template

    Do you really want to delete this template?
    Turn this template into a regular note and keep its content, versions, and comments.

    This page need refresh

    You have an incompatible client version.
    Refresh to update.
    New version available!
    See releases notes here
    Refresh to enjoy new features.
    Your user state has changed.
    Refresh to load new user state.

    Sign in

    Forgot password

    or

    By clicking below, you agree to our terms of service.

    Sign in via Facebook Sign in via Twitter Sign in via GitHub Sign in via Dropbox Sign in with Wallet
    Wallet ( )
    Connect another wallet

    New to HackMD? Sign up

    Help

    • English
    • 中文
    • Français
    • Deutsch
    • 日本語
    • Español
    • Català
    • Ελληνικά
    • Português
    • italiano
    • Türkçe
    • Русский
    • Nederlands
    • hrvatski jezik
    • język polski
    • Українська
    • हिन्दी
    • svenska
    • Esperanto
    • dansk

    Documents

    Help & Tutorial

    How to use Book mode

    Slide Example

    API Docs

    Edit in VSCode

    Install browser extension

    Contacts

    Feedback

    Discord

    Send us email

    Resources

    Releases

    Pricing

    Blog

    Policy

    Terms

    Privacy

    Cheatsheet

    Syntax Example Reference
    # Header Header 基本排版
    - Unordered List
    • Unordered List
    1. Ordered List
    1. Ordered List
    - [ ] Todo List
    • Todo List
    > Blockquote
    Blockquote
    **Bold font** Bold font
    *Italics font* Italics font
    ~~Strikethrough~~ Strikethrough
    19^th^ 19th
    H~2~O H2O
    ++Inserted text++ Inserted text
    ==Marked text== Marked text
    [link text](https:// "title") Link
    ![image alt](https:// "title") Image
    `Code` Code 在筆記中貼入程式碼
    ```javascript
    var i = 0;
    ```
    var i = 0;
    :smile: :smile: Emoji list
    {%youtube youtube_id %} Externals
    $L^aT_eX$ LaTeX
    :::info
    This is a alert area.
    :::

    This is a alert area.

    Versions and GitHub Sync
    Get Full History Access

    • Edit version name
    • Delete

    revision author avatar     named on  

    More Less

    Note content is identical to the latest version.
    Compare
      Choose a version
      No search result
      Version not found
    Sign in to link this note to GitHub
    Learn more
    This note is not linked with GitHub
     

    Feedback

    Submission failed, please try again

    Thanks for your support.

    On a scale of 0-10, how likely is it that you would recommend HackMD to your friends, family or business associates?

    Please give us some advice and help us improve HackMD.

     

    Thanks for your feedback

    Remove version name

    Do you want to remove this version name and description?

    Transfer ownership

    Transfer to
      Warning: is a public team. If you transfer note to this team, everyone on the web can find and read this note.

        Link with GitHub

        Please authorize HackMD on GitHub
        • Please sign in to GitHub and install the HackMD app on your GitHub repo.
        • HackMD links with GitHub through a GitHub App. You can choose which repo to install our App.
        Learn more  Sign in to GitHub

        Push the note to GitHub Push to GitHub Pull a file from GitHub

          Authorize again
         

        Choose which file to push to

        Select repo
        Refresh Authorize more repos
        Select branch
        Select file
        Select branch
        Choose version(s) to push
        • Save a new version and push
        • Choose from existing versions
        Include title and tags
        Available push count

        Pull from GitHub

         
        File from GitHub
        File from HackMD

        GitHub Link Settings

        File linked

        Linked by
        File path
        Last synced branch
        Available push count

        Danger Zone

        Unlink
        You will no longer receive notification when GitHub file changes after unlink.

        Syncing

        Push failed

        Push successfully