def adminEditArea():
    try:
        areaVO = AreaVO()

        areaDAO = AreaDAO()

        areaId = request.args.get('areaId')

        areaVO.areaId = areaId

        areaVOList = areaDAO.editArea(areaVO)

        print("=======areaVOList=======", areaVOList)

        print("=======type of areaVOList=======", type(areaVOList))

        return render_template('admin/editArea.html', areaVOList=areaVOList)
    except Exception as ex:
        print(ex)
Ejemplo n.º 2
0
def adminEditArea():
    try:
        if adminLoginSession() == 'admin':
            areaVO = AreaVO()

            areaDAO = AreaDAO()

            areaId = request.args.get('areaId')

            areaVO.areaId = areaId

            areaVOList = areaDAO.editArea(areaVO)

            return render_template('admin/editArea.html',
                                   areaVOList=areaVOList)
        else:
            adminLogoutSession()

    except Exception as ex:
        print(ex)
Ejemplo n.º 3
0
def adminEditArea():
    try:
        if adminLoginSession() == "admin":
            areaVO = AreaVO()

            areaDAO = AreaDAO()

            cityDAO = CityDAO()

            areaId = request.args.get('areaId')

            areaVO.areaId = areaId

            areaVOList = areaDAO.editArea(areaVO)

            cityVOList = cityDAO.viewCity()

            return render_template('admin/editArea.html',
                                   cityVOList=cityVOList,
                                   areaVOList=areaVOList)
        else:
            return adminLogoutSession()
    except Exception as ex:
        print(ex)