public void delSB_ZZS_YBNSR_Public(ref JObject re_json) { string id = ""; string tbrq = ""; string rqQ = ""; string rqZ = ""; GTXResult resultq = GTXMethod.GetGuangXiYSBQC(); if (resultq.IsSuccess) { List <GDTXGuangXiUserYSBQC> ysbqclist = JsonConvert.DeserializeObject <List <GDTXGuangXiUserYSBQC> >(resultq.Data.ToString()); if (ysbqclist.Count > 0) { foreach (GDTXGuangXiUserYSBQC item in ysbqclist) { if (item.BDDM == "FJSSB") { id = item.Id.ToString(); tbrq = item.HappenDate; rqQ = item.SKSSQQ; rqZ = item.SKSSQZ; } } } } re_json["data"]["HEAD"]["TBRQ"] = new JValue(tbrq); re_json["data"]["HEAD"]["SSSQ_Q"] = new JValue(rqQ); re_json["data"]["HEAD"]["SSSQ_Z"] = new JValue(rqZ); GTXResult gr = GTXMethod.DeleteUserReportData(id, ""); }
public JObject POSTgetSB_SBJG() { JObject re_json = new JObject(); string str = System.IO.File.ReadAllText(System.Web.HttpContext.Current.Server.MapPath("getSB_SBJG.json")); re_json = JsonConvert.DeserializeObject <JObject>(str); JArray RESULT = new JArray(); GTXResult resultq = GTXMethod.GetGuangXiYSBQC(); if (resultq.IsSuccess) { List <GDTXGuangXiUserYSBQC> ysbqclist = JsonConvert.DeserializeObject <List <GDTXGuangXiUserYSBQC> >(resultq.Data.ToString()); ysbqclist = ysbqclist.Where(a => a.SBZT == "已申报").ToList(); for (int i = 0; i < ysbqclist.Count; i++) { JObject RESULT_JO = new JObject(); RESULT_JO["SBRQ"] = ysbqclist[i].HappenDate; RESULT_JO["YZPZXH"] = "0"; RESULT_JO["SSSQ_Z"] = ysbqclist[i].SKSSQZ; RESULT_JO["SBXMMC"] = ysbqclist[i].TaskName; RESULT_JO["NSRLX_DM"] = ""; RESULT_JO["ROWNO"] = i + 1; RESULT_JO["SSSQ_Q"] = ysbqclist[i].SKSSQQ; RESULT_JO["SBJG_MS"] = "申报成功"; RESULT_JO["SJLY"] = "JS"; RESULT.Add(RESULT_JO); } } re_json["data"]["RESULT"] = RESULT; return(re_json); }
public HttpResponseMessage selectGnmkByYhidPidSb(string callback) { string return_str = ""; string str = System.IO.File.ReadAllText(System.Web.HttpContext.Current.Server.MapPath("selectGnmkByYhidPidSb.xgm.json")); JObject return_j = JsonConvert.DeserializeObject<JObject>(str); JArray list_ja = (JArray)return_j["list"]; for (int i = 0; i < list_ja.Count; i++) { JObject jo = (JObject)list_ja[i]; if (jo["SJ_MKXKMC"].ToString() != "增值税(一般纳税人适用)" && jo["SJ_MKXKMC"].ToString() != "增值税(小规模纳税人适用)查账征收" && jo["SJ_MKXKMC"].ToString() != "居民企业(查账征收)企业所得税月(季)度申报" && jo["SJ_MKXKMC"].ToString() != "财务报告报送与信息采集2013(小企业会计准则-月季)" && jo["MKXK_MC"].ToString() != "附加税(费)申报(增值税)" && jo["MKXK_MC"].ToString() != "印花税申报") { jo["MKXK_URL_PT"] = ""; } } GTXResult resultq = GTXMethod.GetGuangXiYSBQC(); if (resultq.IsSuccess) { List<GDTXGuangXiUserYSBQC> ysbqclist = JsonConvert.DeserializeObject<List<GDTXGuangXiUserYSBQC>>(resultq.Data.ToString()); if (ysbqclist.Count > 0) { if (ysbqclist.Where(a => a.BDDM == "XGMZZS").ToList().Count == 1) { } else { JArray list_ja_xgm = JArray.FromObject(list_ja.Where(a => a["SJ_MKXKMC"].ToString() == "增值税(小规模纳税人适用)查账征收" || a["MKXK_MC"].ToString() == "增值税(小规模纳税人适用)查账征收")); for (int j = list_ja.Count - 1; j >= 0; j--) { IEnumerable<JToken> ijt = list_ja_xgm.Where(a => a.ToString().Equals(list_ja[j].ToString())); if (ijt.Count() > 0) { list_ja.RemoveAt(j); } } string s = System.IO.File.ReadAllText(System.Web.HttpContext.Current.Server.MapPath("menutree.ybnsr.json")); list_ja.Merge(JsonConvert.DeserializeObject<JArray>(s)); } } } return_str = callback + "(" + JsonConvert.SerializeObject(return_j) + ")"; return new HttpResponseMessage() { Content = new StringContent(return_str, System.Text.Encoding.UTF8, "application/json") }; }
public JObject POSTgetNsrlx() { JArray ysbqc_ja = new JArray(); JObject re_json = new JObject(); string str = System.IO.File.ReadAllText(System.Web.HttpContext.Current.Server.MapPath("getNsrlx.json")); re_json = JsonConvert.DeserializeObject <JObject>(str); GTXResult resultq = GTXMethod.GetGuangXiYSBQC(); if (resultq.IsSuccess) { List <GDTXGuangXiUserYSBQC> ysbqclist = JsonConvert.DeserializeObject <List <GDTXGuangXiUserYSBQC> >(resultq.Data.ToString()); if (ysbqclist.Count > 0) { ysbqclist = ysbqclist.Where(a => a.BDDM != "YHSSB").ToList(); foreach (GDTXGuangXiUserYSBQC i in ysbqclist) { JObject jo = new JObject(); jo["NSQX"] = "0"; jo["PREMONTH"] = "N"; jo["KKBZ"] = "Y"; jo["FJSBZ"] = "0"; jo["SKZLMC"] = "正税"; jo["ZSPM_MC"] = ""; jo["GDSLX"] = "1"; jo["SBJG_DM"] = ""; jo["NSRSBH"] = ""; jo["SSSQ_Z"] = i.SKSSQZ; jo["NSRLX_MC"] = i.TaskName; jo["SBXMMC"] = i.TaskName; jo["ZSPM_DM"] = i.BDDM; jo["NSRLX_DM"] = "XX"; jo["SBJG_MS"] = i.SBZT; jo["SSSQ_Q"] = i.SKSSQQ; jo["ISFKJC"] = "Y"; jo["KKJG_MS"] = ""; jo["NEXTMONTH"] = "N"; ysbqc_ja.Add(jo); } re_json["data"] = ysbqc_ja; } } return(re_json); }
public JObject getSB_ZZS_XGMNSR_Public(ref JObject re_json, string SBBZL_DM) { string id = ""; string tbrq = ""; string rqQ = ""; string rqZ = ""; GTXResult resultq = GTXMethod.GetGuangXiYSBQC(); if (resultq.IsSuccess) { List <GDTXGuangXiUserYSBQC> ysbqclist = JsonConvert.DeserializeObject <List <GDTXGuangXiUserYSBQC> >(resultq.Data.ToString()); if (ysbqclist.Count > 0) { foreach (GDTXGuangXiUserYSBQC item in ysbqclist) { if (item.BDDM == "XGMZZS") { id = item.Id.ToString(); tbrq = item.HappenDate; rqQ = item.SKSSQQ; rqZ = item.SKSSQZ; } } } } re_json["data"]["HEAD"]["TBRQ"] = new JValue(tbrq); re_json["data"]["HEAD"]["SSSQ_Q"] = new JValue(rqQ); re_json["data"]["HEAD"]["SSSQ_Z"] = new JValue(rqZ); JObject data_json = new JObject(); GTXResult gr = GTXMethod.GetUserReportData(id, SBBZL_DM); if (gr.IsSuccess) { JArray jarr = new JArray(); jarr = JsonConvert.DeserializeObject <JArray>(gr.Data.ToString()); if (jarr.Count > 0) { byte[] bytes = Convert.FromBase64String(jarr[0]["dataValue"].ToString().Replace(" ", "+")); string dataValue = System.Text.Encoding.Default.GetString(bytes); data_json = JsonConvert.DeserializeObject <JObject>(dataValue); } } return(data_json); }
public JObject saveSB_YHS(string data) { JObject re_json = new JObject(); string id = ""; GTXResult resultq = GTXMethod.GetGuangXiYSBQC(); if (resultq.IsSuccess) { List <GDTXGuangXiUserYSBQC> ysbqclist = JsonConvert.DeserializeObject <List <GDTXGuangXiUserYSBQC> >(resultq.Data.ToString()); if (ysbqclist.Count > 0) { foreach (GDTXGuangXiUserYSBQC item in ysbqclist) { if (item.BDDM == "YHSSB") { id = item.Id.ToString(); } } } } List <GTXNameValue> nameList = new List <GTXNameValue>(); GTXNameValue nv = new GTXNameValue(); nv.key = "data"; byte[] bytes = Encoding.Default.GetBytes(JsonConvert.SerializeObject(data)); string _result = Convert.ToBase64String(bytes); nv.value = _result; nameList.Add(nv); GTXResult saveresult = GTXMethod.SaveUserReportData(JsonConvert.SerializeObject(nameList), id, ""); if (saveresult.IsSuccess) { string str = System.IO.File.ReadAllText(System.Web.HttpContext.Current.Server.MapPath("YHSSB.json")); re_json = JsonConvert.DeserializeObject <JObject>(str); GTXResult upresult = GTXMethod.UpdateYSBQC(id, "已申报"); } else { re_json["code"] = "-1"; re_json["msg"] = "操作失败"; } return(re_json); }
public JObject saveSB_FJS_ZB_Public(JObject DATA, string SBBZL_DM) { JObject return_j = new JObject(); string id = ""; GTXResult resultq = GTXMethod.GetGuangXiYSBQC(); if (resultq.IsSuccess) { List <GDTXGuangXiUserYSBQC> ysbqclist = JsonConvert.DeserializeObject <List <GDTXGuangXiUserYSBQC> >(resultq.Data.ToString()); if (ysbqclist.Count > 0) { foreach (GDTXGuangXiUserYSBQC item in ysbqclist) { if (item.BDDM == "FJSSB") { id = item.Id.ToString(); } } } } List <GTXNameValue> nameList = new List <GTXNameValue>(); GTXNameValue nv = new GTXNameValue(); nv.key = SBBZL_DM; byte[] bytes = Encoding.Default.GetBytes(JsonConvert.SerializeObject(DATA)); string _result = Convert.ToBase64String(bytes); nv.value = _result; nameList.Add(nv); GTXResult saveresult = GTXMethod.SaveUserReportData(JsonConvert.SerializeObject(nameList), id, ""); if (saveresult.IsSuccess) { return_j["code"] = "1"; return_j["msg"] = "操作成功"; } else { return_j["code"] = "-1"; return_j["msg"] = "操作失败"; } return(return_j); }
public HttpResponseMessage postgetMsgs(string callback) { string return_str = ""; JObject re_json = new JObject(); JArray ysbqc_ja = new JArray(); string str = System.IO.File.ReadAllText(System.Web.HttpContext.Current.Server.MapPath("getMsgs.json")); re_json = JsonConvert.DeserializeObject <JObject>(str); GTXResult resultq = GTXMethod.GetGuangXiYSBQC(); if (resultq.IsSuccess) { List <GDTXGuangXiUserYSBQC> ysbqclist = JsonConvert.DeserializeObject <List <GDTXGuangXiUserYSBQC> >(resultq.Data.ToString()); ysbqclist = ysbqclist.Where(a => a.SBZT != "已申报" && a.BDDM != "YHSSB").ToList(); for (int i = 0; i < ysbqclist.Count; i++) { JObject jo = new JObject(); jo["BLLX"] = "选办"; jo["DMV"] = "申报待办事项"; jo["CZDZ"] = ysbqclist[i].Url; jo["YWID"] = ysbqclist[i].Id; jo["TOTAL"] = ysbqclist.Count; jo["ROWNO"] = i + 1; jo["CLJGDM"] = "41"; jo["SXLX"] = "1"; jo["ID"] = ysbqclist[i].Id; jo["XTMC"] = "网上申报"; jo["SXMC"] = ysbqclist[i].TaskName; jo["SXRQ"] = ysbqclist[i].SBQX; jo["XTDM"] = "001"; ysbqc_ja.Add(jo); } } re_json["data"]["wddb"] = ysbqc_ja; return_str = callback + "(" + JsonConvert.SerializeObject(re_json) + ")"; return(new HttpResponseMessage() { Content = new StringContent(return_str, System.Text.Encoding.UTF8, "application/json") }); }
public void getZZS_XSSR(ref JObject re_json) { string id = ""; GTXResult resultq = GTXMethod.GetGuangXiYSBQC(); if (resultq.IsSuccess) { List <GDTXGuangXiUserYSBQC> ysbqclist = JsonConvert.DeserializeObject <List <GDTXGuangXiUserYSBQC> >(resultq.Data.ToString()); if (ysbqclist.Count > 0) { foreach (GDTXGuangXiUserYSBQC item in ysbqclist) { if (item.BDDM == "YBNSRZZS" || item.BDDM == "XGMZZS") { id = item.Id.ToString(); } } } } GTXResult gr = GTXMethod.GetUserReportData(id, "101011034"); if (gr.IsSuccess) { JArray jarr = new JArray(); jarr = JsonConvert.DeserializeObject <JArray>(gr.Data.ToString()); if (jarr.Count > 0) { byte[] bytes = Convert.FromBase64String(jarr[0]["dataValue"].ToString().Replace(" ", "+")); string dataValue = Encoding.Default.GetString(bytes); JObject data_json = JsonConvert.DeserializeObject <JObject>(dataValue); if (data_json.HasValues) { JArray data_body = (JArray)data_json["BODY"]; JArray re_DSLIST = (JArray)re_json["data"]["JCSJ"]["DSLIST"]; double XSSR = double.Parse(data_body[0]["COL09"].ToString()) + double.Parse(data_body[1]["COL09"].ToString()) + double.Parse(data_body[2]["COL09"].ToString()) + double.Parse(data_body[3]["COL09"].ToString()) + double.Parse(data_body[4]["COL09"].ToString()) + double.Parse(data_body[5]["COL09"].ToString()); re_DSLIST[0]["XSSR"] = new JValue(XSSR); re_DSLIST[1]["XSSR"] = new JValue(XSSR); re_DSLIST[2]["XSSR"] = new JValue(XSSR); } } } }
public JObject zfsbb() { string ZSPM_DM = System.Web.HttpContext.Current.Request["ZSPM_DM"]; JObject re_json = new JObject(); string str = System.IO.File.ReadAllText(System.Web.HttpContext.Current.Server.MapPath("zfsbb.json")); re_json = JsonConvert.DeserializeObject <JObject>(str); string id = ""; GTXResult resultq = GTXMethod.GetGuangXiYSBQC(); if (resultq.IsSuccess) { List <GDTXGuangXiUserYSBQC> ysbqclist = JsonConvert.DeserializeObject <List <GDTXGuangXiUserYSBQC> >(resultq.Data.ToString()); if (ysbqclist.Count > 0) { foreach (GDTXGuangXiUserYSBQC item in ysbqclist) { if (item.BDDM == ZSPM_DM) { id = item.Id.ToString(); } } } } GTXResult upresult = GTXMethod.UpdateYSBQC(id, "未申报"); if (upresult.IsSuccess) { GTXMethod.DeleteUserReportData(id, ""); re_json["code"] = "4"; re_json["msg"] = "作废成功"; } else { re_json["code"] = "-1"; re_json["msg"] = upresult.Message; } return(re_json); }
protected void Page_Load(object sender, EventArgs e) { GTXResult resultq = GTXMethod.GetGuangXiYSBQC(); if (resultq.IsSuccess) { List <GDTXGuangXiUserYSBQC> ysbqclist = JsonConvert.DeserializeObject <List <GDTXGuangXiUserYSBQC> >(resultq.Data.ToString()); if (ysbqclist.Count > 0) { foreach (GDTXGuangXiUserYSBQC item in ysbqclist) { if (item.BDDM == "YHSSB") { tbrq = item.HappenDate; slrq = item.HappenDate; rqQ = item.SKSSQQ; rqZ = item.SKSSQZ; } } } } GTXResult gr1 = GTXMethod.GetCompany(); if (gr1.IsSuccess) { JObject jo = new JObject(); jo = JsonConvert.DeserializeObject <JObject>(gr1.Data.ToString()); if (jo.HasValues) { JObject data_jo = jo; nsrsbh = data_jo["NSRSBH"].ToString(); slswjg = data_jo["ZGDSSWJFJMC"].ToString(); } } }
public JObject getSB_FJS_ZB_Public(ref JObject re_json, string SBBZL_DM) { string id = ""; string tbrq = ""; string rqQ = ""; string rqZ = ""; GTXResult resultq = GTXMethod.GetGuangXiYSBQC(); if (resultq.IsSuccess) { List <GDTXGuangXiUserYSBQC> ysbqclist = JsonConvert.DeserializeObject <List <GDTXGuangXiUserYSBQC> >(resultq.Data.ToString()); if (ysbqclist.Count > 0) { foreach (GDTXGuangXiUserYSBQC item in ysbqclist) { if (item.BDDM == "FJSSB") { id = item.Id.ToString(); tbrq = item.HappenDate; rqQ = item.SKSSQQ; rqZ = item.SKSSQZ; } } } } re_json["data"]["HEAD"]["TBRQ"] = new JValue(tbrq); re_json["data"]["HEAD"]["SSSQ_Q"] = new JValue(rqQ); re_json["data"]["HEAD"]["SSSQ_Z"] = new JValue(rqZ); JObject in_jo = (JObject)re_json["data"]["HEAD"]; GTXResult gr1 = GTXMethod.GetCompany(); if (gr1.IsSuccess) { JObject jo = new JObject(); jo = JsonConvert.DeserializeObject <JObject>(gr1.Data.ToString()); if (jo.HasValues) { JObject data_jo = jo; in_jo["NSRSBH"] = data_jo["NSRSBH"]; in_jo["LXFS"] = data_jo["LXDH"]; } } JObject data_json = new JObject(); GTXResult gr = GTXMethod.GetUserReportData(id, ""); if (gr.IsSuccess) { JArray jarr = new JArray(); jarr = JsonConvert.DeserializeObject <JArray>(gr.Data.ToString()); IEnumerable <JToken> ejt = jarr.Where(a => a["dataKey"].ToString() == SBBZL_DM); if (ejt.Count() == 1) { JObject jobj = (JObject)ejt.ElementAt(0); byte[] bytes = Convert.FromBase64String(jobj["dataValue"].ToString().Replace(" ", "+")); string dataValue = Encoding.Default.GetString(bytes); data_json = JsonConvert.DeserializeObject <JObject>(dataValue); } } return(data_json); }
public JObject extractSB_ZZS_YBNSR() { JObject re_json = new JObject(); string str = System.IO.File.ReadAllText(System.Web.HttpContext.Current.Server.MapPath("extractSB_ZZS_YBNSR.json")); re_json = JsonConvert.DeserializeObject <JObject>(str); string id = ""; GTXResult resultq = GTXMethod.GetGuangXiYSBQC(); if (resultq.IsSuccess) { List <GDTXGuangXiUserYSBQC> ysbqclist = JsonConvert.DeserializeObject <List <GDTXGuangXiUserYSBQC> >(resultq.Data.ToString()); if (ysbqclist.Count > 0) { foreach (GDTXGuangXiUserYSBQC item in ysbqclist) { if (item.BDDM == "YBNSRZZS") { id = item.Id.ToString(); } } } } GTXResult gr = GTXMethod.GetUserReportData(id, "101011034"); if (gr.IsSuccess) { JArray jarr = new JArray(); jarr = JsonConvert.DeserializeObject <JArray>(gr.Data.ToString()); if (jarr.Count > 0) { byte[] bytes = Convert.FromBase64String(jarr[0]["dataValue"].ToString().Replace(" ", "+")); string dataValue = Encoding.Default.GetString(bytes); JObject data_json = JsonConvert.DeserializeObject <JObject>(dataValue); if (data_json.HasValues) { JArray data_body = (JArray)data_json["BODY"]; JArray re_body = (JArray)re_json["data"]["BODY"]; double YBHW_LW_BYS_1 = double.Parse(data_body[0]["COL09"].ToString()) + double.Parse(data_body[3]["COL09"].ToString()); re_body[0]["YBHW_LW_BYS"] = new JValue(YBHW_LW_BYS_1); double YBHW_LW_BYS_4 = double.Parse(data_body[0]["COL07"].ToString()) + double.Parse(data_body[1]["COL07"].ToString()) + double.Parse(data_body[3]["COL07"].ToString()) + double.Parse(data_body[4]["COL07"].ToString()); re_body[3]["YBHW_LW_BYS"] = new JValue(YBHW_LW_BYS_4); double YBHW_LW_BYS_7 = double.Parse(data_body[19]["COL03"].ToString()); re_body[6]["YBHW_LW_BYS"] = new JValue(YBHW_LW_BYS_7); double YBHW_LW_BYS_8 = double.Parse(data_body[21]["COL03"].ToString()); re_body[7]["YBHW_LW_BYS"] = new JValue(YBHW_LW_BYS_8); double YBHW_LW_BYS_11 = double.Parse(data_body[0]["COL10"].ToString()) + double.Parse(data_body[1]["COL10"].ToString()) + double.Parse(data_body[2]["COL10"].ToString()) + double.Parse(data_body[3]["COL10"].ToString()) + double.Parse(data_body[4]["COL10"].ToString()) + double.Parse(data_body[5]["COL10"].ToString()); re_body[10]["YBHW_LW_BYS"] = new JValue(YBHW_LW_BYS_11); double YBHW_LW_BYS_21 = double.Parse(data_body[8]["COL10"].ToString()) + double.Parse(data_body[9]["COL10"].ToString()) + double.Parse(data_body[10]["COL10"].ToString()) + double.Parse(data_body[11]["COL10"].ToString()) + double.Parse(data_body[12]["COL10"].ToString()) + double.Parse(data_body[13]["COL10"].ToString()); re_body[20]["YBHW_LW_BYS"] = new JValue(YBHW_LW_BYS_21); } } } GTXResult gr2 = GTXMethod.GetUserReportData(id, "101011035"); if (gr2.IsSuccess) { JArray jarr = new JArray(); jarr = JsonConvert.DeserializeObject <JArray>(gr2.Data.ToString()); if (jarr.Count > 0) { byte[] bytes = Convert.FromBase64String(jarr[0]["dataValue"].ToString().Replace(" ", "+")); string dataValue = Encoding.Default.GetString(bytes); JObject data_json = JsonConvert.DeserializeObject <JObject>(dataValue); if (data_json.HasValues) { JArray data_body = (JArray)data_json["BODY"]; JArray re_body = (JArray)re_json["data"]["BODY"]; double YBHW_LW_BYS_12 = double.Parse(data_body[12]["SE"].ToString()); re_body[11]["YBHW_LW_BYS"] = new JValue(YBHW_LW_BYS_12); double YBHW_LW_BYS_14 = double.Parse(data_body[15]["FS"].ToString()); re_body[13]["YBHW_LW_BYS"] = new JValue(YBHW_LW_BYS_14); } } } return(re_json); }