LWC trailhead 中エラー

f:id:kyuhee:20190319212742p:plain

trailhead.salesforce.com

VScodeでこんなエラーが。

A required metadata folder named "lwc" does not exist in this workspace.

下のサイトを参考に。。
salesforce.stackexchange.com

sfdx plugins:install salesforcedx@pre-release
これで新しくpre-release版のプラグインをインストールしたら解決。

#追記
解決できそうに見えたが、なんとなくバグる
f:id:kyuhee:20190319222231p:plain
デプロイができない。

sfdx plugins:install salesforcedx

これでプラグインを新しくインストールして、新しくプロジェクトも作って解決。

#追記
日本語で設定してたのでdefault Home pageで表示されないので、パスができない。。。
Home Page Default
頭は大文字だった。。。

リードの割り当てルール

f:id:kyuhee:20190317173429p:plain

リードの割り当て

[有効な割り当てルールによりリードを割り当てる]を選択すること!!

リード割り当てルールを使用して自動的にリードが割り当てられるようにするには、[有効な割り当てルールによりリードを割り当てる] を選択します。

 

f:id:kyuhee:20190317173615p:plain

複数の値設定

複数の値設定はコンマ区切りで!!

 

会社に、リードと商談の標準命名規則がまだない場合は、ぜひ今すぐ取り入れましょう。命名規則があれば、ユーザがより簡単に案件を見つけたり、リスト上の各案件の内容を理解できるようになるため、全員の作業がより効率的になります。商談の命名規則には、商品名、新規ビジネス、アドオン、量を使用した標準的な方法などがあります。Salesforce では、商談名に自動的に取引先名が追加されます。

 

trailhead.salesforce.com

 

 

取引先

取引先責任者-to-複数取引先 

設定が必要。

 ・取引先設定で許可

 ・ページレイアウトで関連リストを配置(取引先、取引先責任者)

help.salesforce.com

 

階層

取引先責任者の「Reports to」のように

「Parent Account」に入力

 

取引先チーム

-取引先の従業員チームには、営業担当、営業マネージャ、サポートエージェント、サポートマネージャ、マーケティング担当者などがいる場合

 

設定が必要。

・取引先チーム有効化

 

デフォルトの取引先チームの設定はユーザから登録。

Troubleshoot a formula and fix a couple of errors.
The following formula, meant to return the last day of the current month, has a couple of errors in it:

IF( MONTH( NOW() ) = 12,
DATE( YEAR( NOW() ), 12, 31 ),
DATE( YEAR( NOW() ), MONTH( NOW() ) + 1, 1) - 1

Create a new formula with the same label, name, and data type that successfully compiles.
The formula should be of Date type and on the Case object
The formula should have the name Last Day of Month and the resulting API name Last_Day_of_Month__c
The formula should return the last day of the current month

SOLUTION
DATE( YEAR( ADDMONTHS(Today(),1) ),
MONTH( ADDMONTHS(Today(),1) ),
01 ) - 1


<今月の最終日の計算方法>

❶ 翌月の1日の日付を計算(ADDMONTHSを使って)
  Get next month's first using ADDMONTHS
DATE( YEAR( ADDMONTHS(Today(),1) ),
MONTH( ADDMONTHS(Today(),1) ),
01 )

❷ ❶から1日を引く
  Substract a day from ❶(next month's first).
DATE( YEAR( ADDMONTHS(Today(),1) ),
MONTH( ADDMONTHS(Today(),1) ),
01 ) - 1

Create a formula that shows where an Opportunity is in the pipeline.
Create a formula field that classifies an Opportunity as either “Early”, “Middle”, or “Late”. This formula field should use TODAY() to calculate what percentage of the time between an opportunity’s CreatedDate and CloseDate has passed, and label the opportunity accordingly.
This formula should be on the Opportunity object
This formula should be named 'Opportunity Progress' with the resulting API name Opportunity_Progress__c
This formula should return 'Early' if less than or equal to 25% of an opportunity has passed
This formula should return 'Middle' if between 25% and 75% of an opportunity has passed
This formula should return 'Late' if more than 75% of an opportunity has passed
This formula should reference a helper formula field, also on the Opportunity Object, with the type Percent and the name Percent Completed
Percent Completed should return the percentage of the time that has passed between an opportunity’s CreatedDate and CloseDate


Percent Completed > Formula (Percent)
(TODAY() - DATEVALUE(CreatedDate))
/(CloseDate - DATEVALUE(CreatedDate))

※DATEVALUE()
You need to use DATEVALUE because CreatedDate is a Date/Time field.

Opportunity Progress > Formula (Text)
IF(Percent_Completed__c=<25,
 "Early",
 IF(Percent_Completed__c=<75,
  "Middle",
  "Late"))

※Not 0.25

高度な数式

❶書き出す
システム管理者以外の誰かが商談の [フェーズ] を「不成立」に変更し、かつ [Loss Reason (不成立の理由)] が空白の場合は、エラーを表示する。

❷キーワード抽出
「and (かつ/および)」「or (または)」「if (もし/場合)」

tip⑴ 整然
インデントや改行を使ってみやすく

tip⑵ 簡潔にすることに心がける
別の角度から問題に取り組んでみる