private void IsUplod(HttpContext context) { int value = base.GetIntParam(context, "AttributeId", false).Value; bool value2 = base.GetBoolParam(context, "UseAttributeImage", false).Value; int value3 = base.GetIntParam(context, "typeId", false).Value; AttributeInfo attributeInfo = new AttributeInfo(); attributeInfo.AttributeId = value; bool flag = false; if (value2) { flag = false; } else { flag = true; if (ProductTypeHelper.HasSetUseImg(value3) > 0) { throw new HidistroAshxException("已有其他规格可上传图片,最多只有一个规格允许上传商品规格图!"); } } attributeInfo.UseAttributeImage = flag; if (ProductTypeHelper.UpdateIsUseAttribute(attributeInfo)) { base.ReturnSuccessResult(context, "", 0, true); } }