ee.data.createAssetHome
จัดทุกอย่างให้เป็นระเบียบอยู่เสมอด้วยคอลเล็กชัน
บันทึกและจัดหมวดหมู่เนื้อหาตามค่ากำหนดของคุณ
พยายามสร้างโฟลเดอร์รูทหน้าแรก (เช่น "users/joe") สำหรับผู้ใช้ปัจจุบัน ซึ่งจะทำให้เกิดข้อผิดพลาดหากผู้ใช้มีโฟลเดอร์รูทหน้าแรกอยู่แล้วหรือรหัสที่ขอไม่พร้อมใช้งาน
การใช้งาน | การคืนสินค้า |
---|
ee.data.createAssetHome(requestedId, callback) | |
อาร์กิวเมนต์ | ประเภท | รายละเอียด |
---|
requestedId | สตริง | รหัสที่ขอของโฟลเดอร์หลัก
(เช่น "users/joe") |
callback | ฟังก์ชัน (ไม่บังคับ) | การเรียกกลับที่ไม่บังคับ หากไม่ได้ระบุไว้ ระบบจะโทรแบบพร้อมกัน |
เนื้อหาของหน้าเว็บนี้ได้รับอนุญาตภายใต้ใบอนุญาตที่ต้องระบุที่มาของครีเอทีฟคอมมอนส์ 4.0 และตัวอย่างโค้ดได้รับอนุญาตภายใต้ใบอนุญาต Apache 2.0 เว้นแต่จะระบุไว้เป็นอย่างอื่น โปรดดูรายละเอียดที่นโยบายเว็บไซต์ Google Developers Java เป็นเครื่องหมายการค้าจดทะเบียนของ Oracle และ/หรือบริษัทในเครือ
อัปเดตล่าสุด 2025-07-26 UTC
[null,null,["อัปเดตล่าสุด 2025-07-26 UTC"],[[["\u003cp\u003eCreates a home root folder (like "users/joe") for the current user if one doesn't already exist.\u003c/p\u003e\n"],["\u003cp\u003eReturns an error if a home folder for the user already exists or the requested ID is taken.\u003c/p\u003e\n"],["\u003cp\u003eUtilizes the \u003ccode\u003eee.data.createAssetHome()\u003c/code\u003e function, accepting a requested ID and an optional callback.\u003c/p\u003e\n"],["\u003cp\u003eWhen a callback is not provided, the function execution becomes synchronous.\u003c/p\u003e\n"]]],[],null,["# ee.data.createAssetHome\n\n\u003cbr /\u003e\n\nAttempts to create a home root folder (e.g. \"users/joe\") for the current user. This results in an error if the user already has a home root folder or the requested ID is unavailable.\n\n\u003cbr /\u003e\n\n| Usage | Returns |\n|------------------------------------------------------|---------|\n| `ee.data.createAssetHome(requestedId, `*callback*`)` | |\n\n| Argument | Type | Details |\n|---------------|--------------------|------------------------------------------------------------------------|\n| `requestedId` | String | The requested ID of the home folder (e.g. \"users/joe\"). |\n| `callback` | Function, optional | An optional callback. If not supplied, the call is made synchronously. |"]]