mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
Revert 2844 (#2980)
* Revert "review comments" This reverts commit97f2ecd88d. * Revert "Switch to I, remove type parameter default" This reverts commita3073cc99b. * Revert "Improve Table typing and remove annotations on callbacks" This reverts commitdefb0ea0dd.
This commit is contained in:
1 parent
97f2ecd88d
commit
60a19143b4
55 files changed
+471
-479
No files matched your search
@@ -27,6 +27,7 @@ import type { RouteComponentProps } from "react-router";
|
||||
import { podsStore } from "../+workloads-pods/pods.store";
|
||||
import { jobStore } from "./job.store";
|
||||
import { eventStore } from "../+events/event.store";
|
||||
import type { Job } from "../../api/endpoints/job.api";
|
||||
import { KubeObjectListLayout } from "../kube-object";
|
||||
import type { IJobsRouteParams } from "../+workloads";
|
||||
import kebabCase from "lodash/kebabCase";
|
||||
@@ -53,13 +54,13 @@ export class Jobs extends React.Component<Props> {
|
||||
className="Jobs" store={jobStore}
|
||||
dependentStores={[podsStore, eventStore]}
|
||||
sortingCallbacks={{
|
||||
[columnId.name]: job => job.getName(),
|
||||
[columnId.namespace]: job => job.getNs(),
|
||||
[columnId.conditions]: job => job.getCondition() != null ? job.getCondition().type : "",
|
||||
[columnId.age]: job => job.getTimeDiffFromNow(),
|
||||
[columnId.name]: (job: Job) => job.getName(),
|
||||
[columnId.namespace]: (job: Job) => job.getNs(),
|
||||
[columnId.conditions]: (job: Job) => job.getCondition() != null ? job.getCondition().type : "",
|
||||
[columnId.age]: (job: Job) => job.getTimeDiffFromNow(),
|
||||
}}
|
||||
searchFilters={[
|
||||
job => job.getSearchFields(),
|
||||
(job: Job) => job.getSearchFields(),
|
||||
]}
|
||||
renderHeaderTitle="Jobs"
|
||||
renderTableHeader={[
|
||||
@@ -70,7 +71,7 @@ export class Jobs extends React.Component<Props> {
|
||||
{ title: "Age", className: "age", sortBy: columnId.age, id: columnId.age },
|
||||
{ title: "Conditions", className: "conditions", sortBy: columnId.conditions, id: columnId.conditions },
|
||||
]}
|
||||
renderTableContents={job => {
|
||||
renderTableContents={(job: Job) => {
|
||||
const condition = job.getCondition();
|
||||
|
||||
return [
|
||||
|
||||
Reference in new issue
Block a user