Difference between revisions of "C Job Costing"

From Sage Evolution SDK | Documentation Portal
Jump to: navigation, search
(Created page with "Job Cards can be created as active or as a quote and saved but cannot be processed or completed using the SDK. //Create a new instance of the JobCard Class JobCard card = new...")
(No difference)

Revision as of 15:57, 22 October 2015

Job Cards can be created as active or as a quote and saved but cannot be processed or completed using the SDK.

//Create a new instance of the JobCard Class JobCard card = new JobCard();//An existing job can be specified card.Account = new Customer("Cash"); card.Description = "SDK Job Card "; //Make the Job Active card.Status = JobCard.JobStatus.Active;

// Add an Active Inventory Line to the Job Card JobDetail det = new JobDetail(); det.TransactionCode = new JobTransactionCode(JobDetail.TransactionSource.Inventory, "ST"); det.Status = JobCard.JobStatus.Active; det.Account = new InventoryItem("ItemA"); det.Warehouse = new Warehouse("CPT"); det.Quantity = 3; card.Detail.Add(det);

// Add a Return Line to the Job Card det = new JobDetail(); det.TransactionCode = new JobTransactionCode(JobDetail.TransactionSource.Inventory, "ST"); det.Status = JobCard.JobStatus.Active; det.Account = new InventoryItem("ItemA"); det.Warehouse = new Warehouse("CPT"); det.Quantity = -2; card.Detail.Add(det);

//add a Supplier Line to the Job Card det = new JobDetail(); det.TransactionCode = new JobTransactionCode(JobDetail.TransactionSource.Payables, "SC"); det.Status = JobCard.JobStatus.Active; det.Account = new Supplier("Supplier1"); det.UnitCostPrice = 60; det.UnitSellingPrice = 200; card.Detail.Add(det);

//Add a financial Line to the Job Card det = new JobDetail(); det.TransactionCode = new JobTransactionCode(JobDetail.TransactionSource.Ledger, "FL"); det.Status = JobCard.JobStatus.Active; det.Account = new GLAccount("Accounting fees"); det.UnitCostPrice = 50; det.UnitSellingPrice = 200; card.Detail.Add(det); // Save the Job Card Job cards cannot be completed or processed card.Save(); - See more at: http://kb.pastel.co.za/article.php?id=1991#sthash.pgMVdFfd.dpuf