shop_store.php 3.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115
  1. <?php
  2. return array
  3. (
  4. # 表名
  5. 'name' => 'shop_store',
  6. # 显示给用户看的名称
  7. 'lang' => '门店仓库配送关系表',
  8. 'menu' => false,
  9. # 数据结构
  10. 'struct' => array
  11. (
  12. 'id' => array
  13. (
  14. 'type' => 'int-11',
  15. 'name' => 'ID',
  16. 'default' => '',
  17. 'desc' => '',
  18. 'match' => 'is_numeric',
  19. 'search' => 'order',
  20. 'update' => 'hidden',
  21. //'list' => true,
  22. ),
  23. 'shop_id' => array
  24. (
  25. 'type' => 'int-11',
  26. 'name' => '门店ID',
  27. 'default' => '-1',
  28. 'desc' => '门店ID',
  29. 'match' => 'is_numeric',
  30. 'update' => 'hidden',
  31. 'value' => Dever::input('search_option_shop_id'),
  32. ),
  33. 'servicer_store_id' => array
  34. (
  35. 'type' => 'int-11',
  36. 'name' => '仓库ID',
  37. 'default' => '',
  38. 'desc' => '仓库ID',
  39. 'match' => 'is_numeric',
  40. 'update' => 'hidden',
  41. 'search' => 'hidden',
  42. 'value' => Dever::input('search_option_servicer_store_id'),
  43. 'list' => 'Dever::load("scm_supplier/store-one#name", {servicer_store_id})',
  44. ),
  45. 'state' => array
  46. (
  47. 'type' => 'tinyint-1',
  48. 'name' => '状态',
  49. 'default' => '1',
  50. 'desc' => '请选择状态',
  51. 'match' => 'is_numeric',
  52. ),
  53. 'cdate' => array
  54. (
  55. 'type' => 'int-11',
  56. 'name' => '创建时间',
  57. 'match' => array('is_numeric', time()),
  58. 'desc' => '',
  59. # 只有insert时才生效
  60. //'insert' => true,
  61. 'search' => 'date',
  62. 'list' => 'date("Y-m-d H:i:s", {cdate})',
  63. ),
  64. ),
  65. 'manage' => array
  66. (
  67. ),
  68. 'request' => array
  69. (
  70. 'getAll' => array
  71. (
  72. 'option' => array
  73. (
  74. 'seller_id' => 'yes',
  75. 'state' => 1,
  76. ),
  77. 'type' => 'all',
  78. 'col' => '*|servicer_store_id',
  79. ),
  80. 'getData' => array
  81. (
  82. # 匹配的正则或函数 选填项
  83. 'option' => array
  84. (
  85. 'seller_id' => array('yes-t_1.seller_id'),
  86. 'state' => 'yes-t_2.state-1',
  87. 'state_1' => 'yes-t_1.state-1',
  88. ),
  89. # 联表
  90. 'join' => array
  91. (
  92. array
  93. (
  94. 'table' => 'scm_servicer/info',
  95. 'type' => 'left join',
  96. 'on' => array('servicer_store_id','id'),
  97. 'col' => 'servicer_store_id',
  98. ),
  99. ),
  100. 'type' => 'all',
  101. 'order' => array('t_2.reorder' => 'desc', 't_2.id' => 'desc'),
  102. 'col' => '*,t_2.name,t_2.id as id|id',
  103. ),
  104. ),
  105. );