{"version":3,"sources":["webpack:///./src/sys/LangTranslate.vue?1e3d","webpack:///./src/sys/LangTranslate.vue?63fe","webpack:///./src/sys/LangTranslate.vue?3a07","webpack:///./src/sys/LangTranslate.vue?fef7","webpack:///./src/sys/LangTranslate.vue","webpack:///./src/sys/LangTranslate.vue?ccd3","webpack:///./src/sys/LangTranslate.vue?ad6e"],"names":["content","__esModule","default","module","i","locals","exports","add","___CSS_LOADER_API_IMPORT___","push","render","_vm","this","_h","$createElement","_c","_self","staticClass","attrs","on","handleOpen","_l","item","index","key","name","String","slot","_v","_s","staticStyle","$event","addTranslate","model","value","callback","$$v","chText","expression","search","keysData","currentRow","old","handleCurrentChange","scopedSlots","_u","fn","scope","row","LangKey","languageBody","saveBody","$set","deTranslate","pageData","count","limit","page","currentChange","staticRenderFns","ID","AppType","LangName","CompID","ChText","TranslateText","clickKey","form","formBody","isAddKey","compId","compName","menuType","options","post","api","then","res","State","Data","error","keyPath","console","log","getList","window","setTimeout","val","length","moment","$index","$confirm","confirmButtonText","cancelButtonText","type","$message","message","catch","params","List","TotalCount","body","success","component"],"mappings":"kHAAA,W,qBCGA,IAAIA,EAAU,EAAQ,QACnBA,EAAQC,aAAYD,EAAUA,EAAQE,SACnB,kBAAZF,IAAsBA,EAAU,CAAC,CAACG,EAAOC,EAAIJ,EAAS,MAC7DA,EAAQK,SAAQF,EAAOG,QAAUN,EAAQK,QAE5C,IAAIE,EAAM,EAAQ,QAA+DL,QACpEK,EAAI,WAAYP,GAAS,EAAM,CAAC,WAAY,EAAM,YAAa,K,qBCR5E,IAAIQ,EAA8B,EAAQ,QAC1CF,EAAUE,GAA4B,GAEtCF,EAAQG,KAAK,CAACN,EAAOC,EAAI,+sBAAgtB,KAEzuBD,EAAOG,QAAUA,G,yCCNjB,IAAII,EAAS,WAAa,IAAIC,EAAIC,KAASC,EAAGF,EAAIG,eAAmBC,EAAGJ,EAAIK,MAAMD,IAAIF,EAAG,OAAOE,EAAG,MAAM,CAACE,YAAY,YAAY,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AK+E,SAAS,aAAc,KAAM,CAC9BC,kBAAmB,KACnBC,iBAAkB,KAClBC,KAAM,YACPlB,MAAK,WACJ,OAAGF,KAAH,UAAW,OAAIC,IAAf,yBAAmC5B,EAAMC,IAAIY,KAAMgB,MAAK,SAACW,GACpC,GAAbA,EAAIT,OACJ,EAAKnC,oBAAoB,EAAKuB,UAC9B,OAAIoC,QAAQ,SAEZ,OAAItB,MAAM,cAGnBiB,OAAM,WACL,EAAKF,SAAS,CACVD,KAAM,OACNE,QAAS,eApKzB,sBAyKI,SAAS1E,GACL4D,QAAQC,IAAI7D,GASZV,KAAKwD,SAASR,GAAKtC,EAAKsC,GACxBhD,KAAKwD,SAASJ,OAAS1C,EAAK0C,OAC5BpD,KAAKwD,SAASH,cAAgB3C,EAAK2C,cACnC,OAAGS,KAAH,UAAW,OAAIC,IAAf,eAAiC/D,KAAKwD,UAAUQ,MAAK,SAACW,GACjC,GAAbA,EAAIT,MACJxD,EAAKsC,GAAK2B,EAAIR,KAGd,OAAIC,MAAM,aA3L1B,qBA+LI,WACIpE,KAAKQ,WAAW,EAAG,CAAC,QAhM5B,GAA+C,QAA1B,EAAiB,gBADrC,QACoB,WC5FmX,I,wBCQpYmF,EAAY,eACd,EACA7F,EACAiD,GACA,EACA,KACA,WACA,MAIa,aAAA4C,E","file":"js/chunk-ce4d660c.6b4b31b2.js","sourcesContent":["export * from \"-!../../node_modules/vue-style-loader/index.js??ref--10-oneOf-1-0!../../node_modules/css-loader/dist/cjs.js??ref--10-oneOf-1-1!../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../node_modules/postcss-loader/src/index.js??ref--10-oneOf-1-2!../../node_modules/postcss-loader/src/index.js??ref--10-oneOf-1-3!../../node_modules/less-loader/dist/cjs.js??ref--10-oneOf-1-4!../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./LangTranslate.vue?vue&type=style&index=0&id=fc2af4dc&lang=less&scoped=true&\"","// style-loader: Adds some css to the DOM by adding a <style> tag\n\n// load the styles\nvar content = require(\"!!../../node_modules/css-loader/dist/cjs.js??ref--10-oneOf-1-1!../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../node_modules/postcss-loader/src/index.js??ref--10-oneOf-1-2!../../node_modules/postcss-loader/src/index.js??ref--10-oneOf-1-3!../../node_modules/less-loader/dist/cjs.js??ref--10-oneOf-1-4!../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./LangTranslate.vue?vue&type=style&index=0&id=fc2af4dc&lang=less&scoped=true&\");\nif(content.__esModule) content = content.default;\nif(typeof content === 'string') content = [[module.id, content, '']];\nif(content.locals) module.exports = content.locals;\n// add the styles to the DOM\nvar add = require(\"!../../node_modules/vue-style-loader/lib/addStylesClient.js\").default\nvar update = add(\"e5c8ea7a\", content, true, {\"sourceMap\":false,\"shadowMode\":false});","// Imports\nvar ___CSS_LOADER_API_IMPORT___ = require(\"../../node_modules/css-loader/dist/runtime/api.js\");\nexports = ___CSS_LOADER_API_IMPORT___(false);\n// Module\nexports.push([module.id, \".main-body>div[data-v-fc2af4dc]{flex-direction:row}[data-v-fc2af4dc] .el-table .el-table__cell{padding:12px 0!important}.language[data-v-fc2af4dc]{padding:15px 25px;display:flex}.language .menu[data-v-fc2af4dc]{width:10%}.language .languageIndex[data-v-fc2af4dc]{width:90%}.language .languageIndex .top[data-v-fc2af4dc]{display:flex;flex-direction:column}.language .languageIndex .top .buttons[data-v-fc2af4dc]{margin-top:5px}.language .languageIndex .languageBody[data-v-fc2af4dc]{margin-top:10px;display:flex}.language .languageIndex .languageBody .keyWord[data-v-fc2af4dc]{margin-left:2%;width:25%;overflow:auto}.language .languageIndex .languageBody .body[data-v-fc2af4dc]{width:65%;margin-left:3%;overflow:auto}\", \"\"]);\n// Exports\nmodule.exports = exports;\n","var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:\"language\"},[_c('div',{staticClass:\"menu\"},[_c('el-menu',{staticClass:\"el-menu-vertical-demo\",attrs:{\"default-active\":\"1\"},on:{\"select\":_vm.handleOpen}},_vm._l((_vm.options),function(item,index){return _c('el-menu-item',{key:item.name,attrs:{\"index\":String(index + 1)}},[_c('span',{attrs:{\"slot\":\"title\"},slot:\"title\"},[_vm._v(_vm._s(item.name))])])}),1)],1),_c('div',{staticClass:\"languageIndex\"},[_c('div',{staticClass:\"top\"},[_c('div',{staticClass:\"buttons\"},[_c('el-button',{staticStyle:{\"margin-left\":\"30%\"},attrs:{\"type\":\"primary\",\"icon\":\"el-icon-plus\",\"size\":\"small\",\"circle\":\"\"},on:{\"click\":function($event){return _vm.addTranslate()}}}),_c('el-input',{staticStyle:{\"width\":\"300px\",\"margin-left\":\"10px\"},attrs:{\"placeholder\":\"搜索\"},model:{value:(_vm.chText),callback:function ($$v) {_vm.chText=$$v},expression:\"chText\"}},[_c('el-button',{attrs:{\"slot\":\"append\",\"icon\":\"el-icon-search\",\"type\":\"primary\"},on:{\"click\":_vm.search},slot:\"append\"})],1)],1)]),_c('div',{staticClass:\"languageBody\"},[_c('div',{staticClass:\"keyWord\"},[_c('el-table',{attrs:{\"data\":_vm.keysData,\"stripe\":\"\",\"border\":\"\",\"highlight-current-row\":\"\"},on:{\"current-change\":function (currentRow, old) { return _vm.handleCurrentChange(currentRow, 1); }}},[_c('el-table-column',{attrs:{\"prop\":\"LangKey\",\"label\":\"语言关键字\",\"align\":\"center\"},scopedSlots:_vm._u([{key:\"default\",fn:function(scope){return [_c('span',{staticStyle:{\"line-height\":\"16px\"}},[_vm._v(_vm._s(scope.row.LangKey))])]}}])}),_c('el-table-column',{attrs:{\"prop\":\"LangName\",\"label\":\"语言名称\",\"align\":\"center\"}})],1)],1),_c('div',{staticClass:\"body\"},[_c('el-table',{attrs:{\"data\":_vm.languageBody,\"stripe\":\"\",\"border\":\"\",\"height\":\"calc(100vh - 242px)\"}},[_c('el-table-column',{attrs:{\"prop\":\"ChText\",\"label\":\"中文内容\",\"align\":\"center\"},scopedSlots:_vm._u([{key:\"default\",fn:function(scope){return [_c('el-input',{attrs:{\"placeholder\":\"请输入关键字\"},on:{\"blur\":function($event){return _vm.saveBody(scope.row)}},model:{value:(scope.row.ChText),callback:function ($$v) {_vm.$set(scope.row, \"ChText\", $$v)},expression:\"scope.row.ChText\"}})]}}])}),_c('el-table-column',{attrs:{\"prop\":\"TranslateText\",\"label\":\"翻译内容\",\"align\":\"center\"},scopedSlots:_vm._u([{key:\"default\",fn:function(scope){return [_c('el-input',{attrs:{\"placeholder\":\"请输入关键字\"},on:{\"blur\":function($event){return _vm.saveBody(scope.row)}},model:{value:(scope.row.TranslateText),callback:function ($$v) {_vm.$set(scope.row, \"TranslateText\", $$v)},expression:\"scope.row.TranslateText\"}})]}}])}),_c('el-table-column',{attrs:{\"label\":\"操作\",\"width\":\"120\",\"align\":\"center\"},scopedSlots:_vm._u([{key:\"default\",fn:function(scope){return [_c('el-button',{attrs:{\"type\":\"danger\",\"icon\":\"el-icon-delete\",\"size\":\"small\",\"circle\":\"\"},on:{\"click\":function($event){return _vm.deTranslate(scope)}}})]}}])})],1),_c('el-pagination',{staticClass:\"pagination\",staticStyle:{\"margin-top\":\"10px\"},attrs:{\"background\":\"\",\"layout\":\"total, prev, pager, next, jumper\",\"total\":_vm.pageData.count,\"page-size\":_vm.pageData.limit,\"current-page\":_vm.pageData.page},on:{\"current-change\":_vm.currentChange}})],1)])])])}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\r\nimport { Component, Vue } from \"vue-property-decorator\";\r\nimport { Db, Url, Util, Msg } from '@/libs/Utility.ts';\r\n//定义翻译数据类\r\nclass Keys {\r\n    ID = \"\";\r\n    LangKey = '';//关键字\r\n    AppType = '';//类型\r\n    LangName = \"\";//哪种语言\r\n    CompID = \"\";//企业id\r\n}\r\nclass Translate {\r\n    ID = \"\";\r\n    AppType = \"\";\r\n    LangKey = \"\"; //关键字\r\n    ChText = \"\";\r\n    TranslateText = \"\";\r\n    //CompID = \"\";\r\n}\r\n@Component\r\nexport default class LanguageTranslate extends Vue {\r\n    pageData = {\r\n        page: 1, //第几页\r\n        limit: 10,//一页多少条\r\n        count: 0 //总数\r\n    }\r\n    chText=''; //搜索关键字\r\n    keysData: Keys[] = [];//翻译数据\r\n    clickKey: Keys = new Keys(); //点击的关键字对象\r\n    form: Keys = new Keys(); //关键字表单\r\n    formBody: Translate = new Translate();\r\n    isAddKey = true;//是否是新增关键字\r\n    compId = ''//User.getCompID()\r\n    compName = '';\r\n    menuType = 'weChat'\r\n    options = [\r\n        {\r\n            name: '小程序',\r\n            value: 'weChat',\r\n        },\r\n        {\r\n            name: '网页端',\r\n            value: 'web',\r\n            //disable: User.getCompID() == 1\r\n        },\r\n        {\r\n            name: '电脑端',\r\n            value: 'client',\r\n        },\r\n    ]\r\n    languageBody: Translate[] = [] //具体某种语言的数据\r\n    //获取列表\r\n    async getList() {\r\n        Db.post(`${Url.api}/trans/comp/list?type=${this.menuType}`).then((res: any) => {\r\n            if (res.State == 0) {\r\n                this.keysData = res.Data;\r\n                //this.handleCurrentChange(res.Data[0])\r\n            } else {\r\n                Msg.error(res.Data)\r\n            }\r\n        })\r\n    }\r\n    //类型匹配方法\r\n    getOption(key: string) {\r\n        switch (key) {\r\n            case 'weChat': return '小程序';\r\n            case 'web': return '网页端';\r\n            case 'client': return '电脑端';\r\n            case 'params': return '参数';\r\n        }\r\n    }\r\n    //点击目录\r\n    async handleOpen(key: any, keyPath: any) {\r\n        console.log(key, keyPath);\r\n        this.form.AppType = this.options[key - 1].value;\r\n        this.formBody.AppType = this.options[key - 1].value;\r\n        console.log(this.form)\r\n        this.menuType = this.options[key - 1].value\r\n        await this.getList()\r\n        window.setTimeout((val:any) => {\r\n            console.log('keysData', this.keysData)\r\n            if (this.keysData.length <= 0) {\r\n                this.languageBody = []\r\n            } else {\r\n                this.handleCurrentChange(this.keysData[0])\r\n            }\r\n        },500)\r\n\r\n    }\r\n    //修改左侧关键字\r\n    onExchange(scope: any) {\r\n        const moment = this.keysData[scope.$index]\r\n        this.$set(this.keysData, scope.$index, moment)\r\n        Db.post('', this.keysData).then()\r\n    }\r\n    //删除关键字\r\n    delKey(scope: any) {\r\n        this.$confirm('是否删除此关键字?', '提示', {\r\n            confirmButtonText: '确定',\r\n            cancelButtonText: '取消',\r\n            type: 'warning'\r\n        }).then(() => {\r\n            Db.post(`${Url.api}/trans/comp/del?id=${scope.row.ID}`).then((val: any) => {\r\n                if (val.State == 0) {\r\n                    this.getList();\r\n                    this.$message({\r\n                        type: 'success',\r\n                        message: '删除成功!'\r\n                    });\r\n                }\r\n            })\r\n\r\n        }).catch(() => {\r\n            this.$message({\r\n                type: 'info',\r\n                message: '已取消删除'\r\n            });\r\n        });\r\n    }\r\n    //点击左侧列表\r\n    handleCurrentChange(val: Keys, page?: number) {\r\n        console.log('page', page)\r\n        console.log(val)\r\n        this.pageData.page = page ? page : this.pageData.page\r\n        if (!val) { return }\r\n        this.clickKey = val;\r\n        //this.formBody.AppType = val.AppType;\r\n        this.formBody.LangKey = val.LangKey;\r\n        const params = {\r\n            AppType: this.menuType,\r\n            LangKey: val.LangKey\r\n        }\r\n        Db.post(`${Url.api}/trans/search?page=${this.pageData.page}&count=${this.pageData.limit}`, params).then((item: any) => {\r\n            if (item.State == 0) {\r\n                this.languageBody = item.Data.List\r\n                this.pageData.count = item.Data.TotalCount\r\n            }\r\n        })\r\n        //this.pageData.page = 1\r\n    }\r\n    //搜索\r\n    search(){\r\n        const params = {\r\n            AppType: this.menuType,\r\n            LangKey: this.clickKey.LangKey,\r\n            ChText:this.chText\r\n        }\r\n        Db.post(`${Url.api}/trans/search?page=${this.pageData.page}&count=${this.pageData.limit}`, params).then((item: any) => {\r\n            if (item.State == 0) {\r\n                this.languageBody = item.Data.List\r\n                this.pageData.count = item.Data.TotalCount\r\n            }\r\n        })\r\n    }\r\n    //翻页\r\n    currentChange(val: any) {\r\n        this.pageData.page = val;\r\n        this.handleCurrentChange(this.clickKey, val)\r\n    }\r\n    //新增具体翻译内容\r\n    addTranslate() {\r\n        const body: Translate = new Translate();\r\n        body.AppType = this.formBody.AppType;\r\n        body.LangKey = this.formBody.LangKey;\r\n        this.languageBody.push(body);\r\n    }\r\n    //删除具体翻译内容\r\n    deTranslate(scope: any) {\r\n        this.$confirm('是否删除此翻译内容?', '提示', {\r\n            confirmButtonText: '确定',\r\n            cancelButtonText: '取消',\r\n            type: 'warning'\r\n        }).then(() => {\r\n            Db.post(`${Url.api}/trans/del?id=${scope.row.ID}`).then((val: any) => {\r\n                if (val.State == 0) {\r\n                    this.handleCurrentChange(this.clickKey)\r\n                    Msg.success('操作成功')\r\n                } else {\r\n                    Msg.error('操作失败')\r\n                }\r\n            })\r\n        }).catch(() => {\r\n            this.$message({\r\n                type: 'info',\r\n                message: '已取消删除'\r\n            });\r\n        });\r\n    }\r\n    //保存翻译内容\r\n    saveBody(item: Translate) {\r\n        console.log(item)\r\n        /* console.log(this.languageBody)\r\n        const languageFil = this.languageBody.filter(val=>{\r\n            return val.ChText == item.ChText\r\n        })\r\n        if(languageFil.length>1){\r\n            Msg.warning('该翻译内容已添加过')\r\n            return\r\n        } */\r\n        this.formBody.ID = item.ID;\r\n        this.formBody.ChText = item.ChText;\r\n        this.formBody.TranslateText = item.TranslateText;\r\n        Db.post(`${Url.api}/trans/save`, this.formBody).then((val: any) => {\r\n            if (val.State == 0) {\r\n                item.ID = val.Data\r\n                //this.handleCurrentChange(this.clickKey)\r\n            } else {\r\n                Msg.error('操作失败')\r\n            }\r\n        })\r\n    }\r\n    mounted() {\r\n        this.handleOpen(1, [1])\r\n        // this.getList()\r\n        // this.handleCurrentChange(this.keysData[0])\r\n    }\r\n}\r\n","import mod from \"-!../../node_modules/cache-loader/dist/cjs.js??ref--14-0!../../node_modules/thread-loader/dist/cjs.js!../../node_modules/babel-loader/lib/index.js!../../node_modules/ts-loader/index.js??ref--14-3!../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./LangTranslate.vue?vue&type=script&lang=ts&\"; export default mod; export * from \"-!../../node_modules/cache-loader/dist/cjs.js??ref--14-0!../../node_modules/thread-loader/dist/cjs.js!../../node_modules/babel-loader/lib/index.js!../../node_modules/ts-loader/index.js??ref--14-3!../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./LangTranslate.vue?vue&type=script&lang=ts&\"","import { render, staticRenderFns } from \"./LangTranslate.vue?vue&type=template&id=fc2af4dc&scoped=true&\"\nimport script from \"./LangTranslate.vue?vue&type=script&lang=ts&\"\nexport * from \"./LangTranslate.vue?vue&type=script&lang=ts&\"\nimport style0 from \"./LangTranslate.vue?vue&type=style&index=0&id=fc2af4dc&lang=less&scoped=true&\"\n\n\n/* normalize component */\nimport normalizer from \"!../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n  script,\n  render,\n  staticRenderFns,\n  false,\n  null,\n  \"fc2af4dc\",\n  null\n  \n)\n\nexport default component.exports"],"sourceRoot":""}