diff --git a/database/migrations/2019_08_23_152615_create_module_user.php b/database/migrations/2019_08_23_152615_create_module_user.php deleted file mode 100644 index 5cd4a85..0000000 --- a/database/migrations/2019_08_23_152615_create_module_user.php +++ /dev/null @@ -1,37 +0,0 @@ -unsignedInteger('module_id'); - $table->unsignedInteger('user_id'); - $table->unique(['module_id', 'user_id']); - $table->index('module_id'); - $table->index('user_id'); - $table->timestamps(); - }); - } - - /** - * Reverse the migrations. - * - * @return void - */ - public function down() - { - $dbName = config('core.db_name'); - Schema::dropIfExists("$dbName.module_user"); - } -} diff --git a/database/migrations/2019_10_06_173827_temp_update_columns.php b/database/migrations/2019_10_06_173827_temp_update_columns.php new file mode 100644 index 0000000..ad4a96d --- /dev/null +++ b/database/migrations/2019_10_06_173827_temp_update_columns.php @@ -0,0 +1,50 @@ +string('father_name', 255)->nullable(); + $table->string('telegram', 255)->nullable(); + $table->string('website', 255)->nullable(); + $table->text('description')->nullable(); + $table->unsignedInteger('client_title_id')->nullable(); + $table->foreign('client_title_id')->references('id')->on('client_titles'); + $table->dropColumn('client_category_id'); + }); + + Schema::table("$dbName.client_statuses", function (Blueprint $table) { + $table->string('color', 255)->nullable(); + $table->string('icon', 255)->nullable(); + }); + + $dbName = config('common.db_name'); + + Schema::table("$dbName.task_statuses", function (Blueprint $table) { + $table->string('color', 255)->nullable(); + $table->string('icon', 255)->nullable(); + }); + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + + } +} diff --git a/package-lock.json b/package-lock.json index 078f474..bee751b 100644 --- a/package-lock.json +++ b/package-lock.json @@ -11416,6 +11416,11 @@ "integrity": "sha512-4gDntzrifFnCEvyoO8PqyJDmguXgVPxKiIxrBKjIowvL9l+N66196+72XVYR8BBf1Uv1Fgt3bGevJ+sEmxfZzw==", "dev": true }, + "vue-the-mask": { + "version": "0.11.1", + "resolved": "https://registry.npmjs.org/vue-the-mask/-/vue-the-mask-0.11.1.tgz", + "integrity": "sha512-UquSfnSWejD0zAfcD+3jJ1chUAkOAyoxya9Lxh9acCRtrlmGcAIvd0cQYraWqKenbuZJUdum+S174atv2AuEHQ==" + }, "vue-tinymce-editor": { "version": "1.6.2", "resolved": "https://registry.npmjs.org/vue-tinymce-editor/-/vue-tinymce-editor-1.6.2.tgz", diff --git a/package.json b/package.json index 5d471d5..04f7597 100644 --- a/package.json +++ b/package.json @@ -39,6 +39,7 @@ "vue-moment": "^4.0.0", "vue-router": "^3.0.2", "vue-scroll-reveal": "^1.0.11", + "vue-the-mask": "^0.11.1", "vue-tinymce-editor": "^1.6.2", "vuetify": "^2.0.19" }, diff --git a/public/mix-manifest.json b/public/mix-manifest.json index d6bed5d..00f5488 100644 --- a/public/mix-manifest.json +++ b/public/mix-manifest.json @@ -1,6 +1,6 @@ { - "/js/vue/Authentication/app.js": "/js/vue/Authentication/app.js?id=0da35ad1057d82e83419", - "/js/vue/Home/app.js": "/js/vue/Home/app.js?id=28ad11b47b82000bb110", - "/js/vue/Modules/CRM/app.js": "/js/vue/Modules/CRM/app.js?id=7fa03d7410899cabc276", - "/js/vue/User/app.js": "/js/vue/User/app.js?id=8d80fa57638e29bc7263" + "/js/vue/Authentication/app.js": "/js/vue/Authentication/app.js?id=60b0a33dbb353c1d7edc", + "/js/vue/Home/app.js": "/js/vue/Home/app.js?id=9f533af650a307e880c0", + "/js/vue/Modules/CRM/app.js": "/js/vue/Modules/CRM/app.js?id=92214a4c3239559ded55", + "/js/vue/User/app.js": "/js/vue/User/app.js?id=f3c9f37079c432adb37c" } diff --git a/resources/js/Global/mixins/commingSoon.js b/resources/js/Global/mixins/commingSoon.js index a57d6d0..43097ce 100644 --- a/resources/js/Global/mixins/commingSoon.js +++ b/resources/js/Global/mixins/commingSoon.js @@ -7,9 +7,9 @@ var CommingSoonArray = [ "crm-setting", - "crm-client-filter", + // "crm-client-filter", "crm-statistics", - "user-list-filter", + // "user-list-filter", ]; const commingSoon = { methods: { diff --git a/resources/js/Global/plugins/auth.js b/resources/js/Global/plugins/auth.js index 37f8b0d..f740619 100644 --- a/resources/js/Global/plugins/auth.js +++ b/resources/js/Global/plugins/auth.js @@ -9,7 +9,7 @@ if (TokenService.getToken()) { if (PermissionService.get()) { store.commit('auth/SET_AUTH_PERMISSIONS', PermissionService.get()) -} else if (TokenService.getToken()){ +} else if (TokenService.getToken() && UserService.get() && UserService.get().is_owner == false) { store.dispatch('auth/loadAuthPermissions'); } diff --git a/resources/js/Global/services/storage.services.js b/resources/js/Global/services/storage.services.js index ffd195e..124ae90 100644 --- a/resources/js/Global/services/storage.services.js +++ b/resources/js/Global/services/storage.services.js @@ -68,7 +68,7 @@ const VirtualActivityService = { }, save(virtualActivity = null) { - virtualActivity = qs.stringify(virtualActivity); + virtualActivity = qs.stringify(virtualActivity); localStorage.setItem(VIRTUALACTIVITY, virtualActivity) }, diff --git a/resources/js/Global/utils/common/CreateFilterObject.js b/resources/js/Global/utils/common/CreateFilterObject.js new file mode 100644 index 0000000..27a3133 --- /dev/null +++ b/resources/js/Global/utils/common/CreateFilterObject.js @@ -0,0 +1,31 @@ +const createFilterObject = filters => { + let filterObject = {}; + for (const key in filters) { + if (filters.hasOwnProperty(key)) { + if (filters[key]["type"]) { + let filterValue = window[filters[key]["type"]](filters[key]); + if (filterValue) { + filterObject[key] = filterValue; + } + } + } + } + return filterObject; +}; +window['between'] = function (filter) { + var value = null; + if (filter.val1 || filter.val2) { + value = `<${filter.val1},${filter.val2}>`; + } + return value; +} + +window['like'] = function(filter) { + var value = null; + if (filter.val) { + value = `%${filter.val}%`; + } + return value; +} + +export default createFilterObject; diff --git a/resources/js/Global/utils/vee-validate/locale/fa.js b/resources/js/Global/utils/vee-validate/locale/fa.js index 41ae668..0116fe9 100644 --- a/resources/js/Global/utils/vee-validate/locale/fa.js +++ b/resources/js/Global/utils/vee-validate/locale/fa.js @@ -130,8 +130,21 @@ attributes: { name_en: "نام انگلیسی", email: "ایمیل", + website: "آدرس سایت", name: "نام", + text: "متن", + client_type: "نوع مشتری", + cell_number: " شماره همراه ", + password: " کلمه عبور ", + confirm_password: " تکرار کلمه عبور ", + department: "دپارتمان", phone: "شماره ی تلفن", + task_receiver_user : "مسئول وظیفه", + begin_date : " تاریخ شروع ", + end_date : " تاریخ پایان ", + title : " عنوان ", + description : " توضیحات ", + national_code : " کد ملی ", duplicatephone0: "شماره ی تلفن", duplicatephone1: "شماره ی تلفن", duplicatephone2: "شماره ی تلفن",