diff options
| author | Rafi Zadanly <zadanlyr@gmail.com> | 2023-01-26 11:35:49 +0700 |
|---|---|---|
| committer | Rafi Zadanly <zadanlyr@gmail.com> | 2023-01-26 11:35:49 +0700 |
| commit | 36f67ca3cd1140a6e8d4cf537a1ce58d5b5ecdc7 (patch) | |
| tree | d02e7f699195279cafd5a9c443ff55f9d41c47c9 | |
| parent | af46805f7f69b29cc4e0e3ca2e5cf53dd338be5d (diff) | |
| parent | 3e587f4e4fd0dbd8fee3e627ff5665c6b7b78302 (diff) | |
Merge branch 'feature/rest-api' into staging
| -rw-r--r-- | indoteknik_api/controllers/api_v1/banner.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/indoteknik_api/controllers/api_v1/banner.py b/indoteknik_api/controllers/api_v1/banner.py index 18e2e764..1327a749 100644 --- a/indoteknik_api/controllers/api_v1/banner.py +++ b/indoteknik_api/controllers/api_v1/banner.py @@ -15,6 +15,7 @@ class Banner(controller.Controller): type = kw.get('type') limit = int(kw.get('limit', 0)) offset = int(kw.get('offset', 0)) + order = kw.get('order', '') query = [('x_status_banner', '=', 'tayang')] if type: @@ -23,7 +24,7 @@ class Banner(controller.Controller): if manufacture_id: query += [('x_relasi_manufacture', '=', int(manufacture_id))] - banners = request.env['x_banner.banner'].search(query, limit=limit, offset=offset) + banners = request.env['x_banner.banner'].search(query, limit=limit, offset=offset, order=order) data = [] for banner in banners: |
