EditApprovalMatrix.js 30.7 KB
Newer Older
1
import React, { Component } from 'react';
2 3
import { TextField, Typography } from '@material-ui/core';
import { DateTimePicker, KeyboardDatePicker, DatePicker} from "@material-ui/pickers";
4 5
import Autocomplete from '@material-ui/lab/Autocomplete';
import * as R from 'ramda'
6
import format from "date-fns/format";
7
import api from "../../api";
d.arizona's avatar
d.arizona committed
8
import Images from '../../assets/Images';
a.bairuha's avatar
a.bairuha committed
9
import Constant from '../../library/Constant';
10 11

export default class EditApprovalMatrix extends Component {
12 13 14
    constructor(props) {
        super(props)
        this.state = {
15 16
            id: '',
            order: '',
17
            status: "",
18 19
            startDate: null,
            endDate: null,
20 21
            date: new Date(),
            approvedBy: null,
22 23 24 25
            getApprovedBy: null,
            types: null,
            getTypes: null,
            operators: null,
26
            getOperators: null,
27 28 29 30 31 32
            errorType: false,
            msgErrType: '',
            errorApproved: false,
            msgErrApproved: '',
            errorOperator: false,
            msgErrOperator: '',
33 34 35 36 37 38
            errorOrder: false,
            msgErrOrder: '',
            errorStartDate: false,
            errorEndDate: false,
            msgErrorStartDate: "",
            msgErrorEndDate: ""
39 40 41 42
        }
    }

    componentDidMount() {
Rifka Kurnia Irfiana's avatar
Rifka Kurnia Irfiana committed
43
        if (this.props.type === 'edit') {
44 45
            this.getDetailAM()
            console.log(this.state.startDate);
46 47 48
            // let getApprovedBy = {
            //     user_id: data.user_id,
            //     fullname: data.fullname
49
            // })
Rifka Kurnia Irfiana's avatar
Rifka Kurnia Irfiana committed
50
        }
51 52 53 54 55 56
    }

    getDetailAM() {
        api.create().getDetailAM(this.props.data[1]).then(response => {
            // console.log(response)
            if (response.data) {
a.bairuha's avatar
a.bairuha committed
57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73
                if (response.ok) {
                    if (response.data.status === "success") {
                        let data = response.data.data
                        this.setState({
                            id: data.approval_matrix_id,
                            startDate: data.start_date,
                            endDate: data.end_date,
                            order: data.orders,
                            getUserId: data.user_id,
                            getTypeId: data.approval_type_id,
                            getOperatorId: data.operator_type_id,
                            status: data.status,
                            created: data.created,
                            updated: data.updated === null ? "" : data.updated 
                        }, () => this.getUserData(), this.getTypeData(), this.getOperatorData())
                    } else {
                        this.setState({ alert: true, messageAlert: response.data.message, tipeAlert: 'warning' }, () => {
a.bairuha's avatar
a.bairuha committed
74
                            if (response.data.message.includes("Someone Logged In")) {
a.bairuha's avatar
a.bairuha committed
75 76 77 78 79 80 81 82 83
                                setTimeout(() => {
                                    localStorage.removeItem(Constant.TOKEN)
                                    window.location.reload();
                                }, 1000);
                            }
                        })
                    }
                } else {
                    this.setState({ alert: true, messageAlert: response.problem, tipeAlert: 'error' })
84
                }
a.bairuha's avatar
a.bairuha committed
85 86
            } else {
                this.setState({ alert: true, messageAlert: response.problem, tipeAlert: 'error' })
87 88
            }
        })
89 90 91 92
    }

    getUserData() {
        api.create().getApprovedByAM().then((response) => {
a.bairuha's avatar
a.bairuha committed
93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112
            if (response.data) {
                if (response.ok) {
                    if (response.data.status == 'success') {
                        let data = response.data.data
                        let userData = data.map((item) => {
                            return {
                                user_id: item.user_id,
                                fullname: item.fullname
                            }
                        })
                        let index = userData.findIndex((val) => val.user_id == this.state.getUserId)
                        let defaultProps = {
                            options: userData,
                            getOptionLabel: (option) => option.fullname,
                        };
                        // this.setState({ approvedBy: defaultProps, userData: response.data.data, getApprovedBy: index == -1 ? userData[0]: userData[index] })
                        this.setState({ approvedBy: defaultProps, userData: response.data.data, getApprovedBy: index == -1 ? this.setState({ errorApproved: true, msgErrApproved: 'Approver Name has been Inactive.' }): userData[index] })
                        
                    } else {
                        // alert('Pemberi Persetujuan: ' +response.data.message)
a.bairuha's avatar
a.bairuha committed
113
                        if (response.data.message.includes("Someone Logged In")) {
a.bairuha's avatar
a.bairuha committed
114 115 116 117 118 119 120 121 122
                            this.setState({ alert: true, messageAlert: response.data.message, tipeAlert: 'warning' }, () => {
                                setTimeout(() => {
                                    localStorage.removeItem(Constant.TOKEN)
                                    window.location.reload();
                                }, 1000);
                            })
                        } else {
                            this.setState({ alert: true, messageAlert: 'Pemberi Persetujuan: ' +response.data.message, tipeAlert: 'error' })
                        }
123
                    }
a.bairuha's avatar
a.bairuha committed
124 125 126
                } else {
                    this.setState({ alert: true, messageAlert: response.problem, tipeAlert: 'error' })
                }
127
            } else {
a.bairuha's avatar
a.bairuha committed
128
                this.setState({ alert: true, messageAlert: response.problem, tipeAlert: 'error' })
129 130
            }
        })
131 132
    }

133 134
    getOperatorData() {
        api.create().getOperatorAM().then((response) => {
a.bairuha's avatar
a.bairuha committed
135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152
            if (response.data) {
                if (response.ok) {
                    if (response.data.status == 'success') {
                        let data = response.data.data
                        let operatorData = data.map((item) => {
                            return {
                                operator_type_id: item.operator_type_id,
                                operator_type_name: item.operator_type_name
                            }
                        })
                        let index = operatorData.findIndex((val) => val.operator_type_id == this.state.getOperatorId)
                        let operatorProps = {
                            options: operatorData,
                            getOptionLabel: (option) => option.operator_type_name,
                        };
                        this.setState({ operators: operatorProps, operatorData: response.data.data, getOperators: index == -1 ? operatorData[0]: operatorData[index] })                
                    } else {
                        // alert('Operator: ' +response.data.message)
a.bairuha's avatar
a.bairuha committed
153
                        if (response.data.message.includes("Someone Logged In")) {
a.bairuha's avatar
a.bairuha committed
154 155 156 157 158 159 160 161 162
                            this.setState({ alert: true, messageAlert: response.data.message, tipeAlert: 'warning' }, () => {
                                setTimeout(() => {
                                    localStorage.removeItem(Constant.TOKEN)
                                    window.location.reload();
                                }, 1000);
                            })
                        } else {
                            this.setState({ alert: true, messageAlert: 'Operator: ' +response.data.message, tipeAlert: 'error' })
                        }
163
                    }
a.bairuha's avatar
a.bairuha committed
164 165 166
                } else {
                    this.setState({ alert: true, messageAlert: response.problem, tipeAlert: 'error' })
                }
167
            } else {
a.bairuha's avatar
a.bairuha committed
168
                this.setState({ alert: true, messageAlert: response.problem, tipeAlert: 'error' })
169 170 171 172 173 174
            }
        })
    }

    getTypeData() {
        api.create().getTypeAM().then((response) => {
a.bairuha's avatar
a.bairuha committed
175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192
            if (response.data) {
                if (response.ok) {
                    if (response.data.status == 'success') {
                        let data = response.data.data
                        let typeData = data.map((item) => {
                            return {
                                approval_type_id: item.approval_type_id,
                                approval_type_name: item.approval_type_name
                            }
                        })
                        let index = typeData.findIndex((val) => val.approval_type_id == this.state.getTypeId)
                        let typeProps = {
                            options: typeData,
                            getOptionLabel: (option) => option.approval_type_name,
                        };
                        this.setState({ types: typeProps, typeData: response.data.data, getTypes: index == -1 ? typeData[0]: typeData[index] })
                    } else {
                        // alert('Approval Type: ' +response.data.message)
a.bairuha's avatar
a.bairuha committed
193
                        if (response.data.message.includes("Someone Logged In")) {
a.bairuha's avatar
a.bairuha committed
194 195 196 197 198 199 200 201 202
                            this.setState({ alert: true, messageAlert: response.data.message, tipeAlert: 'warning' }, () => {
                                setTimeout(() => {
                                    localStorage.removeItem(Constant.TOKEN)
                                    window.location.reload();
                                }, 1000);
                            })
                        } else {
                            this.setState({ alert: true, messageAlert: 'Approval Type: ' +response.data.message, tipeAlert: 'error' })
                        }
203
                    }
a.bairuha's avatar
a.bairuha committed
204 205 206
                } else {
                    this.setState({ alert: true, messageAlert: response.problem, tipeAlert: 'error' })
                }
207
            } else {
a.bairuha's avatar
a.bairuha committed
208
                this.setState({ alert: true, messageAlert: response.problem, tipeAlert: 'error' })
209 210 211 212 213
            }
        })
    }


214 215
    handleChange(e, type) {
        let data = this.state
Rifka Kurnia Irfiana's avatar
Rifka Kurnia Irfiana committed
216
        let isDate = type !== '' ? true : false
217
        if (isDate && type == 'start_date') {
218 219
            this.setState({ startDate: format(e, 'yyyy-MM-dd'), endDate: null }, () => {
                this.clearError()
220
                // console.log(this.state.startDate)
Rifka Kurnia Irfiana's avatar
Rifka Kurnia Irfiana committed
221
            })
222
        } else if (isDate && type == 'end_date') {
Rifka Kurnia Irfiana's avatar
Rifka Kurnia Irfiana committed
223
            this.setState({ endDate: format(e, 'yyyy-MM-dd') }, () => {
224
                this.clearError()
225
                // console.log(this.state.endDate)
Rifka Kurnia Irfiana's avatar
Rifka Kurnia Irfiana committed
226
            })
227
        } else {
Rifka Kurnia Irfiana's avatar
Rifka Kurnia Irfiana committed
228
            // this.setState({...data, tempData: {...this.state.tempData, [e.target.name] :  e.target.value}})
229
        }
Rifka Kurnia Irfiana's avatar
Rifka Kurnia Irfiana committed
230

231 232
    }

233 234
    clearError() {
        this.setState({
235 236 237 238 239 240
            errorType: false,
            msgErrType: '',
            errorApproved: false,
            msgErrApproved: '',
            errorOperator: false,
            msgErrOperator: '',
241 242 243 244 245 246 247 248 249
            errorOrder: false,
            msgErrOrder: "",
            errorStartDate: false,
            errorEndDate: false,
            msgErrorStartDate: "",
            msgErrorEndDate: ""
        })
    }

250
    validasi() {
251
        if (R.isNil(this.state.getTypes)) {
252
            this.setState({ errorType: true, msgErrType: 'Approval Type Cannot be Empty' })
253 254
        }
        else if (R.isEmpty(this.state.order)) {
255
            this.setState({ errorOrder: true, msgErrOrder: 'Order Cannot be Empty'})
256
        }
257
        else if (R.isNil(this.state.getApprovedBy)) {
258
            this.setState({ errorApproved: true, msgErrApproved: 'Approver Name Cannot be Empty' })
259 260
        } 
        else if (R.isNil(this.state.getOperators)) {
261
            this.setState({ errorOperator: true, msgErrOperator: 'Operator Cannot be Empty' })
262
        } 
263
        else if (R.isEmpty(this.state.startDate)) {
264
            this.setState({ errorStartDate: true, msgErrorStartDate: 'Valid From Cannot be Empty' })
265
        } else if (R.isEmpty(this.state.endDate)) {
266
            this.setState({ errorEndDate: true, msgErrorEndDate: 'Valid To Cannot be Empty' })
267 268 269 270 271 272 273 274 275 276 277 278 279 280
        } else {
            console.log('masuk');
            if (this.props.type == 'edit') {
            let payload = {
                    "approval_matrix_id": this.state.id,
                    "approval_type_id": this.state.getTypes.approval_type_id,
                    "orders": this.state.order,
                    "user_id": this.state.getApprovedBy.user_id,
                    "operator_type_id": this.state.getOperators.operator_type_id,
                    "start_date": this.state.startDate,
                    "end_date": this.state.endDate
                }
                this.props.updateAM(payload)
                // console.log(payload)
281
            }
282
        }
283 284
    }

Rifka Kurnia Irfiana's avatar
Rifka Kurnia Irfiana committed
285
    render() {
286 287 288
        return (
            <div className="test app-popup-show" style={{ paddingTop: 100 }}>
                <div className="popup-content background-white border-radius" style={{ borderRadius: 8 }}>
289
                    <div className="popup-panel grid grid-2x main-color" style={{ height: 64, borderTopRightRadius: 8, borderTopLeftRadius: 8 }}>
290 291 292 293 294 295 296 297 298 299 300
                        <div className="col-1" style={{ maxWidth: "inherit", display: 'flex', alignItems: 'center' }}>
                            <div className="popup-title">
                                <span style={{ color: '#fff', fontSize: 16, fontWeight: 'bold' }}>Edit Data</span>
                            </div>
                        </div>
                        <div className="col-2 content-right" style={{ maxWidth: "inherit", alignSelf: 'center' }}>
                            <button
                                type="button"
                                className="btn btn-circle btn-white"
                                onClick={() => this.props.onClickClose()}
                            >
d.arizona's avatar
d.arizona committed
301
                                <img src={Images.close}/>
302 303 304 305 306 307 308
                            </button>
                        </div>
                    </div>

                    <div className="border-bottom" style={{ padding: 20 }}>
                        <div className="grid grid-2x grid-mobile-none gap-15px">
                            <div className="column-1">
309
                                <div style={{ backgroundColor: '#e8e8e8', padding: 10, borderRadius: 5 }}>
310
                                    <TextField
311
                                        style={{ width: '100%' }}
312 313
                                        id="id"
                                        label="ID"
314
                                        value={this.state.id}
315 316 317 318 319 320 321 322 323 324 325 326 327
                                        disabled
                                        inputProps={{
                                            style: {
                                                fontSize: 11
                                            }
                                        }}
                                        InputLabelProps={{
                                            style: {
                                                fontSize: 11,
                                                color: '#7e8085'
                                            }
                                        }}
                                    />
328 329 330
                                </div>
                            </div>
                            <div className="column-2">
331 332 333 334
                                <div className="" style={{ padding: 10, borderRadius: 5 }}>
                                    <Autocomplete
                                        {...this.state.types}
                                        option
335
                                        debug
336
                                        id="tipe"
337
                                        onChange={(event, newInputValue) => this.setState({getTypes:newInputValue}, ()=> this.clearError())}
338 339
                                        renderInput={(params) => 
                                            <TextField {...params} 
340
                                                label="Approval Type" 
341 342 343
                                                onChange={(e) => this.handleChange(e, '')}
                                                error={this.state.errorType}
                                                helperText={this.state.msgErrType}
344 345 346 347 348 349 350 351
                                                InputLabelProps={{
                                                    style: {
                                                        fontSize: 11,
                                                        color: '#7e8085'
                                                    }
                                                }}
                                                InputProps={{ ...params.InputProps, style: { fontSize: 11 } }}
                                        />}
352 353
                                        value={this.state.getTypes}
                                    />
354 355 356 357 358
                                </div>
                            </div>
                        </div>
                        <div className="grid grid-2x grid-mobile-none gap-15px">
                            <div className="column-1">
359
                                <div className="margin-top-10px" style={{ padding: 10, borderRadius: 5 }}>
360 361 362 363
                                    <TextField
                                        style={{ width: '100%' }}
                                        id="order"
                                        label="Order"
364
                                        value={this.state.order === null ? '' : this.state.order}
365 366
                                        error={this.state.errorOrder}
                                        helperText={this.state.msgErrOrder}
367 368 369 370 371 372 373 374 375
                                        // onChange={(e) => this.setState({ order: e.target.value }, () => this.clearError())}
                                        onChange={(e) => {
                                            let coba = String(e.target.value).replace(/[^\d]/g,'');
                                            this.setState({
                                                order: coba
                                            }, 
                                            () => this.clearError())}
                                            // this.handleChange(coba, 'value')}
                                        }
376 377 378 379 380 381 382 383 384 385 386
                                        inputProps={{
                                            style: {
                                                fontSize: 11
                                            }
                                        }}
                                        InputLabelProps={{
                                            style: {
                                                fontSize: 11,
                                                color: '#7e8085'
                                            }
                                        }}
387
                                        // name="order"
388 389 390 391 392
                                    >
                                    </TextField>
                                </div>
                            </div>
                            <div className="column-2">
393
                                <div className="margin-top-10px" style={{ padding: 10, borderRadius: 5 }}>
394 395 396
                                    <Autocomplete
                                        {...this.state.approvedBy}
                                        option
397
                                        debug
398
                                        id="approvedby"
399
                                        onChange={(event, newInputValue) => this.setState({getApprovedBy: newInputValue}, ()=> this.clearError())}
400 401
                                        renderInput={(params) => 
                                            <TextField {...params} 
402
                                                label="Approver Name"
403 404 405
                                                onChange={(e) => this.handleChange(e, '')}
                                                error={this.state.errorApproved}
                                                helperText={this.state.msgErrApproved}
406 407 408 409 410 411 412 413
                                                InputLabelProps={{
                                                    style: {
                                                        fontSize: 11,
                                                        color: '#7e8085'
                                                    }
                                                }}
                                                InputProps={{ ...params.InputProps, style: { fontSize: 11 } }}
                                            />}
414 415
                                        value={this.state.getApprovedBy}
                                    />
416 417 418 419 420
                                </div>
                            </div>
                        </div>
                        <div className="grid grid-2x grid-mobile-none gap-15px">
                            <div className="column-1">
421 422 423 424
                                <div className="margin-top-10px" style={{ padding: 10, borderRadius: 5 }}>
                                    <Autocomplete
                                        {...this.state.operators}
                                        option
425
                                        debug
426
                                        id="operator"
427
                                        onChange={(event, newInputValue) => this.setState({getOperators: newInputValue}, ()=> this.clearError())}
428 429 430
                                        renderInput={(params) => 
                                            <TextField {...params} 
                                                label="Operator" 
431 432 433
                                                onChange={(e) => this.handleChange(e, '')}
                                                error={this.state.errorOperator}
                                                helperText={this.state.msgErrOperator}
434 435 436 437 438 439 440 441
                                                InputLabelProps={{
                                                    style: {
                                                        fontSize: 11,
                                                        color: '#7e8085'
                                                    }
                                                }}
                                                InputProps={{ ...params.InputProps, style: { fontSize: 11 } }}
                                            />}
442 443
                                        value={this.state.getOperators}
                                    />
444 445 446 447 448 449 450 451
                                </div>
                            </div>
                            <div className="column-2">
                                
                            </div>
                        </div>
                        <div className="grid grid-2x grid-mobile-none gap-15px">
                            <div className="column-1">
452 453 454 455
                                <div className="margin-top-10px" style={{ padding: 10, borderRadius: 5 }}>
                                    <DatePicker
                                        margin="normal"
                                        id="startDate"
456
                                        label="Valid From"
457 458 459 460 461 462
                                        format="dd MMMM yyyy"
                                        value={this.state.startDate}
                                        onChange={(e) => this.handleChange(e, 'start_date')}
                                        KeyboardButtonProps={{
                                            'aria-label': 'change date',
                                        }}
463 464 465 466 467
                                        inputProps={{
                                            style: {
                                                fontSize: 11
                                            }
                                        }}
468 469 470 471 472 473
                                        InputLabelProps={{
                                            style: {
                                                fontSize: 11,
                                                color: '#7e8085'
                                            }
                                        }}
474 475
                                        error={this.state.errorStartDate}
                                        helperText={this.state.msgErrorStartDate}
476
                                        style={{padding: 0, margin: 0, width: '100%'}}
477
                                    />
478 479 480
                                </div>
                            </div>
                            <div className="column-2">
481 482 483 484
                                <div className="margin-top-10px" style={{ padding: 10, borderRadius: 5 }}>
                                    <DatePicker
                                        margin="normal"
                                        id="endDate"
485
                                        label="Valid To"
486
                                        format="dd MMMM yyyy"
487 488 489
                                        error={this.state.errorEndDate}
                                        helperText={this.state.msgErrorEndDate}
                                        minDate={this.state.startDate}
490 491 492 493 494
                                        value={this.state.endDate}
                                        onChange={(e) => this.handleChange(e, 'end_date')}
                                        KeyboardButtonProps={{
                                            'aria-label': 'change date',
                                        }}
495 496 497 498 499
                                        inputProps={{
                                            style: {
                                                fontSize: 11
                                            }
                                        }}
500 501 502 503 504 505
                                        InputLabelProps={{
                                            style: {
                                                fontSize: 11,
                                                color: '#7e8085'
                                            }
                                        }}
506 507
                                        style={{padding: 0, margin: 0, width: '100%'}}
                                        />
508 509 510 511 512
                                </div>
                            </div>
                        </div>
                        <div className="grid grid-2x grid-mobile-none gap-15px">
                            <div className="column-1">
513
                                <div className="margin-top-10px" style={{ backgroundColor: '#e8e8e8', padding: 10, borderRadius: 5 }}>
514 515
                                    <TextField
                                        style={{ width: '100%' }}
516
                                        value={this.state.status}
517
                                        id="status"
518 519 520 521 522 523 524 525 526 527 528 529 530
                                        label="Status"
                                        disabled
                                        inputProps={{
                                            style: {
                                                fontSize: 11
                                            }
                                        }}
                                        InputLabelProps={{
                                            style: {
                                                fontSize: 11,
                                                color: '#7e8085'
                                            }
                                        }}
531 532 533 534 535
                                    >
                                    </TextField>
                                </div>
                            </div>
                            <div className="column-2">
536
                                {/* <div className="margin-top-10px" style={{ padding: 10, borderRadius: 5 }}>
537 538 539 540 541
                                    <TextField
                                        style={{ width: '100%' }}
                                        id="max-value"
                                        label="Max Value"
                                        value="10"
542 543 544 545 546 547 548 549 550 551 552 553
                                        onChange={(e) => this.handleChange(e, '')}
                                        inputProps={{
                                            style: {
                                                fontSize: 11
                                            }
                                        }}
                                        InputLabelProps={{
                                            style: {
                                                fontSize: 11,
                                                color: '#7e8085'
                                            }
                                        }}
554 555
                                    >
                                    </TextField>
556
                                </div> */}
557 558
                            </div>
                        </div>
a.bairuha's avatar
a.bairuha committed
559
                        <div className="margin-top-10px" style={{ paddingTop: 10, paddingBottom: 10, paddingLeft: 10, paddingRight: 20 }}>
560
                            <div style={{ display: 'flex' }}>
a.bairuha's avatar
a.bairuha committed
561
                                <Typography style={{ fontSize: 11, width: '12%' }}>Created By</Typography>
562
                                <Typography style={{ fontSize: 11 }}>: {this.state.created}</Typography>
563 564
                            </div>
                            <div style={{ display: 'flex' }}>
a.bairuha's avatar
a.bairuha committed
565
                                <Typography style={{ fontSize: 11, width: '12%' }}>Updated By</Typography>
566
                                <Typography style={{ fontSize: 11 }}>: {this.state.updated == - null ? "" : this.state.updated}</Typography>
567
                            </div>
568 569 570 571 572
                        </div>
                    </div>
                    <div className="border-top grid grid-2x" style={{ height: 56, backgroundColor: '#f5f5f5', paddingLeft: 20, paddingRight: 20 }}>
                        <div className="column-1" style={{ alignSelf: 'center' }}>
                            <div onClick={() => this.props.onClickClose()} style={{ width: 102, height: 30, border: 'solid 1px #354960', borderRadius: 5, alignItems: 'center', display: 'flex', justifyContent: 'center', cursor:"pointer" }}>
573
                                <span style={{ color: '#354960', fontSize: 11 }} >Cancel</span>
574 575 576
                            </div>
                        </div>
                        <div className="column-2" style={{display: 'flex', justifyContent: 'flex-end', alignItems: 'center'}}>
577
                            <div onClick={() => this.validasi()} style={{ width: 102, height: 30, backgroundColor: '#354960', borderRadius: 5, alignItems: 'center', display: 'flex', justifyContent: 'center', cursor:"pointer" }}>
578
                                <span style={{ color: '#fff', fontSize: 11 }}>Save</span>
579 580 581 582 583 584 585 586
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        );
    }
}