2019-01-22 12:52:20 +00:00
|
|
|
from __future__ import unicode_literals
|
2016-12-27 06:59:11 +00:00
|
|
|
import frappe
|
|
|
|
|
|
|
|
def execute():
|
|
|
|
# variant must have show_in_website = 0
|
|
|
|
frappe.reload_doctype('Item')
|
|
|
|
frappe.db.sql('''
|
|
|
|
update tabItem set
|
|
|
|
show_variant_in_website = 1,
|
|
|
|
show_in_website = 0
|
|
|
|
where
|
|
|
|
show_in_website=1
|
|
|
|
and ifnull(variant_of, "")!=""''')
|