Skip to content

Commit

Permalink
Merge branch 'KelvinTegelaar:main' into main
Browse files Browse the repository at this point in the history
  • Loading branch information
luke255 authored Jul 13, 2023
2 parents 88fbf9d + 5951509 commit c03cb18
Show file tree
Hide file tree
Showing 26 changed files with 868 additions and 97 deletions.
54 changes: 54 additions & 0 deletions .github/ISSUE_TEMPLATE/CLA.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
name: CLA - Contributor License Agreement
description: Sign the CLA for CIPP and CIPP-API
labels: [CLA]

body:
- type: markdown
attributes:
value: >
CONTRIBUTOR LICENSE AGREEMENT ("Agreement")
Version 1.0
1. Definitions
"Contribution" means any original work of authorship, including any modifications or additions to an existing work, that is intentionally submitted by You to Kelvin Tegelaar for inclusion in, or documentation of, any of the products owned or managed by Kelvin Tegelaar (the "Work"). For the purposes of this definition, "submitted" means any form of electronic, verbal, or written communication sent to Kelvin Tegelaar or its representatives, including but not limited to communication on electronic mailing lists, source code control systems, and issue tracking systems that are managed by, or on behalf of, Kelvin Tegelaar for the purpose of discussing and improving the Work, but excluding communication that is conspicuously marked or otherwise designated in writing by You as "Not a Contribution."
"You" (or "Your") means the copyright owner or legal entity authorized by the copyright owner that is making this Agreement with Kelvin Tegelaar. For legal entities, the entity making a Contribution and all other entities that control, are controlled by, or are under common control with that entity are considered to be a single contributor. This Agreement applies both to future Contributions and Contributions made prior to the date of this Agreement.
2. Grant of Copyright License
Subject to the terms and conditions of this Agreement, You hereby grant to Kelvin Tegelaar and to recipients of software distributed by Kelvin Tegelaar a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare derivative works of, publicly display, publicly perform, sublicense, and distribute Your Contributions and such derivative works for the purpose of dual licensing the application.
3. Grant of Patent License
You grant Kelvin Tegelaar, and those who receive the Contribution directly or indirectly from Kelvin Tegelaar, a perpetual, worldwide, non-exclusive, royalty-free, irrevocable license under Your patent claims that are necessarily infringed by the Contribution or the combination of the Contribution with the Project to which it was submitted, to make, have made, use, offer to sell, sell, import, and otherwise dispose of the Contribution alone or with the Project.
4. Other Rights Reserved
Each party reserves all rights not expressly granted in this Agreement. No additional licenses or rights whatsoever (including, without limitation, any implied licenses) are granted by implication, exhaustion, estoppel, or otherwise.
You are not expected to provide support for your Contributions, except to the extent you desire to provide
support. You may provide support for free, for a fee, or not at all. Unless required by applicable law or agreed to in
writing, you provide your Contributions on an “AS IS” BASIS, WITHOUT WARRANTIES OR CONDITIONS OF
ANY KIND, EITHER EXPRESS OR IMPLIED, INCLUDING, WITHOUT LIMITATION, ANY WARRANTIES
OR CONDITIONS OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY, OR FITNESS FOR A
PARTICULAR PURPOSE.
5. Representations
You represent that you are legally entitled to grant the above licenses. If your employer(s) has rights to intellectual property that you create, you represent that you have received permission to make Contributions on behalf of that employer, or that your employer has waived such rights for your Contributions to Kelvin Tegelaar.
You represent that each of Your Contributions is Your original creation. You represent that Your Contribution submissions include complete details of any third-party license or other restriction (including, but not limited to, related patents and trademarks) of which you are personally aware and which are associated with any part of Your Contributions.
6. Project Sale
In the event that the Project is sold or otherwise transferred in ownership in its entirety to a third party, a sum equivalent to fifteen percent (15%) of the total sale price or value of the consideration received shall be set aside. This sum shall be divided amongst all Contributors who have entered into this Agreement, with each Contributor receiving a portion proportional to the relative quantity and significance of their Contributions to the Project, as determined by Kelvin Tegelaar. The method and timeframe of the distribution shall be at the discretion of Kelvin Tegelaar and shall be communicated
- type: textarea
attributes:
label: Description
description: >
Type "I Agree" in the text area.
validations:
required: true
3 changes: 3 additions & 0 deletions LICENSE.CustomLicenses
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
Custom licenses are available upon agreement via Github Sponsorships. Custom licenses will not have to be published in this repository. All contributors automatically agree with this provision.

A CLA is signed by contributors if they have contributed before these provisions. Only contributions currently in the running latest release require the CLA to be signed. The CLA is signed by creating a issue using the issue template "CLA". the agreement will be related directly to available CLA template.
2 changes: 1 addition & 1 deletion public/version_latest.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
3.6.0
3.7.0
3 changes: 3 additions & 0 deletions src/App.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@ import routes from 'src/routes'
import { Helmet } from 'react-helmet'
import adminRoutes from './adminRoutes'
import Skeleton from 'react-loading-skeleton'
import TimeAgo from 'javascript-time-ago'
import en from 'javascript-time-ago/locale/en.json'
TimeAgo.addDefaultLocale(en)

// Containers
const DefaultLayout = React.lazy(() => import('./layout/DefaultLayout'))
Expand Down
2 changes: 1 addition & 1 deletion src/components/layout/AppFooter.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ const AppFooter = () => {
</CLink>{' '}
<CLink href="https://datto.com/">
<CImage src={dattoLogo} alt="Datto" />
</CLink>
</CLink>{' '}
<CLink href="https://rewst.io/">
<CImage src={rewstLogo} alt="Datto" />
</CLink>
Expand Down
1 change: 1 addition & 0 deletions src/components/layout/AppHeader.js
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,7 @@ const AppHeader = () => {
</CHeader>

{dashboard &&
dashboard.length >= 1 &&
dashboard.map((item, index) => (
<div
className="mb-3"
Expand Down
3 changes: 0 additions & 3 deletions src/components/tables/CellDate.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,6 @@ import React from 'react'
import moment from 'moment'
import PropTypes from 'prop-types'
import { CTooltip } from '@coreui/react'
import TimeAgo from 'javascript-time-ago'
import en from 'javascript-time-ago/locale/en.json'
TimeAgo.addDefaultLocale(en)
import ReactTimeAgo from 'react-time-ago'

/**
Expand Down
23 changes: 16 additions & 7 deletions src/components/tables/CippTable.js
Original file line number Diff line number Diff line change
Expand Up @@ -329,8 +329,10 @@ export default function CippTable({

if (!disablePDFExport || !disableCSVExport) {
const keys = []
const exportFormatter = {}
columns.map((col) => {
if (col.exportSelector) keys.push(col.exportSelector)
if (col.exportFormatter) exportFormatter[col.exportSelector] = col.exportFormatter
return null
})

Expand All @@ -340,15 +342,22 @@ export default function CippTable({
keys.reduce((acc, curr) => {
const key = curr.split('/')
if (key.length > 1) {
const parent = key[0]
const subkey = key[1]
if (obj[parent] !== null && obj[parent][subkey] !== null) {
acc[curr] = obj[parent][subkey]
} else {
acc[curr] = 'n/a'
var property = obj
for (var x = 0; x < key.length; x++) {
if (property[key[x]] !== null) {
property = property[key[x]]
} else {
property = 'n/a'
break
}
}
acc[curr] = property
} else {
acc[curr] = obj[curr]
if (typeof exportFormatter[curr] === 'function') {
acc[curr] = exportFormatter[curr]({ cell: obj[curr] })
} else {
acc[curr] = obj[curr]
}
}
return acc
}, {}),
Expand Down
4 changes: 0 additions & 4 deletions src/components/utilities/CippActionsOffcanvas.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,6 @@ import { CippOffcanvasTable } from 'src/components/tables'
import { useLazyGenericGetRequestQuery, useLazyGenericPostRequestQuery } from 'src/store/api/app'
import { Link, useNavigate } from 'react-router-dom'
import { stringCamelCase } from 'src/components/utilities/CippCamelCase'
import TimeAgo from 'javascript-time-ago'

import en from 'javascript-time-ago/locale/en.json'
TimeAgo.addDefaultLocale(en)
import ReactTimeAgo from 'react-time-ago'

export default function CippActionsOffcanvas(props) {
Expand Down
16 changes: 3 additions & 13 deletions src/components/utilities/Toasts.js
Original file line number Diff line number Diff line change
Expand Up @@ -45,20 +45,10 @@ const Toast = ({ message, title, onClose, error }) => {
<CToastBody>
<div className="d-flex justify-content-between align-items-center text-danger">
<strong>{message}</strong>
<CButton size="sm" variant="outline" color="primary" onClick={() => setVisible(!visible)}>
Details
<FontAwesomeIcon
className="ms-1"
size="1x"
icon={visible ? faCompressAlt : faExpandAlt}
/>
</CButton>
</div>
<CCollapse visible={visible}>
<pre>
{error?.status} - {error?.message}
</pre>
</CCollapse>
<pre>
{error?.status} - {error?.message}
</pre>
</CToastBody>
</CToast>
)
Expand Down
Loading

0 comments on commit c03cb18

Please sign in to comment.