Skip to main content

Notifications

Announcements

No record found.

Small and medium business | Business Central, N...
Suggested answer

Job Planning Lines

Posted on by 2
Hi all,
 
I've setup custom page for Job Planning Lines, and I'm able to GET all Job Planning Lines using the Business Central API.
I'm also able to create new Job Planning Lines for a specific job, however the moment I try to add a locationCode I get the following error.
 
/You must specify Resource No. in planning line./
 
Does anyone know how to resolve this error?
  • Job Planning Lines
    I've done the following.
     
    If I POST the following body everything works:
    {
        "jobNo": "JOB001",
        "jobTaskNo": "1",
        "lineType": "Budget",
        "quantityBase": 10,
        "lineNo": 1000,
        "no": "PRODNO001",
        "type": "Item"
    }
    
    However, I would like to add the locationCode as well, so I tried the following
    {
        "jobNo": "JOB001",
        "jobTaskNo": "1",
        "lineType": "Budget",
        "quantityBase": 10,
        "lineNo": 1000,
        "no": "PRODNO001",
        "type": "Item",
        "locationCode": "SL001"
    }
    
    I get the following error: You must specify Item No. in planning line
      
    If I change quantityBase to quantity is get the following error: You must specify Resource No. in planning line
  • Suggested answer
    KasparsSemjonovs Profile Picture
    KasparsSemjonovs 3,926 Super User 2024 Season 2 on at
    Job Planning Lines
    Have You tried providing the Resource No? 
    Or change the Line Type to Text - then the No. field can be blank. 
    Or if You need items, then set the type = Item, and provide the No. field value - the Item number.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,269 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,198 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans