OpenEugene / little-help-book-web

Human service resource guide powered by White Bird Clinic
MIT License
6 stars 4 forks source link

Function to export data in the format needed by White Bird for their print publication #142

Closed ArthurSmid closed 3 years ago

ArthurSmid commented 3 years ago

Microsoft Word, mail merge: https://helpdeskgeek.com/office-tips/how-to-create-a-mail-merge-in-microsoft-word/

This allows data substitution inside of Word, similar to what Handlebars does on our website. This is the data structure Heather sent, and we can arrange a meeting to learn more about how to this.

«SubjectSubject» «SubjectSubject_Subcategory» «Service_Name»
Phone: «Main_Phone»
Address: «Physical_Site_Address_1» «Physical_Site_City», «Physical_Site_State», «Physical_Site_Zip» Web Site: «Web_Address» «Service_Location_Email» «Hours_of_Operation» Description: «Description_of_Service» «ADA_Access» Languages Spoken (other than English): «Languages_Spoken» Intended Participants:«Intended_Participants»

«Next Record»

markdav-is commented 3 years ago

@colindavey or @coatsd what would be really useful is taking the airtable data and making an excel file (csv maybe) with columns that exactly match the existing merg-codes. like Main_Phone for example and Hours_Of_Operation. This data transform will save the client a ton of time not having to re-work the template around the raw airtable data.

colindavey commented 3 years ago

Mark suggested to me that my python static-data builder could be leveraged to add this capability, and I agree.

Does an excel file that works for this purpose exist right now? If so, could someone paste it into here?

markdav-is commented 3 years ago

Just sent a followup email to Arthur to get the time line for the publication

markdav-is commented 3 years ago

@colindavey can you share the CSV you are sharing with whitebird and/or a mapping of column names?

colindavey commented 3 years ago

mailmerge_table.append({ 'Category' : category_str, 'Subcategory' : subcategory_str, 'Service Name' : record['name'], 'Phone Number' : record['phone'], 'Physical Address' : record['address'], 'Hours of operation' : record['hours'], 'Description' : record['description'+language_str], 'Wheelchair access (y)' : record['wheelchair'], 'Language Help (y)' : record['languageHelp'], 'Web address' : record['url'], 'Email Address' : record['email'], })

colindavey commented 3 years ago

These were generated on December 2nd. English and Spanish/CSV & Excel. final_book.xlsx final_book_es.xlsx

markdav-is commented 3 years ago

final_book.zip

colindavey commented 3 years ago

Github wouldn't let me attach csv files.