├── Arshf ├── icon arshf project.ico ├── packages.config ├── DBAR.cs ├── Program.cs ├── Properties │ ├── licenses.licx │ ├── Settings.settings │ ├── AssemblyInfo.cs │ ├── Resources.Designer.cs │ ├── Settings.Designer.cs │ └── Resources.resx ├── DBAR.Designer.cs ├── DBAR.edmx.diagram ├── DBAR.Context.cs ├── TBDep.cs ├── TBArchiveCategory.cs ├── TBUSER.cs ├── TBArchiveFile.cs ├── AddPage │ ├── AddNewFileFromHome.cs │ ├── AddArchiveCategory.cs │ ├── LoginFrom.cs │ ├── AddNewFileFromHome.Designer.cs │ ├── AddDep.cs │ ├── AddNewFileFromHome.resx │ ├── AddUser.cs │ ├── AddArchiveCategory.Designer.cs │ ├── AddDep.Designer.cs │ ├── AddDep.resx │ ├── AddArchiveCategory.resx │ └── LoginFrom.Designer.cs ├── App.config ├── Main.cs ├── PL │ ├── Start.cs │ ├── Start.Designer.cs │ ├── SearchResults.cs │ ├── ArchiveFileForm.cs │ ├── SettingForm.cs │ ├── SettingForm.resx │ ├── SearchResults.resx │ └── ShowFiles.cs └── Pages │ ├── HomePage.cs │ ├── HomePage.resx │ ├── DepPage.cs │ ├── UsersPage.cs │ └── ArchiveCatPage.cs ├── Arshf.sln ├── .gitattributes └── .gitignore /Arshf/icon arshf project.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/engsafaaj/Arshf/HEAD/Arshf/icon arshf project.ico -------------------------------------------------------------------------------- /Arshf/packages.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /Arshf/DBAR.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated from a template. 4 | // 5 | // Manual changes to this file may cause unexpected behavior in your application. 6 | // Manual changes to this file will be overwritten if the code is regenerated. 7 | // 8 | //------------------------------------------------------------------------------ 9 | 10 | -------------------------------------------------------------------------------- /Arshf/Program.cs: -------------------------------------------------------------------------------- 1 | using DevExpress.LookAndFeel; 2 | using DevExpress.Skins; 3 | using DevExpress.UserSkins; 4 | using System; 5 | using System.Collections.Generic; 6 | using System.Linq; 7 | using System.Windows.Forms; 8 | 9 | namespace Arshf 10 | { 11 | static class Program 12 | { 13 | /// 14 | /// The main entry point for the application. 15 | /// 16 | [STAThread] 17 | static void Main() 18 | { 19 | Application.EnableVisualStyles(); 20 | Application.SetCompatibleTextRenderingDefault(false); 21 | Application.Run(new PL.Start()); 22 | } 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /Arshf/Properties/licenses.licx: -------------------------------------------------------------------------------- 1 | DevExpress.XtraEditors.TextEdit, DevExpress.XtraEditors.v20.2, Version=20.2.6.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a 2 | DevExpress.XtraGrid.GridControl, DevExpress.XtraGrid.v20.2, Version=20.2.6.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a 3 | DevExpress.XtraEditors.PictureEdit, DevExpress.XtraEditors.v20.2, Version=20.2.6.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a 4 | DevExpress.XtraRichEdit.RichEditControl, DevExpress.XtraRichEdit.v20.2, Version=20.2.6.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a 5 | DevExpress.XtraEditors.ComboBoxEdit, DevExpress.XtraEditors.v20.2, Version=20.2.6.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a 6 | -------------------------------------------------------------------------------- /Arshf/DBAR.Designer.cs: -------------------------------------------------------------------------------- 1 | // T4 code generation is enabled for model 'C:\Users\Safaa Jassim\source\repos\Arshf\Arshf\DBAR.edmx'. 2 | // To enable legacy code generation, change the value of the 'Code Generation Strategy' designer 3 | // property to 'Legacy ObjectContext'. This property is available in the Properties Window when the model 4 | // is open in the designer. 5 | 6 | // If no context and entity classes have been generated, it may be because you created an empty model but 7 | // have not yet chosen which version of Entity Framework to use. To generate a context class and entity 8 | // classes for your model, open the model in the designer, right-click on the designer surface, and 9 | // select 'Update Model from Database...', 'Generate Database from Model...', or 'Add Code Generation 10 | // Item...'. -------------------------------------------------------------------------------- /Arshf.sln: -------------------------------------------------------------------------------- 1 | 2 | Microsoft Visual Studio Solution File, Format Version 12.00 3 | # Visual Studio Version 16 4 | VisualStudioVersion = 16.0.32228.343 5 | MinimumVisualStudioVersion = 10.0.40219.1 6 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Arshf", "Arshf\Arshf.csproj", "{7E9D3BDC-0190-4B50-90E5-F0B7778A18C3}" 7 | EndProject 8 | Global 9 | GlobalSection(SolutionConfigurationPlatforms) = preSolution 10 | Debug|Any CPU = Debug|Any CPU 11 | Release|Any CPU = Release|Any CPU 12 | EndGlobalSection 13 | GlobalSection(ProjectConfigurationPlatforms) = postSolution 14 | {7E9D3BDC-0190-4B50-90E5-F0B7778A18C3}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 15 | {7E9D3BDC-0190-4B50-90E5-F0B7778A18C3}.Debug|Any CPU.Build.0 = Debug|Any CPU 16 | {7E9D3BDC-0190-4B50-90E5-F0B7778A18C3}.Release|Any CPU.ActiveCfg = Release|Any CPU 17 | {7E9D3BDC-0190-4B50-90E5-F0B7778A18C3}.Release|Any CPU.Build.0 = Release|Any CPU 18 | EndGlobalSection 19 | GlobalSection(SolutionProperties) = preSolution 20 | HideSolutionNode = FALSE 21 | EndGlobalSection 22 | GlobalSection(ExtensibilityGlobals) = postSolution 23 | SolutionGuid = {C9E50B77-6624-4A1E-B0B9-1B8EBF4D97C7} 24 | EndGlobalSection 25 | EndGlobal 26 | -------------------------------------------------------------------------------- /Arshf/DBAR.edmx.diagram: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | -------------------------------------------------------------------------------- /Arshf/DBAR.Context.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated from a template. 4 | // 5 | // Manual changes to this file may cause unexpected behavior in your application. 6 | // Manual changes to this file will be overwritten if the code is regenerated. 7 | // 8 | //------------------------------------------------------------------------------ 9 | 10 | namespace Arshf 11 | { 12 | using System; 13 | using System.Data.Entity; 14 | using System.Data.Entity.Infrastructure; 15 | 16 | public partial class DBAREntities : DbContext 17 | { 18 | public DBAREntities() 19 | : base("name=DBAREntities") 20 | { 21 | } 22 | 23 | protected override void OnModelCreating(DbModelBuilder modelBuilder) 24 | { 25 | throw new UnintentionalCodeFirstException(); 26 | } 27 | 28 | public virtual DbSet TBDeps { get; set; } 29 | public virtual DbSet TBUSERS { get; set; } 30 | public virtual DbSet TBArchiveCategories { get; set; } 31 | public virtual DbSet TBArchiveFiles { get; set; } 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /Arshf/TBDep.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated from a template. 4 | // 5 | // Manual changes to this file may cause unexpected behavior in your application. 6 | // Manual changes to this file will be overwritten if the code is regenerated. 7 | // 8 | //------------------------------------------------------------------------------ 9 | 10 | namespace Arshf 11 | { 12 | using System; 13 | using System.Collections.Generic; 14 | 15 | public partial class TBDep 16 | { 17 | [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Usage", "CA2214:DoNotCallOverridableMethodsInConstructors")] 18 | public TBDep() 19 | { 20 | this.TBUSERS = new HashSet(); 21 | } 22 | 23 | public int ID { get; set; } 24 | public string DepName { get; set; } 25 | public string DepDetails { get; set; } 26 | public Nullable AddDate { get; set; } 27 | 28 | [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly")] 29 | public virtual ICollection TBUSERS { get; set; } 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /Arshf/Properties/Settings.settings: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | اسم المؤسسة 22 | 23 | 24 | وصف المؤسسة 25 | 26 | 27 | 28 | 29 | 30 | -------------------------------------------------------------------------------- /Arshf/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | // General Information about an assembly is controlled through the following 5 | // set of attributes. Change these attribute values to modify the information 6 | // associated with an assembly. 7 | [assembly: AssemblyTitle("Arshf")] 8 | [assembly: AssemblyDescription("")] 9 | [assembly: AssemblyConfiguration("")] 10 | [assembly: AssemblyCompany("")] 11 | [assembly: AssemblyProduct("Arshf")] 12 | [assembly: AssemblyCopyright("Copyright © 2022")] 13 | [assembly: AssemblyTrademark("")] 14 | [assembly: AssemblyCulture("")] 15 | // Setting ComVisible to false makes the types in this assembly not visible 16 | // to COM components. If you need to access a type in this assembly from 17 | // COM, set the ComVisible attribute to true on that type. 18 | [assembly: ComVisible(false)] 19 | // The following GUID is for the ID of the typelib if this project is exposed to COM 20 | [assembly: Guid("9006f149-aa49-4b8e-ba69-386d945fa738")] 21 | // Version information for an assembly consists of the following four values: 22 | // 23 | // Major Version 24 | // Minor Version 25 | // Build Number 26 | // Revision 27 | // 28 | // You can specify all the values or you can default the Build and Revision Numbers 29 | // by using the '*' as shown below: 30 | // [assembly: AssemblyVersion("1.0.*")] 31 | [assembly: AssemblyVersion("1.0.0.0")] 32 | [assembly: AssemblyFileVersion("1.0.0.0")] 33 | -------------------------------------------------------------------------------- /Arshf/TBArchiveCategory.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated from a template. 4 | // 5 | // Manual changes to this file may cause unexpected behavior in your application. 6 | // Manual changes to this file will be overwritten if the code is regenerated. 7 | // 8 | //------------------------------------------------------------------------------ 9 | 10 | namespace Arshf 11 | { 12 | using System; 13 | using System.Collections.Generic; 14 | 15 | public partial class TBArchiveCategory 16 | { 17 | [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Usage", "CA2214:DoNotCallOverridableMethodsInConstructors")] 18 | public TBArchiveCategory() 19 | { 20 | this.TBArchiveFiles = new HashSet(); 21 | } 22 | 23 | public int ID { get; set; } 24 | public Nullable IDUser { get; set; } 25 | public string UserName { get; set; } 26 | public string UserDep { get; set; } 27 | public string ArchiveTitle { get; set; } 28 | public string ArchiveDes { get; set; } 29 | public Nullable AddDate { get; set; } 30 | 31 | public virtual TBUSER TBUSER { get; set; } 32 | [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly")] 33 | public virtual ICollection TBArchiveFiles { get; set; } 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /Arshf/TBUSER.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated from a template. 4 | // 5 | // Manual changes to this file may cause unexpected behavior in your application. 6 | // Manual changes to this file will be overwritten if the code is regenerated. 7 | // 8 | //------------------------------------------------------------------------------ 9 | 10 | namespace Arshf 11 | { 12 | using System; 13 | using System.Collections.Generic; 14 | 15 | public partial class TBUSER 16 | { 17 | [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Usage", "CA2214:DoNotCallOverridableMethodsInConstructors")] 18 | public TBUSER() 19 | { 20 | this.TBArchiveCategories = new HashSet(); 21 | } 22 | 23 | public int ID { get; set; } 24 | public Nullable IDDep { get; set; } 25 | public string FullName { get; set; } 26 | public string UserName { get; set; } 27 | public string Password { get; set; } 28 | public string DepName { get; set; } 29 | public string UserRole { get; set; } 30 | public Nullable AddDate { get; set; } 31 | 32 | public virtual TBDep TBDep { get; set; } 33 | [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly")] 34 | public virtual ICollection TBArchiveCategories { get; set; } 35 | } 36 | } 37 | -------------------------------------------------------------------------------- /Arshf/TBArchiveFile.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated from a template. 4 | // 5 | // Manual changes to this file may cause unexpected behavior in your application. 6 | // Manual changes to this file will be overwritten if the code is regenerated. 7 | // 8 | //------------------------------------------------------------------------------ 9 | 10 | namespace Arshf 11 | { 12 | using System; 13 | using System.Collections.Generic; 14 | 15 | public partial class TBArchiveFile 16 | { 17 | public int ID { get; set; } 18 | public Nullable IDArchive { get; set; } 19 | public string ArchDep { get; set; } 20 | public string ArchTitle { get; set; } 21 | public string ArchNumber { get; set; } 22 | public Nullable ArchDate { get; set; } 23 | public string ArchSender { get; set; } 24 | public string ArchReciver { get; set; } 25 | public string ArchDetails { get; set; } 26 | public string FileName1 { get; set; } 27 | public byte[] FileFile1 { get; set; } 28 | public string FileExt1 { get; set; } 29 | public Nullable FileSize1 { get; set; } 30 | public string FileName2 { get; set; } 31 | public byte[] FileFile2 { get; set; } 32 | public string FileExt2 { get; set; } 33 | public Nullable FileSize2 { get; set; } 34 | public string FileName3 { get; set; } 35 | public byte[] FileFile3 { get; set; } 36 | public string FileExt3 { get; set; } 37 | public Nullable FileSize3 { get; set; } 38 | public string FileName4 { get; set; } 39 | public byte[] FileFile4 { get; set; } 40 | public string FileExt4 { get; set; } 41 | public Nullable FileSize4 { get; set; } 42 | public string FileName5 { get; set; } 43 | public byte[] FileFile5 { get; set; } 44 | public string FileExt5 { get; set; } 45 | public Nullable FileSize5 { get; set; } 46 | public Nullable AddDate { get; set; } 47 | 48 | public virtual TBArchiveCategory TBArchiveCategory { get; set; } 49 | } 50 | } 51 | -------------------------------------------------------------------------------- /Arshf/AddPage/AddNewFileFromHome.cs: -------------------------------------------------------------------------------- 1 | using DevExpress.XtraEditors; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.ComponentModel; 5 | using System.Data; 6 | using System.Drawing; 7 | using System.Linq; 8 | using System.Text; 9 | using System.Threading.Tasks; 10 | using System.Windows.Forms; 11 | 12 | namespace Arshf.AddPage 13 | { 14 | public partial class AddNewFileFromHome : DevExpress.XtraEditors.XtraForm 15 | { 16 | DBAREntities db; 17 | private List ListCategory; 18 | TBArchiveCategory tbaddd; 19 | private int id; 20 | 21 | public string DepName { get; } 22 | public string UserRole { get; } 23 | 24 | public AddNewFileFromHome() 25 | { 26 | InitializeComponent(); 27 | DepName = Properties.Settings.Default.UserDep; 28 | db = new DBAREntities(); 29 | } 30 | 31 | private void GetCategoryName() 32 | { 33 | try 34 | { 35 | 36 | ListCategory = db.TBArchiveCategories.Where(x=>x.UserDep==DepName).Select(x => x.ArchiveTitle).ToList(); 37 | } 38 | catch { } 39 | } 40 | 41 | private async void comboBox1_SelectedIndexChanged(object sender, EventArgs e) 42 | { 43 | 44 | } 45 | 46 | private async void AddNewFileFromHome_Load(object sender, EventArgs e) 47 | { 48 | // Load 49 | await Task.Run(() => GetCategoryName()); 50 | comboBox1.DataSource = ListCategory; 51 | 52 | } 53 | 54 | private void SetCatData(string CatName) 55 | { 56 | try 57 | { 58 | tbaddd = db.TBArchiveCategories.Where(x => x.ArchiveTitle == CatName).FirstOrDefault(); 59 | } 60 | catch { } 61 | } 62 | 63 | private async void btn_search_Click(object sender, EventArgs e) 64 | { 65 | try 66 | { 67 | var CatName = comboBox1.SelectedItem.ToString(); 68 | await Task.Run(() => SetCatData(CatName)); 69 | PL.ArchiveFileForm archive = new PL.ArchiveFileForm(); 70 | id = tbaddd.ID; 71 | archive.lb_id.Text = id.ToString(); 72 | archive.ArchiveID = id; 73 | archive.lb_archivename.Text = tbaddd.ArchiveTitle; 74 | archive.lb_archdep.Text = tbaddd.UserDep; 75 | archive.Show(); 76 | 77 | 78 | } 79 | catch { } 80 | } 81 | } 82 | } -------------------------------------------------------------------------------- /.gitattributes: -------------------------------------------------------------------------------- 1 | ############################################################################### 2 | # Set default behavior to automatically normalize line endings. 3 | ############################################################################### 4 | * text=auto 5 | 6 | ############################################################################### 7 | # Set default behavior for command prompt diff. 8 | # 9 | # This is need for earlier builds of msysgit that does not have it on by 10 | # default for csharp files. 11 | # Note: This is only used by command line 12 | ############################################################################### 13 | #*.cs diff=csharp 14 | 15 | ############################################################################### 16 | # Set the merge driver for project and solution files 17 | # 18 | # Merging from the command prompt will add diff markers to the files if there 19 | # are conflicts (Merging from VS is not affected by the settings below, in VS 20 | # the diff markers are never inserted). Diff markers may cause the following 21 | # file extensions to fail to load in VS. An alternative would be to treat 22 | # these files as binary and thus will always conflict and require user 23 | # intervention with every merge. To do so, just uncomment the entries below 24 | ############################################################################### 25 | #*.sln merge=binary 26 | #*.csproj merge=binary 27 | #*.vbproj merge=binary 28 | #*.vcxproj merge=binary 29 | #*.vcproj merge=binary 30 | #*.dbproj merge=binary 31 | #*.fsproj merge=binary 32 | #*.lsproj merge=binary 33 | #*.wixproj merge=binary 34 | #*.modelproj merge=binary 35 | #*.sqlproj merge=binary 36 | #*.wwaproj merge=binary 37 | 38 | ############################################################################### 39 | # behavior for image files 40 | # 41 | # image files are treated as binary by default. 42 | ############################################################################### 43 | #*.jpg binary 44 | #*.png binary 45 | #*.gif binary 46 | 47 | ############################################################################### 48 | # diff behavior for common document formats 49 | # 50 | # Convert binary document formats to text before diffing them. This feature 51 | # is only available from the command line. Turn it on by uncommenting the 52 | # entries below. 53 | ############################################################################### 54 | #*.doc diff=astextplain 55 | #*.DOC diff=astextplain 56 | #*.docx diff=astextplain 57 | #*.DOCX diff=astextplain 58 | #*.dot diff=astextplain 59 | #*.DOT diff=astextplain 60 | #*.pdf diff=astextplain 61 | #*.PDF diff=astextplain 62 | #*.rtf diff=astextplain 63 | #*.RTF diff=astextplain 64 | -------------------------------------------------------------------------------- /Arshf/App.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 |
6 | 7 | 8 | 9 |
10 | 11 | 12 | 13 | 14 | 15 | System 16 | 17 | 18 | True 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | اسم المؤسسة 41 | 42 | 43 | وصف المؤسسة 44 | 45 | 46 | 47 | 48 | 49 | 50 | -------------------------------------------------------------------------------- /Arshf/Main.cs: -------------------------------------------------------------------------------- 1 | using DevExpress.XtraEditors; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.ComponentModel; 5 | using System.Data; 6 | using System.Drawing; 7 | using System.Linq; 8 | using System.Text; 9 | using System.Windows.Forms; 10 | 11 | namespace Arshf 12 | { 13 | public partial class Main : DevExpress.XtraEditors.XtraForm 14 | { 15 | public Main() 16 | { 17 | InitializeComponent(); 18 | LoadHomePage(); 19 | } 20 | 21 | 22 | // Load Home Page 23 | private void btn_home_ItemClick(object sender, DevExpress.XtraEditors.TileItemEventArgs e) 24 | { 25 | LoadHomePage(); 26 | } 27 | 28 | private void LoadHomePage() 29 | { 30 | Pages.HomePage page = new Pages.HomePage(); 31 | LoadPage(page); 32 | } 33 | 34 | // Load Page Method 35 | private void LoadPage(DevExpress.XtraEditors.XtraUserControl Page) 36 | { 37 | try 38 | { 39 | var oldpage = pn_container.Controls.OfType().FirstOrDefault(); 40 | if (oldpage != null) 41 | { 42 | pn_container.Controls.Remove(oldpage); 43 | oldpage.Dispose(); 44 | } 45 | 46 | 47 | Page.Dock = DockStyle.Fill; 48 | pn_container.Controls.Add(Page); 49 | } 50 | catch { } 51 | } 52 | 53 | private void btn_dep_ItemClick(object sender, DevExpress.XtraEditors.TileItemEventArgs e) 54 | { 55 | Pages.DepPage page = new Pages.DepPage(); 56 | LoadPage(page); 57 | } 58 | 59 | private void btn_users_ItemClick(object sender, DevExpress.XtraEditors.TileItemEventArgs e) 60 | { 61 | Pages.UsersPage page = new Pages.UsersPage(); 62 | LoadPage(page); 63 | } 64 | 65 | private void btn_archive_ItemClick(object sender, DevExpress.XtraEditors.TileItemEventArgs e) 66 | { 67 | Pages.ArchiveCatPage page = new Pages.ArchiveCatPage(); 68 | LoadPage(page); 69 | } 70 | 71 | private void btn_settings_ItemClick(object sender, TileItemEventArgs e) 72 | { 73 | PL.SettingForm setting = new PL.SettingForm(); 74 | setting.Show(); 75 | } 76 | 77 | private void btn_help_ItemClick(object sender, TileItemEventArgs e) 78 | { 79 | AddPage.LoginFrom loginFrom = new AddPage.LoginFrom(); 80 | loginFrom.Show(); 81 | Hide(); 82 | } 83 | 84 | private void Main_FormClosed(object sender, FormClosedEventArgs e) 85 | { 86 | Application.Exit(); 87 | } 88 | } 89 | } 90 | -------------------------------------------------------------------------------- /Arshf/Properties/Resources.Designer.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated by a tool. 4 | // Runtime Version:4.0.30319.18034 5 | // 6 | // Changes to this file may cause incorrect behavior and will be lost if 7 | // the code is regenerated. 8 | // 9 | //------------------------------------------------------------------------------ 10 | 11 | 12 | namespace Arshf.Properties 13 | { 14 | /// 15 | /// A strongly-typed resource class, for looking up localized strings, etc. 16 | /// 17 | // This class was auto-generated by the StronglyTypedResourceBuilder 18 | // class via a tool like ResGen or Visual Studio. 19 | // To add or remove a member, edit your .ResX file then rerun ResGen 20 | // with the /str option, or rebuild your VS project. 21 | [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.0.0.0")] 22 | [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] 23 | [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] 24 | internal class Resources 25 | { 26 | 27 | private static global::System.Resources.ResourceManager resourceMan; 28 | 29 | private static global::System.Globalization.CultureInfo resourceCulture; 30 | 31 | [global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")] 32 | internal Resources() 33 | { 34 | } 35 | 36 | /// 37 | /// Returns the cached ResourceManager instance used by this class. 38 | /// 39 | [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] 40 | internal static global::System.Resources.ResourceManager ResourceManager 41 | { 42 | get 43 | { 44 | if ((resourceMan == null)) 45 | { 46 | global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("Arshf.Properties.Resources", typeof(Resources).Assembly); 47 | resourceMan = temp; 48 | } 49 | return resourceMan; 50 | } 51 | } 52 | 53 | /// 54 | /// Overrides the current thread's CurrentUICulture property for all 55 | /// resource lookups using this strongly typed resource class. 56 | /// 57 | [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] 58 | internal static global::System.Globalization.CultureInfo Culture 59 | { 60 | get 61 | { 62 | return resourceCulture; 63 | } 64 | set 65 | { 66 | resourceCulture = value; 67 | } 68 | } 69 | } 70 | } 71 | -------------------------------------------------------------------------------- /Arshf/PL/Start.cs: -------------------------------------------------------------------------------- 1 | using DevExpress.XtraSplashScreen; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.ComponentModel; 5 | using System.Data; 6 | using System.Drawing; 7 | using System.Linq; 8 | using System.Text; 9 | using System.Threading.Tasks; 10 | using System.Windows.Forms; 11 | 12 | namespace Arshf.PL 13 | { 14 | public partial class Start : SplashScreen 15 | { 16 | DBAREntities db; 17 | TBUSER tbadd; 18 | int state; 19 | public Start() 20 | { 21 | InitializeComponent(); 22 | this.labelCopyright.Text = "جميع الحقوق محفوظة © 2022-" + DateTime.Now.Year.ToString(); 23 | } 24 | 25 | #region Overrides 26 | 27 | public override void ProcessCommand(Enum cmd, object arg) 28 | { 29 | base.ProcessCommand(cmd, arg); 30 | } 31 | 32 | #endregion 33 | 34 | public enum SplashScreenCommand 35 | { 36 | } 37 | 38 | private void CheckState() 39 | { 40 | try 41 | { 42 | db = new DBAREntities(); 43 | var userid = db.TBUSERS.Select(x=>x.ID).FirstOrDefault(); 44 | // Login in 45 | if (userid > 0) 46 | { 47 | state = 1; 48 | } 49 | else 50 | { 51 | state = 2; 52 | } 53 | 54 | } 55 | catch 56 | { 57 | state = 3; 58 | } 59 | } 60 | 61 | private async void Start_Load(object sender, EventArgs e) 62 | { 63 | await Task.Run(() => CheckState()); 64 | if (state == 1) 65 | { 66 | AddPage.LoginFrom loginFrom = new AddPage.LoginFrom(); 67 | loginFrom.Show(); 68 | Hide(); 69 | } 70 | if (state == 2) 71 | { 72 | // Add Dep and User 73 | AddPage.AddDep DepPage = new AddPage.AddDep(); 74 | DepPage.start = 1; 75 | MessageBox.Show("مرحبا بك , الصفحة القادمة تتيح لك اضافة قسم "); 76 | DepPage.Show(); 77 | Hide(); 78 | } 79 | if (state == 3) 80 | { 81 | // Set Server Con form Settings 82 | var rs= MessageBox.Show( "اختر نعم لاعادة الاتصال, لا لضبط الاتصال, الغاء الامر لغلق البرنامج", "خطأ اتصال", MessageBoxButtons.YesNoCancel, MessageBoxIcon.Question); 83 | if (rs == DialogResult.Yes) 84 | { 85 | Application.Restart(); 86 | }else if (rs == DialogResult.No) 87 | { 88 | PL.SettingForm setting = new SettingForm(); 89 | setting.Start = 1; 90 | setting.Show(); 91 | Hide(); 92 | 93 | } 94 | else if(rs==DialogResult.Cancel) 95 | { 96 | Application.Exit(); 97 | } 98 | 99 | } 100 | } 101 | } 102 | } -------------------------------------------------------------------------------- /Arshf/AddPage/AddArchiveCategory.cs: -------------------------------------------------------------------------------- 1 | using DevExpress.XtraEditors; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.ComponentModel; 5 | using System.Data; 6 | using System.Data.Entity.Migrations; 7 | using System.Drawing; 8 | using System.Linq; 9 | using System.Text; 10 | using System.Threading; 11 | using System.Threading.Tasks; 12 | using System.Windows.Forms; 13 | 14 | namespace Arshf.AddPage 15 | { 16 | public partial class AddArchiveCategory : DevExpress.XtraEditors.XtraForm 17 | { 18 | // DataBase and Tables 19 | DBAREntities db; 20 | TBArchiveCategory tbadd; 21 | // Other var 22 | public int id; 23 | public Pages.ArchiveCatPage page; 24 | bool state; 25 | public AddArchiveCategory() 26 | { 27 | InitializeComponent(); 28 | } 29 | 30 | private async void btn_add_Click(object sender, EventArgs e) 31 | { 32 | if (edt_name.Text == "") 33 | { 34 | MessageBox.Show("خطأ ادخال", "اكمل الحقول لطفا", MessageBoxButtons.OK, MessageBoxIcon.Information); 35 | } 36 | else 37 | { 38 | // Set Data 39 | // Check if Add or Edit 40 | if (id == 0) 41 | // Add 42 | { 43 | tbadd = new TBArchiveCategory 44 | { 45 | ArchiveTitle=edt_name.Text, 46 | ArchiveDes=edt_details.Text, 47 | UserName=Properties.Settings.Default.FullName, 48 | UserDep=Properties.Settings.Default.UserDep, 49 | IDUser= Properties.Settings.Default.UserID 50 | }; 51 | } 52 | // Edit 53 | else 54 | { 55 | tbadd = new TBArchiveCategory 56 | { 57 | ID=id, 58 | ArchiveTitle = edt_name.Text, 59 | ArchiveDes = edt_details.Text, 60 | UserName = Properties.Settings.Default.FullName, 61 | UserDep = Properties.Settings.Default.UserDep, 62 | IDUser = Properties.Settings.Default.UserID 63 | 64 | }; 65 | } 66 | 67 | // loading 68 | loading.Visible=true; 69 | // Add or Edit 70 | var result =await Task.Run(()=> AddOrEdit(tbadd)); 71 | if (result == true) 72 | { 73 | // Reload Data 74 | page.LoadData(); 75 | toastNotificationsManager1.ShowNotification("96616aac-b9fe-45d7-8bb1-5cd04f388f4c"); 76 | Close(); 77 | } 78 | else 79 | { 80 | MessageBox.Show("خطأ في الاتصال", "تأكد من الاتصال في السيرفر لطفا", MessageBoxButtons.OK, MessageBoxIcon.Error); 81 | } 82 | loading.Visible = false; 83 | 84 | 85 | } 86 | } 87 | 88 | // Add or Edit 89 | private bool AddOrEdit(TBArchiveCategory Data) 90 | { 91 | try 92 | { 93 | db = new DBAREntities(); 94 | db.Set().AddOrUpdate(Data); 95 | db.SaveChanges(); 96 | state = true; 97 | 98 | } 99 | catch { state = false; } 100 | return state; 101 | } 102 | } 103 | } -------------------------------------------------------------------------------- /Arshf/Pages/HomePage.cs: -------------------------------------------------------------------------------- 1 | using DevExpress.XtraEditors; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.ComponentModel; 5 | using System.Data; 6 | using System.Drawing; 7 | using System.Linq; 8 | using System.Text; 9 | using System.Threading.Tasks; 10 | using System.Windows.Forms; 11 | 12 | namespace Arshf.Pages 13 | { 14 | public partial class HomePage : DevExpress.XtraEditors.XtraUserControl 15 | { 16 | 17 | 18 | private DataSet dataset; 19 | DBAREntities db; 20 | private int Depcount; 21 | private int Usercount; 22 | private int Archiescount; 23 | private double DataCount1; 24 | private double DataCount2; 25 | private double DataCount3; 26 | private double DataCount4; 27 | private double DataCount5; 28 | private double TotalSize; 29 | private int id; 30 | 31 | public HomePage() 32 | { 33 | InitializeComponent(); 34 | db = new DBAREntities(); 35 | } 36 | 37 | 38 | private void LoadDep() 39 | { 40 | try 41 | { 42 | Depcount = db.TBDeps.Select(x => x.ID).ToList().Count; 43 | } 44 | catch { } 45 | } 46 | private void LoadUsers() 47 | { 48 | try 49 | { 50 | Usercount = db.TBUSERS.Select(x => x.ID).ToList().Count; 51 | } 52 | catch { } 53 | } 54 | private void LoadArchies() 55 | { 56 | try 57 | { 58 | Archiescount = db.TBArchiveCategories.Select(x => x.ID).ToList().Count; 59 | } 60 | catch { } 61 | } 62 | private void LoadData() 63 | { 64 | try 65 | { 66 | DataCount1 =(double) db.TBArchiveFiles.Select(x => x.FileSize1).ToArray().Sum(); 67 | DataCount2 = (double)db.TBArchiveFiles.Select(x => x.FileSize2).ToArray().Sum(); 68 | DataCount3 = (double)db.TBArchiveFiles.Select(x => x.FileSize3).ToArray().Sum(); 69 | DataCount4 = (double)db.TBArchiveFiles.Select(x => x.FileSize4).ToArray().Sum(); 70 | DataCount5 = (double)db.TBArchiveFiles.Select(x => x.FileSize5).ToArray().Sum(); 71 | TotalSize = (DataCount1 + DataCount2 + DataCount3 + DataCount4 + DataCount5)*0.000001; 72 | } 73 | catch { } 74 | } 75 | 76 | private async void HomePage_Load(object sender, EventArgs e) 77 | { 78 | // Load Dep 79 | await Task.Run(() => LoadDep()); 80 | await Task.Run(() => LoadArchies()); 81 | await Task.Run(() => LoadData()); 82 | await Task.Run(() => LoadUsers()); 83 | txt_depcount.Text = Depcount.ToString(); 84 | txt_usercount.Text = Usercount.ToString(); 85 | txt_archviecount.Text = Archiescount.ToString(); 86 | txt_datasize.Text = TotalSize.ToString("#0.0"); 87 | 88 | } 89 | 90 | private void btn_search_Click(object sender, EventArgs e) 91 | { 92 | PL.SearchResults search = new PL.SearchResults(); 93 | search.SeachText = edt_search.Text; 94 | search.Show(); 95 | 96 | } 97 | 98 | private void btn_addfile_Click(object sender, EventArgs e) 99 | { 100 | 101 | } 102 | 103 | private void simpleButton1_Click(object sender, EventArgs e) 104 | { 105 | AddPage.AddNewFileFromHome addNewFileFromHome = new AddPage.AddNewFileFromHome(); 106 | addNewFileFromHome.Show(); 107 | 108 | } 109 | } 110 | } 111 | -------------------------------------------------------------------------------- /Arshf/AddPage/LoginFrom.cs: -------------------------------------------------------------------------------- 1 | using DevExpress.XtraEditors; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.ComponentModel; 5 | using System.Data; 6 | using System.Data.Entity.Migrations; 7 | using System.Drawing; 8 | using System.Linq; 9 | using System.Text; 10 | using System.Threading; 11 | using System.Threading.Tasks; 12 | using System.Windows.Forms; 13 | 14 | namespace Arshf.AddPage 15 | { 16 | public partial class LoginFrom : DevExpress.XtraEditors.XtraForm 17 | { 18 | // DataBase and Tables 19 | DBAREntities db; 20 | private List DepNameList; 21 | TBUSER tbadd; 22 | // Other var 23 | public int id; 24 | public int depid; 25 | public Pages.UsersPage page; 26 | bool state; 27 | public LoginFrom() 28 | { 29 | InitializeComponent(); 30 | } 31 | 32 | private async void btn_add_Click(object sender, EventArgs e) 33 | { 34 | if ( edt_username.Text == "" || edt_password.Text == "") 35 | { 36 | MessageBox.Show("خطأ ادخال", "اكمل الحقول لطفا", MessageBoxButtons.OK, MessageBoxIcon.Information); 37 | } 38 | else 39 | { 40 | // Set Data 41 | 42 | 43 | 44 | // loading 45 | loading.Visible=true; 46 | // Add or Edit 47 | var username = edt_username.Text; 48 | var pasword = edt_password.Text; 49 | var result =await Task.Run(()=> LoginCheck(username,pasword)); 50 | if (result == true) 51 | { 52 | // Sign in 53 | Main main = new Main(); 54 | // Set User Data 55 | Properties.Settings.Default.UserID = tbadd.ID; 56 | Properties.Settings.Default.FullName = tbadd.FullName; 57 | Properties.Settings.Default.UserName = tbadd.UserName; 58 | Properties.Settings.Default.UserRole = tbadd.UserRole; 59 | Properties.Settings.Default.UserDep = tbadd.DepName; 60 | Properties.Settings.Default.Save(); 61 | // Role 62 | if (tbadd.UserRole == "مستخدم") 63 | { 64 | main.btn_dep.Visible = false; 65 | main.btn_users.Visible = false; 66 | } 67 | main.Show(); 68 | 69 | Hide(); 70 | } 71 | else 72 | { 73 | MessageBox.Show("خطأ في تسجل الدخول", "خطأ في معلومات تسجيل الدخول", MessageBoxButtons.OK, MessageBoxIcon.Error); 74 | } 75 | loading.Visible = false; 76 | 77 | 78 | } 79 | } 80 | 81 | // Add or Edit 82 | private bool LoginCheck(string UserName, string Password) 83 | { 84 | try 85 | { 86 | db = new DBAREntities(); 87 | tbadd = db.TBUSERS.Where(X => X.UserName == UserName && X.Password == Password).FirstOrDefault(); 88 | if (tbadd != null) 89 | { 90 | state = true; 91 | 92 | } 93 | else 94 | { 95 | state = false; 96 | 97 | } 98 | 99 | 100 | } 101 | catch { state = false; } 102 | return state; 103 | } 104 | 105 | private void LoginFrom_FormClosed(object sender, FormClosedEventArgs e) 106 | { 107 | Application.Exit(); 108 | } 109 | } 110 | } -------------------------------------------------------------------------------- /Arshf/AddPage/AddNewFileFromHome.Designer.cs: -------------------------------------------------------------------------------- 1 | 2 | namespace Arshf.AddPage 3 | { 4 | partial class AddNewFileFromHome 5 | { 6 | /// 7 | /// Required designer variable. 8 | /// 9 | private System.ComponentModel.IContainer components = null; 10 | 11 | /// 12 | /// Clean up any resources being used. 13 | /// 14 | /// true if managed resources should be disposed; otherwise, false. 15 | protected override void Dispose(bool disposing) 16 | { 17 | if (disposing && (components != null)) 18 | { 19 | components.Dispose(); 20 | } 21 | base.Dispose(disposing); 22 | } 23 | 24 | #region Windows Form Designer generated code 25 | 26 | /// 27 | /// Required method for Designer support - do not modify 28 | /// the contents of this method with the code editor. 29 | /// 30 | private void InitializeComponent() 31 | { 32 | this.comboBox1 = new System.Windows.Forms.ComboBox(); 33 | this.btn_search = new DevExpress.XtraEditors.SimpleButton(); 34 | this.SuspendLayout(); 35 | // 36 | // comboBox1 37 | // 38 | this.comboBox1.Font = new System.Drawing.Font("Cairo", 24F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); 39 | this.comboBox1.FormattingEnabled = true; 40 | this.comboBox1.Location = new System.Drawing.Point(94, 9); 41 | this.comboBox1.Name = "comboBox1"; 42 | this.comboBox1.Size = new System.Drawing.Size(427, 83); 43 | this.comboBox1.TabIndex = 5; 44 | this.comboBox1.SelectedIndexChanged += new System.EventHandler(this.comboBox1_SelectedIndexChanged); 45 | // 46 | // btn_search 47 | // 48 | this.btn_search.Appearance.BackColor = DevExpress.LookAndFeel.DXSkinColors.FillColors.Primary; 49 | this.btn_search.Appearance.Font = new System.Drawing.Font("Cairo", 13.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); 50 | this.btn_search.Appearance.Options.UseBackColor = true; 51 | this.btn_search.Appearance.Options.UseFont = true; 52 | this.btn_search.Location = new System.Drawing.Point(223, 101); 53 | this.btn_search.Name = "btn_search"; 54 | this.btn_search.Size = new System.Drawing.Size(156, 77); 55 | this.btn_search.TabIndex = 6; 56 | this.btn_search.Text = "موافق"; 57 | this.btn_search.Click += new System.EventHandler(this.btn_search_Click); 58 | // 59 | // AddNewFileFromHome 60 | // 61 | this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 16F); 62 | this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; 63 | this.ClientSize = new System.Drawing.Size(618, 190); 64 | this.Controls.Add(this.btn_search); 65 | this.Controls.Add(this.comboBox1); 66 | this.IconOptions.ShowIcon = false; 67 | this.MaximizeBox = false; 68 | this.MinimizeBox = false; 69 | this.Name = "AddNewFileFromHome"; 70 | this.RightToLeftLayout = true; 71 | this.ShowInTaskbar = false; 72 | this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen; 73 | this.TopMost = true; 74 | this.Load += new System.EventHandler(this.AddNewFileFromHome_Load); 75 | this.ResumeLayout(false); 76 | 77 | } 78 | 79 | #endregion 80 | private System.Windows.Forms.ComboBox comboBox1; 81 | private DevExpress.XtraEditors.SimpleButton btn_search; 82 | } 83 | } -------------------------------------------------------------------------------- /Arshf/AddPage/AddDep.cs: -------------------------------------------------------------------------------- 1 | using DevExpress.XtraEditors; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.ComponentModel; 5 | using System.Data; 6 | using System.Data.Entity.Migrations; 7 | using System.Drawing; 8 | using System.Linq; 9 | using System.Text; 10 | using System.Threading; 11 | using System.Threading.Tasks; 12 | using System.Windows.Forms; 13 | 14 | namespace Arshf.AddPage 15 | { 16 | public partial class AddDep : DevExpress.XtraEditors.XtraForm 17 | { 18 | // DataBase and Tables 19 | DBAREntities db; 20 | TBDep tbadd; 21 | // Other var 22 | public int id; 23 | public Pages.DepPage page; 24 | bool state; 25 | public int start; 26 | public AddDep() 27 | { 28 | InitializeComponent(); 29 | } 30 | 31 | private async void btn_add_Click(object sender, EventArgs e) 32 | { 33 | if (edt_name.Text == "") 34 | { 35 | MessageBox.Show("خطأ ادخال", "اكمل الحقول لطفا", MessageBoxButtons.OK, MessageBoxIcon.Information); 36 | } 37 | else 38 | { 39 | // Set Data 40 | // Check if Add or Edit 41 | if (id == 0) 42 | // Add 43 | { 44 | tbadd = new TBDep 45 | { 46 | DepName=edt_name.Text, 47 | DepDetails=edt_details.Text, 48 | 49 | }; 50 | } 51 | // Edit 52 | else 53 | { 54 | tbadd = new TBDep 55 | { 56 | ID=id, 57 | DepName = edt_name.Text, 58 | DepDetails = edt_details.Text, 59 | 60 | }; 61 | } 62 | 63 | // loading 64 | loading.Visible=true; 65 | // Add or Edit 66 | var result =await Task.Run(()=> AddOrEdit(tbadd)); 67 | if (result == true) 68 | { 69 | 70 | toastNotificationsManager1.ShowNotification("96616aac-b9fe-45d7-8bb1-5cd04f388f4c"); 71 | if (start == 1) 72 | { 73 | // Add Dep and User 74 | AddPage.AddUser UserPage = new AddPage.AddUser(); 75 | UserPage.Start = 1; 76 | MessageBox.Show(" الصفحة القادمة تتيح لك اضافة مستخدم "); 77 | start = 0; 78 | UserPage.Show(); 79 | } 80 | else 81 | { 82 | // Reload Data 83 | page.LoadData(); 84 | } 85 | Close(); 86 | } 87 | else 88 | { 89 | MessageBox.Show("خطأ في الاتصال", "تأكد من الاتصال في السيرفر لطفا", MessageBoxButtons.OK, MessageBoxIcon.Error); 90 | } 91 | loading.Visible = false; 92 | 93 | 94 | } 95 | } 96 | 97 | // Add or Edit 98 | private bool AddOrEdit(TBDep Data) 99 | { 100 | try 101 | { 102 | db = new DBAREntities(); 103 | db.Set().AddOrUpdate(Data); 104 | db.SaveChanges(); 105 | state = true; 106 | 107 | } 108 | catch { state = false; } 109 | return state; 110 | } 111 | 112 | private void AddDep_FormClosed(object sender, FormClosedEventArgs e) 113 | { 114 | if (start == 1) 115 | { 116 | Application.Exit(); 117 | } 118 | } 119 | } 120 | } -------------------------------------------------------------------------------- /Arshf/Properties/Settings.Designer.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated by a tool. 4 | // Runtime Version:4.0.30319.42000 5 | // 6 | // Changes to this file may cause incorrect behavior and will be lost if 7 | // the code is regenerated. 8 | // 9 | //------------------------------------------------------------------------------ 10 | 11 | namespace Arshf.Properties { 12 | 13 | 14 | [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] 15 | [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "16.10.0.0")] 16 | internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase { 17 | 18 | private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings()))); 19 | 20 | public static Settings Default { 21 | get { 22 | return defaultInstance; 23 | } 24 | } 25 | 26 | [global::System.Configuration.UserScopedSettingAttribute()] 27 | [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] 28 | [global::System.Configuration.DefaultSettingValueAttribute("")] 29 | public string FullName { 30 | get { 31 | return ((string)(this["FullName"])); 32 | } 33 | set { 34 | this["FullName"] = value; 35 | } 36 | } 37 | 38 | [global::System.Configuration.UserScopedSettingAttribute()] 39 | [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] 40 | [global::System.Configuration.DefaultSettingValueAttribute("")] 41 | public string UserName { 42 | get { 43 | return ((string)(this["UserName"])); 44 | } 45 | set { 46 | this["UserName"] = value; 47 | } 48 | } 49 | 50 | [global::System.Configuration.UserScopedSettingAttribute()] 51 | [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] 52 | [global::System.Configuration.DefaultSettingValueAttribute("")] 53 | public string UserDep { 54 | get { 55 | return ((string)(this["UserDep"])); 56 | } 57 | set { 58 | this["UserDep"] = value; 59 | } 60 | } 61 | 62 | [global::System.Configuration.UserScopedSettingAttribute()] 63 | [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] 64 | [global::System.Configuration.DefaultSettingValueAttribute("")] 65 | public string UserRole { 66 | get { 67 | return ((string)(this["UserRole"])); 68 | } 69 | set { 70 | this["UserRole"] = value; 71 | } 72 | } 73 | 74 | [global::System.Configuration.UserScopedSettingAttribute()] 75 | [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] 76 | public int UserID { 77 | get { 78 | return ((int)(this["UserID"])); 79 | } 80 | set { 81 | this["UserID"] = value; 82 | } 83 | } 84 | 85 | [global::System.Configuration.UserScopedSettingAttribute()] 86 | [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] 87 | [global::System.Configuration.DefaultSettingValueAttribute("اسم المؤسسة")] 88 | public string CompanyName { 89 | get { 90 | return ((string)(this["CompanyName"])); 91 | } 92 | set { 93 | this["CompanyName"] = value; 94 | } 95 | } 96 | 97 | [global::System.Configuration.UserScopedSettingAttribute()] 98 | [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] 99 | [global::System.Configuration.DefaultSettingValueAttribute("وصف المؤسسة")] 100 | public string CompanyDes { 101 | get { 102 | return ((string)(this["CompanyDes"])); 103 | } 104 | set { 105 | this["CompanyDes"] = value; 106 | } 107 | } 108 | 109 | [global::System.Configuration.UserScopedSettingAttribute()] 110 | [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] 111 | [global::System.Configuration.DefaultSettingValueAttribute("")] 112 | public string CompanyLogo { 113 | get { 114 | return ((string)(this["CompanyLogo"])); 115 | } 116 | set { 117 | this["CompanyLogo"] = value; 118 | } 119 | } 120 | } 121 | } 122 | -------------------------------------------------------------------------------- /Arshf/PL/Start.Designer.cs: -------------------------------------------------------------------------------- 1 | 2 | namespace Arshf.PL 3 | { 4 | partial class Start 5 | { 6 | /// 7 | /// Required designer variable. 8 | /// 9 | private System.ComponentModel.IContainer components = null; 10 | 11 | /// 12 | /// Clean up any resources being used. 13 | /// 14 | /// true if managed resources should be disposed; otherwise, false. 15 | protected override void Dispose(bool disposing) 16 | { 17 | if (disposing && (components != null)) 18 | { 19 | components.Dispose(); 20 | } 21 | base.Dispose(disposing); 22 | } 23 | 24 | #region Windows Form Designer generated code 25 | 26 | /// 27 | /// Required method for Designer support - do not modify 28 | /// the contents of this method with the code editor. 29 | /// 30 | private void InitializeComponent() 31 | { 32 | System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(Start)); 33 | this.progressBarControl = new DevExpress.XtraEditors.MarqueeProgressBarControl(); 34 | this.labelCopyright = new DevExpress.XtraEditors.LabelControl(); 35 | this.pictureEdit1 = new DevExpress.XtraEditors.PictureEdit(); 36 | this.labelStatus = new DevExpress.XtraEditors.LabelControl(); 37 | ((System.ComponentModel.ISupportInitialize)(this.progressBarControl.Properties)).BeginInit(); 38 | ((System.ComponentModel.ISupportInitialize)(this.pictureEdit1.Properties)).BeginInit(); 39 | this.SuspendLayout(); 40 | // 41 | // progressBarControl 42 | // 43 | this.progressBarControl.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) 44 | | System.Windows.Forms.AnchorStyles.Right))); 45 | this.progressBarControl.EditValue = 0; 46 | this.progressBarControl.Location = new System.Drawing.Point(32, 286); 47 | this.progressBarControl.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4); 48 | this.progressBarControl.Name = "progressBarControl"; 49 | this.progressBarControl.Size = new System.Drawing.Size(536, 15); 50 | this.progressBarControl.TabIndex = 5; 51 | // 52 | // labelCopyright 53 | // 54 | this.labelCopyright.BorderStyle = DevExpress.XtraEditors.Controls.BorderStyles.NoBorder; 55 | this.labelCopyright.Location = new System.Drawing.Point(32, 339); 56 | this.labelCopyright.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4); 57 | this.labelCopyright.Name = "labelCopyright"; 58 | this.labelCopyright.Size = new System.Drawing.Size(54, 16); 59 | this.labelCopyright.TabIndex = 6; 60 | this.labelCopyright.Text = "Copyright"; 61 | // 62 | // pictureEdit1 63 | // 64 | this.pictureEdit1.EditValue = ((object)(resources.GetObject("pictureEdit1.EditValue"))); 65 | this.pictureEdit1.Location = new System.Drawing.Point(-5, 5); 66 | this.pictureEdit1.Name = "pictureEdit1"; 67 | this.pictureEdit1.Properties.BorderStyle = DevExpress.XtraEditors.Controls.BorderStyles.NoBorder; 68 | this.pictureEdit1.Properties.ShowCameraMenuItem = DevExpress.XtraEditors.Controls.CameraMenuItemVisibility.Auto; 69 | this.pictureEdit1.Properties.SizeMode = DevExpress.XtraEditors.Controls.PictureSizeMode.Zoom; 70 | this.pictureEdit1.Size = new System.Drawing.Size(609, 261); 71 | this.pictureEdit1.TabIndex = 8; 72 | // 73 | // labelStatus 74 | // 75 | this.labelStatus.Location = new System.Drawing.Point(515, 264); 76 | this.labelStatus.Margin = new System.Windows.Forms.Padding(4, 4, 4, 1); 77 | this.labelStatus.Name = "labelStatus"; 78 | this.labelStatus.Size = new System.Drawing.Size(43, 17); 79 | this.labelStatus.TabIndex = 7; 80 | this.labelStatus.Text = ".... البدأ"; 81 | // 82 | // Start 83 | // 84 | this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 16F); 85 | this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; 86 | this.ClientSize = new System.Drawing.Size(600, 394); 87 | this.Controls.Add(this.pictureEdit1); 88 | this.Controls.Add(this.labelStatus); 89 | this.Controls.Add(this.labelCopyright); 90 | this.Controls.Add(this.progressBarControl); 91 | this.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4); 92 | this.Name = "Start"; 93 | this.Padding = new System.Windows.Forms.Padding(1); 94 | this.Text = "Start"; 95 | this.Load += new System.EventHandler(this.Start_Load); 96 | ((System.ComponentModel.ISupportInitialize)(this.progressBarControl.Properties)).EndInit(); 97 | ((System.ComponentModel.ISupportInitialize)(this.pictureEdit1.Properties)).EndInit(); 98 | this.ResumeLayout(false); 99 | this.PerformLayout(); 100 | 101 | } 102 | 103 | #endregion 104 | 105 | private DevExpress.XtraEditors.MarqueeProgressBarControl progressBarControl; 106 | private DevExpress.XtraEditors.LabelControl labelCopyright; 107 | private DevExpress.XtraEditors.PictureEdit pictureEdit1; 108 | private DevExpress.XtraEditors.LabelControl labelStatus; 109 | } 110 | } 111 | -------------------------------------------------------------------------------- /Arshf/Properties/Resources.resx: -------------------------------------------------------------------------------- 1 | 2 | 3 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | text/microsoft-resx 107 | 108 | 109 | 2.0 110 | 111 | 112 | System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 113 | 114 | 115 | System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 116 | 117 | -------------------------------------------------------------------------------- /Arshf/Pages/HomePage.resx: -------------------------------------------------------------------------------- 1 | 2 | 3 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | text/microsoft-resx 110 | 111 | 112 | 2.0 113 | 114 | 115 | System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 116 | 117 | 118 | System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 119 | 120 | -------------------------------------------------------------------------------- /Arshf/AddPage/AddNewFileFromHome.resx: -------------------------------------------------------------------------------- 1 | 2 | 3 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | text/microsoft-resx 110 | 111 | 112 | 2.0 113 | 114 | 115 | System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 116 | 117 | 118 | System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 119 | 120 | -------------------------------------------------------------------------------- /Arshf/AddPage/AddUser.cs: -------------------------------------------------------------------------------- 1 | using DevExpress.XtraEditors; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.ComponentModel; 5 | using System.Data; 6 | using System.Data.Entity.Migrations; 7 | using System.Drawing; 8 | using System.Linq; 9 | using System.Text; 10 | using System.Threading; 11 | using System.Threading.Tasks; 12 | using System.Windows.Forms; 13 | 14 | namespace Arshf.AddPage 15 | { 16 | public partial class AddUser : DevExpress.XtraEditors.XtraForm 17 | { 18 | // DataBase and Tables 19 | DBAREntities db; 20 | private List DepNameList; 21 | TBUSER tbadd; 22 | // Other var 23 | public int id; 24 | public int depid; 25 | public Pages.UsersPage page; 26 | bool state; 27 | public int Start; 28 | public AddUser() 29 | { 30 | InitializeComponent(); 31 | } 32 | 33 | private async void btn_add_Click(object sender, EventArgs e) 34 | { 35 | if (edt_name.Text == "" || edt_username.Text == "" || edt_password.Text == "" || edt_dep.SelectedItem==null || edt_role.SelectedItem == null || depid==null) 36 | { 37 | MessageBox.Show("خطأ ادخال", "اكمل الحقول لطفا", MessageBoxButtons.OK, MessageBoxIcon.Information); 38 | } 39 | else 40 | { 41 | // Set Data 42 | // Check if Add or Edit 43 | if (id == 0) 44 | // Add 45 | { 46 | tbadd = new TBUSER 47 | { 48 | IDDep=depid, 49 | FullName = edt_name.Text, 50 | UserName = edt_username.Text, 51 | Password = edt_password.Text, 52 | UserRole = edt_role.Text, 53 | DepName = edt_dep.Text, 54 | }; 55 | } 56 | // Edit 57 | else 58 | { 59 | tbadd = new TBUSER 60 | { 61 | ID=id, 62 | IDDep = depid, 63 | FullName = edt_name.Text, 64 | UserName = edt_username.Text, 65 | Password = edt_password.Text, 66 | UserRole = edt_role.Text, 67 | DepName = edt_dep.Text, 68 | 69 | }; 70 | } 71 | 72 | // loading 73 | loading.Visible=true; 74 | // Add or Edit 75 | var result =await Task.Run(()=> AddOrEdit(tbadd)); 76 | if (result == true) 77 | { 78 | 79 | toastNotificationsManager1.ShowNotification("96616aac-b9fe-45d7-8bb1-5cd04f388f4c"); 80 | if (Start == 1) 81 | { 82 | Start = 0; 83 | Application.Restart(); 84 | } 85 | else 86 | { 87 | // Reload Data 88 | page.LoadData(); 89 | } 90 | Close(); 91 | } 92 | else 93 | { 94 | MessageBox.Show("خطأ في الاتصال", "تأكد من الاتصال في السيرفر لطفا", MessageBoxButtons.OK, MessageBoxIcon.Error); 95 | } 96 | loading.Visible = false; 97 | 98 | 99 | } 100 | } 101 | 102 | // Add or Edit 103 | private bool AddOrEdit(TBUSER Data) 104 | { 105 | try 106 | { 107 | db = new DBAREntities(); 108 | db.Set().AddOrUpdate(Data); 109 | db.SaveChanges(); 110 | state = true; 111 | 112 | } 113 | catch { state = false; } 114 | return state; 115 | } 116 | 117 | private bool LoadDepName() 118 | { 119 | try 120 | { 121 | db = new DBAREntities(); 122 | DepNameList = db.TBDeps.Select(x => x.DepName).ToList(); 123 | state = true; 124 | 125 | } 126 | catch 127 | { 128 | state = false; 129 | } 130 | return state; 131 | } 132 | 133 | private async void AddUser_Load(object sender, EventArgs e) 134 | { 135 | loading.Visible = true; 136 | var rs= await Task.Run(() => LoadDepName()); 137 | if (rs == true) 138 | { 139 | edt_dep.DataSource = DepNameList; 140 | } 141 | else 142 | { 143 | MessageBox.Show("خطأ في الاتصال", "تأكد من الاتصال في السيرفر لطفا", MessageBoxButtons.OK, MessageBoxIcon.Error); 144 | 145 | } 146 | loading.Visible = false; 147 | 148 | } 149 | 150 | private async void edt_dep_SelectedIndexChanged(object sender, EventArgs e) 151 | { 152 | loading.Visible = true; 153 | var depName = edt_dep.Text; 154 | var rs = await Task.Run(() => LoadDepId(depName)); 155 | if (rs == false) 156 | { 157 | MessageBox.Show("خطأ في الاتصال", "تأكد من الاتصال في السيرفر لطفا", MessageBoxButtons.OK, MessageBoxIcon.Error); 158 | 159 | } 160 | 161 | 162 | 163 | loading.Visible = false; 164 | } 165 | 166 | private bool LoadDepId(string DepName) 167 | { 168 | try 169 | { 170 | db = new DBAREntities(); 171 | depid = db.TBDeps.Where(X => X.DepName == DepName).Select(x => x.ID).FirstOrDefault(); 172 | state = true; 173 | 174 | } 175 | catch 176 | { 177 | state = false; 178 | } 179 | return state; 180 | } 181 | 182 | private void AddUser_FormClosed(object sender, FormClosedEventArgs e) 183 | { 184 | if (Start == 1) 185 | { 186 | Application.Exit(); 187 | } 188 | } 189 | } 190 | } -------------------------------------------------------------------------------- /Arshf/Pages/DepPage.cs: -------------------------------------------------------------------------------- 1 | using DevExpress.XtraEditors; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.ComponentModel; 5 | using System.Data; 6 | using System.Drawing; 7 | using System.Linq; 8 | using System.Text; 9 | using System.Threading.Tasks; 10 | using System.Windows.Forms; 11 | 12 | namespace Arshf.Pages 13 | { 14 | public partial class DepPage : DevExpress.XtraEditors.XtraUserControl 15 | { 16 | // DataBase and Tables 17 | private DBAREntities db; 18 | TBDep tbadd; 19 | // other var 20 | int id; 21 | private bool state; 22 | 23 | public DepPage() 24 | { 25 | InitializeComponent(); 26 | LoadData(); 27 | } 28 | 29 | // Load Data 30 | public void LoadData() 31 | { 32 | // This line of code is generated by Data Source Configuration Wizard 33 | this.entityInstantFeedbackSource1.GetQueryable += entityInstantFeedbackSource1_GetQueryable; 34 | // This line of code is generated by Data Source Configuration Wizard 35 | this.entityInstantFeedbackSource1.DismissQueryable += entityInstantFeedbackSource1_DismissQueryable; 36 | this.entityInstantFeedbackSource1.Refresh(); 37 | } 38 | // This event is generated by Data Source Configuration Wizard 39 | void entityInstantFeedbackSource1_GetQueryable(object sender, DevExpress.Data.Linq.GetQueryableEventArgs e) 40 | { 41 | // Instantiate a new DataContext 42 | Arshf.DBAREntities dataContext = new Arshf.DBAREntities(); 43 | // Assign a queryable source to the EntityInstantFeedbackSource 44 | e.QueryableSource = dataContext.TBDeps; 45 | // Assign the DataContext to the Tag property, 46 | // to dispose of it in the DismissQueryable event handler 47 | e.Tag = dataContext; 48 | } 49 | 50 | // This event is generated by Data Source Configuration Wizard 51 | void entityInstantFeedbackSource1_DismissQueryable(object sender, DevExpress.Data.Linq.GetQueryableEventArgs e) 52 | { 53 | // Dispose of the DataContext 54 | ((Arshf.DBAREntities)e.Tag).Dispose(); 55 | } 56 | 57 | // Add 58 | private void btn_add_Click(object sender, EventArgs e) 59 | { 60 | AddPage.AddDep add = new AddPage.AddDep(); 61 | add.btn_add.Text = "اضافة"; 62 | add.id = 0; 63 | add.page = this; 64 | add.Show(); 65 | } 66 | 67 | // Edit 68 | private void btn_edit_Click(object sender, EventArgs e) 69 | { 70 | try 71 | { 72 | id = Convert.ToInt32(gridView1.GetFocusedRowCellValue("ID")); 73 | if (id > 0) 74 | { 75 | // Edit 76 | AddPage.AddDep add = new AddPage.AddDep(); 77 | add.btn_add.Text = "تعديل"; 78 | add.id = id; 79 | add.edt_name.Text = Convert.ToString(gridView1.GetFocusedRowCellValue("DepName")); 80 | add.edt_details.Text = Convert.ToString(gridView1.GetFocusedRowCellValue("DepDetails")); 81 | add.page = this; 82 | add.Show(); 83 | } 84 | else 85 | { 86 | MessageBox.Show("لا بيانات لتعديلها"); 87 | } 88 | } 89 | catch(Exception ex) 90 | { 91 | MessageBox.Show("خطأ في العملية", ex.Message, MessageBoxButtons.OK, MessageBoxIcon.Error); 92 | 93 | } 94 | 95 | 96 | } 97 | 98 | // Delete 99 | private async void btn_delete_Click(object sender, EventArgs e) 100 | { 101 | try 102 | { 103 | id = Convert.ToInt32(gridView1.GetFocusedRowCellValue("ID")); 104 | if (id > 0) 105 | { 106 | var result = MessageBox.Show("اجراء حذف", "هل انت متأكد من هذا الاجراء", MessageBoxButtons.YesNo, MessageBoxIcon.Question); 107 | if (result == DialogResult.Yes) 108 | { 109 | // Delete 110 | // Loading 111 | loading.Visible = true; 112 | tbadd = new TBDep 113 | { 114 | ID = id, 115 | }; 116 | var rs = await Task.Run(() => Delete(tbadd)); 117 | if (rs == true) 118 | { 119 | LoadData(); 120 | toastNotificationsManager1.ShowNotification("96616aac-b9fe-45d7-8bb1-5cd04f388f4c"); 121 | 122 | } 123 | else 124 | { 125 | MessageBox.Show("خطأ في الاتصال", "تأكد من الاتصال في السيرفر لطفا", MessageBoxButtons.OK, MessageBoxIcon.Error); 126 | 127 | } 128 | //End 129 | loading.Visible = false; 130 | } 131 | 132 | 133 | 134 | } 135 | else 136 | { 137 | MessageBox.Show("لا بيانات لحذفها"); 138 | } 139 | } 140 | catch (Exception ex) 141 | { 142 | MessageBox.Show("خطأ في العملية", ex.Message, MessageBoxButtons.OK, MessageBoxIcon.Error); 143 | 144 | } 145 | 146 | } 147 | 148 | // Delete Method 149 | private bool Delete(TBDep Data) 150 | { 151 | try 152 | { 153 | db = new DBAREntities(); 154 | db.Entry(Data).State = System.Data.Entity.EntityState.Deleted; 155 | db.SaveChanges(); 156 | state = true; 157 | 158 | } 159 | catch { state = false; } 160 | return state; 161 | } 162 | 163 | // Print 164 | private void btn_print_Click(object sender, EventArgs e) 165 | { 166 | gridControl1.ShowPrintPreview(); 167 | } 168 | 169 | private void DepPage_Leave(object sender, EventArgs e) 170 | { 171 | } 172 | } 173 | } 174 | -------------------------------------------------------------------------------- /Arshf/Pages/UsersPage.cs: -------------------------------------------------------------------------------- 1 | using DevExpress.XtraEditors; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.ComponentModel; 5 | using System.Data; 6 | using System.Drawing; 7 | using System.Linq; 8 | using System.Text; 9 | using System.Threading.Tasks; 10 | using System.Windows.Forms; 11 | 12 | namespace Arshf.Pages 13 | { 14 | public partial class UsersPage : DevExpress.XtraEditors.XtraUserControl 15 | { 16 | // DataBase and Tables 17 | private DBAREntities db; 18 | TBUSER tbadd; 19 | // other var 20 | int id; 21 | private bool state; 22 | 23 | public UsersPage() 24 | { 25 | db = new DBAREntities(); 26 | InitializeComponent(); 27 | LoadData(); 28 | 29 | } 30 | 31 | // Load Data 32 | public void LoadData() 33 | { 34 | // This line of code is generated by Data Source Configuration Wizard 35 | this.entityInstantFeedbackSource2.GetQueryable += entityInstantFeedbackSource2_GetQueryable; 36 | // This line of code is generated by Data Source Configuration Wizard 37 | this.entityInstantFeedbackSource2.DismissQueryable += entityInstantFeedbackSource2_DismissQueryable; 38 | this.entityInstantFeedbackSource2.Refresh(); 39 | } 40 | 41 | 42 | // Add 43 | private void btn_add_Click(object sender, EventArgs e) 44 | { 45 | AddPage.AddUser add = new AddPage.AddUser(); 46 | add.btn_add.Text = "اضافة"; 47 | add.id = 0; 48 | add.page = this; 49 | add.Show(); 50 | } 51 | 52 | // Edit 53 | private void btn_edit_Click(object sender, EventArgs e) 54 | { 55 | try 56 | { 57 | id = Convert.ToInt32(gridView1.GetFocusedRowCellValue("ID")); 58 | if (id > 0) 59 | { 60 | // Edit 61 | AddPage.AddUser add = new AddPage.AddUser(); 62 | add.btn_add.Text = "تعديل"; 63 | add.id = id; 64 | add.depid = Convert.ToInt32(gridView1.GetFocusedRowCellValue("IDDep")); 65 | add.edt_name.Text = Convert.ToString(gridView1.GetFocusedRowCellValue("FullName")); 66 | add.edt_username.Text = Convert.ToString(gridView1.GetFocusedRowCellValue("UserName")); 67 | add.edt_password.Text = Convert.ToString(gridView1.GetFocusedRowCellValue("Password")); 68 | add.edt_role.Text = Convert.ToString(gridView1.GetFocusedRowCellValue("UserRole")); 69 | add.edt_dep.Text = Convert.ToString(gridView1.GetFocusedRowCellValue("DepName")); 70 | add.page = this; 71 | add.Show(); 72 | } 73 | else 74 | { 75 | MessageBox.Show("لا بيانات لتعديلها"); 76 | } 77 | } 78 | catch(Exception ex) 79 | { 80 | MessageBox.Show("خطأ في العملية", ex.Message, MessageBoxButtons.OK, MessageBoxIcon.Error); 81 | 82 | } 83 | 84 | 85 | } 86 | 87 | // Delete 88 | private async void btn_delete_Click(object sender, EventArgs e) 89 | { 90 | try 91 | { 92 | id = Convert.ToInt32(gridView1.GetFocusedRowCellValue("ID")); 93 | if (id > 0) 94 | { 95 | var result = MessageBox.Show("اجراء حذف", "هل انت متأكد من هذا الاجراء", MessageBoxButtons.YesNo, MessageBoxIcon.Question); 96 | if (result == DialogResult.Yes) 97 | { 98 | // Delete 99 | // Loading 100 | loading.Visible = true; 101 | tbadd = new TBUSER 102 | { 103 | ID = id, 104 | }; 105 | var rs = await Task.Run(() => Delete(tbadd)); 106 | if (rs == true) 107 | { 108 | LoadData(); 109 | toastNotificationsManager1.ShowNotification("96616aac-b9fe-45d7-8bb1-5cd04f388f4c"); 110 | 111 | } 112 | else 113 | { 114 | MessageBox.Show("خطأ في الاتصال", "تأكد من الاتصال في السيرفر لطفا", MessageBoxButtons.OK, MessageBoxIcon.Error); 115 | 116 | } 117 | //End 118 | loading.Visible = false; 119 | } 120 | 121 | 122 | 123 | } 124 | else 125 | { 126 | MessageBox.Show("لا بيانات لحذفها"); 127 | } 128 | } 129 | catch (Exception ex) 130 | { 131 | MessageBox.Show("خطأ في العملية", ex.Message, MessageBoxButtons.OK, MessageBoxIcon.Error); 132 | 133 | } 134 | 135 | } 136 | 137 | // Delete Method 138 | private bool Delete(TBUSER Data) 139 | { 140 | try 141 | { 142 | db.Entry(Data).State = System.Data.Entity.EntityState.Deleted; 143 | db.SaveChanges(); 144 | state = true; 145 | 146 | } 147 | catch { state = false; } 148 | return state; 149 | } 150 | 151 | // Print 152 | private void btn_print_Click(object sender, EventArgs e) 153 | { 154 | gridControl1.ShowPrintPreview(); 155 | } 156 | 157 | // This event is generated by Data Source Configuration Wizard 158 | void entityInstantFeedbackSource2_GetQueryable(object sender, DevExpress.Data.Linq.GetQueryableEventArgs e) 159 | { 160 | // Instantiate a new DataContext 161 | Arshf.DBAREntities dataContext = new Arshf.DBAREntities(); 162 | // Assign a queryable source to the EntityInstantFeedbackSource 163 | e.QueryableSource = dataContext.TBUSERS; 164 | // Assign the DataContext to the Tag property, 165 | // to dispose of it in the DismissQueryable event handler 166 | e.Tag = dataContext; 167 | } 168 | 169 | // This event is generated by Data Source Configuration Wizard 170 | void entityInstantFeedbackSource2_DismissQueryable(object sender, DevExpress.Data.Linq.GetQueryableEventArgs e) 171 | { 172 | // Dispose of the DataContext 173 | ((Arshf.DBAREntities)e.Tag).Dispose(); 174 | } 175 | 176 | private void simpleButton1_Click(object sender, EventArgs e) 177 | { 178 | Properties.Settings.Default.UserID = Convert.ToInt32(gridView1.GetFocusedRowCellValue("ID")); 179 | 180 | Properties.Settings.Default.FullName = Convert.ToString(gridView1.GetFocusedRowCellValue("FullName")); 181 | Properties.Settings.Default.UserName = Convert.ToString(gridView1.GetFocusedRowCellValue("UserName")); 182 | Properties.Settings.Default.UserRole = Convert.ToString(gridView1.GetFocusedRowCellValue("UserRole")); 183 | Properties.Settings.Default.UserDep = Convert.ToString(gridView1.GetFocusedRowCellValue("DepName")); 184 | Properties.Settings.Default.Save(); 185 | } 186 | } 187 | } 188 | -------------------------------------------------------------------------------- /Arshf/Pages/ArchiveCatPage.cs: -------------------------------------------------------------------------------- 1 | using DevExpress.XtraEditors; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.ComponentModel; 5 | using System.Data; 6 | using System.Drawing; 7 | using System.Linq; 8 | using System.Text; 9 | using System.Threading.Tasks; 10 | using System.Windows.Forms; 11 | 12 | namespace Arshf.Pages 13 | { 14 | public partial class ArchiveCatPage : DevExpress.XtraEditors.XtraUserControl 15 | { 16 | // DataBase and Tables 17 | private DBAREntities db; 18 | TBArchiveCategory tbadd; 19 | // other var 20 | int id; 21 | private bool state; 22 | private string UserRole; 23 | private string UserDep; 24 | 25 | public ArchiveCatPage() 26 | { 27 | InitializeComponent(); 28 | UserRole = Properties.Settings.Default.UserRole; 29 | UserDep = Properties.Settings.Default.UserDep; 30 | LoadData(); 31 | } 32 | 33 | // Load Data 34 | public void LoadData() 35 | { 36 | // This line of code is generated by Data Source Configuration Wizard 37 | this.entityInstantFeedbackSource1.GetQueryable += entityInstantFeedbackSource1_GetQueryable; 38 | // This line of code is generated by Data Source Configuration Wizard 39 | this.entityInstantFeedbackSource1.DismissQueryable += entityInstantFeedbackSource1_DismissQueryable; 40 | this.entityInstantFeedbackSource1.Refresh(); 41 | } 42 | // This event is generated by Data Source Configuration Wizard 43 | void entityInstantFeedbackSource1_GetQueryable(object sender, DevExpress.Data.Linq.GetQueryableEventArgs e) 44 | { 45 | // Instantiate a new DataContext 46 | Arshf.DBAREntities dataContext = new Arshf.DBAREntities(); 47 | // User Role = مدير 48 | if (UserRole == "مدير") 49 | { 50 | e.QueryableSource = dataContext.TBArchiveCategories; 51 | 52 | } 53 | else 54 | { 55 | e.QueryableSource = dataContext.TBArchiveCategories.Where(x=>x.UserDep==UserDep); 56 | 57 | } 58 | // to dispose of it in the DismissQueryable event handler 59 | e.Tag = dataContext; 60 | } 61 | 62 | // This event is generated by Data Source Configuration Wizard 63 | void entityInstantFeedbackSource1_DismissQueryable(object sender, DevExpress.Data.Linq.GetQueryableEventArgs e) 64 | { 65 | // Dispose of the DataContext 66 | ((Arshf.DBAREntities)e.Tag).Dispose(); 67 | } 68 | 69 | // Add 70 | private void btn_add_Click(object sender, EventArgs e) 71 | { 72 | AddPage.AddArchiveCategory add = new AddPage.AddArchiveCategory(); 73 | add.btn_add.Text = "اضافة"; 74 | add.id = 0; 75 | add.page = this; 76 | add.Show(); 77 | } 78 | 79 | // Edit 80 | private void btn_edit_Click(object sender, EventArgs e) 81 | { 82 | try 83 | { 84 | id = Convert.ToInt32(tileView1.GetFocusedRowCellValue("ID")); 85 | if (id > 0) 86 | { 87 | // Edit 88 | AddPage.AddArchiveCategory add = new AddPage.AddArchiveCategory(); 89 | add.btn_add.Text = "تعديل"; 90 | add.id = id; 91 | add.edt_name.Text = Convert.ToString(tileView1.GetFocusedRowCellValue("ArchiveTitle")); 92 | add.edt_details.Text = Convert.ToString(tileView1.GetFocusedRowCellValue("ArchiveDes")); 93 | add.page = this; 94 | add.Show(); 95 | } 96 | else 97 | { 98 | MessageBox.Show("لا بيانات لتعديلها"); 99 | } 100 | } 101 | catch(Exception ex) 102 | { 103 | MessageBox.Show("خطأ في العملية", ex.Message, MessageBoxButtons.OK, MessageBoxIcon.Error); 104 | 105 | } 106 | 107 | 108 | } 109 | 110 | // Delete 111 | private async void btn_delete_Click(object sender, EventArgs e) 112 | { 113 | try 114 | { 115 | id = Convert.ToInt32(tileView1.GetFocusedRowCellValue("ID")); 116 | if (id > 0) 117 | { 118 | var result = MessageBox.Show("اجراء حذف", "هل انت متأكد من هذا الاجراء", MessageBoxButtons.YesNo, MessageBoxIcon.Question); 119 | if (result == DialogResult.Yes) 120 | { 121 | // Delete 122 | // Loading 123 | loading.Visible = true; 124 | tbadd = new TBArchiveCategory 125 | { 126 | ID = id, 127 | }; 128 | var rs = await Task.Run(() => Delete(tbadd)); 129 | if (rs == true) 130 | { 131 | LoadData(); 132 | toastNotificationsManager1.ShowNotification("96616aac-b9fe-45d7-8bb1-5cd04f388f4c"); 133 | 134 | } 135 | else 136 | { 137 | MessageBox.Show("خطأ في الاتصال", "تأكد من الاتصال في السيرفر لطفا", MessageBoxButtons.OK, MessageBoxIcon.Error); 138 | 139 | } 140 | //End 141 | loading.Visible = false; 142 | } 143 | 144 | 145 | 146 | } 147 | else 148 | { 149 | MessageBox.Show("لا بيانات لحذفها"); 150 | } 151 | } 152 | catch (Exception ex) 153 | { 154 | MessageBox.Show("خطأ في العملية", ex.Message, MessageBoxButtons.OK, MessageBoxIcon.Error); 155 | 156 | } 157 | 158 | } 159 | 160 | // Delete Method 161 | private bool Delete(TBArchiveCategory Data) 162 | { 163 | try 164 | { 165 | db = new DBAREntities(); 166 | db.Entry(Data).State = System.Data.Entity.EntityState.Deleted; 167 | db.SaveChanges(); 168 | state = true; 169 | 170 | } 171 | catch { state = false; } 172 | return state; 173 | } 174 | 175 | // Print 176 | private void btn_print_Click(object sender, EventArgs e) 177 | { 178 | gridControl1.ShowPrintPreview(); 179 | } 180 | 181 | private void tileView1_ItemDoubleClick(object sender, DevExpress.XtraGrid.Views.Tile.TileViewItemClickEventArgs e) 182 | { 183 | try 184 | { 185 | PL.ArchiveFileForm archive = new PL.ArchiveFileForm(); 186 | id = Convert.ToInt32(tileView1.GetFocusedRowCellValue("ID")); 187 | archive.lb_id.Text = id.ToString(); 188 | archive.ArchiveID = id; 189 | archive.lb_archivename.Text = Convert.ToString(tileView1.GetFocusedRowCellValue("ArchiveTitle")); 190 | archive.lb_archdep.Text = Convert.ToString(tileView1.GetFocusedRowCellValue("UserDep")); 191 | archive.Show(); 192 | 193 | 194 | } 195 | catch { } 196 | } 197 | } 198 | } 199 | -------------------------------------------------------------------------------- /Arshf/PL/SearchResults.cs: -------------------------------------------------------------------------------- 1 | using DevExpress.XtraEditors; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.ComponentModel; 5 | using System.Data; 6 | using System.Drawing; 7 | using System.Linq; 8 | using System.Text; 9 | using System.Threading.Tasks; 10 | using System.Windows.Forms; 11 | 12 | namespace Arshf.PL 13 | { 14 | public partial class SearchResults : DevExpress.XtraEditors.XtraForm 15 | { 16 | // Data Base and Tables 17 | TBArchiveFile tbadd; 18 | DBAREntities db; 19 | // other var 20 | public int ArchiveID; 21 | private int id; 22 | private bool state; 23 | public string SeachText; 24 | string DepName; 25 | string UserRole; 26 | 27 | public SearchResults() 28 | { 29 | InitializeComponent(); 30 | DepName = Properties.Settings.Default.UserDep; 31 | UserRole = Properties.Settings.Default.UserRole; 32 | 33 | 34 | LoadData(); 35 | 36 | 37 | 38 | } 39 | 40 | public void LoadData() 41 | { 42 | // This line of code is generated by Data Source Configuration Wizard 43 | this.entityInstantFeedbackSource1.GetQueryable += entityInstantFeedbackSource1_GetQueryable; 44 | // This line of code is generated by Data Source Configuration Wizard 45 | this.entityInstantFeedbackSource1.DismissQueryable += entityInstantFeedbackSource1_DismissQueryable; 46 | this.entityInstantFeedbackSource1.Refresh(); 47 | } 48 | 49 | // This event is generated by Data Source Configuration Wizard 50 | void entityInstantFeedbackSource1_GetQueryable(object sender, DevExpress.Data.Linq.GetQueryableEventArgs e) 51 | { 52 | // Instantiate a new DataContext 53 | Arshf.DBAREntities dataContext = new Arshf.DBAREntities(); 54 | // Assign a queryable source to the EntityInstantFeedbackSource 55 | if (UserRole == "مدير") 56 | { 57 | e.QueryableSource = dataContext.TBArchiveFiles.Where(x => x.ArchNumber.Contains(SeachText) || x.ArchTitle.Contains(SeachText) || x.ArchReciver.Contains(SeachText) || x.ArchSender.Contains(SeachText)) 58 | .Select(x => new 59 | { 60 | x.ID, 61 | x.IDArchive, 62 | x.AddDate, 63 | x.ArchDate, 64 | x.ArchDep, 65 | x.ArchDetails, 66 | x.ArchNumber, 67 | x.ArchReciver, 68 | x.ArchSender, 69 | x.ArchTitle 70 | }); 71 | // to dispose of it in the DismissQueryable event handler 72 | e.Tag = dataContext; 73 | } 74 | else 75 | { 76 | e.QueryableSource = dataContext.TBArchiveFiles.Where(x=>x.ArchDep==DepName).Where(x => x.ArchNumber.Contains(SeachText) || x.ArchTitle.Contains(SeachText) || x.ArchReciver.Contains(SeachText) || x.ArchSender.Contains(SeachText)) 77 | .Select(x => new 78 | { 79 | x.ID, 80 | x.IDArchive, 81 | x.AddDate, 82 | x.ArchDate, 83 | x.ArchDep, 84 | x.ArchDetails, 85 | x.ArchNumber, 86 | x.ArchReciver, 87 | x.ArchSender, 88 | x.ArchTitle 89 | }); 90 | // to dispose of it in the DismissQueryable event handler 91 | e.Tag = dataContext; 92 | } 93 | 94 | } 95 | 96 | // This event is generated by Data Source Configuration Wizard 97 | void entityInstantFeedbackSource1_DismissQueryable(object sender, DevExpress.Data.Linq.GetQueryableEventArgs e) 98 | { 99 | // Dispose of the DataContext 100 | ((Arshf.DBAREntities)e.Tag).Dispose(); 101 | } 102 | 103 | 104 | private void btn_add_Click(object sender, EventArgs e) 105 | { 106 | 107 | } 108 | 109 | private void btn_edit_Click(object sender, EventArgs e) 110 | { 111 | 112 | } 113 | 114 | private async void btn_delete_Click(object sender, EventArgs e) 115 | { 116 | try 117 | { 118 | id = Convert.ToInt32(gridView1.GetFocusedRowCellValue("ID")); 119 | if (id > 0) 120 | { 121 | var result = MessageBox.Show("اجراء حذف", "هل انت متأكد من هذا الاجراء", MessageBoxButtons.YesNo, MessageBoxIcon.Question); 122 | if (result == DialogResult.Yes) 123 | { 124 | // Delete 125 | // Loading 126 | loading.Visible = true; 127 | tbadd = new TBArchiveFile 128 | { 129 | ID = id, 130 | }; 131 | var rs = await Task.Run(() => Delete(tbadd)); 132 | if (rs == true) 133 | { 134 | LoadData(); 135 | toastNotificationsManager1.ShowNotification("96616aac-b9fe-45d7-8bb1-5cd04f388f4c"); 136 | 137 | } 138 | else 139 | { 140 | MessageBox.Show("خطأ في الاتصال", "تأكد من الاتصال في السيرفر لطفا", MessageBoxButtons.OK, MessageBoxIcon.Error); 141 | 142 | } 143 | //End 144 | loading.Visible = false; 145 | } 146 | 147 | 148 | 149 | } 150 | else 151 | { 152 | MessageBox.Show("لا بيانات لحذفها"); 153 | } 154 | } 155 | catch (Exception ex) 156 | { 157 | MessageBox.Show("خطأ في العملية", ex.Message, MessageBoxButtons.OK, MessageBoxIcon.Error); 158 | 159 | } 160 | } 161 | // Delete Method 162 | private bool Delete(TBArchiveFile Data) 163 | { 164 | try 165 | { 166 | db = new DBAREntities(); 167 | db.Entry(Data).State = System.Data.Entity.EntityState.Deleted; 168 | db.SaveChanges(); 169 | state = true; 170 | 171 | } 172 | catch { state = false; } 173 | return state; 174 | } 175 | 176 | private void btn_print_Click(object sender, EventArgs e) 177 | { 178 | gridControl1.ShowPrintPreview(); 179 | } 180 | 181 | private void btn_showfiles_Click(object sender, EventArgs e) 182 | { 183 | try 184 | { 185 | id = Convert.ToInt32(gridView1.GetFocusedRowCellValue("ID")); 186 | if (id > 0) 187 | { 188 | 189 | 190 | PL.ShowFiles files = new ShowFiles(); 191 | files.id = id; 192 | files.Show(); 193 | 194 | 195 | } 196 | else 197 | { 198 | MessageBox.Show("لا بيانات "); 199 | } 200 | } 201 | catch (Exception ex) 202 | { 203 | MessageBox.Show("خطأ في العملية", ex.Message, MessageBoxButtons.OK, MessageBoxIcon.Error); 204 | 205 | } 206 | 207 | } 208 | } 209 | } -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | ## Ignore Visual Studio temporary files, build results, and 2 | ## files generated by popular Visual Studio add-ons. 3 | ## 4 | ## Get latest from https://github.com/github/gitignore/blob/master/VisualStudio.gitignore 5 | 6 | # User-specific files 7 | *.rsuser 8 | *.suo 9 | *.user 10 | *.userosscache 11 | *.sln.docstates 12 | 13 | # User-specific files (MonoDevelop/Xamarin Studio) 14 | *.userprefs 15 | 16 | # Mono auto generated files 17 | mono_crash.* 18 | 19 | # Build results 20 | [Dd]ebug/ 21 | [Dd]ebugPublic/ 22 | [Rr]elease/ 23 | [Rr]eleases/ 24 | x64/ 25 | x86/ 26 | [Ww][Ii][Nn]32/ 27 | [Aa][Rr][Mm]/ 28 | [Aa][Rr][Mm]64/ 29 | bld/ 30 | [Bb]in/ 31 | [Oo]bj/ 32 | [Oo]ut/ 33 | [Ll]og/ 34 | [Ll]ogs/ 35 | 36 | # Visual Studio 2015/2017 cache/options directory 37 | .vs/ 38 | # Uncomment if you have tasks that create the project's static files in wwwroot 39 | #wwwroot/ 40 | 41 | # Visual Studio 2017 auto generated files 42 | Generated\ Files/ 43 | 44 | # MSTest test Results 45 | [Tt]est[Rr]esult*/ 46 | [Bb]uild[Ll]og.* 47 | 48 | # NUnit 49 | *.VisualState.xml 50 | TestResult.xml 51 | nunit-*.xml 52 | 53 | # Build Results of an ATL Project 54 | [Dd]ebugPS/ 55 | [Rr]eleasePS/ 56 | dlldata.c 57 | 58 | # Benchmark Results 59 | BenchmarkDotNet.Artifacts/ 60 | 61 | # .NET Core 62 | project.lock.json 63 | project.fragment.lock.json 64 | artifacts/ 65 | 66 | # ASP.NET Scaffolding 67 | ScaffoldingReadMe.txt 68 | 69 | # StyleCop 70 | StyleCopReport.xml 71 | 72 | # Files built by Visual Studio 73 | *_i.c 74 | *_p.c 75 | *_h.h 76 | *.ilk 77 | *.meta 78 | *.obj 79 | *.iobj 80 | *.pch 81 | *.pdb 82 | *.ipdb 83 | *.pgc 84 | *.pgd 85 | *.rsp 86 | *.sbr 87 | *.tlb 88 | *.tli 89 | *.tlh 90 | *.tmp 91 | *.tmp_proj 92 | *_wpftmp.csproj 93 | *.log 94 | *.vspscc 95 | *.vssscc 96 | .builds 97 | *.pidb 98 | *.svclog 99 | *.scc 100 | 101 | # Chutzpah Test files 102 | _Chutzpah* 103 | 104 | # Visual C++ cache files 105 | ipch/ 106 | *.aps 107 | *.ncb 108 | *.opendb 109 | *.opensdf 110 | *.sdf 111 | *.cachefile 112 | *.VC.db 113 | *.VC.VC.opendb 114 | 115 | # Visual Studio profiler 116 | *.psess 117 | *.vsp 118 | *.vspx 119 | *.sap 120 | 121 | # Visual Studio Trace Files 122 | *.e2e 123 | 124 | # TFS 2012 Local Workspace 125 | $tf/ 126 | 127 | # Guidance Automation Toolkit 128 | *.gpState 129 | 130 | # ReSharper is a .NET coding add-in 131 | _ReSharper*/ 132 | *.[Rr]e[Ss]harper 133 | *.DotSettings.user 134 | 135 | # TeamCity is a build add-in 136 | _TeamCity* 137 | 138 | # DotCover is a Code Coverage Tool 139 | *.dotCover 140 | 141 | # AxoCover is a Code Coverage Tool 142 | .axoCover/* 143 | !.axoCover/settings.json 144 | 145 | # Coverlet is a free, cross platform Code Coverage Tool 146 | coverage*.json 147 | coverage*.xml 148 | coverage*.info 149 | 150 | # Visual Studio code coverage results 151 | *.coverage 152 | *.coveragexml 153 | 154 | # NCrunch 155 | _NCrunch_* 156 | .*crunch*.local.xml 157 | nCrunchTemp_* 158 | 159 | # MightyMoose 160 | *.mm.* 161 | AutoTest.Net/ 162 | 163 | # Web workbench (sass) 164 | .sass-cache/ 165 | 166 | # Installshield output folder 167 | [Ee]xpress/ 168 | 169 | # DocProject is a documentation generator add-in 170 | DocProject/buildhelp/ 171 | DocProject/Help/*.HxT 172 | DocProject/Help/*.HxC 173 | DocProject/Help/*.hhc 174 | DocProject/Help/*.hhk 175 | DocProject/Help/*.hhp 176 | DocProject/Help/Html2 177 | DocProject/Help/html 178 | 179 | # Click-Once directory 180 | publish/ 181 | 182 | # Publish Web Output 183 | *.[Pp]ublish.xml 184 | *.azurePubxml 185 | # Note: Comment the next line if you want to checkin your web deploy settings, 186 | # but database connection strings (with potential passwords) will be unencrypted 187 | *.pubxml 188 | *.publishproj 189 | 190 | # Microsoft Azure Web App publish settings. Comment the next line if you want to 191 | # checkin your Azure Web App publish settings, but sensitive information contained 192 | # in these scripts will be unencrypted 193 | PublishScripts/ 194 | 195 | # NuGet Packages 196 | *.nupkg 197 | # NuGet Symbol Packages 198 | *.snupkg 199 | # The packages folder can be ignored because of Package Restore 200 | **/[Pp]ackages/* 201 | # except build/, which is used as an MSBuild target. 202 | !**/[Pp]ackages/build/ 203 | # Uncomment if necessary however generally it will be regenerated when needed 204 | #!**/[Pp]ackages/repositories.config 205 | # NuGet v3's project.json files produces more ignorable files 206 | *.nuget.props 207 | *.nuget.targets 208 | 209 | # Microsoft Azure Build Output 210 | csx/ 211 | *.build.csdef 212 | 213 | # Microsoft Azure Emulator 214 | ecf/ 215 | rcf/ 216 | 217 | # Windows Store app package directories and files 218 | AppPackages/ 219 | BundleArtifacts/ 220 | Package.StoreAssociation.xml 221 | _pkginfo.txt 222 | *.appx 223 | *.appxbundle 224 | *.appxupload 225 | 226 | # Visual Studio cache files 227 | # files ending in .cache can be ignored 228 | *.[Cc]ache 229 | # but keep track of directories ending in .cache 230 | !?*.[Cc]ache/ 231 | 232 | # Others 233 | ClientBin/ 234 | ~$* 235 | *~ 236 | *.dbmdl 237 | *.dbproj.schemaview 238 | *.jfm 239 | *.pfx 240 | *.publishsettings 241 | orleans.codegen.cs 242 | 243 | # Including strong name files can present a security risk 244 | # (https://github.com/github/gitignore/pull/2483#issue-259490424) 245 | #*.snk 246 | 247 | # Since there are multiple workflows, uncomment next line to ignore bower_components 248 | # (https://github.com/github/gitignore/pull/1529#issuecomment-104372622) 249 | #bower_components/ 250 | 251 | # RIA/Silverlight projects 252 | Generated_Code/ 253 | 254 | # Backup & report files from converting an old project file 255 | # to a newer Visual Studio version. Backup files are not needed, 256 | # because we have git ;-) 257 | _UpgradeReport_Files/ 258 | Backup*/ 259 | UpgradeLog*.XML 260 | UpgradeLog*.htm 261 | ServiceFabricBackup/ 262 | *.rptproj.bak 263 | 264 | # SQL Server files 265 | *.mdf 266 | *.ldf 267 | *.ndf 268 | 269 | # Business Intelligence projects 270 | *.rdl.data 271 | *.bim.layout 272 | *.bim_*.settings 273 | *.rptproj.rsuser 274 | *- [Bb]ackup.rdl 275 | *- [Bb]ackup ([0-9]).rdl 276 | *- [Bb]ackup ([0-9][0-9]).rdl 277 | 278 | # Microsoft Fakes 279 | FakesAssemblies/ 280 | 281 | # GhostDoc plugin setting file 282 | *.GhostDoc.xml 283 | 284 | # Node.js Tools for Visual Studio 285 | .ntvs_analysis.dat 286 | node_modules/ 287 | 288 | # Visual Studio 6 build log 289 | *.plg 290 | 291 | # Visual Studio 6 workspace options file 292 | *.opt 293 | 294 | # Visual Studio 6 auto-generated workspace file (contains which files were open etc.) 295 | *.vbw 296 | 297 | # Visual Studio LightSwitch build output 298 | **/*.HTMLClient/GeneratedArtifacts 299 | **/*.DesktopClient/GeneratedArtifacts 300 | **/*.DesktopClient/ModelManifest.xml 301 | **/*.Server/GeneratedArtifacts 302 | **/*.Server/ModelManifest.xml 303 | _Pvt_Extensions 304 | 305 | # Paket dependency manager 306 | .paket/paket.exe 307 | paket-files/ 308 | 309 | # FAKE - F# Make 310 | .fake/ 311 | 312 | # CodeRush personal settings 313 | .cr/personal 314 | 315 | # Python Tools for Visual Studio (PTVS) 316 | __pycache__/ 317 | *.pyc 318 | 319 | # Cake - Uncomment if you are using it 320 | # tools/** 321 | # !tools/packages.config 322 | 323 | # Tabs Studio 324 | *.tss 325 | 326 | # Telerik's JustMock configuration file 327 | *.jmconfig 328 | 329 | # BizTalk build output 330 | *.btp.cs 331 | *.btm.cs 332 | *.odx.cs 333 | *.xsd.cs 334 | 335 | # OpenCover UI analysis results 336 | OpenCover/ 337 | 338 | # Azure Stream Analytics local run output 339 | ASALocalRun/ 340 | 341 | # MSBuild Binary and Structured Log 342 | *.binlog 343 | 344 | # NVidia Nsight GPU debugger configuration file 345 | *.nvuser 346 | 347 | # MFractors (Xamarin productivity tool) working folder 348 | .mfractor/ 349 | 350 | # Local History for Visual Studio 351 | .localhistory/ 352 | 353 | # BeatPulse healthcheck temp database 354 | healthchecksdb 355 | 356 | # Backup folder for Package Reference Convert tool in Visual Studio 2017 357 | MigrationBackup/ 358 | 359 | # Ionide (cross platform F# VS Code tools) working folder 360 | .ionide/ 361 | 362 | # Fody - auto-generated XML schema 363 | FodyWeavers.xsd -------------------------------------------------------------------------------- /Arshf/PL/ArchiveFileForm.cs: -------------------------------------------------------------------------------- 1 | using DevExpress.XtraEditors; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.ComponentModel; 5 | using System.Data; 6 | using System.Drawing; 7 | using System.Linq; 8 | using System.Text; 9 | using System.Threading.Tasks; 10 | using System.Windows.Forms; 11 | 12 | namespace Arshf.PL 13 | { 14 | public partial class ArchiveFileForm : DevExpress.XtraEditors.XtraForm 15 | { 16 | // Data Base and Tables 17 | TBArchiveFile tbadd; 18 | DBAREntities db; 19 | // other var 20 | public int ArchiveID; 21 | private int id; 22 | private bool state; 23 | 24 | 25 | public ArchiveFileForm() 26 | { 27 | InitializeComponent(); 28 | ArchiveID =Convert.ToInt32( lb_id.Text); 29 | LoadData(); 30 | 31 | 32 | } 33 | 34 | public void LoadData() 35 | { 36 | // This line of code is generated by Data Source Configuration Wizard 37 | this.entityInstantFeedbackSource1.GetQueryable += entityInstantFeedbackSource1_GetQueryable; 38 | // This line of code is generated by Data Source Configuration Wizard 39 | this.entityInstantFeedbackSource1.DismissQueryable += entityInstantFeedbackSource1_DismissQueryable; 40 | this.entityInstantFeedbackSource1.Refresh(); 41 | } 42 | // This event is generated by Data Source Configuration Wizard 43 | void entityInstantFeedbackSource1_GetQueryable(object sender, DevExpress.Data.Linq.GetQueryableEventArgs e) 44 | { 45 | // Instantiate a new DataContext 46 | Arshf.DBAREntities dataContext = new Arshf.DBAREntities(); 47 | // Assign a queryable source to the EntityInstantFeedbackSource 48 | e.QueryableSource = dataContext.TBArchiveFiles.Where(x => x.IDArchive == ArchiveID) 49 | .Select(x => new 50 | { 51 | x.ID, 52 | x.IDArchive, 53 | x.AddDate, 54 | x.ArchDate, 55 | x.ArchDep, 56 | x.ArchDetails, 57 | x.ArchNumber, 58 | x.ArchReciver, 59 | x.ArchSender, 60 | x.ArchTitle 61 | }); 62 | // to dispose of it in the DismissQueryable event handler 63 | e.Tag = dataContext; 64 | } 65 | 66 | // This event is generated by Data Source Configuration Wizard 67 | void entityInstantFeedbackSource1_DismissQueryable(object sender, DevExpress.Data.Linq.GetQueryableEventArgs e) 68 | { 69 | // Dispose of the DataContext 70 | ((Arshf.DBAREntities)e.Tag).Dispose(); 71 | } 72 | 73 | private void btn_add_Click(object sender, EventArgs e) 74 | { 75 | AddPage.AddFile add = new AddPage.AddFile(); 76 | add.btn_add.Text = "اضافة"; 77 | add.id = 0; 78 | add.IDArch = Convert.ToInt32(lb_id.Text); 79 | add.ArchDep = lb_archdep.Text; 80 | add.page = this; 81 | add.Show(); 82 | } 83 | 84 | private void btn_edit_Click(object sender, EventArgs e) 85 | { 86 | try 87 | { 88 | id = Convert.ToInt32(gridView1.GetFocusedRowCellValue("ID")); 89 | if (id > 0) 90 | { 91 | // Edit 92 | AddPage.AddFile add = new AddPage.AddFile(); 93 | add.btn_add.Text = "تعديل"; 94 | add.id = id; 95 | add.IDArch = Convert.ToInt32(lb_id.Text); 96 | add.ArchDep = lb_archdep.Text; 97 | add.edt_number.Text = Convert.ToString(gridView1.GetFocusedRowCellValue("ArchNumber")); 98 | add.edt_reciver.Text = Convert.ToString(gridView1.GetFocusedRowCellValue("ArchReciver")); 99 | add.edt_sender.Text = Convert.ToString(gridView1.GetFocusedRowCellValue("ArchSender")); 100 | add.edt_title.Text = Convert.ToString(gridView1.GetFocusedRowCellValue("ArchTitle")); 101 | add.edt_date.Text = Convert.ToString(gridView1.GetFocusedRowCellValue("ArchDate")); 102 | add.edt_details.Text = Convert.ToString(gridView1.GetFocusedRowCellValue("ArchDetails")); 103 | add.page = this; 104 | add.Show(); 105 | } 106 | else 107 | { 108 | MessageBox.Show("لا بيانات لتعديلها"); 109 | } 110 | } 111 | catch (Exception ex) 112 | { 113 | MessageBox.Show("خطأ في العملية", ex.Message, MessageBoxButtons.OK, MessageBoxIcon.Error); 114 | 115 | } 116 | } 117 | 118 | private async void btn_delete_Click(object sender, EventArgs e) 119 | { 120 | try 121 | { 122 | id = Convert.ToInt32(gridView1.GetFocusedRowCellValue("ID")); 123 | if (id > 0) 124 | { 125 | var result = MessageBox.Show("اجراء حذف", "هل انت متأكد من هذا الاجراء", MessageBoxButtons.YesNo, MessageBoxIcon.Question); 126 | if (result == DialogResult.Yes) 127 | { 128 | // Delete 129 | // Loading 130 | loading.Visible = true; 131 | tbadd = new TBArchiveFile 132 | { 133 | ID = id, 134 | }; 135 | var rs = await Task.Run(() => Delete(tbadd)); 136 | if (rs == true) 137 | { 138 | LoadData(); 139 | toastNotificationsManager1.ShowNotification("96616aac-b9fe-45d7-8bb1-5cd04f388f4c"); 140 | 141 | } 142 | else 143 | { 144 | MessageBox.Show("خطأ في الاتصال", "تأكد من الاتصال في السيرفر لطفا", MessageBoxButtons.OK, MessageBoxIcon.Error); 145 | 146 | } 147 | //End 148 | loading.Visible = false; 149 | } 150 | 151 | 152 | 153 | } 154 | else 155 | { 156 | MessageBox.Show("لا بيانات لحذفها"); 157 | } 158 | } 159 | catch (Exception ex) 160 | { 161 | MessageBox.Show("خطأ في العملية", ex.Message, MessageBoxButtons.OK, MessageBoxIcon.Error); 162 | 163 | } 164 | } 165 | // Delete Method 166 | private bool Delete(TBArchiveFile Data) 167 | { 168 | try 169 | { 170 | db = new DBAREntities(); 171 | db.Entry(Data).State = System.Data.Entity.EntityState.Deleted; 172 | db.SaveChanges(); 173 | state = true; 174 | 175 | } 176 | catch { state = false; } 177 | return state; 178 | } 179 | 180 | private void btn_print_Click(object sender, EventArgs e) 181 | { 182 | gridControl1.ShowPrintPreview(); 183 | } 184 | 185 | private void btn_showfiles_Click(object sender, EventArgs e) 186 | { 187 | try 188 | { 189 | id = Convert.ToInt32(gridView1.GetFocusedRowCellValue("ID")); 190 | if (id > 0) 191 | { 192 | 193 | 194 | PL.ShowFiles files = new ShowFiles(); 195 | files.id = id; 196 | files.Show(); 197 | 198 | 199 | } 200 | else 201 | { 202 | MessageBox.Show("لا بيانات "); 203 | } 204 | } 205 | catch (Exception ex) 206 | { 207 | MessageBox.Show("خطأ في العملية", ex.Message, MessageBoxButtons.OK, MessageBoxIcon.Error); 208 | 209 | } 210 | 211 | } 212 | } 213 | } -------------------------------------------------------------------------------- /Arshf/PL/SettingForm.cs: -------------------------------------------------------------------------------- 1 | using DevExpress.XtraEditors; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.ComponentModel; 5 | using System.Data; 6 | using System.Drawing; 7 | using System.IO; 8 | using System.Linq; 9 | using System.Text; 10 | using System.Threading.Tasks; 11 | using System.Windows.Forms; 12 | using System.Configuration; 13 | 14 | 15 | namespace Arshf.PL 16 | { 17 | public partial class SettingForm : DevExpress.XtraEditors.XtraForm 18 | { 19 | private DBAREntities db; 20 | private string msg; 21 | 22 | public int Start; 23 | public SettingForm() 24 | { 25 | InitializeComponent(); 26 | } 27 | 28 | private void btn_savegen_Click(object sender, EventArgs e) 29 | { 30 | SaveSetting(); 31 | } 32 | 33 | private void SaveSetting() 34 | { 35 | try 36 | { 37 | Properties.Settings.Default.CompanyName = edt_companyname.Text; 38 | Properties.Settings.Default.CompanyDes = edt_companydes.Text; 39 | 40 | // Set Logo 41 | var ma = new MemoryStream(); 42 | pic_logo.Image.Save(ma, System.Drawing.Imaging.ImageFormat.Png); 43 | Properties.Settings.Default.CompanyLogo = Convert.ToBase64String(ma.ToArray()); 44 | 45 | Properties.Settings.Default.Save(); 46 | MessageBox.Show("تمت عملية الحفظ بنجاح"); 47 | } 48 | catch (Exception ex) 49 | { 50 | MessageBox.Show(ex.Message); 51 | } 52 | } 53 | 54 | private void SettingForm_Load(object sender, EventArgs e) 55 | { 56 | GetSettings(); 57 | } 58 | 59 | private void GetSettings() 60 | { 61 | try 62 | { 63 | edt_companyname.Text= Properties.Settings.Default.CompanyName ; 64 | edt_companydes.Text =Properties.Settings.Default.CompanyDes ; 65 | 66 | // Set Logo 67 | var Bytimage = Convert.FromBase64String(Properties.Settings.Default.CompanyLogo); 68 | if (Bytimage != null) 69 | { 70 | var ma = new MemoryStream(Bytimage); 71 | pic_logo.Image = Image.FromStream(ma); 72 | 73 | } 74 | 75 | } 76 | catch 77 | { 78 | } 79 | } 80 | 81 | private void radioButton1_CheckedChanged(object sender, EventArgs e) 82 | { 83 | SetConType(); 84 | } 85 | 86 | private void SetConType() 87 | { 88 | if (radioButton1.Checked == true) 89 | { 90 | edt_port.Enabled = false; 91 | edt_username.Enabled = false; 92 | edt_password.Enabled = false; 93 | } 94 | else 95 | { 96 | edt_port.Enabled = true; 97 | edt_username.Enabled = true; 98 | edt_password.Enabled = true; 99 | } 100 | } 101 | 102 | private void btn_saveconstring_Click(object sender, EventArgs e) 103 | { 104 | // Method to save 105 | SaveConStrign(); 106 | // Method to Ecryp constring 107 | Encrypteconstring(); 108 | } 109 | 110 | 111 | private void SaveConStrign() 112 | { 113 | // Get input 114 | var server = edt_servername.Text; 115 | var dbname = edt_database.Text; 116 | var port = "," + edt_port.Text; 117 | var user = edt_username.Text; 118 | var password = edt_password.Text; 119 | 120 | if (radioButton1.Checked == true) 121 | { 122 | // Local Con 123 | var ConString = @"metadata=res://*/DBAR.csdl|res://*/DBAR.ssdl|res://*/DBAR.msl;provider=System.Data.SqlClient;provider connection string=';data source="+server+" ;initial catalog=" + dbname + ";integrated security=true;MultipleActiveResultSets=True;App=EntityFramework';"; 124 | 125 | var config = ConfigurationManager.OpenExeConfiguration(ConfigurationUserLevel.None); 126 | var connectionStringsSection = (ConnectionStringsSection)config.GetSection("connectionStrings"); 127 | connectionStringsSection.ConnectionStrings["DBAREntities"].ConnectionString = ConString; 128 | config.Save(); 129 | ConfigurationManager.RefreshSection("connectionStrings"); 130 | 131 | MessageBox.Show("تم تحديث الاتصال بنجاح , سيتم اعادة تشغيل البرنامج لتطبيق الاعدادات "); 132 | Application.Restart(); 133 | } 134 | else 135 | { 136 | // Local Con 137 | var ConString = @"metadata=res://*/DBAR.csdl|res://*/DBAR.ssdl|res://*/DBAR.msl;provider=System.Data.SqlClient;provider connection string=';data source=" + server + port + ";initial catalog=" + dbname + ";user id=" + user + ";password=" + password + ";connect Timeout=60;MultipleActiveResultSets=True;App=EntityFramework';"; 138 | 139 | var config = ConfigurationManager.OpenExeConfiguration(ConfigurationUserLevel.None); 140 | var connectionStringsSection = (ConnectionStringsSection)config.GetSection("connectionStrings"); 141 | connectionStringsSection.ConnectionStrings["DBAREntities"].ConnectionString = ConString; 142 | config.Save(); 143 | ConfigurationManager.RefreshSection("connectionStrings"); 144 | 145 | MessageBox.Show("تم تحديث الاتصال بنجاح , سيتم اعادة تشغيل البرنامج لتطبيق الاعدادات "); 146 | Application.Restart(); 147 | } 148 | 149 | 150 | 151 | } 152 | 153 | private void Encrypteconstring() 154 | { 155 | var config = ConfigurationManager.OpenExeConfiguration(ConfigurationUserLevel.None); 156 | 157 | ExeConfigurationFileMap configFileMap = new ExeConfigurationFileMap(); 158 | configFileMap.ExeConfigFilename = config.FilePath; 159 | System.Configuration.Configuration myConfig = ConfigurationManager.OpenMappedExeConfiguration(configFileMap, ConfigurationUserLevel.None); 160 | 161 | ConnectionStringsSection section = myConfig.GetSection("connectionStrings") as ConnectionStringsSection; 162 | 163 | if (section.SectionInformation.IsProtected) 164 | { 165 | // Remove encryption. 166 | section.SectionInformation.UnprotectSection(); 167 | } 168 | else 169 | { 170 | // Encrypt the section. 171 | section.SectionInformation.ProtectSection("DataProtectionConfigurationProvider"); 172 | } 173 | 174 | myConfig.Save(); 175 | } 176 | 177 | private async void btn_backup_Click(object sender, EventArgs e) 178 | { 179 | FolderBrowserDialog fbd = new FolderBrowserDialog(); 180 | var rs= fbd.ShowDialog(); 181 | if (rs==DialogResult.OK) 182 | { 183 | loading.Visible = true; 184 | var state = await Task.Run(() => BackUp(fbd)); 185 | 186 | if (state == true) 187 | { 188 | MessageBox.Show("تمت عملية النسخ الاحتياطي بنجاح"); 189 | } 190 | else 191 | { 192 | MessageBox.Show(msg); 193 | } 194 | 195 | loading.Visible = false; 196 | } 197 | 198 | } 199 | 200 | 201 | 202 | private bool BackUp(FolderBrowserDialog folder) 203 | { 204 | try 205 | { 206 | db = new DBAREntities(); 207 | 208 | string dbname = db.Database.Connection.Database; 209 | string dbBackUp = "ARDB" + DateTime.Now.ToString("yyyyMMddHHmm"); 210 | var fullpath = folder.SelectedPath.ToString() + dbBackUp + ".bak"; 211 | string sqlCommand = @"BACKUP DATABASE [{0}] TO DISK = '" + fullpath + "' WITH NOFORMAT, NOINIT, NAME = N'DBAR', SKIP, NOREWIND, NOUNLOAD, STATS = 10"; 212 | int path = db.Database.ExecuteSqlCommand(System.Data.Entity.TransactionalBehavior.DoNotEnsureTransaction, string.Format(sqlCommand, dbname, dbBackUp)); 213 | return true; 214 | } 215 | catch (Exception ex) 216 | { 217 | msg = ex.Message; 218 | return false; 219 | 220 | } 221 | } 222 | 223 | private void SettingForm_FormClosed(object sender, FormClosedEventArgs e) 224 | { 225 | if (Start == 1) 226 | { 227 | Application.Exit(); 228 | } 229 | } 230 | } 231 | } -------------------------------------------------------------------------------- /Arshf/AddPage/AddArchiveCategory.Designer.cs: -------------------------------------------------------------------------------- 1 | 2 | namespace Arshf.AddPage 3 | { 4 | partial class AddArchiveCategory 5 | { 6 | /// 7 | /// Required designer variable. 8 | /// 9 | private System.ComponentModel.IContainer components = null; 10 | 11 | /// 12 | /// Clean up any resources being used. 13 | /// 14 | /// true if managed resources should be disposed; otherwise, false. 15 | protected override void Dispose(bool disposing) 16 | { 17 | if (disposing && (components != null)) 18 | { 19 | components.Dispose(); 20 | } 21 | base.Dispose(disposing); 22 | } 23 | 24 | #region Windows Form Designer generated code 25 | 26 | /// 27 | /// Required method for Designer support - do not modify 28 | /// the contents of this method with the code editor. 29 | /// 30 | private void InitializeComponent() 31 | { 32 | this.components = new System.ComponentModel.Container(); 33 | System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(AddArchiveCategory)); 34 | this.panel1 = new System.Windows.Forms.Panel(); 35 | this.btn_add = new DevExpress.XtraEditors.SimpleButton(); 36 | this.label1 = new System.Windows.Forms.Label(); 37 | this.edt_name = new DevExpress.XtraEditors.TextEdit(); 38 | this.label2 = new System.Windows.Forms.Label(); 39 | this.edt_details = new System.Windows.Forms.RichTextBox(); 40 | this.toastNotificationsManager1 = new DevExpress.XtraBars.ToastNotifications.ToastNotificationsManager(this.components); 41 | this.loading = new DevExpress.XtraWaitForm.ProgressPanel(); 42 | this.panel1.SuspendLayout(); 43 | ((System.ComponentModel.ISupportInitialize)(this.edt_name.Properties)).BeginInit(); 44 | ((System.ComponentModel.ISupportInitialize)(this.toastNotificationsManager1)).BeginInit(); 45 | this.SuspendLayout(); 46 | // 47 | // panel1 48 | // 49 | this.panel1.Controls.Add(this.btn_add); 50 | this.panel1.Dock = System.Windows.Forms.DockStyle.Bottom; 51 | this.panel1.Location = new System.Drawing.Point(0, 360); 52 | this.panel1.Name = "panel1"; 53 | this.panel1.Size = new System.Drawing.Size(662, 77); 54 | this.panel1.TabIndex = 0; 55 | // 56 | // btn_add 57 | // 58 | this.btn_add.Anchor = System.Windows.Forms.AnchorStyles.None; 59 | this.btn_add.Appearance.Font = new System.Drawing.Font("Cairo", 13.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); 60 | this.btn_add.Appearance.Options.UseFont = true; 61 | this.btn_add.ImageOptions.Image = ((System.Drawing.Image)(resources.GetObject("btn_add.ImageOptions.Image"))); 62 | this.btn_add.Location = new System.Drawing.Point(500, 8); 63 | this.btn_add.Name = "btn_add"; 64 | this.btn_add.Size = new System.Drawing.Size(150, 57); 65 | this.btn_add.TabIndex = 5; 66 | this.btn_add.Text = "اضافة"; 67 | this.btn_add.Click += new System.EventHandler(this.btn_add_Click); 68 | // 69 | // label1 70 | // 71 | this.label1.AutoSize = true; 72 | this.label1.Font = new System.Drawing.Font("Cairo", 18F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); 73 | this.label1.Location = new System.Drawing.Point(259, 20); 74 | this.label1.Name = "label1"; 75 | this.label1.Size = new System.Drawing.Size(191, 56); 76 | this.label1.TabIndex = 1; 77 | this.label1.Text = "عنون الاضبارة"; 78 | // 79 | // edt_name 80 | // 81 | this.edt_name.Location = new System.Drawing.Point(124, 79); 82 | this.edt_name.Name = "edt_name"; 83 | this.edt_name.Properties.Appearance.Font = new System.Drawing.Font("Cairo", 16.2F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); 84 | this.edt_name.Properties.Appearance.Options.UseFont = true; 85 | this.edt_name.Size = new System.Drawing.Size(418, 56); 86 | this.edt_name.TabIndex = 2; 87 | // 88 | // label2 89 | // 90 | this.label2.AutoSize = true; 91 | this.label2.Font = new System.Drawing.Font("Cairo", 18F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); 92 | this.label2.Location = new System.Drawing.Point(269, 138); 93 | this.label2.Name = "label2"; 94 | this.label2.Size = new System.Drawing.Size(133, 56); 95 | this.label2.TabIndex = 1; 96 | this.label2.Text = "التفاصيل"; 97 | // 98 | // edt_details 99 | // 100 | this.edt_details.Font = new System.Drawing.Font("Cairo", 7.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); 101 | this.edt_details.Location = new System.Drawing.Point(124, 197); 102 | this.edt_details.Name = "edt_details"; 103 | this.edt_details.Size = new System.Drawing.Size(418, 140); 104 | this.edt_details.TabIndex = 3; 105 | this.edt_details.Text = ""; 106 | // 107 | // toastNotificationsManager1 108 | // 109 | this.toastNotificationsManager1.ApplicationId = "cfcb4971-26aa-43fa-9cb6-09c2ad124f56"; 110 | this.toastNotificationsManager1.Notifications.AddRange(new DevExpress.XtraBars.ToastNotifications.IToastNotificationProperties[] { 111 | new DevExpress.XtraBars.ToastNotifications.ToastNotification("96616aac-b9fe-45d7-8bb1-5cd04f388f4c", ((System.Drawing.Image)(resources.GetObject("toastNotificationsManager1.Notifications"))), "تمت العملية بنجاح", "تمت العملية بنجاح", "تمت العملية بنجاح", DevExpress.XtraBars.ToastNotifications.ToastNotificationTemplate.ImageAndText01)}); 112 | // 113 | // loading 114 | // 115 | this.loading.Appearance.BackColor = System.Drawing.Color.Transparent; 116 | this.loading.Appearance.Options.UseBackColor = true; 117 | this.loading.Caption = "الرجاء الانتظار"; 118 | this.loading.Description = "العملية تجرى في الخلفية"; 119 | this.loading.Location = new System.Drawing.Point(194, 214); 120 | this.loading.Name = "loading"; 121 | this.loading.Size = new System.Drawing.Size(246, 66); 122 | this.loading.TabIndex = 4; 123 | this.loading.Text = "progressPanel1"; 124 | this.loading.Visible = false; 125 | // 126 | // AddArchiveCategory 127 | // 128 | this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 16F); 129 | this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; 130 | this.ClientSize = new System.Drawing.Size(662, 437); 131 | this.Controls.Add(this.loading); 132 | this.Controls.Add(this.edt_details); 133 | this.Controls.Add(this.label2); 134 | this.Controls.Add(this.edt_name); 135 | this.Controls.Add(this.label1); 136 | this.Controls.Add(this.panel1); 137 | this.IconOptions.ShowIcon = false; 138 | this.MaximizeBox = false; 139 | this.MinimizeBox = false; 140 | this.Name = "AddArchiveCategory"; 141 | this.RightToLeft = System.Windows.Forms.RightToLeft.Yes; 142 | this.ShowInTaskbar = false; 143 | this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen; 144 | this.Text = "اضافة قسم"; 145 | this.TopMost = true; 146 | this.panel1.ResumeLayout(false); 147 | ((System.ComponentModel.ISupportInitialize)(this.edt_name.Properties)).EndInit(); 148 | ((System.ComponentModel.ISupportInitialize)(this.toastNotificationsManager1)).EndInit(); 149 | this.ResumeLayout(false); 150 | this.PerformLayout(); 151 | 152 | } 153 | 154 | #endregion 155 | 156 | private System.Windows.Forms.Panel panel1; 157 | private System.Windows.Forms.Label label1; 158 | private System.Windows.Forms.Label label2; 159 | public DevExpress.XtraEditors.SimpleButton btn_add; 160 | public DevExpress.XtraEditors.TextEdit edt_name; 161 | public System.Windows.Forms.RichTextBox edt_details; 162 | private DevExpress.XtraBars.ToastNotifications.ToastNotificationsManager toastNotificationsManager1; 163 | private DevExpress.XtraWaitForm.ProgressPanel loading; 164 | } 165 | } -------------------------------------------------------------------------------- /Arshf/AddPage/AddDep.Designer.cs: -------------------------------------------------------------------------------- 1 | 2 | namespace Arshf.AddPage 3 | { 4 | partial class AddDep 5 | { 6 | /// 7 | /// Required designer variable. 8 | /// 9 | private System.ComponentModel.IContainer components = null; 10 | 11 | /// 12 | /// Clean up any resources being used. 13 | /// 14 | /// true if managed resources should be disposed; otherwise, false. 15 | protected override void Dispose(bool disposing) 16 | { 17 | if (disposing && (components != null)) 18 | { 19 | components.Dispose(); 20 | } 21 | base.Dispose(disposing); 22 | } 23 | 24 | #region Windows Form Designer generated code 25 | 26 | /// 27 | /// Required method for Designer support - do not modify 28 | /// the contents of this method with the code editor. 29 | /// 30 | private void InitializeComponent() 31 | { 32 | this.components = new System.ComponentModel.Container(); 33 | System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(AddDep)); 34 | this.panel1 = new System.Windows.Forms.Panel(); 35 | this.btn_add = new DevExpress.XtraEditors.SimpleButton(); 36 | this.label1 = new System.Windows.Forms.Label(); 37 | this.edt_name = new DevExpress.XtraEditors.TextEdit(); 38 | this.label2 = new System.Windows.Forms.Label(); 39 | this.edt_details = new System.Windows.Forms.RichTextBox(); 40 | this.toastNotificationsManager1 = new DevExpress.XtraBars.ToastNotifications.ToastNotificationsManager(this.components); 41 | this.loading = new DevExpress.XtraWaitForm.ProgressPanel(); 42 | this.panel1.SuspendLayout(); 43 | ((System.ComponentModel.ISupportInitialize)(this.edt_name.Properties)).BeginInit(); 44 | ((System.ComponentModel.ISupportInitialize)(this.toastNotificationsManager1)).BeginInit(); 45 | this.SuspendLayout(); 46 | // 47 | // panel1 48 | // 49 | this.panel1.Controls.Add(this.btn_add); 50 | this.panel1.Dock = System.Windows.Forms.DockStyle.Bottom; 51 | this.panel1.Location = new System.Drawing.Point(0, 360); 52 | this.panel1.Name = "panel1"; 53 | this.panel1.Size = new System.Drawing.Size(662, 77); 54 | this.panel1.TabIndex = 0; 55 | // 56 | // btn_add 57 | // 58 | this.btn_add.Anchor = System.Windows.Forms.AnchorStyles.None; 59 | this.btn_add.Appearance.Font = new System.Drawing.Font("Cairo", 13.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); 60 | this.btn_add.Appearance.Options.UseFont = true; 61 | this.btn_add.ImageOptions.Image = ((System.Drawing.Image)(resources.GetObject("btn_add.ImageOptions.Image"))); 62 | this.btn_add.Location = new System.Drawing.Point(500, 8); 63 | this.btn_add.Name = "btn_add"; 64 | this.btn_add.Size = new System.Drawing.Size(150, 57); 65 | this.btn_add.TabIndex = 5; 66 | this.btn_add.Text = "اضافة"; 67 | this.btn_add.Click += new System.EventHandler(this.btn_add_Click); 68 | // 69 | // label1 70 | // 71 | this.label1.AutoSize = true; 72 | this.label1.Font = new System.Drawing.Font("Cairo", 18F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); 73 | this.label1.Location = new System.Drawing.Point(259, 20); 74 | this.label1.Name = "label1"; 75 | this.label1.Size = new System.Drawing.Size(164, 56); 76 | this.label1.TabIndex = 1; 77 | this.label1.Text = "اسم القسم"; 78 | // 79 | // edt_name 80 | // 81 | this.edt_name.Location = new System.Drawing.Point(124, 79); 82 | this.edt_name.Name = "edt_name"; 83 | this.edt_name.Properties.Appearance.Font = new System.Drawing.Font("Cairo", 16.2F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); 84 | this.edt_name.Properties.Appearance.Options.UseFont = true; 85 | this.edt_name.Size = new System.Drawing.Size(418, 56); 86 | this.edt_name.TabIndex = 2; 87 | // 88 | // label2 89 | // 90 | this.label2.AutoSize = true; 91 | this.label2.Font = new System.Drawing.Font("Cairo", 18F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); 92 | this.label2.Location = new System.Drawing.Point(269, 138); 93 | this.label2.Name = "label2"; 94 | this.label2.Size = new System.Drawing.Size(133, 56); 95 | this.label2.TabIndex = 1; 96 | this.label2.Text = "التفاصيل"; 97 | // 98 | // edt_details 99 | // 100 | this.edt_details.Font = new System.Drawing.Font("Cairo", 7.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); 101 | this.edt_details.Location = new System.Drawing.Point(124, 197); 102 | this.edt_details.Name = "edt_details"; 103 | this.edt_details.Size = new System.Drawing.Size(418, 140); 104 | this.edt_details.TabIndex = 3; 105 | this.edt_details.Text = ""; 106 | // 107 | // toastNotificationsManager1 108 | // 109 | this.toastNotificationsManager1.ApplicationId = "cfcb4971-26aa-43fa-9cb6-09c2ad124f56"; 110 | this.toastNotificationsManager1.Notifications.AddRange(new DevExpress.XtraBars.ToastNotifications.IToastNotificationProperties[] { 111 | new DevExpress.XtraBars.ToastNotifications.ToastNotification("96616aac-b9fe-45d7-8bb1-5cd04f388f4c", ((System.Drawing.Image)(resources.GetObject("toastNotificationsManager1.Notifications"))), "تمت العملية بنجاح", "تمت العملية بنجاح", "تمت العملية بنجاح", DevExpress.XtraBars.ToastNotifications.ToastNotificationTemplate.ImageAndText01)}); 112 | // 113 | // loading 114 | // 115 | this.loading.Appearance.BackColor = System.Drawing.Color.Transparent; 116 | this.loading.Appearance.Options.UseBackColor = true; 117 | this.loading.Caption = "الرجاء الانتظار"; 118 | this.loading.Description = "العملية تجرى في الخلفية"; 119 | this.loading.Location = new System.Drawing.Point(207, 141); 120 | this.loading.Name = "loading"; 121 | this.loading.Size = new System.Drawing.Size(246, 66); 122 | this.loading.TabIndex = 4; 123 | this.loading.Text = "progressPanel1"; 124 | this.loading.Visible = false; 125 | // 126 | // AddDep 127 | // 128 | this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 16F); 129 | this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; 130 | this.ClientSize = new System.Drawing.Size(662, 437); 131 | this.Controls.Add(this.loading); 132 | this.Controls.Add(this.edt_details); 133 | this.Controls.Add(this.label2); 134 | this.Controls.Add(this.edt_name); 135 | this.Controls.Add(this.label1); 136 | this.Controls.Add(this.panel1); 137 | this.IconOptions.ShowIcon = false; 138 | this.MaximizeBox = false; 139 | this.MinimizeBox = false; 140 | this.Name = "AddDep"; 141 | this.RightToLeft = System.Windows.Forms.RightToLeft.Yes; 142 | this.ShowInTaskbar = false; 143 | this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen; 144 | this.Text = "اضافة قسم"; 145 | this.TopMost = true; 146 | this.FormClosed += new System.Windows.Forms.FormClosedEventHandler(this.AddDep_FormClosed); 147 | this.panel1.ResumeLayout(false); 148 | ((System.ComponentModel.ISupportInitialize)(this.edt_name.Properties)).EndInit(); 149 | ((System.ComponentModel.ISupportInitialize)(this.toastNotificationsManager1)).EndInit(); 150 | this.ResumeLayout(false); 151 | this.PerformLayout(); 152 | 153 | } 154 | 155 | #endregion 156 | 157 | private System.Windows.Forms.Panel panel1; 158 | private System.Windows.Forms.Label label1; 159 | private System.Windows.Forms.Label label2; 160 | public DevExpress.XtraEditors.SimpleButton btn_add; 161 | public DevExpress.XtraEditors.TextEdit edt_name; 162 | public System.Windows.Forms.RichTextBox edt_details; 163 | private DevExpress.XtraBars.ToastNotifications.ToastNotificationsManager toastNotificationsManager1; 164 | private DevExpress.XtraWaitForm.ProgressPanel loading; 165 | } 166 | } -------------------------------------------------------------------------------- /Arshf/PL/SettingForm.resx: -------------------------------------------------------------------------------- 1 | 2 | 3 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | text/microsoft-resx 110 | 111 | 112 | 2.0 113 | 114 | 115 | System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 116 | 117 | 118 | System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 119 | 120 | 121 | 122 | 123 | iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAABl0RVh0U29m 124 | dHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAAtdEVYdFRpdGxlAEVkaXQ7QmFycztSaWJib247U3Rh 125 | bmRhcmQ7SW1hZ2U7Qml0bWFwOzcHiBcAAADzSURBVFhH7ZPRDYMwDEQZjDEYgCX4ZS4m6gZI/UsvVbCO 126 | 5GjTKhip6sdTyNnYFwe6EMKlSNETKXoiRU+6vu/DlfwN7Azk93MW3PP3DKDOCBawpnUUOecYQI3Y/M41 127 | 035nguOtDcQTWz1iyfIs1tpAHLvVI9Ysz2KtDVw+gfbfAPQB3BKDymGQ0+4vgDZzPDHneZ/C9Q4NYK+a 128 | b0gT0KumhZjVkgbwPLF+wLTlp3eqp8U5hQGsr06e82wQ10xnChMcVwZsX8k307JYCwO12CRY9zQQ2a7M 129 | NG8DRY/CgAfc8/QTv+NvQN6RJ1L0RIqeSNGP0D0AawdicLWv6pMAAAAASUVORK5CYII= 130 | 131 | 132 | 133 | 134 | iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAABl0RVh0U29m 135 | dHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAARdEVYdFRpdGxlAEV4cG9ydDtTYXZlRtSeMQAAAURJ 136 | REFUWEfdlsFpw0AQRd2KKzH45FpSgI8B1+CDStAxdaSPgMtQ5guv2Pn6Y63kZQU+PMLM7Mx/BGx8GIZh 137 | V2SzJbLZEtlsyaxx//o5Gb/GkIF+Iu+/gt/i5onzXAHs0SNbStQQAA/OcwUQS6BEgOfyLee5AqglIx2P 138 | 5oDn8i3nuQKoJSMdj+aA5/It57kCqCUjHY/mgOfyLee5AqglIx2P5orPFVjD7BbnuQKopZpwniuAWqoJ 139 | 57kCqKWacJ4rAC2cDfTe4WjcjE0CfOwl175TfOOvzUcJmjURQOgkkfVHWglMEkxLASlRWyAPi3ASewiA 140 | SWIvATBKLAlccLgUCijhtiSwhrUC40dSCfzR4VLWCEzfB0oA/3b1y3iJUgH3ZaQENpMfzgjDwUzgHfj4 141 | kzAcyENbUQFGGA7koa2oACMMv/bd4R8cYf1FvaRMggAAAABJRU5ErkJggg== 142 | 143 | 144 | 145 | 146 | iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAABl0RVh0U29m 147 | dHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAARdEVYdFRpdGxlAEV4cG9ydDtTYXZlRtSeMQAAAURJ 148 | REFUWEfdlsFpw0AQRd2KKzH45FpSgI8B1+CDStAxdaSPgMtQ5guv2Pn6Y63kZQU+PMLM7Mx/BGx8GIZh 149 | V2SzJbLZEtlsyaxx//o5Gb/GkIF+Iu+/gt/i5onzXAHs0SNbStQQAA/OcwUQS6BEgOfyLee5AqglIx2P 150 | 5oDn8i3nuQKoJSMdj+aA5/It57kCqCUjHY/mgOfyLee5AqglIx2P5orPFVjD7BbnuQKopZpwniuAWqoJ 151 | 57kCqKWacJ4rAC2cDfTe4WjcjE0CfOwl175TfOOvzUcJmjURQOgkkfVHWglMEkxLASlRWyAPi3ASewiA 152 | SWIvATBKLAlccLgUCijhtiSwhrUC40dSCfzR4VLWCEzfB0oA/3b1y3iJUgH3ZaQENpMfzgjDwUzgHfj4 153 | kzAcyENbUQFGGA7koa2oACMMv/bd4R8cYf1FvaRMggAAAABJRU5ErkJggg== 154 | 155 | 156 | 157 | 158 | iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAABl0RVh0U29m 159 | dHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAARdEVYdFRpdGxlAEV4cG9ydDtTYXZlRtSeMQAAAURJ 160 | REFUWEfdlsFpw0AQRd2KKzH45FpSgI8B1+CDStAxdaSPgMtQ5guv2Pn6Y63kZQU+PMLM7Mx/BGx8GIZh 161 | V2SzJbLZEtlsyaxx//o5Gb/GkIF+Iu+/gt/i5onzXAHs0SNbStQQAA/OcwUQS6BEgOfyLee5AqglIx2P 162 | 5oDn8i3nuQKoJSMdj+aA5/It57kCqCUjHY/mgOfyLee5AqglIx2P5orPFVjD7BbnuQKopZpwniuAWqoJ 163 | 57kCqKWacJ4rAC2cDfTe4WjcjE0CfOwl175TfOOvzUcJmjURQOgkkfVHWglMEkxLASlRWyAPi3ASewiA 164 | SWIvATBKLAlccLgUCijhtiSwhrUC40dSCfzR4VLWCEzfB0oA/3b1y3iJUgH3ZaQENpMfzgjDwUzgHfj4 165 | kzAcyENbUQFGGA7koa2oACMMv/bd4R8cYf1FvaRMggAAAABJRU5ErkJggg== 166 | 167 | 168 | -------------------------------------------------------------------------------- /Arshf/PL/SearchResults.resx: -------------------------------------------------------------------------------- 1 | 2 | 3 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | text/microsoft-resx 110 | 111 | 112 | 2.0 113 | 114 | 115 | System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 116 | 117 | 118 | System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 119 | 120 | 121 | 17, 17 122 | 123 | 124 | 125 | 126 | AAEAAAD/////AQAAAAAAAAAMAgAAAFlEZXZFeHByZXNzLkRhdGEudjIwLjIsIFZlcnNpb249MjAuMi42 127 | LjAsIEN1bHR1cmU9bmV1dHJhbCwgUHVibGljS2V5VG9rZW49Yjg4ZDE3NTRkNzAwZTQ5YQUBAAAAHURl 128 | dkV4cHJlc3MuVXRpbHMuU3ZnLlN2Z0ltYWdlAQAAAAREYXRhBwICAAAACQMAAAAPAwAAAAcEAAAC77u/ 129 | PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0nVVRGLTgnPz4NCjxzdmcgeD0iMHB4IiB5PSIwcHgi 130 | IHZpZXdCb3g9IjAgMCAzMiAzMiIgdmVyc2lvbj0iMS4xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcv 131 | MjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB4bWw6c3Bh 132 | Y2U9InByZXNlcnZlIiBpZD0iTGF5ZXJfMSIgc3R5bGU9ImVuYWJsZS1iYWNrZ3JvdW5kOm5ldyAwIDAg 133 | MzIgMzIiPg0KICA8c3R5bGUgdHlwZT0idGV4dC9jc3MiPgoJLkJsdWV7ZmlsbDojMTE3N0Q3O30KCS5Z 134 | ZWxsb3d7ZmlsbDojRkZCMTE1O30KCS5SZWR7ZmlsbDojRDExQzFDO30KCS5HcmVlbntmaWxsOiMwMzlD 135 | MjM7fQoJLkJsYWNre2ZpbGw6IzcyNzI3Mjt9CgkuV2hpdGV7ZmlsbDojRkZGRkZGO30KCS5zdDB7b3Bh 136 | Y2l0eTowLjU7fQoJLnN0MXtvcGFjaXR5OjAuNzU7fQoJLnN0MntkaXNwbGF5Om5vbmU7fQoJLnN0M3tk 137 | aXNwbGF5OmlubGluZTtmaWxsOiNGRkIxMTU7fQoJLnN0NHtkaXNwbGF5OmlubGluZTt9Cgkuc3Q1e2Rp 138 | c3BsYXk6aW5saW5lO29wYWNpdHk6MC43NTt9Cgkuc3Q2e2Rpc3BsYXk6aW5saW5lO29wYWNpdHk6MC41 139 | O30KCS5zdDd7ZGlzcGxheTppbmxpbmU7ZmlsbDojMDM5QzIzO30KCS5zdDh7ZGlzcGxheTppbmxpbmU7 140 | ZmlsbDojRDExQzFDO30KCS5zdDl7ZGlzcGxheTppbmxpbmU7ZmlsbDojMTE3N0Q3O30KCS5zdDEwe2Rp 141 | c3BsYXk6aW5saW5lO2ZpbGw6I0ZGRkZGRjt9Cjwvc3R5bGU+DQogIDxnIGlkPSJGaWxlQXR0YWNobWVu 142 | dCI+DQogICAgPHBhdGggZD0iTTIwLDEwdjEzYzAsMi44LTIuMiw1LTUsNXMtNS0yLjItNS01VjdjMC0x 143 | LjcsMS4zLTMsMy0zczMsMS4zLDMsM3YxNmMwLDAuNi0wLjQsMS0xLDFzLTEtMC40LTEtMVYxMGgtMnYx 144 | MyAgIGMwLDEuNywxLjMsMywzLDNzMy0xLjMsMy0zVjdjMC0yLjgtMi4yLTUtNS01UzgsNC4yLDgsN3Yx 145 | NmMwLDMuOSwzLjEsNyw3LDdzNy0zLjEsNy03VjEwSDIweiIgY2xhc3M9IkJsYWNrIiAvPg0KICA8L2c+ 146 | DQo8L3N2Zz4L 147 | 148 | 149 | 150 | 509, 17 151 | 152 | 153 | 154 | 155 | iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAABl0RVh0U29m 156 | dHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAAhdEVYdFRpdGxlAEFwcGx5O09LO0NoZWNrO0JhcnM7 157 | UmliYm9uO2RjyGgAAAFKSURBVFhHxdAxTgNBEARA2wEpiH9hJETCI0j5Ck8gxI+AABAPgoCj27q1eoa+ 158 | 27XkW4KS3KOd65FXwzD8KzvsyQ57ssOe7LCnEB6eHhch399oH4WQF09l/PYVvMKFdh5+UFlYAMu/YIAP 159 | OBzR4wAtL/hPrHsc4MqZr0vnkgdUy2mpA5rKKQQ8OIXmcgoBj9Q65RZHlVMIeFjcwzOcyazm6HIKAY+J 160 | 5T/AD+yg5YjJcggdWQh4fAelvKgdMVtO2pGFgMfn8A76MZo6olpO2pGFMC60HtFUTtqRhSBLtSOay0k7 161 | shDS4tQRL9BcTtqRhWCWp45QLN+C29/TjiwEtwxzR1TLSTuyENzyiEd8gpZ/ww2494F2ZCG4ZXEJ5QiW 162 | 34J794d2ZCG45YRHvEFzOWlHFoJbNjZmNks7MjvsyQ57ssOe7LAnO+xnWP0CbFjkt+hdVzwAAAAASUVO 163 | RK5CYII= 164 | 165 | 166 | -------------------------------------------------------------------------------- /Arshf/PL/ShowFiles.cs: -------------------------------------------------------------------------------- 1 | using DevExpress.XtraEditors; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.ComponentModel; 5 | using System.Data; 6 | using System.Drawing; 7 | using System.Linq; 8 | using System.Text; 9 | using System.Threading; 10 | using System.Threading.Tasks; 11 | using System.Windows.Forms; 12 | using System.IO; 13 | using System.Diagnostics; 14 | 15 | namespace Arshf.PL 16 | { 17 | public partial class ShowFiles : DevExpress.XtraEditors.XtraForm 18 | { 19 | // Data Base and Tables 20 | TBArchiveFile tbadd; 21 | DBAREntities db; 22 | // other var 23 | public int ArchiveID; 24 | public int id; 25 | private bool state; 26 | string FileName, FileExt, path; 27 | byte[] FileFile; 28 | public ShowFiles() 29 | { 30 | InitializeComponent(); 31 | LoadData(); 32 | 33 | 34 | 35 | 36 | } 37 | 38 | public void LoadData() 39 | { 40 | // This line of code is generated by Data Source Configuration Wizard 41 | this.entityInstantFeedbackSource1.GetQueryable += entityInstantFeedbackSource1_GetQueryable; 42 | // This line of code is generated by Data Source Configuration Wizard 43 | this.entityInstantFeedbackSource1.DismissQueryable += entityInstantFeedbackSource1_DismissQueryable; 44 | this.entityInstantFeedbackSource1.Refresh(); 45 | } 46 | // This event is generated by Data Source Configuration Wizard 47 | void entityInstantFeedbackSource1_GetQueryable(object sender, DevExpress.Data.Linq.GetQueryableEventArgs e) 48 | { 49 | // Instantiate a new DataContext 50 | Arshf.DBAREntities dataContext = new Arshf.DBAREntities(); 51 | // Assign a queryable source to the EntityInstantFeedbackSource 52 | e.QueryableSource = dataContext.TBArchiveFiles.Where(x => x.ID == id) 53 | .Select(x => new 54 | { 55 | x.ID, 56 | x.FileExt1, 57 | x.FileExt2, 58 | x.FileExt3, 59 | x.FileExt4, 60 | x.FileExt5, 61 | x.FileName1, 62 | x.FileName2, 63 | x.FileName3, 64 | x.FileName4, 65 | x.FileName5, 66 | 67 | }); 68 | // to dispose of it in the DismissQueryable event handler 69 | e.Tag = dataContext; 70 | } 71 | 72 | // This event is generated by Data Source Configuration Wizard 73 | void entityInstantFeedbackSource1_DismissQueryable(object sender, DevExpress.Data.Linq.GetQueryableEventArgs e) 74 | { 75 | // Dispose of the DataContext 76 | ((Arshf.DBAREntities)e.Tag).Dispose(); 77 | } 78 | 79 | private void btn_showfolder_Click(object sender, EventArgs e) 80 | { 81 | Process.Start(@".\Files"); 82 | 83 | } 84 | 85 | private async void btn1_Click(object sender, EventArgs e) 86 | { 87 | var ExFile = gridView1.GetRowCellValue(0, "FileName1"); 88 | if (ExFile == null) 89 | { 90 | MessageBox.Show("لا يوجد ملف "); 91 | 92 | } 93 | else 94 | { 95 | loading.Visible = true; 96 | var rs = await Task.Run(() => WriteFile1()); 97 | if (rs == true) 98 | { 99 | Process.Start(path); 100 | 101 | } 102 | else 103 | { 104 | MessageBox.Show("لا يمكن كتابة الملف "); 105 | } 106 | loading.Visible = false; 107 | } 108 | 109 | } 110 | 111 | private bool WriteFile1() 112 | { 113 | try 114 | { 115 | db = new DBAREntities(); 116 | FileName = db.TBArchiveFiles.Where(X => X.ID == id).Select(x => x.FileName1).FirstOrDefault(); 117 | FileExt = db.TBArchiveFiles.Where(X => X.ID == id).Select(x => x.FileExt1).FirstOrDefault(); 118 | FileFile = db.TBArchiveFiles.Where(X => X.ID == id).Select(x => x.FileFile1).FirstOrDefault(); 119 | path = @".\Files\" + FileName + FileExt; 120 | File.WriteAllBytes(path, FileFile); 121 | state = true; 122 | } 123 | catch { state = false; } 124 | return state; 125 | } 126 | private bool WriteFile2() 127 | { 128 | try 129 | { 130 | db = new DBAREntities(); 131 | FileName = db.TBArchiveFiles.Where(X => X.ID == id).Select(x => x.FileName2).FirstOrDefault(); 132 | FileExt = db.TBArchiveFiles.Where(X => X.ID == id).Select(x => x.FileExt2).FirstOrDefault(); 133 | FileFile = db.TBArchiveFiles.Where(X => X.ID == id).Select(x => x.FileFile2).FirstOrDefault(); 134 | path = @".\Files\" + FileName + FileExt; 135 | File.WriteAllBytes(path, FileFile); 136 | state = true; 137 | } 138 | catch { state = false; } 139 | return state; 140 | } 141 | private bool WriteFile3() 142 | { 143 | try 144 | { 145 | db = new DBAREntities(); 146 | FileName = db.TBArchiveFiles.Where(X => X.ID == id).Select(x => x.FileName3).FirstOrDefault(); 147 | FileExt = db.TBArchiveFiles.Where(X => X.ID == id).Select(x => x.FileExt3).FirstOrDefault(); 148 | FileFile = db.TBArchiveFiles.Where(X => X.ID == id).Select(x => x.FileFile3).FirstOrDefault(); 149 | path = @".\Files\" + FileName + FileExt; 150 | File.WriteAllBytes(path, FileFile); 151 | state = true; 152 | } 153 | catch { state = false; } 154 | return state; 155 | } 156 | 157 | private async void btn2_Click(object sender, EventArgs e) 158 | { 159 | var ExFile = gridView1.GetRowCellValue(0, "FileName2"); 160 | if (ExFile == null) 161 | { 162 | MessageBox.Show("لا يوجد ملف "); 163 | 164 | } 165 | else 166 | { 167 | loading.Visible = true; 168 | var rs = await Task.Run(() => WriteFile2()); 169 | if (rs == true) 170 | { 171 | Process.Start(path); 172 | 173 | } 174 | else 175 | { 176 | MessageBox.Show("لا يمكن كتابة الملف "); 177 | } 178 | loading.Visible = false; 179 | } 180 | } 181 | 182 | private async void btn3_Click(object sender, EventArgs e) 183 | { 184 | var ExFile = gridView1.GetRowCellValue(0, "FileName3"); 185 | if (ExFile == null) 186 | { 187 | MessageBox.Show("لا يوجد ملف "); 188 | 189 | } 190 | else 191 | { 192 | loading.Visible = true; 193 | var rs = await Task.Run(() => WriteFile3()); 194 | if (rs == true) 195 | { 196 | Process.Start(path); 197 | 198 | } 199 | else 200 | { 201 | MessageBox.Show("لا يمكن كتابة الملف "); 202 | } 203 | loading.Visible = false; 204 | } 205 | } 206 | 207 | private async void btn4_Click(object sender, EventArgs e) 208 | { 209 | var ExFile = gridView1.GetRowCellValue(0, "FileName4"); 210 | if (ExFile == null) 211 | { 212 | MessageBox.Show("لا يوجد ملف "); 213 | 214 | } 215 | else 216 | { 217 | loading.Visible = true; 218 | var rs = await Task.Run(() => WriteFile4()); 219 | if (rs == true) 220 | { 221 | Process.Start(path); 222 | 223 | } 224 | else 225 | { 226 | MessageBox.Show("لا يمكن كتابة الملف "); 227 | } 228 | loading.Visible = false; 229 | } 230 | } 231 | 232 | private async void btn5_Click(object sender, EventArgs e) 233 | { 234 | var ExFile = gridView1.GetRowCellValue(0, "FileName5"); 235 | if (ExFile == null) 236 | { 237 | MessageBox.Show("لا يوجد ملف "); 238 | 239 | } 240 | else 241 | { 242 | loading.Visible = true; 243 | var rs = await Task.Run(() => WriteFile5()); 244 | if (rs == true) 245 | { 246 | Process.Start(path); 247 | 248 | } 249 | else 250 | { 251 | MessageBox.Show("لا يمكن كتابة الملف "); 252 | } 253 | loading.Visible = false; 254 | } 255 | } 256 | 257 | private bool WriteFile4() 258 | { 259 | try 260 | { 261 | db = new DBAREntities(); 262 | FileName = db.TBArchiveFiles.Where(X => X.ID == id).Select(x => x.FileName4).FirstOrDefault(); 263 | FileExt = db.TBArchiveFiles.Where(X => X.ID == id).Select(x => x.FileExt4).FirstOrDefault(); 264 | FileFile = db.TBArchiveFiles.Where(X => X.ID == id).Select(x => x.FileFile4).FirstOrDefault(); 265 | path = @".\Files\" + FileName + FileExt; 266 | File.WriteAllBytes(path, FileFile); 267 | state = true; 268 | } 269 | catch { state = false; } 270 | return state; 271 | } 272 | private bool WriteFile5() 273 | { 274 | try 275 | { 276 | db = new DBAREntities(); 277 | FileName = db.TBArchiveFiles.Where(X => X.ID == id).Select(x => x.FileName5).FirstOrDefault(); 278 | FileExt = db.TBArchiveFiles.Where(X => X.ID == id).Select(x => x.FileExt5).FirstOrDefault(); 279 | FileFile = db.TBArchiveFiles.Where(X => X.ID == id).Select(x => x.FileFile5).FirstOrDefault(); 280 | path = @".\Files" + FileName + FileExt; 281 | File.WriteAllBytes(path, FileFile); 282 | state = true; 283 | } 284 | catch { state = false; } 285 | return state; 286 | } 287 | } 288 | } -------------------------------------------------------------------------------- /Arshf/AddPage/AddDep.resx: -------------------------------------------------------------------------------- 1 | 2 | 3 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | text/microsoft-resx 110 | 111 | 112 | 2.0 113 | 114 | 115 | System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 116 | 117 | 118 | System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 119 | 120 | 121 | 122 | 123 | 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 168 | SUVORK5CYII= 169 | 170 | 171 | 172 | 17, 17 173 | 174 | 175 | 176 | iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAABl0RVh0U29m 177 | dHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAAhdEVYdFRpdGxlAEFwcGx5O09LO0NoZWNrO0JhcnM7 178 | UmliYm9uO2RjyGgAAAFKSURBVFhHxdAxTgNBEARA2wEpiH9hJETCI0j5Ck8gxI+AABAPgoCj27q1eoa+ 179 | 27XkW4KS3KOd65FXwzD8KzvsyQ57ssOe7LCnEB6eHhch399oH4WQF09l/PYVvMKFdh5+UFlYAMu/YIAP 180 | OBzR4wAtL/hPrHsc4MqZr0vnkgdUy2mpA5rKKQQ8OIXmcgoBj9Q65RZHlVMIeFjcwzOcyazm6HIKAY+J 181 | 5T/AD+yg5YjJcggdWQh4fAelvKgdMVtO2pGFgMfn8A76MZo6olpO2pGFMC60HtFUTtqRhSBLtSOay0k7 182 | shDS4tQRL9BcTtqRhWCWp45QLN+C29/TjiwEtwxzR1TLSTuyENzyiEd8gpZ/ww2494F2ZCG4ZXEJ5QiW 183 | 34J794d2ZCG45YRHvEFzOWlHFoJbNjZmNks7MjvsyQ57ssOe7LAnO+xnWP0CbFjkt+hdVzwAAAAASUVO 184 | RK5CYII= 185 | 186 | 187 | -------------------------------------------------------------------------------- /Arshf/AddPage/AddArchiveCategory.resx: -------------------------------------------------------------------------------- 1 | 2 | 3 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | text/microsoft-resx 110 | 111 | 112 | 2.0 113 | 114 | 115 | System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 116 | 117 | 118 | System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 119 | 120 | 121 | 122 | 123 | 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 168 | SUVORK5CYII= 169 | 170 | 171 | 172 | 17, 17 173 | 174 | 175 | 176 | iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAABl0RVh0U29m 177 | dHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAAhdEVYdFRpdGxlAEFwcGx5O09LO0NoZWNrO0JhcnM7 178 | UmliYm9uO2RjyGgAAAFKSURBVFhHxdAxTgNBEARA2wEpiH9hJETCI0j5Ck8gxI+AABAPgoCj27q1eoa+ 179 | 27XkW4KS3KOd65FXwzD8KzvsyQ57ssOe7LCnEB6eHhch399oH4WQF09l/PYVvMKFdh5+UFlYAMu/YIAP 180 | OBzR4wAtL/hPrHsc4MqZr0vnkgdUy2mpA5rKKQQ8OIXmcgoBj9Q65RZHlVMIeFjcwzOcyazm6HIKAY+J 181 | 5T/AD+yg5YjJcggdWQh4fAelvKgdMVtO2pGFgMfn8A76MZo6olpO2pGFMC60HtFUTtqRhSBLtSOay0k7 182 | shDS4tQRL9BcTtqRhWCWp45QLN+C29/TjiwEtwxzR1TLSTuyENzyiEd8gpZ/ww2494F2ZCG4ZXEJ5QiW 183 | 34J794d2ZCG45YRHvEFzOWlHFoJbNjZmNks7MjvsyQ57ssOe7LAnO+xnWP0CbFjkt+hdVzwAAAAASUVO 184 | RK5CYII= 185 | 186 | 187 | -------------------------------------------------------------------------------- /Arshf/AddPage/LoginFrom.Designer.cs: -------------------------------------------------------------------------------- 1 | 2 | namespace Arshf.AddPage 3 | { 4 | partial class LoginFrom 5 | { 6 | /// 7 | /// Required designer variable. 8 | /// 9 | private System.ComponentModel.IContainer components = null; 10 | 11 | /// 12 | /// Clean up any resources being used. 13 | /// 14 | /// true if managed resources should be disposed; otherwise, false. 15 | protected override void Dispose(bool disposing) 16 | { 17 | if (disposing && (components != null)) 18 | { 19 | components.Dispose(); 20 | } 21 | base.Dispose(disposing); 22 | } 23 | 24 | #region Windows Form Designer generated code 25 | 26 | /// 27 | /// Required method for Designer support - do not modify 28 | /// the contents of this method with the code editor. 29 | /// 30 | private void InitializeComponent() 31 | { 32 | this.components = new System.ComponentModel.Container(); 33 | System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(LoginFrom)); 34 | this.panel1 = new System.Windows.Forms.Panel(); 35 | this.btn_add = new DevExpress.XtraEditors.SimpleButton(); 36 | this.toastNotificationsManager1 = new DevExpress.XtraBars.ToastNotifications.ToastNotificationsManager(this.components); 37 | this.loading = new DevExpress.XtraWaitForm.ProgressPanel(); 38 | this.panel2 = new System.Windows.Forms.Panel(); 39 | this.edt_password = new DevExpress.XtraEditors.TextEdit(); 40 | this.edt_username = new DevExpress.XtraEditors.TextEdit(); 41 | this.label4 = new System.Windows.Forms.Label(); 42 | this.label3 = new System.Windows.Forms.Label(); 43 | this.panel3 = new System.Windows.Forms.Panel(); 44 | this.pictureBox1 = new System.Windows.Forms.PictureBox(); 45 | this.label2 = new System.Windows.Forms.Label(); 46 | this.panel1.SuspendLayout(); 47 | ((System.ComponentModel.ISupportInitialize)(this.toastNotificationsManager1)).BeginInit(); 48 | this.panel2.SuspendLayout(); 49 | ((System.ComponentModel.ISupportInitialize)(this.edt_password.Properties)).BeginInit(); 50 | ((System.ComponentModel.ISupportInitialize)(this.edt_username.Properties)).BeginInit(); 51 | this.panel3.SuspendLayout(); 52 | ((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).BeginInit(); 53 | this.SuspendLayout(); 54 | // 55 | // panel1 56 | // 57 | this.panel1.Controls.Add(this.btn_add); 58 | this.panel1.Dock = System.Windows.Forms.DockStyle.Bottom; 59 | this.panel1.Location = new System.Drawing.Point(0, 591); 60 | this.panel1.Name = "panel1"; 61 | this.panel1.Size = new System.Drawing.Size(1103, 77); 62 | this.panel1.TabIndex = 0; 63 | // 64 | // btn_add 65 | // 66 | this.btn_add.Anchor = System.Windows.Forms.AnchorStyles.None; 67 | this.btn_add.Appearance.Font = new System.Drawing.Font("Cairo", 13.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); 68 | this.btn_add.Appearance.Options.UseFont = true; 69 | this.btn_add.ImageOptions.Image = ((System.Drawing.Image)(resources.GetObject("btn_add.ImageOptions.Image"))); 70 | this.btn_add.Location = new System.Drawing.Point(774, 8); 71 | this.btn_add.Name = "btn_add"; 72 | this.btn_add.Size = new System.Drawing.Size(317, 57); 73 | this.btn_add.TabIndex = 5; 74 | this.btn_add.Text = "دخول"; 75 | this.btn_add.Click += new System.EventHandler(this.btn_add_Click); 76 | // 77 | // toastNotificationsManager1 78 | // 79 | this.toastNotificationsManager1.ApplicationId = "cfcb4971-26aa-43fa-9cb6-09c2ad124f56"; 80 | this.toastNotificationsManager1.Notifications.AddRange(new DevExpress.XtraBars.ToastNotifications.IToastNotificationProperties[] { 81 | new DevExpress.XtraBars.ToastNotifications.ToastNotification("96616aac-b9fe-45d7-8bb1-5cd04f388f4c", ((System.Drawing.Image)(resources.GetObject("toastNotificationsManager1.Notifications"))), "تمت العملية بنجاح", "تمت العملية بنجاح", "تمت العملية بنجاح", DevExpress.XtraBars.ToastNotifications.ToastNotificationTemplate.ImageAndText01)}); 82 | // 83 | // loading 84 | // 85 | this.loading.Appearance.BackColor = System.Drawing.Color.Transparent; 86 | this.loading.Appearance.Options.UseBackColor = true; 87 | this.loading.Caption = "الرجاء الانتظار"; 88 | this.loading.Description = "العملية تجرى في الخلفية"; 89 | this.loading.Location = new System.Drawing.Point(45, 421); 90 | this.loading.Name = "loading"; 91 | this.loading.Size = new System.Drawing.Size(246, 66); 92 | this.loading.TabIndex = 4; 93 | this.loading.Text = "progressPanel1"; 94 | this.loading.Visible = false; 95 | // 96 | // panel2 97 | // 98 | this.panel2.Controls.Add(this.edt_password); 99 | this.panel2.Controls.Add(this.loading); 100 | this.panel2.Controls.Add(this.edt_username); 101 | this.panel2.Controls.Add(this.label4); 102 | this.panel2.Controls.Add(this.label3); 103 | this.panel2.Dock = System.Windows.Forms.DockStyle.Right; 104 | this.panel2.Location = new System.Drawing.Point(504, 0); 105 | this.panel2.Name = "panel2"; 106 | this.panel2.Size = new System.Drawing.Size(599, 591); 107 | this.panel2.TabIndex = 5; 108 | // 109 | // edt_password 110 | // 111 | this.edt_password.Location = new System.Drawing.Point(16, 277); 112 | this.edt_password.Name = "edt_password"; 113 | this.edt_password.Properties.Appearance.Font = new System.Drawing.Font("Cairo", 13.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); 114 | this.edt_password.Properties.Appearance.Options.UseFont = true; 115 | this.edt_password.Size = new System.Drawing.Size(326, 50); 116 | this.edt_password.TabIndex = 2; 117 | // 118 | // edt_username 119 | // 120 | this.edt_username.Location = new System.Drawing.Point(16, 177); 121 | this.edt_username.Name = "edt_username"; 122 | this.edt_username.Properties.Appearance.Font = new System.Drawing.Font("Cairo", 13.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); 123 | this.edt_username.Properties.Appearance.Options.UseFont = true; 124 | this.edt_username.Size = new System.Drawing.Size(326, 50); 125 | this.edt_username.TabIndex = 2; 126 | // 127 | // label4 128 | // 129 | this.label4.AutoSize = true; 130 | this.label4.Font = new System.Drawing.Font("Cairo", 18F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); 131 | this.label4.Location = new System.Drawing.Point(435, 271); 132 | this.label4.Name = "label4"; 133 | this.label4.Size = new System.Drawing.Size(152, 56); 134 | this.label4.TabIndex = 1; 135 | this.label4.Text = "كلمة السر"; 136 | // 137 | // label3 138 | // 139 | this.label3.AutoSize = true; 140 | this.label3.Font = new System.Drawing.Font("Cairo", 18F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); 141 | this.label3.Location = new System.Drawing.Point(377, 171); 142 | this.label3.Name = "label3"; 143 | this.label3.Size = new System.Drawing.Size(210, 56); 144 | this.label3.TabIndex = 1; 145 | this.label3.Text = "اسم المستخدم"; 146 | // 147 | // panel3 148 | // 149 | this.panel3.BackColor = System.Drawing.Color.Black; 150 | this.panel3.Controls.Add(this.pictureBox1); 151 | this.panel3.Controls.Add(this.label2); 152 | this.panel3.Dock = System.Windows.Forms.DockStyle.Fill; 153 | this.panel3.Location = new System.Drawing.Point(0, 0); 154 | this.panel3.Name = "panel3"; 155 | this.panel3.Size = new System.Drawing.Size(504, 591); 156 | this.panel3.TabIndex = 6; 157 | // 158 | // pictureBox1 159 | // 160 | this.pictureBox1.Image = ((System.Drawing.Image)(resources.GetObject("pictureBox1.Image"))); 161 | this.pictureBox1.Location = new System.Drawing.Point(91, 171); 162 | this.pictureBox1.Name = "pictureBox1"; 163 | this.pictureBox1.Size = new System.Drawing.Size(300, 306); 164 | this.pictureBox1.SizeMode = System.Windows.Forms.PictureBoxSizeMode.Zoom; 165 | this.pictureBox1.TabIndex = 0; 166 | this.pictureBox1.TabStop = false; 167 | // 168 | // label2 169 | // 170 | this.label2.AutoSize = true; 171 | this.label2.Font = new System.Drawing.Font("Cairo", 28.2F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); 172 | this.label2.ForeColor = System.Drawing.Color.Silver; 173 | this.label2.Location = new System.Drawing.Point(91, 80); 174 | this.label2.Name = "label2"; 175 | this.label2.Size = new System.Drawing.Size(319, 90); 176 | this.label2.TabIndex = 1; 177 | this.label2.Text = "تسجيل الدخول"; 178 | // 179 | // LoginFrom 180 | // 181 | this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 16F); 182 | this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; 183 | this.ClientSize = new System.Drawing.Size(1103, 668); 184 | this.Controls.Add(this.panel3); 185 | this.Controls.Add(this.panel2); 186 | this.Controls.Add(this.panel1); 187 | this.IconOptions.ShowIcon = false; 188 | this.MaximizeBox = false; 189 | this.MinimizeBox = false; 190 | this.Name = "LoginFrom"; 191 | this.RightToLeft = System.Windows.Forms.RightToLeft.Yes; 192 | this.ShowInTaskbar = false; 193 | this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen; 194 | this.Text = "تسجل الدخول"; 195 | this.TopMost = true; 196 | this.FormClosed += new System.Windows.Forms.FormClosedEventHandler(this.LoginFrom_FormClosed); 197 | this.panel1.ResumeLayout(false); 198 | ((System.ComponentModel.ISupportInitialize)(this.toastNotificationsManager1)).EndInit(); 199 | this.panel2.ResumeLayout(false); 200 | this.panel2.PerformLayout(); 201 | ((System.ComponentModel.ISupportInitialize)(this.edt_password.Properties)).EndInit(); 202 | ((System.ComponentModel.ISupportInitialize)(this.edt_username.Properties)).EndInit(); 203 | this.panel3.ResumeLayout(false); 204 | this.panel3.PerformLayout(); 205 | ((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).EndInit(); 206 | this.ResumeLayout(false); 207 | 208 | } 209 | 210 | #endregion 211 | 212 | private System.Windows.Forms.Panel panel1; 213 | public DevExpress.XtraEditors.SimpleButton btn_add; 214 | private DevExpress.XtraBars.ToastNotifications.ToastNotificationsManager toastNotificationsManager1; 215 | private DevExpress.XtraWaitForm.ProgressPanel loading; 216 | private System.Windows.Forms.Panel panel2; 217 | public DevExpress.XtraEditors.TextEdit edt_password; 218 | public DevExpress.XtraEditors.TextEdit edt_username; 219 | private System.Windows.Forms.Label label4; 220 | private System.Windows.Forms.Label label3; 221 | private System.Windows.Forms.Panel panel3; 222 | private System.Windows.Forms.PictureBox pictureBox1; 223 | private System.Windows.Forms.Label label2; 224 | } 225 | } --------------------------------------------------------------------------------