| | |
| | | using System.Data; |
| | | using System.Data.SqlClient; |
| | | using System.Dynamic; |
| | | using System.Text; |
| | | using Gs.Toolbox; |
| | | using Gs.Toolbox; |
| | | using Gs.Toolbox.ApiCore.Abstract.Mvc; |
| | | using Gs.Toolbox.ApiCore.Common.Mvc; |
| | | using Gs.Toolbox.ApiCore.Group; |
| | | using Microsoft.AspNetCore.Http; |
| | | using Microsoft.AspNetCore.Mvc; |
| | | using Newtonsoft.Json.Linq; |
| | | using System.Data; |
| | | using System.Data.SqlClient; |
| | | using System.Dynamic; |
| | | using System.Text; |
| | | using static Gs.Toolbox.UtilityHelper; |
| | | |
| | | |
| | |
| | | { |
| | | LogHelper.Debug(ToString(), ex.Message); |
| | | return ReturnDto<PageList<dynamic>>.QuickReturn(_pglist, |
| | | ReturnCode.Exception, ex.Message); |
| | | ReturnCode.Exception, ex.Message); |
| | | } |
| | | |
| | | return ReturnDto<PageList<dynamic>>.QuickReturn(_pglist, |
| | |
| | | |
| | | |
| | | /// <summary> |
| | | /// 修改工单状态 |
| | | /// 修改工单状态 |
| | | /// </summary> |
| | | /// <param name="mode"></param> |
| | | /// <returns></returns> |
| | |
| | | |
| | | |
| | | /// <summary> |
| | | /// 重新生成首检 |
| | | /// 重新生成首检 |
| | | /// </summary> |
| | | /// <param name="mode"></param> |
| | | /// <returns></returns> |
| | | [RequestMethod(RequestMethods.POST)] |
| | | public ReturnDto<ExpandoObject> EditModelSubmitShouJian( |
| | | [FromBody] dynamic mode) |
| | | public ReturnDto<ExpandoObject> EditModelSubmitShouJian([FromBody] dynamic mode) |
| | | { |
| | | string _guid = mode.guid; |
| | | string _inFieldValue = mode.inFieldValue; |
| | |
| | | new("@po_outMsg", SqlDbType.NVarChar, 300), |
| | | new("@po_outStatus", SqlDbType.Int), |
| | | new("@pi_user", _userCode), |
| | | new("@pi_DAA_guid", _guid) |
| | | new("@pi_DAA_guid", _guid), |
| | | }; |
| | | parameters[0].Direction = ParameterDirection.Output; |
| | | parameters[1].Direction = ParameterDirection.Output; |
| | |
| | | } |
| | | |
| | | |
| | | |
| | | /// <summary> |
| | | /// 增加或编辑实体 |
| | | /// </summary> |
| | |
| | | { |
| | | new("@outMsg", SqlDbType.NVarChar, 300), |
| | | new("@outSum", SqlDbType.Int), |
| | | new("@inOrderGuid", |
| | | CheckGuid(guid) ? guid : DBNull.Value), |
| | | new("@inOrderGuid",UtilityHelper.CheckGuid(guid)? guid : DBNull.Value), |
| | | new("@inSjxt", sjxt), |
| | | new("@inBz", bz), |
| | | new("@inSclx", sclx), |
| | | new("@inEdtUserGuid", _userGuid) |
| | | new("@inEdtUserGuid", _userGuid), |
| | | }; |
| | | parameters[0].Direction = ParameterDirection.Output; |
| | | parameters[1].Direction = ParameterDirection.Output; |
| | |
| | | } |
| | | } |
| | | } |
| | | |
| | | if (_outSum <= 0) |
| | | return ReturnDto<string>.QuickReturn(guid.ToString(), |
| | | ReturnCode.Exception, _outMsg); |
| | |
| | | dt.Fill(dset, "0"); |
| | | } |
| | | } |
| | | |
| | | conn.Close(); |
| | | } |
| | | } |
| | |
| | | var _dy = dset.Tables[0].TableToDynamicList(); |
| | | _pglist.list = _dy; |
| | | } |
| | | |
| | | return ReturnDto<PageList<dynamic>>.QuickReturn(_pglist, |
| | | ReturnCode.Success, "读取成功"); |
| | | } |
| | | |
| | | |
| | | /// <summary> |
| | | /// 选择dab弹窗体 |
| | | /// 选择dab弹窗体 |
| | | /// </summary> |
| | | /// <param name="model"></param> |
| | | /// <returns></returns> |
| | | [RequestMethod(RequestMethods.POST)] |
| | | public ReturnDto<PageList<dynamic>> GetListSelectDab( |
| | | [FromBody] dynamic model) |
| | | public ReturnDto<PageList<dynamic>> GetListSelectDab([FromBody] dynamic model) |
| | | { |
| | | int currentPage = model.currentPage; |
| | | int everyPageSize = model.everyPageSize; |
| | |
| | | dt.Fill(dset, "0"); |
| | | } |
| | | } |
| | | |
| | | conn.Close(); |
| | | } |
| | | } |
| | |
| | | return ReturnDto<PageList<dynamic>>.QuickReturn( |
| | | default(PageList<dynamic>), ReturnCode.Exception, "读取失败"); |
| | | } |
| | | |
| | | var _pglist = new PageList<dynamic> |
| | | { |
| | | total = 0, |
| | |
| | | var _dy = dset.Tables[0].TableToDynamicList(); |
| | | _pglist.list = _dy; |
| | | } |
| | | |
| | | return ReturnDto<PageList<dynamic>>.QuickReturn(_pglist, |
| | | ReturnCode.Success, "读取成功"); |
| | | } |
| | |
| | | new("@outMsg", SqlDbType.NVarChar, 300), |
| | | new("@outSum", SqlDbType.Int), |
| | | new("@inOrderGuid", |
| | | CheckGuid(guid) |
| | | UtilityHelper.CheckGuid(guid) |
| | | ? guid |
| | | : DBNull.Value), |
| | | new("@inEdtUserGuid", _userGuid), |
| | |
| | | } |
| | | |
| | | if (_outSum <= 0) |
| | | return ReturnDto<int>.QuickReturn(rtnInt, ReturnCode.Exception, |
| | | _outMsg); |
| | | return ReturnDto<int>.QuickReturn(rtnInt, ReturnCode.Exception, _outMsg); |
| | | return ReturnDto<int>.QuickReturn(rtnInt, ReturnCode.Success, _outMsg); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 工艺变更 |
| | | /// 工艺变更 |
| | | /// </summary> |
| | | /// <param name="model"></param> |
| | | /// <returns></returns> |
| | |
| | | _sb.Append("~"); |
| | | _sb.Append(_line); |
| | | } |
| | | |
| | | dynamic mObj = new ExpandoObject(); |
| | | mObj.outMsg = ""; |
| | | mObj.outSum = -1; |
| | |
| | | { |
| | | new("@outMsg", SqlDbType.NVarChar, 300), |
| | | new("@outSum", SqlDbType.Int), |
| | | new("@inOrderGuid", |
| | | CheckGuid(guid) ? guid : DBNull.Value), |
| | | new("@inOrderGuid", CheckGuid(guid) ? guid : DBNull.Value), |
| | | new("@inEdtUserGuid", _userGuid), |
| | | new("@inLineList", _sb.ToString()) |
| | | }; |
| | |
| | | } |
| | | } |
| | | } |
| | | |
| | | if (mObj.outSum <= 0) |
| | | return ReturnDto<dynamic>.QuickReturn(mObj, ReturnCode.Exception, |
| | | mObj.outMsg); |
| | | return ReturnDto<dynamic>.QuickReturn(mObj, ReturnCode.Success, |
| | | mObj.outMsg); |
| | | return ReturnDto<dynamic>.QuickReturn(mObj, ReturnCode.Exception, mObj.outMsg); |
| | | return ReturnDto<dynamic>.QuickReturn(mObj, ReturnCode.Success, mObj.outMsg); |
| | | } |
| | | |
| | | |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | /// <param name="query"></param> |
| | | /// <returns></returns> |
| | | [RequestMethod(RequestMethods.POST)] |
| | | public ReturnDto<List<dynamic>> GetGyList( |
| | | [FromBody] dynamic model) |
| | | [FromBody] dynamic model) |
| | | { |
| | | string daaGuid = model.guid; |
| | | var lst = new List<dynamic>(); |
| | | var dset = new DataSet(); |
| | | var sbSql = new StringBuilder(); |
| | | sbSql.Append( |
| | | " select * from [dbo].[WOMDAA_TECHNIQUE] where daaGuid='" + |
| | | daaGuid + "' order by processNo asc "); |
| | | System.Text.StringBuilder sbSql = new System.Text.StringBuilder(); |
| | | sbSql.Append(" select * from [dbo].[WOMDAA_TECHNIQUE] where daaGuid='" + daaGuid + "' order by processNo asc "); |
| | | try |
| | | { |
| | | dset = DbHelperSQL.Query(sbSql.ToString()); |
| | | dset = Gs.Toolbox.DbHelperSQL.Query(sbSql.ToString()); |
| | | } |
| | | catch (Exception ex) |
| | | { |
| | | LogHelper.Debug(ToString(), ex.Message); |
| | | } |
| | | |
| | | if (dset != null && dset.Tables.Count > 0 && |
| | | dset.Tables[0].Rows.Count > 0) //有数据 |
| | | lst = dset.Tables[0].TableToDynamicList(); |
| | |
| | | |
| | | |
| | | /// <summary> |
| | | /// 变更内包装数量 |
| | | /// 变更内包装数量 |
| | | /// </summary> |
| | | /// <param name="model"></param> |
| | | /// <returns></returns> |
| | |
| | | { |
| | | new("@outMsg", SqlDbType.NVarChar, 300), |
| | | new("@outSum", SqlDbType.Int), |
| | | new("@inOrderGuid", |
| | | CheckGuid(guid) ? guid : DBNull.Value), |
| | | new("@inOrderGuid", UtilityHelper.CheckGuid(guid) ? guid: DBNull.Value), |
| | | new("@inEdtUserGuid", _userGuid), |
| | | new("@inSl", sl) |
| | | }; |
| | |
| | | } |
| | | catch (Exception ex) |
| | | { |
| | | LogHelper.Debug(ToString(), |
| | | "prc_wom_daa_nbz error:" + ex.Message); |
| | | LogHelper.Debug(ToString(), "prc_wom_daa_nbz error:" + ex.Message); |
| | | _outMsg = ex.Message; |
| | | _outSum = -1; |
| | | } |
| | |
| | | } |
| | | |
| | | if (_outSum <= 0) |
| | | return ReturnDto<int>.QuickReturn(rtnInt, ReturnCode.Exception, |
| | | _outMsg); |
| | | return ReturnDto<int>.QuickReturn(rtnInt, ReturnCode.Exception, _outMsg); |
| | | return ReturnDto<int>.QuickReturn(rtnInt, ReturnCode.Success, _outMsg); |
| | | } |
| | | |
| | | } |