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
- Účetnictví
- Sklad
- PoS
- Project
- MRP
This question has been flagged
3192
Zobrazení
Enjoying the discussion? Don't just read, join in!
Create an account today to enjoy exclusive features and engage with our awesome community!
Přihlásit seRelated Posts | Odpovědi | Zobrazení | Aktivita | |
---|---|---|---|---|
|
2
čvc 23
|
6283 | ||
|
1
čvn 23
|
4316 | ||
|
1
dub 23
|
5037 | ||
|
1
lis 22
|
3737 | ||
|
1
říj 21
|
12071 |