sync
This commit is contained in:
@ -3,6 +3,7 @@ using Foresight.Fleet.Services;
|
||||
using Foresight.Fleet.Services.Asset;
|
||||
using Foresight.Fleet.Services.AssetHealth;
|
||||
using Foresight.Fleet.Services.Device;
|
||||
using Foresight.Fleet.Services.User;
|
||||
using Foresight.ServiceModel;
|
||||
using IronIntel.Contractor.Machines;
|
||||
using IronIntel.Contractor.Maintenance;
|
||||
@ -189,6 +190,8 @@ namespace IronIntel.Contractor.Site.Asset
|
||||
var session = GetCurrentLoginSession();
|
||||
if (session != null)
|
||||
{
|
||||
if (!CheckRight(SystemParams.CompanyID, Foresight.Fleet.Services.User.Feature.MANAGE_ASSETS))
|
||||
return "";
|
||||
string clientdata = HttpUtility.HtmlDecode(Request.Params["ClientData"]);
|
||||
AssetDetailItem2 asset = JsonConvert.DeserializeObject<AssetDetailItem2>(clientdata);
|
||||
|
||||
@ -216,7 +219,8 @@ namespace IronIntel.Contractor.Site.Asset
|
||||
var oldMachine = client.GetAssetDetailInfo2(customerid, asset.ID);
|
||||
asset.EngineHours = oldMachine.EngineHours;//EngineHours单独保存
|
||||
var user = UserManagement.GetUserByIID(session.User.UID);
|
||||
if (user.UserType < UserTypes.Admin)
|
||||
bool permission = CheckRight(SystemParams.CompanyID, Feature.MANAGE_ASSETS);
|
||||
if (!permission)
|
||||
{
|
||||
asset.VIN = oldMachine.VIN;
|
||||
asset.MakeID = oldMachine.MakeID;
|
||||
|
Reference in New Issue
Block a user