summaryrefslogtreecommitdiff
path: root/indoteknik_custom
diff options
context:
space:
mode:
authorIT Fixcomart <it@fixcomart.co.id>2023-08-04 07:32:55 +0000
committerIT Fixcomart <it@fixcomart.co.id>2023-08-04 07:32:55 +0000
commite183c3662edc0ac493228c780b42c07eea00cc74 (patch)
tree70e396dc08c26e77a94fbbe22edf07e96df88927 /indoteknik_custom
parentae7bed568731a6fda0156f2b170ba1bad84624be (diff)
parent2421dad6c88900949bc2891bc25006ffa838dd78 (diff)
Merged in production (pull request #86)
Production
Diffstat (limited to 'indoteknik_custom')
-rw-r--r--indoteknik_custom/models/apache_solr.py1
-rwxr-xr-xindoteknik_custom/models/crm_lead.py17
-rw-r--r--indoteknik_custom/views/product_attribute_value.xml3
3 files changed, 13 insertions, 8 deletions
diff --git a/indoteknik_custom/models/apache_solr.py b/indoteknik_custom/models/apache_solr.py
index 6211dfc4..086fb6d0 100644
--- a/indoteknik_custom/models/apache_solr.py
+++ b/indoteknik_custom/models/apache_solr.py
@@ -150,6 +150,7 @@ class ApacheSolr(models.Model):
'search_rank_i': template.search_rank,
'search_rank_weekly_i': template.search_rank_weekly,
'flashsale_id_i': flashsale_data['flashsale_id'] or 0,
+ 'flashsale_tag_s': flashsale_data['flashsale_tag'] or '',
'flashsale_name_s': flashsale_data['flashsale_name'] or '',
'flashsale_base_price_f': flashsale_data['flashsale_base_price'] or 0,
'flashsale_discount_f': flashsale_data['flashsale_discount'] or 0,
diff --git a/indoteknik_custom/models/crm_lead.py b/indoteknik_custom/models/crm_lead.py
index 0cea878a..4efe23c5 100755
--- a/indoteknik_custom/models/crm_lead.py
+++ b/indoteknik_custom/models/crm_lead.py
@@ -80,12 +80,15 @@ class CrmLead(models.Model):
lead.tag_ids = input_tags
if not lead.partner_id:
- continue
- if not lead.user_id or lead.user_id.id == 2 or lead.user_id.id == 25:
- if lead.partner_id.parent_id.user_id:
- salesperson_id = lead.partner_id.parent_id.user_id.id
- elif lead.partner_id.user_id:
- salesperson_id = lead.partner_id.user_id.id
+ salesperson_id = 20
+
+ if not lead.user_id or lead.user_id.id in [2, 25]:
+ partner = lead.partner_id.parent_id or lead.partner_id
+ if partner.user_id and partner.user_id.id not in [2, 25]:
+ salesperson_id = partner.user_id.id
else:
salesperson_id = 20
- lead.user_id = salesperson_id
+
+ lead.user_id = salesperson_id
+
+
diff --git a/indoteknik_custom/views/product_attribute_value.xml b/indoteknik_custom/views/product_attribute_value.xml
index 7c33ba7b..1e84c21a 100644
--- a/indoteknik_custom/views/product_attribute_value.xml
+++ b/indoteknik_custom/views/product_attribute_value.xml
@@ -50,6 +50,7 @@
id="menu_product_attribute_value"
name="Attribute Values"
action="product_attribute_value_action_custom"
- parent="sale.prod_config_main" sequence="6" groups="uom.group_uom"
+ parent="sale.product_menu_catalog"
+ sequence="8"/>
/>
</odoo>