/projects/compiere-330/ad/src/org/compiere/model/X_M_WorkOrder.java
Java | 1026 lines | 508 code | 207 blank | 311 comment | 45 complexity | c74977111f153f821261b00d16f155c7 MD5 | raw file
1/******************************************************************************
2 * Product: Compiere ERP & CRM Smart Business Solution *
3 * Copyright (C) 1999-2008 Compiere, Inc. All Rights Reserved. *
4 * This program is free software, you can redistribute it and/or modify it *
5 * under the terms version 2 of the GNU General Public License as published *
6 * by the Free Software Foundation. This program is distributed in the hope *
7 * that it will be useful, but WITHOUT ANY WARRANTY, without even the implied *
8 * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. *
9 * See the GNU General Public License for more details. *
10 * You should have received a copy of the GNU General Public License along *
11 * with this program, if not, write to the Free Software Foundation, Inc., *
12 * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. *
13 * For the text or an alternative of this public license, you may reach us at *
14 * Compiere, Inc., 3600 Bridge Parkway #102, Redwood City, CA 94065, USA *
15 * or via info@compiere.org or http://www.compiere.org/license.html *
16 *****************************************************************************/
17package org.compiere.model;
18
19/** Generated Model - DO NOT CHANGE */
20import java.sql.*;
21import org.compiere.framework.*;
22import org.compiere.util.*;
23/** Generated Model for M_WorkOrder
24 * @author Jorg Janke (generated)
25 * @version Release 3.2.2_Dev - $Id$ */
26public class X_M_WorkOrder extends PO
27{
28 /** Standard Constructor
29 @param ctx context
30 @param M_WorkOrder_ID id
31 @param trx transaction
32 */
33 public X_M_WorkOrder (Ctx ctx, int M_WorkOrder_ID, Trx trx)
34 {
35 super (ctx, M_WorkOrder_ID, trx);
36
37 /* The following are the mandatory fields for this object.
38
39 if (M_WorkOrder_ID == 0)
40 {
41 setC_DocType_ID (0);
42 setC_UOM_ID (0);
43 setDateAcct (new Timestamp(System.currentTimeMillis())); // @#Date@
44 setDocAction (null); // PR
45 setDocStatus (null); // DR
46 setDocumentNo (null);
47 setIsApproved (false); // @IsApproved@
48 setIsSOTrx (true); // Y
49 setM_BOM_ID (0);
50 setM_Locator_ID (0);
51 setM_Product_ID (0);
52 setM_Routing_ID (0); // 1
53 setM_Warehouse_ID (0); // @#M_Warehouse_ID@
54 setM_WorkOrderClass_ID (0);
55 setM_WorkOrder_ID (0);
56 setPosted (false); // N
57 setPriorityRule (null); // 5
58 setProcessed (false); // N
59 setQtyAssembled (Env.ZERO); // 0
60 setQtyAvailable (Env.ZERO); // 0
61 setQtyEntered (Env.ZERO); // 1
62 setSendEMail (false); // N
63 setWOType (null); // S
64
65 }
66 */
67
68 }
69 /** Load Constructor
70 @param ctx context
71 @param rs result set
72 @param trx transaction
73 */
74 public X_M_WorkOrder (Ctx ctx, ResultSet rs, Trx trx)
75 {
76 super (ctx, rs, trx);
77
78 }
79 /** Serial Version No */
80 private static final long serialVersionUID = 27498790429789L;
81 /** Last Updated Timestamp 2008-07-21 11:31:53.0 */
82 public static final long updatedMS = 1216665113000L;
83 /** AD_Table_ID=1026 */
84 public static final int Table_ID=1026;
85
86 /** TableName=M_WorkOrder */
87 public static final String Table_Name="M_WorkOrder";
88
89 protected static KeyNamePair Model = new KeyNamePair(Table_ID,"M_WorkOrder");
90
91 /**
92 * Get AD Table ID.
93 * @return AD_Table_ID
94 */
95 @Override public int get_Table_ID()
96 {
97 return Table_ID;
98
99 }
100
101 /** AD_OrgTrx_ID AD_Reference_ID=130 */
102 public static final int AD_ORGTRX_ID_AD_Reference_ID=130;
103 /** Set Trx Organization.
104 @param AD_OrgTrx_ID Performing or initiating organization */
105 public void setAD_OrgTrx_ID (int AD_OrgTrx_ID)
106 {
107 if (AD_OrgTrx_ID <= 0) set_Value ("AD_OrgTrx_ID", null);
108 else
109 set_Value ("AD_OrgTrx_ID", Integer.valueOf(AD_OrgTrx_ID));
110
111 }
112
113 /** Get Trx Organization.
114 @return Performing or initiating organization */
115 public int getAD_OrgTrx_ID()
116 {
117 return get_ValueAsInt("AD_OrgTrx_ID");
118
119 }
120
121 /** Set User/Contact.
122 @param AD_User_ID User within the system - Internal or Business Partner Contact */
123 public void setAD_User_ID (int AD_User_ID)
124 {
125 if (AD_User_ID <= 0) set_Value ("AD_User_ID", null);
126 else
127 set_Value ("AD_User_ID", Integer.valueOf(AD_User_ID));
128
129 }
130
131 /** Get User/Contact.
132 @return User within the system - Internal or Business Partner Contact */
133 public int getAD_User_ID()
134 {
135 return get_ValueAsInt("AD_User_ID");
136
137 }
138
139 /** Set Activity.
140 @param C_Activity_ID Business Activity */
141 public void setC_Activity_ID (int C_Activity_ID)
142 {
143 if (C_Activity_ID <= 0) set_Value ("C_Activity_ID", null);
144 else
145 set_Value ("C_Activity_ID", Integer.valueOf(C_Activity_ID));
146
147 }
148
149 /** Get Activity.
150 @return Business Activity */
151 public int getC_Activity_ID()
152 {
153 return get_ValueAsInt("C_Activity_ID");
154
155 }
156
157 /** Set Business Partner.
158 @param C_BPartner_ID Identifies a Business Partner */
159 public void setC_BPartner_ID (int C_BPartner_ID)
160 {
161 if (C_BPartner_ID <= 0) set_Value ("C_BPartner_ID", null);
162 else
163 set_Value ("C_BPartner_ID", Integer.valueOf(C_BPartner_ID));
164
165 }
166
167 /** Get Business Partner.
168 @return Identifies a Business Partner */
169 public int getC_BPartner_ID()
170 {
171 return get_ValueAsInt("C_BPartner_ID");
172
173 }
174
175 /** Set Partner Location.
176 @param C_BPartner_Location_ID Identifies the (ship to) address for this Business Partner */
177 public void setC_BPartner_Location_ID (int C_BPartner_Location_ID)
178 {
179 if (C_BPartner_Location_ID <= 0) set_Value ("C_BPartner_Location_ID", null);
180 else
181 set_Value ("C_BPartner_Location_ID", Integer.valueOf(C_BPartner_Location_ID));
182
183 }
184
185 /** Get Partner Location.
186 @return Identifies the (ship to) address for this Business Partner */
187 public int getC_BPartner_Location_ID()
188 {
189 return get_ValueAsInt("C_BPartner_Location_ID");
190
191 }
192
193 /** Set Campaign.
194 @param C_Campaign_ID Marketing Campaign */
195 public void setC_Campaign_ID (int C_Campaign_ID)
196 {
197 if (C_Campaign_ID <= 0) set_Value ("C_Campaign_ID", null);
198 else
199 set_Value ("C_Campaign_ID", Integer.valueOf(C_Campaign_ID));
200
201 }
202
203 /** Get Campaign.
204 @return Marketing Campaign */
205 public int getC_Campaign_ID()
206 {
207 return get_ValueAsInt("C_Campaign_ID");
208
209 }
210
211
212 /** C_DocType_ID AD_Reference_ID=170 */
213 public static final int C_DOCTYPE_ID_AD_Reference_ID=170;
214 /** Set Document Type.
215 @param C_DocType_ID Document type or rules */
216 public void setC_DocType_ID (int C_DocType_ID)
217 {
218 if (C_DocType_ID < 0) throw new IllegalArgumentException ("C_DocType_ID is mandatory.");
219 set_ValueNoCheck ("C_DocType_ID", Integer.valueOf(C_DocType_ID));
220
221 }
222
223 /** Get Document Type.
224 @return Document type or rules */
225 public int getC_DocType_ID()
226 {
227 return get_ValueAsInt("C_DocType_ID");
228
229 }
230
231 /** Set Order Line.
232 @param C_OrderLine_ID Order Line */
233 public void setC_OrderLine_ID (int C_OrderLine_ID)
234 {
235 if (C_OrderLine_ID <= 0) set_Value ("C_OrderLine_ID", null);
236 else
237 set_Value ("C_OrderLine_ID", Integer.valueOf(C_OrderLine_ID));
238
239 }
240
241 /** Get Order Line.
242 @return Order Line */
243 public int getC_OrderLine_ID()
244 {
245 return get_ValueAsInt("C_OrderLine_ID");
246
247 }
248
249 /** Set Order.
250 @param C_Order_ID Order */
251 public void setC_Order_ID (int C_Order_ID)
252 {
253 if (C_Order_ID <= 0) set_Value ("C_Order_ID", null);
254 else
255 set_Value ("C_Order_ID", Integer.valueOf(C_Order_ID));
256
257 }
258
259 /** Get Order.
260 @return Order */
261 public int getC_Order_ID()
262 {
263 return get_ValueAsInt("C_Order_ID");
264
265 }
266
267 /** Set Project.
268 @param C_Project_ID Financial Project */
269 public void setC_Project_ID (int C_Project_ID)
270 {
271 if (C_Project_ID <= 0) set_Value ("C_Project_ID", null);
272 else
273 set_Value ("C_Project_ID", Integer.valueOf(C_Project_ID));
274
275 }
276
277 /** Get Project.
278 @return Financial Project */
279 public int getC_Project_ID()
280 {
281 return get_ValueAsInt("C_Project_ID");
282
283 }
284
285 /** Set UOM.
286 @param C_UOM_ID Unit of Measure */
287 public void setC_UOM_ID (int C_UOM_ID)
288 {
289 if (C_UOM_ID < 1) throw new IllegalArgumentException ("C_UOM_ID is mandatory.");
290 set_Value ("C_UOM_ID", Integer.valueOf(C_UOM_ID));
291
292 }
293
294 /** Get UOM.
295 @return Unit of Measure */
296 public int getC_UOM_ID()
297 {
298 return get_ValueAsInt("C_UOM_ID");
299
300 }
301
302 /** Set Copy From.
303 @param CopyFrom Copy From Record */
304 public void setCopyFrom (String CopyFrom)
305 {
306 set_Value ("CopyFrom", CopyFrom);
307
308 }
309
310 /** Get Copy From.
311 @return Copy From Record */
312 public String getCopyFrom()
313 {
314 return (String)get_Value("CopyFrom");
315
316 }
317
318 /** Set Account Date.
319 @param DateAcct General Ledger Date */
320 public void setDateAcct (Timestamp DateAcct)
321 {
322 if (DateAcct == null) throw new IllegalArgumentException ("DateAcct is mandatory.");
323 set_Value ("DateAcct", DateAcct);
324
325 }
326
327 /** Get Account Date.
328 @return General Ledger Date */
329 public Timestamp getDateAcct()
330 {
331 return (Timestamp)get_Value("DateAcct");
332
333 }
334
335 /** Set Actual Date From.
336 @param DateActualFrom Actual date an activity started */
337 public void setDateActualFrom (Timestamp DateActualFrom)
338 {
339 set_Value ("DateActualFrom", DateActualFrom);
340
341 }
342
343 /** Get Actual Date From.
344 @return Actual date an activity started */
345 public Timestamp getDateActualFrom()
346 {
347 return (Timestamp)get_Value("DateActualFrom");
348
349 }
350
351 /** Set Actual Date To.
352 @param DateActualTo Actual date an activity ended */
353 public void setDateActualTo (Timestamp DateActualTo)
354 {
355 set_Value ("DateActualTo", DateActualTo);
356
357 }
358
359 /** Get Actual Date To.
360 @return Actual date an activity ended */
361 public Timestamp getDateActualTo()
362 {
363 return (Timestamp)get_Value("DateActualTo");
364
365 }
366
367 /** Set Scheduled Date From.
368 @param DateScheduleFrom Date an activity is scheduled to start */
369 public void setDateScheduleFrom (Timestamp DateScheduleFrom)
370 {
371 set_Value ("DateScheduleFrom", DateScheduleFrom);
372
373 }
374
375 /** Get Scheduled Date From.
376 @return Date an activity is scheduled to start */
377 public Timestamp getDateScheduleFrom()
378 {
379 return (Timestamp)get_Value("DateScheduleFrom");
380
381 }
382
383 /** Set Scheduled Date To.
384 @param DateScheduleTo Date an activity is scheduled to end */
385 public void setDateScheduleTo (Timestamp DateScheduleTo)
386 {
387 set_Value ("DateScheduleTo", DateScheduleTo);
388
389 }
390
391 /** Get Scheduled Date To.
392 @return Date an activity is scheduled to end */
393 public Timestamp getDateScheduleTo()
394 {
395 return (Timestamp)get_Value("DateScheduleTo");
396
397 }
398
399 /** Set Description.
400 @param Description Optional short description of the record */
401 public void setDescription (String Description)
402 {
403 set_Value ("Description", Description);
404
405 }
406
407 /** Get Description.
408 @return Optional short description of the record */
409 public String getDescription()
410 {
411 return (String)get_Value("Description");
412
413 }
414
415
416 /** DocAction AD_Reference_ID=135 */
417 public static final int DOCACTION_AD_Reference_ID=135;
418 /** <None> = -- */
419 public static final String DOCACTION_None = X_Ref__Document_Action.NONE.getValue();
420 /** Approve = AP */
421 public static final String DOCACTION_Approve = X_Ref__Document_Action.APPROVE.getValue();
422 /** Close = CL */
423 public static final String DOCACTION_Close = X_Ref__Document_Action.CLOSE.getValue();
424 /** Complete = CO */
425 public static final String DOCACTION_Complete = X_Ref__Document_Action.COMPLETE.getValue();
426 /** Invalidate = IN */
427 public static final String DOCACTION_Invalidate = X_Ref__Document_Action.INVALIDATE.getValue();
428 /** Post = PO */
429 public static final String DOCACTION_Post = X_Ref__Document_Action.POST.getValue();
430 /** Prepare = PR */
431 public static final String DOCACTION_Prepare = X_Ref__Document_Action.PREPARE.getValue();
432 /** Reverse - Accrual = RA */
433 public static final String DOCACTION_Reverse_Accrual = X_Ref__Document_Action.REVERSE__ACCRUAL.getValue();
434 /** Reverse - Correct = RC */
435 public static final String DOCACTION_Reverse_Correct = X_Ref__Document_Action.REVERSE__CORRECT.getValue();
436 /** Re-activate = RE */
437 public static final String DOCACTION_Re_Activate = X_Ref__Document_Action.RE__ACTIVATE.getValue();
438 /** Reject = RJ */
439 public static final String DOCACTION_Reject = X_Ref__Document_Action.REJECT.getValue();
440 /** Void = VO */
441 public static final String DOCACTION_Void = X_Ref__Document_Action.VOID.getValue();
442 /** Wait Complete = WC */
443 public static final String DOCACTION_WaitComplete = X_Ref__Document_Action.WAIT_COMPLETE.getValue();
444 /** Unlock = XL */
445 public static final String DOCACTION_Unlock = X_Ref__Document_Action.UNLOCK.getValue();
446 /** Is test a valid value.
447 @param test testvalue
448 @return true if valid **/
449 public static boolean isDocActionValid(String test)
450 {
451 return X_Ref__Document_Action.isValid(test);
452
453 }
454 /** Set Document Action.
455 @param DocAction The targeted status of the document */
456 public void setDocAction (String DocAction)
457 {
458 if (DocAction == null) throw new IllegalArgumentException ("DocAction is mandatory");
459 if (!isDocActionValid(DocAction))
460 throw new IllegalArgumentException ("DocAction Invalid value - " + DocAction + " - Reference_ID=135 - -- - AP - CL - CO - IN - PO - PR - RA - RC - RE - RJ - VO - WC - XL");
461 set_Value ("DocAction", DocAction);
462
463 }
464
465 /** Get Document Action.
466 @return The targeted status of the document */
467 public String getDocAction()
468 {
469 return (String)get_Value("DocAction");
470
471 }
472
473
474 /** DocStatus AD_Reference_ID=131 */
475 public static final int DOCSTATUS_AD_Reference_ID=131;
476 /** Unknown = ?? */
477 public static final String DOCSTATUS_Unknown = X_Ref__Document_Status.UNKNOWN.getValue();
478 /** Approved = AP */
479 public static final String DOCSTATUS_Approved = X_Ref__Document_Status.APPROVED.getValue();
480 /** Closed = CL */
481 public static final String DOCSTATUS_Closed = X_Ref__Document_Status.CLOSED.getValue();
482 /** Completed = CO */
483 public static final String DOCSTATUS_Completed = X_Ref__Document_Status.COMPLETED.getValue();
484 /** Drafted = DR */
485 public static final String DOCSTATUS_Drafted = X_Ref__Document_Status.DRAFTED.getValue();
486 /** Invalid = IN */
487 public static final String DOCSTATUS_Invalid = X_Ref__Document_Status.INVALID.getValue();
488 /** In Progress = IP */
489 public static final String DOCSTATUS_InProgress = X_Ref__Document_Status.IN_PROGRESS.getValue();
490 /** Not Approved = NA */
491 public static final String DOCSTATUS_NotApproved = X_Ref__Document_Status.NOT_APPROVED.getValue();
492 /** Reversed = RE */
493 public static final String DOCSTATUS_Reversed = X_Ref__Document_Status.REVERSED.getValue();
494 /** Voided = VO */
495 public static final String DOCSTATUS_Voided = X_Ref__Document_Status.VOIDED.getValue();
496 /** Waiting Confirmation = WC */
497 public static final String DOCSTATUS_WaitingConfirmation = X_Ref__Document_Status.WAITING_CONFIRMATION.getValue();
498 /** Waiting Payment = WP */
499 public static final String DOCSTATUS_WaitingPayment = X_Ref__Document_Status.WAITING_PAYMENT.getValue();
500 /** Is test a valid value.
501 @param test testvalue
502 @return true if valid **/
503 public static boolean isDocStatusValid(String test)
504 {
505 return X_Ref__Document_Status.isValid(test);
506
507 }
508 /** Set Document Status.
509 @param DocStatus The current status of the document */
510 public void setDocStatus (String DocStatus)
511 {
512 if (DocStatus == null) throw new IllegalArgumentException ("DocStatus is mandatory");
513 if (!isDocStatusValid(DocStatus))
514 throw new IllegalArgumentException ("DocStatus Invalid value - " + DocStatus + " - Reference_ID=131 - ?? - AP - CL - CO - DR - IN - IP - NA - RE - VO - WC - WP");
515 set_Value ("DocStatus", DocStatus);
516
517 }
518
519 /** Get Document Status.
520 @return The current status of the document */
521 public String getDocStatus()
522 {
523 return (String)get_Value("DocStatus");
524
525 }
526
527 /** Set Document No.
528 @param DocumentNo Document sequence number of the document */
529 public void setDocumentNo (String DocumentNo)
530 {
531 if (DocumentNo == null) throw new IllegalArgumentException ("DocumentNo is mandatory.");
532 set_ValueNoCheck ("DocumentNo", DocumentNo);
533
534 }
535
536 /** Get Document No.
537 @return Document sequence number of the document */
538 public String getDocumentNo()
539 {
540 return (String)get_Value("DocumentNo");
541
542 }
543
544 /** Get Record ID/ColumnName
545 @return ID/ColumnName pair */
546 public KeyNamePair getKeyNamePair()
547 {
548 return new KeyNamePair(get_ID(), getDocumentNo());
549
550 }
551
552 /** Set Comment.
553 @param Help Comment, Help or Hint */
554 public void setHelp (String Help)
555 {
556 set_Value ("Help", Help);
557
558 }
559
560 /** Get Comment.
561 @return Comment, Help or Hint */
562 public String getHelp()
563 {
564 return (String)get_Value("Help");
565
566 }
567
568 /** Set Approved.
569 @param IsApproved Indicates if this document requires approval */
570 public void setIsApproved (boolean IsApproved)
571 {
572 set_Value ("IsApproved", Boolean.valueOf(IsApproved));
573
574 }
575
576 /** Get Approved.
577 @return Indicates if this document requires approval */
578 public boolean isApproved()
579 {
580 return get_ValueAsBoolean("IsApproved");
581
582 }
583
584 /** Set Sales Transaction.
585 @param IsSOTrx This is a Sales Transaction */
586 public void setIsSOTrx (boolean IsSOTrx)
587 {
588 set_Value ("IsSOTrx", Boolean.valueOf(IsSOTrx));
589
590 }
591
592 /** Get Sales Transaction.
593 @return This is a Sales Transaction */
594 public boolean isSOTrx()
595 {
596 return get_ValueAsBoolean("IsSOTrx");
597
598 }
599
600 /** Set Attribute Set Instance.
601 @param M_AttributeSetInstance_ID Product Attribute Set Instance */
602 public void setM_AttributeSetInstance_ID (int M_AttributeSetInstance_ID)
603 {
604 if (M_AttributeSetInstance_ID <= 0) set_Value ("M_AttributeSetInstance_ID", null);
605 else
606 set_Value ("M_AttributeSetInstance_ID", Integer.valueOf(M_AttributeSetInstance_ID));
607
608 }
609
610 /** Get Attribute Set Instance.
611 @return Product Attribute Set Instance */
612 public int getM_AttributeSetInstance_ID()
613 {
614 return get_ValueAsInt("M_AttributeSetInstance_ID");
615
616 }
617
618 /** Set BOM.
619 @param M_BOM_ID Bill of Materials */
620 public void setM_BOM_ID (int M_BOM_ID)
621 {
622 if (M_BOM_ID < 1) throw new IllegalArgumentException ("M_BOM_ID is mandatory.");
623 set_Value ("M_BOM_ID", Integer.valueOf(M_BOM_ID));
624
625 }
626
627 /** Get BOM.
628 @return Bill of Materials */
629 public int getM_BOM_ID()
630 {
631 return get_ValueAsInt("M_BOM_ID");
632
633 }
634
635
636 /** M_Locator_ID AD_Reference_ID=446 */
637 public static final int M_LOCATOR_ID_AD_Reference_ID=446;
638 /** Set Locator.
639 @param M_Locator_ID Warehouse Locator */
640 public void setM_Locator_ID (int M_Locator_ID)
641 {
642 if (M_Locator_ID < 1) throw new IllegalArgumentException ("M_Locator_ID is mandatory.");
643 set_Value ("M_Locator_ID", Integer.valueOf(M_Locator_ID));
644
645 }
646
647 /** Get Locator.
648 @return Warehouse Locator */
649 public int getM_Locator_ID()
650 {
651 return get_ValueAsInt("M_Locator_ID");
652
653 }
654
655 /** Set Product.
656 @param M_Product_ID Product, Service, Item */
657 public void setM_Product_ID (int M_Product_ID)
658 {
659 if (M_Product_ID < 1) throw new IllegalArgumentException ("M_Product_ID is mandatory.");
660 set_Value ("M_Product_ID", Integer.valueOf(M_Product_ID));
661
662 }
663
664 /** Get Product.
665 @return Product, Service, Item */
666 public int getM_Product_ID()
667 {
668 return get_ValueAsInt("M_Product_ID");
669
670 }
671
672 /** Set Routing.
673 @param M_Routing_ID Routing for an assembly */
674 public void setM_Routing_ID (int M_Routing_ID)
675 {
676 if (M_Routing_ID < 1) throw new IllegalArgumentException ("M_Routing_ID is mandatory.");
677 set_Value ("M_Routing_ID", Integer.valueOf(M_Routing_ID));
678
679 }
680
681 /** Get Routing.
682 @return Routing for an assembly */
683 public int getM_Routing_ID()
684 {
685 return get_ValueAsInt("M_Routing_ID");
686
687 }
688
689 /** Set Warehouse.
690 @param M_Warehouse_ID Storage Warehouse and Service Point */
691 public void setM_Warehouse_ID (int M_Warehouse_ID)
692 {
693 if (M_Warehouse_ID < 1) throw new IllegalArgumentException ("M_Warehouse_ID is mandatory.");
694 set_Value ("M_Warehouse_ID", Integer.valueOf(M_Warehouse_ID));
695
696 }
697
698 /** Get Warehouse.
699 @return Storage Warehouse and Service Point */
700 public int getM_Warehouse_ID()
701 {
702 return get_ValueAsInt("M_Warehouse_ID");
703
704 }
705
706 /** Set Work Order Class.
707 @param M_WorkOrderClass_ID Indicates the document types and accounts to be used for a work order */
708 public void setM_WorkOrderClass_ID (int M_WorkOrderClass_ID)
709 {
710 if (M_WorkOrderClass_ID < 1) throw new IllegalArgumentException ("M_WorkOrderClass_ID is mandatory.");
711 set_ValueNoCheck ("M_WorkOrderClass_ID", Integer.valueOf(M_WorkOrderClass_ID));
712
713 }
714
715 /** Get Work Order Class.
716 @return Indicates the document types and accounts to be used for a work order */
717 public int getM_WorkOrderClass_ID()
718 {
719 return get_ValueAsInt("M_WorkOrderClass_ID");
720
721 }
722
723 /** Set Work Order.
724 @param M_WorkOrder_ID Work Order */
725 public void setM_WorkOrder_ID (int M_WorkOrder_ID)
726 {
727 if (M_WorkOrder_ID < 1) throw new IllegalArgumentException ("M_WorkOrder_ID is mandatory.");
728 set_ValueNoCheck ("M_WorkOrder_ID", Integer.valueOf(M_WorkOrder_ID));
729
730 }
731
732 /** Get Work Order.
733 @return Work Order */
734 public int getM_WorkOrder_ID()
735 {
736 return get_ValueAsInt("M_WorkOrder_ID");
737
738 }
739
740 /** Set Posted.
741 @param Posted Posting status */
742 public void setPosted (boolean Posted)
743 {
744 set_ValueNoCheck ("Posted", Boolean.valueOf(Posted));
745
746 }
747
748 /** Get Posted.
749 @return Posting status */
750 public boolean isPosted()
751 {
752 return get_ValueAsBoolean("Posted");
753
754 }
755
756
757 /** PriorityRule AD_Reference_ID=154 */
758 public static final int PRIORITYRULE_AD_Reference_ID=154;
759 /** Urgent = 1 */
760 public static final String PRIORITYRULE_Urgent = X_Ref__PriorityRule.URGENT.getValue();
761 /** High = 3 */
762 public static final String PRIORITYRULE_High = X_Ref__PriorityRule.HIGH.getValue();
763 /** Medium = 5 */
764 public static final String PRIORITYRULE_Medium = X_Ref__PriorityRule.MEDIUM.getValue();
765 /** Low = 7 */
766 public static final String PRIORITYRULE_Low = X_Ref__PriorityRule.LOW.getValue();
767 /** Minor = 9 */
768 public static final String PRIORITYRULE_Minor = X_Ref__PriorityRule.MINOR.getValue();
769 /** Is test a valid value.
770 @param test testvalue
771 @return true if valid **/
772 public static boolean isPriorityRuleValid(String test)
773 {
774 return X_Ref__PriorityRule.isValid(test);
775
776 }
777 /** Set Priority.
778 @param PriorityRule Priority of a document */
779 public void setPriorityRule (String PriorityRule)
780 {
781 if (PriorityRule == null) throw new IllegalArgumentException ("PriorityRule is mandatory");
782 if (!isPriorityRuleValid(PriorityRule))
783 throw new IllegalArgumentException ("PriorityRule Invalid value - " + PriorityRule + " - Reference_ID=154 - 1 - 3 - 5 - 7 - 9");
784 set_Value ("PriorityRule", PriorityRule);
785
786 }
787
788 /** Get Priority.
789 @return Priority of a document */
790 public String getPriorityRule()
791 {
792 return (String)get_Value("PriorityRule");
793
794 }
795
796 /** Set Processed.
797 @param Processed The document has been processed */
798 public void setProcessed (boolean Processed)
799 {
800 set_ValueNoCheck ("Processed", Boolean.valueOf(Processed));
801
802 }
803
804 /** Get Processed.
805 @return The document has been processed */
806 public boolean isProcessed()
807 {
808 return get_ValueAsBoolean("Processed");
809
810 }
811
812 /** Set Process Now.
813 @param Processing Process Now */
814 public void setProcessing (boolean Processing)
815 {
816 set_Value ("Processing", Boolean.valueOf(Processing));
817
818 }
819
820 /** Get Process Now.
821 @return Process Now */
822 public boolean isProcessing()
823 {
824 return get_ValueAsBoolean("Processing");
825
826 }
827
828 /** Set Qty Assembled.
829 @param QtyAssembled Quantity finished at a production routing step */
830 public void setQtyAssembled (java.math.BigDecimal QtyAssembled)
831 {
832 if (QtyAssembled == null) throw new IllegalArgumentException ("QtyAssembled is mandatory.");
833 set_Value ("QtyAssembled", QtyAssembled);
834
835 }
836
837 /** Get Qty Assembled.
838 @return Quantity finished at a production routing step */
839 public java.math.BigDecimal getQtyAssembled()
840 {
841 return get_ValueAsBigDecimal("QtyAssembled");
842
843 }
844
845 /** Set Available Quantity.
846 @param QtyAvailable Available Quantity (On Hand - Reserved) */
847 public void setQtyAvailable (java.math.BigDecimal QtyAvailable)
848 {
849 if (QtyAvailable == null) throw new IllegalArgumentException ("QtyAvailable is mandatory.");
850 set_Value ("QtyAvailable", QtyAvailable);
851
852 }
853
854 /** Get Available Quantity.
855 @return Available Quantity (On Hand - Reserved) */
856 public java.math.BigDecimal getQtyAvailable()
857 {
858 return get_ValueAsBigDecimal("QtyAvailable");
859
860 }
861
862 /** Set Quantity.
863 @param QtyEntered The Quantity Entered is based on the selected UoM */
864 public void setQtyEntered (java.math.BigDecimal QtyEntered)
865 {
866 if (QtyEntered == null) throw new IllegalArgumentException ("QtyEntered is mandatory.");
867 set_Value ("QtyEntered", QtyEntered);
868
869 }
870
871 /** Get Quantity.
872 @return The Quantity Entered is based on the selected UoM */
873 public java.math.BigDecimal getQtyEntered()
874 {
875 return get_ValueAsBigDecimal("QtyEntered");
876
877 }
878
879
880 /** SalesRep_ID AD_Reference_ID=286 */
881 public static final int SALESREP_ID_AD_Reference_ID=286;
882 /** Set Representative.
883 @param SalesRep_ID Company Agent like Sales Representative, Purchase Agent, and Customer Service Representative... */
884 public void setSalesRep_ID (int SalesRep_ID)
885 {
886 if (SalesRep_ID <= 0) set_Value ("SalesRep_ID", null);
887 else
888 set_Value ("SalesRep_ID", Integer.valueOf(SalesRep_ID));
889
890 }
891
892 /** Get Representative.
893 @return Company Agent like Sales Representative, Purchase Agent, and Customer Service Representative... */
894 public int getSalesRep_ID()
895 {
896 return get_ValueAsInt("SalesRep_ID");
897
898 }
899
900 /** Set Send EMail.
901 @param SendEMail Enable sending Document EMail */
902 public void setSendEMail (boolean SendEMail)
903 {
904 set_Value ("SendEMail", Boolean.valueOf(SendEMail));
905
906 }
907
908 /** Get Send EMail.
909 @return Enable sending Document EMail */
910 public boolean isSendEMail()
911 {
912 return get_ValueAsBoolean("SendEMail");
913
914 }
915
916
917 /** User1_ID AD_Reference_ID=134 */
918 public static final int USER1_ID_AD_Reference_ID=134;
919 /** Set User List 1.
920 @param User1_ID User defined list element #1 */
921 public void setUser1_ID (int User1_ID)
922 {
923 if (User1_ID <= 0) set_Value ("User1_ID", null);
924 else
925 set_Value ("User1_ID", Integer.valueOf(User1_ID));
926
927 }
928
929 /** Get User List 1.
930 @return User defined list element #1 */
931 public int getUser1_ID()
932 {
933 return get_ValueAsInt("User1_ID");
934
935 }
936
937
938 /** User2_ID AD_Reference_ID=137 */
939 public static final int USER2_ID_AD_Reference_ID=137;
940 /** Set User List 2.
941 @param User2_ID User defined list element #2 */
942 public void setUser2_ID (int User2_ID)
943 {
944 if (User2_ID <= 0) set_Value ("User2_ID", null);
945 else
946 set_Value ("User2_ID", Integer.valueOf(User2_ID));
947
948 }
949
950 /** Get User List 2.
951 @return User defined list element #2 */
952 public int getUser2_ID()
953 {
954 return get_ValueAsInt("User2_ID");
955
956 }
957
958
959 /** WOSource AD_Reference_ID=449 */
960 public static final int WOSOURCE_AD_Reference_ID=449;
961 /** Sales Order = O */
962 public static final String WOSOURCE_SalesOrder = X_Ref_M_WorkOrder_WOSource.SALES_ORDER.getValue();
963 /** Is test a valid value.
964 @param test testvalue
965 @return true if valid **/
966 public static boolean isWOSourceValid(String test)
967 {
968 return X_Ref_M_WorkOrder_WOSource.isValid(test);
969
970 }
971 /** Set Source.
972 @param WOSource Work Order source */
973 public void setWOSource (String WOSource)
974 {
975 if (!isWOSourceValid(WOSource))
976 throw new IllegalArgumentException ("WOSource Invalid value - " + WOSource + " - Reference_ID=449 - O");
977 set_Value ("WOSource", WOSource);
978
979 }
980
981 /** Get Source.
982 @return Work Order source */
983 public String getWOSource()
984 {
985 return (String)get_Value("WOSource");
986
987 }
988
989
990 /** WOType AD_Reference_ID=450 */
991 public static final int WOTYPE_AD_Reference_ID=450;
992 /** Refurbish = F */
993 public static final String WOTYPE_Refurbish = X_Ref_M_WorkOrder_Type.REFURBISH.getValue();
994 /** Repair = R */
995 public static final String WOTYPE_Repair = X_Ref_M_WorkOrder_Type.REPAIR.getValue();
996 /** Standard = S */
997 public static final String WOTYPE_Standard = X_Ref_M_WorkOrder_Type.STANDARD.getValue();
998 /** Is test a valid value.
999 @param test testvalue
1000 @return true if valid **/
1001 public static boolean isWOTypeValid(String test)
1002 {
1003 return X_Ref_M_WorkOrder_Type.isValid(test);
1004
1005 }
1006 /** Set Work Order Type.
1007 @param WOType Work Order Type */
1008 public void setWOType (String WOType)
1009 {
1010 if (WOType == null) throw new IllegalArgumentException ("WOType is mandatory");
1011 if (!isWOTypeValid(WOType))
1012 throw new IllegalArgumentException ("WOType Invalid value - " + WOType + " - Reference_ID=450 - F - R - S");
1013 set_ValueNoCheck ("WOType", WOType);
1014
1015 }
1016
1017 /** Get Work Order Type.
1018 @return Work Order Type */
1019 public String getWOType()
1020 {
1021 return (String)get_Value("WOType");
1022
1023 }
1024
1025
1026}