@@ -37,8 +37,8 @@ import { emptyMessage } from "@/layouts/emptyMessage";
3737import { labelWithIcon } from "@/layouts/labelWithIcon" ;
3838import { page } from "@/layouts/page" ;
3939import { panel , panelBody } from "@/layouts/panel" ;
40- import { OrgTab } from "@/routes" ;
41- import { stringFor } from "@/strings/ui" ;
40+ import { OrgTab , WorkflowTab } from "@/routes" ;
41+ import { noData , stringFor } from "@/strings/ui" ;
4242import type { APIPaginatedList , APIPaginationQuery } from "@/types/api" ;
4343import type { Profile , Workflow } from "@/types/crawler" ;
4444import type { CrawlState } from "@/types/crawlState" ;
@@ -434,9 +434,12 @@ export class BrowserProfilesProfilePage extends BtrixElement {
434434 : none ,
435435 ) }
436436 </ btrix-desc-list-item >
437- < btrix-desc-list-item label =${ msg ( "Tags" ) } >
438- ${ this . renderDetail ( ( ) => html `${ none } ` ) }
439- </ btrix-desc-list-item >
437+ ${
438+ // <btrix-desc-list-item label=${msg("Tags")}>
439+ // ${this.renderDetail(() => html`${none}`) }
440+ // </btrix-desc-list-item>
441+ undefined
442+ }
440443 </ btrix-desc-list >
441444 < sl-divider class ="my-5 "> </ sl-divider >
442445 < btrix-desc-list >
@@ -459,16 +462,29 @@ export class BrowserProfilesProfilePage extends BtrixElement {
459462 ) ,
460463 ) }
461464 </ btrix-desc-list-item >
462- < btrix-desc-list-item label =${ msg ( "Modification Reason" ) } >
463- ${ this . renderDetail ( ( profile ) => {
464- const userName = profile . modifiedByName || profile . createdByName ;
465- if ( userName ) {
466- return `${ msg ( "Updated by" ) } ${ userName } ` ;
467- }
468-
469- return stringFor . notApplicable ;
470- } ) }
471- </ btrix-desc-list-item >
465+ ${ when ( this . profile , ( profile ) =>
466+ profile . modified
467+ ? html `< btrix-desc-list-item label =${ msg ( "Modified By" ) } >
468+ ${ this . renderDetail ( ( profile ) => {
469+ if (
470+ profile . modifiedCrawlDate &&
471+ ( ! profile . modified ||
472+ profile . modifiedCrawlDate >= profile . modified )
473+ ) {
474+ return msg ( "Automatic update from crawl" ) ;
475+ }
476+
477+ if ( profile . modifiedByName ) {
478+ return profile . modifiedByName ;
479+ }
480+
481+ return noData ;
482+ } ) }
483+ </ btrix-desc-list-item > `
484+ : html `< btrix-desc-list-item label =${ msg ( "Created By" ) } >
485+ ${ profile . createdByName || noData }
486+ </ btrix-desc-list-item > ` ,
487+ ) }
472488 < btrix-desc-list-item label =${ msg ( "Backup Status" ) } >
473489 ${ this . renderDetail ( ( profile ) => {
474490 const isBackedUp =
@@ -505,8 +521,22 @@ export class BrowserProfilesProfilePage extends BtrixElement {
505521 ? `${ this . localize . number ( this . workflowsTask . value . total ) } ${ pluralOf ( "workflows" , this . workflowsTask . value . total ) } `
506522 : html `< sl-skeleton > </ sl-skeleton > ` }
507523 </ btrix-desc-list-item >
508- < btrix-desc-list-item label =${ msg ( "Modified By Use" ) } >
509- ${ msg ( "No" ) }
524+ < btrix-desc-list-item
525+ label =${ msg ( "Last Modified by Crawl" ) }
526+ >
527+ ${ profile . modifiedCrawlId && profile . modifiedCrawlDate
528+ ? html `
529+ ${ this . localize . relativeDate (
530+ profile . modifiedCrawlDate ,
531+ ) }
532+
533+ < btrix-link
534+ href ="${ this . navigate
535+ . orgBasePath } /${ OrgTab . Workflows } /${ profile . modifiedCrawlCid } /${ WorkflowTab . Crawls } / ${ profile . modifiedCrawlId } "
536+ > ${ msg ( "View Crawl" ) } </ btrix-link
537+ >
538+ `
539+ : msg ( "No" ) }
510540 </ btrix-desc-list-item >
511541 </ btrix-desc-list >
512542 </ div >
0 commit comments