inside py
@api.model
def run_sql(self, qry):
self._cr.execute(qry)
_res = self._cr.fetchall()
return _res
qweb<t t-set= "amount" t-value="o.id" ></t>
<t t-foreach="docs" t-as="o">
<t t-set="latest_partner" t-value="o.run_sql('SELECT DISTINCT purchase_request.Name as MaterialRequest,purchase_request.origin as Source Fromm purchase_request INNER JOIN purchase_request_line on purchase_request_line.request_id = purchase_request.id
INNER JOIN purchase_order_purchase_request_line_rel on purchase_order_purchase_request_line_rel.purchase_request_line_id = purchase_request_line.id
where
purchase_order_purchase_request_line_rel.purchase_order_id =%s' % amount)"/>
<span t-esc="latest_partner"/>
<span t-esc="part"/> </t> </t>
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
- CRM
- e-Commerce
- Księgowość
- Zapasy
- PoS
- Project
- MRP
To pytanie dostało ostrzeżenie
2876
Widoki
Podoba Ci się ta dyskusja? Dołącz do niej!
Stwórz konto dzisiaj, aby cieszyć się ekskluzywnymi funkcjami i wchodzić w interakcje z naszą wspaniałą społecznością!
Zarejestruj sięPowiązane posty | Odpowiedzi | Widoki | Czynność | |
---|---|---|---|---|
|
2
lip 23
|
5045 | ||
|
1
cze 23
|
3386 | ||
|
1
kwi 23
|
4266 | ||
|
1
lis 22
|
3005 | ||
|
1
paź 21
|
11556 |