index.html 1.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  1. {% extends "../theme.html" %}
  2. {% block content %}
  3. {%include 'inc/menu.html'%}
  4. <div class="pannel">
  5. <div class="ul7">
  6. <dl>
  7. <dt>劳作图像</dt>
  8. <dt>农事日期</dt>
  9. <dt>劳作种类</dt>
  10. <dt>劳作内容</dt>
  11. <dt>劳作数据</dt>
  12. <dt>操作地块</dt>
  13. <dt>管理</dt>
  14. </dl>
  15. {% for v in data['list'] %}
  16. <dl>
  17. <dd>
  18. <img src="{{v['pic']}}" width="100%">
  19. </dd>
  20. <dd><p>{{v['workdates']}}</p></dd>
  21. <dd><p>{{v['category']}}</p></dd>
  22. <dd><p>{{v['method']}}</p></dd>
  23. <dd><p>{{v['amount']}}</p></dd>
  24. <dd><p>{{v['land']}}</p></dd>
  25. <dd><p><a href="javascript:;" onclick="Farm.Page('修改农事', '/work/update?id={{v['id']}}')">修改</a><a href="javascript:;" onclick="Farm.Delete(this, '{{v['id']}}', '/work/update?id={{v['id']}}')">删除</a></p></dd>
  26. </dl>
  27. {% end %}
  28. </div>
  29. </div>
  30. {%set url = data['url']['index'] %}
  31. {%include '../inc/page.html'%}
  32. {% end %}
  33. {% block script %}
  34. <script type="text/javascript" src="{{static_url('pc/lib/laydate/laydate.js')}}"></script>
  35. <script type="text/javascript" src="{{static_url('pc/lib/layui/layui.js')}}"></script>
  36. <script>
  37. function selectShow(e, id) {
  38. id = '#update_' + id
  39. if ($(id).length) {
  40. $(id).find('option').each(function()
  41. {
  42. var parent = $(this).attr('parent');
  43. if (parent) {
  44. if (parent != e.val()) {
  45. $(this).html('');
  46. $(this).attr('selected', false)
  47. $(this).hide();
  48. } else {
  49. $(this).html($(this).attr('name'));
  50. $(this).show();
  51. }
  52. }
  53. //$(this).val(0);
  54. })
  55. }
  56. }
  57. </script>
  58. {% end %}