PageRenderTime 53ms CodeModel.GetById 27ms RepoModel.GetById 0ms app.codeStats 0ms

/tags/1.31/src/Tests/BehaveTest/BehaveOrganizationUtils.cs

#
C# | 64 lines | 41 code | 6 blank | 17 comment | 0 complexity | cbe54ff6502deee866b796c741e27612 MD5 | raw file
Possible License(s): AGPL-1.0, LGPL-2.1
  1. /****************************************************************************************************
  2. Copyright (C) 2010 RapidWebDev Organization (http://rapidwebdev.org)
  3. Author: Tim, Legal Name: Long Yi, Email: tim.yi@RapidWebDev.org
  4. This program is free software: you can redistribute it and/or modify
  5. it under the terms of the GNU General Public License as published by
  6. the Free Software Foundation, either version 2 of the License, or
  7. (at your option) any later version.
  8. This program is distributed in the hope that it will be useful,
  9. but WITHOUT ANY WARRANTY; without even the implied warranty of
  10. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  11. GNU General Public License for more details.
  12. You should have received a copy of the GNU General Public License
  13. along with this program. If not, see <http://www.gnu.org/licenses/>.
  14. ****************************************************************************************************/
  15. using System;
  16. using System.IO;
  17. using System.Collections.Generic;
  18. using System.Linq;
  19. using System.Data.Linq;
  20. using System.Text;
  21. using System.Transactions;
  22. using System.Web.UI;
  23. using System.Web.UI.WebControls;
  24. using System.Xml;
  25. using System.Xml.Schema;
  26. using NUnit.Framework;
  27. using BaoJianSoft.Common;
  28. using BaoJianSoft.Platform;
  29. using BaoJianSoft.Platform.Linq;
  30. using BaoJianSoft.RapidWeb;
  31. using BaoJianSoft.RapidWeb.DynamicPages;
  32. using BaoJianSoft.RapidWeb.Controls;
  33. namespace BaoJianSoft.Tests.BehaveTest
  34. {
  35. public class BehaveOrganizationUtils
  36. {
  37. public OrganizationObject CreateOrganizationObject(Guid _OrganizationTypeId,string Name,string code)
  38. {
  39. OrganizationObject shOrganization = new OrganizationObject
  40. {
  41. OrganizationCode = code,
  42. OrganizationName = Name,
  43. OrganizationTypeId = _OrganizationTypeId,
  44. Status = OrganizationStatus.Enabled,
  45. Description = "sh-desc"
  46. };
  47. return shOrganization;
  48. }
  49. public OrganizationTypeObject CreateOrganizationTypeOject(string _Name,string _Domain)
  50. {
  51. OrganizationTypeObject department = new OrganizationTypeObject { Name = _Name, Domain = _Domain, Description = "department-desc" };
  52. return department;
  53. }
  54. }
  55. }