1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253 |
- mainVM = new Vue({
- el: "html",
- data: {
- loading: true,
- dataList:"",
- userInfo:""
- },
- computed: {},
- ready: function () {
- this.getDataList();
- this.getUserInfo();
- },
- methods: {
- getDataList: function () {
- var _self = this;
- $.ajax({
- url: baseConfig.URL.menuList + "",
- type: "get",
- data:{},
- cache: false,
- success:function (res) {
- console.log(res);
- _self.dataList = res.list;
- },
- complete:function (XHR, TS) {
- // $('.ui-dialog-buttonpane').find('button:contains("保存添加信息")').removeAttr("disabled");
- },
- error:function (XMLHttpRequest, textStatus, errorThrown) {
- alert(textStatus);
- }
- });
- },
- getUserInfo: function () {
- var _self = this;
- $.ajax({
- url: baseConfig.URL.loginInfo + "",
- type: "get",
- data:{},
- cache: false,
- success:function (res) {
- console.log(res);
- _self.userInfo = res.loginInfo;
- },
- complete:function (XHR, TS) {
- // $('.ui-dialog-buttonpane').find('button:contains("保存添加信息")').removeAttr("disabled");
- },
- error:function (XMLHttpRequest, textStatus, errorThrown) {
- alert(textStatus);
- }
- });
- }
- }
- });
|