summaryrefslogtreecommitdiff
path: root/indoteknik_custom/models
diff options
context:
space:
mode:
authorstephanchrst <stephanchrst@gmail.com>2022-05-10 17:21:18 +0700
committerstephanchrst <stephanchrst@gmail.com>2022-05-10 17:21:18 +0700
commit803e4f8b3cf9c1d6a43a354023edc1e065f4121e (patch)
treeb462ac26fd679c449f848dc8a2de7fc1b8fe3c5c /indoteknik_custom/models
parent37c91dd605b4ff1acc9941eed549164eb7de2089 (diff)
initial commit 2
Diffstat (limited to 'indoteknik_custom/models')
-rw-r--r--indoteknik_custom/models/__init__.py9
-rw-r--r--indoteknik_custom/models/coupon_program.py20
-rw-r--r--indoteknik_custom/models/product_public_category.py11
-rw-r--r--indoteknik_custom/models/product_template.py19
-rw-r--r--indoteknik_custom/models/x_banner_banner.py20
-rw-r--r--indoteknik_custom/models/x_banner_category.py11
-rw-r--r--indoteknik_custom/models/x_biaya_kirim.py15
-rw-r--r--indoteknik_custom/models/x_manufactures.py34
-rw-r--r--indoteknik_custom/models/x_partner_purchase_order.py13
-rw-r--r--indoteknik_custom/models/x_product_tags.py9
10 files changed, 161 insertions, 0 deletions
diff --git a/indoteknik_custom/models/__init__.py b/indoteknik_custom/models/__init__.py
new file mode 100644
index 00000000..2679aa23
--- /dev/null
+++ b/indoteknik_custom/models/__init__.py
@@ -0,0 +1,9 @@
+from . import x_banner_banner
+from . import x_banner_category
+from . import x_biaya_kirim
+from . import x_manufactures
+from . import coupon_program
+from . import product_public_category
+from . import product_template
+from . import x_partner_purchase_order
+from . import x_product_tags
diff --git a/indoteknik_custom/models/coupon_program.py b/indoteknik_custom/models/coupon_program.py
new file mode 100644
index 00000000..4c839c9f
--- /dev/null
+++ b/indoteknik_custom/models/coupon_program.py
@@ -0,0 +1,20 @@
+from odoo import fields, models
+
+
+class CouponProgram(models.Model):
+ _inherit = "coupon.program"
+
+ x_studio_banner_promo = fields.Binary(string="Banner Promo")
+ x_studio_field_2Ul77 = fields.Binary(string="Icon Program Promo 2")
+ x_studio_field_Ifopn = fields.Binary(string="Icon Program Promo")
+ x_studio_field_xaRIr = fields.One2many(
+ comodel_name="x_banner.banner",
+ inverse_name="x_studio_field_7ppSi",
+ string="New One2many"
+ )
+ x_studio_field_xo3cl = fields.One2many(
+ comodel_name="x_banner.banner",
+ inverse_name="x_studio_field_7ppSi",
+ string="Relasi Banner"
+ )
+ x_studio_image_promo = fields.Binary(string="Image Promo")
diff --git a/indoteknik_custom/models/product_public_category.py b/indoteknik_custom/models/product_public_category.py
new file mode 100644
index 00000000..bb661772
--- /dev/null
+++ b/indoteknik_custom/models/product_public_category.py
@@ -0,0 +1,11 @@
+from odoo import fields, models
+
+class ProductPublicCategory(models.Model):
+ _inherit = "product.public.category"
+
+ x_studio_field_4qhoN = fields.Boolean(string="Tampil di Index")
+ # x_studio_field_5RdHI = fields.Many2many("product.template", string="Product Template")
+ x_studio_field_7bVEO = fields.Many2many("x_banner.banner", string="Banner Index")
+ x_studio_field_BfNp2 = fields.Char(string="Nama Alias")
+ x_studio_field_d1HS4 = fields.Char(string="Name 2")
+ x_studio_field_f54P2 = fields.Char(string="Name 3")
diff --git a/indoteknik_custom/models/product_template.py b/indoteknik_custom/models/product_template.py
new file mode 100644
index 00000000..b2816d3f
--- /dev/null
+++ b/indoteknik_custom/models/product_template.py
@@ -0,0 +1,19 @@
+from odoo import fields, models
+
+
+class ProductTemplate(models.Model):
+ _inherit = "product.template"
+
+ x_studio_field_tGhJR = fields.Many2many('x_product_tags', string="Product Tags")
+ x_manufacture = fields.Many2one(
+ comodel_name="x_manufactures",
+ string="Manufactures"
+ )
+ x_model_product = fields.Char(string="Model Produk")
+ x_product_manufacture = fields.Many2one(
+ comodel_name="x_manufactures",
+ string="Manufacture"
+ )
+ x_lazada = fields.Text(string="Lazada")
+ x_tokopedia = fields.Text(string="Tokopedia")
+
diff --git a/indoteknik_custom/models/x_banner_banner.py b/indoteknik_custom/models/x_banner_banner.py
new file mode 100644
index 00000000..a402789a
--- /dev/null
+++ b/indoteknik_custom/models/x_banner_banner.py
@@ -0,0 +1,20 @@
+from odoo import fields, models
+
+
+class XBannerBanner(models.Model):
+ _name = "x_banner.banner"
+ _description = "Banner"
+ _rec_name = "x_name"
+
+ x_name = fields.Char(string="Name")
+ x_url_banner = fields.Char(string="URL Banner")
+ x_banner_image = fields.Binary(string="Image")
+ x_banner_category = fields.Many2one('x_banner.category', string="Banner Category")
+ # x_banner_tags = fields.Many2many('blog.tag', string="Banner Tags")
+ x_relasi_manufacture = fields.Many2one('x_manufactures', string="Relasi Merek")
+ x_sequence_banner = fields.Integer(string="Sequence")
+ x_status_banner = fields.Selection([
+ ('tayang', 'Tayang'),
+ ('tidak_tayang', 'Tidak Tayang')
+ ], string="Status")
+ x_studio_field_7ppSi = fields.Many2one('coupon.program', string="Coupon Program") \ No newline at end of file
diff --git a/indoteknik_custom/models/x_banner_category.py b/indoteknik_custom/models/x_banner_category.py
new file mode 100644
index 00000000..7c91bd78
--- /dev/null
+++ b/indoteknik_custom/models/x_banner_category.py
@@ -0,0 +1,11 @@
+from odoo import fields, models
+
+
+class XBannerCategory(models.Model):
+ _name = "x_banner.category"
+ _description = "Banner Category"
+ _rec_name = "x_name"
+
+ x_name = fields.Char(string="Name")
+ x_banner_subtitle = fields.Char(string="Sub Title")
+ x_studio_field_KKVl4 = fields.Char(string="URL")
diff --git a/indoteknik_custom/models/x_biaya_kirim.py b/indoteknik_custom/models/x_biaya_kirim.py
new file mode 100644
index 00000000..2869d5f3
--- /dev/null
+++ b/indoteknik_custom/models/x_biaya_kirim.py
@@ -0,0 +1,15 @@
+from odoo import models, fields
+
+
+class XBiayaKirim(models.Model):
+ _name = "x_biaya_kirim"
+ _description = "Biaya Kirim"
+ _rec_name = "x_name"
+
+ x_name = fields.Char(string="Name")
+ x_studio_field_8GRtX = fields.Integer(string="Biaya Kirim")
+ x_studio_field_BSNiA = fields.Boolean(string="Gratis Ongkir?")
+ x_studio_field_CxtaQ = fields.Boolean(string="Minimum KG")
+ x_studio_field_KKYEj = fields.Many2one('vit.kecamatan', string="Kecamatan")
+ x_studio_field_Ww89j = fields.Many2one("delivery.carrier", string="Carrier")
+ x_studio_field_XusU9 = fields.Char(string="Estimasi Kirim")
diff --git a/indoteknik_custom/models/x_manufactures.py b/indoteknik_custom/models/x_manufactures.py
new file mode 100644
index 00000000..8aff7f26
--- /dev/null
+++ b/indoteknik_custom/models/x_manufactures.py
@@ -0,0 +1,34 @@
+from odoo import models, fields
+
+
+class XManufactures(models.Model):
+ _name = 'x_manufactures'
+ _description = "Manufactures"
+ _rec_name = "x_name"
+
+ x_name = fields.Char(string="Name")
+ x_description = fields.Html(string="Description")
+ x_logo_manufacture = fields.Binary(string="Logo Manufacture")
+ x_manufacture_level = fields.Selection([
+ ('prioritas', 'Prioritas'),
+ ('gold', 'Gold'),
+ ('silver', 'Silver')
+ ], string="Manufacture Level")
+ x_manufacture_product = fields.One2many(
+ comodel_name="product.template",
+ inverse_name="x_manufacture",
+ string="Relasi Produk"
+ )
+ x_manufacture_service_center = fields.Many2many("res.partner", string="Service Center")
+ x_manufactures_banners = fields.One2many(
+ comodel_name="x_banner.banner",
+ inverse_name="x_relasi_manufacture",
+ string="Relasi Manufacture Banner"
+ )
+ x_negara_asal = fields.Char(string="Negara Asal")
+ x_produk_aksesoris_sparepart = fields.Selection([
+ ('produk', 'Produk'),
+ ('aksesoris', 'Aksesoris'),
+ ('sparepart', 'Spare Part')
+ ], string="Jenis Produk")
+ x_short_desc = fields.Text(string="Short Description")
diff --git a/indoteknik_custom/models/x_partner_purchase_order.py b/indoteknik_custom/models/x_partner_purchase_order.py
new file mode 100644
index 00000000..6beca5df
--- /dev/null
+++ b/indoteknik_custom/models/x_partner_purchase_order.py
@@ -0,0 +1,13 @@
+from odoo import models, fields
+
+
+class XPartnerPurchaseOrder(models.Model):
+ _name = "x_partner.purchase.order"
+ _description = "Customer Purchase Order"
+ _rec_name = "x_name"
+
+ x_name = fields.Char(string="Nomor PO/Name")
+ x_studio_field_56vPy = fields.Text(string="Keterangan")
+ x_studio_field_EcZlH = fields.Integer(string="Partner ID")
+ x_studio_field_eFt2C = fields.Binary(string="Upload PO")
+ x_studio_field_yDfr5 = fields.Many2one('sale.order', string="Sales Order")
diff --git a/indoteknik_custom/models/x_product_tags.py b/indoteknik_custom/models/x_product_tags.py
new file mode 100644
index 00000000..dac7ffe1
--- /dev/null
+++ b/indoteknik_custom/models/x_product_tags.py
@@ -0,0 +1,9 @@
+from odoo import fields, models
+
+
+class XProductTags(models.Model):
+ _name = "x_product_tags"
+ _description = "Product Tags"
+ _rec_name = "x_name"
+
+ x_name = fields.Char(string="Name")