APCGC_CBS.DAL/Admin/DALCust.cs

(开头部分) 8KB

这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。

using APCGC_CBS.Models.Admin;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Data.SqlClient;
using APCGC_CBS.DAL.DataAccess;
using System.Data;
using APCGC_CBS.Common;

namespace APCGC_CBS.DAL.Admin
{
   public class DALCust
    {
       public bool AddCust(Cust_Main cust)
       {
           string SQL = "Proc_AddCust";
           SqlParameter[] Para = new SqlParameter[]{
                  new SqlParameter("@LoginName",cust.LoginName),
                     new SqlParameter("@PassWord",DEncrypt.Encrypt(cust.PassWord)),
               new SqlParameter("@Cust_Name",cust.Cust_Name),
                 new SqlParameter("@Cust_Phone",cust.Cust_Phone),
                   new SqlParameter("@Cust_Age",cust.Cust_Age),
                     new SqlParameter("@Role_ID",cust.Role_ID),
                       new SqlParameter("@Cust_Sex",cust.Cust_Sex),
                            new SqlParameter("@IDCard",cust.IDCard),
                               new SqlParameter("@CreateUSERID",cust.CreateUSERID)
           };
           return DbHelperSQL.RunProcReturnRows(SQL,Para)>0;
       }

       public DataTable GetCustByCustID(int Cust_ID)
       {
           string SQL = @"SELECT * FROM V_GetCustList Where Cust_ID=@Cust_ID";
           SqlParameter[] Para = new SqlParameter[] { new SqlParameter("@Cust_ID",Cust_ID)};
           return DbHelperSQL.Query(SQL, Para).Tables[0];
       }

       public bool EditCust(Cust_Main cust)
       {
           string SQL = "Proc_EditCust";
           SqlParameter[] Para = new SqlParameter[]{
                  new SqlParameter("@Cust_ID",cust.Cust_ID),
                  new SqlParameter("@LoginName",cust.LoginName),
                //     new SqlParameter("@PassWord",DEncrypt.Encrypt(cust.PassWord)),
               new SqlParameter("@Cust_Name",cust.Cust_Name),
                 new SqlParameter("@Cust_Phone",cust.Cust_Phone),
                   new SqlParameter("@Cust_Age",cust.Cust_Age),
                     new SqlParameter("@Role_ID",cust.Role_ID),
                       new SqlParameter("@Cust_Sex",cust.Cust_Sex),
                            new SqlParameter("@IDCard",cust.IDCard)
                          
           };
           return DbHelperSQL.RunProcReturnRows(SQL, Para) > 0;
       }

       public DataTable GetRoleList()
       {
           string SQL = @"SELECT * FROM dbo.Sys_Roles WHERE Status=0";
后面还有 140 行代码,购买后查看完整代码

24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明

AI 解读 AI

登录后可用,每次 10 算力,解读结果公开显示在下面。

还没有人解读过这个文件。