Skip to content
Extraits de code Groupes Projets
Valider ecc1bc95 rédigé par Juliana's avatar Juliana
Parcourir les fichiers

Retours recettes + Mails 10/11 et 12/11

parent 4b80df6d
Aucune branche associée trouvée
Aucune étiquette associée trouvée
Aucune requête de fusion associée trouvée
......@@ -13,6 +13,7 @@
],
"data": [
"security/ir.model.access.csv",
"views/assets.xml",
"views/res_partner.xml",
]
}
......@@ -27,7 +27,7 @@ class ScopPartner(models.Model):
staff_planned = fields.Integer("Effectif prévu")
adhesion_comments = fields.Text("Commentaires Adhésion")
feasibility_study = fields.Boolean("Etude de faisabilité signée")
feasibility_study = fields.Boolean("Etude de faisabilité signée / validée")
amount_feasibility_study = fields.Integer(
"Montant de l’étude de faisabilité")
date_convention = fields.Date("Date de signature de la convention")
......@@ -36,7 +36,7 @@ class ScopPartner(models.Model):
date_transmission_cg = fields.Date(
"Date de transmission du dossier à la CG")
# Dossier EU
# Dossier UE
file_fse_open = fields.Boolean("Dossier FSE ouvert Oui/Non")
date_return_file = fields.Date("Date de retour du dossier")
fse_full = fields.Boolean("FSE Complet")
......
Fichier ajouté
odoo.define('cgscop_adhesion.basic_fields', function (require) {
"use strict";
var AbstractField = require('web.AbstractField');
var fieldRegistry = require('web.field_registry');
var PriorityWidgetCG = AbstractField.extend({
className: "o_priority",
events: {
'click > a': '_onClick',
},
supportedFieldTypes: ['selection'],
isSet: function () {
return true;
},
_render: function () {
var self = this;
var index_value = this.value ? _.findIndex(this.field.selection, function (v) {
return v[0] === self.value;
}) : 0;
this.$el.empty();
this.empty_value = this.field.selection[0][0];
_.each(this.field.selection.slice(1), function (choice, index) {
self.$el.append(self._renderStar('<a href="#">', index_value >= index+1, index+1, choice[1]));
});
},
_renderStar: function (tag, isFull, index, tip) {
return $(tag)
.attr('title', tip)
.attr('aria-label', tip)
.attr('data-index', index)
.addClass('o_priority_star fa')
.toggleClass('fa-star', isFull)
.toggleClass('fa-star-o', !isFull);
},
_onClick: function (event) {
event.preventDefault();
event.stopPropagation();
},
});
fieldRegistry.add('prioritycg', PriorityWidgetCG);
});
<?xml version="1.0"?>
<!-- Copyright 2019 Le Filament
License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). -->
<odoo>
<template id="cgscop_assets_backend" name="account assets" inherit_id="web.assets_backend">
<xpath expr="." position="inside">
<script type="text/javascript" src="/cgscop_adhesion/static/src/js/basic_fields.js"/>
</xpath>
</template>
</odoo>
\ No newline at end of file
......@@ -13,7 +13,10 @@
<field name="percent_realisation"/>
</xpath>
<xpath expr="//div[hasclass('oe_kanban_partner_links')]" position="after">
<field name="percent_realisation" widget="priority"/>
<div>
<!-- <label for='percent_realisation' class="oe_edit_only"/> -->
<field name="percent_realisation" widget="prioritycg" readonly="1"/>
</div>
</xpath>
</field>
</record>
......@@ -30,9 +33,9 @@
<group string="Général">
<field name="percent_realisation" widget="priority" />
<field name="date_realisation"/>
<field name="prescriber_canal_id" widget="res_partner_many2one" options="{'no_create': True}"/>
<field name="prescriber_canal_id" widget="res_partner_many2one" options="{'no_create': True, 'no_open': True}"/>
</group>
<group string="Dossier EU">
<group string="Dossier UE">
<field name="file_fse_open" widget="boolean_toggle"/>
<field name="date_return_file"/>
<field name="fse_full" widget="boolean_toggle"/>
......@@ -48,7 +51,7 @@
<field name="feasibility_study" widget="boolean_toggle"/>
<field name="amount_feasibility_study" widget="monetary"/>
</group>
<group string="Phase d'accompagnement" attrs="{'invisible':[('project_status','in',('1_information','2_pre-diagnostic'))]}">
<group string="Phase d'accompagnement projet" attrs="{'invisible':[('project_status','in',('1_information','2_pre-diagnostic'))]}">
<field name="date_convention"/>
<field name="amount_convention" widget="monetary"/>
</group>
......@@ -65,11 +68,11 @@
<group string="Général">
<field name="percent_realisation" widget="priority"/>
<field name="date_realisation"/>
<field name="prescriber_canal_id" widget="res_partner_many2one" options="{'no_create': True}"/>
<field name="prescriber_canal_id" widget="res_partner_many2one" options="{'no_create': True, 'no_open': True}"/>
<field name="creation_delegate_id" widget="res_partner_many2one"
attrs="{'required':[('project_status','in',('3_accompagnement','4_adhesion', '5_cg'))]}" options="{'no_create': True}" domain="[('ur_id', '=', ur_id)]"/>
</group>
<group string="Dossier EU">
<group string="Dossier UE">
<field name="file_fse_open" widget="boolean_toggle"/>
<field name="date_return_file"/>
<field name="fse_full" widget="boolean_toggle"/>
......@@ -85,7 +88,7 @@
<field name="feasibility_study" widget="boolean_toggle"/>
<field name="amount_feasibility_study" widget="monetary"/>
</group>
<group string="Phase d'accompagnement" attrs="{'invisible':[('project_status','in',('1_information','2_pre-diagnostic'))]}">
<group string="Phase d'accompagnement projet" attrs="{'invisible':[('project_status','in',('1_information','2_pre-diagnostic'))]}">
<field name="date_convention"/>
<field name="amount_convention" widget="monetary"/>
</group>
......@@ -139,7 +142,7 @@
<field name="inherit_id" ref="base.view_partner_form"/>
<field name="arch" type="xml">
<xpath expr='//notebook' position="inside">
<page name="eu_file" string="Dossier EU" attrs="{'invisible': ['|', ('is_company', '=', True), ('type','!=','contact')]}">
<page name="eu_file" string="Dossier UE" attrs="{'invisible': ['|', ('is_company', '=', True), ('type','!=','contact')]}">
<group>
<field name="file_fse_open" widget="boolean_toggle"/>
<field name="date_return_file"/>
......
0% Chargement en cours ou .
You are about to add 0 people to the discussion. Proceed with caution.
Veuillez vous inscrire ou vous pour commenter