6553-workerBusiness #1311
|
@ -11,64 +11,6 @@ const quasar = useQuasar();
|
||||||
const route = useRoute();
|
const route = useRoute();
|
||||||
const tableRef = ref();
|
const tableRef = ref();
|
||||||
const entityId = computed(() => route.params.id);
|
const entityId = computed(() => route.params.id);
|
||||||
const businessFilter = {
|
|
||||||
include: [
|
|
||||||
{
|
|
||||||
relation: 'department',
|
|
||||||
scope: {
|
|
||||||
fields: ['id', 'name'],
|
|
||||||
},
|
|
||||||
},
|
|
||||||
{
|
|
||||||
relation: 'workCenter',
|
|
||||||
scope: {
|
|
||||||
fields: ['id', 'name'],
|
|
||||||
},
|
|
||||||
},
|
|
||||||
{
|
|
||||||
relation: 'companyCode',
|
|
||||||
scope: {
|
|
||||||
fields: ['code'],
|
|
||||||
},
|
|
||||||
},
|
|
||||||
{
|
|
||||||
relation: 'reasonEnd',
|
|
||||||
scope: {
|
|
||||||
fields: ['id', 'reason'],
|
|
||||||
},
|
|
||||||
},
|
|
||||||
{
|
|
||||||
relation: 'occupationCode',
|
|
||||||
scope: {
|
|
||||||
fields: ['code', 'name'],
|
|
||||||
},
|
|
||||||
},
|
|
||||||
{
|
|
||||||
relation: 'workerBusinessProfessionalCategory',
|
|
||||||
scope: {
|
|
||||||
fields: ['id', 'description'],
|
|
||||||
},
|
|
||||||
},
|
|
||||||
{
|
|
||||||
relation: 'calendarType',
|
|
||||||
scope: {
|
|
||||||
fields: ['id', 'description'],
|
|
||||||
},
|
|
||||||
},
|
|
||||||
{
|
|
||||||
relation: 'workerBusinessType',
|
|
||||||
scope: {
|
|
||||||
fields: ['id', 'name'],
|
|
||||||
},
|
|
||||||
},
|
|
||||||
// { Falla
|
|
||||||
// relation: 'workerBusinessAgreement',
|
|
||||||
// scope: {
|
|
||||||
// fields: ['id', 'name'],
|
|
||||||
// },
|
|
||||||
// },
|
|
||||||
],
|
|
||||||
};
|
|
||||||
|
|
||||||
async function reactivateWorker(business) {
|
async function reactivateWorker(business) {
|
||||||
console.log('value: ', business);
|
console.log('value: ', business);
|
||||||
|
@ -271,14 +213,14 @@ const columns = computed(() => [
|
||||||
}"
|
}"
|
||||||
order="id DESC"
|
order="id DESC"
|
||||||
:columns="columns"
|
:columns="columns"
|
||||||
:filter="businessFilter"
|
|
||||||
default-mode="card"
|
default-mode="card"
|
||||||
auto-load
|
auto-load
|
||||||
|
:disable-option="{ table: true }"
|
||||||
:right-search="false"
|
:right-search="false"
|
||||||
card-class="grid-two q-gutter-x-md"
|
card-class="grid-two q-gutter-x-md"
|
||||||
:is-editable="true"
|
:is-editable="true"
|
||||||
:use-model="true"
|
:use-model="true"
|
||||||
@save-changes="reactivateWorker"
|
@save-changes="reactivateWorker(entityId)"
|
||||||
/>
|
/>
|
||||||
</template>
|
</template>
|
||||||
<style lang="scss" scoped></style>
|
<style lang="scss" scoped></style>
|
||||||
|
|
|
@ -212,7 +212,7 @@ const filter = {
|
||||||
|
|
||||||
<VnLv
|
<VnLv
|
||||||
:label="t('worker.summary.reasonEnd')"
|
:label="t('worker.summary.reasonEnd')"
|
||||||
:value="worker.business[0].reasonEndFk"
|
:value="worker.business[0].reasonEnd.reason"
|
||||||
/>
|
/>
|
||||||
<VnLv
|
<VnLv
|
||||||
:label="t('worker.summary.department')"
|
:label="t('worker.summary.department')"
|
||||||
|
|
Loading…
Reference in New Issue