When a new project is created from a successful lead, i would like to trigger a folder creation in dropbox. Is this possible using dropbox intg?
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
- ลูกค้าสัมพันธ์
- e-Commerce
- ระบบบัญชี
- สินค้าคงคลัง
- PoS
- Project
- MRP
คำถามนี้ถูกตั้งค่าสถานะ
1
ตอบกลับ
605
มุมมอง
Hi
Venkatesh,
You can do this by following these steps:
- Step 1: Review Dropbox HTTP Documentation: https://www.dropbox.com/developers/documentation/http/documentation#files-create_folder
- Step 2: Register try an account and get an access token
- Step 3: Inheritance create method on your model project.
import requests
from odoo import models, api
class MyProject(models.Model):
_inherit = "project.project"
@api.model_create_multi
def create(self, vals_list):
res = super().create(vals_list)
... something here
headers = {'Authorization': 'Bearer ', 'Content-Type: application/json'}
data = {"autorename": false, "path": "/your/project/path"}
requests.post(url=https://api.dropboxapi.com/2/files/create_folder_v2, headers=headers, data=data)
return res
Hope to help you!
สนุกกับการพูดคุยนี้ใช่ไหม? เข้าร่วมเลย!
สร้างบัญชีวันนี้เพื่อเพลิดเพลินไปกับฟีเจอร์พิเศษและมีส่วนร่วมกับคอมมูนิตี้ที่ยอดเยี่ยมของเรา!
ลงชื่อRelated Posts | ตอบกลับ | มุมมอง | กิจกรรม | |
---|---|---|---|---|
|
3
มิ.ย. 23
|
5589 |