JmgTermJob Class [AX 2012]
The JmgTermJob class represents a job in the Shop Floor Control.
Syntax
class JmgTermJob
Run On
Called
Methods
Method | Description | |
---|---|---|
actOprId | This method retrieves the operation or activity ID associated with the job. | |
allow | Determines whether employees can register on the job. | |
cancelTimeOut | Cancels a previous method call to the setTimeOut method. (Inherited from Object.) | |
equal | Determines whether the specified object is equal to the current one. (Inherited from Object.) | |
estimatedHours | Retrieves the estimated job time. | |
function | Retrieves the function that is associated with the job. | |
getTimeOutTimerHandle | Returns the timer handle for the object. (Inherited from Object.) | |
handle | Retrieves the handle of the class of the object. (Inherited from Object.) | |
init | Part of the initialization procedure of an instance. The method is called by the JmgTermJob::construct Method and JmgTermJob::constructJobTable Method. | |
initCommon | This method initializes the common fields in a JmgTermReg record, which is created when a registration is made. | |
initSourceData | Loads the source data, upon which the job is based, into memory. | |
isValidJobId | This method returns whether an instance of the JmgTermJob Class is based on a valid job ID. | |
jmgJobTable | Retrieves the JmgJobTable record, which is associated to the job. | |
jobDescription | This method returns a description of the job. | |
jobId | This method returns the job ID which identifies this job. | |
jobRef | Returns the job reference of the job. | |
jobStatus | Retrieves the status of a job. | |
jourRegType | Returns the journal registration type to which this kind of job corresponds. | |
makeFeedback | This method is used to provide feedback on a started job. | |
makeRegistration | This method creates a start or a stop job registration on this job. | |
module | This method returns the module from where the job originates. | |
new | Initializes a new instance of the JmgTermJob class. | |
notify | Releases the hold on an object that has called the wait method on this object. (Inherited from Object.) | |
notifyAll | Releases a lock on the object that was issued by the wait method on this object. (Inherited from Object.) | |
objectOnServer | Determines whether the object is on a server. (Inherited from Object.) | |
owner | Returns the instance that owns the object. (Inherited from Object.) | |
pmfCanHaveCoProducts | Indicates whether the job can have co-product outputs. | |
pmfIsBatchOrderJob | Indicates whether the term job belongs to the batch order. | |
registrationError | This method is invoked if an error occurs when a registration on the job is created. It throws an error that has the specified error message. If special handling of registration errors is necessary for a specific type of job, this method should be overridden. | |
reportedFinish | This method returns whether the job is reported as finished in Shop Floor Control. | |
reportedStarted | This method returns whether the job has been reported as started. | |
requireFeedbackInfo | This method returns whether any additional feedback is needed. A set of feedback parameters is supplied to the method and based on these parameters it is determined whether additional feedback is required to make a stop registration on the job. | |
requireStartupInfo | This method returns whether any additional startup information is needed. A set of startup parameters is supplied to the method and based on these parameters it is determined whether additional feedback is required to make a start registration on the job. | |
setTimeOut | Sets up the scheduled execution of a specified method. (Inherited from Object.) | |
signType | This method returns the type of registration associated with this job. | |
sourceData | This method provides access to the source data record from which the job originates. | |
stampType | Returns the stamp type associated with this job. | |
toString | Returns a string that represents the current object. (Inherited from Object.) | |
usageCount | Returns the current number of references, that is, the value of the reference counter, that the object has. (Inherited from Object.) | |
validateStampJournalTransWrite | Validates a JmgStampJournalTrans record. | |
wait | Pauses a process. (Inherited from Object.) | |
xml | Returns an XML string that represents the current object. (Inherited from Object.) | |
::commonJob | This static method is used to retrieve the source data record from which the supplied job ID originates. | |
::construct | This method creates a new instance of the JmgTermJob subclasses. Based on the specified job ID, an instance of the appropriate subclasses is returned. | |
::constructJobTable | This method constructs a new instance of the JmgTermJob class based on a JmgJobTable record. Based on the jobId field of the JmgJobTable table, an instance of the appropriate subclass is returned. |
Top
Remarks
A Shop Floor Control handles different types of jobs: absence jobs, indirect production jobs, and project jobs. This class provides a uniform way to retrieve information about jobs and create employee registrations on jobs.The JmgTermJob class is an abstract class. Each of the subclasses that are mentioned in the See Also section represent a type of job. Any instance of the JmgTermJob subclasses should be created by using either the JmgTermJob::construct or JmgTermJob::constructJobTable static methods. If the supplied job ID or JmgJobTable record represents an invalid job, such as when the job ID is not valid, no error is thrown. Instead, an instance of the JmgTermJob_illegal class is returned.
Examples
The following examples show how to do the do the following tow tasks:
Print the job description associated to job ID ‘10000007’ in an Infolog.
Create a start job registration on job ID '10000007' for employee 'EBA'.
//Example 1
JmgTermJob jmgTermJob;
;
jmgTermJob = JmgTermJob::construct('10000007');
info(jmgTermJob.jobDescription());
//Example 2
JmgTermJob jmgTermJob;
;
jmgTermJob = JmgTermJob::construct('10000007');
jmgTermJob.makeRegistration(jmgWorkerRecId, today(), timeNow());
Inheritance Hierarchy
Object Class
JmgTermJob Class
JmgTermJob_HRMAbsence Class
JmgTermJob_illegal Class
JmgTermJob_IPC Class
JmgTermJob_Prod Class
JmgTermJob_Proj Class