import ViewObject from "../../main/ViewObject";
import FqPay from "../../pay/FqPay";
import PayShopItem from "./PayShopItem";

/**
 * 充值商店
 */
const {ccclass, property} = cc._decorator;

@ccclass
export default class PayShopView extends ViewObject {

    @property(cc.Node)
    mContent: cc.Node = null;

    @property(cc.Prefab)
    mPayItem: cc.Prefab = null;


    public init(){
        // let gaveData = this.main.player.firstPayGave;
        // // let gaveData = [1001,1002,1003];
        // let _payDatas = this.main.sManage.payDatas
        // for (let i = 0; i < _payDatas.length; i++) {
        //     const element = _payDatas[i];
            
        //     let node = cc.instantiate(this.mPayItem)
        //     node.parent = this.mContent
        //     let payItem = node.getComponent(PayShopItem)
        //     payItem.init(element, gaveData)
        //     payItem.setCallback((item:PayShopItem)=>{
        //         let fqPay:FqPay = new FqPay(this.main)
        //         fqPay.pay(item._payData,()=>{

        //         })
        //     })
        // }
    }


}
