Commit fea04e0b authored by 郭志伟's avatar 郭志伟

Merge branch 'feat/1.2.2-pre' into 'master'

Feat/1.2.2 pre

See merge request !21
parents 2e329cda c4ffdc39
...@@ -18,6 +18,7 @@ config/plugin.local.js ...@@ -18,6 +18,7 @@ config/plugin.local.js
config/plugin.js config/plugin.js
config/config.*.js config/config.*.js
config/apollo.json config/apollo.json
config/apollo.ssr.json
index.js index.js
config/manifest.json config/manifest.json
app/view/* app/view/*
......
module.exports = { module.exports = {
// Sentry options are required // Sentry options are required
organization: 'sentry', organization: 'sentry',
project: 'quantum-blocks-h5', project: 'quantum-block-h5',
apiKey: '2e7e0678d81d4542b09cdbc35812f1cbb07a4993cd13435ba49d9511be11ec95', apiKey: '2e7e0678d81d4542b09cdbc35812f1cbb07a4993cd13435ba49d9511be11ec95',
// Release version name/hash is required // Release version name/hash is required
release: 'quantum-blocks-h5@0.0.1', release: 'quantum-block-h5@0.0.1',
baseSentryURL: 'https://sentry.quantgroups.com/api/0', baseSentryURL: 'https://sentry.quantgroups.com/api/0',
deleteAfterCompile: true, deleteAfterCompile: true,
include: /js\//, // 只上传js和map文件 include: /js\//, // 只上传js和map文件
......
const protocol = EASY_ENV_IS_BROWSER ? window.location.protocol : 'https'; const protocol = EASY_ENV_IS_BROWSER ? window.location.protocol : 'https';
const hostMap = { export default {
apiHost: `${protocol}//quantum-blocks.q-gp.com`, apiHost: `https://quantum-blocks.q-gp.com`,
shenceUrl: `${protocol}//bn.xyqb.com/sa?project=production`, shenceUrl: `${protocol}//bn.xyqb.com/sa?project=production`,
// opapiHost: `${protocol}//opapi.q-gp.com`,
test: false test: false
}; };
export default hostMap;
...@@ -75,7 +75,7 @@ export default class App { ...@@ -75,7 +75,7 @@ export default class App {
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
router.onReady(() => { router.onReady(() => {
this.fetch(vm).then(() => { this.fetch(vm).then(() => {
context.state = {...store.state, apollo: context.state.apollo}; context.state = {...store.state, apollo: context.state.apollo || {}};
return resolve(new Vue(vm)); return resolve(new Vue(vm));
}); });
}); });
......
...@@ -100,9 +100,6 @@ export default class Activity extends Mixins(TransformStyleMixin, SaMixin) { ...@@ -100,9 +100,6 @@ export default class Activity extends Mixins(TransformStyleMixin, SaMixin) {
gridItemEle.classList.remove('del_transform'); gridItemEle.classList.remove('del_transform');
} }
const transform = getStyle(gridItemEle, 'transform'); const transform = getStyle(gridItemEle, 'transform');
const transformY = transform.split('(')[1].split(')')[0].split(',')[5];
gridItemEle.style.top = `${transformY}px`;
gridItemEle.className += ' del_transform';
if (transform && transform.length) { if (transform && transform.length) {
const transformY = transform.split('(')[1].split(')')[0].split(',')[5]; const transformY = transform.split('(')[1].split(')')[0].split(',')[5];
gridItemEle.style.top = `${transformY}px`; gridItemEle.style.top = `${transformY}px`;
......
...@@ -32,11 +32,11 @@ ...@@ -32,11 +32,11 @@
</template> </template>
<script lang="ts" src="./index.ts"></script> <script lang="ts" src="./index.ts"></script>
<style lang="less" scoped> <style lang="less" scoped>
.activity { .activity {
width: 100%; width: 100%;
min-height: 100%; min-height: 100%;
background-color: rgb(244, 244, 244); background-color: rgb(244, 244, 244);
box-shadow: 2px 0px 10px rgba(0, 0, 0, 0.2); box-shadow: 2px 0 10px rgba(0, 0, 0, 0.2);
// overflow-x: hidden; // overflow-x: hidden;
// overflow-y: scroll; // overflow-y: scroll;
/deep/ .vue-grid-layout { /deep/ .vue-grid-layout {
...@@ -44,19 +44,22 @@ ...@@ -44,19 +44,22 @@
box-sizing: content-box; box-sizing: content-box;
// transform: translateY(-10px); // transform: translateY(-10px);
transition-property: none; transition-property: none;
.vue-grid-item { .vue-grid-item {
transition-property: none; transition-property: none;
display: flex; display: flex;
justify-content: center; justify-content: center;
align-items: center; align-items: center;
/* 不可设置溢出隐藏,tabs导航会出问题 */ /* 不可设置溢出隐藏,tabs导航会出问题 */
overflow: hidden; overflow: hidden;
&>*:first-child {
& > *:first-child {
height: 100%; height: 100%;
} }
} }
} }
} }
.del_transform { .del_transform {
overflow: visible !important; overflow: visible !important;
......
...@@ -37,7 +37,7 @@ export default class TransformStyleMixin extends Vue { ...@@ -37,7 +37,7 @@ export default class TransformStyleMixin extends Vue {
const eleId = element.getAttribute('id'); const eleId = element.getAttribute('id');
const component = this.pageData.elements.find(v => v.id === eleId); const component = this.pageData.elements.find(v => v.id === eleId);
if (!component) { return; } if (!component) { return; }
const point = { ...component.point, h: +height }; const point = { ...component.point, h: Math.ceil(+height) };
this.setElementPoint({ id: eleId, data: point }); this.setElementPoint({ id: eleId, data: point });
console.log('adjustHeight', height, component, element.getAttribute('id'), point); console.log('adjustHeight', height, component, element.getAttribute('id'), point);
......
...@@ -21,10 +21,7 @@ export default class EditorModule implements Module<EditorState, RootState> { ...@@ -21,10 +21,7 @@ export default class EditorModule implements Module<EditorState, RootState> {
actions: ActionTree<EditorState, RootState> = { actions: ActionTree<EditorState, RootState> = {
async getPageDate({ commit }, condition) { async getPageDate({ commit }, condition) {
const [res] = await api.getPageById(condition); const [res] = await api.getPageById(condition);
let { page, ...rest } = res as PageInfo; const { page, ...rest } = res as PageInfo;
if (!page) {
page = '[]';
}
commit(SET_PAGE_INFO, { ...rest, page: JSON.parse(page as string) }); commit(SET_PAGE_INFO, { ...rest, page: JSON.parse(page as string) });
} }
}; };
...@@ -34,8 +31,8 @@ export default class EditorModule implements Module<EditorState, RootState> { ...@@ -34,8 +31,8 @@ export default class EditorModule implements Module<EditorState, RootState> {
state.pageInfo = data; state.pageInfo = data;
}, },
[UPDATE_PAGE_INFO](state, { containerIndex, childIndex, data }) { [UPDATE_PAGE_INFO](state, { containerIndex, childIndex, data }) {
const page = (state.pageInfo.page as Page).elements || []; const page = (state.pageInfo.page as Page).elements;
if ((childIndex || childIndex === 0) && page[containerIndex].child) { if (childIndex || childIndex === 0) {
page[containerIndex].child.splice(childIndex, 1, data); page[containerIndex].child.splice(childIndex, 1, data);
} else { } else {
page.splice(containerIndex, 1, data); page.splice(containerIndex, 1, data);
......
...@@ -4,20 +4,22 @@ ...@@ -4,20 +4,22 @@
"h5Host": "https://quantum-h5-test1.liangkebang.net", "h5Host": "https://quantum-h5-test1.liangkebang.net",
"opapiHost": "https://opapi-test1.liangkebang.net", "opapiHost": "https://opapi-test1.liangkebang.net",
"passportHost": "https://passportapi-test1.liangkebang.net", "passportHost": "https://passportapi-test1.liangkebang.net",
"kdspHost": "https://talos-test1.liangkebang.net" "kdspHost": "https://talos-test1.liangkebang.net",
"loginUrl": "",
"h5ShopHost": "https://tenet-test1.liangkebang.net/#"
}, },
"mysql": { "mysql": {
"low_code": { "low_code": {
"host": "172.17.5.9", "host": "undefined",
"port": 31024, "port": "undefined",
"username": "qa", "username": "qa",
"password": "qatest", "password": "qatest",
"database": "low_code" "database": "low_code"
} }
}, },
"redis": { "redis": {
"port": 31400, "port": "undefined",
"host": "172.17.5.17", "host": "undefined",
"password": "", "password": "",
"db": 0 "db": 0
}, },
......
...@@ -29,8 +29,8 @@ export default (appInfo: EggAppConfig) => { ...@@ -29,8 +29,8 @@ export default (appInfo: EggAppConfig) => {
exports.redis = { exports.redis = {
client: { client: {
port: 31565, // Redis port port: 31400, // Redis port
host: '172.17.5.13', // Redis host host: '172.17.5.17', // Redis host
password: '', password: '',
db: 0 db: 0
} }
......
...@@ -20,7 +20,7 @@ export default (appInfo: EggAppConfig) => { ...@@ -20,7 +20,7 @@ export default (appInfo: EggAppConfig) => {
password: 'ln4^ESq80j4nrTMZ', password: 'ln4^ESq80j4nrTMZ',
db: 0 db: 0
} }
};; };
return exports; return {...exports, apollo: {}};
}; };
...@@ -1658,9 +1658,9 @@ ...@@ -1658,9 +1658,9 @@
} }
}, },
"@qg/citrus-ui": { "@qg/citrus-ui": {
"version": "0.1.13", "version": "0.1.14",
"resolved": "http://npmprivate.quantgroups.com/@qg%2fcitrus-ui/-/citrus-ui-0.1.13.tgz", "resolved": "http://npmprivate.quantgroups.com/@qg%2fcitrus-ui/-/citrus-ui-0.1.14.tgz",
"integrity": "sha512-hsiOo61SwlAhp1Cc0gmOhBCH4S7aESrftZAWqWp0HbL6qwcNTLqfIOUxiFJEw0m5nrU+Evjaa8H7iAsDOBkvLg==", "integrity": "sha512-88AJuAsBMugnMFkGA60S1quAH7UEh6iNjTqvq/hbQjV5UUSxksdAgdcF0+7ASSPb8aqek4XV2fdRrvC+YBtQxA==",
"requires": { "requires": {
"@better-scroll/core": "^2.1.1", "@better-scroll/core": "^2.1.1",
"@qg/cherry-ui": "^2.20.20", "@qg/cherry-ui": "^2.20.20",
......
...@@ -10,7 +10,7 @@ ...@@ -10,7 +10,7 @@
"dev": "egg-bin dev -r egg-ts-helper/register", "dev": "egg-bin dev -r egg-ts-helper/register",
"debug": "egg-bin debug -r egg-ts-helper/register", "debug": "egg-bin debug -r egg-ts-helper/register",
"apollo": "node bin/apollo.js", "apollo": "node bin/apollo.js",
"build": "cross-env COS_ENV=production easy build --devtool", "build": "npm run apollo && cross-env COS_ENV=production easy build --devtool",
"build:test": "cross-env COS_ENV=test easy build --devtool", "build:test": "cross-env COS_ENV=test easy build --devtool",
"tsc": "ets && tsc -p tsconfig.json", "tsc": "ets && tsc -p tsconfig.json",
"clean": "ets clean", "clean": "ets clean",
...@@ -24,7 +24,7 @@ ...@@ -24,7 +24,7 @@
"@better-scroll/core": "^2.0.5", "@better-scroll/core": "^2.0.5",
"@qg/apollo-nodejs": "^2.1.2", "@qg/apollo-nodejs": "^2.1.2",
"@qg/cherry-ui": "2.20.20", "@qg/cherry-ui": "2.20.20",
"@qg/citrus-ui": "0.1.13", "@qg/citrus-ui": "0.1.14",
"babel-plugin-transform-vue-jsx": "^4.0.1", "babel-plugin-transform-vue-jsx": "^4.0.1",
"cos-nodejs-sdk-v5": "^2.9.12", "cos-nodejs-sdk-v5": "^2.9.12",
"egg": "^2.3.0", "egg": "^2.3.0",
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment