KindModel.js 9.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323
  1. /**
  2. * Created by zhouy on 2018/10/18.
  3. */
  4. Ext.define('saas.view.document.kind.KindModel', {
  5. extend: 'Ext.app.ViewModel',
  6. alias: 'viewmodel.document-kind',
  7. data: {
  8. title: '客户类型'
  9. },
  10. stores: {
  11. customerkind: {
  12. fields:[
  13. {name: 'id', type: 'int'},
  14. {name: 'ck_name', type: 'string'}
  15. ],
  16. proxy: {
  17. type: 'ajax',
  18. url: '/api/document/customerkind/list',
  19. actionMethods: {
  20. read: 'GET'
  21. },
  22. reader: {
  23. type: 'json',
  24. rootProperty: 'data'
  25. }
  26. },
  27. pageSize: null,
  28. autoLoad: false,
  29. listeners: {
  30. beforeload: function (store, op) {
  31. Ext.apply(store.proxy.extraParams, {
  32. number: 1,
  33. size: 1000
  34. });
  35. }
  36. }
  37. },
  38. vendorkind:{
  39. fields:[
  40. {name: 'id', type: 'int'},
  41. {name: 'vk_name', type: 'string'}
  42. ],
  43. proxy: {
  44. type: 'ajax',
  45. url: '/api/document/vendorkind/list',
  46. actionMethods: {
  47. read: 'GET'
  48. },
  49. reader: {
  50. type: 'json',
  51. rootProperty: 'data'
  52. }
  53. },
  54. pageSize: null,
  55. autoLoad: false,
  56. listeners: {
  57. beforeload: function (store, op) {
  58. Ext.apply(store.proxy.extraParams, {
  59. number: 1,
  60. size: 1000
  61. });
  62. }
  63. }
  64. },
  65. productkind:{
  66. fields:[
  67. {name: 'id', type: 'int'},
  68. {name: 'pt_name', type: 'string'}
  69. ],
  70. proxy: {
  71. type: 'ajax',
  72. url: '/api/document/producttype/list',
  73. actionMethods: {
  74. read: 'GET'
  75. },
  76. reader: {
  77. type: 'json',
  78. rootProperty: 'data'
  79. }
  80. },
  81. pageSize: null,
  82. autoLoad: false,
  83. listeners: {
  84. beforeload: function (store, op) {
  85. Ext.apply(store.proxy.extraParams, {
  86. number: 1,
  87. size: 1000
  88. });
  89. }
  90. }
  91. },
  92. productbrand:{
  93. fields:[
  94. {name: 'id', type: 'int'},
  95. {name: 'pb_name', type: 'string'}
  96. ],
  97. proxy: {
  98. type: 'ajax',
  99. url: '/api/document/productbrand/list',
  100. actionMethods: {
  101. read: 'GET'
  102. },
  103. reader: {
  104. type: 'json',
  105. rootProperty: 'data'
  106. }
  107. },
  108. pageSize: null,
  109. autoLoad: false,
  110. listeners: {
  111. beforeload: function (store, op) {
  112. Ext.apply(store.proxy.extraParams, {
  113. number: 1,
  114. size: 1000
  115. });
  116. }
  117. }
  118. },
  119. bankinformation:{
  120. fields:[
  121. {name: 'id', type: 'int'},
  122. {name: 'bk_bankname', type: 'string'},
  123. {name: 'bk_bankcode', type: 'string'},
  124. {name: 'bk_type', type: 'string'},
  125. {name: 'bk_beginamount', type: 'float'},
  126. {name: 'bk_thisamount', type: 'float'},
  127. {name: 'bk_date', type: 'date'},
  128. {name: 'updateTime', type: 'date'}
  129. ],
  130. proxy: {
  131. type: 'ajax',
  132. url: '/api/document/bankinformation/list',
  133. actionMethods: {
  134. read: 'GET'
  135. },
  136. reader: {
  137. type: 'json',
  138. rootProperty: 'data.list'
  139. }
  140. },
  141. pageSize: null,
  142. autoLoad: false,
  143. listeners: {
  144. beforeload: function (store, op) {
  145. Ext.apply(store.proxy.extraParams, {
  146. number: 1,
  147. size: 1000
  148. });
  149. }
  150. }
  151. },
  152. inoutkind:{
  153. fields:[
  154. {name: 'id', type: 'int'},
  155. {name: 'ft_kind', type: 'string'},
  156. {name: 'ft_name', type: 'string'}
  157. ],
  158. proxy: {
  159. type: 'ajax',
  160. url: '/api/document/fundinouttype/list',
  161. actionMethods: {
  162. read: 'GET'
  163. },
  164. reader: {
  165. type: 'json',
  166. rootProperty: 'data'
  167. }
  168. },
  169. pageSize: null,
  170. autoLoad: false,
  171. listeners: {
  172. beforeload: function (store, op) {
  173. Ext.apply(store.proxy.extraParams, {
  174. number: 1,
  175. size: 1000
  176. });
  177. }
  178. }
  179. },
  180. warehouse: {
  181. fields:[
  182. {name: 'id', type: 'int'},
  183. {name: 'wh_code', type: 'string'},
  184. {name: 'wh_type', type: 'string'},
  185. {name: 'wh_description', type: 'string'},
  186. {name: 'wh_statuscode', type: 'string'},
  187. {name: 'wh_status', type: 'string'}
  188. ],
  189. proxy: {
  190. type: 'ajax',
  191. url: '/api/document/warehouse/list',
  192. actionMethods: {
  193. read: 'GET'
  194. },
  195. reader: {
  196. type: 'json',
  197. rootProperty: 'data.list'
  198. }
  199. },
  200. pageSize: null,
  201. autoLoad: false,
  202. listeners: {
  203. beforeload: function (store, op) {
  204. Ext.apply(store.proxy.extraParams, {
  205. number: 1,
  206. size: 1000
  207. });
  208. }
  209. }
  210. },
  211. address: {
  212. fields:[
  213. {name: 'id', type: 'int'},
  214. {name: 'ad_address', type: 'string'}
  215. ],
  216. proxy: {
  217. type: 'ajax',
  218. url: '/api/document/address/list',
  219. actionMethods: {
  220. read: 'GET'
  221. },
  222. reader: {
  223. type: 'json',
  224. rootProperty: 'data'
  225. }
  226. },
  227. pageSize: null,
  228. autoLoad: false,
  229. listeners: {
  230. beforeload: function (store, op) {
  231. Ext.apply(store.proxy.extraParams, {
  232. number: 1,
  233. size: 1000
  234. });
  235. }
  236. }
  237. },
  238. accountinformation: {
  239. fields:[
  240. {name: 'id', type: 'int'},
  241. {name: 'rl_name', type: 'string'}
  242. ],
  243. proxy: {
  244. type: 'ajax',
  245. url: '/api/account/account/accountRole/list',
  246. actionMethods: {
  247. read: 'GET'
  248. },
  249. reader: {
  250. type: 'json',
  251. rootProperty: 'data'
  252. }
  253. },
  254. pageSize: null,
  255. autoLoad: false,
  256. listeners: {
  257. beforeload: function (store, op) {
  258. Ext.apply(store.proxy.extraParams, {
  259. number: 1,
  260. size: 1000
  261. });
  262. }
  263. }
  264. },
  265. employee:{
  266. fields:[
  267. {name: 'id', type: 'int'},
  268. {name: 'em_code', type: 'string'},
  269. {name: 'em_mobile', type: 'string'},
  270. {name: 'em_email', type: 'string'},
  271. {name: 'em_clasee', type: 'string'}
  272. ],
  273. proxy: {
  274. type: 'ajax',
  275. url: '/api/document/employee/list',
  276. actionMethods: {
  277. read: 'GET'
  278. },
  279. reader: {
  280. type: 'json',
  281. rootProperty: 'data.list'
  282. }
  283. },
  284. pageSize: null,
  285. autoLoad: false,
  286. listeners: {
  287. beforeload: function (store, op) {
  288. Ext.apply(store.proxy.extraParams, {
  289. number: 1,
  290. size: 1000
  291. });
  292. }
  293. }
  294. },
  295. productunit: {
  296. fields:[
  297. {name: 'id', type: 'int'},
  298. {name: 'pu_name', type: 'string'}
  299. ],
  300. proxy: {
  301. type: 'ajax',
  302. url: '/api/document/productunit/list',
  303. actionMethods: {
  304. read: 'GET'
  305. },
  306. reader: {
  307. type: 'json',
  308. rootProperty: 'data'
  309. }
  310. },
  311. pageSize: null,
  312. autoLoad: false,
  313. listeners: {
  314. beforeload: function (store, op) {
  315. Ext.apply(store.proxy.extraParams, {
  316. number: 1,
  317. size: 1000
  318. });
  319. }
  320. }
  321. }
  322. }
  323. });