agree.js 534 B

12345678910111213141516171819202122
  1. var app = new Vue({
  2. el: '#app',
  3. data: {
  4. info: {},
  5. },
  6. created: function () {
  7. this.getInfo();
  8. },
  9. methods: {
  10. // 获取信息
  11. getInfo: function(){
  12. var _this = this;
  13. $.post('/weixin/news/getAgree', {}, function (res) {
  14. if (res.code == 'success') {
  15. _this.info = res.data
  16. } else if (res.code == 'login') {
  17. login(res.data.url);
  18. }
  19. }, "json");
  20. },
  21. }
  22. });