Commit 4d743eaf authored by liujiangnan's avatar liujiangnan

feat

parent b8369783
......@@ -88,7 +88,19 @@ export default class SceneComponent extends MyCocosSceneComponent_NJ_usercenter
if (products && products.length>0) {
const endDate = products[0].syll_end_date.split("T")[0].trim();
cc.find(`Canvas/usercenter/view/content/scollpage/user_center/enddate`).getComponent(cc.Label).string = `有效期至:${endDate}`;
const container = cc.find(`Canvas/usercenter/paylist_bg/container`);
container.removeAllChildren();
const item = cc.find(`Canvas/usercenter/paylist_bg/item`);
for (let i = 0; i < products.length; i++) {
const p = products[i];
if (p.type_ == 2) {
const endDay = p.syll_end_date.split("T")[0].trim();
const itemClone = cc.instantiate(item);
itemClone.parent = container;
itemClone.active = true;
cc.find(`level`, itemClone).getComponent(cc.Label).string = `${p.name} 有效期至 ${endDay}`;
}
}
}
}
......@@ -292,7 +304,13 @@ export default class SceneComponent extends MyCocosSceneComponent_NJ_usercenter
}
showBuyList() {
cc.find(`Canvas/usercenter/paylist_bg`).active = true;
}
hideBuyList() {
cc.find(`Canvas/usercenter/paylist_bg`).active = false;
}
initBg() {
const bgNode = cc.find('Canvas/bg');
......
{
"ver": "2.3.5",
"uuid": "2f9aaae1-00b9-43ed-9c07-4f344aa4bfc3",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 53,
"height": 57,
"platformSettings": {},
"subMetas": {
"close": {
"ver": "1.0.4",
"uuid": "f8e56362-47e3-4294-b344-0217c0a5d3f5",
"rawTextureUuid": "2f9aaae1-00b9-43ed-9c07-4f344aa4bfc3",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 53,
"height": 57,
"rawWidth": 53,
"rawHeight": 57,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"ver": "2.3.5",
"uuid": "58c36846-2ec7-4686-bcf7-8e65f8164394",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 394,
"height": 354,
"platformSettings": {},
"subMetas": {
"paylist_bg": {
"ver": "1.0.4",
"uuid": "ec84a91f-d85b-4cba-96a2-44072769ba69",
"rawTextureUuid": "58c36846-2ec7-4686-bcf7-8e65f8164394",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 4,
"trimY": 4,
"width": 386,
"height": 346,
"rawWidth": 394,
"rawHeight": 354,
"borderTop": 33,
"borderBottom": 47,
"borderLeft": 38,
"borderRight": 40,
"subMetas": {}
}
}
}
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment