express_delivery.js 1.7 KB

12345678910111213141516171819202122232425262728293031323334
  1. define(["jquery", "easy-admin"], function ($, ea) {
  2. var init = {
  3. table_elem: '#currentTable',
  4. table_render_id: 'currentTableRenderId',
  5. index_url: 'mall.express_delivery/index',
  6. add_url: 'mall.express_delivery/add',
  7. edit_url: 'mall.express_delivery/edit',
  8. delete_url: 'mall.express_delivery/delete',
  9. export_url: 'mall.express_delivery/export',
  10. modify_url: 'mall.express_delivery/modify',
  11. };
  12. var Controller = {
  13. index: function () {
  14. ea.table.render({
  15. init: init,
  16. cols: [[
  17. {type: 'checkbox'}, {field: 'id', title: 'ID'}, {field: 'name', title: '模版名称'}, {field: 'is_free', title: '是否包邮 0=不包邮,1=包邮'}, {field: 'price_method', title: '计价方式'}, {field: 'specify_conditions', title: '是否指定条件包邮'}, {field: 'default_pieces', title: '默认件数'}, {field: 'default_price', title: '默认价格'}, {field: 'add_pieces', title: '续件'}, {field: 'add_price', title: '续费'}, {field: 'created_time', title: '添加时间'}, {field: 'updated_time', title: '更新时间'}, {width: 250, title: '操作', templet: ea.table.tool},
  18. ]],
  19. });
  20. ea.listen();
  21. },
  22. add: function () {
  23. ea.listen();
  24. },
  25. edit: function () {
  26. ea.listen();
  27. },
  28. };
  29. return Controller;
  30. });