forked from Rudoo/L10n_ru
Compare commits
2 Commits
Author | SHA1 | Date | |
---|---|---|---|
![]() |
2c894fe74b | ||
![]() |
e07335deaa |
@ -1,6 +1,7 @@
|
|||||||
from odoo import http
|
from odoo import http
|
||||||
from odoo.http import request
|
from odoo.http import request
|
||||||
from datetime import datetime, date
|
from datetime import datetime, date
|
||||||
|
import werkzeug
|
||||||
|
|
||||||
|
|
||||||
class ActRevise(http.Controller):
|
class ActRevise(http.Controller):
|
||||||
@ -13,9 +14,13 @@ class ActRevise(http.Controller):
|
|||||||
partner = request.env.user.partner_id.id
|
partner = request.env.user.partner_id.id
|
||||||
partner_name = request.env.user.partner_id.name
|
partner_name = request.env.user.partner_id.name
|
||||||
company = request.env.user.company_id.id
|
company = request.env.user.company_id.id
|
||||||
company_name = request.env.user.company_id.name
|
# company_name = request.env.user.company_id.name
|
||||||
today = date.today()
|
# today = date.today()
|
||||||
d1 = today.strftime("%d.%m.%y")
|
# d1 = today.strftime("%d.%m.%y")
|
||||||
|
#
|
||||||
|
# new_url=str('AC ' + company +' - ' + partner + ' ' + d1)
|
||||||
|
# if request.httprequest.full_path == '/my/act_revise/a?':
|
||||||
|
# return werkzeug.utils.redirect('/my/act_revise/%s' % new_url)
|
||||||
|
|
||||||
wizard_data = {
|
wizard_data = {
|
||||||
"target_move": "posted",
|
"target_move": "posted",
|
||||||
@ -28,10 +33,14 @@ class ActRevise(http.Controller):
|
|||||||
}
|
}
|
||||||
wizard_record = request.env['general.ledger.act_revise.wizard'].sudo().create(wizard_data)
|
wizard_record = request.env['general.ledger.act_revise.wizard'].sudo().create(wizard_data)
|
||||||
|
|
||||||
action = request.env.ref('l10n_ru_act_rev.action_general_ledger_wizard').read()[0]
|
action_read = request.env.ref('l10n_ru_act_rev.action_general_ledger_wizard').sudo().read()
|
||||||
|
if action_read:
|
||||||
|
action = action_read[0]
|
||||||
action['res_id'] = wizard_record.id
|
action['res_id'] = wizard_record.id
|
||||||
action['context'] = dict(request.env.context)
|
action['context'] = dict(request.env.context)
|
||||||
return request.redirect('/web#action=' + str(action['id']) + '&id=' + str(wizard_record.id) + '&view_type=form')
|
return request.redirect('/web#action=' + str(action['id']) + '&id=' + str(wizard_record.id) + '&view_type=form')
|
||||||
|
else:
|
||||||
|
return request.make_response("Error: Action not found.",[('Content-Type', 'text/plain')],400)
|
||||||
|
|
||||||
# @http.route(['/my/act_revise/<string:act>'], type='http', auth="public", website=True)
|
# @http.route(['/my/act_revise/<string:act>'], type='http', auth="public", website=True)
|
||||||
# def print_report(self):
|
# def print_report(self):
|
||||||
|
@ -5,9 +5,10 @@ import operator
|
|||||||
from odoo.exceptions import UserError
|
from odoo.exceptions import UserError
|
||||||
from odoo import _, api, models
|
from odoo import _, api, models
|
||||||
from odoo.tools import float_is_zero
|
from odoo.tools import float_is_zero
|
||||||
|
import logging
|
||||||
|
|
||||||
class GeneralLedgerReport(models.AbstractModel):
|
class GeneralLedgerReport(models.AbstractModel):
|
||||||
_name = "report.act_revise.general_ledger"
|
_name = "report.l10n_ru_act_rev.general_ledger"
|
||||||
_description = "General Ledger Report"
|
_description = "General Ledger Report"
|
||||||
|
|
||||||
COMMON_ML_FIELDS = [
|
COMMON_ML_FIELDS = [
|
||||||
@ -199,7 +200,7 @@ class GeneralLedgerReport(models.AbstractModel):
|
|||||||
|
|
||||||
def _get_acc_prt_accounts_ids(self, company_id, grouped_by):
|
def _get_acc_prt_accounts_ids(self, company_id, grouped_by):
|
||||||
accounts_domain = [
|
accounts_domain = [
|
||||||
("company_id", "=", company_id),
|
("company_ids", "=", company_id),
|
||||||
] + self._get_account_type_domain(grouped_by)
|
] + self._get_account_type_domain(grouped_by)
|
||||||
acc_prt_accounts = self.env["account.account"].search(accounts_domain)
|
acc_prt_accounts = self.env["account.account"].search(accounts_domain)
|
||||||
return acc_prt_accounts.ids
|
return acc_prt_accounts.ids
|
||||||
@ -208,7 +209,7 @@ class GeneralLedgerReport(models.AbstractModel):
|
|||||||
self, account_ids, company_id, date_from, base_domain, grouped_by, acc_prt=False
|
self, account_ids, company_id, date_from, base_domain, grouped_by, acc_prt=False
|
||||||
):
|
):
|
||||||
accounts_domain = [
|
accounts_domain = [
|
||||||
("company_id", "=", company_id),
|
("company_ids", "=", company_id),
|
||||||
("include_initial_balance", "=", True),
|
("include_initial_balance", "=", True),
|
||||||
]
|
]
|
||||||
if account_ids:
|
if account_ids:
|
||||||
@ -226,7 +227,7 @@ class GeneralLedgerReport(models.AbstractModel):
|
|||||||
self, account_ids, company_id, date_from, fy_start_date, base_domain
|
self, account_ids, company_id, date_from, fy_start_date, base_domain
|
||||||
):
|
):
|
||||||
accounts_domain = [
|
accounts_domain = [
|
||||||
("company_id", "=", company_id),
|
("company_ids", "=", company_id),
|
||||||
("include_initial_balance", "=", False),
|
("include_initial_balance", "=", False),
|
||||||
]
|
]
|
||||||
if account_ids:
|
if account_ids:
|
||||||
@ -256,7 +257,7 @@ class GeneralLedgerReport(models.AbstractModel):
|
|||||||
self, account_ids, company_id, fy_start_date, base_domain
|
self, account_ids, company_id, fy_start_date, base_domain
|
||||||
):
|
):
|
||||||
accounts_domain = [
|
accounts_domain = [
|
||||||
("company_id", "=", company_id),
|
("company_ids", "=", company_id),
|
||||||
("include_initial_balance", "=", False),
|
("include_initial_balance", "=", False),
|
||||||
]
|
]
|
||||||
if account_ids:
|
if account_ids:
|
||||||
@ -930,7 +931,16 @@ class GeneralLedgerReport(models.AbstractModel):
|
|||||||
list_centralized_ml += list(centralized_ml[jnl_id].values())
|
list_centralized_ml += list(centralized_ml[jnl_id].values())
|
||||||
return list_centralized_ml
|
return list_centralized_ml
|
||||||
|
|
||||||
|
@api.model
|
||||||
def _get_report_values(self, docids, data):
|
def _get_report_values(self, docids, data):
|
||||||
|
logging.info(f'@@@@ general_ledger ')
|
||||||
|
logging.info(f'@@@@---------------------------------------------------------------------------------------------- _get_report_values ')
|
||||||
|
logging.info(f'@@@@----------------------------------------------------------------------------------------------' )
|
||||||
|
logging.info(f'@@@@---------------------------------------------------------------------------------------------- ')
|
||||||
|
logging.info(f'@@@@----------------------------------------------------------------------------------------------' )
|
||||||
|
logging.info(f'@@@@---------------------------------------------------------------------------------------------- ')
|
||||||
|
logging.info(f'@@@@---------------------------------------------------------------------------------------------- ')
|
||||||
|
|
||||||
wizard_id = data["wizard_id"]
|
wizard_id = data["wizard_id"]
|
||||||
company = self.env["res.company"].browse(data["company_id"])
|
company = self.env["res.company"].browse(data["company_id"])
|
||||||
company_id = data["company_id"]
|
company_id = data["company_id"]
|
||||||
@ -1004,6 +1014,11 @@ class GeneralLedgerReport(models.AbstractModel):
|
|||||||
account[grouped_by] = False
|
account[grouped_by] = False
|
||||||
del account["list_grouped"]
|
del account["list_grouped"]
|
||||||
general_ledger = sorted(general_ledger, key=lambda k: k["code"])
|
general_ledger = sorted(general_ledger, key=lambda k: k["code"])
|
||||||
|
logging.info(f'@@@@ general_ledger ')
|
||||||
|
logging.info(f'@@@@ general_ledger ')
|
||||||
|
logging.info(f'@@@@ general_ledger {general_ledger}')
|
||||||
|
logging.info(f'@@@@ general_ledger ')
|
||||||
|
logging.info(f'@@@@ general_ledger ')
|
||||||
if not general_ledger:
|
if not general_ledger:
|
||||||
raise UserError(f'Проводок для формирования акта по введенным условиям не найдено.')
|
raise UserError(f'Проводок для формирования акта по введенным условиям не найдено.')
|
||||||
return {
|
return {
|
||||||
|
@ -1,2 +1,3 @@
|
|||||||
id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink
|
id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink
|
||||||
access_general_ledger_act_revise_wizard,general.ledger.act_revise.wizard,model_general_ledger_act_revise_wizard,base.group_user,1,1,1,1
|
access_general_ledger_act_revise_wizard,general.ledger.act_revise.wizard,model_general_ledger_act_revise_wizard,base.group_user,1,1,1,1
|
||||||
|
access_general_ledger_act_revise_wizard_portal,general.ledger.act_revise.wizard.portal,model_general_ledger_act_revise_wizard,base.group_portal,1,1,1,1
|
||||||
|
|
@ -117,7 +117,7 @@ class GeneralLedgerReportWizard(models.TransientModel):
|
|||||||
)
|
)
|
||||||
if self.company_id:
|
if self.company_id:
|
||||||
self.account_ids = self.account_ids.filtered(
|
self.account_ids = self.account_ids.filtered(
|
||||||
lambda a: a.company_id == self.company_id
|
lambda a: a.company_ids == self.company_id
|
||||||
)
|
)
|
||||||
|
|
||||||
def _init_date_from(self):
|
def _init_date_from(self):
|
||||||
@ -158,7 +158,7 @@ class GeneralLedgerReportWizard(models.TransientModel):
|
|||||||
count = self.env["account.account"].search_count(
|
count = self.env["account.account"].search_count(
|
||||||
[
|
[
|
||||||
("account_type", "=", "equity_unaffected"),
|
("account_type", "=", "equity_unaffected"),
|
||||||
("company_id", "=", self.company_id.id),
|
("company_ids", "=", self.company_id.id),
|
||||||
]
|
]
|
||||||
)
|
)
|
||||||
self.not_only_one_unaffected_earnings_account = count != 1
|
self.not_only_one_unaffected_earnings_account = count != 1
|
||||||
@ -181,7 +181,7 @@ class GeneralLedgerReportWizard(models.TransientModel):
|
|||||||
self.onchange_type_accounts_only()
|
self.onchange_type_accounts_only()
|
||||||
else:
|
else:
|
||||||
self.account_ids = self.account_ids.filtered(
|
self.account_ids = self.account_ids.filtered(
|
||||||
lambda a: a.company_id == self.company_id
|
lambda a: a.company_ids == self.company_id
|
||||||
)
|
)
|
||||||
if self.company_id and self.cost_center_ids:
|
if self.company_id and self.cost_center_ids:
|
||||||
self.cost_center_ids = self.cost_center_ids.filtered(
|
self.cost_center_ids = self.cost_center_ids.filtered(
|
||||||
@ -199,9 +199,9 @@ class GeneralLedgerReportWizard(models.TransientModel):
|
|||||||
if not self.company_id:
|
if not self.company_id:
|
||||||
return res
|
return res
|
||||||
else:
|
else:
|
||||||
res["domain"]["account_ids"] += [("company_id", "=", self.company_id.id)]
|
res["domain"]["account_ids"] += [("company_ids", "=", self.company_id.id)]
|
||||||
res["domain"]["account_journal_ids"] += [
|
res["domain"]["account_journal_ids"] += [
|
||||||
("company_id", "=", self.company_id.id)
|
("company_ids", "=", self.company_id.id)
|
||||||
]
|
]
|
||||||
res["domain"]["partner_ids"] += self._get_partner_ids_domain()
|
res["domain"]["partner_ids"] += self._get_partner_ids_domain()
|
||||||
res["domain"]["cost_center_ids"] += [
|
res["domain"]["cost_center_ids"] += [
|
||||||
@ -240,7 +240,7 @@ class GeneralLedgerReportWizard(models.TransientModel):
|
|||||||
def onchange_type_accounts_only(self):
|
def onchange_type_accounts_only(self):
|
||||||
"""Handle receivable/payable accounts only change."""
|
"""Handle receivable/payable accounts only change."""
|
||||||
if self.receivable_accounts_only or self.payable_accounts_only:
|
if self.receivable_accounts_only or self.payable_accounts_only:
|
||||||
domain = [("company_id", "=", self.company_id.id)]
|
domain = [("company_ids", "=", self.company_id.id)]
|
||||||
if self.receivable_accounts_only and self.payable_accounts_only:
|
if self.receivable_accounts_only and self.payable_accounts_only:
|
||||||
domain += [
|
domain += [
|
||||||
("account_type", "in", ("asset_receivable", "liability_payable"))
|
("account_type", "in", ("asset_receivable", "liability_payable"))
|
||||||
@ -267,7 +267,7 @@ class GeneralLedgerReportWizard(models.TransientModel):
|
|||||||
record.unaffected_earnings_account = self.env["account.account"].search(
|
record.unaffected_earnings_account = self.env["account.account"].search(
|
||||||
[
|
[
|
||||||
("account_type", "=", "equity_unaffected"),
|
("account_type", "=", "equity_unaffected"),
|
||||||
("company_id", "=", record.company_id.id),
|
("company_ids", "=", record.company_id.id),
|
||||||
]
|
]
|
||||||
)
|
)
|
||||||
|
|
||||||
@ -306,7 +306,6 @@ class GeneralLedgerReportWizard(models.TransientModel):
|
|||||||
('date', '<=', self.date_to),
|
('date', '<=', self.date_to),
|
||||||
('date', '>=', self.date_from)
|
('date', '>=', self.date_from)
|
||||||
])
|
])
|
||||||
logging.warning(f'account_data {account_data}')
|
|
||||||
if self.target_move == 'posted' and not account_data.filtered(lambda p: p.parent_state == 'posted') or not account_data:
|
if self.target_move == 'posted' and not account_data.filtered(lambda p: p.parent_state == 'posted') or not account_data:
|
||||||
raise UserError(f'Проводок для формирования акта по введенным условиям не найдено.')
|
raise UserError(f'Проводок для формирования акта по введенным условиям не найдено.')
|
||||||
return {
|
return {
|
||||||
|
@ -19,10 +19,10 @@
|
|||||||
<!-- <field name="date_range_id" />-->
|
<!-- <field name="date_range_id" />-->
|
||||||
<field name="date_from" />
|
<field name="date_from" />
|
||||||
<field name="date_to" />
|
<field name="date_to" />
|
||||||
<field name="fy_start_date" invisible="1" />
|
<field name="fy_start_date" invisible="1" /><!-- reason: need-->
|
||||||
<field name="target_move" widget="radio" />
|
<field name="target_move" widget="radio" />
|
||||||
</group>
|
</group>
|
||||||
<group name="other_filters" invisible="1">
|
<group name="other_filters" invisible="1"><!-- reason: need-->
|
||||||
<field name="grouped_by" />
|
<field name="grouped_by" />
|
||||||
<field name="centralize" />
|
<field name="centralize" />
|
||||||
<field name="hide_account_at_0" />
|
<field name="hide_account_at_0" />
|
||||||
@ -30,7 +30,7 @@
|
|||||||
<field name="show_cost_center" />
|
<field name="show_cost_center" />
|
||||||
</group>
|
</group>
|
||||||
</group>
|
</group>
|
||||||
<notebook invisible="1">
|
<notebook invisible="1"><!-- reason: need-->
|
||||||
<page string="Filter accounts">
|
<page string="Filter accounts">
|
||||||
<group name="account_filter" col="4">
|
<group name="account_filter" col="4">
|
||||||
<label for="account_ids" colspan="4" />
|
<label for="account_ids" colspan="4" />
|
||||||
@ -94,10 +94,7 @@
|
|||||||
</notebook>
|
</notebook>
|
||||||
</div>
|
</div>
|
||||||
<div invisible= "not_only_one_unaffected_earnings_account==False" >
|
<div invisible= "not_only_one_unaffected_earnings_account==False" >
|
||||||
<field
|
<field name="not_only_one_unaffected_earnings_account" invisible="1"/><!-- reason: need-->
|
||||||
name="not_only_one_unaffected_earnings_account"
|
|
||||||
invisible="1"
|
|
||||||
/>
|
|
||||||
<group />
|
<group />
|
||||||
<h4>
|
<h4>
|
||||||
General Ledger can be computed only if selected company have
|
General Ledger can be computed only if selected company have
|
||||||
|
BIN
l10n_ru_attorney/models/__init__.pyc
Normal file
BIN
l10n_ru_attorney/models/__init__.pyc
Normal file
Binary file not shown.
@ -9,3 +9,11 @@ class HrEmployee(models.Model):
|
|||||||
inn = fields.Char(string=_("ИНН"))
|
inn = fields.Char(string=_("ИНН"))
|
||||||
pass_kem = fields.Char(string=_("Кем выдан паспорт"))
|
pass_kem = fields.Char(string=_("Кем выдан паспорт"))
|
||||||
pass_date = fields.Date(string=_('Дата выдачи паспорта'))
|
pass_date = fields.Date(string=_('Дата выдачи паспорта'))
|
||||||
|
|
||||||
|
class HrEmployeePublic(models.Model):
|
||||||
|
_inherit = 'hr.employee.public'
|
||||||
|
|
||||||
|
inn = fields.Char(related='employee_id.inn', readonly = True)
|
||||||
|
pass_kem = fields.Char(related='employee_id.pass_kem', readonly = True)
|
||||||
|
pass_date = fields.Date(related='employee_id.pass_date', readonly = True)
|
||||||
|
|
||||||
|
@ -5,7 +5,7 @@
|
|||||||
string="Доверенность"
|
string="Доверенность"
|
||||||
id="action_report_consent"
|
id="action_report_consent"
|
||||||
model="base.consent"
|
model="base.consent"
|
||||||
report_type="qweb-html"
|
report_type="qweb-pdf"
|
||||||
name="l10n_ru_attorney.report_consent"
|
name="l10n_ru_attorney.report_consent"
|
||||||
file="l10n_ru_attorney.report_consent"
|
file="l10n_ru_attorney.report_consent"
|
||||||
/>
|
/>
|
||||||
@ -14,7 +14,7 @@
|
|||||||
<field name="name">Доверенность</field>
|
<field name="name">Доверенность</field>
|
||||||
<field name="model">base.consent</field>
|
<field name="model">base.consent</field>
|
||||||
<field name="print_report_name">(u'Доверенность - %s.pdf' % (object.name))</field>
|
<field name="print_report_name">(u'Доверенность - %s.pdf' % (object.name))</field>
|
||||||
<field name="report_type">qweb-html</field>
|
<field name="report_type">qweb-pdf</field>
|
||||||
<field name="report_name">l10n_ru_attorney.report_consent</field>
|
<field name="report_name">l10n_ru_attorney.report_consent</field>
|
||||||
</record>
|
</record>
|
||||||
|
|
||||||
@ -35,275 +35,102 @@
|
|||||||
</record>
|
</record>
|
||||||
|
|
||||||
<template id="l10n_ru_attorney.report_consent">
|
<template id="l10n_ru_attorney.report_consent">
|
||||||
<t t-call="web.html_container">
|
<t t-call="web.basic_layout">
|
||||||
<t t-foreach="docs" t-as="o">
|
<t t-foreach="docs" t-as="o">
|
||||||
<div class="page">
|
<div class="page">
|
||||||
<style type="text/css">
|
<style type="text/css">
|
||||||
/*----------------Invoice classes-------------------*/
|
/*----------------Invoice classes-------------------*/
|
||||||
p {
|
body { background: #ffffff; font-family: Arial; font-size: 8pt; font-style: normal; }
|
||||||
font-size: 13px;
|
p { font-family: Arial; font-size: 13px; }
|
||||||
}
|
.tb-numbers { width: 600px; }
|
||||||
.tb-numbers {
|
.tb-numbers td { padding: 4px 10px; font-family: Arial; }
|
||||||
width: 600px;
|
.tb-numbers label {display: inline-block;padding: 4px 0px 0px;line-height: 20px;font-size:
|
||||||
}
|
12px;font-family: Arial;}
|
||||||
.tb-numbers td {
|
.tb-numbers input {width: 100px;}
|
||||||
padding: 4px 10px;
|
.company-info {width: 100%;margin: 20px auto;}
|
||||||
}
|
.company-info td {padding: 5px 2px;font-size: 13px;font-family: Arial;}
|
||||||
.tb-numbers label {
|
.approver-info {width: 100%;margin: 20px auto;text-align: center;}
|
||||||
display: inline-block;
|
.approver-info .director {font-weight: bold;}
|
||||||
padding: 4px 0px 0px;
|
.approver-info .title {font-weight: bold;font-size: 18px;padding-bottom: 20px;}
|
||||||
line-height: 20px;
|
.approver-info .signature {font-size: 11px;padding-top: 40px;}
|
||||||
font-size: 12px;
|
.actDate {float: right;}
|
||||||
}
|
.actDescription {width: 100%;padding-top: 30px;}
|
||||||
.tb-numbers input {
|
.act-info p {font-weight: bold;}
|
||||||
width: 100px;
|
.buyer-box {width: 50%;}
|
||||||
}
|
.buyer-box table {width: 100%;}
|
||||||
.company-info {
|
.buyer-box .tb-info {width: 310px;}
|
||||||
width: 100%;
|
.buyer-box .tb-info td {padding: 2px 5px;}
|
||||||
margin: 20px auto;
|
.buyer-box .tb-info td.lbl {text-align: right;font-weight: bold;width: 40%;}
|
||||||
}
|
.tb-invoice {width: 100%;border-collapse: collapse;}
|
||||||
.company-info td {
|
.tb-invoice td {padding: 2px 4px;border: 1px solid #ccc;font-size: 11px;text-align:
|
||||||
padding: 5px 2px;
|
center;font-family: Arial;}
|
||||||
font-size: 13px;
|
.tb-invoice td input {border: 0px;text-align: center;}
|
||||||
}
|
.tb-invoice .head td {background: #f3f3f3;font-weight: bold;}
|
||||||
.approver-info {
|
.deleteRow {color: Red;font-size: 13px;font-weight: bold;cursor: pointer;}
|
||||||
width: 100%;
|
.tb-act {width: 100%;border-collapse: collapse;margin-bottom: 15px;clear: both;margin: 20px
|
||||||
margin: 20px auto;
|
0px 10px 0px;}
|
||||||
text-align: center
|
.tb-act td {padding: 2px 4px;border: 1px solid #ccc;font-size:
|
||||||
}
|
13px;text-align:center;font-family: Arial;}
|
||||||
.approver-info .director {
|
.tb-act td input {border: 0px;text-align:center;}
|
||||||
font-weight: bold;
|
.tb-act .head td {background:#f3f3f3;}
|
||||||
}
|
.tb-act td .deleteActRow {color: Red;font-size :13 px;font-weight:bold;cursor:pointer;}
|
||||||
.approver-info .title {
|
.description {font-size :12 px;text-align :justify;text-indent :1.5 em;white-space
|
||||||
font-weight: bold;
|
:pre-wrap;}
|
||||||
font-size: 18px;
|
.tb-total {width :405 px;margin: 30px 0px 20px auto;}
|
||||||
padding-bottom: 20px;
|
.tb-total td {padding: 2px 5px;font-size :12 px;}
|
||||||
}
|
.tb-total td.lbl {font-weight:bold;text-align:right;}
|
||||||
.approver-info .signature {
|
.tb-total td.val {border :1 px solid #ccc ;min-width :50 px ;}
|
||||||
font-size: 11px;
|
.tb-total td input {padding :1 px ;font-size :11 px ;}
|
||||||
padding-top: 40px;
|
.act-link-addrow-container {margin-bottom :30 px ;}
|
||||||
}
|
.link-addrow, .act-link-addrow {text-decoration:none !important ;border-bottom :1 px dashed
|
||||||
.actDate {
|
#777 ;font-size :13 px ;}
|
||||||
float: right
|
.btn-box {margin: 10px 0px;}
|
||||||
}
|
.signer-box {width: 400px;}
|
||||||
.actDescription {
|
.buyer-box .tb-info {width: 400px;}
|
||||||
width: 100%;
|
.btn-box a {font-size: 14px;margin-left: 10px;}
|
||||||
padding-top: 30px
|
.podpis-box {clear: both;display: inline-block;font-size: 11px;margin: 20px auto 30px;width:
|
||||||
}
|
100%;}
|
||||||
.act-info p {
|
.tb-podpis {width: 100%;}
|
||||||
font-weight: bold;
|
.podpis-box .box1 {float: left;width: 48%;}
|
||||||
}
|
|
||||||
.buyer-box {
|
|
||||||
width: 50%;
|
|
||||||
}
|
|
||||||
.buyer-box table {
|
|
||||||
width: 100%;
|
|
||||||
}
|
|
||||||
.buyer-box .tb-info {
|
|
||||||
width: 310px;
|
|
||||||
}
|
|
||||||
.buyer-box .tb-info td {
|
|
||||||
padding: 2px 5px;
|
|
||||||
}
|
|
||||||
.buyer-box .tb-info td.lbl {
|
|
||||||
text-align: right;
|
|
||||||
font-weight: bold;
|
|
||||||
width: 40%;
|
|
||||||
}
|
|
||||||
.tb-invoice {
|
|
||||||
width: 100%;
|
|
||||||
border-collapse: collapse;
|
|
||||||
}
|
|
||||||
.tb-invoice td {
|
|
||||||
padding: 2px 4px;
|
|
||||||
border: 1px solid #ccc;
|
|
||||||
font-size: 11px;
|
|
||||||
text-align: center;
|
|
||||||
}
|
|
||||||
.tb-invoice td input {
|
|
||||||
border: 0px;
|
|
||||||
text-align: center;
|
|
||||||
}
|
|
||||||
.tb-invoice .head td {
|
|
||||||
background: #f3f3f3;
|
|
||||||
font-weight: bold;
|
|
||||||
}
|
|
||||||
.deleteRow {
|
|
||||||
color: Red;
|
|
||||||
font-size: 13px;
|
|
||||||
font-weight: bold;
|
|
||||||
cursor: pointer;
|
|
||||||
}
|
|
||||||
.tb-act {
|
|
||||||
width: 100%;
|
|
||||||
border-collapse: collapse;
|
|
||||||
margin-bottom: 15px;
|
|
||||||
clear: both;
|
|
||||||
margin: 20px 0px 10px 0px;
|
|
||||||
}
|
|
||||||
.tb-act td {
|
|
||||||
padding: 2px 4px;
|
|
||||||
border: 1px solid #ccc;
|
|
||||||
font-size: 13px;
|
|
||||||
text-align: center;
|
|
||||||
}
|
|
||||||
.tb-act td input {
|
|
||||||
border: 0px;
|
|
||||||
text-align: center;
|
|
||||||
}
|
|
||||||
.tb-act .head td {
|
|
||||||
background: #f3f3f3;
|
|
||||||
}
|
|
||||||
.tb-act td .deleteActRow {
|
|
||||||
color: Red;
|
|
||||||
font-size: 13px;
|
|
||||||
font-weight: bold;
|
|
||||||
cursor: pointer;
|
|
||||||
}
|
|
||||||
.description {
|
|
||||||
font-size: 12px;
|
|
||||||
text-align: justify;
|
|
||||||
text-indent: 1.5em;
|
|
||||||
white-space: pre-wrap;
|
|
||||||
}
|
|
||||||
.tb-total {
|
|
||||||
width: 405px;
|
|
||||||
margin: 30px 0px 20px auto;
|
|
||||||
}
|
|
||||||
.tb-total td {
|
|
||||||
padding: 2px 5px;
|
|
||||||
font-size: 12px;
|
|
||||||
}
|
|
||||||
.tb-total td.lbl {
|
|
||||||
font-weight: bold;
|
|
||||||
text-align: right;
|
|
||||||
}
|
|
||||||
.tb-total td.val {
|
|
||||||
border: 1px solid #ccc;
|
|
||||||
min-width: 50px;
|
|
||||||
}
|
|
||||||
.tb-total td input {
|
|
||||||
padding: 1px;
|
|
||||||
font-size: 11px;
|
|
||||||
}
|
|
||||||
.act-link-addrow-container {
|
|
||||||
margin-bottom: 30px;
|
|
||||||
}
|
|
||||||
.link-addrow,
|
|
||||||
.act-link-addrow {
|
|
||||||
text-decoration: none !important;
|
|
||||||
border-bottom: 1px dashed #777;
|
|
||||||
font-size: 13px;
|
|
||||||
}
|
|
||||||
.btn-box {
|
|
||||||
margin: 10px 0px;
|
|
||||||
}
|
|
||||||
.signer-box {
|
|
||||||
width: 400px;
|
|
||||||
}
|
|
||||||
.buyer-box .tb-info {
|
|
||||||
width: 400px;
|
|
||||||
}
|
|
||||||
.btn-box a {
|
|
||||||
font-size: 14px;
|
|
||||||
margin-left: 10px;
|
|
||||||
}
|
|
||||||
.podpis-box {
|
|
||||||
clear: both;
|
|
||||||
display: inline-block;
|
|
||||||
font-size: 11px;
|
|
||||||
margin: 20px auto 30px;
|
|
||||||
width: 100%;
|
|
||||||
}
|
|
||||||
.tb-podpis {
|
|
||||||
width: 100%;
|
|
||||||
}
|
|
||||||
.podpis-box .box1 {
|
|
||||||
float: left;
|
|
||||||
width: 48%;
|
|
||||||
}
|
|
||||||
/*SIGNATURES PLACE BEGIN*/
|
|
||||||
.signatures-box {
|
|
||||||
clear: both;
|
|
||||||
display: inline-block;
|
|
||||||
font-size: 11px;
|
|
||||||
margin: 20px auto 30px;
|
|
||||||
width: 100%;
|
|
||||||
}
|
|
||||||
.signatures-box .box1 {
|
|
||||||
float: left;
|
|
||||||
width: 35%;
|
|
||||||
}
|
|
||||||
.signatures-box .box2 {
|
|
||||||
float: right;
|
|
||||||
width: 35%;
|
|
||||||
}
|
|
||||||
.signatures-box .box1 table,
|
|
||||||
.signatures-box .box2 table {
|
|
||||||
width: 100%;
|
|
||||||
}
|
|
||||||
.signatures-box table td {
|
|
||||||
padding: 3px;
|
|
||||||
text-align: center;
|
|
||||||
}
|
|
||||||
/*SIGNATURES PLACE END*/
|
|
||||||
.podpis-box .box2 {
|
|
||||||
float: right;
|
|
||||||
width: 48%;
|
|
||||||
}
|
|
||||||
.podpis-box .box1 table,
|
|
||||||
.podpis-box .box2 table {
|
|
||||||
width: 100%;
|
|
||||||
}
|
|
||||||
.podpis-box table td {
|
|
||||||
padding: 3px;
|
|
||||||
text-align: center;
|
|
||||||
}
|
|
||||||
.special-line {
|
|
||||||
border-bottom: 1px solid #000;
|
|
||||||
display: block;
|
|
||||||
line-height: 22px !important;
|
|
||||||
text-align: center;
|
|
||||||
}
|
|
||||||
.w120 {
|
|
||||||
width: 120px;
|
|
||||||
}
|
|
||||||
.w130 {
|
|
||||||
width: 130px;
|
|
||||||
}
|
|
||||||
.note {
|
|
||||||
font-size: 11px !important;
|
|
||||||
}
|
|
||||||
.l {
|
|
||||||
text-align: left !important;
|
|
||||||
}
|
|
||||||
.r {
|
|
||||||
text-align: right !important;
|
|
||||||
}
|
|
||||||
.c {
|
|
||||||
text-align: center !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
/*SIGNATURES PLACE BEGIN*/
|
||||||
|
.signatures-box {clear: both;display: inline-block;font-size: 11px;margin: 20px auto
|
||||||
|
30px;width: 100%;}
|
||||||
|
.signatures-box .box1 {float: left;width: 35%;}
|
||||||
|
.signatures-box .box2 {float: right;width: 35%;}
|
||||||
|
.signatures-box .box1 table,
|
||||||
|
.signatures-box .box2 table { width: 100%; }
|
||||||
|
.signatures-box table td { padding: 3px; text-align: center; }
|
||||||
|
|
||||||
|
/*SIGNATURES PLACE END*/
|
||||||
|
.podpis-box .box2 { float: right; width: 48%; }
|
||||||
|
.podpis-box .box1 table,
|
||||||
|
.podpis-box .box2 table { width: 100%; }
|
||||||
|
.podpis-box table td { padding: 3px; text-align: center; }
|
||||||
|
.special-line { border-bottom: 1px solid #000; display: block; line-height: 22px
|
||||||
|
!important;text-align: center; }
|
||||||
|
.w120 { width: 120px; }
|
||||||
|
.w130 { width: 130px; }
|
||||||
|
.note { font-size: 11px !important; }
|
||||||
|
.l { text-align: left !important; }
|
||||||
|
.r { text-align: right !important; }
|
||||||
|
.c { text-align: center !important; }
|
||||||
</style>
|
</style>
|
||||||
|
|
||||||
<div>
|
<div>
|
||||||
<h4 style="text-align:center; margin:10px 5px 5px;">
|
<h4 style="text-align:center; margin:10px 5px 5px;">
|
||||||
|
|
||||||
|
|
||||||
Доверенность №
|
Доверенность №
|
||||||
<span t-field="o.name"/>
|
<span t-field="o.name"/>
|
||||||
</h4>
|
</h4>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<table style="width:55%">
|
<table style="width:55%">
|
||||||
<tr>
|
<tr>
|
||||||
<td>Дата выдачи:</td>
|
<td>Дата выдачи:</td>
|
||||||
|
|
||||||
|
|
||||||
<td>
|
<td>
|
||||||
<span t-field="o.date_from" t-options="{"widget": "date"}"/>
|
<span t-field="o.date_from" t-options="{"widget": "date"}"/>
|
||||||
г.
|
г.
|
||||||
</td>
|
</td>
|
||||||
|
|
||||||
|
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td>Доверенность действительна по:</td>
|
<td>Доверенность действительна по:</td>
|
||||||
@ -314,63 +141,45 @@
|
|||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
|
|
||||||
|
|
||||||
<div class="special-line" style="width:100%;margin-top:15px;text-align:center">
|
<div class="special-line" style="width:100%;margin-top:15px;text-align:center">
|
||||||
<b>
|
<b>
|
||||||
<span t-field="o.company_id.name"/>, адрес:<span t-field="o.company_id.street"/>, ИНН
|
<span t-field="o.company_id.name"/>, адрес:<span t-field="o.company_id.street"/>, ИНН
|
||||||
<span t-field="o.company_id.vat"/>,
|
<span t-field="o.company_id.vat"/>,
|
||||||
|
|
||||||
</b>
|
</b>
|
||||||
</div>
|
</div>
|
||||||
<div style="margin:0 auto;text-align:center;">наименование предприятия и его адрес</div>
|
<div style="margin:0 auto;text-align:center;">наименование предприятия и его адрес</div>
|
||||||
<table style="width:100%;margin-top:10px">
|
<table style="width:100%;margin-top:10px">
|
||||||
<tr>
|
<tr>
|
||||||
<td style="width:30%">
|
<td style="width:30%">
|
||||||
|
|
||||||
|
|
||||||
Доверенность выдана
|
Доверенность выдана
|
||||||
|
|
||||||
|
|
||||||
</td>
|
</td>
|
||||||
<td style="width:100%;text-align:center;">
|
<td style="width:100%;text-align:center;">
|
||||||
<span style="border-bottom:1px solid;display:block;clear:both;text-align:center;">
|
<span style="border-bottom:1px solid;display:block;clear:both;text-align:center;">
|
||||||
<span t-field="o.employee_id"/>,<span t-field="o.employee_id.job_id.name"/>, ИНН
|
<span t-field="o.employee_id"/>,<span t-field="o.employee_id.job_id.name"/>, ИНН
|
||||||
<span t-field="o.employee_id.inn"/>
|
<span t-field="o.employee_id.inn"/>
|
||||||
|
|
||||||
|
|
||||||
</span>
|
</span>
|
||||||
<span style="">
|
<span style="">
|
||||||
|
|
||||||
|
|
||||||
должность и Ф.И.О.
|
должность и Ф.И.О.
|
||||||
|
|
||||||
|
|
||||||
</span>
|
</span>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
|
|
||||||
<table style="width:100%">
|
<table style="width:100%">
|
||||||
<tr>
|
<tr>
|
||||||
<td>Паспорт серия и №
|
<td>Паспорт серия и №
|
||||||
|
|
||||||
|
|
||||||
<span style="padding:0 5px 0 5px;margin-left:12px;margin-right:12px;display:inline-table;"
|
<span style="padding:0 5px 0 5px;margin-left:12px;margin-right:12px;display:inline-table;"
|
||||||
class="special-line">
|
class="special-line">
|
||||||
|
|
||||||
<span t-field="o.employee_id.passport_id"/>
|
<span t-field="o.employee_id.passport_id"/>
|
||||||
|
|
||||||
|
|
||||||
</span>
|
</span>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td>Кем выдан
|
<td>Кем выдан
|
||||||
|
|
||||||
|
|
||||||
<span style="padding:0 5px 0 5px;margin-left:12px;margin-right:12px;display:inline-table;"
|
<span style="padding:0 5px 0 5px;margin-left:12px;margin-right:12px;display:inline-table;"
|
||||||
class="special-line">
|
class="special-line">
|
||||||
<span t-field="o.employee_id.pass_kem"/>
|
<span t-field="o.employee_id.pass_kem"/>
|
||||||
|
|
||||||
</span>
|
</span>
|
||||||
|
|
||||||
|
|
||||||
@ -378,16 +187,10 @@
|
|||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td>Дата выдачи
|
<td>Дата выдачи
|
||||||
|
|
||||||
|
|
||||||
<span style="padding:0 5px 0 5px;margin-left:12px;margin-right:12px;display:inline-table;"
|
<span style="padding:0 5px 0 5px;margin-left:12px;margin-right:12px;display:inline-table;"
|
||||||
class="special-line">
|
class="special-line">
|
||||||
|
|
||||||
<span t-field="o.employee_id.pass_date"/>
|
<span t-field="o.employee_id.pass_date"/>
|
||||||
|
|
||||||
</span>
|
</span>
|
||||||
|
|
||||||
|
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
@ -395,56 +198,32 @@
|
|||||||
<table style="width:100%">
|
<table style="width:100%">
|
||||||
<tr>
|
<tr>
|
||||||
<td style="width:25%">
|
<td style="width:25%">
|
||||||
|
|
||||||
|
|
||||||
На получение от
|
На получение от
|
||||||
|
|
||||||
|
|
||||||
</td>
|
</td>
|
||||||
<td style="width:75%;text-align:center;">
|
<td style="width:75%;text-align:center;">
|
||||||
<span style="border-bottom:1px solid;display:block;clear:both;">
|
<span style="border-bottom:1px solid;display:block;clear:both;">
|
||||||
|
|
||||||
|
|
||||||
<span t-field="o.partner_id"/>
|
<span t-field="o.partner_id"/>
|
||||||
|
|
||||||
|
|
||||||
</span>
|
</span>
|
||||||
<span style="">
|
<span style="">
|
||||||
|
|
||||||
|
|
||||||
наименование поставщика
|
наименование поставщика
|
||||||
|
|
||||||
|
|
||||||
</span>
|
</span>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td style="width:25%">
|
<td style="width:25%">
|
||||||
|
|
||||||
|
|
||||||
Материальных ценностей по
|
Материальных ценностей по
|
||||||
|
|
||||||
|
|
||||||
</td>
|
</td>
|
||||||
<td style="width:75%;text-align:center;">
|
<td style="width:75%;text-align:center;">
|
||||||
<span style="border-bottom:1px solid;display:block;clear:both;">
|
<span style="border-bottom:1px solid;display:block;clear:both;">
|
||||||
|
|
||||||
|
|
||||||
Заказу на закупку №
|
Заказу на закупку №
|
||||||
<span t-field="o.purchaseorder_id.name"/>
|
<span t-field="o.purchaseorder_id.name"/>
|
||||||
от
|
от
|
||||||
<span t-field="o.purchaseorder_id.date_order"
|
<span t-field="o.purchaseorder_id.date_order"
|
||||||
t-options="{"widget": "date"}"/>
|
t-options="{"widget": "date"}"/>
|
||||||
г.
|
г.
|
||||||
|
|
||||||
|
|
||||||
</span>
|
</span>
|
||||||
<span style="">
|
<span style="">
|
||||||
|
|
||||||
|
|
||||||
наименование, номер и дата документа
|
наименование, номер и дата документа
|
||||||
|
|
||||||
|
|
||||||
</span>
|
</span>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
@ -452,15 +231,9 @@
|
|||||||
|
|
||||||
<div>
|
<div>
|
||||||
<h4 style="text-align:center; margin:15px 5px 15px;">
|
<h4 style="text-align:center; margin:15px 5px 15px;">
|
||||||
|
|
||||||
|
|
||||||
Перечень материальных ценностей,
|
Перечень материальных ценностей,
|
||||||
|
|
||||||
|
|
||||||
<br/>
|
<br/>
|
||||||
подлежащих получению
|
подлежащих получению
|
||||||
|
|
||||||
|
|
||||||
</h4>
|
</h4>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@ -494,60 +267,30 @@
|
|||||||
<div class="clear h100"></div>
|
<div class="clear h100"></div>
|
||||||
<div>
|
<div>
|
||||||
<p></p>
|
<p></p>
|
||||||
|
|
||||||
<p>Подпись лица, получившего доверенность ___________________ удостоверяем</p>
|
<p>Подпись лица, получившего доверенность ___________________ удостоверяем</p>
|
||||||
|
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
<div class="podpis-box">
|
<div class="podpis-box">
|
||||||
<table style="width:50%;">
|
<table style="width:50%;">
|
||||||
<tr>
|
<tr>
|
||||||
<td style="width: 13%;">Руководитель предприятия</td>
|
<td style="width: 13%;">Руководитель предприятия</td>
|
||||||
<td style="width: 19%; vertical-align: bottom;">
|
<td style="width: 19%; vertical-align: bottom;">
|
||||||
|
|
||||||
|
|
||||||
<span class="special-line"></span>
|
<span class="special-line"></span>
|
||||||
|
|
||||||
|
|
||||||
<span class="note">(подпись)</span>
|
<span class="note">(подпись)</span>
|
||||||
|
|
||||||
|
|
||||||
</td>
|
</td>
|
||||||
<td style="width: 16%; vertical-align: bottom;">
|
<td style="width: 16%; vertical-align: bottom;">
|
||||||
|
|
||||||
|
|
||||||
<span class="special-line"></span>
|
<span class="special-line"></span>
|
||||||
|
|
||||||
|
|
||||||
<span class="note">(Ф.И.О)</span>
|
<span class="note">(Ф.И.О)</span>
|
||||||
|
|
||||||
|
|
||||||
</td>
|
</td>
|
||||||
<td style="width: 16%; vertical-align: bottom;"></td>
|
|
||||||
|
|
||||||
|
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td style="width: 13%;">Гл. бухгалтер:</td>
|
<td style="width: 13%;">Гл. бухгалтер:</td>
|
||||||
<td style="width: 19%; vertical-align: bottom;">
|
<td style="width: 19%; vertical-align: bottom;">
|
||||||
|
|
||||||
|
|
||||||
<span class="special-line"></span>
|
<span class="special-line"></span>
|
||||||
|
|
||||||
|
|
||||||
<span class="note">(подпись)</span>
|
<span class="note">(подпись)</span>
|
||||||
|
|
||||||
|
|
||||||
</td>
|
</td>
|
||||||
<td style="width: 16%; vertical-align: bottom;">
|
<td style="width: 16%; vertical-align: bottom;">
|
||||||
|
|
||||||
|
|
||||||
<span class="special-line"></span>
|
<span class="special-line"></span>
|
||||||
|
|
||||||
|
|
||||||
<span class="note">(Ф.И.О)</span>
|
<span class="note">(Ф.И.О)</span>
|
||||||
|
|
||||||
|
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
|
@ -5,13 +5,13 @@
|
|||||||
<field name="name">Consents</field>
|
<field name="name">Consents</field>
|
||||||
<field name="model">base.consent</field>
|
<field name="model">base.consent</field>
|
||||||
<field name="arch" type="xml">
|
<field name="arch" type="xml">
|
||||||
<tree>
|
<list>
|
||||||
<field name="name"/>
|
<field name="name"/>
|
||||||
<field name="partner_id"/>
|
<field name="partner_id"/>
|
||||||
<field name="employee_id"/>
|
<field name="employee_id"/>
|
||||||
<field name="date_from"/>
|
<field name="date_from"/>
|
||||||
<field name="date_to"/>
|
<field name="date_to"/>
|
||||||
</tree>
|
</list>
|
||||||
</field>
|
</field>
|
||||||
</record>
|
</record>
|
||||||
|
|
||||||
@ -36,10 +36,11 @@
|
|||||||
</group>
|
</group>
|
||||||
</group>
|
</group>
|
||||||
</sheet>
|
</sheet>
|
||||||
<div class="oe_chatter">
|
<chatter/>
|
||||||
<field name="message_follower_ids" widget="mail_followers"/>
|
<!-- <div class="oe_chatter">-->
|
||||||
<field name="message_ids" widget="mail_thread"/>
|
<!-- <field name="message_follower_ids" widget="mail_followers"/>-->
|
||||||
</div>
|
<!-- <field name="message_ids" widget="mail_thread"/>-->
|
||||||
|
<!-- </div>-->
|
||||||
</form>
|
</form>
|
||||||
</field>
|
</field>
|
||||||
</record>
|
</record>
|
||||||
@ -47,10 +48,10 @@
|
|||||||
<record id="l10n_ru_attorney.action_consent" model="ir.actions.act_window">
|
<record id="l10n_ru_attorney.action_consent" model="ir.actions.act_window">
|
||||||
<field name="name">Доверенности</field>
|
<field name="name">Доверенности</field>
|
||||||
<field name="res_model">base.consent</field>
|
<field name="res_model">base.consent</field>
|
||||||
<field name="view_mode">tree,form</field>
|
<field name="view_mode">list,form</field>
|
||||||
</record>
|
</record>
|
||||||
|
|
||||||
<menuitem id="l10n_ru_attorney.menu_1" name="Consents" parent="purchase.menu_purchase_root"
|
<menuitem id="l10n_ru_attorney.menu_1" name="Доверенности" parent="purchase.menu_purchase_root"
|
||||||
action="l10n_ru_attorney.action_consent"/>
|
action="l10n_ru_attorney.action_consent"/>
|
||||||
|
|
||||||
<record id="seq_consent" model="ir.sequence">
|
<record id="seq_consent" model="ir.sequence">
|
||||||
|
@ -16,11 +16,11 @@
|
|||||||
'author': "MK.Lab",
|
'author': "MK.Lab",
|
||||||
'website': "https://www.inf-centre.ru/",
|
'website': "https://www.inf-centre.ru/",
|
||||||
|
|
||||||
'version': '17.0.1.0.0',
|
'version': '18.0.1.0.0',
|
||||||
'license': 'LGPL-3',
|
'license': 'LGPL-3',
|
||||||
'category': 'Uncategorized',
|
'category': 'Uncategorized',
|
||||||
|
|
||||||
'depends': [],
|
'depends': ["account", "portal", "website", 'contacts','base', 'mail', 'sale', 'purchase', 'hr','sale_management', 'sale_stock', 'uom','web'],
|
||||||
|
|
||||||
'data': [
|
'data': [
|
||||||
'views/res_config_settings_views.xml',
|
'views/res_config_settings_views.xml',
|
||||||
|
@ -1,13 +1,13 @@
|
|||||||
# Translation of Odoo Server.
|
# Translation of Odoo Server.
|
||||||
# This file contains the translation of the following modules:
|
# This file contains the translation of the following modules:
|
||||||
# * base_russian_localization
|
# * l10n_ru_base
|
||||||
#
|
#
|
||||||
msgid ""
|
msgid ""
|
||||||
msgstr ""
|
msgstr ""
|
||||||
"Project-Id-Version: Odoo Server 17.0+e-20240904\n"
|
"Project-Id-Version: Odoo Server 18.0+e\n"
|
||||||
"Report-Msgid-Bugs-To: \n"
|
"Report-Msgid-Bugs-To: \n"
|
||||||
"POT-Creation-Date: 2024-10-29 07:45+0000\n"
|
"POT-Creation-Date: 2024-12-17 06:36+0000\n"
|
||||||
"PO-Revision-Date: 2024-10-29 07:45+0000\n"
|
"PO-Revision-Date: 2024-12-17 06:36+0000\n"
|
||||||
"Last-Translator: \n"
|
"Last-Translator: \n"
|
||||||
"Language-Team: \n"
|
"Language-Team: \n"
|
||||||
"MIME-Version: 1.0\n"
|
"MIME-Version: 1.0\n"
|
||||||
@ -15,95 +15,103 @@ msgstr ""
|
|||||||
"Content-Transfer-Encoding: \n"
|
"Content-Transfer-Encoding: \n"
|
||||||
"Plural-Forms: \n"
|
"Plural-Forms: \n"
|
||||||
|
|
||||||
#. module: base_russian_localization
|
#. module: l10n_ru_base
|
||||||
#. odoo-python
|
#. odoo-python
|
||||||
#: code:addons/base_russian_localization/models/res_config_settings.py:0
|
#: code:addons/l10n_ru_base/models/res_config_settings.py:0
|
||||||
#: model:ir.model.fields,field_description:base_russian_localization.field_res_config_settings__module_act_revise
|
#: model:ir.model.fields,field_description:l10n_ru_base.field_res_config_settings__module_l10n_ru_act_rev
|
||||||
#: model_terms:ir.ui.view,arch_db:base_russian_localization.res_config_settings_view_form
|
#: model_terms:ir.ui.view,arch_db:l10n_ru_base.res_config_settings_view_form
|
||||||
|
msgid "Act revise"
|
||||||
|
msgstr "Акт сверки"
|
||||||
|
|
||||||
|
#. module: l10n_ru_base
|
||||||
|
#. odoo-python
|
||||||
|
#: code:addons/l10n_ru_base/models/res_config_settings.py:0
|
||||||
|
#: model:ir.model.fields,field_description:l10n_ru_base.field_res_config_settings__module_act_revise
|
||||||
|
#: model_terms:ir.ui.view,arch_db:l10n_ru_base.res_config_settings_view_form
|
||||||
#, python-format
|
#, python-format
|
||||||
msgid "Act revise"
|
msgid "Act revise"
|
||||||
msgstr "Акт сверки"
|
msgstr "Акт сверки"
|
||||||
|
|
||||||
#. module: base_russian_localization
|
#. module: l10n_ru_base
|
||||||
#: model:ir.model.fields,field_description:base_russian_localization.field_res_config_settings__company_status_rf
|
#: model:ir.model.fields,field_description:l10n_ru_base.field_res_config_settings__company_status_rf
|
||||||
msgid "Company Status Rf"
|
msgid "Company Status Rf"
|
||||||
msgstr "Статус компании"
|
msgstr "Статус компании"
|
||||||
|
|
||||||
#. module: base_russian_localization
|
#. module: l10n_ru_base
|
||||||
#: model:ir.model,name:base_russian_localization.model_res_config_settings
|
#: model:ir.model,name:l10n_ru_base.model_res_config_settings
|
||||||
msgid "Config Settings"
|
msgid "Config Settings"
|
||||||
msgstr "Параметры конфигурации"
|
msgstr "Параметры конфигурации"
|
||||||
|
|
||||||
#. module: base_russian_localization
|
#. module: l10n_ru_base
|
||||||
#. odoo-python
|
#. odoo-python
|
||||||
#: code:addons/base_russian_localization/models/res_config_settings.py:0
|
#: code:addons/l10n_ru_base/models/res_config_settings.py:0
|
||||||
#: model:ir.model.fields,field_description:base_russian_localization.field_res_config_settings__module_fehu_base_consent
|
#: model:ir.model.fields,field_description:l10n_ru_base.field_res_config_settings__module_fehu_base_consent
|
||||||
#: model_terms:ir.ui.view,arch_db:base_russian_localization.res_config_settings_view_form
|
#: model_terms:ir.ui.view,arch_db:l10n_ru_base.res_config_settings_view_form
|
||||||
#, python-format
|
#, python-format
|
||||||
msgid "Consent"
|
msgid "Consent"
|
||||||
msgstr "Доверенность"
|
msgstr "Доверенность"
|
||||||
|
|
||||||
#. module: base_russian_localization
|
#. module: l10n_ru_base
|
||||||
#. odoo-python
|
#. odoo-python
|
||||||
#: code:addons/base_russian_localization/models/res_config_settings.py:0
|
#: code:addons/l10n_ru_base/models/res_config_settings.py:0
|
||||||
#: model:ir.model.fields,field_description:base_russian_localization.field_res_config_settings__module_contract
|
#: model:ir.model.fields,field_description:l10n_ru_base.field_res_config_settings__module_contract
|
||||||
#, python-format
|
#, python-format
|
||||||
msgid "Contract"
|
msgid "Contract"
|
||||||
msgstr "Договор"
|
msgstr "Договор"
|
||||||
|
|
||||||
#. module: base_russian_localization
|
#. module: l10n_ru_base
|
||||||
#: model_terms:ir.ui.view,arch_db:base_russian_localization.res_config_settings_view_form
|
#: model_terms:ir.ui.view,arch_db:l10n_ru_base.res_config_settings_view_form
|
||||||
msgid "Contracts"
|
msgid "Contracts"
|
||||||
msgstr "Договоры"
|
msgstr "Договоры"
|
||||||
|
|
||||||
#. module: base_russian_localization
|
#. module: l10n_ru_base
|
||||||
#: model_terms:ir.ui.view,arch_db:base_russian_localization.res_config_settings_view_form
|
#: model_terms:ir.ui.view,arch_db:l10n_ru_base.res_config_settings_view_form
|
||||||
msgid "Powers of attorney"
|
msgid "Powers of attorney"
|
||||||
msgstr "Доверенность на получение ТМЦ"
|
msgstr "Доверенность на получение ТМЦ"
|
||||||
|
|
||||||
#. module: base_russian_localization
|
#. module: l10n_ru_base
|
||||||
#. odoo-python
|
#. odoo-python
|
||||||
#: code:addons/base_russian_localization/models/res_config_settings.py:0
|
#: code:addons/l10n_ru_base/models/res_config_settings.py:0
|
||||||
#: model:ir.model.fields,field_description:base_russian_localization.field_res_config_settings__module_l10n_ru_doc
|
#: model:ir.model.fields,field_description:l10n_ru_base.field_res_config_settings__module_l10n_ru_doc
|
||||||
#: model_terms:ir.ui.view,arch_db:base_russian_localization.res_config_settings_view_form
|
#: model_terms:ir.ui.view,arch_db:l10n_ru_base.res_config_settings_view_form
|
||||||
#, python-format
|
#, python-format
|
||||||
msgid "Print forms"
|
msgid "Print forms"
|
||||||
msgstr "Печатные формы"
|
msgstr "Печатные формы"
|
||||||
|
|
||||||
#. module: base_russian_localization
|
#. module: l10n_ru_base
|
||||||
#: model_terms:ir.ui.view,arch_db:base_russian_localization.res_config_settings_view_form
|
#: model_terms:ir.ui.view,arch_db:l10n_ru_base.res_config_settings_view_form
|
||||||
msgid "Report act revise"
|
msgid "Report act revise"
|
||||||
msgstr "Отчет Акт сверки"
|
msgstr "Отчет Акт сверки"
|
||||||
|
|
||||||
#. module: base_russian_localization
|
#. module: l10n_ru_base
|
||||||
#: model_terms:ir.ui.view,arch_db:base_russian_localization.res_config_settings_view_form
|
#: model_terms:ir.ui.view,arch_db:l10n_ru_base.res_config_settings_view_form
|
||||||
msgid "Report contract"
|
msgid "Report contract"
|
||||||
msgstr "Договоры"
|
msgstr "Договоры"
|
||||||
|
|
||||||
#. module: base_russian_localization
|
#. module: l10n_ru_base
|
||||||
#: model_terms:ir.ui.view,arch_db:base_russian_localization.res_config_settings_view_form
|
#: model_terms:ir.ui.view,arch_db:l10n_ru_base.res_config_settings_view_form
|
||||||
msgid "Report report_xml"
|
msgid "Report report_xml"
|
||||||
msgstr "УПД в формате xml для ЭДО"
|
msgstr "УПД в формате xml для ЭДО"
|
||||||
|
|
||||||
#. module: base_russian_localization
|
#. module: l10n_ru_base
|
||||||
#. odoo-python
|
#. odoo-python
|
||||||
#: code:addons/base_russian_localization/models/res_config_settings.py:0
|
#: code:addons/l10n_ru_base/models/res_config_settings.py:0
|
||||||
#: model:ir.model.fields,field_description:base_russian_localization.field_res_config_settings__module_report_xml
|
#: model:ir.model.fields,field_description:l10n_ru_base.field_res_config_settings__module_report_xml
|
||||||
#, python-format
|
#, python-format
|
||||||
msgid "Report_xml"
|
msgid "Report_xml"
|
||||||
msgstr "Универсальный передаточный документ (УПД) в формате xml для ЭДО"
|
msgstr "Универсальный передаточный документ (УПД) в формате xml для ЭДО"
|
||||||
|
|
||||||
#. module: base_russian_localization
|
#. module: l10n_ru_base
|
||||||
#: model_terms:ir.ui.view,arch_db:base_russian_localization.res_config_settings_view_form
|
#: model_terms:ir.ui.view,arch_db:l10n_ru_base.res_config_settings_view_form
|
||||||
msgid "Russian Localization"
|
msgid "Russian Localization"
|
||||||
msgstr "Российская локализация"
|
msgstr "Российская локализация"
|
||||||
|
|
||||||
#. module: base_russian_localization
|
#. module: l10n_ru_base
|
||||||
#: model_terms:ir.ui.view,arch_db:base_russian_localization.res_config_settings_view_form
|
#: model_terms:ir.ui.view,arch_db:l10n_ru_base.res_config_settings_view_form
|
||||||
msgid "UPD xml"
|
msgid "UPD xml"
|
||||||
msgstr "УПД в формате xml для ЭДО"
|
msgstr "УПД в формате xml для ЭДО"
|
||||||
|
|
||||||
#. module: base_russian_localization
|
#. module: l10n_ru_base
|
||||||
#: model_terms:ir.ui.view,arch_db:base_russian_localization.res_config_settings_view_form
|
#: model_terms:ir.ui.view,arch_db:l10n_ru_base.res_config_settings_view_form
|
||||||
msgid "print_forms"
|
msgid "print_forms"
|
||||||
msgstr "Печатные формы документов"
|
msgstr "Печатные формы документов"
|
||||||
|
@ -4,6 +4,8 @@
|
|||||||
from odoo import _, api, fields, models
|
from odoo import _, api, fields, models
|
||||||
from odoo.exceptions import UserError
|
from odoo.exceptions import UserError
|
||||||
|
|
||||||
|
import logging
|
||||||
|
|
||||||
_FIELDS_MODUL = [
|
_FIELDS_MODUL = [
|
||||||
'module_l10n_ru_act_rev',
|
'module_l10n_ru_act_rev',
|
||||||
'module_l10n_ru_contract',
|
'module_l10n_ru_contract',
|
||||||
@ -23,13 +25,16 @@ class ResConfigSettings(models.TransientModel):
|
|||||||
|
|
||||||
@api.model
|
@api.model
|
||||||
def write(self, values):
|
def write(self, values):
|
||||||
|
if any(field in values for field in _FIELDS_MODUL):
|
||||||
company = self.env.company
|
company = self.env.company
|
||||||
if company.country_id.code != 'RU':
|
if company.country_id.code != 'RU':
|
||||||
raise UserError("Признак Российской компании не обнаружен!")
|
raise UserError("Признак Российской компании не обнаружен!")
|
||||||
|
|
||||||
if _FIELDS_MODUL:
|
if _FIELDS_MODUL:
|
||||||
missing_modules = set()
|
missing_modules = set()
|
||||||
for field in _FIELDS_MODUL:
|
for field in _FIELDS_MODUL:
|
||||||
if self.mapped(field)[0]:
|
mapped_values = self.mapped(field)
|
||||||
|
if mapped_values and mapped_values[0]:
|
||||||
module_name = field[7:]
|
module_name = field[7:]
|
||||||
module_installed = self.env['ir.module.module'].search([('name', '=', module_name)], limit=1)
|
module_installed = self.env['ir.module.module'].search([('name', '=', module_name)], limit=1)
|
||||||
if not module_installed:
|
if not module_installed:
|
||||||
|
30
l10n_ru_contract/README.md
Normal file
30
l10n_ru_contract/README.md
Normal file
@ -0,0 +1,30 @@
|
|||||||
|
# Российская локализация - Договоры
|
||||||
|
name: l10n_ru_contract
|
||||||
|
|
||||||
|
|
||||||
|
## Описание
|
||||||
|
Создание договоров с клиентами и поставщиками в системе.
|
||||||
|
Возможность разделения договоров на виды, отслеживание статуса договора. Вы также можете распечатать договор из системы.
|
||||||
|
|
||||||
|
### Создание вида договора клиента(поставщика):
|
||||||
|
1. Меню Продажи (Покупки) - Договоры - Виды договора - кнопка "Создать";
|
||||||
|
2. На форме указываем:
|
||||||
|
|
||||||
|
2.1. Журнал и счета дебетовой и кредиторской задолженности;
|
||||||
|
|
||||||
|
2.2. Присваиваем новое название.
|
||||||
|
|
||||||
|
### Создание договора клиента (поставщика):
|
||||||
|
1. Меню Продажи (Покупки) - Договоры - кнопка "Создать";
|
||||||
|
2. На форме указываем основные и дополнительные условия договора:
|
||||||
|
|
||||||
|
2.1. Контрагент - клиент (поставщик);
|
||||||
|
|
||||||
|
2.2. Тип контрагента;
|
||||||
|
|
||||||
|
2.3. Компанию, от лица которой будет подписан договор;
|
||||||
|
|
||||||
|
2.4. Вид договора.
|
||||||
|
|
||||||
|
### Для печати:
|
||||||
|
1. Открываем созданную запись договора - Действие - "Договор".
|
@ -1,14 +1,41 @@
|
|||||||
# -*- coding: utf-8 -*-
|
# -*- coding: utf-8 -*-
|
||||||
{
|
{
|
||||||
'name': 'Контракты клиентов',
|
'name': 'Российская локализация - Договоры',
|
||||||
'version': '17.0.2024.02.02',
|
'summary': """
|
||||||
|
Создание договоров, их видов и печать
|
||||||
|
""",
|
||||||
|
|
||||||
|
'description': """
|
||||||
|
Создание договоров с клиентами и поставщиками. Возможность разделения на виды договоров, отслеживание статуса договора и его печатью
|
||||||
|
Создание вида договора клиента(поставщика):
|
||||||
|
1. Меню Продажи (Покупки) - Договоры - Виды договора - кнопка "Создать";
|
||||||
|
2. На форме указываем:
|
||||||
|
2.1. Журнал и счета дебетовой и кредиторской задолженности;
|
||||||
|
2.2. Присваиваем новое название.
|
||||||
|
|
||||||
|
Создание договора клиента (поставщика):
|
||||||
|
1. Меню Продажи (Покупки) - Договоры - кнопка "Создать";
|
||||||
|
2. На форме указываем основные и дополнительные условия договора:
|
||||||
|
2.1. Контрагент - клиент (поставщик);
|
||||||
|
2.2. Тип контрагента;
|
||||||
|
2.3. Компанию, от лица которой будет подписан договор;
|
||||||
|
2.4. Вид договора.
|
||||||
|
|
||||||
|
Для печати:
|
||||||
|
1. Открываем созданную запись договора - Действие - "Договор".
|
||||||
|
""",
|
||||||
|
|
||||||
|
'version': '18.0.1.0.0',
|
||||||
'sequence': 0,
|
'sequence': 0,
|
||||||
'author': 'StarlingSoft',
|
'author': 'MK.Lab',
|
||||||
'website': 'https://inf-centre.ru',
|
'website': 'https://www.inf-centre.ru/',
|
||||||
|
'external_dependencies': {
|
||||||
|
'python': ['pymorphy2'],
|
||||||
|
},
|
||||||
'depends': [
|
'depends': [
|
||||||
'base',
|
'base',
|
||||||
'mail',
|
'mail',
|
||||||
'account', 'sale', 'sale_management', 'purchase'
|
'account', 'sale', 'sale_management', 'purchase', 'l10n_ru_base'
|
||||||
],
|
],
|
||||||
'data': [
|
'data': [
|
||||||
'data/data.xml',
|
'data/data.xml',
|
||||||
@ -17,7 +44,7 @@
|
|||||||
'report/report_contract.xml',
|
'report/report_contract.xml',
|
||||||
'report/report_contract_order.xml',
|
'report/report_contract_order.xml',
|
||||||
'report/report_contract_order1.xml',
|
'report/report_contract_order1.xml',
|
||||||
'report/report_contract_invoce.xml',
|
'report/report_contract_invoice.xml',
|
||||||
|
|
||||||
],
|
],
|
||||||
'installable': True,
|
'installable': True,
|
||||||
|
@ -1,2 +1,9 @@
|
|||||||
# -*- coding: utf-8 -*-
|
# -*- coding: utf-8 -*-
|
||||||
from . import contract_customer, invoice_saleorder, dop_field, crutch_fields_header
|
|
||||||
|
from . import account_move
|
||||||
|
from . import contract_customer
|
||||||
|
from . import crutch_fields_header
|
||||||
|
from . import dop_field
|
||||||
|
from . import purchase_order
|
||||||
|
from . import sale_make_invoice_advance
|
||||||
|
from . import sale_order
|
||||||
|
BIN
l10n_ru_contract/models/__pycache__/__init__.cpython-310.pyc
Normal file
BIN
l10n_ru_contract/models/__pycache__/__init__.cpython-310.pyc
Normal file
Binary file not shown.
BIN
l10n_ru_contract/models/__pycache__/__init__.cpython-311.pyc
Normal file
BIN
l10n_ru_contract/models/__pycache__/__init__.cpython-311.pyc
Normal file
Binary file not shown.
BIN
l10n_ru_contract/models/__pycache__/__init__.cpython-35.pyc
Normal file
BIN
l10n_ru_contract/models/__pycache__/__init__.cpython-35.pyc
Normal file
Binary file not shown.
BIN
l10n_ru_contract/models/__pycache__/__init__.cpython-36.pyc
Normal file
BIN
l10n_ru_contract/models/__pycache__/__init__.cpython-36.pyc
Normal file
Binary file not shown.
BIN
l10n_ru_contract/models/__pycache__/__init__.cpython-37.pyc
Normal file
BIN
l10n_ru_contract/models/__pycache__/__init__.cpython-37.pyc
Normal file
Binary file not shown.
BIN
l10n_ru_contract/models/__pycache__/__init__.cpython-38.pyc
Normal file
BIN
l10n_ru_contract/models/__pycache__/__init__.cpython-38.pyc
Normal file
Binary file not shown.
BIN
l10n_ru_contract/models/__pycache__/__init__.cpython-39.pyc
Normal file
BIN
l10n_ru_contract/models/__pycache__/__init__.cpython-39.pyc
Normal file
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
l10n_ru_contract/models/__pycache__/dop_field.cpython-310.pyc
Normal file
BIN
l10n_ru_contract/models/__pycache__/dop_field.cpython-310.pyc
Normal file
Binary file not shown.
BIN
l10n_ru_contract/models/__pycache__/dop_field.cpython-311.pyc
Normal file
BIN
l10n_ru_contract/models/__pycache__/dop_field.cpython-311.pyc
Normal file
Binary file not shown.
BIN
l10n_ru_contract/models/__pycache__/dop_field.cpython-36.pyc
Normal file
BIN
l10n_ru_contract/models/__pycache__/dop_field.cpython-36.pyc
Normal file
Binary file not shown.
BIN
l10n_ru_contract/models/__pycache__/dop_field.cpython-37.pyc
Normal file
BIN
l10n_ru_contract/models/__pycache__/dop_field.cpython-37.pyc
Normal file
Binary file not shown.
BIN
l10n_ru_contract/models/__pycache__/dop_field.cpython-38.pyc
Normal file
BIN
l10n_ru_contract/models/__pycache__/dop_field.cpython-38.pyc
Normal file
Binary file not shown.
BIN
l10n_ru_contract/models/__pycache__/dop_field.cpython-39.pyc
Normal file
BIN
l10n_ru_contract/models/__pycache__/dop_field.cpython-39.pyc
Normal file
Binary file not shown.
BIN
l10n_ru_contract/models/__pycache__/report_helper.cpython-36.pyc
Normal file
BIN
l10n_ru_contract/models/__pycache__/report_helper.cpython-36.pyc
Normal file
Binary file not shown.
50
l10n_ru_contract/models/account_move.py
Normal file
50
l10n_ru_contract/models/account_move.py
Normal file
@ -0,0 +1,50 @@
|
|||||||
|
from odoo import api, fields, models, exceptions, _
|
||||||
|
|
||||||
|
|
||||||
|
class AccountMove(models.Model):
|
||||||
|
_inherit = 'account.move'
|
||||||
|
|
||||||
|
mt_contract_id = fields.Many2one('partner.contract.customer', string=_('Номер договора'))
|
||||||
|
sf_number = fields.Char(string=_('Номер с/ф'))
|
||||||
|
osnovanie = fields.Char(string=_('Основание'))
|
||||||
|
sec_partner_id = fields.Many2one('res.partner', string=_('Контрагент'), store=True, compute='_compute_get_pid')
|
||||||
|
stamp = fields.Boolean(string=_('Печать и подпись'), related='mt_contract_id.stamp')
|
||||||
|
|
||||||
|
@api.depends('partner_id')
|
||||||
|
def _compute_get_pid(self):
|
||||||
|
for s in self:
|
||||||
|
s.sec_partner_id = s.partner_id.parent_id if s.partner_id.parent_id else s.partner_id
|
||||||
|
|
||||||
|
@api.onchange('mt_contract_id')
|
||||||
|
def set_ons(self):
|
||||||
|
if self.mt_contract_id:
|
||||||
|
self.osnovanie = 'Договор № ' + self.mt_contract_id.name + ' от ' + fields.Datetime.from_string(
|
||||||
|
self.mt_contract_id.date_start).strftime("%d.%m.%Y")
|
||||||
|
|
||||||
|
@api.constrains('state')
|
||||||
|
def invoice_fields_check(self):
|
||||||
|
for s in self:
|
||||||
|
if s.state == 'posted':
|
||||||
|
if s.mt_contract_id:
|
||||||
|
errors_list = []
|
||||||
|
journal_in_contract = s.mt_contract_id.profile_id.journal_id
|
||||||
|
payment_term_in_contract = s.mt_contract_id.profile_id.payment_term_id
|
||||||
|
receivable_in_contract = s.mt_contract_id.profile_id.receivable_account_id
|
||||||
|
|
||||||
|
if journal_in_contract != s.journal_id:
|
||||||
|
errors_list.append(f'Отличается Журнал - [{s.journal_id.name}] '
|
||||||
|
f'и указанный в договоре №{s.mt_contract_id.name} '
|
||||||
|
f'Журнал - [{journal_in_contract.name}]\n\n')
|
||||||
|
|
||||||
|
if payment_term_in_contract != s.invoice_payment_term_id:
|
||||||
|
errors_list.append(f'Отличается поле "Условие оплаты" в инвойсе '
|
||||||
|
f'[Условие оплаты - {s.invoice_payment_term_id.name}] '
|
||||||
|
f'и указанный в договоре №{s.mt_contract_id.name} '
|
||||||
|
f'[Условие оплаты - {payment_term_in_contract.name}]\n\n')
|
||||||
|
|
||||||
|
if receivable_in_contract not in s.line_ids.account_id:
|
||||||
|
errors_list.append(f'Отличается поле "Счет дебиторской задолженности" в инвойсе '
|
||||||
|
f'и указанный в договоре №{s.mt_contract_id.name}')
|
||||||
|
|
||||||
|
if errors_list:
|
||||||
|
raise exceptions.ValidationError(''.join(errors_list))
|
@ -1,5 +1,5 @@
|
|||||||
# -*- coding: utf-8 -*-
|
# -*- coding: utf-8 -*-
|
||||||
from odoo import api, fields, models, exceptions, tools
|
from odoo import api, fields, models, exceptions, tools, _
|
||||||
import pymorphy2
|
import pymorphy2
|
||||||
from datetime import datetime, timedelta
|
from datetime import datetime, timedelta
|
||||||
from dateutil.relativedelta import relativedelta
|
from dateutil.relativedelta import relativedelta
|
||||||
@ -17,63 +17,63 @@ class PartnerContractCustomer(models.Model):
|
|||||||
six_months = datetime.today() + relativedelta(months=+11)
|
six_months = datetime.today() + relativedelta(months=+11)
|
||||||
return fields.Datetime.to_string(six_months)
|
return fields.Datetime.to_string(six_months)
|
||||||
|
|
||||||
name = fields.Char(string='Номер')
|
name = fields.Char(string=_('Номер'))
|
||||||
date_start = fields.Date(string='Дата договора', required=True, default=fields.Datetime.now())
|
date_start = fields.Date(string=_('Дата договора'), required=True, default=fields.Datetime.now())
|
||||||
partner_id = fields.Many2one('res.partner', string='Контрагент', required=True)
|
partner_id = fields.Many2one('res.partner', string=_('Контрагент'), required=True)
|
||||||
sec_partner_id = fields.Many2one('res.partner', string='Контрагент как в заказе')
|
sec_partner_id = fields.Many2one('res.partner', string=_('Контрагент как в заказе'))
|
||||||
company_id = fields.Many2one('res.company', string='Компания', required=True)
|
company_id = fields.Many2one('res.company', string=_('Компания'), required=True)
|
||||||
name_print = fields.Char(string='Имя для печати', compute='_get_name_print')
|
name_print = fields.Char(string=_('Имя для печати'), compute='_get_name_print')
|
||||||
name_print1 = fields.Char(string='Имя для печати, И.П.', compute='_get_name_printip')
|
name_print1 = fields.Char(string=_('Имя для печати, И.П.'), compute='_get_name_printip')
|
||||||
date_end = fields.Date(string='Дата окончания', required=True, default=get_dateend)
|
date_end = fields.Date(string=_('Дата окончания'), required=True, default=get_dateend)
|
||||||
name_dirprint = fields.Char(string='Имя нашего директора для печати')
|
name_dirprint = fields.Char(string=_('Имя нашего директора для печати'))
|
||||||
name_dirprint1 = fields.Char(string='Имя нашего директора для печати И.П.')
|
name_dirprint1 = fields.Char(string=_('Имя нашего директора для печати И.П.'))
|
||||||
lines = fields.One2many('contract.line', 'contract_id', string='Договорные цены')
|
lines = fields.One2many('contract.line', 'contract_id', string=_('Договорные цены'))
|
||||||
type = fields.Selection(
|
type = fields.Selection(
|
||||||
[('customer', 'С покупателем'),
|
[('customer', 'С покупателем'),
|
||||||
('supplier', 'С поставщиком'),
|
('supplier', 'С поставщиком'),
|
||||||
('other', 'Прочие расчеты'),
|
('other', 'Прочие расчеты'),
|
||||||
|
|
||||||
],
|
],
|
||||||
string='Тип договора', default='customer', required=True)
|
string=_('Тип договора'), default='customer', required=True)
|
||||||
saleorder_id = fields.Many2one('sale.order', string='Заказ/Сделка')
|
saleorder_id = fields.Many2one('sale.order', string=_('Заказ/Сделка'))
|
||||||
stamp = fields.Boolean(string='Печать и подпись')
|
stamp = fields.Boolean(string=_('Печать и подпись'))
|
||||||
signed = fields.Boolean(string='Договор подписан')
|
signed = fields.Boolean(string=_('Договор подписан'))
|
||||||
state = fields.Selection(
|
state = fields.Selection(
|
||||||
[('draft', 'Черновик'),
|
[('draft', 'Черновик'),
|
||||||
('progress', 'На согласовании'),
|
('progress', 'На согласовании'),
|
||||||
('signed', 'Подписан, действует'),
|
('signed', 'Подписан, действует'),
|
||||||
('closed', 'Истёк'),
|
('closed', 'Истёк'),
|
||||||
],
|
],
|
||||||
string='Статус', default='draft', group_expand='_expand_states', index=True
|
string=_('Статус'), default='draft', group_expand='_expand_states', index=True
|
||||||
)
|
)
|
||||||
is_template = fields.Boolean('Это шаблон')
|
is_template = fields.Boolean(_('Это шаблон'))
|
||||||
copy_from = fields.Many2one('partner.contract.customer', string='Копировать из этого шаблона')
|
copy_from = fields.Many2one('partner.contract.customer', string=_('Копировать из этого шаблона'))
|
||||||
profile_id = fields.Many2one('contract.profile', string='Вид договора', required=True)
|
profile_id = fields.Many2one('contract.profile', string=_('Вид договора'), required=True)
|
||||||
credit_limit = fields.Float(string='Лимит кредита')
|
credit_limit = fields.Float(string=_('Лимит кредита'))
|
||||||
guid_1s = fields.Char('Код договора из 1С')
|
guid_1s = fields.Char(_('Код договора из 1С'))
|
||||||
buh_code = fields.Char('Код договора из бухгалтерии')
|
buh_code = fields.Char(_('Код договора из бухгалтерии'))
|
||||||
payment_term_id = fields.Many2one('account.payment.term', string='Условие оплаты')
|
payment_term_id = fields.Many2one('account.payment.term', string=_('Условие оплаты'))
|
||||||
manager_id = fields.Many2one('res.users', string='Менеджер по продажам')
|
manager_id = fields.Many2one('res.users', string=_('Менеджер по продажам'))
|
||||||
accountant_id = fields.Many2one('res.users', string='Бухгалтер по взаиморасчетам')
|
accountant_id = fields.Many2one('res.users', string=_('Бухгалтер по взаиморасчетам'))
|
||||||
time_to_delivery_from = fields.Datetime('Время доставки от')
|
time_to_delivery_from = fields.Datetime(_('Время доставки от'))
|
||||||
time_to_delivery_to = fields.Datetime('Время доставки до')
|
time_to_delivery_to = fields.Datetime(_('Время доставки до'))
|
||||||
day_of_delivery = fields.Float('Дни доставки')
|
day_of_delivery = fields.Float(_('Дни доставки'))
|
||||||
day_of_otgruzki = fields.Float('Дни отгрузки')
|
day_of_otgruzki = fields.Float(_('Дни отгрузки'))
|
||||||
|
|
||||||
channel_id = fields.Many2one('saleorder.channel', string='Канал продаж')
|
channel_id = fields.Many2one('saleorder.channel', string=_('Канал продаж'))
|
||||||
team_id = fields.Many2one('crm.team', string='Команда продаж')
|
team_id = fields.Many2one('crm.team', string=_('Команда продаж'))
|
||||||
order_days_ids = fields.Many2many(comodel_name='contract.day', relation='orderdays', string='Дни доставки',
|
order_days_ids = fields.Many2many(comodel_name='contract.day', relation='orderdays', string=_('Дни доставки'),
|
||||||
column1='contract_id', column2='day_id')
|
column1='contract_id', column2='day_id')
|
||||||
shipment_days_ids = fields.Many2many(comodel_name='contract.day', relation='shipmentdays', string='Дни отгрузки',
|
shipment_days_ids = fields.Many2many(comodel_name='contract.day', relation='shipmentdays', string=_('Дни отгрузки'),
|
||||||
column1='contract_id',
|
column1='contract_id',
|
||||||
column2='day_id')
|
column2='day_id')
|
||||||
# Доработка хедера договора
|
# Доработка хедера договора
|
||||||
partner_type = fields.Selection(string='Тип контрагента', selection=[
|
partner_type = fields.Selection(string=_('Тип контрагента'), selection=[
|
||||||
('person', 'Физ. лицо'),
|
('person', 'Физ. лицо'),
|
||||||
('company_ip', 'ИП'),
|
('company_ip', 'ИП'),
|
||||||
('company', 'Юр. лицо')
|
('company', 'Юр. лицо')
|
||||||
], required=True)
|
], required=True)
|
||||||
contract_header = fields.Html('Шапка договора')
|
contract_header = fields.Html(_('Шапка договора'))
|
||||||
|
|
||||||
@api.onchange('partner_type')
|
@api.onchange('partner_type')
|
||||||
def generate_contract_header(self):
|
def generate_contract_header(self):
|
||||||
@ -94,7 +94,7 @@ class PartnerContractCustomer(models.Model):
|
|||||||
def set_pid(self):
|
def set_pid(self):
|
||||||
self.partner_id = self.sec_partner_id.parent_id if self.sec_partner_id.parent_id else self.sec_partner_id
|
self.partner_id = self.sec_partner_id.parent_id if self.sec_partner_id.parent_id else self.sec_partner_id
|
||||||
|
|
||||||
def _expand_states(self, states, domain, order):
|
def _expand_states(self, states, domain):
|
||||||
return [key for key, val in type(self).state.selection]
|
return [key for key, val in type(self).state.selection]
|
||||||
|
|
||||||
def copy_it(self):
|
def copy_it(self):
|
||||||
@ -218,8 +218,8 @@ class PartnerContractCustomer(models.Model):
|
|||||||
if self.saleorder_id:
|
if self.saleorder_id:
|
||||||
return self.saleorder_id.print_contract()
|
return self.saleorder_id.print_contract()
|
||||||
else:
|
else:
|
||||||
raise exceptions.UserError(
|
raise exceptions.UserError(_(
|
||||||
'Вы не можете напечатать договор с Клиентом, потому что нет связи с Заказом. Нужно зайти в Заказ и привязать этот договор.')
|
'Вы не можете напечатать договор с Клиентом, потому что нет связи с Заказом. Нужно зайти в Заказ и привязать этот договор.'))
|
||||||
|
|
||||||
def contract_action_confirm(self):
|
def contract_action_confirm(self):
|
||||||
if self.state == 'draft':
|
if self.state == 'draft':
|
||||||
@ -249,7 +249,7 @@ class PartnerContractCustomer(models.Model):
|
|||||||
def check_name(self):
|
def check_name(self):
|
||||||
obj = self.search([('name', '=', self.name), ('id', '!=', self.id), ('state', '!=', 'closed')])
|
obj = self.search([('name', '=', self.name), ('id', '!=', self.id), ('state', '!=', 'closed')])
|
||||||
if obj:
|
if obj:
|
||||||
raise exceptions.ValidationError('Договор с таким номером уже существует')
|
raise exceptions.ValidationError(_('Договор с таким номером уже существует'))
|
||||||
|
|
||||||
"""
|
"""
|
||||||
@api.constrains('profile_id')
|
@api.constrains('profile_id')
|
||||||
@ -270,8 +270,8 @@ class PartnerContractCustomer(models.Model):
|
|||||||
class Partner(models.Model):
|
class Partner(models.Model):
|
||||||
_inherit = 'res.partner'
|
_inherit = 'res.partner'
|
||||||
|
|
||||||
contract_count = fields.Integer(string='Договоры', compute='get_count_contract')
|
contract_count = fields.Integer(string=_('Договоры'), compute='get_count_contract')
|
||||||
pol = fields.Selection(string="Пол", selection=[('m', 'Муж.'), ('j', 'Жен'), ], required=False)
|
pol = fields.Selection(string=_("Пол"), selection=[('m', 'Муж.'), ('j', 'Жен'), ], required=False)
|
||||||
type = fields.Selection(selection_add=[('director', 'Директор')])
|
type = fields.Selection(selection_add=[('director', 'Директор')])
|
||||||
|
|
||||||
def get_count_contract(self):
|
def get_count_contract(self):
|
||||||
@ -306,8 +306,8 @@ class ContractLine(models.Model):
|
|||||||
|
|
||||||
class AllowedProfiles(models.Model):
|
class AllowedProfiles(models.Model):
|
||||||
_name = 'contract.allowed.profiles'
|
_name = 'contract.allowed.profiles'
|
||||||
name = fields.Char(string='Одновременно включены следующие виды договоров:')
|
name = fields.Char(string=_('Одновременно включены следующие виды договоров:'))
|
||||||
allowed_profiles = fields.Many2many('contract.profile', string='Виды договоров', required=True)
|
allowed_profiles = fields.Many2many('contract.profile', string=_('Виды договоров'), required=True)
|
||||||
|
|
||||||
@api.onchange('allowed_profiles')
|
@api.onchange('allowed_profiles')
|
||||||
def set_name(self):
|
def set_name(self):
|
||||||
@ -321,14 +321,14 @@ class AllowedProfiles(models.Model):
|
|||||||
|
|
||||||
class ContractProfile(models.Model):
|
class ContractProfile(models.Model):
|
||||||
_name = 'contract.profile'
|
_name = 'contract.profile'
|
||||||
name = fields.Char(string='Вид договора', required=True)
|
name = fields.Char(string=_('Вид договора'), required=True)
|
||||||
payable_account_id = fields.Many2one('account.account', string='Счет кредиторской задолженности', required=True)
|
payable_account_id = fields.Many2one('account.account', string=_('Счет кредиторской задолженности'), required=True)
|
||||||
receivable_account_id = fields.Many2one('account.account', string='Счет дебиторской задолженности', required=True)
|
receivable_account_id = fields.Many2one('account.account', string=_('Счет дебиторской задолженности'), required=True)
|
||||||
max_receivable_id = fields.Float(string='Максимальная деб. задолженность', required=True)
|
max_receivable_id = fields.Float(string=_('Максимальная деб. задолженность'), required=True)
|
||||||
payment_term_id = fields.Many2one('account.payment.term', string='Условие оплаты', required=True)
|
payment_term_id = fields.Many2one('account.payment.term', string=_('Условие оплаты'), required=True)
|
||||||
journal_id = fields.Many2one('account.journal', string='Журнал', required=True)
|
journal_id = fields.Many2one('account.journal', string=_('Журнал'), required=True)
|
||||||
|
|
||||||
|
|
||||||
class ContractDay(models.Model):
|
class ContractDay(models.Model):
|
||||||
_name = 'contract.day'
|
_name = 'contract.day'
|
||||||
name = fields.Char('День')
|
name = fields.Char(_('День'))
|
||||||
|
@ -1,128 +0,0 @@
|
|||||||
from odoo import api, fields, models, exceptions
|
|
||||||
from datetime import datetime
|
|
||||||
|
|
||||||
|
|
||||||
class contract_sale_order(models.Model):
|
|
||||||
_inherit = 'sale.order'
|
|
||||||
mt_contractid = fields.Many2one('partner.contract.customer', string='Номер договора')
|
|
||||||
sec_partner_id = fields.Many2one('res.partner', string='Контрагент', store=True, compute='get_pid')
|
|
||||||
stamp = fields.Boolean(string='Печать и подпись', related='mt_contractid.stamp')
|
|
||||||
|
|
||||||
@api.depends('partner_id')
|
|
||||||
def get_pid(self):
|
|
||||||
for s in self:
|
|
||||||
s.sec_partner_id = s.partner_id.parent_id if s.partner_id.parent_id else s.partner_id
|
|
||||||
|
|
||||||
@api.onchange('mt_contractid')
|
|
||||||
def set_ons(self):
|
|
||||||
if self.mt_contractid:
|
|
||||||
self.payment_term_id = self.mt_contractid.payment_term_id
|
|
||||||
|
|
||||||
@api.constrains('state')
|
|
||||||
def late_payment_check(self):
|
|
||||||
if self.mt_contractid:
|
|
||||||
if self.state == 'sale':
|
|
||||||
late_invoices_count = 0
|
|
||||||
max_receivable = self.mt_contractid.profile_id.max_receivable_id # макс. деб. задолженность в договоре
|
|
||||||
# ищу просроченные инвойсы контрагента указанного в заказе со стейтом "Подтверждено"
|
|
||||||
invoices_obj = self.env['account.move'].search([('partner_id', '=', self.partner_id.id),
|
|
||||||
('state', '=', 'posted'),
|
|
||||||
('invoice_date_due', '<', datetime.now().date())])
|
|
||||||
|
|
||||||
for invoice in invoices_obj:
|
|
||||||
late_invoices_count += invoice.amount_residual # складываю деб. задолженность по просроченным инвойсам
|
|
||||||
|
|
||||||
if late_invoices_count > max_receivable:
|
|
||||||
raise exceptions.ValidationError(
|
|
||||||
f'Нельзя подтвердить заказ, так как у контрагента {self.sec_partner_id.name} нарушено '
|
|
||||||
f'условие по дебиторской задолженности.\n\n'
|
|
||||||
f'Контрагент {self.sec_partner_id.name} должен {late_invoices_count}руб.\n'
|
|
||||||
f'Максимальная дебиторская задолженность указанная в '
|
|
||||||
f'договоре №{self.mt_contractid.name} - {max_receivable}руб.\n\n'
|
|
||||||
f'Проверьте следующие неоплаченные счета контрагента:\n'
|
|
||||||
f'{", ".join([invoice.name for invoice in invoices_obj])}')
|
|
||||||
|
|
||||||
# при выбора счета "Обычный счет"
|
|
||||||
@api.model
|
|
||||||
def _create_invoices(self, grouped=False, final=False, date=None):
|
|
||||||
res = super(contract_sale_order, self)._create_invoices(grouped, final, date)
|
|
||||||
if self.mt_contractid:
|
|
||||||
res.write({'mt_contractid': self.mt_contractid,
|
|
||||||
'journal_id': self.mt_contractid.profile_id.journal_id})
|
|
||||||
# 'invoice_payment_term_id': self.mt_contractid.profile_id.payment_term_id
|
|
||||||
# 'line_ids': [(0, 0, {
|
|
||||||
# 'account_id': self.mt_contractid.profile_id.receivable_account_id.id})]
|
|
||||||
return res
|
|
||||||
|
|
||||||
|
|
||||||
class ContractCreateInvoice(models.TransientModel):
|
|
||||||
_inherit = 'sale.advance.payment.inv'
|
|
||||||
|
|
||||||
# при выбора счета "Авансовый платеж"
|
|
||||||
@api.model
|
|
||||||
def _create_invoice(self, order, so_line, amount):
|
|
||||||
res = super(ContractCreateInvoice, self)._create_invoice(order, so_line, amount)
|
|
||||||
if order.mt_contractid:
|
|
||||||
res.write({'mt_contractid': order.mt_contractid,
|
|
||||||
'journal_id': order.mt_contractid.profile_id.journal_id, })
|
|
||||||
# 'invoice_payment_term_id': order.mt_contractid.profile_id.payment_term_id
|
|
||||||
return res
|
|
||||||
|
|
||||||
|
|
||||||
class contract_invoice(models.Model):
|
|
||||||
_inherit = 'account.move'
|
|
||||||
mt_contractid = fields.Many2one('partner.contract.customer', string='Номер договора')
|
|
||||||
sf_number = fields.Char(string='Номер с/ф')
|
|
||||||
osnovanie = fields.Char(string='Основание')
|
|
||||||
sec_partner_id = fields.Many2one('res.partner', string='Контрагент', store=True, compute='get_pid')
|
|
||||||
stamp = fields.Boolean(string='Печать и подпись', related='mt_contractid.stamp')
|
|
||||||
|
|
||||||
@api.depends('partner_id')
|
|
||||||
def get_pid(self):
|
|
||||||
for s in self:
|
|
||||||
s.sec_partner_id = s.partner_id.parent_id if s.partner_id.parent_id else s.partner_id
|
|
||||||
|
|
||||||
@api.onchange('mt_contractid')
|
|
||||||
def set_ons(self):
|
|
||||||
if self.mt_contractid:
|
|
||||||
self.osnovanie = 'Договор № ' + self.mt_contractid.name + ' от ' + fields.Datetime.from_string(
|
|
||||||
self.mt_contractid.date_start).strftime("%d.%m.%Y")
|
|
||||||
|
|
||||||
@api.constrains('state')
|
|
||||||
def invoice_fields_check(self):
|
|
||||||
for s in self:
|
|
||||||
if s.state == 'posted':
|
|
||||||
if s.mt_contractid:
|
|
||||||
errors_list = []
|
|
||||||
journal_in_contract = s.mt_contractid.profile_id.journal_id
|
|
||||||
payment_term_in_contract = s.mt_contractid.profile_id.payment_term_id
|
|
||||||
receivable_in_contract = s.mt_contractid.profile_id.receivable_account_id
|
|
||||||
|
|
||||||
if journal_in_contract != s.journal_id:
|
|
||||||
errors_list.append(f'Отличается Журнал - [{s.journal_id.name}] '
|
|
||||||
f'и указанный в договоре №{s.mt_contractid.name} '
|
|
||||||
f'Журнал - [{journal_in_contract.name}]\n\n')
|
|
||||||
|
|
||||||
if payment_term_in_contract != s.invoice_payment_term_id:
|
|
||||||
errors_list.append(f'Отличается поле "Условие оплаты" в инвойсе '
|
|
||||||
f'[Условие оплаты - {s.invoice_payment_term_id.name}] '
|
|
||||||
f'и указанный в договоре №{s.mt_contractid.name} '
|
|
||||||
f'[Условие оплаты - {payment_term_in_contract.name}]\n\n')
|
|
||||||
|
|
||||||
if receivable_in_contract not in s.line_ids.account_id:
|
|
||||||
errors_list.append(f'Отличается поле "Счет дебиторской задолженности" в инвойсе '
|
|
||||||
f'и указанный в договоре №{s.mt_contractid.name}')
|
|
||||||
|
|
||||||
if errors_list:
|
|
||||||
raise exceptions.ValidationError(''.join(errors_list))
|
|
||||||
|
|
||||||
|
|
||||||
class contact_purchase_order(models.Model):
|
|
||||||
_inherit = 'purchase.order'
|
|
||||||
mt_contractid = fields.Many2one('partner.contract.customer', string='Номер договора')
|
|
||||||
sec_partner_id = fields.Many2one('res.partner', string='Контрагент', store=True, compute='get_pid')
|
|
||||||
|
|
||||||
@api.depends('partner_id')
|
|
||||||
def get_pid(self):
|
|
||||||
for s in self:
|
|
||||||
s.sec_partner_id = s.partner_id.parent_id if s.partner_id.parent_id else s.partner_id
|
|
13
l10n_ru_contract/models/purchase_order.py
Normal file
13
l10n_ru_contract/models/purchase_order.py
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
from odoo import api, fields, models, exceptions, _
|
||||||
|
|
||||||
|
|
||||||
|
class PurchaseOrder(models.Model):
|
||||||
|
_inherit = 'purchase.order'
|
||||||
|
|
||||||
|
mt_contract_id = fields.Many2one('partner.contract.customer', string=_('Номер договора'))
|
||||||
|
sec_partner_id = fields.Many2one('res.partner', string=_('Контрагент'), store=True, compute='_compute_get_pid')
|
||||||
|
|
||||||
|
@api.depends('partner_id')
|
||||||
|
def _compute_get_pid(self):
|
||||||
|
for s in self:
|
||||||
|
s.sec_partner_id = s.partner_id.parent_id if s.partner_id.parent_id else s.partner_id
|
18
l10n_ru_contract/models/sale_make_invoice_advance.py
Normal file
18
l10n_ru_contract/models/sale_make_invoice_advance.py
Normal file
@ -0,0 +1,18 @@
|
|||||||
|
from odoo import api, fields, models
|
||||||
|
|
||||||
|
|
||||||
|
class ContractCreateInvoice(models.TransientModel):
|
||||||
|
_inherit = 'sale.advance.payment.inv'
|
||||||
|
|
||||||
|
# # при выбора счета "Авансовый платеж"
|
||||||
|
# @api.model
|
||||||
|
# def _create_invoice(self, order, so_line, amount):
|
||||||
|
# res = super(ContractCreateInvoice, self)._create_invoice(order, so_line, amount)
|
||||||
|
# if order.mt_contract_id:
|
||||||
|
# res.write({'mt_contract_id': order.mt_contract_id,
|
||||||
|
# 'journal_id': order.mt_contract_id.profile_id.journal_id, })
|
||||||
|
# return res
|
||||||
|
def _prepare_invoice_values(self, order, name, amount):
|
||||||
|
invoice_vals = super(ContractCreateInvoice, self)._prepare_invoice_values(order, name, amount)
|
||||||
|
invoice_vals['mt_contract_id'] = order.mt_contract_id.id
|
||||||
|
return invoice_vals
|
62
l10n_ru_contract/models/sale_order.py
Normal file
62
l10n_ru_contract/models/sale_order.py
Normal file
@ -0,0 +1,62 @@
|
|||||||
|
from odoo import api, fields, models, exceptions, _
|
||||||
|
from datetime import datetime
|
||||||
|
|
||||||
|
|
||||||
|
class SaleOrder(models.Model):
|
||||||
|
_inherit = 'sale.order'
|
||||||
|
|
||||||
|
mt_contract_id = fields.Many2one('partner.contract.customer', string=_('Номер договора'))
|
||||||
|
sec_partner_id = fields.Many2one('res.partner', string=_('Контрагент'), store=True, compute='_compute_get_pid')
|
||||||
|
stamp = fields.Boolean(string=_('Печать и подпись'), related='mt_contract_id.stamp')
|
||||||
|
|
||||||
|
@api.depends('partner_id')
|
||||||
|
def _compute_get_pid(self):
|
||||||
|
for s in self:
|
||||||
|
s.sec_partner_id = s.partner_id.parent_id if s.partner_id.parent_id else s.partner_id
|
||||||
|
|
||||||
|
@api.onchange('mt_contract_id')
|
||||||
|
def set_ons(self):
|
||||||
|
if self.mt_contract_id:
|
||||||
|
self.payment_term_id = self.mt_contract_id.payment_term_id
|
||||||
|
|
||||||
|
@api.constrains('state')
|
||||||
|
def late_payment_check(self):
|
||||||
|
if self.mt_contract_id:
|
||||||
|
if self.state == 'sale':
|
||||||
|
late_invoices_count = 0
|
||||||
|
max_receivable = self.mt_contract_id.profile_id.max_receivable_id # макс. деб. задолженность в договоре
|
||||||
|
# ищу просроченные инвойсы контрагента указанного в заказе со стейтом "Подтверждено"
|
||||||
|
invoices_obj = self.env['account.move'].search([('partner_id', '=', self.partner_id.id),
|
||||||
|
('state', '=', 'posted'),
|
||||||
|
('invoice_date_due', '<', datetime.now().date())])
|
||||||
|
|
||||||
|
for invoice in invoices_obj:
|
||||||
|
late_invoices_count += invoice.amount_residual # складываю деб. задолженность по просроченным инвойсам
|
||||||
|
|
||||||
|
if late_invoices_count > max_receivable:
|
||||||
|
raise exceptions.ValidationError(
|
||||||
|
f'Нельзя подтвердить заказ, так как у контрагента {self.sec_partner_id.name} нарушено '
|
||||||
|
f'условие по дебиторской задолженности.\n\n'
|
||||||
|
f'Контрагент {self.sec_partner_id.name} должен {late_invoices_count}руб.\n'
|
||||||
|
f'Максимальная дебиторская задолженность указанная в '
|
||||||
|
f'договоре №{self.mt_contract_id.name} - {max_receivable}руб.\n\n'
|
||||||
|
f'Проверьте следующие неоплаченные счета контрагента:\n'
|
||||||
|
f'{", ".join([invoice.name for invoice in invoices_obj])}')
|
||||||
|
|
||||||
|
# # при выбора счета "Обычный счет"
|
||||||
|
# @api.model
|
||||||
|
# def _create_invoices(self, grouped=False, final=False, date=None):
|
||||||
|
# res = super(SaleOrder, self)._create_invoices(grouped, final, date)
|
||||||
|
# if self.mt_contract_id:
|
||||||
|
# res.write({'mt_contract_id': self.mt_contract_id,
|
||||||
|
# 'journal_id': self.mt_contract_id.profile_id.journal_id})
|
||||||
|
# return res
|
||||||
|
def _get_invoice_grouping_keys(self):
|
||||||
|
res = super(SaleOrder, self)._get_invoice_grouping_keys()
|
||||||
|
res.append('mt_contract_id')
|
||||||
|
return res #['company_id', 'partner_id', 'currency_id', 'mt_contractid']
|
||||||
|
|
||||||
|
def _prepare_invoice(self):
|
||||||
|
invoice_vals = super(SaleOrder, self)._prepare_invoice()
|
||||||
|
invoice_vals['mt_contract_id'] = self.mt_contract_id.id
|
||||||
|
return invoice_vals
|
@ -1,2 +1,4 @@
|
|||||||
# -*- coding: utf-8 -*-
|
# -*- coding: utf-8 -*-
|
||||||
from . import report_contract,report_contract_order,report_contract_invoce
|
from . import report_contract
|
||||||
|
from . import report_contract_order
|
||||||
|
from . import report_contract_invoice
|
||||||
|
BIN
l10n_ru_contract/report/__pycache__/__init__.cpython-310.pyc
Normal file
BIN
l10n_ru_contract/report/__pycache__/__init__.cpython-310.pyc
Normal file
Binary file not shown.
BIN
l10n_ru_contract/report/__pycache__/__init__.cpython-311.pyc
Normal file
BIN
l10n_ru_contract/report/__pycache__/__init__.cpython-311.pyc
Normal file
Binary file not shown.
BIN
l10n_ru_contract/report/__pycache__/__init__.cpython-35.pyc
Normal file
BIN
l10n_ru_contract/report/__pycache__/__init__.cpython-35.pyc
Normal file
Binary file not shown.
BIN
l10n_ru_contract/report/__pycache__/__init__.cpython-36.pyc
Normal file
BIN
l10n_ru_contract/report/__pycache__/__init__.cpython-36.pyc
Normal file
Binary file not shown.
BIN
l10n_ru_contract/report/__pycache__/__init__.cpython-37.pyc
Normal file
BIN
l10n_ru_contract/report/__pycache__/__init__.cpython-37.pyc
Normal file
Binary file not shown.
BIN
l10n_ru_contract/report/__pycache__/__init__.cpython-38.pyc
Normal file
BIN
l10n_ru_contract/report/__pycache__/__init__.cpython-38.pyc
Normal file
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
l10n_ru_contract/report/__pycache__/report_helper.cpython-36.pyc
Normal file
BIN
l10n_ru_contract/report/__pycache__/report_helper.cpython-36.pyc
Normal file
Binary file not shown.
@ -388,10 +388,10 @@
|
|||||||
<field name="name">Договор</field>
|
<field name="name">Договор</field>
|
||||||
<field name="model">partner.contract.customer</field>
|
<field name="model">partner.contract.customer</field>
|
||||||
<field name="report_type">qweb-pdf</field>
|
<field name="report_type">qweb-pdf</field>
|
||||||
<field name="report_name">contract.report_contract_customer</field>
|
<field name="report_name">l10n_ru_contract.report_contract_customer</field>
|
||||||
<field name="report_file">contract.report_contract_customer</field>
|
<field name="report_file">l10n_ru_contract.report_contract_customer</field>
|
||||||
<field name="print_report_name">'Договор - %s' % (object.name)</field>
|
<field name="print_report_name">'Договор - %s' % (object.name)</field>
|
||||||
<field name="binding_model_id" ref="contract.model_partner_contract_customer" />
|
<field name="binding_model_id" ref="l10n_ru_contract.model_partner_contract_customer" />
|
||||||
<field name="paperformat_id" ref="paperformat_a4" />
|
<field name="paperformat_id" ref="paperformat_a4" />
|
||||||
<field name="binding_type">report</field>
|
<field name="binding_type">report</field>
|
||||||
</record>
|
</record>
|
||||||
|
@ -2,8 +2,8 @@
|
|||||||
from odoo import api, models
|
from odoo import api, models
|
||||||
|
|
||||||
|
|
||||||
class ContractCustomerReportOrder(models.AbstractModel):
|
class ContractCustomerReportInvoice(models.AbstractModel):
|
||||||
_name = 'contract.customer.report_invoce'
|
_name = 'contract.customer.report_invoice'
|
||||||
|
|
||||||
|
|
||||||
def get_report_values(self, docids, data=None):
|
def get_report_values(self, docids, data=None):
|
@ -1,6 +1,6 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
<odoo>
|
<odoo>
|
||||||
<template id="report_contract_customer_invoce">
|
<template id="report_contract_customer_invoice">
|
||||||
<t t-call="web.basic_layout">
|
<t t-call="web.basic_layout">
|
||||||
<t t-foreach="docs" t-as="o">
|
<t t-foreach="docs" t-as="o">
|
||||||
<t t-if="o and 'company_id' in o">
|
<t t-if="o and 'company_id' in o">
|
||||||
@ -23,9 +23,9 @@
|
|||||||
<table border="0" cellpadding="0" cellspacing="0" style="width:100%">
|
<table border="0" cellpadding="0" cellspacing="0" style="width:100%">
|
||||||
<tbody>
|
<tbody>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C0"><t t-esc="o.mt_contractid.company_id.name or ''"/></td>
|
<td class="R0C0"><t t-esc="o.mt_contract_id.company_id.name or ''"/></td>
|
||||||
<td class="R0C1">Договор <t t-esc="o.mt_contractid.name or ''"/> от <t
|
<td class="R0C1">Договор <t t-esc="o.mt_contract_id.name or ''"/> от <t
|
||||||
t-esc="o.mt_contractid.date_start or ''"/></td>
|
t-esc="o.mt_contract_id.date_start or ''"/></td>
|
||||||
</tr>
|
</tr>
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
@ -93,7 +93,7 @@
|
|||||||
<table border="0" cellpadding="0" cellspacing="0" style="width:100%; page-break-inside: auto;">
|
<table border="0" cellpadding="0" cellspacing="0" style="width:100%; page-break-inside: auto;">
|
||||||
<tbody>
|
<tbody>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C0" colspan="2">Договор № <t t-esc="o.mt_contractid.name or ''"/></td>
|
<td class="R0C0" colspan="2">Договор № <t t-esc="o.mt_contract_id.name or ''"/></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C0" colspan="2">на поставку продукции</td>
|
<td class="R0C0" colspan="2">на поставку продукции</td>
|
||||||
@ -103,9 +103,9 @@
|
|||||||
<td class="R0C2"></td>
|
<td class="R0C2"></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C1"><t t-esc="o.mt_contractid.company_id.partner_id.city or ''"/></td>
|
<td class="R0C1"><t t-esc="o.mt_contract_id.company_id.partner_id.city or ''"/></td>
|
||||||
<td class="R0C2"><t
|
<td class="R0C2"><t
|
||||||
t-esc="o.mt_contractid.get_date_text(o.mt_contractid.date_start) or ''"/></td>
|
t-esc="o.mt_contract_id.get_date_text(o.mt_contract_id.date_start) or ''"/></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C1"></td>
|
<td class="R0C1"></td>
|
||||||
@ -114,7 +114,7 @@
|
|||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C3" colspan="2">
|
<td class="R0C3" colspan="2">
|
||||||
<span>
|
<span>
|
||||||
<t t-raw="o.mt_contractid.contract_header or ''"/>
|
<t t-raw="o.mt_contract_id.contract_header or ''"/>
|
||||||
</span>
|
</span>
|
||||||
</td>
|
</td>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
@ -122,7 +122,7 @@
|
|||||||
<td class="R0C2"></td>
|
<td class="R0C2"></td>
|
||||||
</tr>
|
</tr>
|
||||||
</tr>
|
</tr>
|
||||||
<!--t t-foreach="o.mt_contractid.lines.sorted(key=lambda r: r.sequence, reverse=False)" t-as="line">
|
<!--t t-foreach="o.mt_contract_id.lines.sorted(key=lambda r: r.sequence, reverse=False)" t-as="line">
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C4" colspan="2"><t t-esc="line.name"/></td>
|
<td class="R0C4" colspan="2"><t t-esc="line.name"/></td>
|
||||||
</tr>
|
</tr>
|
||||||
@ -142,7 +142,7 @@
|
|||||||
</tr-->
|
</tr-->
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
<t t-foreach="o.mt_contractid.lines.sorted(key=lambda r: r.sequence, reverse=False)" t-as="line">
|
<t t-foreach="o.mt_contract_id.lines.sorted(key=lambda r: r.sequence, reverse=False)" t-as="line">
|
||||||
<p class="R0C4"><t t-esc="line.name or ''"/></p>
|
<p class="R0C4"><t t-esc="line.name or ''"/></p>
|
||||||
<div class="R0C5"><span><t t-raw="line.punct or ''"/></span></div>
|
<div class="R0C5"><span><t t-raw="line.punct or ''"/></span></div>
|
||||||
</t>
|
</t>
|
||||||
@ -165,24 +165,24 @@
|
|||||||
<td class="R0C6rtl" colspan="3">Покупатель:</td>
|
<td class="R0C6rtl" colspan="3">Покупатель:</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C6rl" colspan="3"><t t-esc="o.mt_contractid.company_id.name or ''"/></td>
|
<td class="R0C6rl" colspan="3"><t t-esc="o.mt_contract_id.company_id.name or ''"/></td>
|
||||||
<td class="R0C6rl" colspan="3"><t t-esc="o.mt_contractid.partner_id.name or ''"/></td>
|
<td class="R0C6rl" colspan="3"><t t-esc="o.mt_contract_id.partner_id.name or ''"/></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C6l" colspan="3">ИНН
|
<td class="R0C6l" colspan="3">ИНН
|
||||||
<t t-esc="o.mt_contractid.company_id.inn or ''"/>
|
<t t-esc="o.mt_contract_id.company_id.inn or ''"/>
|
||||||
</td>
|
</td>
|
||||||
<td class="R0C7rl" colspan="3">ИНН <t
|
<td class="R0C7rl" colspan="3">ИНН <t
|
||||||
t-esc="o.mt_contractid.partner_id.inn or ''"/></td>
|
t-esc="o.mt_contract_id.partner_id.inn or ''"/></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C6l" colspan="2">ОГРН
|
<td class="R0C6l" colspan="2">ОГРН
|
||||||
<t t-esc="o.company_id.company_registry or ''"/>
|
<t t-esc="o.company_id.company_registry or ''"/>
|
||||||
</td>
|
</td>
|
||||||
<td class="R0C6r" rowspan="2">
|
<td class="R0C6r" rowspan="2">
|
||||||
<t t-esc="o.mt_contractid.name_dirprint1 or ''"/>
|
<t t-esc="o.mt_contract_id.name_dirprint1 or ''"/>
|
||||||
</td>
|
</td>
|
||||||
<t t-if="o.mt_contractid.partner_type in ['company', 'company_ip']">
|
<t t-if="o.mt_contract_id.partner_type in ['company', 'company_ip']">
|
||||||
<td class="R0C7rl" colspan="3">ОГРН
|
<td class="R0C7rl" colspan="3">ОГРН
|
||||||
<t t-esc="o.partner_id.ogrn or ''"/>
|
<t t-esc="o.partner_id.ogrn or ''"/>
|
||||||
</td>
|
</td>
|
||||||
@ -195,9 +195,9 @@
|
|||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C6l" colspan="3">КПП
|
<td class="R0C6l" colspan="3">КПП
|
||||||
<t t-esc="o.mt_contractid.company_id.kpp or ''"/>
|
<t t-esc="o.mt_contract_id.company_id.kpp or ''"/>
|
||||||
</td>
|
</td>
|
||||||
<t t-if="o.mt_contractid.partner_type == 'company'">
|
<t t-if="o.mt_contract_id.partner_type == 'company'">
|
||||||
<td class="R0C7rl" colspan="3">КПП
|
<td class="R0C7rl" colspan="3">КПП
|
||||||
<t t-esc="o.partner_id.kpp or ''"/>
|
<t t-esc="o.partner_id.kpp or ''"/>
|
||||||
</td>
|
</td>
|
||||||
@ -214,10 +214,10 @@
|
|||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C6l" colspan="3">
|
<td class="R0C6l" colspan="3">
|
||||||
<t t-esc="o.mt_contractid.address(o.company_id) or ''"/>
|
<t t-esc="o.mt_contract_id.address(o.company_id) or ''"/>
|
||||||
</td>
|
</td>
|
||||||
<td class="R0C7rl" colspan="3">
|
<td class="R0C7rl" colspan="3">
|
||||||
<t t-esc="o.mt_contractid.address(o.partner_id) or ''"/>
|
<t t-esc="o.mt_contract_id.address(o.partner_id) or ''"/>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
@ -236,12 +236,12 @@
|
|||||||
<td class="R0C6l"></td>
|
<td class="R0C6l"></td>
|
||||||
<td class="R0C6tI">
|
<td class="R0C6tI">
|
||||||
<SPAN>
|
<SPAN>
|
||||||
<t t-raw="o.stamp and o.mt_contractid.img(o.company_id.chief_id.facsimile) or ''"/>
|
<t t-raw="o.stamp and o.mt_contract_id.img(o.company_id.chief_id.facsimile) or ''"/>
|
||||||
</SPAN>
|
</SPAN>
|
||||||
</td>
|
</td>
|
||||||
<td class="R0C6tS">
|
<td class="R0C6tS">
|
||||||
<SPAN>
|
<SPAN>
|
||||||
<t t-raw="o.stamp and o.mt_contractid.img(o.company_id.stamp) or ''"/>
|
<t t-raw="o.stamp and o.mt_contract_id.img(o.company_id.stamp) or ''"/>
|
||||||
</SPAN>
|
</SPAN>
|
||||||
</td>
|
</td>
|
||||||
<td class="R0C6rl" colspan="3"></td>
|
<td class="R0C6rl" colspan="3"></td>
|
||||||
@ -281,8 +281,8 @@
|
|||||||
<tbody>
|
<tbody>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C8" colspan="8">Приложение<br/>к договору № <t
|
<td class="R0C8" colspan="8">Приложение<br/>к договору № <t
|
||||||
t-esc="o.mt_contractid.name"/><br/>на поставку продукции<br/>от <t
|
t-esc="o.mt_contract_id.name"/><br/>на поставку продукции<br/>от <t
|
||||||
t-esc="o.mt_contractid.get_date_text(o.mt_contractid.date_start) or ''"/></td>
|
t-esc="o.mt_contract_id.get_date_text(o.mt_contract_id.date_start) or ''"/></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C0" colspan="8"></td>
|
<td class="R0C0" colspan="8"></td>
|
||||||
@ -295,9 +295,9 @@
|
|||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C1" colspan="4"><t
|
<td class="R0C1" colspan="4"><t
|
||||||
t-esc="o.mt_contractid.company_id.partner_id.city or ''"/></td>
|
t-esc="o.mt_contract_id.company_id.partner_id.city or ''"/></td>
|
||||||
<td class="R0C2" colspan="4"><t
|
<td class="R0C2" colspan="4"><t
|
||||||
t-esc="o.mt_contractid.get_date_text(o.mt_contractid.date_start) or ''"/></td>
|
t-esc="o.mt_contract_id.get_date_text(o.mt_contract_id.date_start) or ''"/></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C0" colspan="8"></td>
|
<td class="R0C0" colspan="8"></td>
|
||||||
@ -305,7 +305,7 @@
|
|||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C3" colspan="8">
|
<td class="R0C3" colspan="8">
|
||||||
<span>
|
<span>
|
||||||
<t t-raw="o.mt_contractid.contract_header or ''"/>
|
<t t-raw="o.mt_contract_id.contract_header or ''"/>
|
||||||
</span>
|
</span>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
@ -314,8 +314,8 @@
|
|||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C5" colspan="8">1. По договору на поставку продукции <t
|
<td class="R0C5" colspan="8">1. По договору на поставку продукции <t
|
||||||
t-esc="o.mt_contractid.name or ''"/> от <t
|
t-esc="o.mt_contract_id.name or ''"/> от <t
|
||||||
t-esc="o.mt_contractid.get_date_text(o.mt_contractid.date_start) or ''"/>.
|
t-esc="o.mt_contract_id.get_date_text(o.mt_contract_id.date_start) or ''"/>.
|
||||||
Поставщик обязуется поставить, а Покупатель оплатить в полном объеме следующее:</td>
|
Поставщик обязуется поставить, а Покупатель оплатить в полном объеме следующее:</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
@ -363,18 +363,18 @@
|
|||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C5" colspan="8">Итого: <t t-esc="sum_full or ''"/> рублей (<t
|
<td class="R0C5" colspan="8">Итого: <t t-esc="sum_full or ''"/> рублей (<t
|
||||||
t-esc="o.mt_contractid.rubles(sum_full) or ''"/>). В стоимость продукции входит стоимость
|
t-esc="o.mt_contract_id.rubles(sum_full) or ''"/>). В стоимость продукции входит стоимость
|
||||||
тары и стоимость транспортных расходов, связанных с доставкой продукции до станции
|
тары и стоимость транспортных расходов, связанных с доставкой продукции до станции
|
||||||
назначения.<br/>
|
назначения.<br/>
|
||||||
2. Базис поставки (пункт назначения) по отгрузочным реквизитам:<br/>
|
2. Базис поставки (пункт назначения) по отгрузочным реквизитам:<br/>
|
||||||
<t t-esc="o.mt_contractid.address_delivery(o.mt_contractid.partner_id.id) or ''"/><br/>
|
<t t-esc="o.mt_contract_id.address_delivery(o.mt_contract_id.partner_id.id) or ''"/><br/>
|
||||||
Грузополучатель: <t t-esc="o.mt_contractid.partner_id.name or ''"/>, код <t
|
Грузополучатель: <t t-esc="o.mt_contract_id.partner_id.name or ''"/>, код <t
|
||||||
t-esc="o.mt_contractid.partner_id.id or ''"/>, ОКПО <t
|
t-esc="o.mt_contract_id.partner_id.id or ''"/>, ОКПО <t
|
||||||
t-esc="o.mt_contractid.partner_id.okpo or ''"/>.<br/>
|
t-esc="o.mt_contract_id.partner_id.okpo or ''"/>.<br/>
|
||||||
3. Условия оплаты: <t t-esc="o.invoice_payment_term_id.name or ''"/> согласно
|
3. Условия оплаты: <t t-esc="o.invoice_payment_term_id.name or ''"/> согласно
|
||||||
выставленному счету Поставщика.<br/>
|
выставленному счету Поставщика.<br/>
|
||||||
4. Срок отгрузки: <t
|
4. Срок отгрузки: <t
|
||||||
t-esc="o.mt_contractid.get_date_text(o.mt_contractid.date_end) or ''"/><br/>
|
t-esc="o.mt_contract_id.get_date_text(o.mt_contract_id.date_end) or ''"/><br/>
|
||||||
5. Срок действия настоящей спецификации ограничен и равен сроку отгрузки по условиям
|
5. Срок действия настоящей спецификации ограничен и равен сроку отгрузки по условиям
|
||||||
данной спецификации.
|
данной спецификации.
|
||||||
</td>
|
</td>
|
||||||
@ -403,24 +403,24 @@
|
|||||||
<td class="R0C6rtl" colspan="3">Покупатель:</td>
|
<td class="R0C6rtl" colspan="3">Покупатель:</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C6rl" colspan="3"><t t-esc="o.mt_contractid.company_id.name or ''"/></td>
|
<td class="R0C6rl" colspan="3"><t t-esc="o.mt_contract_id.company_id.name or ''"/></td>
|
||||||
<td class="R0C6rl" colspan="3"><t t-esc="o.mt_contractid.partner_id.name or ''"/></td>
|
<td class="R0C6rl" colspan="3"><t t-esc="o.mt_contract_id.partner_id.name or ''"/></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C6l" colspan="3">ИНН
|
<td class="R0C6l" colspan="3">ИНН
|
||||||
<t t-esc="o.mt_contractid.company_id.inn or ''"/>
|
<t t-esc="o.mt_contract_id.company_id.inn or ''"/>
|
||||||
</td>
|
</td>
|
||||||
<td class="R0C7rl" colspan="3">ИНН <t
|
<td class="R0C7rl" colspan="3">ИНН <t
|
||||||
t-esc="o.mt_contractid.partner_id.inn or ''"/></td>
|
t-esc="o.mt_contract_id.partner_id.inn or ''"/></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C6l" colspan="2">ОГРН
|
<td class="R0C6l" colspan="2">ОГРН
|
||||||
<t t-esc="o.company_id.company_registry or ''"/>
|
<t t-esc="o.company_id.company_registry or ''"/>
|
||||||
</td>
|
</td>
|
||||||
<td class="R0C6r" rowspan="2">
|
<td class="R0C6r" rowspan="2">
|
||||||
<t t-esc="o.mt_contractid.name_dirprint1 or ''"/>
|
<t t-esc="o.mt_contract_id.name_dirprint1 or ''"/>
|
||||||
</td>
|
</td>
|
||||||
<t t-if="o.mt_contractid.partner_type in ['company', 'company_ip']">
|
<t t-if="o.mt_contract_id.partner_type in ['company', 'company_ip']">
|
||||||
<td class="R0C7rl" colspan="3">ОГРН
|
<td class="R0C7rl" colspan="3">ОГРН
|
||||||
<t t-esc="o.partner_id.ogrn or ''"/>
|
<t t-esc="o.partner_id.ogrn or ''"/>
|
||||||
</td>
|
</td>
|
||||||
@ -433,9 +433,9 @@
|
|||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C6l" colspan="3">КПП
|
<td class="R0C6l" colspan="3">КПП
|
||||||
<t t-esc="o.mt_contractid.company_id.kpp or ''"/>
|
<t t-esc="o.mt_contract_id.company_id.kpp or ''"/>
|
||||||
</td>
|
</td>
|
||||||
<t t-if="o.mt_contractid.partner_type == 'company'">
|
<t t-if="o.mt_contract_id.partner_type == 'company'">
|
||||||
<td class="R0C7rl" colspan="3">КПП
|
<td class="R0C7rl" colspan="3">КПП
|
||||||
<t t-esc="o.partner_id.kpp or ''"/>
|
<t t-esc="o.partner_id.kpp or ''"/>
|
||||||
</td>
|
</td>
|
||||||
@ -452,10 +452,10 @@
|
|||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C6l" colspan="3">
|
<td class="R0C6l" colspan="3">
|
||||||
<t t-esc="o.mt_contractid.address(o.company_id) or ''"/>
|
<t t-esc="o.mt_contract_id.address(o.company_id) or ''"/>
|
||||||
</td>
|
</td>
|
||||||
<td class="R0C7rl" colspan="3">
|
<td class="R0C7rl" colspan="3">
|
||||||
<t t-esc="o.mt_contractid.address(o.partner_id) or ''"/>
|
<t t-esc="o.mt_contract_id.address(o.partner_id) or ''"/>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
@ -474,12 +474,12 @@
|
|||||||
<td class="R0C6l"></td>
|
<td class="R0C6l"></td>
|
||||||
<td class="R0C6tI">
|
<td class="R0C6tI">
|
||||||
<SPAN>
|
<SPAN>
|
||||||
<t t-raw="o.stamp and o.mt_contractid.img(o.company_id.chief_id.facsimile) or ''"/>
|
<t t-raw="o.stamp and o.mt_contract_id.img(o.company_id.chief_id.facsimile) or ''"/>
|
||||||
</SPAN>
|
</SPAN>
|
||||||
</td>
|
</td>
|
||||||
<td class="R0C6tS">
|
<td class="R0C6tS">
|
||||||
<SPAN>
|
<SPAN>
|
||||||
<t t-raw="o.stamp and o.mt_contractid.img(o.company_id.stamp) or ''"/>
|
<t t-raw="o.stamp and o.mt_contract_id.img(o.company_id.stamp) or ''"/>
|
||||||
</SPAN>
|
</SPAN>
|
||||||
</td>
|
</td>
|
||||||
<td class="R0C6rl" colspan="3"></td>
|
<td class="R0C6rl" colspan="3"></td>
|
||||||
@ -538,7 +538,7 @@
|
|||||||
<td class="R0C6tI">
|
<td class="R0C6tI">
|
||||||
<SPAN>
|
<SPAN>
|
||||||
<t
|
<t
|
||||||
t-raw="o.stamp and o.mt_contractid.img(company.chief_id.facsimile) or ''"/>
|
t-raw="o.stamp and o.mt_contract_id.img(company.chief_id.facsimile) or ''"/>
|
||||||
</SPAN>
|
</SPAN>
|
||||||
</td>
|
</td>
|
||||||
<td class="R0C0"></td>
|
<td class="R0C0"></td>
|
||||||
@ -578,12 +578,12 @@
|
|||||||
<field name="dpi">90</field>
|
<field name="dpi">90</field>
|
||||||
</record>
|
</record>
|
||||||
|
|
||||||
<record id="action_report_contract_customer_invoce" model="ir.actions.report">
|
<record id="action_report_contract_customer_invoice" model="ir.actions.report">
|
||||||
<field name="name">Договор со спецификацией</field>
|
<field name="name">Договор со спецификацией</field>
|
||||||
<field name="model">account.move</field>
|
<field name="model">account.move</field>
|
||||||
<field name="report_type">qweb-pdf</field>
|
<field name="report_type">qweb-pdf</field>
|
||||||
<field name="report_name">contract.report_contract_customer_invoce</field>
|
<field name="report_name">l10n_ru_contract.report_contract_customer_invoice</field>
|
||||||
<field name="report_file">contract.report_contract_customer_invoce</field>
|
<field name="report_file">l10n_ru_contract.report_contract_customer_invoice</field>
|
||||||
<field name="print_report_name">'Договор со спецификацией - %s' % (object.name)</field>
|
<field name="print_report_name">'Договор со спецификацией - %s' % (object.name)</field>
|
||||||
<field name="binding_model_id" ref="account.model_account_move" />
|
<field name="binding_model_id" ref="account.model_account_move" />
|
||||||
<field name="paperformat_id" ref="paperformat_a4" />
|
<field name="paperformat_id" ref="paperformat_a4" />
|
@ -23,9 +23,9 @@
|
|||||||
<table border="0" cellpadding="0" cellspacing="0" style="width:100%">
|
<table border="0" cellpadding="0" cellspacing="0" style="width:100%">
|
||||||
<tbody>
|
<tbody>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C0"><t t-esc="o.mt_contractid.company_id.name or ''"/></td>
|
<td class="R0C0"><t t-esc="o.mt_contract_id.company_id.name or ''"/></td>
|
||||||
<td class="R0C1">Договор <t t-esc="o.mt_contractid.name or ''"/> от <t
|
<td class="R0C1">Договор <t t-esc="o.mt_contract_id.name or ''"/> от <t
|
||||||
t-esc="o.mt_contractid.date_start or ''"/></td>
|
t-esc="o.mt_contract_id.date_start or ''"/></td>
|
||||||
</tr>
|
</tr>
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
@ -93,7 +93,7 @@
|
|||||||
<table border="0" cellpadding="0" cellspacing="0" style="width:100%;">
|
<table border="0" cellpadding="0" cellspacing="0" style="width:100%;">
|
||||||
<tbody>
|
<tbody>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C0" colspan="2">Договор № <t t-esc="o.mt_contractid.name or ''"/></td>
|
<td class="R0C0" colspan="2">Договор № <t t-esc="o.mt_contract_id.name or ''"/></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C0" colspan="2">на поставку продукции</td>
|
<td class="R0C0" colspan="2">на поставку продукции</td>
|
||||||
@ -103,9 +103,9 @@
|
|||||||
<td class="R0C2"></td>
|
<td class="R0C2"></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C1"><t t-esc="o.mt_contractid.company_id.partner_id.city or ''"/></td>
|
<td class="R0C1"><t t-esc="o.mt_contract_id.company_id.partner_id.city or ''"/></td>
|
||||||
<td class="R0C2"><t
|
<td class="R0C2"><t
|
||||||
t-esc="o.mt_contractid.get_date_text(o.mt_contractid.date_start) or ''"/></td>
|
t-esc="o.mt_contract_id.get_date_text(o.mt_contract_id.date_start) or ''"/></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C1"></td>
|
<td class="R0C1"></td>
|
||||||
@ -114,7 +114,7 @@
|
|||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C3" colspan="2">
|
<td class="R0C3" colspan="2">
|
||||||
<span>
|
<span>
|
||||||
<t t-raw="o.mt_contractid.contract_header or ''"/>
|
<t t-raw="o.mt_contract_id.contract_header or ''"/>
|
||||||
</span>
|
</span>
|
||||||
</td>
|
</td>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
@ -122,7 +122,7 @@
|
|||||||
<td class="R0C2"></td>
|
<td class="R0C2"></td>
|
||||||
</tr>
|
</tr>
|
||||||
</tr>
|
</tr>
|
||||||
<!--t t-foreach="o.mt_contractid.lines.sorted(key=lambda r: r.sequence, reverse=False)" t-as="line">
|
<!--t t-foreach="o.mt_contract_id.lines.sorted(key=lambda r: r.sequence, reverse=False)" t-as="line">
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C4" colspan="2"><t t-esc="line.name"/></td>
|
<td class="R0C4" colspan="2"><t t-esc="line.name"/></td>
|
||||||
</tr>
|
</tr>
|
||||||
@ -142,7 +142,7 @@
|
|||||||
</tr-->
|
</tr-->
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
<t t-foreach="o.mt_contractid.lines.sorted(key=lambda r: r.sequence, reverse=False)" t-as="line">
|
<t t-foreach="o.mt_contract_id.lines.sorted(key=lambda r: r.sequence, reverse=False)" t-as="line">
|
||||||
<p class="R0C4"><t t-esc="line.name or ''"/></p>
|
<p class="R0C4"><t t-esc="line.name or ''"/></p>
|
||||||
<div class="R0C5"><span><t t-raw="line.punct or ''"/></span></div>
|
<div class="R0C5"><span><t t-raw="line.punct or ''"/></span></div>
|
||||||
</t>
|
</t>
|
||||||
@ -165,24 +165,24 @@
|
|||||||
<td class="R0C6rtl" colspan="3">Покупатель:</td>
|
<td class="R0C6rtl" colspan="3">Покупатель:</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C6rl" colspan="3"><t t-esc="o.mt_contractid.company_id.name or ''"/></td>
|
<td class="R0C6rl" colspan="3"><t t-esc="o.mt_contract_id.company_id.name or ''"/></td>
|
||||||
<td class="R0C6rl" colspan="3"><t t-esc="o.mt_contractid.partner_id.name or ''"/></td>
|
<td class="R0C6rl" colspan="3"><t t-esc="o.mt_contract_id.partner_id.name or ''"/></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C6l" colspan="3">ИНН
|
<td class="R0C6l" colspan="3">ИНН
|
||||||
<t t-esc="o.mt_contractid.company_id.inn or ''"/>
|
<t t-esc="o.mt_contract_id.company_id.inn or ''"/>
|
||||||
</td>
|
</td>
|
||||||
<td class="R0C7rl" colspan="3">ИНН <t
|
<td class="R0C7rl" colspan="3">ИНН <t
|
||||||
t-esc="o.mt_contractid.partner_id.inn or ''"/></td>
|
t-esc="o.mt_contract_id.partner_id.inn or ''"/></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C6l" colspan="2">ОГРН
|
<td class="R0C6l" colspan="2">ОГРН
|
||||||
<t t-esc="o.company_id.company_registry or ''"/>
|
<t t-esc="o.company_id.company_registry or ''"/>
|
||||||
</td>
|
</td>
|
||||||
<td class="R0C6r" rowspan="2">
|
<td class="R0C6r" rowspan="2">
|
||||||
<t t-esc="o.mt_contractid.name_dirprint1 or ''"/>
|
<t t-esc="o.mt_contract_id.name_dirprint1 or ''"/>
|
||||||
</td>
|
</td>
|
||||||
<t t-if="o.mt_contractid.partner_type in ['company', 'company_ip']">
|
<t t-if="o.mt_contract_id.partner_type in ['company', 'company_ip']">
|
||||||
<td class="R0C7rl" colspan="3">ОГРН
|
<td class="R0C7rl" colspan="3">ОГРН
|
||||||
<t t-esc="o.partner_id.ogrn or ''"/>
|
<t t-esc="o.partner_id.ogrn or ''"/>
|
||||||
</td>
|
</td>
|
||||||
@ -195,9 +195,9 @@
|
|||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C6l" colspan="3">КПП
|
<td class="R0C6l" colspan="3">КПП
|
||||||
<t t-esc="o.mt_contractid.company_id.kpp or ''"/>
|
<t t-esc="o.mt_contract_id.company_id.kpp or ''"/>
|
||||||
</td>
|
</td>
|
||||||
<t t-if="o.mt_contractid.partner_type == 'company'">
|
<t t-if="o.mt_contract_id.partner_type == 'company'">
|
||||||
<td class="R0C7rl" colspan="3">КПП
|
<td class="R0C7rl" colspan="3">КПП
|
||||||
<t t-esc="o.partner_id.kpp or ''"/>
|
<t t-esc="o.partner_id.kpp or ''"/>
|
||||||
</td>
|
</td>
|
||||||
@ -214,10 +214,10 @@
|
|||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C6l" colspan="3">
|
<td class="R0C6l" colspan="3">
|
||||||
<t t-esc="o.mt_contractid.address(o.company_id) or ''"/>
|
<t t-esc="o.mt_contract_id.address(o.company_id) or ''"/>
|
||||||
</td>
|
</td>
|
||||||
<td class="R0C7rl" colspan="3">
|
<td class="R0C7rl" colspan="3">
|
||||||
<t t-esc="o.mt_contractid.address(o.partner_id) or ''"/>
|
<t t-esc="o.mt_contract_id.address(o.partner_id) or ''"/>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
@ -236,12 +236,12 @@
|
|||||||
<td class="R0C6l"></td>
|
<td class="R0C6l"></td>
|
||||||
<td class="R0C6tI">
|
<td class="R0C6tI">
|
||||||
<SPAN>
|
<SPAN>
|
||||||
<t t-raw="o.stamp and o.mt_contractid.img(o.company_id.chief_id.facsimile) or ''"/>
|
<t t-raw="o.stamp and o.mt_contract_id.img(o.company_id.chief_id.facsimile) or ''"/>
|
||||||
</SPAN>
|
</SPAN>
|
||||||
</td>
|
</td>
|
||||||
<td class="R0C6tS">
|
<td class="R0C6tS">
|
||||||
<SPAN>
|
<SPAN>
|
||||||
<t t-raw="o.stamp and o.mt_contractid.img(o.company_id.stamp) or ''"/>
|
<t t-raw="o.stamp and o.mt_contract_id.img(o.company_id.stamp) or ''"/>
|
||||||
</SPAN>
|
</SPAN>
|
||||||
</td>
|
</td>
|
||||||
<td class="R0C6rl" colspan="3"></td>
|
<td class="R0C6rl" colspan="3"></td>
|
||||||
@ -281,8 +281,8 @@
|
|||||||
<tbody>
|
<tbody>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C8" colspan="8">Приложение<br/>к договору № <t
|
<td class="R0C8" colspan="8">Приложение<br/>к договору № <t
|
||||||
t-esc="o.mt_contractid.name"/><br/>на поставку продукции<br/>от <t
|
t-esc="o.mt_contract_id.name"/><br/>на поставку продукции<br/>от <t
|
||||||
t-esc="o.mt_contractid.get_date_text(o.mt_contractid.date_start) or ''"/></td>
|
t-esc="o.mt_contract_id.get_date_text(o.mt_contract_id.date_start) or ''"/></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C0" colspan="8"></td>
|
<td class="R0C0" colspan="8"></td>
|
||||||
@ -295,9 +295,9 @@
|
|||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C1" colspan="4"><t
|
<td class="R0C1" colspan="4"><t
|
||||||
t-esc="o.mt_contractid.company_id.partner_id.city or ''"/></td>
|
t-esc="o.mt_contract_id.company_id.partner_id.city or ''"/></td>
|
||||||
<td class="R0C2" colspan="4"><t
|
<td class="R0C2" colspan="4"><t
|
||||||
t-esc="o.mt_contractid.get_date_text(o.mt_contractid.date_start) or ''"/></td>
|
t-esc="o.mt_contract_id.get_date_text(o.mt_contract_id.date_start) or ''"/></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C0" colspan="8"></td>
|
<td class="R0C0" colspan="8"></td>
|
||||||
@ -305,7 +305,7 @@
|
|||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C3" colspan="8">
|
<td class="R0C3" colspan="8">
|
||||||
<span>
|
<span>
|
||||||
<t t-raw="o.mt_contractid.contract_header or ''"/>
|
<t t-raw="o.mt_contract_id.contract_header or ''"/>
|
||||||
</span>
|
</span>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
@ -314,8 +314,8 @@
|
|||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C5" colspan="8">1. По договору на поставку продукции <t
|
<td class="R0C5" colspan="8">1. По договору на поставку продукции <t
|
||||||
t-esc="o.mt_contractid.name or ''"/> от <t
|
t-esc="o.mt_contract_id.name or ''"/> от <t
|
||||||
t-esc="o.mt_contractid.get_date_text(o.mt_contractid.date_start) or ''"/>.
|
t-esc="o.mt_contract_id.get_date_text(o.mt_contract_id.date_start) or ''"/>.
|
||||||
Поставщик обязуется поставить, а Покупатель оплатить в полном объеме следующее:</td>
|
Поставщик обязуется поставить, а Покупатель оплатить в полном объеме следующее:</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
@ -362,20 +362,20 @@
|
|||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C5" colspan="9">Итого: <t t-esc="sum_full or ''"/> рублей (<t
|
<td class="R0C5" colspan="9">Итого: <t t-esc="sum_full or ''"/> рублей (<t
|
||||||
t-esc="o.mt_contractid.rubles(sum_full) or ''"/>). В стоимость продукции входит
|
t-esc="o.mt_contract_id.rubles(sum_full) or ''"/>). В стоимость продукции входит
|
||||||
стоимость
|
стоимость
|
||||||
тары и стоимость транспортных расходов, связанных с доставкой продукции до станции
|
тары и стоимость транспортных расходов, связанных с доставкой продукции до станции
|
||||||
назначения.<br/>
|
назначения.<br/>
|
||||||
2. Базис поставки (пункт назначения) по отгрузочным реквизитам:<br/>
|
2. Базис поставки (пункт назначения) по отгрузочным реквизитам:<br/>
|
||||||
<t t-esc="o.mt_contractid.address_delivery(o.mt_contractid.partner_id.id) or ''"/><br/>
|
<t t-esc="o.mt_contract_id.address_delivery(o.mt_contract_id.partner_id.id) or ''"/><br/>
|
||||||
Грузополучатель: <t t-esc="o.mt_contractid.partner_id.name or ''"/>, код <t
|
Грузополучатель: <t t-esc="o.mt_contract_id.partner_id.name or ''"/>, код <t
|
||||||
t-esc="o.mt_contractid.partner_id.id or ''"/>, ОКПО <t
|
t-esc="o.mt_contract_id.partner_id.id or ''"/>, ОКПО <t
|
||||||
t-esc="o.mt_contractid.partner_id.okpo or ''"/>.<br/>
|
t-esc="o.mt_contract_id.partner_id.okpo or ''"/>.<br/>
|
||||||
3. Условия оплаты: <t t-esc="o.payment_term_id.name or ''"/> согласно выставленному
|
3. Условия оплаты: <t t-esc="o.payment_term_id.name or ''"/> согласно выставленному
|
||||||
счету
|
счету
|
||||||
Поставщика.<br/>
|
Поставщика.<br/>
|
||||||
4. Срок отгрузки: <t
|
4. Срок отгрузки: <t
|
||||||
t-esc="o.mt_contractid.get_date_text(o.mt_contractid.date_end) or ''"/>
|
t-esc="o.mt_contract_id.get_date_text(o.mt_contract_id.date_end) or ''"/>
|
||||||
<br/>
|
<br/>
|
||||||
5. Срок действия настоящей спецификации ограничен и равен сроку отгрузки по
|
5. Срок действия настоящей спецификации ограничен и равен сроку отгрузки по
|
||||||
условиям данной спецификации.
|
условиям данной спецификации.
|
||||||
@ -405,24 +405,24 @@
|
|||||||
<td class="R0C6rtl" colspan="3">Покупатель:</td>
|
<td class="R0C6rtl" colspan="3">Покупатель:</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C6rl" colspan="3"><t t-esc="o.mt_contractid.company_id.name or ''"/></td>
|
<td class="R0C6rl" colspan="3"><t t-esc="o.mt_contract_id.company_id.name or ''"/></td>
|
||||||
<td class="R0C6rl" colspan="3"><t t-esc="o.mt_contractid.partner_id.name or ''"/></td>
|
<td class="R0C6rl" colspan="3"><t t-esc="o.mt_contract_id.partner_id.name or ''"/></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C6l" colspan="3">ИНН
|
<td class="R0C6l" colspan="3">ИНН
|
||||||
<t t-esc="o.mt_contractid.company_id.inn or ''"/>
|
<t t-esc="o.mt_contract_id.company_id.inn or ''"/>
|
||||||
</td>
|
</td>
|
||||||
<td class="R0C7rl" colspan="3">ИНН <t
|
<td class="R0C7rl" colspan="3">ИНН <t
|
||||||
t-esc="o.mt_contractid.partner_id.inn or ''"/></td>
|
t-esc="o.mt_contract_id.partner_id.inn or ''"/></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C6l" colspan="2">ОГРН
|
<td class="R0C6l" colspan="2">ОГРН
|
||||||
<t t-esc="o.company_id.company_registry or ''"/>
|
<t t-esc="o.company_id.company_registry or ''"/>
|
||||||
</td>
|
</td>
|
||||||
<td class="R0C6r" rowspan="2">
|
<td class="R0C6r" rowspan="2">
|
||||||
<t t-esc="o.mt_contractid.name_dirprint1 or ''"/>
|
<t t-esc="o.mt_contract_id.name_dirprint1 or ''"/>
|
||||||
</td>
|
</td>
|
||||||
<t t-if="o.mt_contractid.partner_type in ['company', 'company_ip']">
|
<t t-if="o.mt_contract_id.partner_type in ['company', 'company_ip']">
|
||||||
<td class="R0C7rl" colspan="3">ОГРН
|
<td class="R0C7rl" colspan="3">ОГРН
|
||||||
<t t-esc="o.partner_id.ogrn or ''"/>
|
<t t-esc="o.partner_id.ogrn or ''"/>
|
||||||
</td>
|
</td>
|
||||||
@ -435,9 +435,9 @@
|
|||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C6l" colspan="3">КПП
|
<td class="R0C6l" colspan="3">КПП
|
||||||
<t t-esc="o.mt_contractid.company_id.kpp or ''"/>
|
<t t-esc="o.mt_contract_id.company_id.kpp or ''"/>
|
||||||
</td>
|
</td>
|
||||||
<t t-if="o.mt_contractid.partner_type == 'company'">
|
<t t-if="o.mt_contract_id.partner_type == 'company'">
|
||||||
<td class="R0C7rl" colspan="3">КПП
|
<td class="R0C7rl" colspan="3">КПП
|
||||||
<t t-esc="o.partner_id.kpp or ''"/>
|
<t t-esc="o.partner_id.kpp or ''"/>
|
||||||
</td>
|
</td>
|
||||||
@ -454,10 +454,10 @@
|
|||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C6l" colspan="3">
|
<td class="R0C6l" colspan="3">
|
||||||
<t t-esc="o.mt_contractid.address(o.company_id) or ''"/>
|
<t t-esc="o.mt_contract_id.address(o.company_id) or ''"/>
|
||||||
</td>
|
</td>
|
||||||
<td class="R0C7rl" colspan="3">
|
<td class="R0C7rl" colspan="3">
|
||||||
<t t-esc="o.mt_contractid.address(o.partner_id) or ''"/>
|
<t t-esc="o.mt_contract_id.address(o.partner_id) or ''"/>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
@ -476,12 +476,12 @@
|
|||||||
<td class="R0C6l"></td>
|
<td class="R0C6l"></td>
|
||||||
<td class="R0C6tI">
|
<td class="R0C6tI">
|
||||||
<SPAN>
|
<SPAN>
|
||||||
<t t-raw="o.stamp and o.mt_contractid.img(o.company_id.chief_id.facsimile) or ''"/>
|
<t t-raw="o.stamp and o.mt_contract_id.img(o.company_id.chief_id.facsimile) or ''"/>
|
||||||
</SPAN>
|
</SPAN>
|
||||||
</td>
|
</td>
|
||||||
<td class="R0C6tS">
|
<td class="R0C6tS">
|
||||||
<SPAN>
|
<SPAN>
|
||||||
<t t-raw="o.stamp and o.mt_contractid.img(o.company_id.stamp) or ''"/>
|
<t t-raw="o.stamp and o.mt_contract_id.img(o.company_id.stamp) or ''"/>
|
||||||
</SPAN>
|
</SPAN>
|
||||||
</td>
|
</td>
|
||||||
<td class="R0C6rl" colspan="3"></td>
|
<td class="R0C6rl" colspan="3"></td>
|
||||||
@ -540,7 +540,7 @@
|
|||||||
<td class="R0C6tI">
|
<td class="R0C6tI">
|
||||||
<SPAN>
|
<SPAN>
|
||||||
<t
|
<t
|
||||||
t-raw="o.stamp and o.mt_contractid.img(company.chief_id.facsimile) or ''"/>
|
t-raw="o.stamp and o.mt_contract_id.img(company.chief_id.facsimile) or ''"/>
|
||||||
</SPAN>
|
</SPAN>
|
||||||
</td>
|
</td>
|
||||||
<td class="R0C0"></td>
|
<td class="R0C0"></td>
|
||||||
@ -584,8 +584,8 @@
|
|||||||
<field name="name">Договор со спецификацией</field>
|
<field name="name">Договор со спецификацией</field>
|
||||||
<field name="model">sale.order</field>
|
<field name="model">sale.order</field>
|
||||||
<field name="report_type">qweb-pdf</field>
|
<field name="report_type">qweb-pdf</field>
|
||||||
<field name="report_name">contract.report_contract_customer_order</field>
|
<field name="report_name">l10n_ru_contract.report_contract_customer_order</field>
|
||||||
<field name="report_file">contract.report_contract_customer_order</field>
|
<field name="report_file">l10n_ru_contract.report_contract_customer_order</field>
|
||||||
<field name="print_report_name">'Договор со спецификацией - %s' % (object.name)</field>
|
<field name="print_report_name">'Договор со спецификацией - %s' % (object.name)</field>
|
||||||
<field name="binding_model_id" ref="sale.model_sale_order" />
|
<field name="binding_model_id" ref="sale.model_sale_order" />
|
||||||
<field name="paperformat_id" ref="paperformat_a4" />
|
<field name="paperformat_id" ref="paperformat_a4" />
|
||||||
|
@ -23,9 +23,9 @@
|
|||||||
<table border="0" cellpadding="0" cellspacing="0" style="width:100%">
|
<table border="0" cellpadding="0" cellspacing="0" style="width:100%">
|
||||||
<tbody>
|
<tbody>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C0"><t t-esc="o.mt_contractid.company_id.name or ''"/></td>
|
<td class="R0C0"><t t-esc="o.mt_contract_id.company_id.name or ''"/></td>
|
||||||
<td class="R0C1">Договор <t t-esc="o.mt_contractid.name or ''"/> от <t
|
<td class="R0C1">Договор <t t-esc="o.mt_contract_id.name or ''"/> от <t
|
||||||
t-esc="o.mt_contractid.date_start or ''"/></td>
|
t-esc="o.mt_contract_id.date_start or ''"/></td>
|
||||||
</tr>
|
</tr>
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
@ -96,8 +96,8 @@
|
|||||||
<tbody>
|
<tbody>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C8" colspan="8">Приложение<br/>к договору № <t
|
<td class="R0C8" colspan="8">Приложение<br/>к договору № <t
|
||||||
t-esc="o.mt_contractid.name"/><br/>на поставку продукции<br/>от <t
|
t-esc="o.mt_contract_id.name"/><br/>на поставку продукции<br/>от <t
|
||||||
t-esc="o.mt_contractid.get_date_text(o.mt_contractid.date_start) or ''"/></td>
|
t-esc="o.mt_contract_id.get_date_text(o.mt_contract_id.date_start) or ''"/></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C0" colspan="8"></td>
|
<td class="R0C0" colspan="8"></td>
|
||||||
@ -110,9 +110,9 @@
|
|||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C1" colspan="4"><t
|
<td class="R0C1" colspan="4"><t
|
||||||
t-esc="o.mt_contractid.company_id.partner_id.city or ''"/></td>
|
t-esc="o.mt_contract_id.company_id.partner_id.city or ''"/></td>
|
||||||
<td class="R0C2" colspan="4"><t
|
<td class="R0C2" colspan="4"><t
|
||||||
t-esc="o.mt_contractid.get_date_text(o.mt_contractid.date_start) or ''"/></td>
|
t-esc="o.mt_contract_id.get_date_text(o.mt_contract_id.date_start) or ''"/></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C0" colspan="8"></td>
|
<td class="R0C0" colspan="8"></td>
|
||||||
@ -120,7 +120,7 @@
|
|||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C3" colspan="8">
|
<td class="R0C3" colspan="8">
|
||||||
<span>
|
<span>
|
||||||
<t t-raw="o.mt_contractid.contract_header or ''"/>
|
<t t-raw="o.mt_contract_id.contract_header or ''"/>
|
||||||
</span>
|
</span>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
@ -129,8 +129,8 @@
|
|||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C5" colspan="8">1. По договору на поставку продукции <t
|
<td class="R0C5" colspan="8">1. По договору на поставку продукции <t
|
||||||
t-esc="o.mt_contractid.name or ''"/> от <t
|
t-esc="o.mt_contract_id.name or ''"/> от <t
|
||||||
t-esc="o.mt_contractid.get_date_text(o.mt_contractid.date_start) or ''"/>.
|
t-esc="o.mt_contract_id.get_date_text(o.mt_contract_id.date_start) or ''"/>.
|
||||||
Поставщик обязуется поставить, а Покупатель оплатить в полном объеме следующее:</td>
|
Поставщик обязуется поставить, а Покупатель оплатить в полном объеме следующее:</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
@ -177,18 +177,18 @@
|
|||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C5" colspan="8">Итого: <t t-esc="sum_full or ''"/> рублей (<t
|
<td class="R0C5" colspan="8">Итого: <t t-esc="sum_full or ''"/> рублей (<t
|
||||||
t-esc="o.mt_contractid.rubles(sum_full) or ''"/>). В стоимость продукции входит стоимость
|
t-esc="o.mt_contract_id.rubles(sum_full) or ''"/>). В стоимость продукции входит стоимость
|
||||||
тары и стоимость транспортных расходов, связанных с доставкой продукции до станции
|
тары и стоимость транспортных расходов, связанных с доставкой продукции до станции
|
||||||
назначения.<br/>
|
назначения.<br/>
|
||||||
2. Базис поставки (пункт назначения) по отгрузочным реквизитам:<br/>
|
2. Базис поставки (пункт назначения) по отгрузочным реквизитам:<br/>
|
||||||
<t t-esc="o.mt_contractid.address_delivery(o.mt_contractid.partner_id.id) or ''"/><br/>
|
<t t-esc="o.mt_contract_id.address_delivery(o.mt_contract_id.partner_id.id) or ''"/><br/>
|
||||||
Грузополучатель: <t t-esc="o.mt_contractid.partner_id.name or ''"/>, код <t
|
Грузополучатель: <t t-esc="o.mt_contract_id.partner_id.name or ''"/>, код <t
|
||||||
t-esc="o.mt_contractid.partner_id.id or ''"/>, ОКПО <t
|
t-esc="o.mt_contract_id.partner_id.id or ''"/>, ОКПО <t
|
||||||
t-esc="o.mt_contractid.partner_id.okpo or ''"/>.<br/>
|
t-esc="o.mt_contract_id.partner_id.okpo or ''"/>.<br/>
|
||||||
3. Условия оплаты: <t t-esc="o.payment_term_id.name or ''"/> согласно выставленному счету
|
3. Условия оплаты: <t t-esc="o.payment_term_id.name or ''"/> согласно выставленному счету
|
||||||
Поставщика.<br/>
|
Поставщика.<br/>
|
||||||
4. Срок отгрузки: <t
|
4. Срок отгрузки: <t
|
||||||
t-esc="o.mt_contractid.get_date_text(o.mt_contractid.date_end) or ''"/><br/>
|
t-esc="o.mt_contract_id.get_date_text(o.mt_contract_id.date_end) or ''"/><br/>
|
||||||
5. Срок действия настоящей спецификации ограничен и равен сроку отгрузки по условиям
|
5. Срок действия настоящей спецификации ограничен и равен сроку отгрузки по условиям
|
||||||
данной спецификации.
|
данной спецификации.
|
||||||
</td>
|
</td>
|
||||||
@ -217,24 +217,24 @@
|
|||||||
<td class="R0C6rtl" colspan="3">Покупатель:</td>
|
<td class="R0C6rtl" colspan="3">Покупатель:</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C6rl" colspan="3"><t t-esc="o.mt_contractid.company_id.name or ''"/></td>
|
<td class="R0C6rl" colspan="3"><t t-esc="o.mt_contract_id.company_id.name or ''"/></td>
|
||||||
<td class="R0C6rl" colspan="3"><t t-esc="o.mt_contractid.partner_id.name or ''"/></td>
|
<td class="R0C6rl" colspan="3"><t t-esc="o.mt_contract_id.partner_id.name or ''"/></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C6l" colspan="3">ИНН
|
<td class="R0C6l" colspan="3">ИНН
|
||||||
<t t-esc="o.mt_contractid.company_id.inn or ''"/>
|
<t t-esc="o.mt_contract_id.company_id.inn or ''"/>
|
||||||
</td>
|
</td>
|
||||||
<td class="R0C7rl" colspan="3">ИНН <t
|
<td class="R0C7rl" colspan="3">ИНН <t
|
||||||
t-esc="o.mt_contractid.partner_id.inn or ''"/></td>
|
t-esc="o.mt_contract_id.partner_id.inn or ''"/></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C6l" colspan="2">ОГРН
|
<td class="R0C6l" colspan="2">ОГРН
|
||||||
<t t-esc="o.company_id.company_registry or ''"/>
|
<t t-esc="o.company_id.company_registry or ''"/>
|
||||||
</td>
|
</td>
|
||||||
<td class="R0C6r" rowspan="2">
|
<td class="R0C6r" rowspan="2">
|
||||||
<t t-esc="o.mt_contractid.name_dirprint1 or ''"/>
|
<t t-esc="o.mt_contract_id.name_dirprint1 or ''"/>
|
||||||
</td>
|
</td>
|
||||||
<t t-if="o.mt_contractid.partner_type in ['company', 'company_ip']">
|
<t t-if="o.mt_contract_id.partner_type in ['company', 'company_ip']">
|
||||||
<td class="R0C7rl" colspan="3">ОГРН
|
<td class="R0C7rl" colspan="3">ОГРН
|
||||||
<t t-esc="o.partner_id.ogrn or ''"/>
|
<t t-esc="o.partner_id.ogrn or ''"/>
|
||||||
</td>
|
</td>
|
||||||
@ -247,9 +247,9 @@
|
|||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C6l" colspan="3">КПП
|
<td class="R0C6l" colspan="3">КПП
|
||||||
<t t-esc="o.mt_contractid.company_id.kpp or ''"/>
|
<t t-esc="o.mt_contract_id.company_id.kpp or ''"/>
|
||||||
</td>
|
</td>
|
||||||
<t t-if="o.mt_contractid.partner_type == 'company'">
|
<t t-if="o.mt_contract_id.partner_type == 'company'">
|
||||||
<td class="R0C7rl" colspan="3">КПП
|
<td class="R0C7rl" colspan="3">КПП
|
||||||
<t t-esc="o.partner_id.kpp or ''"/>
|
<t t-esc="o.partner_id.kpp or ''"/>
|
||||||
</td>
|
</td>
|
||||||
@ -266,10 +266,10 @@
|
|||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
<td class="R0C6l" colspan="3">
|
<td class="R0C6l" colspan="3">
|
||||||
<t t-esc="o.mt_contractid.address(o.company_id) or ''"/>
|
<t t-esc="o.mt_contract_id.address(o.company_id) or ''"/>
|
||||||
</td>
|
</td>
|
||||||
<td class="R0C7rl" colspan="3">
|
<td class="R0C7rl" colspan="3">
|
||||||
<t t-esc="o.mt_contractid.address(o.partner_id) or ''"/>
|
<t t-esc="o.mt_contract_id.address(o.partner_id) or ''"/>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr class="R0">
|
<tr class="R0">
|
||||||
@ -288,12 +288,12 @@
|
|||||||
<td class="R0C6l"></td>
|
<td class="R0C6l"></td>
|
||||||
<td class="R0C6tI">
|
<td class="R0C6tI">
|
||||||
<SPAN>
|
<SPAN>
|
||||||
<t t-raw="o.stamp and o.mt_contractid.img(o.company_id.chief_id.facsimile) or ''"/>
|
<t t-raw="o.stamp and o.mt_contract_id.img(o.company_id.chief_id.facsimile) or ''"/>
|
||||||
</SPAN>
|
</SPAN>
|
||||||
</td>
|
</td>
|
||||||
<td class="R0C6tS">
|
<td class="R0C6tS">
|
||||||
<SPAN>
|
<SPAN>
|
||||||
<t t-raw="o.stamp and o.mt_contractid.img(o.company_id.stamp) or ''"/>
|
<t t-raw="o.stamp and o.mt_contract_id.img(o.company_id.stamp) or ''"/>
|
||||||
</SPAN>
|
</SPAN>
|
||||||
</td>
|
</td>
|
||||||
<td class="R0C6rl" colspan="3"></td>
|
<td class="R0C6rl" colspan="3"></td>
|
||||||
@ -352,7 +352,7 @@
|
|||||||
<td class="R0C6tI">
|
<td class="R0C6tI">
|
||||||
<SPAN>
|
<SPAN>
|
||||||
<t
|
<t
|
||||||
t-raw="o.stamp and o.mt_contractid.img(company.chief_id.facsimile) or ''"/>
|
t-raw="o.stamp and o.mt_contract_id.img(company.chief_id.facsimile) or ''"/>
|
||||||
</SPAN>
|
</SPAN>
|
||||||
</td>
|
</td>
|
||||||
<td class="R0C0"></td>
|
<td class="R0C0"></td>
|
||||||
@ -396,8 +396,8 @@
|
|||||||
<field name="name">Спецификация</field>
|
<field name="name">Спецификация</field>
|
||||||
<field name="model">sale.order</field>
|
<field name="model">sale.order</field>
|
||||||
<field name="report_type">qweb-pdf</field>
|
<field name="report_type">qweb-pdf</field>
|
||||||
<field name="report_name">contract.report_contract_customer_order1</field>
|
<field name="report_name">l10n_ru_contract.report_contract_customer_order1</field>
|
||||||
<field name="report_file">contract.report_contract_customer_order1</field>
|
<field name="report_file">l10n_ru_contract.report_contract_customer_order1</field>
|
||||||
<field name="print_report_name">'Спецификация - %s' % (object.name)</field>
|
<field name="print_report_name">'Спецификация - %s' % (object.name)</field>
|
||||||
<field name="binding_model_id" ref="sale.model_sale_order" />
|
<field name="binding_model_id" ref="sale.model_sale_order" />
|
||||||
<field name="paperformat_id" ref="paperformat_a4" />
|
<field name="paperformat_id" ref="paperformat_a4" />
|
||||||
|
@ -36,14 +36,14 @@
|
|||||||
<field name="partner_id" readonly="state!='draft'"/>
|
<field name="partner_id" readonly="state!='draft'"/>
|
||||||
<field name="partner_type" readonly="state!='draft'"/>
|
<field name="partner_type" readonly="state!='draft'"/>
|
||||||
<!-- <field name="name_print"/>-->
|
<!-- <field name="name_print"/>-->
|
||||||
<field name="sec_partner_id" invisible="1"/>
|
<field name="sec_partner_id" invisible="1"/><!-- reason: need-->
|
||||||
<field name="company_id" readonly="state!='draft'"/>
|
<field name="company_id" readonly="state!='draft'"/>
|
||||||
<!--<field name="name_dirprint"/>-->
|
<!--<field name="name_dirprint"/>-->
|
||||||
<field name="stamp"/>
|
<field name="stamp"/>
|
||||||
<field name="signed"/>
|
<field name="signed"/>
|
||||||
</group>
|
</group>
|
||||||
<group>
|
<group>
|
||||||
<field name="payment_term_id" invisible="1"/>
|
<field name="payment_term_id" invisible="1"/> <!-- reason: need-->
|
||||||
<field name="manager_id"/>
|
<field name="manager_id"/>
|
||||||
<field name="team_id"/>
|
<field name="team_id"/>
|
||||||
|
|
||||||
@ -72,11 +72,11 @@
|
|||||||
<notebook>
|
<notebook>
|
||||||
<page string="Пункты договора" name="contract_lines">
|
<page string="Пункты договора" name="contract_lines">
|
||||||
<field name="lines">
|
<field name="lines">
|
||||||
<tree editable="bottom">
|
<list editable="bottom">
|
||||||
<field name='sequence' widget='handle'/>
|
<field name='sequence' widget='handle'/>
|
||||||
<field name="name"/>
|
<field name="name"/>
|
||||||
<field name="punct"/>
|
<field name="punct"/>
|
||||||
</tree>
|
</list>
|
||||||
</field>
|
</field>
|
||||||
</page>
|
</page>
|
||||||
<page string="Шапка договора" name="contract_header">
|
<page string="Шапка договора" name="contract_header">
|
||||||
@ -86,11 +86,12 @@
|
|||||||
|
|
||||||
|
|
||||||
</sheet>
|
</sheet>
|
||||||
<div class="oe_chatter">
|
<chatter/>
|
||||||
<field name="message_follower_ids" widget="mail_followers"/>
|
<!-- <div class="oe_chatter">-->
|
||||||
<field name="activity_ids" widget="mail_activity"/>
|
<!-- <field name="message_follower_ids" widget="mail_followers"/>-->
|
||||||
<field name="message_ids" widget="mail_thread"/>
|
<!-- <field name="activity_ids" widget="mail_activity"/>-->
|
||||||
</div>
|
<!-- <field name="message_ids" widget="mail_thread"/>-->
|
||||||
|
<!-- </div>-->
|
||||||
</form>
|
</form>
|
||||||
</field>
|
</field>
|
||||||
</record>
|
</record>
|
||||||
@ -114,11 +115,11 @@
|
|||||||
<field name="name">Договор</field>
|
<field name="name">Договор</field>
|
||||||
<field name="model">partner.contract.customer</field>
|
<field name="model">partner.contract.customer</field>
|
||||||
<field name="arch" type="xml">
|
<field name="arch" type="xml">
|
||||||
<tree string="Договоры">
|
<list string="Договоры">
|
||||||
<field name="name"/>
|
<field name="name"/>
|
||||||
<field name="partner_id"/>
|
<field name="partner_id"/>
|
||||||
<field name="date_start"/>
|
<field name="date_start"/>
|
||||||
</tree>
|
</list>
|
||||||
</field>
|
</field>
|
||||||
</record>
|
</record>
|
||||||
|
|
||||||
@ -142,7 +143,7 @@
|
|||||||
<field name="name">Договоры</field>
|
<field name="name">Договоры</field>
|
||||||
<field name="type">ir.actions.act_window</field>
|
<field name="type">ir.actions.act_window</field>
|
||||||
<field name="res_model">partner.contract.customer</field>
|
<field name="res_model">partner.contract.customer</field>
|
||||||
<field name="view_mode">kanban,tree,form</field>
|
<field name="view_mode">kanban,list,form</field>
|
||||||
<field name="help" type="html">
|
<field name="help" type="html">
|
||||||
<p class="oe_view_nocontent_create">
|
<p class="oe_view_nocontent_create">
|
||||||
Нет созданных контрактов
|
Нет созданных контрактов
|
||||||
@ -157,7 +158,7 @@
|
|||||||
<field name="name">Договоры</field>
|
<field name="name">Договоры</field>
|
||||||
<field name="type">ir.actions.act_window</field>
|
<field name="type">ir.actions.act_window</field>
|
||||||
<field name="res_model">partner.contract.customer</field>
|
<field name="res_model">partner.contract.customer</field>
|
||||||
<field name="view_mode">kanban,tree,form</field>
|
<field name="view_mode">kanban,list,form</field>
|
||||||
<field name="domain">[('type', '=', 'supplier')]</field>
|
<field name="domain">[('type', '=', 'supplier')]</field>
|
||||||
<field name="help" type="html">
|
<field name="help" type="html">
|
||||||
|
|
||||||
@ -174,7 +175,7 @@
|
|||||||
<field name="name">Договоры</field>
|
<field name="name">Договоры</field>
|
||||||
<field name="type">ir.actions.act_window</field>
|
<field name="type">ir.actions.act_window</field>
|
||||||
<field name="res_model">partner.contract.customer</field>
|
<field name="res_model">partner.contract.customer</field>
|
||||||
<field name="view_mode">kanban,tree,form</field>
|
<field name="view_mode">kanban,list,form</field>
|
||||||
<field name="domain">[('type', '=', 'customer')]</field>
|
<field name="domain">[('type', '=', 'customer')]</field>
|
||||||
<field name="help" type="html">
|
<field name="help" type="html">
|
||||||
|
|
||||||
@ -191,14 +192,14 @@
|
|||||||
<field name="name">Настройка одновременно включенных договоров</field>
|
<field name="name">Настройка одновременно включенных договоров</field>
|
||||||
<field name="type">ir.actions.act_window</field>
|
<field name="type">ir.actions.act_window</field>
|
||||||
<field name="res_model">contract.allowed.profiles</field>
|
<field name="res_model">contract.allowed.profiles</field>
|
||||||
<field name="view_mode">tree,form</field>
|
<field name="view_mode">list,form</field>
|
||||||
</record>
|
</record>
|
||||||
|
|
||||||
<record id="contract_profile_action" model="ir.actions.act_window">
|
<record id="contract_profile_action" model="ir.actions.act_window">
|
||||||
<field name="name">Виды договоров</field>
|
<field name="name">Виды договоров</field>
|
||||||
<field name="type">ir.actions.act_window</field>
|
<field name="type">ir.actions.act_window</field>
|
||||||
<field name="res_model">contract.profile</field>
|
<field name="res_model">contract.profile</field>
|
||||||
<field name="view_mode">tree,form</field>
|
<field name="view_mode">list,form</field>
|
||||||
</record>
|
</record>
|
||||||
|
|
||||||
<record id="contract_profile_view" model="ir.ui.view">
|
<record id="contract_profile_view" model="ir.ui.view">
|
||||||
@ -250,10 +251,10 @@
|
|||||||
<field name="inherit_id" ref="sale.view_order_form"/>
|
<field name="inherit_id" ref="sale.view_order_form"/>
|
||||||
<field name="arch" type="xml">
|
<field name="arch" type="xml">
|
||||||
<xpath expr="//field[@name='partner_id']" position="after">
|
<xpath expr="//field[@name='partner_id']" position="after">
|
||||||
<field name="mt_contractid"
|
<field name="mt_contract_id"
|
||||||
domain="[('partner_id','=',sec_partner_id),('company_id','=',company_id)]"
|
domain="[('partner_id','=',sec_partner_id),('company_id','=',company_id)]"
|
||||||
context="{'default_sec_partner_id':partner_id,'default_company_id':company_id,'default_type':'customer'}"/>
|
context="{'default_sec_partner_id':partner_id,'default_company_id':company_id,'default_type':'customer'}"/>
|
||||||
<field name="sec_partner_id" invisible="1"/>
|
<field name="sec_partner_id" invisible="1"/><!-- reason: need-->
|
||||||
|
|
||||||
</xpath>
|
</xpath>
|
||||||
|
|
||||||
@ -267,10 +268,10 @@
|
|||||||
<field name="arch" type="xml">
|
<field name="arch" type="xml">
|
||||||
<xpath expr="//field[@name='origin']" position="after">
|
<xpath expr="//field[@name='origin']" position="after">
|
||||||
|
|
||||||
<field name="mt_contractid"
|
<field name="mt_contract_id"
|
||||||
domain="[('partner_id','=',sec_partner_id),('company_id','=',company_id)]"
|
domain="[('partner_id','=',sec_partner_id),('company_id','=',company_id)]"
|
||||||
context="{'default_sec_partner_id':partner_id,'default_company_id':company_id,'default_type':'supplier'}"/>
|
context="{'default_sec_partner_id':partner_id,'default_company_id':company_id,'default_type':'supplier'}"/>
|
||||||
<field name="sec_partner_id" invisible="1"/>
|
<field name="sec_partner_id" invisible="1"/><!-- reason: need-->
|
||||||
|
|
||||||
</xpath>
|
</xpath>
|
||||||
|
|
||||||
@ -284,12 +285,12 @@
|
|||||||
<field name="arch" type="xml">
|
<field name="arch" type="xml">
|
||||||
<xpath expr="//field[@name='payment_reference']" position="after">
|
<xpath expr="//field[@name='payment_reference']" position="after">
|
||||||
|
|
||||||
<field name="mt_contractid"
|
<field name="mt_contract_id"
|
||||||
domain="[('partner_id','=',sec_partner_id),('company_id','=',company_id)]"
|
domain="[('partner_id','=',sec_partner_id),('company_id','=',company_id)]"
|
||||||
context="{'default_sec_partner_id':partner_id,'default_company_id':company_id,'default_type':'customer'}"/>
|
context="{'default_sec_partner_id':partner_id,'default_company_id':company_id,'default_type':'customer'}"/>
|
||||||
<field name="sec_partner_id" invisible="1"/>
|
<field name="sec_partner_id" invisible="1"/><!-- reason: need-->
|
||||||
<field name="sf_number"/>
|
<field name="sf_number"/>
|
||||||
<field name="osnovanie" invisible="1"/>
|
<field name="osnovanie" invisible="1"/><!-- reason: need-->
|
||||||
|
|
||||||
</xpath>
|
</xpath>
|
||||||
|
|
||||||
@ -332,27 +333,25 @@
|
|||||||
|
|
||||||
</field>
|
</field>
|
||||||
</record>
|
</record>
|
||||||
<menuitem name="Договоры" id="contract.main" parent="sale.sale_menu_root"/>
|
<menuitem name="Договоры" id="l10n_ru_contract.main" parent="sale.sale_menu_root"/>
|
||||||
<menuitem name="Договоры" id="contract.contracts" parent="contract.main"
|
<menuitem name="Договоры" id="l10n_ru_contract.contracts" parent="l10n_ru_contract.main"
|
||||||
action="contract.contract_customer_action2"/>
|
action="l10n_ru_contract.contract_customer_action2"/>
|
||||||
|
|
||||||
<menuitem name="Договоры" id="contract.main1" parent="purchase.menu_purchase_root"/>
|
<menuitem name="Договоры" id="l10n_ru_contract.main1" parent="purchase.menu_purchase_root"/>
|
||||||
<menuitem name="Договоры" id="contract.contracts1" parent="contract.main1"
|
<menuitem name="Договоры" id="l10n_ru_contract.contracts1" parent="l10n_ru_contract.main1"
|
||||||
action="contract.contract_customer_action1"/>
|
action="l10n_ru_contract.contract_customer_action1"/>
|
||||||
|
|
||||||
<menuitem name="Настройка" id="separator" parent="contract.main"/>
|
<menuitem name="Настройка" id="l10n_ru_contract.separator" parent="l10n_ru_contract.main"/>
|
||||||
<menuitem name="Виды договоров" id="contract_profiles" parent="separator"
|
<menuitem name="Виды договоров" id="l10n_ru_contract.contract_profiles" parent="l10n_ru_contract.separator"
|
||||||
action="contract.contract_profile_action"/>
|
action="l10n_ru_contract.contract_profile_action"/>
|
||||||
<menuitem name="Включенные договора" id="contract_profile_setting" parent="separator"
|
<menuitem name="Включенные договора" id="l10n_ru_contract.contract_profile_setting" parent="l10n_ru_contract.separator"
|
||||||
action="contract.contract_allowed_profiles_action"/>
|
action="l10n_ru_contract.contract_allowed_profiles_action"/>
|
||||||
|
|
||||||
|
|
||||||
<menuitem name="Настройка" id="separator1" parent="contract.main1"/>
|
|
||||||
<menuitem name="Виды договоров" id="contract_profiles1" parent="separator1"
|
|
||||||
action="contract.contract_profile_action"/>
|
|
||||||
<menuitem name="Включенные договора" id="contract_profile_setting1" parent="separator1"
|
|
||||||
action="contract.contract_allowed_profiles_action"/>
|
|
||||||
|
|
||||||
|
|
||||||
|
<menuitem name="Настройка" id="l10n_ru_contract.separator1" parent="l10n_ru_contract.main1"/>
|
||||||
|
<menuitem name="Виды договоров" id="l10n_ru_contract.contract_profiles1" parent="l10n_ru_contract.separator1"
|
||||||
|
action="l10n_ru_contract.contract_profile_action"/>
|
||||||
|
<menuitem name="Включенные договора" id="l10n_ru_contract.contract_profile_setting1" parent="l10n_ru_contract.separator1"
|
||||||
|
action="l10n_ru_contract.contract_allowed_profiles_action"/>
|
||||||
</data>
|
</data>
|
||||||
</odoo>
|
</odoo>
|
||||||
|
37
l10n_ru_contract/views/mail_template.xml
Normal file
37
l10n_ru_contract/views/mail_template.xml
Normal file
@ -0,0 +1,37 @@
|
|||||||
|
<odoo>
|
||||||
|
<data noupdate="1">
|
||||||
|
<!--Email template -->
|
||||||
|
<record id="email_template_order_special" model="mail.template">
|
||||||
|
<field name="name">Шаблон почты</field>
|
||||||
|
<field name="model_id" ref="sale.model_sale_order" />
|
||||||
|
<field name="email_from">${(object.company_id.email |safe}</field>
|
||||||
|
<field name="email_to" >${object.partner_id.email}</field>
|
||||||
|
<field name="subject">Заказ ${object.name or 'n/a' }</field>
|
||||||
|
<field name="auto_delete" eval="True"/>
|
||||||
|
<!--field name="report_template" ref="action_report_contract_customer_order1"/-->
|
||||||
|
<!--field name="report_name">Спецификация к заказу</field-->
|
||||||
|
<!--field name="report_name">Спецификация к заказу ${(object.name or '')}</field-->
|
||||||
|
<!--field name="lang">${object.partner_id.lang}</field-->
|
||||||
|
<field name="body_html"><![CDATA[
|
||||||
|
<p></p>
|
||||||
|
]]>
|
||||||
|
</field>
|
||||||
|
</record>
|
||||||
|
|
||||||
|
<record id="email_template_contract2" model="mail.template">
|
||||||
|
<field name="name">Договор</field>
|
||||||
|
<field name="model_id" ref="l10n_ru_contract.model_partner_contract_customer" />
|
||||||
|
<field name="email_from">${(object.company_id.email |safe}</field>
|
||||||
|
<field name="email_to" >${object.partner_id.email}</field>
|
||||||
|
<field name="subject">Договор №${(object.name or 'n/a')} ${(object.company_id.name or 'n/a')} - ${(object.partner_id.parent_id.name or object.partner_id.name or 'n/a')} от ${(object.date_start or 'n/a')}</field>
|
||||||
|
<field name="auto_delete" eval="True"/>
|
||||||
|
<!--field name="report_template" ref="action_report_contract_customer"/-->
|
||||||
|
<!--field name="report_name">Договор №${(object.name or 'n/a')}</field-->
|
||||||
|
<field name="lang">${object.partner_id.lang}</field>
|
||||||
|
<field name="body_html"><![CDATA[
|
||||||
|
<p></p>
|
||||||
|
]]>
|
||||||
|
</field>
|
||||||
|
</record>
|
||||||
|
</data>
|
||||||
|
</odoo>
|
38
l10n_ru_doc/README.md
Normal file
38
l10n_ru_doc/README.md
Normal file
@ -0,0 +1,38 @@
|
|||||||
|
# Российская локализация - Документы
|
||||||
|
name: l10n_ru_doc
|
||||||
|
|
||||||
|
## Описание
|
||||||
|
Модуль для печати документов в соответствии с законодательством России.
|
||||||
|
|
||||||
|
##Возможности:
|
||||||
|
* Товарная накладная (ТОРГ-12)
|
||||||
|
* Счет на оплату (по форме 1С)
|
||||||
|
* Счет-фактура
|
||||||
|
* Акт выполненных работ
|
||||||
|
* Универсальный передаточный документ
|
||||||
|
|
||||||
|
### Товарная накладная (ТОРГ-12)
|
||||||
|
#### Для печати:
|
||||||
|
1. Меню Бухгалтерия - Клиенты - Счета (account.move);
|
||||||
|
2. Отчет "Товарная накладная (ТОРГ-12)".
|
||||||
|
|
||||||
|
### Счет на оплату (по форме 1С)
|
||||||
|
1. Меню Продажи - Заказ продаж (sale.order));
|
||||||
|
2. Отчет "Счет по форме 1С".
|
||||||
|
|
||||||
|
### Счет-фактура
|
||||||
|
1. Меню Бухгалтерия - Клиенты - Счета (account.move);
|
||||||
|
2. Отчет "Счет-фактура".
|
||||||
|
|
||||||
|
### Акт выполненных работ
|
||||||
|
1. Меню Бухгалтерия - Клиенты - Счета (account.move);
|
||||||
|
2. Отчет "Акт выполненных работ".
|
||||||
|
|
||||||
|
### Универсальный передаточный документ
|
||||||
|
1. Меню Бухгалтерия - Клиенты - Счета (account.move);
|
||||||
|
2. В двух вариантах:отчет "Универсальный передаточный документ(УПД)"
|
||||||
|
|
||||||
|
2.1. Отчет "Универсальный передаточный документ(УПД)";
|
||||||
|
|
||||||
|
2.2. Отчет "УПД без печатей";
|
||||||
|
|
@ -1,30 +1,54 @@
|
|||||||
# -*- coding: utf-8 -*-
|
# -*- coding: utf-8 -*-
|
||||||
{
|
{
|
||||||
'name': "Russia - Documents",
|
'name': "Российская локализация - Документы",
|
||||||
|
|
||||||
'summary': "Первичные документы",
|
'summary': "Первичные документы",
|
||||||
|
|
||||||
'description': """
|
'description': """
|
||||||
The module for print documents in accordance laws of Russia.
|
Модуль для печати документов в соответствии с законодательством России.
|
||||||
============================================================
|
============================================================
|
||||||
Возможности:
|
Возможности:
|
||||||
* Товарная накладная (ТОРГ-12)
|
* Товарная накладная (ТОРГ-12)
|
||||||
* Счет на оплату
|
* Счет на оплату (по форме 1С)
|
||||||
* Счет-фактура
|
* Счет-фактура
|
||||||
* Акт выполненных работ
|
* Акт выполненных работ
|
||||||
* Вывод подписей и печати
|
* Универсальный передаточный документ
|
||||||
|
|
||||||
|
Для печати:
|
||||||
|
Товарная накладная (ТОРГ-12)
|
||||||
|
1. Меню Бухгалтерия - Клиенты - Счета (account.move);
|
||||||
|
2. Отчет "Товарная накладная (ТОРГ-12)".
|
||||||
|
|
||||||
|
Счет на оплату (по форме 1С)
|
||||||
|
1. Меню Продажи - Заказ продаж (sale.order));
|
||||||
|
2. Отчет "Счет по форме 1С".
|
||||||
|
|
||||||
|
Счет-фактура
|
||||||
|
1. Меню Бухгалтерия - Клиенты - Счета (account.move);
|
||||||
|
2. Отчет "Счет-фактура".
|
||||||
|
|
||||||
|
Акт выполненных работ
|
||||||
|
1. Меню Бухгалтерия - Клиенты - Счета (account.move);
|
||||||
|
2. Отчет "Акт выполненных работ".
|
||||||
|
|
||||||
|
Универсальный передаточный документ
|
||||||
|
1. Меню Бухгалтерия - Клиенты - Счета (account.move);
|
||||||
|
2. В двух вариантах:отчет "Универсальный передаточный документ(УПД)"
|
||||||
|
2.1. Отчет "Универсальный передаточный документ(УПД)";
|
||||||
|
2.2. Отчет "УПД без печатей";
|
||||||
|
|
||||||
""",
|
""",
|
||||||
|
|
||||||
'author': "CodUP and MKLab",
|
'author': "CodeUP and MK.Lab",
|
||||||
'website': "https://inf-centre.ru",
|
'website': "https://www.inf-centre.ru/",
|
||||||
|
|
||||||
'license': 'AGPL-3',
|
'license': 'AGPL-3',
|
||||||
'category': 'Localization',
|
'category': 'Localization',
|
||||||
'version': '17.0.2024.06.28',
|
'version': '0.1',
|
||||||
|
|
||||||
'depends': ['base','sale','account','sale_stock','uom'],
|
'depends': ['base', 'sale', 'account', 'sale_stock', 'uom', 'l10n_ru_base'],
|
||||||
|
|
||||||
'external_dependencies': {'python' : ['pytils']},
|
'external_dependencies': {'python': ['pytils']},
|
||||||
|
|
||||||
'data': [
|
'data': [
|
||||||
'views/account_invoice_view.xml',
|
'views/account_invoice_view.xml',
|
||||||
|
Binary file not shown.
Binary file not shown.
@ -39,29 +39,29 @@ class AccountInvoice(models.Model):
|
|||||||
|
|
||||||
s.payment_text = payment_text
|
s.payment_text = payment_text
|
||||||
|
|
||||||
def action_bill_sent(self):
|
# def action_bill_sent(self):
|
||||||
assert len(self) == 1, 'This option should only be used for a single id at a time.'
|
# assert len(self) == 1, 'This option should only be used for a single id at a time.'
|
||||||
template = self.env.ref('account.email_template_edi_invoice', False)
|
# template = self.env.ref('account.email_template_edi_invoice', False)
|
||||||
compose_form = self.env.ref('mail.email_compose_message_wizard_form', False)
|
# compose_form = self.env.ref('mail.email_compose_message_wizard_form', False)
|
||||||
ctx = {
|
# ctx = {
|
||||||
'default_model': 'account.move',
|
# 'default_model': 'account.move',
|
||||||
'default_res_id': self.id,
|
# 'default_res_id': self.id,
|
||||||
'default_use_template': bool(template),
|
# 'default_use_template': bool(template),
|
||||||
'default_template_id': template.id,
|
# 'default_template_id': template.id,
|
||||||
'default_composition_mode': 'comment',
|
# 'default_composition_mode': 'comment',
|
||||||
'mark_invoice_as_sent': True,
|
# 'mark_invoice_as_sent': True,
|
||||||
}
|
# }
|
||||||
return {
|
# return {
|
||||||
'name': 'Compose Email',
|
# 'name': 'Compose Email',
|
||||||
'type': 'ir.actions.act_window',
|
# 'type': 'ir.actions.act_window',
|
||||||
'view_type': 'form',
|
# 'view_type': 'form',
|
||||||
'view_mode': 'form',
|
# 'view_mode': 'form',
|
||||||
'res_model': 'mail.compose.message',
|
# 'res_model': 'mail.compose.message',
|
||||||
'views': [(compose_form.id, 'form')],
|
# 'views': [(compose_form.id, 'form')],
|
||||||
'view_id': compose_form.id,
|
# 'view_id': compose_form.id,
|
||||||
'target': 'new',
|
# 'target': 'new',
|
||||||
'context': ctx,
|
# 'context': ctx,
|
||||||
}
|
# }
|
||||||
|
|
||||||
def bill_print(self):
|
def bill_print(self):
|
||||||
assert len(self) == 1, 'This option should only be used for a single id at a time.'
|
assert len(self) == 1, 'This option should only be used for a single id at a time.'
|
||||||
@ -69,9 +69,10 @@ class AccountInvoice(models.Model):
|
|||||||
|
|
||||||
def get_delivery_doc_name(self):
|
def get_delivery_doc_name(self):
|
||||||
for s in self:
|
for s in self:
|
||||||
|
if s:
|
||||||
pickings = []
|
pickings = []
|
||||||
pickings_list = '0'
|
pickings_list = '0'
|
||||||
orders = self.env['sale.order'].sudo().search([('name','=',s.invoice_origin)])
|
orders = self.env['sale.order'].sudo().search([('name','=',s.invoice_origin)]) if s.invoice_origin else []
|
||||||
for o in orders:
|
for o in orders:
|
||||||
if o.picking_ids:
|
if o.picking_ids:
|
||||||
for p in o.picking_ids:
|
for p in o.picking_ids:
|
||||||
@ -80,24 +81,29 @@ class AccountInvoice(models.Model):
|
|||||||
pickings_list = ';'.join(pickings)
|
pickings_list = ';'.join(pickings)
|
||||||
if pickings_list != '0':
|
if pickings_list != '0':
|
||||||
return pickings_list
|
return pickings_list
|
||||||
if s.name.find('/') > -1:
|
if s.name and s.name.find('/') > -1:
|
||||||
return 'УПД № ' + s.name[len(s.name) - 4:]
|
return 'УПД № ' + s.name[len(s.name) - 4:]
|
||||||
return 'УПД № ' + s.name
|
return 'УПД № ' + str(s.name) if s.name else ''
|
||||||
|
|
||||||
|
|
||||||
def get_delivery_doc_date(self):
|
def get_delivery_doc_date(self):
|
||||||
for s in self:
|
for s in self:
|
||||||
|
if s:
|
||||||
|
delivery_dates = []
|
||||||
pickings = []
|
pickings = []
|
||||||
pickings_list = '0'
|
orders = self.env['sale.order'].sudo().search([('name', '=', s.invoice_origin)])
|
||||||
orders = self.env['sale.order'].sudo().search([('name','=',s.invoice_origin)])
|
|
||||||
for o in orders:
|
for o in orders:
|
||||||
if o.picking_ids:
|
if o.picking_ids:
|
||||||
for p in o.picking_ids:
|
for p in o.picking_ids:
|
||||||
pickings.append(datetime.strftime(p.date, '%d.%m.%Y'))
|
if p.date:
|
||||||
if len(pickings)>0:
|
formatted_date = datetime.strftime(p.date, '%d.%m.%Y')
|
||||||
pickings_list = ';'.join(pickings)
|
pickings.append(formatted_date)
|
||||||
if pickings_list != '0':
|
if pickings and len(pickings)>0:
|
||||||
return pickings_list
|
delivery_dates.append(';'.join(pickings))
|
||||||
return datetime.strftime(s.date, '%d.%m.%Y')
|
else:
|
||||||
|
if s.date:
|
||||||
|
delivery_dates.append(datetime.strftime(s.date, '%d.%m.%Y'))
|
||||||
|
return delivery_dates
|
||||||
|
|
||||||
def get_function_partner(self, partner=False, type='director'):
|
def get_function_partner(self, partner=False, type='director'):
|
||||||
if partner:
|
if partner:
|
||||||
|
@ -97,7 +97,7 @@ class QWebHelper(object):
|
|||||||
repr.append("р/сч " + bank.acc_number)
|
repr.append("р/сч " + bank.acc_number)
|
||||||
if bank and bank.bank_name:
|
if bank and bank.bank_name:
|
||||||
repr.append("в банке " + bank.bank_name)
|
repr.append("в банке " + bank.bank_name)
|
||||||
if bank and bank.banvk_bic:
|
if bank and bank.bank_bic:
|
||||||
repr.append("БИК " + bank.bank_bic)
|
repr.append("БИК " + bank.bank_bic)
|
||||||
if bank and bank.bank_corr_acc:
|
if bank and bank.bank_corr_acc:
|
||||||
repr.append("к/с " + bank.bank_corr_acc)
|
repr.append("к/с " + bank.bank_corr_acc)
|
||||||
|
@ -7,11 +7,11 @@
|
|||||||
<field name="model">account.move</field>
|
<field name="model">account.move</field>
|
||||||
<field name="inherit_id" ref="account.view_move_form"/>
|
<field name="inherit_id" ref="account.view_move_form"/>
|
||||||
<field name="arch" type="xml">
|
<field name="arch" type="xml">
|
||||||
<data>
|
<!-- <data>-->
|
||||||
<button name="action_invoice_sent" position="attributes">
|
<!-- <button name="action_invoice_sent" position="attributes">-->
|
||||||
<attribute name="name">action_bill_sent</attribute>
|
<!-- <attribute name="name">action_bill_sent</attribute>-->
|
||||||
</button>
|
<!-- </button>-->
|
||||||
</data>
|
<!-- </data>-->
|
||||||
<xpath expr="//group[@id='header_left_group']" position="inside">
|
<xpath expr="//group[@id='header_left_group']" position="inside">
|
||||||
|
|
||||||
<field name="kladov"/>
|
<field name="kladov"/>
|
||||||
@ -20,11 +20,11 @@
|
|||||||
|
|
||||||
<field name="transport"/>
|
<field name="transport"/>
|
||||||
<field name="osnovanie"/>
|
<field name="osnovanie"/>
|
||||||
<field name="only_service" invisible="1"/>
|
<field name="only_service" invisible="1"/> <!-- reason: need-->
|
||||||
</xpath>
|
</xpath>
|
||||||
|
|
||||||
<xpath expr="//page[@name='invoice_tab']/field[@name='invoice_line_ids']/tree/field[@name='tax_ids']" position="after">
|
<xpath expr="//page[@name='invoice_tab']/field[@name='invoice_line_ids']/list/field[@name='tax_ids']" position="after">
|
||||||
<field name="price_total_pf" column_invisible="True"/>
|
<field name="price_total_pf" column_invisible="True"/><!-- reason: need-->
|
||||||
</xpath>
|
</xpath>
|
||||||
|
|
||||||
</field>
|
</field>
|
||||||
|
@ -8,7 +8,7 @@
|
|||||||
<field name="inherit_id" ref="base.view_company_form"/>
|
<field name="inherit_id" ref="base.view_company_form"/>
|
||||||
<field name="arch" type="xml">
|
<field name="arch" type="xml">
|
||||||
<xpath expr="//field[@name='vat']" position="after">
|
<xpath expr="//field[@name='vat']" position="after">
|
||||||
<field name="inn" invisible="True"/>
|
<field name="inn" invisible="True"/><!-- reason: need-->
|
||||||
<field name="kpp"/>
|
<field name="kpp"/>
|
||||||
<field name="okpo"/>
|
<field name="okpo"/>
|
||||||
</xpath>
|
</xpath>
|
||||||
|
@ -8,7 +8,7 @@
|
|||||||
<field name="inherit_id" ref="base.view_partner_form"/>
|
<field name="inherit_id" ref="base.view_partner_form"/>
|
||||||
<field name="arch" type="xml">
|
<field name="arch" type="xml">
|
||||||
<xpath expr="//field[@name='vat']" position="after">
|
<xpath expr="//field[@name='vat']" position="after">
|
||||||
<field name="inn" invisible="True"/>
|
<field name="inn" invisible="True"/> <!-- reason: need-->
|
||||||
<field name="kpp" invisible="is_company==False"/>
|
<field name="kpp" invisible="is_company==False"/>
|
||||||
<field name="okpo" invisible="is_company==False"/>
|
<field name="okpo" invisible="is_company==False"/>
|
||||||
<field name="ogrn" invisible="is_company==False"/>
|
<field name="ogrn" invisible="is_company==False"/>
|
||||||
|
@ -17,7 +17,7 @@
|
|||||||
<field name="model">uom.category</field>
|
<field name="model">uom.category</field>
|
||||||
<field name="inherit_id" ref="uom.product_uom_categ_form_view"/>
|
<field name="inherit_id" ref="uom.product_uom_categ_form_view"/>
|
||||||
<field name="arch" type="xml">
|
<field name="arch" type="xml">
|
||||||
<xpath expr="//field[@name='uom_ids']/tree/field[@name='name']" position="after">
|
<xpath expr="//field[@name='uom_ids']/list/field[@name='name']" position="after">
|
||||||
<field name="kod"/>
|
<field name="kod"/>
|
||||||
</xpath>
|
</xpath>
|
||||||
</field>
|
</field>
|
||||||
|
9
l10n_ru_upd_xml/README.md
Normal file
9
l10n_ru_upd_xml/README.md
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
# Российская локализация - УПД в xml-формате
|
||||||
|
name: l10n_ru_upd_xml
|
||||||
|
|
||||||
|
## Описание
|
||||||
|
Формирует универсальный передаточный документ в формате XML.
|
||||||
|
|
||||||
|
###Для печати:
|
||||||
|
1. Меню Бухгалтерия - Клиенты - Счета (account.move);
|
||||||
|
2. Кнопка "Печать УПД в xml-формате".
|
@ -1,5 +1,3 @@
|
|||||||
# -*- coding: utf-8 -*-
|
|
||||||
|
|
||||||
from . import controllers
|
from . import controllers
|
||||||
from . import models
|
from . import models
|
||||||
from . import reports
|
from . import reports
|
||||||
|
@ -1,51 +1,45 @@
|
|||||||
# -*- coding: utf-8 -*-
|
# -*- coding: utf-8 -*-
|
||||||
{
|
{
|
||||||
'name': "Печать УПД в xml формате",
|
'name': "Российская локализация - УПД в xml-формате",
|
||||||
|
|
||||||
'summary': "Формирует УПД в формате XML, формат 5.01",
|
'summary': """
|
||||||
|
Формирует УПД в формате XML, формат 5.01""",
|
||||||
|
|
||||||
'description': """
|
'description': """
|
||||||
Формирует УПД в формате XML, формат 5.01
|
Формирует УПД в формате XML.
|
||||||
|
|
||||||
|
Для печати:
|
||||||
|
1. Меню Бухгалтерия - Клиенты - Счета (account.move);
|
||||||
|
2. Кнопка "Печать УПД в xml-формате".
|
||||||
""",
|
""",
|
||||||
|
|
||||||
'author': "MKLab",
|
'author': "MK.Lab",
|
||||||
'website': "https://inf-centre.ru",
|
'website': "https://www.inf-centre.ru/",
|
||||||
|
|
||||||
# Categories can be used to filter modules in modules listing
|
'category': 'Uncategorized',
|
||||||
# Check https://github.com/odoo/odoo/blob/15.0/odoo/addons/base/data/ir_module_category_data.xml
|
'version': '0.1',
|
||||||
# for the full list
|
"depends": ["web", "base", "account", "l10n_ru_doc", 'l10n_ru_base'],
|
||||||
'category': 'Localization',
|
"data": [
|
||||||
'version': '17.0.1.230710',
|
#"views/webclient_templates.xml",
|
||||||
|
"views/ir_actions_report_view.xml",
|
||||||
# any module necessary for this one to work correctly
|
"views/res_partner_view.xml",
|
||||||
'depends': ['web','base','account','l10n_ru_doc','contract'],
|
"views/res_company_view.xml",
|
||||||
|
"views/res_users_view.xml",
|
||||||
# always loaded
|
"views/views_uom_okei.xml",
|
||||||
'data': [
|
"views/view_account_move.xml",
|
||||||
'views/ir_actions_report_view.xml',
|
"reports/upd_report.xml",
|
||||||
'views/res_partner_view.xml',
|
"reports/report.xml",
|
||||||
'views/res_company_view.xml',
|
|
||||||
'views/res_users_view.xml',
|
|
||||||
'views/views_uom_okei.xml',
|
|
||||||
'views/view_move.xml',
|
|
||||||
'reports/report.xml',
|
|
||||||
'reports/upd_report.xml',
|
|
||||||
],
|
],
|
||||||
|
|
||||||
'assets': {
|
"assets": {
|
||||||
'web.assets_backend': [
|
"web.assets_backend": [
|
||||||
'upd_xml/static/src/js/report/action_manager_report.js',
|
"l10n_ru_upd_xml/static/src/js/report/action_manager_report.js",
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
# only loaded in demonstration mode
|
|
||||||
'demo': [
|
|
||||||
'demo/demo.xml',
|
|
||||||
],
|
|
||||||
|
|
||||||
'external_dependencies': {
|
"external_dependencies": {
|
||||||
'python': [
|
"python": [
|
||||||
'lxml'
|
"lxml"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Binary file not shown.
@ -1,3 +1,3 @@
|
|||||||
# -*- coding: utf-8 -*-
|
# -*- coding: utf-8 -*-
|
||||||
|
|
||||||
from . import controllers
|
from . import main
|
||||||
|
Binary file not shown.
Binary file not shown.
@ -1,8 +1,7 @@
|
|||||||
# -*- coding: utf-8 -*-
|
|
||||||
|
|
||||||
from . import ir_actions_report
|
from . import ir_actions_report
|
||||||
from . import res_company
|
from . import res_company
|
||||||
from . import res_partner
|
from . import res_partner
|
||||||
from . import res_users
|
from . import res_users
|
||||||
from . import uom_okei
|
from . import uom_uom
|
||||||
from . import move
|
from . import account_move
|
||||||
|
from . import account_move_line
|
||||||
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user