Merge branch 'administativePages' of https://gitlab.com/kluppsoftware/smart-energia-web into administativePages
This commit is contained in:
commit
1a62aa6878
@ -26,6 +26,7 @@
|
|||||||
"@mui/material": "^5.6.4",
|
"@mui/material": "^5.6.4",
|
||||||
"@mui/x-data-grid": "^5.11.0",
|
"@mui/x-data-grid": "^5.11.0",
|
||||||
"@mui/x-date-pickers": "^5.0.0-alpha.3",
|
"@mui/x-date-pickers": "^5.0.0-alpha.3",
|
||||||
|
"@tinymce/tinymce-react": "^4.1.0",
|
||||||
"@types/react-csv": "^1.1.2",
|
"@types/react-csv": "^1.1.2",
|
||||||
"@typescript-eslint/eslint-plugin": "^5.22.0",
|
"@typescript-eslint/eslint-plugin": "^5.22.0",
|
||||||
"@typescript-eslint/parser": "^5.22.0",
|
"@typescript-eslint/parser": "^5.22.0",
|
||||||
@ -34,6 +35,7 @@
|
|||||||
"eslint-plugin-react": "^7.29.4",
|
"eslint-plugin-react": "^7.29.4",
|
||||||
"eslit": "^6.0.0",
|
"eslit": "^6.0.0",
|
||||||
"faker": "5.5.3",
|
"faker": "5.5.3",
|
||||||
|
"fs-extra": "^10.1.0",
|
||||||
"install": "^0.13.0",
|
"install": "^0.13.0",
|
||||||
"next": "12.1.6",
|
"next": "12.1.6",
|
||||||
"npm": "^8.10.0",
|
"npm": "^8.10.0",
|
||||||
@ -45,7 +47,8 @@
|
|||||||
"react-csv": "^2.2.2",
|
"react-csv": "^2.2.2",
|
||||||
"react-dom": "18.1.0",
|
"react-dom": "18.1.0",
|
||||||
"react-icons": "^4.3.1",
|
"react-icons": "^4.3.1",
|
||||||
"styled-components": "^5.3.5"
|
"styled-components": "^5.3.5",
|
||||||
|
"tinymce": "^6.0.3"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@babel/preset-env": "^7.17.10",
|
"@babel/preset-env": "^7.17.10",
|
||||||
|
|||||||
@ -53,7 +53,7 @@ export default function Sidebar() {
|
|||||||
<Image src='/assets/logo.svg' width={100} height={100} />
|
<Image src='/assets/logo.svg' width={100} height={100} />
|
||||||
</div>
|
</div>
|
||||||
<ul>
|
<ul>
|
||||||
<Link href='/administrative/dashboard'><li className={router.pathname=='/dashboard'? 'actualPath' : null} ><Image src='/assets/sidebar/dashboardIcon.svg' width={25} height={25} />{'Visão Geral'}</li></Link>
|
<Link href='/administrative'><li className={router.pathname=='/administrative'? 'actualPath' : null} ><Image src='/assets/sidebar/dashboardIcon.svg' width={25} height={25} />{'Visão Geral'}</li></Link>
|
||||||
{/* <li onClick={() => setEconomiaDrawer(!economiaDrawer)} className={router.pathname=='/grossSavings' || router.pathname=='/accumulatedSavings' || router.pathname=='/estimatedCost' || router.pathname=='/costIndicator' ? 'actualPath' : null } ><Image src='/assets/sidebar/economyIcon.svg' width={25} height={25} />{'Economia >'}</li>
|
{/* <li onClick={() => setEconomiaDrawer(!economiaDrawer)} className={router.pathname=='/grossSavings' || router.pathname=='/accumulatedSavings' || router.pathname=='/estimatedCost' || router.pathname=='/costIndicator' ? 'actualPath' : null } ><Image src='/assets/sidebar/economyIcon.svg' width={25} height={25} />{'Economia >'}</li>
|
||||||
<div className='economiaDrawer drawer' >
|
<div className='economiaDrawer drawer' >
|
||||||
<Link href='/administrative/grossSavings'><li className={router.pathname=='/grossSavings'? 'actualPathDrawer' : null}>Economia Bruta</li></Link>
|
<Link href='/administrative/grossSavings'><li className={router.pathname=='/grossSavings'? 'actualPathDrawer' : null}>Economia Bruta</li></Link>
|
||||||
|
|||||||
@ -1,94 +1,11 @@
|
|||||||
import FormControl from '@mui/material/FormControl';
|
import { Editor } from '@tinymce/tinymce-react'
|
||||||
import IconButton from '@mui/material/IconButton';
|
import React from 'react'
|
||||||
import InputAdornment from '@mui/material/InputAdornment';
|
|
||||||
import InputLabel from '@mui/material/InputLabel';
|
|
||||||
import OutlinedInput from '@mui/material/OutlinedInput';
|
|
||||||
import TextField from '@mui/material/TextField';
|
|
||||||
import Head from 'next/head';
|
|
||||||
import Image from 'next/image';
|
|
||||||
import Link from 'next/link';
|
|
||||||
import { useRouter } from 'next/router'
|
|
||||||
import React, { useState } from 'react'
|
|
||||||
import { AiOutlineEye, AiOutlineEyeInvisible } from 'react-icons/ai';
|
|
||||||
|
|
||||||
import LoginButton from '../../components/buttons/loginButton/LoginButton';
|
|
||||||
import { LoginContainer, LoginView } from '../../styles/layouts/login/LoginView';
|
|
||||||
|
|
||||||
export default function Home() {
|
|
||||||
const [state, setstate]=useState(false);
|
|
||||||
|
|
||||||
const [values, setValues] = React.useState({
|
|
||||||
password: '',
|
|
||||||
showPassword: false,
|
|
||||||
});
|
|
||||||
|
|
||||||
const router = useRouter()
|
|
||||||
const rota = router.pathname
|
|
||||||
|
|
||||||
const handleChange = (prop) => (event) => {
|
|
||||||
setValues({ ...values, [prop]: event.target.value });
|
|
||||||
};
|
|
||||||
|
|
||||||
const handleClickShowPassword = () => {
|
|
||||||
setValues({
|
|
||||||
...values,
|
|
||||||
showPassword: !values.showPassword,
|
|
||||||
});
|
|
||||||
};
|
|
||||||
|
|
||||||
const handleMouseDownPassword = (event) => {
|
|
||||||
event.preventDefault();
|
|
||||||
};
|
|
||||||
|
|
||||||
|
export default function index() {
|
||||||
return (
|
return (
|
||||||
<LoginView auth={rota} >
|
<>
|
||||||
<Head>
|
<div>Visão Geral</div>
|
||||||
<title>Smart Energia</title>
|
<Editor />
|
||||||
</Head>
|
</>
|
||||||
|
|
||||||
<div>
|
|
||||||
<Image src='/assets/marca1.svg' width={520} height={350} />
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<LoginContainer>
|
|
||||||
<h1>Bem-Vindo</h1>
|
|
||||||
<h2>Estratégias Inteligentes em<br /> Gestão de Energia</h2>
|
|
||||||
|
|
||||||
<TextField id="outlined-basic" sx={{ m: 1, width: '90%' }}label="Login" variant="outlined" />
|
|
||||||
<FormControl sx={{ m: 1, width: '90%' }} variant="outlined">
|
|
||||||
<InputLabel htmlFor="outlined-adornment-password">Password</InputLabel>
|
|
||||||
<OutlinedInput
|
|
||||||
id="outlined-adornment-password"
|
|
||||||
type={values.showPassword ? 'text' : 'password'}
|
|
||||||
value={values.password}
|
|
||||||
onChange={handleChange('password')}
|
|
||||||
endAdornment={
|
|
||||||
<InputAdornment position="end">
|
|
||||||
<IconButton
|
|
||||||
aria-label="toggle password visibility"
|
|
||||||
onClick={handleClickShowPassword}
|
|
||||||
onMouseDown={handleMouseDownPassword}
|
|
||||||
edge="end"
|
|
||||||
>
|
|
||||||
{values.showPassword ? <AiOutlineEye /> : <AiOutlineEyeInvisible />}
|
|
||||||
</IconButton>
|
|
||||||
</InputAdornment>
|
|
||||||
}
|
|
||||||
label="Password"
|
|
||||||
/>
|
|
||||||
</FormControl>
|
|
||||||
<Link href='verifyEmail' >Esqueceu a senha ?</Link>
|
|
||||||
|
|
||||||
<LoginButton title='ENTRAR' link />
|
|
||||||
|
|
||||||
<fieldset className="line">
|
|
||||||
<legend className="text">Ou</legend>
|
|
||||||
</fieldset>
|
|
||||||
|
|
||||||
<p><a href='tel:+55(41) 3012-5900' >+55(41) 3012-5900</a><br/><a href='https://www.energiasmart.com.br' target="_blank" rel="noreferrer" >www.energiasmart.com.br</a></p>
|
|
||||||
|
|
||||||
</LoginContainer>
|
|
||||||
|
|
||||||
</LoginView>
|
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|||||||
33
yarn.lock
33
yarn.lock
@ -1382,6 +1382,13 @@
|
|||||||
version "1.1.3"
|
version "1.1.3"
|
||||||
resolved "https://registry.npmjs.org/@rushstack/eslint-patch/-/eslint-patch-1.1.3.tgz"
|
resolved "https://registry.npmjs.org/@rushstack/eslint-patch/-/eslint-patch-1.1.3.tgz"
|
||||||
|
|
||||||
|
"@tinymce/tinymce-react@^4.1.0":
|
||||||
|
version "4.1.0"
|
||||||
|
resolved "https://registry.yarnpkg.com/@tinymce/tinymce-react/-/tinymce-react-4.1.0.tgz#e2a5e289dc1af03837365bebe969b1a722bf6d99"
|
||||||
|
dependencies:
|
||||||
|
prop-types "^15.6.2"
|
||||||
|
tinymce "^6.0.0 || ^5.5.1"
|
||||||
|
|
||||||
"@tootallnate/once@2":
|
"@tootallnate/once@2":
|
||||||
version "2.0.0"
|
version "2.0.0"
|
||||||
resolved "https://registry.yarnpkg.com/@tootallnate/once/-/once-2.0.0.tgz#f544a148d3ab35801c1f633a7441fd87c2e484bf"
|
resolved "https://registry.yarnpkg.com/@tootallnate/once/-/once-2.0.0.tgz#f544a148d3ab35801c1f633a7441fd87c2e484bf"
|
||||||
@ -2498,6 +2505,14 @@ flatted@^3.1.0:
|
|||||||
version "3.2.5"
|
version "3.2.5"
|
||||||
resolved "https://registry.npmjs.org/flatted/-/flatted-3.2.5.tgz"
|
resolved "https://registry.npmjs.org/flatted/-/flatted-3.2.5.tgz"
|
||||||
|
|
||||||
|
fs-extra@^10.1.0:
|
||||||
|
version "10.1.0"
|
||||||
|
resolved "https://registry.yarnpkg.com/fs-extra/-/fs-extra-10.1.0.tgz#02873cfbc4084dde127eaa5f9905eef2325d1abf"
|
||||||
|
dependencies:
|
||||||
|
graceful-fs "^4.2.0"
|
||||||
|
jsonfile "^6.0.1"
|
||||||
|
universalify "^2.0.0"
|
||||||
|
|
||||||
fs-minipass@^2.0.0, fs-minipass@^2.1.0:
|
fs-minipass@^2.0.0, fs-minipass@^2.1.0:
|
||||||
version "2.1.0"
|
version "2.1.0"
|
||||||
resolved "https://registry.yarnpkg.com/fs-minipass/-/fs-minipass-2.1.0.tgz#7f5036fdbf12c63c169190cbe4199c852271f9fb"
|
resolved "https://registry.yarnpkg.com/fs-minipass/-/fs-minipass-2.1.0.tgz#7f5036fdbf12c63c169190cbe4199c852271f9fb"
|
||||||
@ -2638,7 +2653,7 @@ globby@^11.0.4:
|
|||||||
merge2 "^1.4.1"
|
merge2 "^1.4.1"
|
||||||
slash "^3.0.0"
|
slash "^3.0.0"
|
||||||
|
|
||||||
graceful-fs@^4.1.2, graceful-fs@^4.2.10, graceful-fs@^4.2.6:
|
graceful-fs@^4.1.2, graceful-fs@^4.1.6, graceful-fs@^4.2.0, graceful-fs@^4.2.10, graceful-fs@^4.2.6:
|
||||||
version "4.2.10"
|
version "4.2.10"
|
||||||
resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.2.10.tgz#147d3a006da4ca3ce14728c7aefc287c367d7a6c"
|
resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.2.10.tgz#147d3a006da4ca3ce14728c7aefc287c367d7a6c"
|
||||||
|
|
||||||
@ -2973,6 +2988,14 @@ json5@^2.2.1:
|
|||||||
version "2.2.1"
|
version "2.2.1"
|
||||||
resolved "https://registry.npmjs.org/json5/-/json5-2.2.1.tgz"
|
resolved "https://registry.npmjs.org/json5/-/json5-2.2.1.tgz"
|
||||||
|
|
||||||
|
jsonfile@^6.0.1:
|
||||||
|
version "6.1.0"
|
||||||
|
resolved "https://registry.yarnpkg.com/jsonfile/-/jsonfile-6.1.0.tgz#bc55b2634793c679ec6403094eb13698a6ec0aae"
|
||||||
|
dependencies:
|
||||||
|
universalify "^2.0.0"
|
||||||
|
optionalDependencies:
|
||||||
|
graceful-fs "^4.1.6"
|
||||||
|
|
||||||
jsonparse@^1.3.1:
|
jsonparse@^1.3.1:
|
||||||
version "1.3.1"
|
version "1.3.1"
|
||||||
resolved "https://registry.yarnpkg.com/jsonparse/-/jsonparse-1.3.1.tgz#3f4dae4a91fac315f71062f8521cc239f1366280"
|
resolved "https://registry.yarnpkg.com/jsonparse/-/jsonparse-1.3.1.tgz#3f4dae4a91fac315f71062f8521cc239f1366280"
|
||||||
@ -4401,6 +4424,10 @@ tiny-warning@^1.0.2:
|
|||||||
version "1.0.3"
|
version "1.0.3"
|
||||||
resolved "https://registry.yarnpkg.com/tiny-warning/-/tiny-warning-1.0.3.tgz#94a30db453df4c643d0fd566060d60a875d84754"
|
resolved "https://registry.yarnpkg.com/tiny-warning/-/tiny-warning-1.0.3.tgz#94a30db453df4c643d0fd566060d60a875d84754"
|
||||||
|
|
||||||
|
"tinymce@^6.0.0 || ^5.5.1", tinymce@^6.0.3:
|
||||||
|
version "6.0.3"
|
||||||
|
resolved "https://registry.yarnpkg.com/tinymce/-/tinymce-6.0.3.tgz#993db09afa473a764ad8b594cdaf744b2c7e2e74"
|
||||||
|
|
||||||
to-fast-properties@^2.0.0:
|
to-fast-properties@^2.0.0:
|
||||||
version "2.0.0"
|
version "2.0.0"
|
||||||
resolved "https://registry.npmjs.org/to-fast-properties/-/to-fast-properties-2.0.0.tgz"
|
resolved "https://registry.npmjs.org/to-fast-properties/-/to-fast-properties-2.0.0.tgz"
|
||||||
@ -4496,6 +4523,10 @@ unique-slug@^2.0.0:
|
|||||||
dependencies:
|
dependencies:
|
||||||
imurmurhash "^0.1.4"
|
imurmurhash "^0.1.4"
|
||||||
|
|
||||||
|
universalify@^2.0.0:
|
||||||
|
version "2.0.0"
|
||||||
|
resolved "https://registry.yarnpkg.com/universalify/-/universalify-2.0.0.tgz#75a4984efedc4b08975c5aeb73f530d02df25717"
|
||||||
|
|
||||||
uri-js@^4.2.2:
|
uri-js@^4.2.2:
|
||||||
version "4.4.1"
|
version "4.4.1"
|
||||||
resolved "https://registry.npmjs.org/uri-js/-/uri-js-4.4.1.tgz"
|
resolved "https://registry.npmjs.org/uri-js/-/uri-js-4.4.1.tgz"
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user