bklLiudl
2025-04-07 4e8f58cb41c7b6d570fd1979d80f74ab8a4d00c2
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
31
32
33
34
35
36
37
38
39
40
41
using System;
using System.Collections.Generic;
using System.Linq;
using System.Linq.Expressions;
using System.Text;
using System.Threading.Tasks;
using SqlSugar;
using WMS.Entity.Context;
using WMS.Entity.SysEntity;
using WMS.IDAL.ISysInterface;
 
namespace WMS.DAL.SysInfrastructure
{
    public class StorageAreaRepository: BaseRepository<SysStorageArea>,IStorageAreaRepository
    {
        public static readonly SqlSugarScope Db = DataContext.Db;  
        public StorageAreaRepository() : base(Db)
        {
        }
       
        /// <summary>
        /// 修改库区域状态信息
        /// </summary>
        /// <param name="model">实体类</param>
        /// <returns>是否成功</returns>
        public int EditStorageAreaStatus(SysStorageArea model)
        {
            try
            {
                var num =  Db.Updateable(model).UpdateColumns(m => new {m.Status, m.UpdateTime, m.UpdateUser}).ExecuteCommand();
                return num;
            }
            catch (Exception e)
            {
                throw new Exception(e.Message);
            }
        }
        
 
    }
}