diff --git a/constant/UrlConstant.js b/constant/UrlConstant.js index e749a07..9db1044 100644 --- a/constant/UrlConstant.js +++ b/constant/UrlConstant.js @@ -4,8 +4,8 @@ * add by wuxw 2019-12-28 */ // 服务器域名 -//const baseUrl = 'https://app.demo.winqi.cn/'; -const baseUrl = '/'; +const baseUrl = 'https://app.demo.winqi.cn/'; +//const baseUrl = '/'; const hcBaseUrl = 'https://hc.demo.winqi.cn'; // 登录接口 const loginUrl = baseUrl + 'app/loginProperty'; diff --git a/main.js b/main.js index 5bbd5c7..6c83c8f 100644 --- a/main.js +++ b/main.js @@ -1,6 +1,8 @@ import Vue from 'vue' import App from './App' import Java110Context from './context/Java110Context.js' +//引入vuex +import store from './store' import cuCustom from './colorui/components/cu-custom.vue' Vue.component('cu-custom',cuCustom) @@ -10,10 +12,12 @@ Vue.prototype.java110Context = Java110Context; Vue.prototype.java110Constant = Java110Context.constant; Vue.prototype.java110Factory = Java110Context.factory; Vue.prototype.java110Util = Java110Context.util; +Vue.prototype.$store = store App.mpType = 'app' const app = new Vue({ - ...App + ...App, + store }) app.$mount() diff --git a/manifest.json b/manifest.json index 8d1f4e7..b493fec 100644 --- a/manifest.json +++ b/manifest.json @@ -1,89 +1,110 @@ { - "name" : "HC掌上物业", - "appid" : "__UNI__29E0560", - "description" : "", - "versionName" : "1.0.0", - "versionCode" : "100", - "transformPx" : false, - /* 5+App特有相关 */ - "app-plus" : { - "usingComponents" : true, - "nvueCompiler" : "uni-app", - "compilerVersion" : 3, - "splashscreen" : { - "alwaysShowBeforeRender" : true, - "waiting" : true, - "autoclose" : true, - "delay" : 0 - }, - /* 模块配置 */ - "modules" : {}, - /* 应用发布信息 */ - "distribute" : { - /* android打包配置 */ - "android" : { - "permissions" : [ - "", - "", - "", - "", - "", - "", - "", - "", - "", - "", - "", - "", - "", - "", - "", - "", - "", - "", - "", - "", - "", - "" - ] - }, - /* ios打包配置 */ - "ios" : {}, - /* SDK配置 */ - "sdkConfigs" : {} - } - }, - /* 快应用特有相关 */ - "quickapp" : {}, - /* 小程序特有相关 */ - "mp-weixin" : { - "appid" : "", - "setting" : { - "urlCheck" : false - }, - "usingComponents" : true - }, - "mp-alipay" : { - "usingComponents" : true - }, - "mp-baidu" : { - "usingComponents" : true - }, - "mp-toutiao" : { - "usingComponents" : true - }, - /* h5特有相关 */ - "h5" : { - "devServer" : { - "port" : 8000, //端口号 - "disableHostCheck" : true, - "proxy" : { - "/app" : { - "target" : "https://app.demo.winqi.cn", //目标接口域名 - "changeOrigin" : true, //是否跨域 - "secure" : true // 设置支持https协议的代理 - } - } - } - } + "name" : "HC掌上物业", + "appid" : "__UNI__29E0560", + "description" : "", + "versionName" : "1.0.0", + "versionCode" : "100", + "transformPx" : false, + /* 5+App特有相关 */ + "app-plus" : + { + "usingComponents" : true, + "nvueCompiler" : "uni-app", + "compilerVersion" : 3, + "splashscreen" : + { + "alwaysShowBeforeRender" : true, + "waiting" : true, + "autoclose" : true, + "delay" : 0 + }, + /* 模块配置 */ + "modules" : {}, + /* 应用发布信息 */ + "distribute" : + { + /* android打包配置 */ + "android" : + { + "permissions" : + [ + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "" + ] + }, + /* ios打包配置 */ + "ios" : {}, + /* SDK配置 */ + "sdkConfigs" : + { + "ad" : null + } + } + }, + /* 快应用特有相关 */ + "quickapp" : {}, + /* 小程序特有相关 */ + "mp-weixin" : + { + "appid" : "", + "setting" : + { + "urlCheck" : false + }, + "usingComponents" : true + }, + "mp-alipay" : + { + "usingComponents" : true + }, + "mp-baidu" : + { + "usingComponents" : true + }, + "mp-toutiao" : + { + "usingComponents" : true + }, + /* h5特有相关 */ + "h5" : + { + "devServer" : + { + "port" : 8000, //端口号 + + "disableHostCheck" : true, + "proxy" : + { + "/app" : + { + "target" : "https://app.demo.winqi.cn", //目标接口域名 + + "changeOrigin" : true, //是否跨域 + + "secure" : true // 设置支持https协议的代理 + + } + } + } + } } diff --git a/pages/login/login.vue b/pages/login/login.vue index 875a3a0..a670b25 100644 --- a/pages/login/login.vue +++ b/pages/login/login.vue @@ -46,9 +46,14 @@ }); this.logoUrl = this.java110Constant.url.baseUrl + 'logo.png'; - - - + + }, + onBackPress(options) { + if (options.from === 'navigateBack') { + return false; + } + plus.runtime.quit(); + return true; }, methods: { diff --git a/store/index.js b/store/index.js new file mode 100644 index 0000000..837fe2b --- /dev/null +++ b/store/index.js @@ -0,0 +1,9 @@ +import Vue from 'vue' +import Vuex from 'vuex' +Vue.use(Vuex) +const store = new Vuex.Store({ + state: {}, + mutations: {}, + actions: {} +}) +export default store \ No newline at end of file