با مجموعهها، منظم بمانید
ذخیره و طبقهبندی محتوا براساس اولویتهای شما.
برچسبها، فیلدها و انتخابها در طول زندگی خود حالتهای خاصی را طی میکنند. علاوه بر این، برچسبها ممکن است بازبینیهای متفاوتی داشته باشند. نمودار زیر چرخه عمر برچسب، از جمله تجدید نظر را نشان می دهد:
شکل 3. چرخه حیات یک برچسب
ایجاد یک برچسب ( create() ) - برچسب ایجاد و در یک پایگاه داده به عنوان revision_id=1 ذخیره می شود. برچسب دارای وضعیت UNPUBLISHED_DRAFT است. در این حالت:
کاربران نمی توانند برچسب را ببینند
کاربران نمیتوانند این برچسب را روی موارد Drive اعمال کنند.
(اختیاری) بهروزرسانی یک برچسب، فیلد یا انتخاب ( delta() ) - هر بهروزرسانی، حتی قبل از انتشار، در یک پایگاه داده ذخیره میشود و بازبینی برچسب افزایش مییابد.
انتشار یک برچسب ( publish() ) — برچسب حالت PUBLISHED را دارد و کاربران می توانند برچسب را اعمال کنند. انتشار برچسب، بازبینی آن را افزایش می دهد.
(اختیاری) بهروزرسانی یک برچسب، فیلد یا انتخاب ( delta() ) - برچسب، فیلد یا انتخاب بهروزرسانی میشود و در یک پایگاه داده به عنوان یک برچسب پیشنویس ذخیره میشود. برچسب دارای وضعیت PUBLISHED با hasUnpublishedChanges=true است به این معنی که تغییرات پیش نویس وجود دارد، اما برای کاربران در دسترس نیستند. هر بهروزرسانی بازبینی برچسب را افزایش میدهد.
(اختیاری) انتشار یک برچسب ( publish() ) — در صورت موجود بودن، پیش نویس فعلی منتشر می شود. برچسب دارای وضعیت PUBLISHED است و کاربران می توانند برچسب را اعمال کنند. انتشار برچسب نسخه آن را افزایش می دهد.
غیرفعال کردن یک برچسب ( disable() ) - این برچسب دارای وضعیت DISABLED است، اگرچه کاربران می توانند برچسب را از طریق API اعمال کنند. با این حال، یک برچسب غیرفعال در رابط کاربری نشان داده نمیشود مگر اینکه برای نمایش پیکربندی شده باشد. منسوخ شدن برچسب، بازبینی آن را افزایش می دهد.
فعال کردن یک برچسب ( enable() ) - برچسب به حالت PUBLISHED برمیگردد و کاربران میتوانند برچسب را اعمال کنند. انتشار برچسب، بازبینی آن را افزایش می دهد.
حذف یک برچسب ( delete() ) - برچسب حالت DELETED دارد و قابل اعمال نیست. برچسب های حذف شده در نهایت پاک می شوند.
مهم است که تأکید کنیم که هر بهروزرسانی برای یک برچسب، بازبینی برچسب را افزایش میدهد. و اگر برچسب قبلاً منتشر شده باشد، انتشار مجدد آن پس از n بهروزرسانی به این معنی است که شماره ویرایش منتشر شده آن revision + n + 1 تعداد بهروزرسانیهای متوالی است.
تاریخ آخرین بهروزرسانی 2025-08-29 بهوقت ساعت هماهنگ جهانی.
[null,null,["تاریخ آخرین بهروزرسانی 2025-08-29 بهوقت ساعت هماهنگ جهانی."],[],[],null,["# Label lifecycle\n\nLabels, fields, and choices go through specific states throughout their lives.\nAdditionally, labels might have different revisions. The following diagram shows\nthe label lifecycle, including revisioning:\n**Figure 3.** Lifecycle of a label\n\n1. **Create a label (`create()`)** ---The label is created and stored in a database as `revision_id=1`. The label has the state of `UNPUBLISHED_DRAFT`. In this state:\n - Users can't view the label\n - Users can't apply the label to Drive items.\n2. **(optional) Update a label, field, or choice (`delta()`)**--- Every update, even before it's published, is stored in a database, and the label's revision is incremented.\n3. **Publish a label (`publish()`)** ---The label has the state of `PUBLISHED` and users can apply the label. Publishing the label increments its revision.\n4. **(optional) Update a label, field, or choice (`delta()`)** --- The label, field, or choice is updated and stored in a database as a draft label. The label has the state of `PUBLISHED` with `hasUnpublishedChanges=true` meaning there are draft changes, but they aren't available to users. Each update increments the label's revision.\n5. **(optional) Publish a label (`publish()`)** ---If available, the most-current draft is published. The label has the state of `PUBLISHED` and users can apply the label. Publishing the label increments its version.\n6. **Disable a label (`disable()`)** ---The label has the state of `DISABLED` though users can apply the label through the API. However, a disabled label isn't shown in a UI unless configured to be shown. Deprecating the label increments its revision.\n7. **Enable a label (`enable()`)** ---The label is returned to a `PUBLISHED` state and users can apply the label. Publishing the label increments its revision.\n8. **Delete a label (`delete()`)** ---The label has a state of `DELETED` and can't be applied. Deleted labels are eventually purged.\n\nIt's important to emphasize that every update to a label increments the label's\nrevision. And, if the label has already been published, publishing it again\nafter *n* updates means that its published revision number is revision + *n* + 1\nnumber of successive updates."]]