columns.js 7.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436
  1. //是否定制
  2. const options1 = [
  3. { id: "0", name: "否" },
  4. { id: "1", name: "是" },
  5. ]
  6. //专属类型
  7. const options2 = [
  8. { id: "0", name: "非泰康" },
  9. { id: "1", name: "泰康" },
  10. ]
  11. //销售权限
  12. const options3 = [
  13. { id: "0", name: "无销售权限" },
  14. { id: "1", name: "有销售权限" },
  15. ]
  16. //是否库存品
  17. const options4 = [
  18. { id: "0", name: "非库存品" },
  19. { id: "1", name: "库存品" },
  20. ]
  21. //是否启用实时金价
  22. const options5 = [
  23. { id: "0", name: "否" },
  24. { id: "1", name: "是" },
  25. ]
  26. //供货区域
  27. const options6 = [
  28. { id: "1", name: "全国" },
  29. { id: "2", name: "全国除偏远" },
  30. ]
  31. //是否启用阶梯
  32. const options7 = [
  33. { id: "0", name: "否" },
  34. { id: "1", name: "是" },
  35. ]
  36. const listCol = [
  37. {
  38. type: "selection",
  39. fixed: "left",
  40. _noset_: true
  41. },
  42. {
  43. prop: "spuCode",
  44. label: "编号",
  45. width: "160px",
  46. },
  47. // {
  48. // prop: "good_img",
  49. // label: "图片",
  50. // _slot_: "good_img",
  51. // width: "45px",
  52. // },
  53. {
  54. prop: "good_name",
  55. label: "名称",
  56. "min-width": "160px",
  57. },
  58. {
  59. prop: "cat_name",
  60. label: "分类",
  61. },
  62. {
  63. prop: "brand_name",
  64. label: "品牌",
  65. },
  66. {
  67. prop: "good_type",
  68. label: "是否定制",
  69. _slot_: "good_type",
  70. width: "70px",
  71. },
  72. // {
  73. // prop: "status",
  74. // label: "状态",
  75. // _slot_: "status",
  76. // width: "118px",
  77. // },
  78. // {
  79. // prop: "supplierNo",
  80. // label: "供应商编号",
  81. // width: "110px",
  82. // },
  83. // {
  84. // prop: "supplier_name",
  85. // label: "供应商名称",
  86. // width: "110px",
  87. // },
  88. {
  89. prop: "companyNo",
  90. label: "业务公司编号",
  91. width: "110px",
  92. },
  93. {
  94. prop: "companyName",
  95. label: "业务公司名称",
  96. width: "110px",
  97. },
  98. {
  99. prop: "addtime",
  100. label: "创建时间",
  101. width: "140px",
  102. },
  103. {
  104. prop: "",
  105. label: "操作",
  106. fixed: "right",
  107. _noset_: true,
  108. width: "50px",
  109. _slot_: "operation",
  110. },
  111. ]
  112. const rules = {
  113. cat_id: [
  114. {
  115. type: "array",
  116. required: true,
  117. message: "商品分类",
  118. trigger: "change",
  119. },
  120. ],
  121. brandid: [
  122. {
  123. type: "array",
  124. required: false,
  125. message: "商品品牌",
  126. trigger: "change",
  127. },
  128. ],
  129. noble_weight: [
  130. {
  131. required: true,
  132. message: "贵金属重量为合法数字",
  133. trigger: "blur",
  134. },
  135. ],
  136. weight: [
  137. {
  138. required: true,
  139. message: "商品总重量为合法数字",
  140. trigger: "blur",
  141. },
  142. ],
  143. good_type: [
  144. {
  145. required: true,
  146. message: "请选择是否定制",
  147. trigger: "change",
  148. },
  149. ],
  150. is_stock: [
  151. {
  152. required: true,
  153. message: "请选择是否库存品",
  154. trigger: "change",
  155. },
  156. ],
  157. company_id: [
  158. {
  159. required: true,
  160. message: "请选择业务公司",
  161. trigger: "change",
  162. },
  163. ],
  164. supplierNo: [
  165. {
  166. type: "array",
  167. required: true,
  168. message: "请选择供应商",
  169. trigger: "change",
  170. },
  171. ],
  172. is_auth: [
  173. {
  174. required: true,
  175. message: "商品主图",
  176. trigger: "change",
  177. },
  178. ],
  179. tax: [
  180. {
  181. required: true,
  182. message: "请选择税率",
  183. trigger: "change",
  184. },
  185. ],
  186. good_name: [
  187. {
  188. required: true,
  189. message: "请输入商品名称",
  190. trigger: "blur",
  191. },
  192. ],
  193. unit: [
  194. {
  195. type: "array",
  196. required: true,
  197. message: "请输入商品单位",
  198. trigger: "blur",
  199. },
  200. ],
  201. is_exclusive: [
  202. {
  203. required: true,
  204. message: "请选择专属类型",
  205. trigger: "change",
  206. },
  207. ],
  208. noble_metal: [
  209. {
  210. required: true,
  211. message: "请选择贵金属种类",
  212. trigger: "change",
  213. },
  214. ],
  215. is_gold_price: [
  216. {
  217. required: true,
  218. message: "请选择是否启用实时金价",
  219. trigger: "change",
  220. },
  221. ],
  222. moq: [
  223. {
  224. required: true,
  225. message: "定制起订量应为合法数字",
  226. trigger: "blur",
  227. },
  228. ],
  229. customized: [
  230. {
  231. required: true,
  232. message: "定制工期为合法数字",
  233. trigger: "blur",
  234. },
  235. ],
  236. after_sales: [
  237. {
  238. required: true,
  239. message: "售后说明不能为空",
  240. trigger: "blur",
  241. },
  242. ],
  243. good_remark: [
  244. {
  245. required: true,
  246. message: "商品备注不能为空",
  247. trigger: "blur",
  248. },
  249. ],
  250. //包装/发货/图片
  251. packing_list: [
  252. {
  253. required: true,
  254. message: "请输入包装清单",
  255. trigger: "blur",
  256. },
  257. ],
  258. packing_way: [
  259. {
  260. required: true,
  261. message: "请输入包装方式",
  262. trigger: "blur",
  263. },
  264. ],
  265. packing_spec: [
  266. {
  267. required: true,
  268. message: "请输入装箱规格",
  269. trigger: "blur",
  270. },
  271. ],
  272. packing_weight: [
  273. {
  274. required: true,
  275. message: "请输入装箱重量",
  276. trigger: "blur",
  277. },
  278. ],
  279. packing_szie: [
  280. {
  281. required: true,
  282. message: "请输入装箱尺寸",
  283. trigger: "blur",
  284. },
  285. ],
  286. supply_area: [
  287. {
  288. required: true,
  289. message: "请选择供货区域",
  290. trigger: "change",
  291. },
  292. ],
  293. delivery_place: [
  294. {
  295. type: "array",
  296. required: true,
  297. message: "请选择发货地",
  298. trigger: "change",
  299. },
  300. ],
  301. origin_place: [
  302. {
  303. type: "array",
  304. required: true,
  305. message: "请选择产地",
  306. trigger: "change",
  307. },
  308. ],
  309. delivery_day: [
  310. {
  311. required: true,
  312. message: "请输入物流时间",
  313. trigger: "blur",
  314. },
  315. ],
  316. lead_time: [
  317. {
  318. required: true,
  319. message: "请输入供货周期",
  320. trigger: "blur",
  321. },
  322. ],
  323. sample_day: [
  324. {
  325. required: true,
  326. message: "请输入调样周期",
  327. trigger: "blur",
  328. },
  329. ],
  330. packing_size: [
  331. {
  332. required: true,
  333. message: "请输入装箱尺寸",
  334. trigger: "blur",
  335. },
  336. ],
  337. good_thumb_img: [
  338. {
  339. required: true,
  340. message: "商品主图",
  341. trigger: "change",
  342. },
  343. ],
  344. // good_img: [
  345. // {
  346. // required: true,
  347. // message: "商品详情主图",
  348. // trigger: "change",
  349. // },
  350. // ],
  351. good_info_img: [
  352. {
  353. type: "array",
  354. required: true,
  355. message: "商品详情介绍图",
  356. trigger: "change",
  357. },
  358. ],
  359. //固定成本
  360. cert_fee: [
  361. {
  362. required: true,
  363. message: "证书费应为合法数字",
  364. trigger: "blur",
  365. },
  366. ],
  367. packing_fee: [
  368. {
  369. required: true,
  370. message: "包装费应为合法数字",
  371. trigger: "blur",
  372. },
  373. ],
  374. cost_fee: [
  375. {
  376. required: true,
  377. message: "成本工艺费应为合法数字",
  378. trigger: "blur",
  379. },
  380. ],
  381. mark_fee: [
  382. {
  383. required: true,
  384. message: "加标费应为合法数字",
  385. trigger: "blur",
  386. },
  387. ],
  388. demo_fee: [
  389. {
  390. required: true,
  391. message: "打样应为合法数字",
  392. trigger: "blur",
  393. },
  394. ],
  395. open_fee: [
  396. {
  397. required: true,
  398. message: "开模费应为合法数字",
  399. trigger: "blur",
  400. },
  401. ],
  402. sample_fee: [
  403. {
  404. required: true,
  405. message: "调样费应为合法数字",
  406. trigger: "blur",
  407. },
  408. ],
  409. market_price: [
  410. {
  411. required: true,
  412. message: "市场价应为合法数字",
  413. trigger: "blur",
  414. },
  415. ],
  416. nake_price: [
  417. {
  418. required: true,
  419. message: "含税成本合计应为合法数字",
  420. trigger: "blur",
  421. },
  422. ],
  423. is_step: {
  424. required: true,
  425. message: "请选择是否启用阶梯",
  426. trigger: "change",
  427. },
  428. }
  429. export { options1, options2, options3, options4, options5, options6, options7, listCol, rules }