ディスカッション
NetSuiteの保存検索やレポートをマスターするための究極のガイドである分析センターを使用して、データの力を最大限に活用しましょう。複雑さを単純化し、組織の真の可能性を解き放ちます。今すぐ分析センターに参加して、新たな高みを目指しましょう!
New AI Community Guidelines. Please review and follow them to ensure AI use stays safe, accurate, and compliant.
NetSuite の始め方| N/record: Column.isDisplayプロパティ
前の記事NetSuiteの始め方 | SuiteScript 2.x Modulesで、レコードの操作に使用されるSuiteScriptモジュールおよびN/recordモジュールNetSuiteの始め方 | N/record Module 概要を学習しました。次に、N/record: Column.isDisplay Propertyのメンバーの1つを詳しく確認します。
Column.isDisplayプロパティは、アクティブなレコード・フォーム・コンテキストに特定のサブリスト列が現在表示されているかどうかを示す読取り専用ブール・プロパティです。
プロパティ詳細
- タイプ: ブール(true/false)。
- 読取り専用: この値は設定できません。これは、レコード/ページ・コンテキストに基づいてNetSuiteによって決定されます。
- アクセス可能: クライアントおよびサーバー・スクリプト
使用例
次に、レコードの作成時に「アイテム」サブリストの「金額」列が表示されるかどうかを確認する簡単な例を示します。
/**
* @NApiVersion 2.x
* @NScriptType UserEventScript
*/
define(['N/record', 'N/log'], function(record, log) {
function beforeLoad(context) {
if (context.type === context.UserEventType.CREATE) {
var newRecord = context.newRecord;
try {
// 例: 'item'サブリストの'amount'列を確認
var itemSublist = newRecord.getSublist({ sublistId: 'item' });
var amountColumn = itemSublist.getColumn({ fieldId: 'amount' });
// 列を表示する場合にログを記録
if (amountColumn && amountColumn.isDisplay) {
log.debug({
title: 'Amount Column Enabled',
details: 'The "amount" column on the item sublist is displayed.'
});
} else {
log.debug({
title: 'Amount Column Disabled',
details: 'The "amount" column on the item sublist is not displayed.' Richard James Uri - SuiteCloud | WMS Tech | SuiteCommerce Advanced
----
- NetSuite Admin Corner | New to NetSuite
- Explore the NSC Webinars Category
- Join our poll and share your ideas! We want to know what you think. Don't forget to comment and make your voice heard!
- Expand your NetSuite knowledge by joining this month's Ask A Guru Live about Suitebuilder . RSVP on this event now!
タグ付けされた:
0
