pageContent method

Widget pageContent()

Implementation

Widget pageContent() {
  return LayoutBuilder(builder: (context, _) {
    final isPhone = Get.width <= 960;
    return Container(
      padding: EdgeInsets.symmetric(horizontal: isPhone ? 20.dp : 32.dp),
      child: Column(
        crossAxisAlignment: CrossAxisAlignment.start,
        children: [
          if (isPhone) 20.dp.SpaceX,
          Container(
              padding:
                  const EdgeInsets.symmetric(horizontal: 32, vertical: 30),
              width: double.infinity,
              decoration: BoxDecoration(
                color: Colors.white,
                borderRadius: BorderRadius.circular(16),
                boxShadow: [
                  BoxShadow(
                    color: ColorHelper.primaryBlue.withOpacity(.1),
                    blurRadius: 4.0,
                    offset: const Offset(0, 2),
                  ),
                ],
                border: Border.all(
                  color: ColorHelper.grey01,
                  width: 1.0, // Border width
                ),
              ),
              child: Wrap(
                children: [
                  _buildStatColumn(
                    title: "Total Profit",
                    value: "\$276,219",
                  ),
                  myDivider(),
                  _buildStatColumn(
                    title: "Total Base Price For Sold Tickets",
                    value: "\$152,432",
                  ),
                  myDivider(),
                  _buildStatColumn(
                    title: "Sale Price",
                    value: "\$152,432",
                  ),
                  myDivider(),
                  _buildDiscountColumn(
                    title: "Online Price",
                    value: "\$49,725",
                  ),
                ],
              )),
          30.dp.SpaceX,
          Text(
            "Ticket Sales and Profit Analysis",
            style: TextStyle(
              fontSize: 18.dp,
              fontWeight: FontWeight.w600,
              color: ColorHelper.black02,
            ),
          ),
          16.SpaceX,
          Obx(() {
            return !controller.isBookingLoading.value? controller.bookingList.isEmpty
                ? Container(
                    alignment: Alignment.center,
                    margin: EdgeInsets.symmetric(vertical: 150.dp),
                    child: Column(
                      children: [
                        Image.asset(
                          'assets/requests/empty_list.png',
                          width: 200.dp,
                          height: 200.dp,
                        ),
                        28.dp.SpaceX,
                        Text(
                          "No Data Available",
                          style: TextStyle(
                            fontSize: 24.dp,
                            fontWeight: FontWeight.w600,
                            color: ColorHelper.neutralText,
                          ),
                        ),
                        8.dp.SpaceX,
                        SizedBox(
                          width: 300.dp,
                          child: Text(
                            "It looks like there’s nothing here yet. Requests should be made by users to reflect data here.",
                            textAlign: TextAlign.center,
                            style: TextStyle(
                              fontSize: 12.dp,
                              fontWeight: FontWeight.w400,
                              color: ColorHelper.neutralText02,
                            ),
                          ),
                        ),
                      ],
                    ),
                  )
                // : _table();
                : _requestsTable(): const SizedBox();
          }),
          50.SpaceX,
        ],
      ),
    );
  });
}