Dream
Time based field update with workflow
I thought about this but I ran into an issue when trying find many, i’ll give your code a shot and see how I can change it.
Highly appreciated!
A bit off topic - I’m currently using some python scripts that scans a folder for CSV files, once 1 is added, it automatically imports the csv file into the database of people/companies.
Will there ever be a way I could do this using workflow?
7 replies
Time based field update with workflow
Thanks @thomast, Feel free to look over the code and recommend changes, if you want. Not a necessity, as it works, and only needs to work as long as the new workflow features aren't released.
I ended up doing this, using a lot of CoPilot. I'm not a coder, just know some basics.
For anyone that might need this in the future. This finds all people in person tab, looks for "expiry" field. If date is more than 6 months away, marks a field as "active", less than 6 months marks as "6 months" and past the date marks as "expired"
7 replies
can't open api imported attachment?
Hey guys. Sorry for the Necro.
I'm still stuggling with this.
I've noticed that the file path when opening the "attached" file is as follows: "/files//twentyscripts/temp_attachments/testcsv.csv?token=" (Note that twentyscripts/temp_attachments/Samuel_Cust_dio.txt is the path that the file is being uploaded from through the python script)
If i attach a file the normal way, the URL for accessing the file is "/files/attachment/fcbb98b1-031e-4b51-bcb0-f596299de025.csv?token="
This might be a me problem but I have no clue how to fix it. Maybe I'm importing it wrong?
Clearly there's some additional changes being made to the file through Twenty, as the name of the file in the URL also changed to an UUID I'd assume?
P.S. Some additional info, the script is basically watches a directory on the twenty instance. Once a csv file is added, that csv is used to create the person or update said person in the twenty database.
But I'd like to attach the original CSV file as an attachment for easy access
8 replies