order_process.php 8.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275
  1. <?php
  2. $audit = array
  3. (
  4. 1 => '审核通过',
  5. 2 => '拒绝',
  6. );
  7. $status = array
  8. (
  9. 1 => '初审',
  10. 2 => '终审',
  11. 3 => '权益发放',
  12. 4 => '已完成',
  13. );
  14. $type = array
  15. (
  16. 1 => '支付已确认',
  17. 2 => '权益已确认发放',
  18. 3 => '分润已确认发放',
  19. //4 => '期权已确认发放',
  20. 5 => '代理合同已生成',
  21. );
  22. $cstatus = array
  23. (
  24. 1 => '不拆分',
  25. 2 => '拆分',
  26. );
  27. $status_value = Dever::input('status', 1);
  28. $audit_desc = '';
  29. if ($status_value == 1) {
  30. $audit_desc = '需确认代理商信息无误则通过审核。审核通过后,需确认支付金额是否拆分。';
  31. } elseif ($status_value == 2) {
  32. $audit_desc = '现行确认是否已到账,未确认到账时,无法发放权益等操作。';
  33. }
  34. $prize_type = array
  35. (
  36. 1 => '非赠送区域',
  37. 2 => '赠送区域,会自动扣减已有名额',
  38. );
  39. return array
  40. (
  41. # 表名
  42. 'name' => 'order_process',
  43. # 显示给用户看的名称
  44. 'lang' => '订单审核进度表',
  45. 'menu' => false,
  46. 'status' => $status,
  47. 'start' => array
  48. (
  49. 'insert' => 'agent/lib/manage.orderStartUpdate',
  50. 'update' => 'agent/lib/manage.orderStartUpdate',
  51. ),
  52. 'end' => array
  53. (
  54. 'insert' => 'agent/lib/manage.orderUpdate',
  55. 'update' => 'agent/lib/manage.orderUpdate',
  56. ),
  57. # 数据结构
  58. 'struct' => array
  59. (
  60. 'id' => array
  61. (
  62. 'type' => 'int-11',
  63. 'name' => 'ID',
  64. 'default' => '',
  65. 'desc' => '',
  66. 'match' => 'is_numeric',
  67. 'search' => 'order',
  68. 'update' => 'hidden',
  69. //'list' => true,
  70. ),
  71. 'order_id' => array
  72. (
  73. 'type' => 'int-11',
  74. 'name' => '订单表id',
  75. 'default' => '',
  76. 'desc' => '订单表id',
  77. 'match' => 'is_numeric',
  78. 'update' => 'hidden',
  79. 'value' => Dever::input('order_id', 1),
  80. ),
  81. 'status' => array
  82. (
  83. 'type' => 'int-11',
  84. 'name' => '状态',
  85. 'default' => '1',
  86. 'desc' => '状态',
  87. 'match' => 'is_numeric',
  88. 'update' => 'hidden',
  89. 'option' => $status,
  90. 'search' => 'select',
  91. 'value' => $status_value,
  92. 'control' => 'status',
  93. ),
  94. 'audit' => array
  95. (
  96. 'type' => 'int-11',
  97. 'name' => '审核状态-' . $audit_desc,
  98. 'default' => '1',
  99. 'desc' => '审核状态',
  100. 'match' => 'is_numeric',
  101. 'update' => 'radio',
  102. 'option' => $audit,
  103. 'search' => 'select',
  104. 'control' => 'audit',
  105. ),
  106. 'prize_type' => array
  107. (
  108. 'type' => 'tinyint-1',
  109. 'name' => '是否赠送区域-当出现此选项时,代表代理商有免费赠送的区域名额,当选择赠送区域时,会自动扣减当前代理商已有的名额,并且会将实付金额强制改为0元',
  110. 'default' => '1',
  111. 'desc' => '是否赠送区域',
  112. 'match' => 'is_numeric',
  113. 'update' => 'radio',
  114. 'option' => $prize_type,
  115. 'control' => 'prize_type',
  116. 'show' => 'audit=1',
  117. ),
  118. 'price' => array
  119. (
  120. 'type' => 'decimal-11,2',
  121. 'name' => '实付金额',
  122. 'default' => '0',
  123. 'desc' => '金额',
  124. 'match' => 'option',
  125. 'update' => 'text',
  126. 'const' => Dever::input('price'),
  127. 'list' => true,
  128. 'show' => 'prize_type=1&audit=1',
  129. ),
  130. 'cstatus' => array
  131. (
  132. 'type' => 'tinyint-1',
  133. 'name' => '是否拆分代理费-选择拆分后,将代理费拆为代理费和软件服务费',
  134. 'default' => '1',
  135. 'desc' => '是否拆分代理费',
  136. 'match' => 'is_numeric',
  137. 'update' => 'radio',
  138. 'option' => $cstatus,
  139. 'show' => 'audit=1',
  140. 'control' => 'cstatus',
  141. ),
  142. 'soft_price' => array
  143. (
  144. 'type' => 'decimal-11,2',
  145. 'name' => '软件服务费',
  146. 'default' => '0',
  147. 'desc' => '金额',
  148. 'match' => 'option',
  149. 'update' => 'text',
  150. 'const' => Dever::input('soft_price', '0'),
  151. 'show' => 'cstatus=2',
  152. ),
  153. 'option_price' => array
  154. (
  155. 'type' => 'decimal-11,2',
  156. 'name' => '赠送期权价值',
  157. 'default' => '0',
  158. 'desc' => '金额',
  159. 'match' => 'option',
  160. 'update' => 'text',
  161. 'const' => Dever::input('option_price', '0'),
  162. 'show' => 'audit=1',
  163. 'list' => true,
  164. ),
  165. 'desc' => array
  166. (
  167. 'type' => 'varchar-400',
  168. 'name' => '备注',
  169. 'default' => '',
  170. 'desc' => '备注',
  171. 'match' => 'is_string',
  172. 'update' => 'textarea',
  173. 'search' => 'fulltext',
  174. 'list' => true,
  175. 'show' => 'type=1,2&audit=2',
  176. ),
  177. 'type' => array
  178. (
  179. 'type' => 'varchar-400',
  180. 'name' => '权益发放情况',
  181. 'default' => '1',
  182. 'desc' => '权益发放情况',
  183. 'match' => 'option',
  184. 'update' => 'checkbox',
  185. 'checkall' => 1,
  186. 'disabled' => 1,
  187. 'option' => $type,
  188. 'search' => 'select',
  189. 'show' => 'type=3',
  190. ),
  191. 'admin' => array
  192. (
  193. 'type' => 'int-11',
  194. 'name' => '操作人',
  195. 'default' => '',
  196. 'match' => 'is_numeric',
  197. 'desc' => '操作人',
  198. //'list' => '"{admin}" > 0 ? Dever::load("manage/admin-find#username", {admin}) : "-"',
  199. 'list_order' => 8,
  200. ),
  201. 'state' => array
  202. (
  203. 'type' => 'tinyint-1',
  204. 'name' => '状态',
  205. 'default' => '1',
  206. 'desc' => '请选择状态',
  207. 'match' => 'is_numeric',
  208. ),
  209. 'cdate' => array
  210. (
  211. 'type' => 'int-11',
  212. 'name' => '创建时间',
  213. 'match' => array('is_numeric', time()),
  214. 'desc' => '',
  215. # 只有insert时才生效
  216. //'insert' => true,
  217. 'search' => 'date',
  218. 'list' => 'date("Y-m-d H:i:s", {cdate})',
  219. ),
  220. ),
  221. 'alter' => array
  222. (
  223. 10 => array
  224. (
  225. array('update', 'price', 'price', 'decimal-11,2 0 实付金额'),
  226. array('update', 'soft_cash', 'soft_cash', 'decimal-11,2 0 软件服务费'),
  227. array('update', 'option_price', 'option_price', 'decimal-11,2 0 赠送期权价值'),
  228. ),
  229. 'version' => 10,
  230. ),
  231. 'manage' => array
  232. (
  233. 'insert' => false,
  234. 'delete' => false,
  235. 'page_list' => 'order_process',
  236. ),
  237. 'request' => array
  238. (
  239. 'getData' => array
  240. (
  241. # 匹配的正则或函数 选填项
  242. 'option' => array
  243. (
  244. 'order_id' => 'yes',
  245. 'state' => 1,
  246. ),
  247. 'type' => 'all',
  248. 'order' => array('status' => 'asc', 'cdate' => 'asc'),
  249. 'col' => '*|status',
  250. ),
  251. ),
  252. );