|
|
@ -1,10 +1,7 @@
|
|
|
|
import { Form, useParams } from "react-router-dom";
|
|
|
|
import { useParams } from "react-router-dom";
|
|
|
|
import { useState, useEffect } from 'react';
|
|
|
|
import { useEffect } from 'react';
|
|
|
|
import { observer } from "mobx-react";
|
|
|
|
import { observer } from "mobx-react";
|
|
|
|
import { Row, Col, Typography, Space, DatePicker, Button, Select, Table, Tag } from 'antd';
|
|
|
|
import { Row, Col, Space, Button, Table, Tag } from 'antd';
|
|
|
|
import {
|
|
|
|
|
|
|
|
SearchOutlined,
|
|
|
|
|
|
|
|
} from '@ant-design/icons';
|
|
|
|
|
|
|
|
import { useStore } from '../stores/StoreContext.js';
|
|
|
|
import { useStore } from '../stores/StoreContext.js';
|
|
|
|
|
|
|
|
|
|
|
|
const columns = [
|
|
|
|
const columns = [
|
|
|
@ -82,7 +79,6 @@ const data = [
|
|
|
|
function Plan() {
|
|
|
|
function Plan() {
|
|
|
|
|
|
|
|
|
|
|
|
const {planId} = useParams();
|
|
|
|
const {planId} = useParams();
|
|
|
|
const [count, setCount] = useState(0);
|
|
|
|
|
|
|
|
const store = useStore();
|
|
|
|
const store = useStore();
|
|
|
|
const planStore = store.plan;
|
|
|
|
const planStore = store.plan;
|
|
|
|
|
|
|
|
|
|
|
@ -90,15 +86,6 @@ function Plan() {
|
|
|
|
console.info('planId: ' + planId);
|
|
|
|
console.info('planId: ' + planId);
|
|
|
|
}, [planId]);
|
|
|
|
}, [planId]);
|
|
|
|
|
|
|
|
|
|
|
|
const contact = {
|
|
|
|
|
|
|
|
first: "Your",
|
|
|
|
|
|
|
|
last: "Name",
|
|
|
|
|
|
|
|
avatar: "https://placekitten.com/g/200/200",
|
|
|
|
|
|
|
|
twitter: "your_handle",
|
|
|
|
|
|
|
|
notes: "Some notes",
|
|
|
|
|
|
|
|
favorite: true,
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
return (
|
|
|
|
return (
|
|
|
|
<Space direction="vertical" style={{ width: '100%' }}>
|
|
|
|
<Space direction="vertical" style={{ width: '100%' }}>
|
|
|
|
<Row gutter={{ md: 24 }} justify="end">
|
|
|
|
<Row gutter={{ md: 24 }} justify="end">
|
|
|
@ -120,24 +107,4 @@ function Plan() {
|
|
|
|
);
|
|
|
|
);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
function Favorite({ contact }) {
|
|
|
|
|
|
|
|
// yes, this is a `let` for later
|
|
|
|
|
|
|
|
let favorite = contact.favorite;
|
|
|
|
|
|
|
|
return (
|
|
|
|
|
|
|
|
<Form method="post">
|
|
|
|
|
|
|
|
<button
|
|
|
|
|
|
|
|
name="favorite"
|
|
|
|
|
|
|
|
value={favorite ? "false" : "true"}
|
|
|
|
|
|
|
|
aria-label={
|
|
|
|
|
|
|
|
favorite
|
|
|
|
|
|
|
|
? "Remove from favorites"
|
|
|
|
|
|
|
|
: "Add to favorites"
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
>
|
|
|
|
|
|
|
|
{favorite ? "★" : "☆"}
|
|
|
|
|
|
|
|
</button>
|
|
|
|
|
|
|
|
</Form>
|
|
|
|
|
|
|
|
);
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
export default observer(Plan);
|
|
|
|
export default observer(Plan);
|