General change

This commit is contained in:
pepper 2020-12-10 23:17:14 -05:00
parent 9bc7b93def
commit 2508af3cde
8 changed files with 207 additions and 158 deletions

34
package-lock.json generated
View File

@ -2546,6 +2546,11 @@
} }
} }
}, },
"@types/lodash": {
"version": "4.14.165",
"resolved": "https://registry.npmjs.org/@types/lodash/-/lodash-4.14.165.tgz",
"integrity": "sha512-tjSSOTHhI5mCHTy/OOXYIhi2Wt1qcbHmuXD1Ha7q70CgI/I71afO4XtLb/cVexki1oVYchpul/TOuu3Arcdxrg=="
},
"@types/minimatch": { "@types/minimatch": {
"version": "3.0.3", "version": "3.0.3",
"resolved": "https://registry.npmjs.org/@types/minimatch/-/minimatch-3.0.3.tgz", "resolved": "https://registry.npmjs.org/@types/minimatch/-/minimatch-3.0.3.tgz",
@ -11750,6 +11755,11 @@
"resolved": "https://registry.npmjs.org/mute-stream/-/mute-stream-0.0.8.tgz", "resolved": "https://registry.npmjs.org/mute-stream/-/mute-stream-0.0.8.tgz",
"integrity": "sha512-nnbWWOkoWyUsTjKrhgD0dcz22mdkSnpYqbEjIm2nhwhuxlSkpywJmBo8h0ZqJdkp73mb90SssHkN4rsRaBAfAA==" "integrity": "sha512-nnbWWOkoWyUsTjKrhgD0dcz22mdkSnpYqbEjIm2nhwhuxlSkpywJmBo8h0ZqJdkp73mb90SssHkN4rsRaBAfAA=="
}, },
"nanoclone": {
"version": "0.2.1",
"resolved": "https://registry.npmjs.org/nanoclone/-/nanoclone-0.2.1.tgz",
"integrity": "sha512-wynEP02LmIbLpcYw8uBKpcfF6dmg2vcpKqxeH5UcoKEYdExslsdUA4ugFauuaeYdTB76ez6gJW8XAZ6CgkXYxA=="
},
"nanoid": { "nanoid": {
"version": "3.1.16", "version": "3.1.16",
"resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.1.16.tgz", "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.1.16.tgz",
@ -13849,6 +13859,11 @@
"warning": "^4.0.0" "warning": "^4.0.0"
} }
}, },
"property-expr": {
"version": "2.0.4",
"resolved": "https://registry.npmjs.org/property-expr/-/property-expr-2.0.4.tgz",
"integrity": "sha512-sFPkHQjVKheDNnPvotjQmm3KD3uk1fWKUN7CrpdbwmUx3CrG3QiM8QpTSimvig5vTXmTvjz7+TDvXOI9+4rkcg=="
},
"proxy-addr": { "proxy-addr": {
"version": "2.0.6", "version": "2.0.6",
"resolved": "https://registry.npmjs.org/proxy-addr/-/proxy-addr-2.0.6.tgz", "resolved": "https://registry.npmjs.org/proxy-addr/-/proxy-addr-2.0.6.tgz",
@ -17102,6 +17117,11 @@
"resolved": "https://registry.npmjs.org/toidentifier/-/toidentifier-1.0.0.tgz", "resolved": "https://registry.npmjs.org/toidentifier/-/toidentifier-1.0.0.tgz",
"integrity": "sha512-yaOH/Pk/VEhBWWTlhI+qXxDFXlejDGcQipMlyxda9nthulaxLZUNcUqFxokp0vcYnvteJln5FNQDRrxj3YcbVw==" "integrity": "sha512-yaOH/Pk/VEhBWWTlhI+qXxDFXlejDGcQipMlyxda9nthulaxLZUNcUqFxokp0vcYnvteJln5FNQDRrxj3YcbVw=="
}, },
"toposort": {
"version": "2.0.2",
"resolved": "https://registry.npmjs.org/toposort/-/toposort-2.0.2.tgz",
"integrity": "sha1-riF2gXXRVZ1IvvNUILL0li8JwzA="
},
"tough-cookie": { "tough-cookie": {
"version": "3.0.1", "version": "3.0.1",
"resolved": "https://registry.npmjs.org/tough-cookie/-/tough-cookie-3.0.1.tgz", "resolved": "https://registry.npmjs.org/tough-cookie/-/tough-cookie-3.0.1.tgz",
@ -19114,6 +19134,20 @@
"integrity": "sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==" "integrity": "sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg=="
} }
} }
},
"yup": {
"version": "0.32.5",
"resolved": "https://registry.npmjs.org/yup/-/yup-0.32.5.tgz",
"integrity": "sha512-bLbkTrPrFEF4rg30lS8T3QqoVLSAJ1N/b6btn5HVM4y9Q2EVJr2VLk+3kcskqPB41OSPx0cGRLINklH7PNqSYg==",
"requires": {
"@babel/runtime": "^7.10.5",
"@types/lodash": "^4.14.165",
"lodash": "^4.17.20",
"lodash-es": "^4.17.11",
"nanoclone": "^0.2.1",
"property-expr": "^2.0.4",
"toposort": "^2.0.2"
}
} }
} }
} }

View File

@ -43,7 +43,8 @@
"reactstrap-date-picker": "0.0.11", "reactstrap-date-picker": "0.0.11",
"redux": "^4.0.5", "redux": "^4.0.5",
"styled-components": "^5.2.1", "styled-components": "^5.2.1",
"web-vitals": "^0.2.4" "web-vitals": "^0.2.4",
"yup": "^0.32.5"
}, },
"scripts": { "scripts": {
"start": "react-scripts start", "start": "react-scripts start",

View File

@ -33,16 +33,8 @@ export class Navigation extends Component {
</li> </li>
</ul> </ul>
{/* Inline UUID search bar is here */} {/* Inline UUID search bar is here */}
<ul className="right hide-on-med-and-down"> <ul className="right ">
<li style={{ paddingRight: "1em" }}>UUID:</li> <InLineSearch />
<li>
<InLineSearch style={{ paddingRight: "4em" }}></InLineSearch>
</li>
{/* <li>
<Link>
<IdSearchForm />
</Link>
</li> */}
</ul> </ul>
</div> </div>
</div> </div>

View File

@ -6,6 +6,12 @@ import FormPage from "../common/Forms/FormPage";
// links directly to FormPage which contains the POST request // links directly to FormPage which contains the POST request
export default class Book extends Component { export default class Book extends Component {
constructor(props) {
super(props);
this.state = {
migs: [],
};
}
render() { render() {
return ( return (
<div className="container-fluid"> <div className="container-fluid">

View File

@ -31,6 +31,7 @@ export default class Reports extends Component {
.catch(function (error) { .catch(function (error) {
console.log(error); console.log(error);
}); });
console.log(urlID);
} }
render() { render() {

View File

@ -3,6 +3,7 @@ import "bootstrap/dist/css/bootstrap.min.css";
import moment from "moment"; import moment from "moment";
import { Col, FormGroup, Row, Container, Label } from "reactstrap"; import { Col, FormGroup, Row, Container, Label } from "reactstrap";
import { Formik, Form } from "formik"; import { Formik, Form } from "formik";
import * as Yup from "yup";
import { Input, Submit } from "formstrap"; import { Input, Submit } from "formstrap";
import { callAPI } from "../../../actions/API"; import { callAPI } from "../../../actions/API";
@ -10,6 +11,10 @@ import { callAPI } from "../../../actions/API";
// found at /book under the web hosting migration tab // found at /book under the web hosting migration tab
// Things to add: // Things to add:
// better date time picking. // better date time picking.
const InputValidation = Yup.object().shape({
domain: Yup.string().min(2, "Too Short!").required("Required"),
username: Yup.string().min(2, "Too Short!").required("Required"),
});
export const CPanelBooking = () => { export const CPanelBooking = () => {
const initialValues = { const initialValues = {
@ -30,7 +35,12 @@ export const CPanelBooking = () => {
resetForm({ values: "" }); resetForm({ values: "" });
}; };
return ( return (
<Formik initialValues={initialValues} onSubmit={onSubmit}> <Formik
initialValues={initialValues}
onSubmit={onSubmit}
validationSchema={InputValidation}
>
{({ errors, touched }) => (
<Form> <Form>
<Container> <Container>
<Row> <Row>
@ -176,6 +186,7 @@ export const CPanelBooking = () => {
<Submit withSpinner>Submit</Submit> <Submit withSpinner>Submit</Submit>
</Container> </Container>
</Form> </Form>
)}
</Formik> </Formik>
); );
}; };

View File

@ -13,7 +13,7 @@ import classnames from "classnames";
import { CPanelBooking } from "./CPanelBooking"; import { CPanelBooking } from "./CPanelBooking";
import EmailBooking from "./EmailBooking"; import EmailBooking from "./EmailBooking";
const FormPage = (props) => { const FormPage = ({ item }) => {
const [activeTab, setActiveTab] = useState("1"); const [activeTab, setActiveTab] = useState("1");
const toggle = (tab) => { const toggle = (tab) => {

View File

@ -29,7 +29,11 @@ class InLineSearch extends React.Component {
value={this.state.data} value={this.state.data}
onChange={this.onChange} onChange={this.onChange}
onKeyDown={this.onKeyPressed} onKeyDown={this.onKeyPressed}
></input> placeholder="Enter Migration UUID"
id="search"
type="search"
required
/>
</span> </span>
); );
} }