diff --git a/resources/jscomposition/cases/casesDetail/config/columns.js b/resources/jscomposition/cases/casesDetail/config/columns.js index 6dc843a7ce..7d9b024ba1 100644 --- a/resources/jscomposition/cases/casesDetail/config/columns.js +++ b/resources/jscomposition/cases/casesDetail/config/columns.js @@ -20,9 +20,7 @@ const taskNumberColumn = () => ({ cellRenderer: () => ({ component: LinkCell, params: { - click: (row, column, columns) => { - window.document.location = `/tasks/${row.id}/edit`; - }, + href: (row) => `/tasks/${row.id}/edit`, }, }), }); @@ -36,9 +34,7 @@ const taskNameColumn = () => ({ cellRenderer: () => ({ component: LinkCell, params: { - click: (row, column, columns) => { - window.document.location = `/tasks/${row.id}/edit`; - }, + href: (row) => `/tasks/${row.id}/edit`, }, }), }); @@ -87,9 +83,7 @@ const requestIdColumn = () => ({ cellRenderer: () => ({ component: LinkCell, params: { - click: (row, column, columns) => { - window.document.location = `/requests/${row.id}`; - }, + href: (row) => `/requests/${row.id}`, }, }), }); @@ -111,9 +105,7 @@ const taskColumn = () => ({ cellRenderer: () => ({ component: TruncatedOptionsCell, params: { - click: (option, row, column, columns) => { - window.document.location = `/tasks/${option.id}/edit`; - }, + href: (row) => `/tasks/${row.id}/edit`, formatterOptions: (option, row, column, columns) => option.element_name, }, }), diff --git a/resources/jscomposition/cases/casesMain/config/columns.js b/resources/jscomposition/cases/casesMain/config/columns.js index 593fb53fb2..6d6bf05587 100644 --- a/resources/jscomposition/cases/casesMain/config/columns.js +++ b/resources/jscomposition/cases/casesMain/config/columns.js @@ -39,9 +39,7 @@ export const caseNumberColumn = () => ({ cellRenderer: () => ({ component: LinkCell, params: { - click: (row, column, columns) => { - window.document.location = `/cases/${row.case_number}`; - }, + href: (row) => `/cases/${row.case_number}`, }, }), }); @@ -54,9 +52,7 @@ export const caseTitleColumn = () => ({ cellRenderer: () => ({ component: CaseTitleCell, params: { - click: (row, column, columns) => { - window.document.location = `/cases/${row.case_number}`; - }, + href: (row) => `/cases/${row.case_number}`, }, }), filter: { @@ -89,9 +85,7 @@ export const taskColumn = () => ({ cellRenderer: () => ({ component: TruncatedOptionsCell, params: { - click: (option, row, column, columns) => { - window.document.location = `/tasks/${option.id}/edit`; - }, + href: (option) => `/tasks/${option.id}/edit`, formatterOptions: (option, row, column, columns) => option.name, }, }), diff --git a/resources/jscomposition/system/table/cell/CaseTitle.vue b/resources/jscomposition/system/table/cell/CaseTitle.vue new file mode 100644 index 0000000000..1b008e394b --- /dev/null +++ b/resources/jscomposition/system/table/cell/CaseTitle.vue @@ -0,0 +1,25 @@ + + diff --git a/resources/jscomposition/system/table/cell/CaseTitleCell.vue b/resources/jscomposition/system/table/cell/CaseTitleCell.vue index 0299bec34c..928f7b202b 100644 --- a/resources/jscomposition/system/table/cell/CaseTitleCell.vue +++ b/resources/jscomposition/system/table/cell/CaseTitleCell.vue @@ -1,25 +1,34 @@