#!/usr/bin/env python3
# -*- coding: utf-8 -*-

from fastapi import APIRouter, Request, Depends
from database import get_db
from sqlalchemy.orm import Session
from utils.DataQueryTemplate import get_idx_01

router = APIRouter()


@router.get('/resourceOverview')
async def mine(request: Request,db: Session = Depends(get_db)):
    opr_idx_li=['idx001','idx002','idx003','idx004','idx005','idx006','idx007','idx008','idx009','idx010','idx011','idx012','idx013','idx014','idx015','idx016']
    result = {}
    for opr_idx in opr_idx_li:
        result[opr_idx]=get_idx_01(opr_idx,'440900000',db)
    return {
        'errmsg': '查询成功',
        'errcode': 200,
        "data":result
    }
