@ailaw/venus 0.3.6 → 0.3.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/en3.js +3 -1
- package/dist/venus.es.js +93 -58
- package/package.json +1 -1
package/dist/en3.js
CHANGED
|
@@ -858,6 +858,8 @@ var lang3 = {
|
|
|
858
858
|
tasks: "Tasks",
|
|
859
859
|
sendTaskEmail: "Send the notification email",
|
|
860
860
|
none: "None",
|
|
861
|
-
taskSetting: "Task setting"
|
|
861
|
+
taskSetting: "Task setting",
|
|
862
|
+
lastUpdatedTime: "Last Updated Time",
|
|
863
|
+
lastUpdatedBy: "Last Updated By"
|
|
862
864
|
};
|
|
863
865
|
export { lang3 as default };
|
package/dist/venus.es.js
CHANGED
|
@@ -912,7 +912,7 @@ function __vue2_injectStyles$9(context) {
|
|
|
912
912
|
var AFileUploader = /* @__PURE__ */ function() {
|
|
913
913
|
return __component__$9.exports;
|
|
914
914
|
}();
|
|
915
|
-
|
|
915
|
+
var refactorParams = (record) => {
|
|
916
916
|
var _a2;
|
|
917
917
|
return {
|
|
918
918
|
id: record.id,
|
|
@@ -1029,7 +1029,7 @@ var render$8 = function() {
|
|
|
1029
1029
|
var staticRenderFns$8 = [];
|
|
1030
1030
|
var index_vue_vue_type_style_index_0_scoped_true_lang$3 = "";
|
|
1031
1031
|
const __cssModules$8 = {};
|
|
1032
|
-
var __component__$8 = /* @__PURE__ */ normalizeComponent(__vue2_script$8, render$8, staticRenderFns$8, false, __vue2_injectStyles$8, "
|
|
1032
|
+
var __component__$8 = /* @__PURE__ */ normalizeComponent(__vue2_script$8, render$8, staticRenderFns$8, false, __vue2_injectStyles$8, "40080928", null, null);
|
|
1033
1033
|
function __vue2_injectStyles$8(context) {
|
|
1034
1034
|
for (let o in __cssModules$8) {
|
|
1035
1035
|
this[o] = __cssModules$8[o];
|
|
@@ -2299,36 +2299,41 @@ var useSearchTaskTemplates = (pagination, conditions = ref$1({}), lawFirmId) =>
|
|
|
2299
2299
|
}));
|
|
2300
2300
|
};
|
|
2301
2301
|
const taskTemplateFragment = gql`
|
|
2302
|
-
|
|
2303
|
-
|
|
2304
|
-
|
|
2305
|
-
|
|
2306
|
-
|
|
2307
|
-
|
|
2308
|
-
|
|
2309
|
-
|
|
2310
|
-
|
|
2311
|
-
|
|
2312
|
-
|
|
2302
|
+
fragment taskTemplate on TaskTemplate {
|
|
2303
|
+
id
|
|
2304
|
+
taskName
|
|
2305
|
+
tagList
|
|
2306
|
+
isEmployee
|
|
2307
|
+
generalTaskType
|
|
2308
|
+
descriptions
|
|
2309
|
+
sampleDocs {
|
|
2310
|
+
id
|
|
2311
|
+
name
|
|
2312
|
+
link
|
|
2313
|
+
}
|
|
2314
|
+
updatedUser{
|
|
2315
|
+
id
|
|
2316
|
+
name
|
|
2317
|
+
}
|
|
2318
|
+
updatedOn
|
|
2313
2319
|
}
|
|
2314
|
-
}
|
|
2315
2320
|
`;
|
|
2316
2321
|
const SearchTaskTemplatesQuery = gql`
|
|
2317
|
-
|
|
2318
|
-
|
|
2319
|
-
|
|
2320
|
-
|
|
2321
|
-
|
|
2322
|
-
|
|
2323
|
-
|
|
2324
|
-
|
|
2325
|
-
|
|
2326
|
-
|
|
2327
|
-
|
|
2328
|
-
|
|
2322
|
+
query taskTemplateSearch(
|
|
2323
|
+
$query: TaskTemplateFilterInput!
|
|
2324
|
+
$startIndex: Int
|
|
2325
|
+
$endIndex: Int
|
|
2326
|
+
$lawFirmId: Int!
|
|
2327
|
+
) {
|
|
2328
|
+
taskTemplateSearch(query: $query) {
|
|
2329
|
+
numResult
|
|
2330
|
+
taskTemplateList(startIndex: $startIndex, endIndex: $endIndex) {
|
|
2331
|
+
...taskTemplate
|
|
2332
|
+
isGallery(selfLawFirmId: $lawFirmId)
|
|
2333
|
+
}
|
|
2334
|
+
}
|
|
2329
2335
|
}
|
|
2330
|
-
|
|
2331
|
-
${taskTemplateFragment}
|
|
2336
|
+
${taskTemplateFragment}
|
|
2332
2337
|
`;
|
|
2333
2338
|
var useTaskActions = (addedTasks, emit) => {
|
|
2334
2339
|
const addTask = (record) => emit("update:addedTasks", [...addedTasks.value, record]);
|
|
@@ -2346,6 +2351,43 @@ var useTaskActions = (addedTasks, emit) => {
|
|
|
2346
2351
|
removeTask
|
|
2347
2352
|
};
|
|
2348
2353
|
};
|
|
2354
|
+
var useTaskTemplateTableData = (props, emit) => {
|
|
2355
|
+
const initialPagination = ref$1({
|
|
2356
|
+
current: 1,
|
|
2357
|
+
pageSize: 6,
|
|
2358
|
+
total: 0
|
|
2359
|
+
});
|
|
2360
|
+
const { conditions, addedTasks = ref$1([]) } = toRefs$1(props);
|
|
2361
|
+
const { result, loading, refetch } = useSearchTaskTemplates(initialPagination, conditions, props.lawFirmId);
|
|
2362
|
+
const dataSource = computed(() => {
|
|
2363
|
+
var _a2;
|
|
2364
|
+
return ((_a2 = result.value) == null ? void 0 : _a2.taskTemplateSearch.taskTemplateList) || [];
|
|
2365
|
+
});
|
|
2366
|
+
const total = computed(() => {
|
|
2367
|
+
var _a2;
|
|
2368
|
+
return ((_a2 = result.value) == null ? void 0 : _a2.taskTemplateSearch.numResult) || 0;
|
|
2369
|
+
});
|
|
2370
|
+
const pagination = computed(() => __spreadProps(__spreadValues({}, initialPagination.value), {
|
|
2371
|
+
total: total.value
|
|
2372
|
+
}));
|
|
2373
|
+
const changePagination = (pagination2) => {
|
|
2374
|
+
initialPagination.value = __spreadValues({}, pagination2);
|
|
2375
|
+
};
|
|
2376
|
+
const { addTask, editTask, removeTask } = useTaskActions(addedTasks, emit);
|
|
2377
|
+
return {
|
|
2378
|
+
addTask,
|
|
2379
|
+
editTask,
|
|
2380
|
+
removeTask,
|
|
2381
|
+
changePagination,
|
|
2382
|
+
pagination,
|
|
2383
|
+
dataSource,
|
|
2384
|
+
result,
|
|
2385
|
+
loading,
|
|
2386
|
+
refetch,
|
|
2387
|
+
conditions,
|
|
2388
|
+
addedTasks
|
|
2389
|
+
};
|
|
2390
|
+
};
|
|
2349
2391
|
var __vue2_script$4 = defineComponent({
|
|
2350
2392
|
name: "TaskTable",
|
|
2351
2393
|
components: {
|
|
@@ -2366,28 +2408,16 @@ var __vue2_script$4 = defineComponent({
|
|
|
2366
2408
|
}
|
|
2367
2409
|
},
|
|
2368
2410
|
setup(props, { emit }) {
|
|
2369
|
-
const
|
|
2370
|
-
|
|
2371
|
-
|
|
2372
|
-
|
|
2373
|
-
|
|
2374
|
-
|
|
2375
|
-
|
|
2376
|
-
|
|
2377
|
-
|
|
2378
|
-
|
|
2379
|
-
});
|
|
2380
|
-
const total = computed(() => {
|
|
2381
|
-
var _a2;
|
|
2382
|
-
return ((_a2 = result.value) == null ? void 0 : _a2.taskTemplateSearch.numResult) || 0;
|
|
2383
|
-
});
|
|
2384
|
-
const pagination = computed(() => __spreadProps(__spreadValues({}, initialPagination.value), {
|
|
2385
|
-
total: total.value
|
|
2386
|
-
}));
|
|
2387
|
-
const changePagination = (pagination2) => {
|
|
2388
|
-
initialPagination.value = __spreadValues({}, pagination2);
|
|
2389
|
-
};
|
|
2390
|
-
const { addTask, editTask, removeTask } = useTaskActions(addedTasks, emit);
|
|
2411
|
+
const {
|
|
2412
|
+
loading,
|
|
2413
|
+
refetch,
|
|
2414
|
+
dataSource,
|
|
2415
|
+
pagination,
|
|
2416
|
+
changePagination,
|
|
2417
|
+
addTask,
|
|
2418
|
+
editTask,
|
|
2419
|
+
removeTask
|
|
2420
|
+
} = useTaskTemplateTableData(props, emit);
|
|
2391
2421
|
return {
|
|
2392
2422
|
loading,
|
|
2393
2423
|
refetch,
|
|
@@ -2410,7 +2440,7 @@ var render$4 = function() {
|
|
|
2410
2440
|
var staticRenderFns$4 = [];
|
|
2411
2441
|
var TaskTable_vue_vue_type_style_index_0_scoped_true_lang = "";
|
|
2412
2442
|
const __cssModules$4 = {};
|
|
2413
|
-
var __component__$4 = /* @__PURE__ */ normalizeComponent(__vue2_script$4, render$4, staticRenderFns$4, false, __vue2_injectStyles$4, "
|
|
2443
|
+
var __component__$4 = /* @__PURE__ */ normalizeComponent(__vue2_script$4, render$4, staticRenderFns$4, false, __vue2_injectStyles$4, "52cec9c7", null, null);
|
|
2414
2444
|
function __vue2_injectStyles$4(context) {
|
|
2415
2445
|
for (let o in __cssModules$4) {
|
|
2416
2446
|
this[o] = __cssModules$4[o];
|
|
@@ -2562,7 +2592,9 @@ var render$2 = function() {
|
|
|
2562
2592
|
var _vm = this;
|
|
2563
2593
|
var _h = _vm.$createElement;
|
|
2564
2594
|
var _c = _vm._self._c || _h;
|
|
2565
|
-
return _c("ant-modal", { attrs: { "zIndex": 900, "width": "900px", "visible": _vm.visible, "title": _vm.$t("message.reviewTasksTitle") }
|
|
2595
|
+
return _c("ant-modal", { attrs: { "zIndex": 900, "width": "900px", "visible": _vm.visible, "title": _vm.$t("message.reviewTasksTitle") }, on: { "cancel": function($event) {
|
|
2596
|
+
return _vm.$emit("update:visible", false);
|
|
2597
|
+
} } }, [_c("task-table-pure", { attrs: { "show-edit": false, "loading": false, "no-edit": true, "data-source": _vm.addedTasks, "pagination": _vm.pagination, "added-tasks": _vm.addedTasks }, on: { "removeTask": _vm.removeTask, "changePagination": _vm.changePagination } }), _c("div", { attrs: { "slot": "footer" }, slot: "footer" }, [_vm.showSendEmail ? _c("ant-checkbox", { staticStyle: { "float": "left" }, attrs: { "checked": _vm.sendEmail }, on: { "change": function($event) {
|
|
2566
2598
|
return _vm.$emit("update:sendEmail", $event.target.checked);
|
|
2567
2599
|
} } }, [_vm._v(" " + _vm._s(_vm.$t("message.sendTaskEmail")) + " ")]) : _vm._e(), _c("ant-button", { on: { "click": function($event) {
|
|
2568
2600
|
return _vm.$emit("update:visible", false);
|
|
@@ -2580,7 +2612,7 @@ var render$2 = function() {
|
|
|
2580
2612
|
var staticRenderFns$2 = [];
|
|
2581
2613
|
var ReviewModal_vue_vue_type_style_index_0_scoped_true_lang = "";
|
|
2582
2614
|
const __cssModules$2 = {};
|
|
2583
|
-
var __component__$2 = /* @__PURE__ */ normalizeComponent(__vue2_script$2, render$2, staticRenderFns$2, false, __vue2_injectStyles$2, "
|
|
2615
|
+
var __component__$2 = /* @__PURE__ */ normalizeComponent(__vue2_script$2, render$2, staticRenderFns$2, false, __vue2_injectStyles$2, "3f8e3a92", null, null);
|
|
2584
2616
|
function __vue2_injectStyles$2(context) {
|
|
2585
2617
|
for (let o in __cssModules$2) {
|
|
2586
2618
|
this[o] = __cssModules$2[o];
|
|
@@ -6322,18 +6354,21 @@ var __vue2_script$1 = defineComponent({
|
|
|
6322
6354
|
}
|
|
6323
6355
|
});
|
|
6324
6356
|
const submit = async (record) => {
|
|
6325
|
-
var _a2, _b, _c;
|
|
6357
|
+
var _a2, _b, _c, _d;
|
|
6326
6358
|
let newRecord = {};
|
|
6327
6359
|
console.log(record);
|
|
6328
6360
|
let res;
|
|
6361
|
+
let success;
|
|
6329
6362
|
if (record.taskTemplateId) {
|
|
6330
6363
|
res = await updateTemplate.mutate(record);
|
|
6331
6364
|
newRecord = ((_a2 = res == null ? void 0 : res.data) == null ? void 0 : _a2.updateTaskTemplate.updatedTaskTemplate) || {};
|
|
6365
|
+
success = ((_b = res == null ? void 0 : res.data) == null ? void 0 : _b.updateTaskTemplate.code) === ResponseCode.success;
|
|
6332
6366
|
} else {
|
|
6333
6367
|
res = await createTemplate.mutate(record);
|
|
6334
|
-
newRecord = ((
|
|
6368
|
+
newRecord = ((_c = res == null ? void 0 : res.data) == null ? void 0 : _c.createTaskTemplate.newTaskTemplate) || {};
|
|
6369
|
+
success = ((_d = res == null ? void 0 : res.data) == null ? void 0 : _d.createTaskTemplate.code) === ResponseCode.success;
|
|
6335
6370
|
}
|
|
6336
|
-
if (
|
|
6371
|
+
if (success) {
|
|
6337
6372
|
newTaskVisible.value = false;
|
|
6338
6373
|
message.success("Success!");
|
|
6339
6374
|
mainModal.value.taskTable.refetch();
|
|
@@ -6412,7 +6447,7 @@ var render$1 = function() {
|
|
|
6412
6447
|
var staticRenderFns$1 = [];
|
|
6413
6448
|
var index_vue_vue_type_style_index_0_scoped_true_lang = "";
|
|
6414
6449
|
const __cssModules$1 = {};
|
|
6415
|
-
var __component__$1 = /* @__PURE__ */ normalizeComponent(__vue2_script$1, render$1, staticRenderFns$1, false, __vue2_injectStyles$1, "
|
|
6450
|
+
var __component__$1 = /* @__PURE__ */ normalizeComponent(__vue2_script$1, render$1, staticRenderFns$1, false, __vue2_injectStyles$1, "2a10fa2e", null, null);
|
|
6416
6451
|
function __vue2_injectStyles$1(context) {
|
|
6417
6452
|
for (let o in __cssModules$1) {
|
|
6418
6453
|
this[o] = __cssModules$1[o];
|
|
@@ -6450,4 +6485,4 @@ function __vue2_injectStyles(context) {
|
|
|
6450
6485
|
var index = /* @__PURE__ */ function() {
|
|
6451
6486
|
return __component__.exports;
|
|
6452
6487
|
}();
|
|
6453
|
-
export { AssigneeTag, NewTask, index$3 as ProfileSelect, TagsWithTooltip, index$1 as TaskCart, TaskForm, TaskTable, TaskTemplateFilter, index as TestComponent, index$2 as forms, getLanguageMessage, useSearchTaskConditions, useSearchTaskTemplates };
|
|
6488
|
+
export { AssigneeTag, NewTask, index$3 as ProfileSelect, TagsWithTooltip, index$1 as TaskCart, TaskForm, TaskTable, TaskTemplateFilter, index as TestComponent, index$2 as forms, getLanguageMessage, refactorParams as refactorTaskTemplateParams, useSearchTaskConditions, useSearchTaskTemplates };
|