Nie możesz wybrać więcej, niż 25 tematów Tematy muszą się zaczynać od litery lub cyfry, mogą zawierać myślniki ('-') i mogą mieć do 35 znaków.
 
 
 
 
 
 

713 wiersze
19 KiB

  1. using Learun.Util;
  2. using System;
  3. using System.Data;
  4. using System.Collections.Generic;
  5. namespace Learun.Application.TwoDevelopment.EducationalAdministration
  6. {
  7. /// <summary>
  8. /// 版 本 Learun-ADMS-Ultimate V7.0.0 数字化智慧校园
  9. /// Copyright (c) 2013-2018 北京泉江科技有限公司
  10. /// 创 建:超级管理员
  11. /// 日 期:2019-02-21 16:53
  12. /// 描 述:学生学籍
  13. /// </summary>
  14. public class StuInfoBasicBLL : StuInfoBasicIBLL
  15. {
  16. private StuInfoBasicService stuInfoBasicService = new StuInfoBasicService();
  17. #region 获取数据
  18. /// <summary>
  19. /// 获取页面显示列表数据
  20. /// <summary>
  21. /// <param name="queryJson">查询参数</param>
  22. /// <returns></returns>
  23. public IEnumerable<StuInfoBasicEntity> GetPageList(Pagination pagination, string queryJson)
  24. {
  25. try
  26. {
  27. return stuInfoBasicService.GetPageList(pagination, queryJson);
  28. }
  29. catch (Exception ex)
  30. {
  31. if (ex is ExceptionEx)
  32. {
  33. throw;
  34. }
  35. else
  36. {
  37. throw ExceptionEx.ThrowBusinessException(ex);
  38. }
  39. }
  40. }
  41. /// <summary>
  42. /// 获取StuInfoBasic表实体数据
  43. /// <param name="keyValue">主键</param>
  44. /// <summary>
  45. /// <returns></returns>
  46. public StuInfoBasicEntity GetStuInfoBasicEntity(string keyValue)
  47. {
  48. try
  49. {
  50. return stuInfoBasicService.GetStuInfoBasicEntity(keyValue);
  51. }
  52. catch (Exception ex)
  53. {
  54. if (ex is ExceptionEx)
  55. {
  56. throw;
  57. }
  58. else
  59. {
  60. throw ExceptionEx.ThrowBusinessException(ex);
  61. }
  62. }
  63. }
  64. /// <summary>
  65. /// 获取准许毕业学生的专业
  66. /// <summary>
  67. /// <returns></returns>
  68. public List<CdMajorEntity> GetMajorInfoWithGraduation()
  69. {
  70. try
  71. {
  72. return stuInfoBasicService.GetMajorInfoWithGraduation();
  73. }
  74. catch (Exception ex)
  75. {
  76. if (ex is ExceptionEx)
  77. {
  78. throw;
  79. }
  80. else
  81. {
  82. throw ExceptionEx.ThrowBusinessException(ex);
  83. }
  84. }
  85. }
  86. /// <summary>
  87. /// 根据专业顺序生成毕业证号
  88. /// <summary>
  89. /// <returns></returns>
  90. public void CreateGraduateNoByMajor(string CityCode, string SchoolCode, string MajorList)
  91. {
  92. try
  93. {
  94. stuInfoBasicService.CreateGraduateNoByMajor(CityCode, SchoolCode, MajorList);
  95. }
  96. catch (Exception ex)
  97. {
  98. if (ex is ExceptionEx)
  99. {
  100. throw;
  101. }
  102. else
  103. {
  104. throw ExceptionEx.ThrowBusinessException(ex);
  105. }
  106. }
  107. }
  108. /// <summary>
  109. /// 获取StuInfoBasic表实体数据
  110. /// <param name="keyValue">主键</param>
  111. /// <summary>
  112. /// <returns></returns>
  113. public void DoCreateGraduateNo()
  114. {
  115. try
  116. {
  117. stuInfoBasicService.DoCreateGraduateNo();
  118. }
  119. catch (Exception ex)
  120. {
  121. if (ex is ExceptionEx)
  122. {
  123. throw;
  124. }
  125. else
  126. {
  127. throw ExceptionEx.ThrowBusinessException(ex);
  128. }
  129. }
  130. }
  131. /// <summary>
  132. /// 获取StuInfoBasic表实体数据
  133. /// <param name="keyValue">主键</param>
  134. /// <summary>
  135. /// <returns></returns>
  136. public StuInfoBasicEntity GetStuNoByAccount(string keyValue)
  137. {
  138. try
  139. {
  140. return stuInfoBasicService.GetStuNoByAccount(keyValue);
  141. }
  142. catch (Exception ex)
  143. {
  144. if (ex is ExceptionEx)
  145. {
  146. throw;
  147. }
  148. else
  149. {
  150. throw ExceptionEx.ThrowBusinessException(ex);
  151. }
  152. }
  153. }
  154. public List<string> GetSaveClassStudents(string account)
  155. {
  156. try
  157. {
  158. return stuInfoBasicService.GetSaveClassStudents(account);
  159. }
  160. catch (Exception ex)
  161. {
  162. if (ex is ExceptionEx)
  163. {
  164. throw;
  165. }
  166. else
  167. {
  168. throw ExceptionEx.ThrowBusinessException(ex);
  169. }
  170. }
  171. }
  172. public StuInfoBasicEntity GetStuInfoBasicEntityByStuNo(string enCode)
  173. {
  174. try
  175. {
  176. return stuInfoBasicService.GetStuInfoBasicEntityByStuNo(enCode);
  177. }
  178. catch (Exception ex)
  179. {
  180. if (ex is ExceptionEx)
  181. {
  182. throw;
  183. }
  184. else
  185. {
  186. throw ExceptionEx.ThrowBusinessException(ex);
  187. }
  188. }
  189. }
  190. public StuInfoBasicEntity GetStuInfoBasicEntityByStuName(string name)
  191. {
  192. try
  193. {
  194. return stuInfoBasicService.GetStuInfoBasicEntityByStuName(name);
  195. }
  196. catch (Exception ex)
  197. {
  198. if (ex is ExceptionEx)
  199. {
  200. throw;
  201. }
  202. else
  203. {
  204. throw ExceptionEx.ThrowBusinessException(ex);
  205. }
  206. }
  207. }
  208. public StuInfoBasicEntity GetStuInfoBasicEntityByStuNoOrStuName(string stuno, string stuname)
  209. {
  210. try
  211. {
  212. return stuInfoBasicService.GetStuInfoBasicEntityByStuNoOrStuName(stuno, stuname);
  213. }
  214. catch (Exception ex)
  215. {
  216. if (ex is ExceptionEx)
  217. {
  218. throw;
  219. }
  220. else
  221. {
  222. throw ExceptionEx.ThrowBusinessException(ex);
  223. }
  224. }
  225. }
  226. /// <summary>
  227. /// 获取左侧树形数据
  228. /// <summary>
  229. /// <returns></returns>
  230. public List<TreeModel> GetTree()
  231. {
  232. try
  233. {
  234. DataTable list = stuInfoBasicService.GetSqlTree();
  235. List<TreeModel> treeList = new List<TreeModel>();
  236. foreach (DataRow item in list.Rows)
  237. {
  238. TreeModel node = new TreeModel
  239. {
  240. id = item["classno"].ToString(),
  241. text = item["classname"].ToString(),
  242. value = item["classno"].ToString(),
  243. showcheck = false,
  244. checkstate = 0,
  245. isexpand = true,
  246. parentId = ""
  247. };
  248. treeList.Add(node);
  249. }
  250. return treeList.ToTree();
  251. }
  252. catch (Exception ex)
  253. {
  254. if (ex is ExceptionEx)
  255. {
  256. throw;
  257. }
  258. else
  259. {
  260. throw ExceptionEx.ThrowBusinessException(ex);
  261. }
  262. }
  263. }
  264. #endregion
  265. #region 提交数据
  266. /// <summary>
  267. /// 生成教师帐号
  268. /// </summary>
  269. public void GenerateAccout()
  270. {
  271. try
  272. {
  273. stuInfoBasicService.GenerateAccout();
  274. }
  275. catch (Exception ex)
  276. {
  277. if (ex is ExceptionEx)
  278. {
  279. throw;
  280. }
  281. else
  282. {
  283. throw ExceptionEx.ThrowBusinessException(ex);
  284. }
  285. }
  286. }
  287. public bool GetAny()
  288. {
  289. try
  290. {
  291. return stuInfoBasicService.GetAny();
  292. }
  293. catch (Exception ex)
  294. {
  295. if (ex is ExceptionEx)
  296. {
  297. throw;
  298. }
  299. else
  300. {
  301. throw ExceptionEx.ThrowBusinessException(ex);
  302. }
  303. }
  304. }
  305. public IEnumerable<StuInfoBasicEntity> GetAllList()
  306. {
  307. try
  308. {
  309. return stuInfoBasicService.GetAllList();
  310. }
  311. catch (Exception ex)
  312. {
  313. if (ex is ExceptionEx)
  314. {
  315. throw;
  316. }
  317. else
  318. {
  319. throw ExceptionEx.ThrowBusinessException(ex);
  320. }
  321. }
  322. }
  323. public IEnumerable<StuInfoBasicEntity> GetAllList(string ChangeType)
  324. {
  325. try
  326. {
  327. return stuInfoBasicService.GetAllList(ChangeType);
  328. }
  329. catch (Exception ex)
  330. {
  331. if (ex is ExceptionEx)
  332. {
  333. throw;
  334. }
  335. else
  336. {
  337. throw ExceptionEx.ThrowBusinessException(ex);
  338. }
  339. }
  340. }
  341. public IEnumerable<StuInfoBasicEntity> GetStuInfoByClassNo(string classNo)
  342. {
  343. try
  344. {
  345. return stuInfoBasicService.GetStuInfoByClassNo(classNo);
  346. }
  347. catch (Exception ex)
  348. {
  349. if (ex is ExceptionEx)
  350. {
  351. throw;
  352. }
  353. else
  354. {
  355. throw ExceptionEx.ThrowBusinessException(ex);
  356. }
  357. }
  358. }
  359. public void UpdateAccount()
  360. {
  361. try
  362. {
  363. stuInfoBasicService.UpdateAccount();
  364. }
  365. catch (Exception ex)
  366. {
  367. if (ex is ExceptionEx)
  368. {
  369. throw;
  370. }
  371. else
  372. {
  373. throw ExceptionEx.ThrowBusinessException(ex);
  374. }
  375. }
  376. }
  377. public void UpdateState(string keyValue, string state)
  378. {
  379. try
  380. {
  381. stuInfoBasicService.UpdateState(keyValue, state);
  382. }
  383. catch (Exception ex)
  384. {
  385. if (ex is ExceptionEx)
  386. {
  387. throw;
  388. }
  389. else
  390. {
  391. throw ExceptionEx.ThrowBusinessException(ex);
  392. }
  393. }
  394. }
  395. /// <summary>
  396. /// 删除实体数据
  397. /// <param name="keyValue">主键</param>
  398. /// <summary>
  399. /// <returns></returns>
  400. public void DeleteEntity(string keyValue)
  401. {
  402. try
  403. {
  404. stuInfoBasicService.DeleteEntity(keyValue);
  405. }
  406. catch (Exception ex)
  407. {
  408. if (ex is ExceptionEx)
  409. {
  410. throw;
  411. }
  412. else
  413. {
  414. throw ExceptionEx.ThrowBusinessException(ex);
  415. }
  416. }
  417. }
  418. /// <summary>
  419. /// 领取毕业证
  420. /// <param name="keyValue">主键</param>
  421. /// <summary>
  422. /// <returns></returns>
  423. public void GetCard(string keyValue, string status, StuInfoBasicEntity entity)
  424. {
  425. try
  426. {
  427. stuInfoBasicService.GetCard(keyValue, status, entity);
  428. }
  429. catch (Exception ex)
  430. {
  431. if (ex is ExceptionEx)
  432. {
  433. throw;
  434. }
  435. else
  436. {
  437. throw ExceptionEx.ThrowBusinessException(ex);
  438. }
  439. }
  440. }
  441. /// <summary>
  442. /// 图书资料归还
  443. /// <param name="keyValue">主键</param>
  444. /// <summary>
  445. /// <returns></returns>
  446. public void IsReturnBooks(string keyValue, string status)
  447. {
  448. try
  449. {
  450. stuInfoBasicService.IsReturnBooks(keyValue, status);
  451. }
  452. catch (Exception ex)
  453. {
  454. if (ex is ExceptionEx)
  455. {
  456. throw;
  457. }
  458. else
  459. {
  460. throw ExceptionEx.ThrowBusinessException(ex);
  461. }
  462. }
  463. }
  464. /// <summary>
  465. /// 就业协议备案
  466. /// <param name="keyValue">主键</param>
  467. /// <summary>
  468. /// <returns></returns>
  469. public void IsEmployAgree(string keyValue, string status)
  470. {
  471. try
  472. {
  473. stuInfoBasicService.IsEmployAgree(keyValue, status);
  474. }
  475. catch (Exception ex)
  476. {
  477. if (ex is ExceptionEx)
  478. {
  479. throw;
  480. }
  481. else
  482. {
  483. throw ExceptionEx.ThrowBusinessException(ex);
  484. }
  485. }
  486. }
  487. /// <summary>
  488. /// 学杂费结算
  489. /// <param name="keyValue">主键</param>
  490. /// <summary>
  491. /// <returns></returns>
  492. public void IsFeeSettle(string keyValue, string status)
  493. {
  494. try
  495. {
  496. stuInfoBasicService.IsFeeSettle(keyValue, status);
  497. }
  498. catch (Exception ex)
  499. {
  500. if (ex is ExceptionEx)
  501. {
  502. throw;
  503. }
  504. else
  505. {
  506. throw ExceptionEx.ThrowBusinessException(ex);
  507. }
  508. }
  509. }
  510. /// <summary>
  511. /// 办理退住手续
  512. /// <param name="keyValue">主键</param>
  513. /// <summary>
  514. /// <returns></returns>
  515. public void IsCheckOut(string keyValue, string status)
  516. {
  517. try
  518. {
  519. stuInfoBasicService.IsCheckOut(keyValue, status);
  520. }
  521. catch (Exception ex)
  522. {
  523. if (ex is ExceptionEx)
  524. {
  525. throw;
  526. }
  527. else
  528. {
  529. throw ExceptionEx.ThrowBusinessException(ex);
  530. }
  531. }
  532. }
  533. /// <summary>
  534. /// 校园卡注销
  535. /// <param name="keyValue">主键</param>
  536. /// <summary>
  537. /// <returns></returns>
  538. public void IsCardDeregistrate(string keyValue, string status)
  539. {
  540. try
  541. {
  542. stuInfoBasicService.IsCardDeregistrate(keyValue, status);
  543. }
  544. catch (Exception ex)
  545. {
  546. if (ex is ExceptionEx)
  547. {
  548. throw;
  549. }
  550. else
  551. {
  552. throw ExceptionEx.ThrowBusinessException(ex);
  553. }
  554. }
  555. }
  556. /// <summary>
  557. /// 档案与组织关系转出
  558. /// <param name="keyValue">主键</param>
  559. /// <summary>
  560. /// <returns></returns>
  561. public void IsFileTransfer(string keyValue, string status, string fort)
  562. {
  563. try
  564. {
  565. stuInfoBasicService.IsFileTransfer(keyValue, status, fort);
  566. }
  567. catch (Exception ex)
  568. {
  569. if (ex is ExceptionEx)
  570. {
  571. throw;
  572. }
  573. else
  574. {
  575. throw ExceptionEx.ThrowBusinessException(ex);
  576. }
  577. }
  578. }
  579. /// <summary>
  580. /// 毕业生归档
  581. /// <param name="keyValue">主键</param>
  582. /// <summary>
  583. /// <returns></returns>
  584. public void StuStore()
  585. {
  586. try
  587. {
  588. stuInfoBasicService.StuStore();
  589. }
  590. catch (Exception ex)
  591. {
  592. if (ex is ExceptionEx)
  593. {
  594. throw;
  595. }
  596. else
  597. {
  598. throw ExceptionEx.ThrowBusinessException(ex);
  599. }
  600. }
  601. }
  602. /// <summary>
  603. /// 审核全部
  604. /// </summary>
  605. public void CheckAll()
  606. {
  607. try
  608. {
  609. stuInfoBasicService.CheckAll();
  610. }
  611. catch (Exception ex)
  612. {
  613. if (ex is ExceptionEx)
  614. {
  615. throw;
  616. }
  617. else
  618. {
  619. throw ExceptionEx.ThrowBusinessException(ex);
  620. }
  621. }
  622. }
  623. /// <summary>
  624. /// 准许毕业
  625. /// </summary>
  626. public void AllowGraduate(string stuNo, string status)
  627. {
  628. try
  629. {
  630. stuInfoBasicService.AllowGraduate(stuNo, status);
  631. }
  632. catch (Exception ex)
  633. {
  634. if (ex is ExceptionEx)
  635. {
  636. throw;
  637. }
  638. else
  639. {
  640. throw ExceptionEx.ThrowBusinessException(ex);
  641. }
  642. }
  643. }
  644. public void SynPhoto()
  645. {
  646. try
  647. {
  648. stuInfoBasicService.SynPhoto();
  649. }
  650. catch (Exception ex)
  651. {
  652. if (ex is ExceptionEx)
  653. {
  654. throw;
  655. }
  656. else
  657. {
  658. throw ExceptionEx.ThrowBusinessException(ex);
  659. }
  660. }
  661. }
  662. /// <summary>
  663. /// 保存实体数据(新增、修改)
  664. /// <param name="keyValue">主键</param>
  665. /// <summary>
  666. /// <returns></returns>
  667. public void SaveEntity(string keyValue, StuInfoBasicEntity entity)
  668. {
  669. try
  670. {
  671. stuInfoBasicService.SaveEntity(keyValue, entity);
  672. }
  673. catch (Exception ex)
  674. {
  675. if (ex is ExceptionEx)
  676. {
  677. throw;
  678. }
  679. else
  680. {
  681. throw ExceptionEx.ThrowBusinessException(ex);
  682. }
  683. }
  684. }
  685. #endregion
  686. }
  687. }