Allow to open candidate from vacancy candidate card (#943)

Signed-off-by: Andrey Sobolev <haiodo@gmail.com>
This commit is contained in:
Andrey Sobolev 2022-02-07 16:21:59 +07:00 committed by GitHub
parent 666b4446b8
commit 11abc2f38c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 19 additions and 4 deletions

View File

@ -51,7 +51,6 @@ export default mergeIds(recruitId, recruit, {
KanbanCard: '' as AnyComponent,
ApplicationPresenter: '' as AnyComponent,
ApplicationsPresenter: '' as AnyComponent,
EditVacancy: '' as AnyComponent,
EditApplication: '' as AnyComponent,
TemplatesIcon: '' as AnyComponent,
Applications: '' as AnyComponent,

View File

@ -14,10 +14,12 @@
-->
<script lang="ts">
import contact, { Channel, formatName } from '@anticrm/contact'
import { ChannelsView } from '@anticrm/contact-resources'
import { Avatar, createQuery } from '@anticrm/presentation'
import type { Candidate } from '@anticrm/recruit'
import { ChannelsView } from '@anticrm/contact-resources'
import contact, { Channel, formatName } from '@anticrm/contact'
import { showPanel } from '@anticrm/ui'
import view from '@anticrm/view'
export let candidate: Candidate
@ -34,7 +36,9 @@
)
</script>
<div class="flex-col h-full card-container">
<div class="flex-col h-full card-container" on:click={() => {
showPanel(view.component.EditDoc, candidate._id, candidate._class, 'full')
}}>
<div class="label">CANDIDATE</div>
<Avatar avatar={candidate.avatar} size={'large'} />
{#if candidate}
@ -47,11 +51,19 @@
<style lang="scss">
.card-container {
cursor: pointer;
padding: 1rem 1.5rem 1.25rem;
background-color: var(--theme-button-bg-enabled);
border: 1px solid var(--theme-bg-accent-color);
border-radius: .75rem;
&:hover {
&:hover .name {
text-decoration: underline;
}
}
.label {
margin-bottom: 1.75rem;
font-weight: 500;

View File

@ -17,6 +17,7 @@ import { Ref, Space } from '@anticrm/core'
import type { IntlString, StatusCode } from '@anticrm/platform'
import { mergeIds } from '@anticrm/platform'
import recruit, { recruitId } from '@anticrm/recruit'
import { AnyComponent } from '@anticrm/ui'
export default mergeIds(recruitId, recruit, {
status: {
@ -60,5 +61,8 @@ export default mergeIds(recruitId, recruit, {
},
space: {
CandidatesPublic: '' as Ref<Space>
},
component: {
EditVacancy: '' as AnyComponent
}
})