check-model.js 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889
  1. import {
  2. Base
  3. } from '../../static/util/base.js'
  4. class CheckModel extends Base {
  5. constructor() {
  6. super();
  7. }
  8. getSampleListByNJB(data,callBack) {
  9. var params = {
  10. url: '/ah/ahSampleSheet/getSampleListByNJB',
  11. data:data,
  12. sCallBack: function(res) {
  13. callBack && callBack(res.data)
  14. }
  15. }
  16. this.serviceRequest(params);
  17. }
  18. getSampleInfoByNJB(sampleSheetNumber,callBack) {
  19. var params = {
  20. url: '/ah/ahSampleSheet/getSampleInfoByNJB',
  21. data:{sampleSheetNumber},
  22. sCallBack: function(res) {
  23. callBack && callBack(res.data)
  24. }
  25. }
  26. this.serviceRequest(params);
  27. }
  28. submitSampleSheetNJB(id,callBack) {
  29. var params = {
  30. url: '/ah/ahSampleSheet/submitSampleSheetNJB',
  31. data:{id},
  32. sCallBack: function(res) {
  33. callBack && callBack(res.data)
  34. }
  35. }
  36. this.serviceRequest(params);
  37. }
  38. submitSampleSheet(data,callBack) {
  39. var params = {
  40. url: '/ah/ahCheckNak/submitSampleSheet',
  41. data:data,
  42. sCallBack: function(res) {
  43. callBack && callBack(res)
  44. }
  45. }
  46. this.serviceRequest(params);
  47. }
  48. /**
  49. * 查询抽样单详情
  50. * @param id
  51. * @param callBack
  52. */
  53. getAhSampleSheetDetail(id,callBack) {
  54. var params = {
  55. url: '/ah/ahSampleSheet/'+id,
  56. sCallBack: function(res) {
  57. callBack && callBack(res.data)
  58. }
  59. }
  60. this.serviceRequest(params);
  61. }
  62. /**
  63. * 获取本抽样单下面所有样品详细信息
  64. */
  65. getSampleSheetDetailData(data,callBack){
  66. const params = {
  67. url: '/ah/ahSampleDetail/list',
  68. type: 'get',
  69. data:data,
  70. sCallBack: function(res) {
  71. callBack && callBack(res.data)
  72. }
  73. }
  74. this.serviceRequest(params);
  75. }
  76. }
  77. const _checkModel = new CheckModel();
  78. export {
  79. _checkModel
  80. }