Personfield.js 667 B

12345678910111213141516171819202122232425
  1. MWF.xDesktop.requireApp("process.Xform", "Personfield", null, false);
  2. MWF.xApplication.cms.Xform.Personfield = MWF.CMSPersonfield = new Class({
  3. Extends: MWF.APPPersonfield,
  4. getDepartments: function(){
  5. if (this.json.range=="depart"){
  6. return this.getRange();
  7. }
  8. if (this.json.range=="currentdepart"){
  9. return [this.form.businessData.document.creatorDepartment];
  10. }
  11. return [];
  12. },
  13. getCompanys: function(){
  14. if (this.json.range=="company"){
  15. var comp = "";
  16. //if (this.json.rangeKey){
  17. return this.getRange();
  18. //}
  19. }
  20. if (this.json.range=="currentcompany"){
  21. return [this.form.businessData.document.creatorCompany];
  22. }
  23. return [];
  24. }
  25. });