New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[ADD] agriculture: Agricultural Retail #18
base: 17.0
Are you sure you want to change the base?
Conversation
remove .zip |
7362e6f
to
8db6b96
Compare
@xavieralt In testing we found a problem with the loyalty program and website page so we fixed it after the ready tag. |
b22aebf
to
857d5eb
Compare
a2d124d
to
9184cae
Compare
4c35f38
to
16974a5
Compare
30a0efe
to
7cf799b
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@dhrs-odoo
Thanks for working on this PR.
Here are some review points. also need to reduce the attachments and remove duplicate images.
Cheers!
agriculture/__manifest__.py
Outdated
'website_sale_loyalty', | ||
'knowledge', | ||
'payment_demo', | ||
'pos_sale', | ||
'product_expiry', | ||
'survey', | ||
'crm', | ||
'sale_purchase', | ||
'purchase_requisition', | ||
'theme_enark', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please follow standard sequence
if len(records) > 1: | ||
raise UserError("Only start survey for one Lead/Opportunity.") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if len(records) > 1: | |
raise UserError("Only start survey for one Lead/Opportunity.") |
Not required as server action calls from the button of form view and there is no binding_view_types
if records.x_answer: | ||
raise UserError("Survey alrady done, You can create new Lead/Opportunity and take new survey.") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if records.x_answer: | |
raise UserError("Survey alrady done, You can create new Lead/Opportunity and take new survey.") | |
if records.x_answer: | |
raise UserError("Survey alrady done, You can create new Lead/Opportunity and take new survey.") |
We can hide the button depending on the x_answer.
if not records.x_survey: | ||
raise UserError("Survey not selected.") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
same as above
records.write({'x_answer': user_input.id}) | ||
action = { | ||
'type': 'ir.actions.act_url', | ||
'name': "Survey", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
'name': "Survey", | |
'name': 'Survey', |
agriculture/demo/website_page.xml
Outdated
@@ -0,0 +1,28 @@ | |||
<?xml version='1.0' encoding='UTF-8'?> | |||
<odoo> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
<odoo> | |
<odoo noupdate="1"> |
agriculture/demo/website_page.xml
Outdated
<field name="url">/red-revolution-tomato-seeds</field> | ||
<field name="view_id" ref="red_revolution_tomato_seeds"/> | ||
<field name="is_published" eval="True"/> | ||
<field name="is_in_menu" eval="False"/> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
<field name="is_in_menu" eval="False"/> |
Compute?
</function> | ||
|
||
<function name="write" model="ir.ui.view"> | ||
<value model="ir.ui.view" eval="obj().env['website'].with_context(website_id=obj().env.ref('website.default_website').id).viewref('website.homepage').id"/> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
<value model="ir.ui.view" eval="obj().env['website'].with_context(website_id=obj().env.ref('website.default_website').id).viewref('website.homepage').id"/> | |
<value model="ir.ui.view" eval="obj().env['website'].with_context(website_id=ref('website.default_website')).viewref('website.homepage').id"/> |
?
</function> | ||
|
||
<function name="write" model="ir.ui.view"> | ||
<value model="ir.ui.view" eval="obj().env['website'].with_context(website_id=obj().env.ref('website.default_website').id).viewref('website.contactus').id"/> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
same
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
duplicate image
c499a7c
to
7160048
Compare
Hello @paso-odoo Sir |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
agriculture/__manifest__.py
Outdated
{ | ||
'name': 'Agricultural Retail', | ||
'version': '1.0', | ||
'category': 'Manufacturing', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
'category': 'Manufacturing', | |
'category': ''Retail'', |
<?xml version='1.0' encoding='UTF-8'?> | ||
<odoo> | ||
<record id="action_lead_survey_start" model="ir.actions.server"> | ||
<field name="name">lead survey start</field> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
<field name="name">lead survey start</field> | |
<field name="name">Lead Survey Start</field> |
agriculture/data/ir_model_fields.xml
Outdated
<field name="model_id" ref="crm.model_crm_lead"/> | ||
<field name="field_description">Answer</field> | ||
<field name="relation">survey.user_input</field> | ||
</record> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
</record> | |
</record> |
agriculture/data/ir_model_fields.xml
Outdated
<field name="model_id" ref="account.model_account_move_line"/> | ||
<field name="field_description">Product Story</field> | ||
<field name="related">product_id.x_binary_field_product_template</field> | ||
</record> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
same
<ul style="margin-bottom: 0px;"> | ||
<li> | ||
Create RFQ for product "<font style="color: rgb(57, 132, 198);"><strong>Onion Seeds</strong></font>" for vendor "<span style="color: rgb(57, 132, 198); font-size: 0.9625rem;"><strong>Gloster Organics</strong></span>" | ||
<span style="color: rgb(17, 24, 39); font-size: 0.9625rem;">"</span> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
<span style="color: rgb(17, 24, 39); font-size: 0.9625rem;">"</span> |
<value model="stock.lot" eval="{'lot_id': ref('stock_lot_2'), 'lot_name': obj().env.ref('agriculture.stock_lot_2').name}"/> | ||
</function> | ||
<function name="button_validate" model="stock.picking"> | ||
<value model="stock.picking" eval="obj().env.ref('agriculture.purchase_order_1').group_id.stock_move_ids.picking_id.ids"/> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would use picking_ids directly from purchase_order.
agriculture/demo/res_partner.xml
Outdated
<record id="res_partner_10" model="res.partner"> | ||
<field name="name">Shailendra Rathod(SRA)</field> | ||
<field name="email">sra@example.com</field> | ||
<field name="phone">9876543210</field> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
don't use fictive phone number
agriculture/demo/stock_lot.xml
Outdated
<field name="name">LOT0001</field> | ||
<field name="product_id" ref="product_product_12"/> | ||
<field name="location_id" ref="stock.stock_location_stock"/> | ||
<field name="product_expiry_reminded" eval="True"/> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
<field name="product_expiry_reminded" eval="True"/> |
7160048
to
cf31b9a
Compare
Tailored setup for agricultural retail businesses engaged in B2B and B2C sales of farming products. Point of Sale (POS) stores & website offer categorised items such as seeds, pesticides, plant nutrition, and farming equipment. task- 3460550
Tailored setup for agricultural retail businesses engaged in B2B and B2C sales of farming products. Point of Sale (POS) stores & website offer categorised items such as seeds, pesticides, plant nutrition, and farming equipment. task- 3460550
cf31b9a
to
03a26a6
Compare
03a26a6
to
59c9d2c
Compare
57f17b0
to
97208bc
Compare
Hello @paso-odoo |
Ticket ID: 3460550