Commit 74c9e100 authored by zhangtingting's avatar zhangtingting

Merge branch 'dev' of gitlab2.dui88.com:laoqifeng/zeroing-editor into test_ztt

parents 37c35fef 659c4e39
......@@ -174,6 +174,11 @@ export function findProcess(rootMetas, builtinMetas, filter) {
return result;
function findOnce(metas, parentPath) {
/*if (parentPath) {
//let pathStr = parentPath.map(item=>item.name || item.metaName).join('>');
let pathStr = parentPath.map(item => item.name || item.process.uuid.substr(0, 8)).join('>');
console.log('findProcess', pathStr);
}*/
for (let meta of metas) {
let path = parentPath ? parentPath : [];
if (!parentPath) {
......@@ -181,6 +186,9 @@ export function findProcess(rootMetas, builtinMetas, filter) {
}
for (let key in meta.sub) {
let subProcess = meta.sub[key];
if (path.find(item => item.process && item.process.uuid === subProcess.uuid)) {
break;
}
let subMeta = meta.metas ? meta.metas.find(item => item.id === subProcess.meta) : null;
if (!subMeta) {
subMeta = rootMetas.find(item => item.id === subProcess.meta);
......@@ -486,7 +494,7 @@ export function dataURLtoBlob(dataUrl) {
return new Blob([u8arr], {type: mime});
}
export async function zipViewFile(file){
export async function zipViewFile(file) {
let dataString = await readTextFile(file);
let buf = new Buffer(dataString);
......
......@@ -141,7 +141,8 @@ export async function packImages(assets, options = {}) {
}
async function deal(assets, urls, getSheetUrlByUUID, name, blob, frames) {
const sheetUUID = sha256(urls.sort().join()).toString();
//const sheetUUID = sha256(urls.sort().join()).toString();
const sheetUUID = sha256(Object.keys(frames).sort().join()).toString();
let url;
if (getSheetUrlByUUID) {
......
......@@ -53,7 +53,7 @@ export async function preprocess(project, packages) {
const dataUrl = URL.createObjectURL(new Blob([JSON.stringify(data)]));
const {libraryScriptElMap, analyseResult} = await generateLibraryScriptEl(tpl, dependencies, getPackages(packages), '//yun.duiba.com.cn/editor/zeroing/libs/');
const {libraryScriptElMap, analyseResult} = await generateLibraryScriptEl(tpl, dependencies, getPackages(packages), '//yun.duiba.com.cn/editor/zeroing/libs/', true);
tpl = fillTemplate(tpl, {
pageTitle,
......@@ -64,7 +64,7 @@ export async function preprocess(project, packages) {
tpl = tpl.replace('//yun.duiba.com.cn/aurora/$VERSION$-data.json', dataUrl);
console.log("塞入数据",storeName,data)
db.set(storeName, {
id: project.id,
data,
......
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