button added to add contact to personne morale (styling not correct yet) + opening of onTheFly thirdparty, but conditions and parameters not yet correct

This commit is contained in:
Julie Lenaerts 2022-01-12 17:38:24 +01:00
parent f2221565c5
commit 89edf508f5
3 changed files with 118 additions and 86 deletions

View File

@ -51,6 +51,16 @@
</div>
</template>
<template v-slot:body v-else-if="action === 'addContact'">
<on-the-fly-thirdparty
:parent="parent"
type="thirdparty"
action="create"
kind="child"
ref="castThirdparty">
</on-the-fly-thirdparty>
</template>
<template v-slot:body v-else>
<on-the-fly-create
:action="action"
@ -117,6 +127,8 @@ export default {
return 'btn-update';
case 'create':
return 'btn-create';
case 'addContact':
return 'btn-create';
}
},
titleAction() {

View File

@ -23,6 +23,11 @@
:entity="item.result"
:options="{ displayLong: true }">
</badge-entity>
<on-the-fly
type="thirdparty"
action="create"
:parent="item.result"
></on-the-fly>
<on-the-fly
type="thirdparty"
v-bind:id="item.result.id"

View File

@ -20,7 +20,7 @@
</div>
</div>
<div v-else-if="action === 'edit' || action === 'create'">
{{ action }}
<div class="form-floating mb-3" v-if="thirdparty.kind !== 'child'">
<div class="form-check">
<input class="form-check-input mt-0" type="radio" v-model="kind" value="company" id="tpartyKindInstitution">
@ -43,7 +43,22 @@
</div>
<div v-else>
<p>Contact de&nbsp;:</p>
<third-party-render-box :thirdparty="thirdparty.parent"
<third-party-render-box v-if="thirdparty.parent"
:thirdparty="thirdparty.parent"
:options="{
addInfo: true,
addEntity: false,
addAltNames: true,
addId: false,
addLink: false,
addAge: false,
hLevel: 4,
addCenter: false,
addNoData: true,
isMultiline: false
}"></third-party-render-box>
<third-party-render-box v-else
:thirdparty="parent"
:options="{
addInfo: true,
addEntity: false,