Merge branch 'master' of http://139.186.142.91:10010/r/productDev/dmMes
已添加63个文件
已删除6个文件
已修改45个文件
| | |
| | | @load="onLoad"> |
| | | <div class="content_list"> |
| | | <div class="content_list_item" v-for="(item, i) in list" :key="i" @click="jump(item)"> |
| | | <div class="content_list_item_name">{{item.name}}</div> |
| | | <div class="content_list_item_name"> |
| | | <span style="color: #03AF76;" v-if="item.tmodel.label == 'APPLIANCE_ONTEST'">[{{ item.tmodel.code }}]</span> |
| | | <span style="color: #305ED5;" v-if="item.tmodel.label == 'APPLIANCE_MIX'">[{{ item.tmodel.code }}]</span> |
| | | <span style="color: #F5A400;" v-if="item.tmodel.label == 'APPLIANCE_OFFTEST'">[{{ item.tmodel.code }}]</span> |
| | | <span style="color: red;" v-if="item.tmodel.label == 'APPLIANCE_USELESS'">[{{ item.tmodel.code }}]</span> |
| | | <span>{{item.name}}</span> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </van-list> |
| | |
| | | margin-right: 10px; |
| | | } |
| | | .content_list_item_name { |
| | | font-size: 28px; |
| | | width: 100%; |
| | | display: flex; |
| | | align-items: center; |
| | | span { |
| | | font-size: 30px; |
| | | font-family: PingFangSC-Regular, PingFang SC; |
| | | font-weight: 400; |
| | | color: #222222; |
| | | } |
| | | } |
| | | } |
| | | } |
| | |
| | | let list = ref([ |
| | | { name: 'åæ ¼', id: '0' }, |
| | | { name: 'ä¸è¯', id: '1' }, |
| | | { name: 'æ¥åº', id: '2' }, |
| | | { name: 'æ··å', id: '3' } |
| | | { name: 'æ¥åº', id: '2' } |
| | | ]) |
| | | |
| | | // è¿åä¸ä¸é¡µå¸¦åæ° |
| | |
| | | // uuid: '0000', |
| | | // code: '0000' |
| | | // }) |
| | | // let res = await testLogin({ // 大æ |
| | | // username: '18019924213', |
| | | // password: '123456', |
| | | // companyId: '1', |
| | | // uuid: '0000', |
| | | // code: '0000' |
| | | // }) |
| | | let res = await testLogin({ // ææ¦ |
| | | username: '18656077929', |
| | | let res = await testLogin({ // 大æ |
| | | username: '18019924213', |
| | | password: '123456', |
| | | companyId: '8', |
| | | uuid: '0000', |
| | | code: '0000' |
| | | }) |
| | | // let res = await testLogin({ // ææ¦ |
| | | // username: '18656077929', |
| | | // password: '123456', |
| | | // companyId: '111', |
| | | // uuid: '0000', |
| | | // code: '0000' |
| | | // }) |
| | | // let res = await testLogin({ // è¡å
ä¸ |
| | | // username: '17751132561', |
| | | // password: '123456', |
| | |
| | | { |
| | | batch: '', |
| | | locationId: '', |
| | | locationIdLabel: '', |
| | | locationName: '', |
| | | materialId: '', |
| | | materialName: '', |
| | |
| | | } |
| | | // æå¼éæ©ç©æ |
| | | const openQ = (index: number) => { |
| | | if (list.value[index].locationIdLabel == 'APPLIANCE_ONTEST' || list.value[index].locationIdLabel == 'APPLIANCE_OFFTEST' || list.value[index].locationIdLabel == 'APPLIANCE_USELESS') { |
| | | return |
| | | } |
| | | i.value = index |
| | | qualityShow.value = true |
| | | } |
| | |
| | | locationShow.value = true |
| | | } |
| | | const addItem = () => { |
| | | // if (!form.warehouseId) return Toast('è¯·éæ©å
¥åºä»åº') |
| | | if (!form.warehouseId) return Toast('è¯·éæ©å
¥åºä»åº') |
| | | list.value.push({ |
| | | batch: '', |
| | | locationId: '', |
| | | locationName: '', |
| | | locationIdLabel: list.value[list.value.length - 1].locationIdLabel, |
| | | materialId: '', |
| | | materialName: '', |
| | | num: '', |
| | | procedureId: '', |
| | | procedureName: '', |
| | | qualityType: '', |
| | | qualityTypeName: '', |
| | | qualityType: list.value[list.value.length - 1].qualityType, |
| | | qualityTypeName: list.value[list.value.length - 1].qualityTypeName, |
| | | unitId: '', |
| | | unitName: '' |
| | | }) |
| | |
| | | item.locationId = res.data[0].id |
| | | item.locationName = res.data[0].unionName |
| | | }) |
| | | list.value[i.value].locationIdLabel = res.data[0].label |
| | | if (res.data[0].label === 'APPLIANCE_ONTEST') { |
| | | list.value[i.value].qualityType = '0' |
| | | list.value[i.value].qualityTypeName = 'åæ ¼' |
| | | } else if (res.data[0].label === 'APPLIANCE_OFFTEST') { |
| | | list.value[i.value].qualityType = '1' |
| | | list.value[i.value].qualityTypeName = 'ä¸è¯' |
| | | } else if (res.data[0].label === 'APPLIANCE_USELESS') { |
| | | list.value[i.value].qualityType = '2' |
| | | list.value[i.value].qualityTypeName = 'æ¥åº' |
| | | } |
| | | } else { |
| | | location.value = true |
| | | list.value.forEach(item => { |
| | |
| | | const getValue3 = (item: any): void => { |
| | | list.value[i.value].locationId = item.id |
| | | list.value[i.value].locationName = item.unionName |
| | | list.value[i.value].qualityType = '' |
| | | list.value[i.value].qualityTypeName = '' |
| | | list.value[i.value].locationIdLabel = item.label |
| | | if (item.label === 'APPLIANCE_ONTEST') { |
| | | list.value[i.value].qualityType = '0' |
| | | list.value[i.value].qualityTypeName = 'åæ ¼' |
| | | } else if (item.label === 'APPLIANCE_OFFTEST') { |
| | | list.value[i.value].qualityType = '1' |
| | | list.value[i.value].qualityTypeName = 'ä¸è¯' |
| | | } else if (item.label === 'APPLIANCE_USELESS') { |
| | | list.value[i.value].qualityType = '2' |
| | | list.value[i.value].qualityTypeName = 'æ¥åº' |
| | | } |
| | | locationShow.value = false |
| | | } |
| | | // éæ©å·¥åº |
| | |
| | | <span>åºåºè´§ä½ï¼{{ item.locationName }}</span> |
| | | <div class="rework_qd_item_hw_right"> |
| | | <span>æ°éï¼</span> |
| | | <input type="number" v-model="item.num" placeholder="0" /> |
| | | <input type="number" v-model="item.num" @input="changeNum(item)" placeholder="0" /> |
| | | <span>{{ item.unitName }}</span> |
| | | </div> |
| | | </div> |
| | |
| | | const onCancel = () => { |
| | | typeShow.value = false |
| | | } |
| | | |
| | | const changeNum = (obj: any) => { |
| | | if (obj.num < 0) { |
| | | obj.num = '' |
| | | return Toast('åºåºç©ææ°éå¿
须大äº0') |
| | | } |
| | | if (obj.num > obj.total) { |
| | | obj.num = '' |
| | | return Toast('åºåºç©ææ°éä¸è½å¤§äºåºåæ°') |
| | | } |
| | | } |
| | | // è·åå½å¤©å¹´ææ¥ |
| | | const getDay = () => { |
| | | var date = new Date(); |
| | |
| | | if (!form.warehouseId) return Toast('è¯·éæ©åºåºä»åº') |
| | | if (list.value.length === 0) return Toast('è³å°éæ©ä¸æ¡åºåºç©æ') |
| | | for (let i = 0; i < list.value.length; i++) { |
| | | if (!list.value[i].num || list.value[i].num == '' || list.value[i].num == 0) { |
| | | if (!list.value[i].num || list.value[i].num == '' || list.value[i].num <= 0) { |
| | | return Toast(`第${i + 1}个åºåºç©ææ°éå¿
须大äº0`) |
| | | } |
| | | if (list.value[i].num > list.value[i].total) { |
| | |
| | | color: #333333; |
| | | background: #FFFFFF; |
| | | border-radius: 8px; |
| | | border: 1px solid #CCCCCC; |
| | | border: 1PX solid #CCCCCC; |
| | | margin: 0 20px; |
| | | padding: 0 30px; |
| | | box-sizing: border-box; |
| | |
| | | <template> |
| | | <div class="content"> |
| | | <div :class="{ 'content_top': status }" class="content_search"> |
| | | <v-Search @searchInput="searchInput" @submit="submit" :isShow="false" placeholder="æç´¢ç©æåç§°/ç¼ç /å·¥åºåç§°"> |
| | | </v-Search> |
| | | </div> |
| | | <van-pull-refresh v-model="refreshing" @refresh="onRefresh"> |
| | | <van-list |
| | | v-model:loading="loading" |
| | |
| | | </template> |
| | | |
| | | <script setup lang="ts"> |
| | | import { reactive, ref, onBeforeUnmount, getCurrentInstance } from "vue" |
| | | import { reactive, ref, onBeforeUnmount, getCurrentInstance, onMounted } from "vue" |
| | | import { useRouter, useRoute } from "vue-router" |
| | | import { getList } from "@/apis/PlanningAPI" |
| | | import { judgmentPlatform } from '@/utils/utils' |
| | | |
| | | const route = useRoute() |
| | | const router = useRouter() |
| | | |
| | | let status = ref<boolean>(false) // æ ¹æ®å¹³å°æ¯å¦éè¦è®¾ç½®top |
| | | |
| | | const { $Bus } = getCurrentInstance().appContext.config.globalProperties |
| | | |
| | |
| | | const pageData = reactive({ |
| | | capacity: 10, |
| | | page: 0, |
| | | total: 0 |
| | | total: 0, |
| | | name: '' |
| | | }) |
| | | |
| | | // åè¡¨æ°æ® |
| | |
| | | const clickItem = (obj: any) => { |
| | | $Bus.emit('callback', obj) |
| | | router.go(-1) |
| | | } |
| | | |
| | | // æç´¢æäº¤ |
| | | const submit = (): void => { |
| | | pageData.page = 0 |
| | | finished.value = false |
| | | listData.value = [] |
| | | onLoad() |
| | | } |
| | | |
| | | // æç´¢æ¡ |
| | | const searchInput = (data: any) => { |
| | | pageData.name = data |
| | | pageData.page = 0 |
| | | finished.value = false |
| | | listData.value = [] |
| | | onLoad() |
| | | } |
| | | |
| | | // å表 |
| | |
| | | onBeforeUnmount(() => { |
| | | $Bus.all.delete("changeOdr") |
| | | }) |
| | | |
| | | onMounted(() => { |
| | | status.value = judgmentPlatform() |
| | | }) |
| | | </script> |
| | | |
| | | <style lang="scss" scoped> |
| | |
| | | // height: 100%; |
| | | position: absolute; |
| | | background: #F7F7F7; |
| | | .content_top { |
| | | top: 0 !important; |
| | | } |
| | | .content_search { |
| | | padding: 30px; |
| | | background: white; |
| | | box-sizing: border-box; |
| | | position: sticky; |
| | | top: 88px; |
| | | z-index: 9; |
| | | .Search_item { |
| | | margin-bottom: 40px; |
| | | .Search_item_label { |
| | | font-size: 30px; |
| | | font-weight: 500; |
| | | color: #222222; |
| | | } |
| | | .Search_item_content { |
| | | display: flex; |
| | | align-items: center; |
| | | justify-content: space-between; |
| | | margin-top: 30px; |
| | | .tag { |
| | | display: flex; |
| | | flex-wrap: wrap; |
| | | align-items: center; |
| | | .tag_active { |
| | | background: $nav-color !important; |
| | | color: #ffffff !important; |
| | | } |
| | | .tag_item { |
| | | width: 156px; |
| | | height: 70px; |
| | | box-sizing: border-box; |
| | | background: #F2F2F2; |
| | | border-radius: 8px; |
| | | font-size: 26px; |
| | | font-weight: 400; |
| | | color: #333333; |
| | | display: flex; |
| | | align-items: center; |
| | | justify-content: center; |
| | | margin-right: 22px; |
| | | margin-bottom: 22px; |
| | | &:nth-child(4n) { |
| | | margin-right: 0; |
| | | } |
| | | } |
| | | } |
| | | span { |
| | | font-size: 26px; |
| | | font-weight: 400; |
| | | color: #333333; |
| | | } |
| | | .Search_item_content_a { |
| | | width: 308px; |
| | | height: 70px; |
| | | background: #F7F7F7; |
| | | border-radius: 8px; |
| | | border: 1px solid #EEEEEE; |
| | | font-size: 26px; |
| | | font-weight: 400; |
| | | color: #B2B2B2; |
| | | display: flex; |
| | | align-items: center; |
| | | justify-content: center; |
| | | } |
| | | } |
| | | } |
| | | .content_search_x { |
| | | height: 24px; |
| | | } |
| | | } |
| | | .content_list { |
| | | width: 100%; |
| | | height: 100%; |
| | |
| | | <span>æ°å¢ææ</span> |
| | | </div> |
| | | </div> |
| | | <template v-if="wuList.length > 0"> |
| | | <template v-if="wuList.length > 0 && !(hasBom == 1 && bomType == 1)"> |
| | | <van-swipe-cell v-for="(item, index) in wuList" :key="index"> |
| | | <div class="bg_list_item_h"> |
| | | <div class="bg_list_item_num"> |
| | |
| | | </template> |
| | | </van-swipe-cell> |
| | | </template> |
| | | <template v-else> |
| | | <template v-else-if="wuList.length == 0 && !(hasBom == 1 && bomType == 1)"> |
| | | <div class="kong"> |
| | | <span>ææ æ°æ®</span> |
| | | </div> |
| | |
| | | <span><b>*</b>è¯åæ°</span> |
| | | <div class="bg_list_item_num_item_sr"> |
| | | <input type="number" v-model="from.qualified" @input="changeNum(1)" placeholder="请è¾å
¥" /> |
| | | <span>å</span> |
| | | <span v-if="from.processPlan">{{from.processPlan.unitName}}</span> |
| | | </div> |
| | | </div> |
| | | </div> |
| | |
| | | <span>ä¸è¯æ°</span> |
| | | <div class="bg_list_item_num_item_sr"> |
| | | <input type="number" v-model="from.undesirable" @input="changeNum(2)" placeholder="请è¾å
¥" /> |
| | | <span>å</span> |
| | | <span v-if="from.processPlan">{{from.processPlan.unitName}}</span> |
| | | </div> |
| | | </div> |
| | | </div> |
| | |
| | | <div class="bg_list_item_num_item"> |
| | | <span>å·¥èµåä»·</span> |
| | | <div class="bg_list_item_num_item_sr"> |
| | | <span class="color1">{{infoBox.salary}}å
/{{infoBox.type == 0 ? 'ä»¶' : 'æ¶'}}</span> |
| | | <span class="color1">{{(infoBox.salary / 10 / 10).toFixed(2)}}å
/{{infoBox.type == 0 ? 'ä»¶' : 'æ¶'}}</span> |
| | | </div> |
| | | </div> |
| | | </div> |
| | |
| | | <div class="bg_footer_submit" @click="submit">æäº¤</div> |
| | | </div> |
| | | <!-- éæ©ä¸è¯é¡¹ --> |
| | | <van-popup v-model:show="show" round position="bottom" :style="{ height: '53%' }"> |
| | | <van-popup v-model:show="show" round position="bottom"> |
| | | <div class="bl"> |
| | | <div class="bl_head"> |
| | | <img src="@/assets/icon/ic_close@2x.png" style="opacity: 0;" alt="" /> |
| | |
| | | text: 'name' |
| | | }; |
| | | let userShow = ref(false) |
| | | let userList = ref([]) |
| | | let wuList: any = ref([]) |
| | | let wuList = ref<Array<any>>([]) |
| | | |
| | | // äº§åºæ°ééªè¯ |
| | | const changeNum = (type: number) => { |
| | |
| | | } else { |
| | | if (!wuList.value.length === 0) return Toast('ææä¸è½ä¸ºç©º') |
| | | } |
| | | if (!from.qualified) return Toast('è¯åæ°ä¸è½ä¸ºç©º') |
| | | if (!from.qualified && !from.undesirable) { |
| | | return Toast('è¯åæ°ä¸ä¸è¯æ°ä¸è½åæ¶ä¸ºç©º') |
| | | } |
| | | // if (!from.qualified) return Toast('è¯åæ°ä¸è½ä¸ºç©º') |
| | | // æä¸è¯æ° |
| | | if (from.undesirable > 0) { |
| | | if (from.defective.length === 0) return Toast('ä¸è¯é¡¹ä¸è½ä¸ºç©º') |
| | |
| | | autoWorkReport({ |
| | | createWorkorderRecordDTO: { |
| | | duration: from.duration, |
| | | qualifiedNum: from.qualified, |
| | | unQualifiedNum: from.undesirable |
| | | qualifiedNum: from.qualified ? from.qualified : 0, |
| | | unQualifiedNum: from.undesirable ? from.undesirable : 0 |
| | | }, |
| | | plansId: from.processPlan.id, |
| | | proGroupId: deviceId.value, |
| | |
| | | |
| | | // é¢è®¡å·¥èµ |
| | | const expectedSalary = computed(() => { |
| | | if (!infoBox.value) return 0 |
| | | if (!infoBox.value) return 0; |
| | | // æä»¶è®¡ç® |
| | | if (infoBox.value.type == 0) { |
| | | console.log('计件') |
| | | if (!from.qualified) return 0 |
| | | if (infoBox.value.unqualified == 1) { // æ¯å¦è®¡å
¥ä¸è¯å |
| | | let total = Number(from.qualified) + Number(from.undesirable) |
| | | return total * infoBox.value.salary |
| | | return (total * (infoBox.value.salary / 10 / 10)).toFixed(2) || 0 |
| | | } else { |
| | | return Number(from.qualified) * infoBox.value.salary |
| | | return (Number(from.qualified) * (infoBox.value.salary / 10 / 10)).toFixed(2) || 0 |
| | | } |
| | | } else { |
| | | console.log('计æ¶') |
| | | if (!from.duration) return 0; |
| | | let h = (from.duration / 60 / 60).toFixed(2) |
| | | return Number(h) * infoBox.value.salary |
| | | return (Number(h) * (infoBox.value.salary / 10 / 10)).toFixed(2) || 0 |
| | | } |
| | | }) |
| | | |
| | | // è¾¾æ ç |
| | | const complianceRate = computed(() => { |
| | | if (!infoBox.value) return 0; |
| | | if (!from.qualified) return 0; |
| | | if (!from.qualified && !from.undesirable) return 0; |
| | | if (!from.duration) return 0; |
| | | // æä»¶è®¡ç® |
| | | // if (infoBox.value.type == 0) { |
| | | // if (infoBox.value.unqualified == 1) { // æ¯å¦è®¡å
¥ä¸è¯å |
| | | if (infoBox.value.unqualified == 1) { // æ¯å¦è®¡å
¥ä¸è¯å |
| | | let a = ((Number(from.qualified) + Number(from.undesirable)) / (from.duration / 60 / 60)).toFixed(2) |
| | | let b = (infoBox.value.num / (infoBox.value.times / 60 / 60)).toFixed(2) |
| | | console.log(a) |
| | | console.log(b) |
| | | return (Number(a) / Number(b)).toFixed(2) |
| | | return ((Number(a) / Number(b)) * 100).toFixed(2) || 0 |
| | | // let total = (Number(from.qualified) + Number(from.undesirable)) / ((from.duration * 60 * 60) * infoBox.value.num / ) |
| | | // return total * infoBox.value.salary; |
| | | // } else { |
| | | // return Number(from.qualified) * infoBox.value.salary; |
| | | // } |
| | | } else { |
| | | let a = (from.qualified / (from.duration / 60 / 60)).toFixed(2) |
| | | let b = (infoBox.value.num / (infoBox.value.times / 60 / 60)).toFixed(2) |
| | | console.log(a) |
| | | console.log(b) |
| | | return ((Number(a) / Number(b)) * 100).toFixed(2) || 0 |
| | | // return Number(from.qualified) * infoBox.value.salary; |
| | | } |
| | | // } else { |
| | | // console.log('ææ¶é¿') |
| | | // } |
| | |
| | | // è·åç±»å |
| | | getIdPlansExt(res.id) |
| | | .then(res2 => { |
| | | if (res.code === 200) { |
| | | if (res2.code === 200) { |
| | | bomType.value = res2.data.bomType |
| | | hasBom.value = res2.data.hasBom |
| | | } |
| | |
| | | font-size: 28px; |
| | | font-weight: 400; |
| | | color: #333333; |
| | | padding: 0 30px |
| | | padding: 0 30px; |
| | | } |
| | | .wulll { |
| | | width: 400px; |
| | |
| | | } |
| | | } |
| | | .bl { |
| | | width: 100%; |
| | | height: 800px; |
| | | padding: 30px; |
| | | box-sizing: border-box; |
| | | display: flex; |
| | | flex-direction: column; |
| | | .bl_head { |
| | | width: 100%; |
| | | height: 50px; |
| | | display: flex; |
| | | align-items: center; |
| | | justify-content: space-between; |
| | |
| | | } |
| | | .bl_list { |
| | | width: 100%; |
| | | height: 550px; |
| | | height: calc(100% - 168px); |
| | | overflow-y: scroll; |
| | | margin-top: 30px; |
| | | .bl_list_item { |
| | |
| | | </div> |
| | | <template v-if="feedingData && feedingData.length > 0"> |
| | | <van-swipe-cell v-for="(item, index) in feedingData" :key="index"> |
| | | <div class="bg_list_item_num"> |
| | | <div class="bg_list_item_num_item"> |
| | | <!-- <span>{{item.code}}</span> --> |
| | | <div class="bg_list_item_num_item_wl"> |
| | | <span> {{ item.materialName }}{{ item.procedureName ? ` | ${item.procedureName}` : '' }}</span> |
| | | <div class="bg_list_item_num_item_wl_lx"> |
| | | <span class="green" v-if="item.qualityType == 0">åæ ¼ / </span> |
| | | <span class="yellow" v-if="item.qualityType == 1">ä¸è¯ / </span> |
| | | <span class="red" v-if="item.qualityType == 2">æ¥åº / </span> |
| | | <span>{{ item.locationName }}</span> |
| | | <span>{{ item.batch ? ` / ${item.batch}` : '' }}</span> |
| | | <div class="bg_list_item_h"> |
| | | <div class="bg_list_item_num"> |
| | | <div class="bg_list_item_num_item"> |
| | | <!-- <span>{{item.code}}</span> --> |
| | | <div class="bg_list_item_num_item_wl"> |
| | | <span> {{ item.materialName }}{{ item.procedureName ? ` | ${item.procedureName}` : '' }}</span> |
| | | <div class="bg_list_item_num_item_wl_lx"> |
| | | <span class="green" v-if="item.qualityType == 0">åæ ¼ / </span> |
| | | <span class="yellow" v-if="item.qualityType == 1">ä¸è¯ / </span> |
| | | <span class="red" v-if="item.qualityType == 2">æ¥åº / </span> |
| | | <span>{{ item.locationName }}</span> |
| | | <span>{{ item.batch ? ` / ${item.batch}` : '' }}</span> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <div class="bg_list_item_num_item_sr"> |
| | | <input v-model="item.num" :disabled="!proxy.$auth('h5:workorderinput:update')" @blur="change(item.id, item.num, 'T', item.maxNum, item, item.unitAttribute)" type="number" /> |
| | | <span>{{item.unitName}}</span> |
| | | <div class="bg_list_item_num_item_sr"> |
| | | <input v-model="item.num" :disabled="!proxy.$auth('h5:workorderinput:update')" @blur="change(item.id, item.num, 'T', item.maxNum, item, item.unitAttribute)" type="number" /> |
| | | <span>{{item.unitName}}</span> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | |
| | | <template #right v-if="proxy.$auth('h5:workorderinput:delete')"> |
| | | <van-button style="height: 100%;" square text="å é¤" @click="deleItem(item.id, 'T')" type="danger" /> |
| | | </template> |
| | |
| | | <!-- <template v-if="produceData && produceData.length > 0"> --> |
| | | <!-- v-for="(item, index) in produceData" :key="index" --> |
| | | <van-swipe-cell> |
| | | <div class="bg_list_item_num"> |
| | | <div class="bg_list_item_num_item"> |
| | | <span>è¯åæ°</span> |
| | | <div class="bg_list_item_num_item_sr"> |
| | | <!-- :disabled="!proxy.$auth('h5:workorderoutput:update')" --> |
| | | <!-- @blur="change(item.id, item.num, 'C', item.maxNum, item)" --> |
| | | <input type="number" v-model="produceFrom.qualified" @blur="changeCC('0', produceFrom.qualified, produceFrom.qualifiedId)" placeholder="请è¾å
¥" /> |
| | | <span v-if="info.umodel">{{info.umodel.name}}</span> |
| | | <div class="bg_list_item_h"> |
| | | <div class="bg_list_item_num"> |
| | | <div class="bg_list_item_num_item"> |
| | | <span>è¯åæ°({{ info.umodel ? info.umodel.name : '' }})</span> |
| | | <div class="bg_list_item_num_item_sr"> |
| | | <!-- :disabled="!proxy.$auth('h5:workorderoutput:update')" --> |
| | | <!-- @blur="change(item.id, item.num, 'C', item.maxNum, item)" --> |
| | | <input type="number" v-model="produceFrom.qualified" @blur="changeCC('0', produceFrom.qualified, produceFrom.qualifiedId)" placeholder="请è¾å
¥" /> |
| | | <span v-if="info.umodel">{{info.umodel.name}}</span> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </van-swipe-cell> |
| | | <van-swipe-cell> |
| | | <div class="bg_list_item_num"> |
| | | <!-- @blur="change(item.id, item.num, 'C', item.maxNum, item)" --> |
| | | <div class="bg_list_item_num_item"> |
| | | <span>ä¸è¯æ°</span> |
| | | <div class="bg_list_item_num_item_sr"> |
| | | <!-- :disabled="!proxy.$auth('h5:workorderoutput:update')" --> |
| | | <!-- @blur="change(item.id, item.num, 'C', item.maxNum, item)" --> |
| | | <input type="number" v-model="produceFrom.undesirable" @blur="changeCC('1', produceFrom.undesirable, produceFrom.undesirableId)" placeholder="请è¾å
¥" /> |
| | | <span v-if="info.umodel">{{info.umodel.name}}</span> |
| | | <div class="bg_list_item_h"> |
| | | <div class="bg_list_item_num"> |
| | | <!-- @blur="change(item.id, item.num, 'C', item.maxNum, item)" --> |
| | | <div class="bg_list_item_num_item"> |
| | | <span>ä¸è¯æ°({{ info.umodel ? info.umodel.name : '' }})</span> |
| | | <div class="bg_list_item_num_item_sr"> |
| | | <!-- :disabled="!proxy.$auth('h5:workorderoutput:update')" --> |
| | | <!-- @blur="change(item.id, item.num, 'C', item.maxNum, item)" --> |
| | | <input type="number" v-model="produceFrom.undesirable" @blur="changeCC('1', produceFrom.undesirable, produceFrom.undesirableId)" placeholder="请è¾å
¥" /> |
| | | <span v-if="info.umodel">{{info.umodel.name}}</span> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </van-swipe-cell> |
| | | <!-- <van-swipe-cell> |
| | | <div class="bg_list_item_num"> |
| | | <div class="bg_list_item_num_item" @click="show = true"> |
| | | <span>ä¸è¯é¡¹</span> |
| | | <div class="bg_list_item_num_item_sr"> |
| | | <span>设置 ></span> |
| | | <van-swipe-cell v-if="produceFrom.undesirable > 0"> |
| | | <div class="bg_list_item_h"> |
| | | <div class="bg_list_item_num"> |
| | | <div class="bg_list_item_num_item" @click="show = true"> |
| | | <span>ä¸è¯é¡¹</span> |
| | | <div class="bg_list_item_num_item_sr"> |
| | | <span class="wulll" :style="{color: from.defectiveName ? '#305ED5' : ''}">{{from.defectiveName ? from.defectiveName : '设置'}}</span> |
| | | <img src="@/assets/icon/ic_ar@2x.png" alt="" /> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </van-swipe-cell> --> |
| | | </van-swipe-cell> |
| | | <!-- </template> |
| | | <template v-else> |
| | | <div class="kong"> |
| | | <span>ææ æ°æ®</span> |
| | | </div> |
| | | </template> --> |
| | | </div> |
| | | <div class="bg_plan" @click="TimeShow = true"> |
| | | <div class="bg_plan_label"> |
| | | <span><b>*</b>æ¥å·¥æ¶é¿</span> |
| | | </div> |
| | | <div class="bg_plan_label_val"> |
| | | <span :style="{color: from.durationName ? '#333' : ''}">{{from.durationName ? from.durationName : 'è¯·éæ©'}}</span> |
| | | <img src="@/assets/icon/ic_ar@2x.png" alt="" /> |
| | | </div> |
| | | </div> |
| | | <div class="bg_list_item" v-if="infoBox"> |
| | | <div class="bg_list_item_top"> |
| | | <div class="bg_list_item_top_left"> |
| | | <div class="bg_list_item_top_left_x"></div> |
| | | <span>å·¥èµç»©æ</span> |
| | | </div> |
| | | </div> |
| | | <div class="bg_list_item_h"> |
| | | <div class="bg_list_item_num"> |
| | | <div class="bg_list_item_num_item"> |
| | | <span>计件æ¹å¼</span> |
| | | <div class="bg_list_item_num_item_list"> |
| | | <div class="bg_list_item_num_item_list_item active" v-if="infoBox.type == 0">计件</div> |
| | | <div class="bg_list_item_num_item_list_item active" v-if="infoBox.type == 1">计æ¶</div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <div class="bg_list_item_num"> |
| | | <div class="bg_list_item_num_item"> |
| | | <span>å·¥èµåä»·</span> |
| | | <div class="bg_list_item_num_item_sr"> |
| | | <span class="color1">{{infoBox.salary / 100}}å
/{{infoBox.type == 0 ? 'ä»¶' : 'æ¶'}}</span> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <div class="bg_list_item_num"> |
| | | <div class="bg_list_item_num_item"> |
| | | <span>é¢è®¡å·¥èµ</span> |
| | | <div class="bg_list_item_num_item_sr"> |
| | | <span class="color1">{{expectedSalary}}å
</span> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <div class="bg_list_item_num"> |
| | | <div class="bg_list_item_num_item"> |
| | | <span>è¾¾æ ç</span> |
| | | <div class="bg_list_item_num_item_sr"> |
| | | <span class="color1">{{complianceRate}}%</span> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <!-- <div class="bg_list_item"> |
| | | <div class="bg_list_item_top"> |
| | |
| | | </div> |
| | | </div> |
| | | </van-popup> |
| | | <!-- æ¶é´ --> |
| | | <van-popup v-model:show="TimeShow" round position="bottom" :style="{ height: '50%' }"> |
| | | <van-datetime-picker |
| | | v-model="from.time" |
| | | type="time" |
| | | title="éæ©æ¶é´" |
| | | @confirm="onConfirm2" |
| | | @cancel="onCancel2" |
| | | /> |
| | | </van-popup> |
| | | <!-- éæ©ä¸è¯é¡¹ --> |
| | | <van-popup v-model:show="show" round position="bottom" :style="{ height: '53%' }"> |
| | | <van-popup v-model:show="show" round position="bottom"> |
| | | <div class="bl"> |
| | | <div class="bl_head"> |
| | | <span @click="show = false">åæ¶</span> |
| | | <img src="@/assets/icon/ic_close@2x.png" style="opacity: 0;" alt="" /> |
| | | <span>ä¸è¯é¡¹</span> |
| | | <span>确认</span> |
| | | <!-- <span>确认</span> --> |
| | | <img src="@/assets/icon/ic_close@2x.png" @click="show = false" alt="" /> |
| | | </div> |
| | | <div class="bl_list"> |
| | | <div class="bl_list_item" v-for="(item, i) in 12" :key="i"> |
| | | <div class="bl_list_item" v-for="(item, i) in cateList" :key="i" @click="changeChecked(i)"> |
| | | <div class="bl_list_item_left"> |
| | | <input type="checkbox" :checked="true" name="" id="" /> |
| | | <span>æåç</span> |
| | | <input type="checkbox" :checked="item.active" /> |
| | | <span>{{ item.name }}</span> |
| | | </div> |
| | | <div class="bl_list_item_right"> |
| | | <input type="number" placeholder="请è¾å
¥" /> |
| | | <input type="number" @click.stop v-model="item.num" placeholder="0" /> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <div class="bl_footer" @click="onConfirm3">确认</div> |
| | | </div> |
| | | </van-popup> |
| | | </div> |
| | | </template> |
| | | |
| | | <script setup lang="ts"> |
| | | import { getCurrentInstance, nextTick, onMounted, ref, reactive } from 'vue' |
| | | import { getCurrentInstance, nextTick, onMounted, ref, reactive, computed } from 'vue' |
| | | import { useRouter, useRoute } from "vue-router" |
| | | import { Dialog, Toast } from 'vant' |
| | | import { REGULAR } from '@/utils/utils' |
| | | import { categoryExtList, queryOne } from '@/apis/PlanningAPI' |
| | | import { |
| | | getBarcodeContent, |
| | | queryById, |
| | |
| | | const router = useRouter() |
| | | const route = useRoute() |
| | | |
| | | let TimeShow = ref(false) |
| | | |
| | | let from: any = reactive({ |
| | | time: '', |
| | | defective: [], |
| | | defectiveName: '' |
| | | }) |
| | | |
| | | // é¢è®¡å·¥èµ |
| | | const expectedSalary = computed(() => { |
| | | if (!infoBox.value) return 0; |
| | | // æä»¶è®¡ç® |
| | | if (infoBox.value.type == 0) { |
| | | if (!produceFrom.qualified) return 0 |
| | | if (infoBox.value.unqualified == 1) { // æ¯å¦è®¡å
¥ä¸è¯å |
| | | let total = Number(produceFrom.qualified) + Number(produceFrom.undesirable) |
| | | return (total * (infoBox.value.salary / 100)).toFixed(2) || 0 |
| | | } else { |
| | | return (Number(produceFrom.qualified) * (infoBox.value.salary / 100)).toFixed(2) || 0 |
| | | } |
| | | } else { |
| | | if (!from.duration) return 0; |
| | | let h = (from.duration / 60 / 60).toFixed(2) |
| | | return (Number(h) * (infoBox.value.salary / 10 / 10)).toFixed(2) || 0 |
| | | } |
| | | }) |
| | | |
| | | // è¾¾æ ç |
| | | const complianceRate = computed(() => { |
| | | if (!infoBox.value) return 0; |
| | | if (!produceFrom.qualified && !produceFrom.undesirable) return 0; |
| | | if (!from.duration) return 0; |
| | | // æä»¶è®¡ç® |
| | | // if (infoBox.value.type == 0) { |
| | | if (infoBox.value.unqualified == 1) { // æ¯å¦è®¡å
¥ä¸è¯å |
| | | let a = ((Number(from.qualified) + Number(from.undesirable)) / (from.duration / 60 / 60)).toFixed(2) |
| | | let b = (infoBox.value.num / (infoBox.value.times / 60 / 60)).toFixed(2) |
| | | console.log(a) |
| | | console.log(b) |
| | | return (Number(a) / Number(b)).toFixed(2) || 0 |
| | | // let total = (Number(from.qualified) + Number(from.undesirable)) / ((from.duration * 60 * 60) * infoBox.value.num / ) |
| | | // return total * infoBox.value.salary; |
| | | } else { |
| | | let a = (produceFrom.qualified / (from.duration / 60 / 60)).toFixed(2) |
| | | let b = (infoBox.value.num / (infoBox.value.times / 60 / 60)).toFixed(2) |
| | | console.log(a) |
| | | console.log(b) |
| | | return (Number(a) / Number(b)).toFixed(2) || 0 |
| | | // return Number(from.qualified) * infoBox.value.salary; |
| | | } |
| | | // } else { |
| | | // console.log('ææ¶é¿') |
| | | // } |
| | | }) |
| | | |
| | | const loading = ref(false); |
| | | const finished = ref(false); |
| | | let show = ref(false) |
| | |
| | | page: 0 |
| | | }) |
| | | |
| | | let infoBox: any = ref(null) // å·¥èµç»©æ |
| | | |
| | | // 产åºåæ ¼/ä¸è¯ |
| | | let produceFrom = reactive({ |
| | | let produceFrom: any = reactive({ |
| | | qualifiedId: '', |
| | | qualified: '', // åæ ¼ |
| | | undesirableId: '', |
| | | undesirable: '' // ä¸è¯ |
| | | }) |
| | | |
| | | let cateList:any = ref([]) // ä¸è¯é¡¹ |
| | | |
| | | // 详æ
æ°æ® |
| | | const info: any = ref({}) |
| | |
| | | // æ§å¶æ¥å·¥ç»è®¡ |
| | | const statistics = ref<boolean>(false) |
| | | |
| | | const changeChecked = (i: number) => { |
| | | cateList.value[i].active = !cateList.value[i].active |
| | | } |
| | | |
| | | const getData = () => { |
| | | categoryExtList({ |
| | | cateType: "3" |
| | | }).then(res => { |
| | | if (res.code === 200) { |
| | | res.data.forEach((item: any) => { |
| | | item.active = false |
| | | item.num = '' |
| | | }) |
| | | cateList.value = res.data |
| | | } |
| | | }) |
| | | } |
| | | |
| | | const onConfirm2 = (e: string) => { |
| | | let h = Number(e.substring(0, 2)) |
| | | let m = Number(e.substring(3, 5)) |
| | | let s = 0 |
| | | if (h > 0) { |
| | | s += h * 60 * 60 |
| | | } |
| | | if (m > 0) { |
| | | s += m * 60 |
| | | } |
| | | from.duration = s |
| | | from.durationName = `${h}å°æ¶${m}åé` |
| | | TimeShow.value = false |
| | | } |
| | | |
| | | const onCancel2 = () => { |
| | | TimeShow.value = false |
| | | } |
| | | |
| | | const onConfirm3 = () => { |
| | | let isOpen = false |
| | | cateList.value.forEach((item: any, index: number) => { |
| | | if (item.active) { |
| | | isOpen = true |
| | | } |
| | | }) |
| | | if (!isOpen) return Toast('è¯·éæ©ä¸è¯é¡¹') |
| | | let arr: any = [] |
| | | let total: any = 0 |
| | | let name: any = '' |
| | | cateList.value.forEach((item: any, index: number) => { |
| | | if (item.active) { |
| | | if (item.num <= 0) { |
| | | return Toast('ä¸è¯æ°éå¿
须大äº0') |
| | | } |
| | | total = total += item.num |
| | | arr.push(item) |
| | | name += item.name + item.num + 'ï¼' |
| | | } |
| | | }) |
| | | if (total !== produceFrom.undesirable) return Toast('ä¸è¯æ°å¿
é¡»çäºäº§åºä¸è¯æ°') |
| | | from.defective = arr |
| | | from.defectiveName = name |
| | | show.value = false |
| | | } |
| | | |
| | | // ææç»è®¡ |
| | | const tlTotal = (): string => { |
| | | if (feedingData.value.length > 0) { |
| | |
| | | // ä¿®æ¹äº§åº |
| | | const changeCC = (downType: string, num: number, recordId: string) => { |
| | | if (!num) return |
| | | console.log(produceFrom.qualified + produceFrom.undesirable) |
| | | if ((produceFrom.qualified + produceFrom.undesirable) > info.value.planNum) { |
| | | return Toast.fail({ message: 'äº§åºæ°éä¸è½å¤§äºè®¡åæ°é', duration: 2000 }) |
| | | } |
| | | if (num >= 0) { |
| | | dealWorkorderRecordStandard({ |
| | | downType, num, recordId, workorderId: route.query.id |
| | | }).then(res => { |
| | | if (res.code === 200) { |
| | | getOrocessRecordCC() |
| | | } |
| | | }) |
| | | from.defective = [] |
| | | from.defectiveName = '' |
| | | // dealWorkorderRecordStandard({ |
| | | // downType, num, recordId, workorderId: route.query.id |
| | | // }).then(res => { |
| | | // if (res.code === 200) { |
| | | // getOrocessRecordCC() |
| | | // } |
| | | // }) |
| | | } else { |
| | | if (downType == 0) { |
| | | produceFrom.qualified = 0 |
| | |
| | | queryById(route.query.id).then(res => { |
| | | if (res.code === 200) { |
| | | info.value = res.data |
| | | // è·åå·¥èµç»©ææ°æ® |
| | | queryOne({ |
| | | deleted: 0, |
| | | departId: res.data.factoryId, |
| | | materialId: res.data.materialId, |
| | | procedureId: res.data.procedureId |
| | | }).then((result: any) => { |
| | | if (result.code === 200) { |
| | | infoBox.value = result.data |
| | | } |
| | | }) |
| | | } |
| | | }) |
| | | } |
| | |
| | | if (res.code === 200 && type === 'T') { |
| | | getOrocessRecords() |
| | | } else if (res.code === 200 && type === 'C') { |
| | | getOrocessRecordCC() |
| | | // getOrocessRecordCC() |
| | | } |
| | | }) |
| | | } |
| | |
| | | if (info.value.bomType === 1) { // æå¼ |
| | | console.log('æå¼') |
| | | statisticsData.value = [] |
| | | if (produceFrom.qualified <= 0) { |
| | | Toast.fail({ message: 'äº§åºæç»ä¸è½ä¸ºç©º' }) |
| | | return |
| | | } |
| | | if (info.value.hasBom === 0) { |
| | | console.log('æ bom') |
| | | // let data: any = [ |
| | |
| | | Toast.fail({ message: 'æææç»ä¸è½ä¸ºç©º' }) |
| | | return |
| | | } |
| | | if (produceFrom.qualified <= 0) { |
| | | Toast.fail({ message: 'äº§åºæç»ä¸è½ä¸ºç©º' }) |
| | | return |
| | | } |
| | | statisticsData.value = [] |
| | | if (info.value.hasBom === 0) { |
| | | console.log('æ bom') |
| | |
| | | |
| | | // 确认æ¥å·¥ |
| | | const submitBG = () => { |
| | | if (!from.duration || from.duration <= 0) { |
| | | return Toast('æ¥å·¥æ¶é¿ä¸è½ä¸ºç©º') |
| | | } |
| | | let createUnqualifiedDTOList = from.defective.map((item: any) => { |
| | | return { |
| | | categoryId: item.id, |
| | | unQualifiedNum: item.num |
| | | } |
| | | }) |
| | | let createWorkorderRecordDTO = { |
| | | workorderId: route.query.id, |
| | | duration: from.duration, |
| | | qualifiedNum: produceFrom.qualified ? produceFrom.qualified : 0, |
| | | unQualifiedNum: produceFrom.undesirable ? produceFrom.undesirable : 0 |
| | | } |
| | | // id: route.query.id |
| | | comfirmDoneStandard({ |
| | | id: route.query.id |
| | | createUnqualifiedDTOList, |
| | | createWorkorderRecordDTO |
| | | }).then(res => { |
| | | if (res.code === 200) { |
| | | Toast.success({ message: 'æ¥å·¥æå', forbidClick: true, duration: 2000 }) |
| | |
| | | pageDJs() |
| | | queryByIds() |
| | | getOrocessRecords() |
| | | getOrocessRecordCC() |
| | | getData() |
| | | // getOrocessRecordCC() |
| | | }) |
| | | </script> |
| | | |
| | |
| | | /*height: 100%;*/ |
| | | position: absolute; |
| | | background: #F7F7F7; |
| | | .bg_plan { |
| | | width: 100%; |
| | | // height: 98px; |
| | | padding: 30px; |
| | | box-sizing: border-box; |
| | | background: #FFFFFF; |
| | | margin-bottom: 40px; |
| | | display: flex; |
| | | align-items: center; |
| | | justify-content: space-between; |
| | | span { |
| | | font-size: 30px; |
| | | font-family: PingFangSC-Regular, PingFang SC; |
| | | font-weight: 400; |
| | | color: #222222; |
| | | b { |
| | | color: red; |
| | | } |
| | | } |
| | | .bg_plan_nr { |
| | | display: flex; |
| | | flex-direction: column; |
| | | span { |
| | | font-size: 24px; |
| | | font-family: PingFangSC-Regular, PingFang SC; |
| | | font-weight: 400; |
| | | color: #666666; |
| | | margin-top: 20px; |
| | | &:first-child { |
| | | font-size: 32px; |
| | | font-family: PingFangSC-Medium, PingFang SC; |
| | | font-weight: 500; |
| | | color: #333333; |
| | | margin-top: 0 !important; |
| | | } |
| | | } |
| | | } |
| | | .bg_plan_label_val { |
| | | display: flex; |
| | | align-items: center; |
| | | span { |
| | | font-size: 28px; |
| | | font-family: PingFangSC-Regular, PingFang SC; |
| | | font-weight: 400; |
| | | color: #999999; |
| | | } |
| | | img { |
| | | width: 12px; |
| | | height: 24px; |
| | | margin-left: 20px; |
| | | } |
| | | } |
| | | } |
| | | .details_cz { |
| | | width: 100%; |
| | | padding: 30px; |
| | |
| | | } |
| | | } |
| | | } |
| | | .bg_list_item_num { |
| | | .bg_list_item_h { |
| | | width: 100%; |
| | | background: white; |
| | | padding: 0 30px; |
| | | box-sizing: border-box; |
| | | .kong { |
| | | text-align: center; |
| | | font-size: 25px; |
| | | padding: 30px 0; |
| | | background: #ffffff; |
| | | } |
| | | .bg_list_item_num_item { |
| | | background: white; |
| | | .bg_list_item_num { |
| | | width: 100%; |
| | | min-height: 98px; |
| | | background: white; |
| | | display: flex; |
| | | justify-content: center; |
| | | align-items: center; |
| | | // height: 118px; |
| | | padding: 15px 0; |
| | | box-sizing: border-box; |
| | | justify-content: space-between; |
| | | border-bottom: 1px solid #E5E5E5; |
| | | border-bottom: 1PX solid #E5E5E5; |
| | | &:last-child { |
| | | border: none; |
| | | border: none !important; |
| | | } |
| | | .bg_list_item_num_item_wl { |
| | | flex-shrink: 0; |
| | | .kong { |
| | | text-align: center; |
| | | font-size: 25px; |
| | | padding: 30px 0; |
| | | background: #ffffff; |
| | | } |
| | | .bg_list_item_num_item { |
| | | width: 100%; |
| | | height: 100%; |
| | | display: flex; |
| | | flex-direction: column; |
| | | span { |
| | | font-size: 34px; |
| | | color: #222222; |
| | | align-items: center; |
| | | // height: 118px; |
| | | padding: 15px 0; |
| | | box-sizing: border-box; |
| | | justify-content: space-between; |
| | | border-bottom: 1px solid #E5E5E5; |
| | | &:last-child { |
| | | border: none; |
| | | } |
| | | .bg_list_item_num_item_wl_lx { |
| | | margin-top: 10px; |
| | | span { |
| | | color: #222222; |
| | | font-size: 28px; |
| | | .bg_list_item_num_item_list { |
| | | display: flex; |
| | | align-items: center; |
| | | .active { |
| | | background: #305ED5 !important; |
| | | color: #FFFFFF !important; |
| | | } |
| | | .bg_list_item_num_item_list_item { |
| | | width: 116px; |
| | | height: 62px; |
| | | line-height: 62px; |
| | | text-align: center; |
| | | background: #F2F2F2; |
| | | border-radius: 8px; |
| | | font-size: 26px; |
| | | font-family: PingFangSC-Regular, PingFang SC; |
| | | font-weight: 400; |
| | | color: #333333; |
| | | margin-right: 20px; |
| | | &:last-child { |
| | | margin: 0 !important; |
| | | } |
| | | } |
| | | } |
| | | } |
| | | .warning { |
| | | color: $nav-stateColor5 !important; |
| | | } |
| | | .err { |
| | | color: $nav-stateColor4 !important; |
| | | } |
| | | span { |
| | | flex-shrink: 0; |
| | | overflow: hidden; |
| | | text-overflow: ellipsis; |
| | | white-space: nowrap; |
| | | .bg_list_item_num_item_wl { |
| | | flex-shrink: 0; |
| | | display: flex; |
| | | flex-direction: column; |
| | | span { |
| | | font-size: 34px; |
| | | color: #222222; |
| | | } |
| | | .bg_list_item_num_item_wl_lx { |
| | | margin-top: 10px; |
| | | span { |
| | | color: #222222; |
| | | font-size: 28px; |
| | | } |
| | | } |
| | | } |
| | | .warning { |
| | | color: $nav-stateColor5 !important; |
| | | margin-right: 5px; |
| | | } |
| | | .err { |
| | | color: $nav-stateColor4 !important; |
| | | margin-right: 5px; |
| | | } |
| | | &:nth-child(1) { |
| | | font-size: 30px; |
| | | font-weight: 400; |
| | | color: #222222; |
| | | } |
| | | &:nth-child(2) { |
| | | font-size: 28px; |
| | | font-weight: 400; |
| | | color: #333333; |
| | | flex-shrink: 0; |
| | | } |
| | | } |
| | | .bg_list_item_num_item_sr { |
| | | flex: 1; |
| | | display: flex; |
| | | align-items: center; |
| | | justify-content: flex-end; |
| | | input::-webkit-input-placeholder { |
| | | font-size: 28px; |
| | | } |
| | | input { |
| | | text-align: right; |
| | | width: 180px; |
| | | height: 60px; |
| | | border-radius: 8px; |
| | | border: 1PX solid #E5E5E5; |
| | | margin-right: 20px; |
| | | font-size: 28px; |
| | | font-weight: 400; |
| | | color: #333333; |
| | | padding: 0 30px |
| | | img { |
| | | width: 12px; |
| | | height: 24px; |
| | | margin-left: 20px; |
| | | } |
| | | span { |
| | | font-size: 28px; |
| | | font-weight: 400; |
| | | color: #666666; |
| | | flex-shrink: 0; |
| | | overflow: hidden; |
| | | text-overflow: ellipsis; |
| | | white-space: nowrap; |
| | | b { |
| | | font-size: 30px; |
| | | color: red; |
| | | margin-right: 5px; |
| | | } |
| | | .warning { |
| | | color: $nav-stateColor5 !important; |
| | | margin-right: 5px; |
| | | } |
| | | .err { |
| | | color: $nav-stateColor4 !important; |
| | | margin-right: 5px; |
| | | } |
| | | &:nth-child(1) { |
| | | font-size: 30px; |
| | | font-weight: 400; |
| | | color: #222222; |
| | | } |
| | | &:nth-child(2) { |
| | | font-size: 28px; |
| | | font-weight: 400; |
| | | color: #333333; |
| | | flex-shrink: 0; |
| | | } |
| | | } |
| | | .bg_list_item_num_item_sr { |
| | | flex: 1; |
| | | display: flex; |
| | | align-items: center; |
| | | justify-content: flex-end; |
| | | .color1 { |
| | | font-size: 28px; |
| | | font-family: PingFangSC-Regular, PingFang SC; |
| | | font-weight: 400; |
| | | color: #333333; |
| | | } |
| | | input::-webkit-input-placeholder { |
| | | font-size: 28px; |
| | | } |
| | | input { |
| | | text-align: right; |
| | | width: 180px; |
| | | height: 60px; |
| | | border-radius: 8px; |
| | | border: 1PX solid #E5E5E5; |
| | | margin-right: 20px; |
| | | font-size: 28px; |
| | | font-weight: 400; |
| | | color: #333333; |
| | | padding: 0 30px |
| | | } |
| | | .wulll { |
| | | width: 400px; |
| | | text-align: right; |
| | | overflow: hidden; |
| | | white-space: nowrap; |
| | | text-overflow: ellipsis; |
| | | } |
| | | span { |
| | | font-size: 28px; |
| | | font-family: PingFangSC-Regular, PingFang SC; |
| | | font-weight: 400; |
| | | color: #999999; |
| | | } |
| | | } |
| | | } |
| | | } |
| | |
| | | } |
| | | } |
| | | .bl { |
| | | width: 100%; |
| | | height: 800px; |
| | | padding: 30px; |
| | | box-sizing: border-box; |
| | | display: flex; |
| | | flex-direction: column; |
| | | .bl_head { |
| | | width: 100%; |
| | | height: 50px; |
| | | display: flex; |
| | | align-items: center; |
| | | justify-content: space-between; |
| | |
| | | font-size: 32px !important; |
| | | } |
| | | } |
| | | img { |
| | | width: 28px; |
| | | height: 28px; |
| | | } |
| | | } |
| | | .bl_footer { |
| | | width: 100%; |
| | | height: 88px; |
| | | line-height: 88px; |
| | | text-align: center; |
| | | background: #305ED5; |
| | | border-radius: 8px; |
| | | font-size: 32px; |
| | | font-family: PingFangSC-Medium, PingFang SC; |
| | | font-weight: 500; |
| | | color: #FFFFFF; |
| | | margin-top: 30px; |
| | | } |
| | | .bl_list { |
| | | width: 100%; |
| | | height: 580px; |
| | | height: calc(100% - 168px); |
| | | overflow-y: scroll; |
| | | margin-top: 30px; |
| | | .bl_list_item { |
| | | width: 100%; |
| | | height: 60px; |
| | | height: 96px; |
| | | display: flex; |
| | | align-items: center; |
| | | justify-content: space-between; |
| | | margin-bottom: 20px; |
| | | border-bottom: 1PX solid #E5E5E5; |
| | | &:last-child { |
| | | margin-bottom: 0 !important; |
| | | border: none !important; |
| | | } |
| | | .bl_list_item_left { |
| | | flex: 1; |
| | |
| | | input { |
| | | width: 30px; |
| | | height: 30px; |
| | | border: 1PX solid #CCCCCC; |
| | | margin: 0 !important; |
| | | } |
| | | span { |
| | |
| | | padding-left: 5px; |
| | | width: 160px; |
| | | height: 100%; |
| | | padding: 0 30px; |
| | | box-sizing: border-box; |
| | | text-align: right; |
| | | font-size: 28px; |
| | | color: #333333; |
| | | border-radius: 10px; |
| | | border: 2px solid #999999 |
| | | border: 1PX solid #CCCCCC; |
| | | &::-webkit-input-placeholder { |
| | | font-size: 28px; |
| | | font-family: PingFangSC-Regular, PingFang SC; |
| | | font-weight: 400; |
| | | color: #999999; |
| | | } |
| | | } |
| | | } |
| | | } |
| | |
| | | input { |
| | | flex: 1; |
| | | height: 100%; |
| | | padding: 0 !important; |
| | | font-size: 30px; |
| | | font-family: PingFangSC-Regular, PingFang SC; |
| | | font-weight: 400; |
| | |
| | | <script>
|
| | | <script> |
| | | console.log('app------'); |
| | | // import { pageCount } from '@/util/api/index.js'
|
| | | export default {
|
| | | onLaunch: function() {
|
| | | onLaunch: function() { |
| | | // pageCount({})
|
| | | },
|
| | | onShow: function() {
|
| | | },
|
| | |
| | | module.exports = { |
| | | // baseUrl: 'http://106.14.20.42/test_hfznzz/', |
| | | baseUrl: 'https://hefei.dtkey.cn/test_hfznzz/', |
| | | // baseUrl: 'http://192.168.0.35:10011/', |
| | | // baseUrl: 'https://hefei.dtkey.cn/test_hfznzz/', |
| | | baseUrl: 'https://dmtest.ahapp.net/doumeeplant_api/' |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | <template> |
| | | <view> |
| | | <u-tabbar |
| | | :value="index" |
| | | @change="change" |
| | | fixed |
| | | activeColor="#222" |
| | | inactiveColor="#666" |
| | | > |
| | | <u-tabbar-item text="å¾
å"> |
| | | <view class="" slot="active-icon"> |
| | | <image src="@/static/nav_daiban_sel@2x.png" class="icon-style" mode=""></image> |
| | | </view> |
| | | <view class="" slot="inactive-icon"> |
| | | <image src="@/static/nav_daiban@2x.png" class="icon-style" mode=""></image> |
| | | </view> |
| | | </u-tabbar-item> |
| | | <u-tabbar-item text="å·¥ä½å°"> |
| | | <view class="" slot="active-icon"> |
| | | <image src="@/static/nav_gongzuotai_sel@2x.png" class="icon-style" mode=""></image> |
| | | </view> |
| | | <view class="" slot="inactive-icon"> |
| | | <image src="@/static/nav_gongzuotai@2x.png" class="icon-style" mode=""></image> |
| | | </view> |
| | | </u-tabbar-item> |
| | | <u-tabbar-item text="æç"> |
| | | <view class="" slot="active-icon"> |
| | | <image src="@/static/nav_wode_sel@2x.png" class="icon-style" mode=""></image> |
| | | </view> |
| | | <view class="" slot="inactive-icon"> |
| | | <image src="@/static/nav_wode@2x.png" class="icon-style" mode=""></image> |
| | | </view> |
| | | </u-tabbar-item> |
| | | </u-tabbar> |
| | | </view> |
| | | </template> |
| | | |
| | | <script> |
| | | export default { |
| | | name:"myTabbar", |
| | | props: { |
| | | index: 0 |
| | | }, |
| | | data() { |
| | | return { |
| | | value: 0 |
| | | }; |
| | | }, |
| | | methods: { |
| | | click(index) { |
| | | // console.log('click', index); |
| | | // this.$nextTick(() => { |
| | | // this.value = index |
| | | // if (index==0) { |
| | | // uni.switchTab({ |
| | | // url: '/pages/index/index' |
| | | // }); |
| | | // } else if (index== 1) { |
| | | // uni.switchTab({ |
| | | // url: '/pages/service/service' |
| | | // }); |
| | | // }else { |
| | | // uni.switchTab({ |
| | | // url: '/pages/mine/mine' |
| | | // }); |
| | | // } |
| | | // }) |
| | | }, |
| | | change(index) { |
| | | this.$nextTick(() => { |
| | | this.value = index |
| | | }) |
| | | |
| | | console.log(this.value); |
| | | if (index==0) { |
| | | // console.log('index'); |
| | | uni.switchTab({ |
| | | url: '/pages/index/index' |
| | | }); |
| | | } else if (index== 1) { |
| | | // console.log('workbench'); |
| | | uni.switchTab({ |
| | | url: '/pages/workbench/workbench' |
| | | }); |
| | | }else { |
| | | // console.log('mine'); |
| | | uni.switchTab({ |
| | | url: '/pages/mine/mine' |
| | | }); |
| | | } |
| | | } |
| | | }, |
| | | } |
| | | </script> |
| | | |
| | | <style lang="scss" scope> |
| | | .icon-style { |
| | | width: 44rpx; |
| | | height: 44rpx; |
| | | } |
| | | </style> |
| | |
| | | import Vue from 'vue' |
| | | import App from './App' |
| | | |
| | | // vuex
|
| | | import store from './store' |
| | | |
| | | import mixin from './common/mixin' |
| | | |
| | | // å¼å
¥å
¨å±uView
|
| | | import uView from '@/uni_modules/uview-ui' |
| | | Vue.use(uView) |
| | | |
| | | // vuex
|
| | | import store from './store' |
| | | Vue.prototype.$store = store |
| | | store.dispatch('getHeight') |
| | | |
| | | Vue.config.productionTip = false |
| | | |
| | | App.mpType = 'app'
|
| | | Vue.use(uView) |
| | | |
| | | console.log(uni.$u); |
| | | // #ifdef MP
|
| | | // å¼å
¥uView对å°ç¨åºå享çmixinå°è£
|
| | | const mpShare = require('@/uni_modules/uview-ui/libs/mixin/mpShare.js') |
| | |
| | | // #endif |
| | | |
| | | Vue.mixin(mixin) |
| | | // å¼å
¥è¯·æ±å°è£
|
| | | |
| | | const app = new Vue({ |
| | | store,
|
| | | ...App
|
| | | })
|
| | |
|
| | | // å¼å
¥è¯·æ±å°è£
|
| | | require('./util/request/index')(app)
|
| | | // è·åå¾
åæ°é |
| | | store.dispatch('getUpcomingNum')
|
| | |
|
| | | app.$mount() |
| | |
| | | {
|
| | | "pages": [ //pagesæ°ç»ä¸ç¬¬ä¸é¡¹è¡¨ç¤ºåºç¨å¯å¨é¡µï¼åèï¼https://uniapp.dcloud.io/collocation/pages
|
| | | { |
| | | "path": "pages/projectList/projectList", |
| | | "path": "pages/workbench/workbench", |
| | | "style": { |
| | | "navigationBarTitleText": "项ç®å表", |
| | | // "enablePullDownRefresh": true, |
| | | "navigationStyle": "custom" |
| | | "navigationBarTitleText": "å·¥ä½å°", |
| | | "enablePullDownRefresh": false |
| | | } |
| | | |
| | | },{
|
| | | }, |
| | | {
|
| | | "path": "pages/index/index",
|
| | | "style": {
|
| | | "navigationBarTitleText": "uni-app",
|
| | | "navigationStyle": "custom"
|
| | | "navigationBarTitleText": "å¾
å"
|
| | | }
|
| | | }, {
|
| | | "path": "pages/applyList/applyList",
|
| | | }, {
|
| | | "path": "pages/mine/mine",
|
| | | "style": {
|
| | | "navigationBarTitleText": "ä¼ä¸æ¥åå表",
|
| | | "enablePullDownRefresh": false,
|
| | | "navigationBarBackgroundColor": "#F3F6F9"
|
| | | }
|
| | |
|
| | | }, {
|
| | | "path": "pages/comApplyList/comApplyList",
|
| | | "style": {
|
| | | "navigationBarTitleText": "ä¼ä¸æ¥åå表",
|
| | | "navigationBarTitleText": "æç",
|
| | | "enablePullDownRefresh": false
|
| | | }
|
| | |
|
| | | }, {
|
| | | "path": "pages/applyDetail/applyDetail",
|
| | | "style": {
|
| | | "navigationBarTitleText": "ä¼ä¸æ¥å详æ
",
|
| | | "enablePullDownRefresh": false,
|
| | | "navigationStyle": "custom"
|
| | | }
|
| | |
|
| | | }, {
|
| | | "path": "pages/uploadServiceData/uploadServiceData",
|
| | | "style": {
|
| | | "navigationBarTitleText": "ä¸ä¼ æå¡æ°æ®",
|
| | | "enablePullDownRefresh": false
|
| | |
|
| | | }
|
| | |
|
| | | }, {
|
| | | "path": "pages/uploadCheckData/uploadCheckData",
|
| | | "style": {
|
| | | "navigationBarTitleText": "ä¸ä¼ è¯ææ°æ®",
|
| | | "enablePullDownRefresh": false
|
| | | }
|
| | |
|
| | | }
|
| | | ],
|
| | | ,{
|
| | | "path" : "pages/login/login", |
| | | "style" : |
| | | { |
| | | "navigationBarTitleText": "ç»å½", |
| | | "enablePullDownRefresh": false, |
| | | "navigationStyle": "custom" |
| | | } |
| | | |
| | | }
|
| | | ],
|
| | | "globalStyle": {
|
| | | "navigationBarTextStyle": "black",
|
| | | "navigationBarTitleText": "uni-app",
|
| | | "navigationBarTitleText": "uni-app", |
| | | "navigationBarBackgroundColor": "#F3F6F9",
|
| | | "backgroundColor": "#F3F6F9"
|
| | | }, |
| | | "tabBar": { |
| | | "color": "#666666", |
| | | "selectedColor": "#222222", |
| | | "borderStyle": "black", |
| | | "backgroundColor": "#fff", |
| | | "list": [ |
| | | { |
| | | "pagePath": "pages/index/index", |
| | | "iconPath": "static/nav_daiban@2x.png", |
| | | "selectedIconPath": "static/nav_daiban_sel@2x.png", |
| | | "text": "å¾
å" |
| | | }, |
| | | { |
| | | "pagePath": "pages/workbench/workbench", |
| | | "iconPath": "static/nav_gongzuotai@2x.png", |
| | | "selectedIconPath": "static/nav_gongzuotai_sel@2x.png", |
| | | "text": "å·¥ä½å°" |
| | | }, |
| | | { |
| | | "pagePath": "pages/mine/mine", |
| | | "iconPath": "static/nav_wode@2x.png", |
| | | "selectedIconPath": "static/nav_wode_sel@2x.png", |
| | | "text": "æç" |
| | | } |
| | | ] |
| | | },
|
| | | "uniIdRouter": {}
|
| | | } |
| | |
| | | <template>
|
| | | <view class="content">
|
| | | <view class="p40 nav bbox"> |
| | | <view class="">åè¥å¸æºæ¹æ°è½¬è¯ææå¡å¹³å°</view> |
| | | <view class="">欢è¿ç»å½</view> |
| | | </view> |
| | | <view class="p40 mt30"> |
| | | <u--input |
| | | placeholder="请è¾å
¥è´¦å·" |
| | | prefixIcon="account" |
| | | clearable |
| | | v-model="form.account" |
| | | prefixIconStyle="font-size: 40rpx;color: #AAAAAA" |
| | | ></u--input> |
| | | <view class="p20"></view> |
| | | <u--input |
| | | placeholder="请è¾å
¥å¯ç " |
| | | prefixIcon="lock" |
| | | password |
| | | clearable |
| | | v-model="form.password" |
| | | prefixIconStyle="font-size: 40rpx;color: #AAAAAA" |
| | | ></u--input> |
| | | <view class="ptb50"></view> |
| | | <u-button |
| | | :loading="logining" |
| | | type="primary" |
| | | color="#216EEE" |
| | | text="ç»å½" |
| | | size="large" |
| | | @click="loginAction" |
| | | ></u-button> |
| | | </view> |
| | | <view> |
| | |
|
| | | <myTabbar :index="0" />
|
| | | </view>
|
| | | </template>
|
| | |
|
| | | <script> |
| | | |
| | | import { coustomLogin, wxEmpower } from '@/util/api/index' |
| | | <script>
|
| | | // import { coustomLogin, wxEmpower } from '@/util/api/index'
|
| | |
|
| | |
|
| | | import myTabbar from "@/components/myTabber.vue"
|
| | | export default {
|
| | | components: {
|
| | | myTabbar
|
| | | },
|
| | | data() {
|
| | | return {
|
| | | form: { |
| | | account: '', |
| | | password: '', |
| | | }, |
| | | logining: false, |
| | | form: {
|
| | | account: '',
|
| | | password: '',
|
| | | },
|
| | | logining: false,
|
| | | openId: ''
|
| | | }
|
| | | }, |
| | | onLoad() { |
| | | uni.login({ |
| | | success: data => { |
| | | this.wxLogin(data.code) |
| | | }, |
| | | fail: err => { |
| | | uni.$u.toast(err) |
| | | } |
| | | }) |
| | | },
|
| | | onLoad() {
|
| | | // uni.login({
|
| | | // success: data => {
|
| | | // this.wxLogin(data.code)
|
| | | // },
|
| | | // fail: err => {
|
| | | // uni.$u.toast(err)
|
| | | // }
|
| | | // })
|
| | | },
|
| | | methods: {
|
| | | loginAction() { |
| | | if (!this.form.account || !this.form.password) { |
| | | uni.$u.toast('è´¦å·æè
å¯ç ä¸è½ä¸ºç©º') |
| | | } |
| | | this.logining = true |
| | | coustomLogin({...this.form, openid: this.openId}) |
| | | .then(res => { |
| | | this.$store.commit('SETTOKEN', res.token) |
| | | this.$store.commit('SETUSERINFO', res) |
| | | uni.navigateTo({ |
| | | url:'/pages/projectList/projectList' |
| | | }) |
| | | }) |
| | | .finally(() => { |
| | | this.logining = false |
| | | }) |
| | | }, |
| | | wxLogin(code) { |
| | | wxEmpower({code}) |
| | | .then(res => { |
| | | this.openId = res.openid |
| | | if (res.userInfo) { |
| | | this.$store.commit('SETTOKEN', res.userInfo.token) |
| | | this.$store.commit('SETUSERINFO', res.userInfo) |
| | | uni.navigateTo({ |
| | | url:'/pages/projectList/projectList' |
| | | }) |
| | | } |
| | | }) |
| | | .catch(err => { |
| | | uni.$u.toast(err) |
| | | }) |
| | | }
|
| | | // loginAction() {
|
| | | // if (!this.form.account || !this.form.password) {
|
| | | // uni.$u.toast('è´¦å·æè
å¯ç ä¸è½ä¸ºç©º')
|
| | | // }
|
| | | // this.logining = true
|
| | | // coustomLogin({...this.form, openid: this.openId})
|
| | | // .then(res => {
|
| | | // this.$store.commit('SETTOKEN', res.token)
|
| | | // this.$store.commit('SETUSERINFO', res)
|
| | | // uni.navigateTo({
|
| | | // url:'/pages/projectList/projectList'
|
| | | // })
|
| | | // })
|
| | | // .finally(() => {
|
| | | // this.logining = false
|
| | | // })
|
| | | // },
|
| | | // wxLogin(code) {
|
| | | // wxEmpower({code})
|
| | | // .then(res => {
|
| | | // this.openId = res.openid
|
| | | // if (res.userInfo) {
|
| | | // this.$store.commit('SETTOKEN', res.userInfo.token)
|
| | | // this.$store.commit('SETUSERINFO', res.userInfo)
|
| | | // uni.navigateTo({
|
| | | // url:'/pages/projectList/projectList'
|
| | | // })
|
| | | // } |
| | | // })
|
| | | // .catch(err => {
|
| | | // uni.$u.toast(err)
|
| | | // })
|
| | | // }
|
| | | }
|
| | | }
|
| | | </script>
|
| | |
|
| | | <style lang="scss" scoped>
|
| | | .content {
|
| | | // display: flex;
|
| | | // flex-direction: column;
|
| | | // align-items: center;
|
| | | // justify-content: center; |
| | | height: 100vh; |
| | | background-color: #FFFFFF; |
| | | .nav { |
| | | |
| | | width: 750rpx; |
| | | height: 520rpx; |
| | | background: linear-gradient(180deg, #C7EBFF 0%, #FFFFFF 100%); |
| | | display: flex; |
| | | flex-direction: column-reverse; |
| | | color: #293C5B; |
| | | :first-child { |
| | | height: 52rpx; |
| | | font-size: 36rpx; |
| | | line-height: 52rpx; |
| | | } |
| | | :last-child { |
| | | height: 80rpx; |
| | | font-size: 56rpx; |
| | | font-weight: 500; |
| | | line-height: 80rpx; |
| | | margin-bottom: 16rpx; |
| | | } |
| | | }
|
| | | }
|
| | |
|
| | | .logo {
|
| | | height: 200rpx;
|
| | | width: 200rpx;
|
| | | margin-top: 200rpx;
|
| | | margin-left: auto;
|
| | | margin-right: auto;
|
| | | margin-bottom: 50rpx;
|
| | | }
|
| | |
|
| | | .text-area {
|
| | | display: flex;
|
| | | justify-content: center;
|
| | | }
|
| | |
|
| | | .title {
|
| | | font-size: 36rpx;
|
| | | color: #8f8f94;
|
| | | }
|
| | | </style> |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | <template> |
| | | <view class="login-content plr60"> |
| | | <view class="login-bg"> |
| | | <image src="@/static/login_bg@2x.png" mode="aspectFill" class="bg-img"></image> |
| | | <image src="@/static/logo@2x.png" mode="aspectFill" class="login-log img180"></image> |
| | | <view class="tc title">DMäºå·¥å</view> |
| | | </view> |
| | | <view class="bg_w rd8 ptb30 pl40 bbox com-input flex input-height"> |
| | | <image src="@/static/login_ic_code@2x.png" mode="" class="img40 mr25"></image> |
| | | <u--input placeholder="ä¼ä¸ä»£ç " border="none"></u--input> |
| | | </view> |
| | | <view class="bg_w rd8 ptb30 pl40 bbox mt40 flex input-height"> |
| | | <image src="@/static/login_ic_phone@2x.png" mode="" class="img40 mr25"></image> |
| | | <u--input placeholder="ææºå·" border="none"></u--input> |
| | | </view> |
| | | <view class="bg_w rd8 ptb30 pl40 bbox mt40 flex input-height"> |
| | | <image src="@/static/login_ic_password@2x.png" mode="" class="img40 mr25"></image> |
| | | <u--input placeholder="å¯ç " border="none"></u--input> |
| | | </view> |
| | | <view class="login-btn mt80">ç«å³ç»å½</view> |
| | | </view> |
| | | </template> |
| | | |
| | | <script> |
| | | export default { |
| | | data() { |
| | | return { |
| | | bgImg: require('@/static/login_bg@2x.png') |
| | | }; |
| | | } |
| | | } |
| | | </script> |
| | | |
| | | <style lang="scss" scoped> |
| | | .login-content { |
| | | height: 100vh; |
| | | background: #FFFFFF linear-gradient(180deg, rgba(66,117,252,0.2) 0%, rgba(66,117,252,0) 100%); |
| | | .login-bg { |
| | | position: relative; |
| | | height: 812rpx; |
| | | .bg-img { |
| | | position: absolute; |
| | | z-index: 1; |
| | | width: 100%; |
| | | height: 100%; |
| | | } |
| | | .login-log { |
| | | // margin-top: ; |
| | | margin: 356rpx auto 0 auto ; |
| | | left: 0; |
| | | right: 0; |
| | | position: absolute; |
| | | } |
| | | .title { |
| | | position: absolute; |
| | | margin-top: 576rpx; |
| | | left: 0; |
| | | width: 100%; |
| | | height: 60rpx; |
| | | font-size: 44rpx; |
| | | font-weight: 600; |
| | | color: #333333; |
| | | line-height: 60rpx; |
| | | } |
| | | } |
| | | .input-height { |
| | | height: 100rpx; |
| | | } |
| | | .com-input { |
| | | margin-top: -60px; |
| | | } |
| | | .login-btn { |
| | | height: 98rpx; |
| | | background: #4275FC; |
| | | box-shadow: 0rpx 12rpx 24rpx 0rpx rgba(66,117,252,0.2); |
| | | border-radius: 8rpx; |
| | | text-align: center; |
| | | font-size: 32rpx; |
| | | font-weight: 500; |
| | | color: #FFFFFF; |
| | | line-height: 98rpx; |
| | | } |
| | | } |
| | | </style> |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | <template>
|
| | | <view>
|
| | |
|
| | | <myTabbar :index="2" />
|
| | | </view>
|
| | | </template>
|
| | |
|
| | | <script>
|
| | | import myTabbar from "@/components/myTabber.vue"
|
| | | export default {
|
| | | components: {
|
| | | myTabbar
|
| | | },
|
| | | data() {
|
| | | return {
|
| | | form: {
|
| | | account: '',
|
| | | password: '',
|
| | | },
|
| | | logining: false,
|
| | | openId: ''
|
| | | }
|
| | | },
|
| | | onLoad() {
|
| | | // uni.login({
|
| | | // success: data => {
|
| | | // this.wxLogin(data.code)
|
| | | // },
|
| | | // fail: err => {
|
| | | // uni.$u.toast(err)
|
| | | // }
|
| | | // })
|
| | | },
|
| | | methods: {
|
| | | // loginAction() {
|
| | | // if (!this.form.account || !this.form.password) {
|
| | | // uni.$u.toast('è´¦å·æè
å¯ç ä¸è½ä¸ºç©º')
|
| | | // }
|
| | | // this.logining = true
|
| | | // coustomLogin({...this.form, openid: this.openId})
|
| | | // .then(res => {
|
| | | // this.$store.commit('SETTOKEN', res.token)
|
| | | // this.$store.commit('SETUSERINFO', res)
|
| | | // uni.navigateTo({
|
| | | // url:'/pages/projectList/projectList'
|
| | | // })
|
| | | // })
|
| | | // .finally(() => {
|
| | | // this.logining = false
|
| | | // })
|
| | | // },
|
| | | // wxLogin(code) {
|
| | | // wxEmpower({code})
|
| | | // .then(res => {
|
| | | // this.openId = res.openid
|
| | | // if (res.userInfo) {
|
| | | // this.$store.commit('SETTOKEN', res.userInfo.token)
|
| | | // this.$store.commit('SETUSERINFO', res.userInfo)
|
| | | // uni.navigateTo({
|
| | | // url:'/pages/projectList/projectList'
|
| | | // })
|
| | | // } |
| | | // })
|
| | | // .catch(err => {
|
| | | // uni.$u.toast(err)
|
| | | // })
|
| | | // }
|
| | | }
|
| | | }
|
| | | </script>
|
| | |
|
| | | <style lang="scss" scoped>
|
| | |
|
| | | </style> |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | <template>
|
| | | <view>
|
| | |
|
| | | <myTabbar :index="1" />
|
| | | </view>
|
| | | </template>
|
| | |
|
| | | <script>
|
| | | import myTabbar from "@/components/myTabber.vue" |
| | | |
| | | export default {
|
| | | components: {
|
| | | myTabbar
|
| | | },
|
| | | data() {
|
| | | return {
|
| | |
|
| | | };
|
| | | },
|
| | | onLoad() { |
| | | uni.hideTabBar()
|
| | | // uni.login({
|
| | | // success: data => {
|
| | | // this.wxLogin(data.code)
|
| | | // },
|
| | | // fail: err => {
|
| | | // uni.$u.toast(err)
|
| | | // }
|
| | | // })
|
| | | },
|
| | | methods: {
|
| | | |
| | | // wxLogin(code) {
|
| | | // wxEmpower({code})
|
| | | // .then(res => {
|
| | | // this.openId = res.openid
|
| | | // if (res.userInfo) {
|
| | | // this.$store.commit('SETTOKEN', res.userInfo.token)
|
| | | // this.$store.commit('SETUSERINFO', res.userInfo)
|
| | | // uni.navigateTo({
|
| | | // url:'/pages/projectList/projectList'
|
| | | // })
|
| | | // } |
| | | // })
|
| | | // .catch(err => {
|
| | | // uni.$u.toast(err)
|
| | | // })
|
| | | // }
|
| | | }
|
| | | }
|
| | | </script>
|
| | |
|
| | | <style lang="scss">
|
| | |
|
| | | </style> |
| | |
| | | import Vue from 'vue'
|
| | | import Vuex from 'vuex'
|
| | | import Vuex from 'vuex' |
| | | import { pageCount } from '@/util/api/index.js'
|
| | |
|
| | | Vue.use(Vuex) // vueçæä»¶æºå¶
|
| | |
|
| | |
| | | token: token || null,
|
| | | menuButtonWidth: menuButtonWidth || '0',
|
| | | statusbarHeight: statusbarHeight || '0',
|
| | | navHeight: navHeight || '0',
|
| | | navHeight: navHeight || '0', |
| | | // å¾
åæ°é |
| | | upcomingNum: { |
| | | d: 0, |
| | | y: 0 |
| | | },
|
| | | },
|
| | | mutations: {
|
| | | setHeight(state, val) {
|
| | |
| | | SETUSERINFO(state, val) { |
| | | state.userInfo = val |
| | | uni.setStorageSync('userInfo', val); |
| | | }, |
| | | SETNUM(state, val) { |
| | | state.upcomingNum.d = val.d |
| | | state.upcomingNum.y = val.y |
| | | }
|
| | | },
|
| | | actions: {
|
| | |
| | | menuButtonWidth
|
| | | })
|
| | | }, |
| | | async getUpcomingNum() { |
| | | let res = await pageCount({}) |
| | | if (res.code === 200) { |
| | | content.commit('SETNUM', { d: res.data.startNum, y: res.data.endNum }) |
| | | } |
| | | } |
| | | }
|
| | | })
|
| | |
|
| | |
| | | console.log('-----------'); |
| | | const http = uni.$u.http |
| | | // ç»å½ |
| | | export function coustomLogin(params) { |
| | | return http.get('/wechat/ordinaryLogin', {params}) |
| | | } |
| | | |
| | | // å¾®ä¿¡ææ |
| | | export function wxEmpower(params) { |
| | | return http.get('/wechat/wxEmpower', {params}) |
| | | } |
| | | // å页æ¥è¯¢é¡¹ç®ä¿¡æ¯ |
| | | export function projectPage(data) { |
| | | return http.post('/wechat/project/page', data) |
| | | } |
| | | |
| | | // æ ¹æ®é¡¹ç®idå页æ¥è¯¢ä¼ä¸æ¥åæ°æ® |
| | | export function getPageByProjectId(data) { |
| | | return http.post('/wechat/getPageByProjectId', data) |
| | | } |
| | | |
| | | // æ ¹æ®IDæ¥è¯¢æ¥å详æ
|
| | | export function declaresDetail(id) { |
| | | return http.get(`/wechat/declares/${id}`) |
| | | } |
| | | |
| | | // æ ¹æ®IDæ¥è¯¢æ¥å详æ
|
| | | export function companyDetail(params) { |
| | | return http.get(`/wechat/company/queryDetail`, { params }) |
| | | } |
| | | |
| | | |
| | | // æ ¹æ®é¡¹ç®idå页æ¥è¯¢ä¼ä¸æ¥åæ°æ® |
| | | export function serviceDetail(data) { |
| | | return http.post('/wechat/declares/serviceDetail', data) |
| | | } |
| | | |
| | | // æ ¹æ®ç»çº¬åº¦éè§£æå°å |
| | | export function getAddrByLatAndLng(params) { |
| | | return http.get(`/wechat/getAddrByLatAndLng`, { params }) |
| | | } |
| | | |
| | | // æ ¹æ®ç³æ¥ç¼ç æ¥è¯¢æå䏿¬¡æ ¸æ¥æè¯ææ°æ® |
| | | export function declareService({id, type}) { |
| | | return http.post(`/wechat/declareService/${id}?type=${type}`) |
| | | } |
| | | |
| | | // ä¸ä¼ æ ¸æ¥èµæ-ä¸ä¼ æå¡èµæ |
| | | export function uploadHCData(data) { |
| | | return http.post(`/wechat/uploadHCData`, data) |
| | | // æ¥è¯¢ç»è®¡å表æ°é |
| | | export function pageCount(data) { |
| | | return http.post('/ext/noticesExt/pageCount', data) |
| | | } |
| | | |
| | | // éåºç»å½ |
| | |
| | | return http.get(`/wechat/logout`) |
| | | } |
| | | |
| | | // æ ¹æ®ç³æ¥idæ¥çç³æ¥è¿åº¦ |
| | | export function getDeclareHistoryList(data) { |
| | | return http.post(`/wechat/getDeclareHistoryList`, data) |
| | | } |
| | |
| | | module.exports = (vm) => { |
| | | // console.log(vm)
|
| | | uni.$u.http.interceptors.request.use((config) => { // å¯ä½¿ç¨async await å弿¥æä½
|
| | | // åå§åè¯·æ±æ¦æªå¨æ¶ï¼ä¼æ§è¡æ¤æ¹æ³ï¼æ¤æ¶data为undefinedï¼èµäºé»è®¤{}
|
| | | // åå§åè¯·æ±æ¦æªå¨æ¶ï¼ä¼æ§è¡æ¤æ¹æ³ï¼æ¤æ¶data为undefinedï¼èµäºé»è®¤{} |
| | | console.log('è¯·æ±æ¦æª');
|
| | | config.data = config.data || {} |
| | | const token = vm.$store.state.token |
| | | if (token) { |
| | |
| | | * ååºæ¦æª
|
| | | * @param {Object} http
|
| | | */ |
| | | import { coustomLogin, wxEmpower } from '@/util/api/index'
|
| | | module.exports = (vm) => {
|
| | | uni.$u.http.interceptors.response.use((response) => {
|
| | | /* 对ååºæååç¹ä»ä¹ å¯ä½¿ç¨async await å弿¥æä½*/
|
| | |
| | | const custom = response.config?.custom
|
| | | if (data.code !== 200) { // æå¡ç«¯è¿åçç¶æç ä¸çäº200ï¼åreject() |
| | | uni.$u.toast(data.message) |
| | | if (data.code === 5112) { |
| | | if (data.code === 401) { |
| | | // console.log('æªç»å½ãç»å½å¤±æ'); |
| | | // æªç»å½ãç»å½å¤±æ |
| | | uni.reLaunch({ |
| | | url: '/pages/index/index' |
| | | url: '/pages/login/login' |
| | | }) |
| | | } |
| | | return Promise.reject(data)
|
| | |
| | | @PostMapping("/updateById") |
| | | @RequiresPermissions("business:salaryparam:update") |
| | | public ApiResponse updateById(@RequestBody SalaryParam salaryParam) { |
| | | salaryParamService.updateById(salaryParam); |
| | | salaryParamService.update(salaryParam); |
| | | return ApiResponse.success(null); |
| | | } |
| | | |
| | |
| | | per.setType(Constants.PlatType.admin); |
| | | }else{ |
| | | if(authenticationToken.getCompanyId() == null){ |
| | | throw new BusinessException(ResponseStatus.BAD_REQUEST.getCode(),"对ä¸èµ·ï¼è¯¥è´¦æ·å¼å¸¸ï¼"); |
| | | throw new BusinessException(ResponseStatus.BAD_REQUEST.getCode(),"对ä¸èµ·ï¼è¯¥è´¦æ·å é¤ï¼"); |
| | | } |
| | | com = companyExtService.getModelById(authenticationToken.getCompanyId()); |
| | | if(com == null){ |
| | | throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"对ä¸èµ·ï¼è¯¥è´¦æ·å¼å¸¸ï¼"); |
| | | if(com == null || Constants.equalsInteger( com.getDeleted(),Constants.ONE)){ |
| | | throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"对ä¸èµ·ï¼è¯¥è´¦æ·å¼å¸¸ï¼è¯·è系管çå"); |
| | | } |
| | | if(Constants.equalsInteger( com.getStatus(),Constants.ZERO) ){ |
| | | throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"对ä¸èµ·ï¼è¯¥ä¼ä¸å·²ç¦ç¨ï¼"); |
| | |
| | | private String planCode; |
| | | |
| | | @ApiModelProperty(value = "计åå®ææ¥æ") |
| | | @ExcelColumn(name="è®¡åæ¥æ",index = 4,width =15) |
| | | @ExcelColumn(name="计åå®ææ¥æ",index = 4,width =15) |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | private Date planDate; |
| | | @ApiModelProperty(value = "计åå¼å§æ¥æ") |
| | |
| | | package doumeemes.dao.ext.dto; |
| | | |
| | | import doumeemes.core.annotation.excel.ExcelColumn; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import javax.validation.constraints.NotEmpty; |
| | | |
| | | /** |
| | | * @author æ±è¹è¹ |
| | |
| | | @ApiModelProperty(value = "计价æ¹å¼ 0计件 1计æ¶") |
| | | private Integer type; |
| | | |
| | | @ApiModelProperty(value = "主ç»ç»ç¼ç ï¼å
³èdepartmentè¡¨æ ¹ç»ç»ï¼") |
| | | private Integer rootDepartId; |
| | | |
| | | @ApiModelProperty(value = "å·¥åç¼ç ï¼å
³èdepartment表ï¼") |
| | | private Integer departId; |
| | | |
| | | } |
| | |
| | | package doumeemes.service.business.impl; |
| | | |
| | | import com.baomidou.mybatisplus.extension.api.R; |
| | | import doumeemes.core.constants.ResponseStatus; |
| | | import doumeemes.core.exception.BusinessException; |
| | | import doumeemes.core.model.ApiResponse; |
| | |
| | | import doumeemes.core.utils.Utils; |
| | | import doumeemes.core.utils.excel.EasyExcelUtil; |
| | | import doumeemes.core.utils.redis.RedisUtil; |
| | | import doumeemes.dao.business.DepartmentMapper; |
| | | import doumeemes.dao.business.DeviceMapper; |
| | | import doumeemes.dao.business.UserDeviceMapper; |
| | | import doumeemes.dao.business.model.CompanyUser; |
| | | import doumeemes.dao.business.model.Department; |
| | | import doumeemes.dao.business.model.Device; |
| | | import doumeemes.dao.business.model.UserDevice; |
| | | import doumeemes.dao.business.*; |
| | | import doumeemes.dao.business.model.*; |
| | | import doumeemes.dao.ext.dto.DeviceImportDTO; |
| | | import doumeemes.dao.ext.dto.QueryDeviceExtDTO; |
| | | import doumeemes.dao.ext.vo.DeviceExtListVO; |
| | |
| | | import org.springframework.util.CollectionUtils; |
| | | import org.springframework.web.multipart.MultipartFile; |
| | | |
| | | import java.util.Date; |
| | | import java.util.List; |
| | | import java.util.*; |
| | | import java.util.stream.Collectors; |
| | | |
| | | /** |
| | | * ç产设å¤ä¿¡æ¯è¡¨Serviceå®ç° |
| | |
| | | |
| | | @Autowired |
| | | private DepartmentMapper departmentMapper; |
| | | |
| | | @Autowired |
| | | private ProceduresMapper proceduresMapper; |
| | | |
| | | @Autowired |
| | | private WarehouseLocationMapper warehouseLocationMapper; |
| | | |
| | | @Override |
| | | public Integer create(Device device) { |
| | |
| | | userDeviceMapper.delete(new QueryWrapper<UserDevice>().eq("DEVICE_ID",deviceId)); |
| | | } |
| | | if(StringUtils.isNotEmpty(userIds)){ |
| | | String [] ids=userIds.split(","); |
| | | String [] ids=userIds.replace(" ","").split("[.,;ï¼]"); |
| | | for (String id : ids) { |
| | | CompanyUser companyUser = companyUserService.findById(Integer.valueOf(id)); |
| | | UserDevice userDevice = new UserDevice(); |
| | |
| | | if(plansList == null || plansList.size()==0){ |
| | | throw new BusinessException(ResponseStatus.SERVER_ERROR.getCode(), "导å
¥æ°æ®å
容æè¯¯ï¼"); |
| | | } |
| | | |
| | | List<String> departName = new ArrayList<>(); |
| | | List<String> procedureName = new ArrayList<>(); |
| | | plansList.forEach(s->{ |
| | | |
| | | if (StringUtils.isBlank(s.getDeviceName()) |
| | |
| | | || StringUtils.isBlank(s.getFinishWarehouseLocationName())){ |
| | | throw new BusinessException(ResponseStatus.BAD_REQUEST.getCode(),"导å
¥æ°æ®å
容æè¯¯"); |
| | | } |
| | | departName.add(s.getDepartName()); |
| | | procedureName.add(s.getProcedureName()); |
| | | }); |
| | | |
| | | |
| | | QueryWrapper<Department> wrapper = new QueryWrapper<>(); |
| | | wrapper.lambda().eq(Department::getRootId,user.getRootDepartment().getId()); |
| | | departmentMapper.selectList(wrapper); |
| | | |
| | | plansList.forEach(s->{ |
| | | |
| | | QueryWrapper<Department> wrapper = new QueryWrapper<>(); |
| | | wrapper.lambda() |
| | | .eq(Department::getRootId,user.getRootDepartment().getId()) |
| | | .eq(Department::getName,departName) |
| | | .last("limit 1"); |
| | | Department department = departmentMapper.selectOne(wrapper); |
| | | if(Objects.isNull(department)){ |
| | | throw new BusinessException(ResponseStatus.BAD_REQUEST.getCode(),"å·¥ååç§°ä¸åå¨"); |
| | | } |
| | | |
| | | QueryWrapper<Procedures> proceduresQuery = new QueryWrapper<>(); |
| | | proceduresQuery.lambda() |
| | | .eq(Procedures::getRootDepartId,user.getRootDepartment().getId()) |
| | | .eq(Procedures::getDepartId,department.getId()) |
| | | .eq(Procedures::getName,s.getProcedureName()); |
| | | Procedures procedures = proceduresMapper.selectOne(proceduresQuery); |
| | | if(Objects.isNull(procedures)){ |
| | | throw new BusinessException(ResponseStatus.BAD_REQUEST.getCode(),"å·¥åºåç§°å·²åå¨"); |
| | | } |
| | | QueryDeviceExtDTO queryDeviceExtDTO=new QueryDeviceExtDTO(); |
| | | queryDeviceExtDTO.setDeleted(Constants.ZERO); |
| | | queryDeviceExtDTO.setCode(s.getDeviceCode()); |
| | | queryDeviceExtDTO.setRootDepartId(user.getRootDepartment().getId()); |
| | | List<DeviceExtListVO> list= deviceExtService.getListByCondition(queryDeviceExtDTO); |
| | | if(list.size() > 0){ |
| | | throw new BusinessException(ResponseStatus.BAD_REQUEST.getCode(),"设å¤ç¼ç ä¸åå¨"); |
| | | } |
| | | |
| | | QueryWrapper<WarehouseLocation> warehouseLocationQuery = new QueryWrapper<>(); |
| | | warehouseLocationQuery.lambda() |
| | | .eq(WarehouseLocation::getRootDepartId,department.getRootId()) |
| | | .eq(WarehouseLocation::getUnionName |
| | | ,Arrays.asList(s.getFinishWarehouseLocationName(),s.getProduceWarehouseLocationName())); |
| | | if(Objects.equals(list.size(),2)){ |
| | | throw new BusinessException(ResponseStatus.BAD_REQUEST.getCode(),"åºä½ä¿¡æ¯å·²åå¨"); |
| | | } |
| | | List<WarehouseLocation> warehouseLocations = warehouseLocationMapper.selectList(warehouseLocationQuery); |
| | | |
| | | Map<String, WarehouseLocation> collect = warehouseLocations.stream().collect(Collectors.toMap(w -> w.getUnionName(), w -> w)); |
| | | |
| | | Device device = new Device(); |
| | | device.setDeleted(Constants.ZERO); |
| | |
| | | device.setUpdateUser(user.getId()); |
| | | device.setUpdateTime(new Date()); |
| | | // device.setRemark(); |
| | | // device.setRootDepartId(); |
| | | // device.setDepartId(); |
| | | // device.setProcedureId(); |
| | | // device.setCode(); |
| | | // device.setType(); |
| | | // device.setName(); |
| | | // device.setModel(); |
| | | // device.setStatus(); |
| | | device.setRootDepartId(department.getRootId()); |
| | | device.setDepartId(procedures.getId()); |
| | | device.setProcedureId(procedures.getId()); |
| | | |
| | | device.setCode(StringUtils.isNotBlank(device.getCode()) ? device.getCode() : this.getNextCode(user.getCompany().getId())); |
| | | device.setType(StringUtils.isNotBlank(device.getCode()) ? device.getCode().trim().equals("设å¤") ? 1 : 0 : 1); |
| | | device.setName(s.getDeviceName()); |
| | | device.setModel(s.getModel()); |
| | | device.setStatus(Constants.ZERO); |
| | | // device.setSupplier(); |
| | | // device.setStationCode(); |
| | | device.setStationCode(s.getStationCode()); |
| | | // device.setGroupId(); |
| | | // device.setSerialNum(); |
| | | // device.setProduceWarehouseLocationId(); |
| | | // device.setProduceWarehouseId(); |
| | | // device.setFinishWarehouseLocationId(); |
| | | // device.setFinishWarehouseId(); |
| | | // device.setUserIds(); |
| | | device.setProduceWarehouseLocationId(collect.get(s.getProduceWarehouseLocationName()).getId()); |
| | | device.setFinishWarehouseLocationId(collect.get(s.getFinishWarehouseLocationName()).getId()); |
| | | deviceMapper.insert(device); |
| | | if(StringUtils.isNotBlank(s.getUserIds())){ |
| | | this.dealDeviceUserId(Constants.ZERO,device.getUserIds().trim(),device.getId(),user); |
| | | } |
| | | |
| | | }); |
| | | } |
| | | |
| | |
| | | LoginUserInfo principal = (LoginUserInfo) SecurityUtils.getSubject().getPrincipal(); |
| | | |
| | | SalaryParam insert = new SalaryParam(); |
| | | insert.setRootDepartId(salaryParam.getRootDepartId()); |
| | | insert.setRootDepartId(principal.getRootDepartment().getId()); |
| | | insert.setDepartId(salaryParam.getDepartId()); |
| | | insert.setProcedureId(salaryParam.getProcedureId()); |
| | | insert.setMaterialId(salaryParam.getMaterialId()); |
| | |
| | | // .set(SalaryParam::getDepartId,salaryParam.getDepartId()) |
| | | // .set(SalaryParam::getMaterialId,salaryParam.getMaterialId()) |
| | | // .set(SalaryParam::getProcedureId,salaryParam.getProcedureId()) |
| | | .set(SalaryParam::getSalary,salaryParam.getSalary().divide(new BigDecimal(100))) |
| | | .set(SalaryParam::getSalary,salaryParam.getSalary().multiply(new BigDecimal(100))) |
| | | .set(SalaryParam::getNum,salaryParam.getNum()) |
| | | .set(SalaryParam::getTimes,salaryParam.getTimes()) |
| | | .set(SalaryParam::getUnqualified,salaryParam.getUnqualified()); |
| | |
| | | @Override |
| | | public PageData<SalaryParamVO> findPage(PageWrap<SalaryParamDTO> pageWrap) { |
| | | IPage<SalaryParam> page = new Page<>(pageWrap.getPage(), pageWrap.getCapacity()); |
| | | LoginUserInfo principal = (LoginUserInfo) SecurityUtils.getSubject().getPrincipal(); |
| | | SalaryParamDTO model = pageWrap.getModel(); |
| | | model.setRootDepartId(principal.getRootDepartment().getId()); |
| | | // model.setDepartId(principal.getComDepartment().getId()); |
| | | IPage<SalaryParamVO> salaryParamVOIPage = salaryParamMapper.selectPage(page, model); |
| | | if (!CollectionUtils.isEmpty(salaryParamVOIPage.getRecords())){ |
| | | salaryParamVOIPage.getRecords().forEach(s->s.setSalary(s.getSalary().divide(new BigDecimal(100)))); |
| | |
| | | order.setUrgent(mp.getUrgent()); |
| | | order.setFactoryId(mp.getFactoryId()); |
| | | order.setBackorderId(mp.getBackorderId()); |
| | | order.setUnqualifiedNum(param.getUnqualifiedNum()); |
| | | order.setQualifiedNum(param.getQualifiedNum()); |
| | | order.setOriginId(systemDictDataBiz.queryByCode(Constants.WORKORDER_SOURCE,Constants.WORKORDER_SOURCE_PLAN).getId()); |
| | | //å·¥åç¼ç |
| | | order.setCode(workorderExtService.getNextCode(user.getCompany().getId())); |
| | |
| | | Integer produceNum = workorderList.stream().map(s -> s.getPlanNum()).reduce(Constants.ZERO, Integer::sum); |
| | | Integer surplusNum = plans.getNum() - produceNum; |
| | | if(num.compareTo(BigDecimal.valueOf(surplusNum))>0){ |
| | | throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"åæ°é误ï¼è¶
åºå·¥åå©ä½å¯åé
æ°é"); |
| | | throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"è¶
åºå½åå·¥åºè®¡å坿¥å·¥æ°é"); |
| | | } |
| | | Workorder param = new Workorder(); |
| | | param.setPlanId(autoWorkReportDTO.getPlansId()); |
| | |
| | | param.setProUserList(autoWorkReportDTO.getProUserList()); |
| | | param.setPlanNum(num.intValue()); |
| | | //çæå·¥åä¿¡æ¯ |
| | | param.setUnqualifiedNum(autoWorkReportDTO.getCreateWorkorderRecordDTO().getUnQualifiedNum().intValue()); |
| | | param.setQualifiedNum(autoWorkReportDTO.getCreateWorkorderRecordDTO().getQualifiedNum().intValue()); |
| | | Workorder workorder = this.distributeDone(user,param,num.intValue()); |
| | | //å·¥åææè®°å½ |
| | | CreateMaterialDTO createMaterialDTO = new CreateMaterialDTO(); |
| | |
| | | if(p.getPlanDate() == null){ |
| | | throw new BusinessException(ResponseStatus.BAD_REQUEST.getCode(),"对ä¸èµ·ï¼ç¬¬ã"+(index+2)+"ãè¡ã计åç»ææ¥æãæ°æ®éè¯¯ï¼æ£ç¡®æ ¼å¼ä¸ºï¼yyyy-MM-ddï¼å¦2022-06-07ï¼ï¼"); |
| | | } |
| | | if(p.getPlanDate().getTime() <= p.getStartDate().getTime()){ |
| | | if(p.getPlanDate().getTime() < p.getStartDate().getTime()){ |
| | | throw new BusinessException(ResponseStatus.BAD_REQUEST.getCode(),"对ä¸èµ·ï¼ç¬¬ã"+(index+2)+"ãè¡ã计åå¼å§æ¥æãè¦æ©äºã计åç»ææ¥æãï¼"); |
| | | } |
| | | if(StringUtils.isBlank(p.getMaterialCode())){ |
| | |
| | | } |
| | | |
| | | Date pDate = DateUtil.getDateFromString(DateUtil.getShortTime(p.getPlanDate()) +" 00:00:00"); |
| | | Date nDate = DateUtil.getDateFromString(DateUtil.getShortTime(DateUtil.getCurrentDate()) +" 00:00:00"); |
| | | Date nDate = DateUtil.getDateFromString(DateUtil.getShortTime(DateUtil.getCurrentDate()) +" 23:59:59"); |
| | | if( nDate.getTime() > pDate.getTime()){ |
| | | throw new BusinessException(ResponseStatus.BAD_REQUEST.getCode(), "对ä¸èµ·ï¼è®¡åçäº§æ¥æå¿
须为ä»å¤©ä»¥åçæ¥æï¼"); |
| | | } |
| | |
| | | * @param param |
| | | */ |
| | | @Override |
| | | @Async |
| | | // @Async |
| | | public void statisticNum(Workorder param){ |
| | | if(param.getPlanId()== null){ |
| | | if(param.getId()== null){ |
| | |
| | | && item.getOmodel()!=null |
| | | && (Constants.equalsInteger(item.getOmodel().getStatus() ,Constants.WORKORDER_STATUS.baogong) |
| | | ||Constants.equalsInteger(item.getOmodel().getStatus() ,Constants.WORKORDER_STATUS.instock))){ |
| | | //妿æ¯äº§åº |
| | | if(Constants.equalsInteger(item.getDoneType(),Constants.ZERO)){ |
| | | //妿æ¯åæ ¼äº§åºï¼ç´¯è®¡æ°é |
| | | qulifiedNum += Constants.formatBigdecimal(item.getNum()).intValue(); |
| | | }else{ |
| | | //妿æ¯ä¸è¯äº§åºï¼ç´¯è®¡æ°é |
| | | unqulifiedNum += Constants.formatBigdecimal(item.getNum()).intValue(); |
| | | } |
| | | //妿æ¯åæ ¼äº§åºï¼ç´¯è®¡æ°é |
| | | qulifiedNum += Constants.formatBigdecimal(BigDecimal.valueOf(item.getQualifiedNum())).intValue(); |
| | | //妿æ¯ä¸è¯äº§åºï¼ç´¯è®¡æ°é |
| | | unqulifiedNum += Constants.formatBigdecimal(BigDecimal.valueOf(item.getUnqualifiedNum())).intValue(); |
| | | } |
| | | } |
| | | } |
| | |
| | | if(!Objects.isNull(plan.getWorkPlansId())){ |
| | | //æ´æ°ä¸»è®¢åæ°æ®ä¿¡æ¯ |
| | | if(plansMapper.selectCount(new QueryWrapper<Plans>() |
| | | .in("STATUS",0,1,4) |
| | | .in("STATUS",0,1,4,5) |
| | | .eq("DELETED",Constants.ZERO) |
| | | .ne("id",p.getId()) |
| | | .eq("WORK_PLANS_ID",plan.getWorkPlansId()))<=Constants.ZERO){ |
| | |
| | | List<WOutbound> outboundList = new ArrayList<>(); |
| | | //妿éè¦ææçç©æéåï¼å¨åºåä¸å¯»æ¾æææ¥æº |
| | | for(WStock model : materialList){ |
| | | List<WStock> useList = allList.stream().filter(wStock -> Constants.equalsInteger(model.getMaterialId(),wStock.getMaterialId())).collect(Collectors.toList()); |
| | | BigDecimal wStockNum = useList.stream().map(s -> s.getNum()).reduce(BigDecimal.ZERO, BigDecimal::add); |
| | | if(wStockNum.compareTo(Constants.formatBigdecimal(model.getNum()))<Constants.ZERO){ |
| | | throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(), "对ä¸èµ·ï¼çäº§ç©æä¸è¶³ï¼æ æ³è¿è¡è¯¥æä½ï¼"); |
| | | } |
| | | for(WStock ts : allList){ |
| | | |
| | | if(Constants.equalsInteger(model.getMaterialId(),ts.getMaterialId())){ |
| | | //è¿éè¦æææ°é |
| | | BigDecimal actNum = Constants.formatBigdecimal(model.getNum()).subtract(Constants.formatBigdecimal(model.getTNum())); |
| | |
| | | if (bomDetailList == null || bomDetailList.size() == 0) { |
| | | throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(), "对ä¸èµ·ï¼è¯¥çäº§ç©æçbomé
ç½®æè¯¯ï¼è¯·è系管çåï¼"); |
| | | } |
| | | // for (BomDetailExtListVO i :bomDetailList) { |
| | | // //æ¥è¯¢æ¯å¦ææ |
| | | // if(workorderRecordExtMapper.selectCount(new QueryWrapper<WorkorderRecord>() |
| | | // .eq("DELETED",Constants.ZERO).eq("MATERIAL_ID",i.getMaterialId()).eq("TYPE",Constants.ZERO))<=0){ |
| | | // throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"å卿ªææBOMç©æï¼æ æ³è¿è¡æ¥å·¥"); |
| | | // } |
| | | // } |
| | | for (BomDetailExtListVO i :bomDetailList) { |
| | | //æ¥è¯¢æ¯å¦ææ |
| | | if(workorderRecordExtMapper.selectCount(new QueryWrapper<WorkorderRecord>() |
| | | .eq("WORKORDER_ID",mp.getId()) |
| | | .eq("DELETED",Constants.ZERO).eq("MATERIAL_ID",i.getMaterialId()).eq("TYPE",Constants.ZERO))<=0){ |
| | | throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"å卿ªææBOMç©æï¼æ æ³è¿è¡æ¥å·¥"); |
| | | } |
| | | } |
| | | } |
| | | |
| | | WOutbound outbound = new WOutbound(); |
| | |
| | | import doumeemes.core.utils.Constants; |
| | | import doumeemes.core.utils.HttpsUtil; |
| | | import doumeemes.core.utils.Utils; |
| | | import doumeemes.dao.business.model.Company; |
| | | import doumeemes.dao.business.model.CompanyUser; |
| | | import doumeemes.dao.business.model.Department; |
| | | import doumeemes.dao.ext.CompanyExtMapper; |
| | |
| | | |
| | | @Autowired |
| | | private SystemLoginLogService systemLoginLogService; |
| | | @Autowired |
| | | private CompanyExtMapper companyExtMapper; |
| | | |
| | | |
| | | /** |
| | |
| | | if(Objects.isNull(department)){ |
| | | throw new BusinessException(ResponseStatus.DATA_EMPTY.getCode(),"æªæ¥è¯¢å°ç»å®é¨é¨ä¿¡æ¯"); |
| | | } |
| | | Company company = companyExtMapper.selectById(department.getCompanyId()); |
| | | if(Objects.isNull(company)||company.getStatus().equals(Constants.ZERO)){ |
| | | wxLoginVO.setLoginStatus(Constants.ONE); |
| | | return wxLoginVO; |
| | | } |
| | | SystemUser systemUser = systemUserMapper.selectById(companyUser.getUserId()); |
| | | //æ¥è¯¢ç¨æ·æ°æ® |
| | | LoginDTO dto = new LoginDTO(); |
| | |
| | | wxLoginVO.setLoginStatus(Constants.ZERO); |
| | | wxLoginVO.setSession(session); |
| | | return wxLoginVO; |
| | | }catch (BusinessException e) { |
| | | wxLoginVO.setLoginStatus(Constants.ONE); |
| | | return wxLoginVO; |
| | | }catch (AuthenticationException e) { |
| | | BusinessException ee = null; |
| | | loginLog.setSuccess(Boolean.FALSE); |
| | |
| | | <!-- AND #{endDate} >= `a`.`PLAN_DATE`--> |
| | | <!-- </if>--> |
| | | <if test="mixParam != null and mixParam!=''"> |
| | | AND (mmodel.name like concat('%',#{mixParam},'%') or mmodel.code like concat('%',#{mixParam},'%') or pmodel.name like concat('%',#{mixParam},'%')) |
| | | AND (mmodel.name like concat('%',#{mixParam},'%') or mmodel.code like concat('%',#{mixParam},'%') or pmodel.name like concat('%',#{mixParam},'%') or a.BATCH like concat('%',#{mixParam},'%') or w.SALESORDER like concat('%',#{mixParam},'%') ) |
| | | </if> |
| | | <if test="usermodelInvalidTime != null"> |
| | | AND `usermodel`.`INVALID_TIME` = #{usermodelInvalidTime} |
| | |
| | | or m.`CODE` = #{model.keyWord})</if> |
| | | <if test="model.procedureName != null and model.procedureName != ''"> and p.`NAME` like concat('%',#{model.procedureName},'%')</if> |
| | | <if test="model.type != null"> and sp.`TYPE` = #{model.type}</if> |
| | | <if test="model.rootDepartId != null"> and sp.`ROOT_DEPART_ID` = #{model.rootDepartId}</if> |
| | | <if test="model.departId != null"> and sp.`DEPART_ID` = #{model.departId}</if> |
| | | order by sp.CREATE_TIME desc |
| | | </select> |
| | | </mapper> |
| | |
| | | left join unit d on a.UNIT_ID = d.ID |
| | | left join procedures f on a.PROCEDURE_ID =f.ID |
| | | where a.DELETED = 0 |
| | | and a.TYPE = 1 |
| | | <if test="rootDepartId != null"> |
| | | AND a.`ROOT_DEPART_ID` = #{rootDepartId} |
| | | </if> |
| | |
| | | VUE_APP_API_PREFIX = '' |
| | | |
| | | # ç¦æ¾ |
| | | VUE_APP_BASE_URL = 'http://192.168.0.36:10021/' |
| | | # VUE_APP_BASE_URL = 'http://192.168.0.36:10021/' |
| | | # VUE_APP_BASE_URL = 'http://192.168.0.134:10021/' |
| | | |
| | | # 任康æ¬å° |
| | | VUE_APP_BASE_URL = 'http://192.168.0.15:10021/' |
| | | |
| | | # æ±è |
| | | # VUE_APP_BASE_URL = 'http://192.168.0.35:10021/' |
| | | |
| | | # æµè¯æå¡å¨ |
| | | # VUE_APP_BASE_URL = 'https://dmtest.ahapp.net/doumeeplant_api/' |
| | | VUE_APP_BASE_URL = 'https://dmtest.ahapp.net/doumeeplant_api/' |
| | | |
| | |
| | | export default { |
| | | name: 'BaseTable', |
| | | extends: BasePage, |
| | | data () { |
| | | data() { |
| | | return { |
| | | // æ¥å£ |
| | | api: null, |
| | |
| | | * |
| | | * @param extParams é
ç½®åæ° |
| | | */ |
| | | config (extParams) { |
| | | config(extParams) { |
| | | if (extParams == null) { |
| | | throw new Error('Parameter can not be null of method \'config\' .') |
| | | } |
| | |
| | | /** |
| | | * æç´¢ï¼ç¹å»æç´¢æé®æ¶è§¦åï¼ |
| | | */ |
| | | search () { |
| | | search() { |
| | | this.handlePageChange(1) |
| | | }, |
| | | /** |
| | | * 导åºExcelï¼ç¹å»å¯¼åºæé®æ¶è§¦åï¼ |
| | | */ |
| | | exportExcel () { |
| | | exportExcel() { |
| | | this.__checkApi() |
| | | this.$dialog.exportConfirm('确认导åºåï¼') |
| | | .then(() => { |
| | |
| | | /** |
| | | * éç½®æç´¢æ¡ä»¶ï¼ç¹å»éç½®æé®æ¶è§¦åï¼ |
| | | */ |
| | | reset () { |
| | | reset() { |
| | | this.$refs.searchForm.resetFields() |
| | | this.search() |
| | | }, |
| | |
| | | * |
| | | * @param pageSize 页容é |
| | | */ |
| | | handleSizeChange (pageSize) { |
| | | handleSizeChange(pageSize) { |
| | | this.tableData.pagination.pageSize = pageSize |
| | | this.search() |
| | | }, |
| | |
| | | * |
| | | * @param selectedRows å·²éä¸çè¡æ°ç» |
| | | */ |
| | | handleSelectionChange (selectedRows) { |
| | | handleSelectionChange(selectedRows) { |
| | | this.tableData.selectedRows = selectedRows |
| | | }, |
| | | /** |
| | |
| | | * |
| | | * @param sortData æåºåæ° |
| | | */ |
| | | handleSortChange (sortData) { |
| | | handleSortChange(sortData) { |
| | | this.tableData.sorts = [] |
| | | if (sortData.order != null) { |
| | | this.tableData.sorts.push({ |
| | |
| | | * |
| | | * @param pageIndex æ°é¡µç |
| | | */ |
| | | handlePageChange (pageIndex) { |
| | | handlePageChange(pageIndex) { |
| | | this.__checkApi() |
| | | this.tableData.pagination.pageIndex = pageIndex || this.tableData.pagination.pageIndex |
| | | this.isWorking.search = true |
| | |
| | | * @param row è¡å¯¹è±¡ |
| | | * @param childConfirm å é¤åèç¹æ¶æ¯å¦è¿è¡äºæ¬¡ç¡®è®¤ |
| | | */ |
| | | deleteById (row, childConfirm = true) { |
| | | deleteById(row, childConfirm = true) { |
| | | this.__checkApi() |
| | | let message = `确认å é¤${this.module}ã${row[this.configData['field.main']]}ãå?` |
| | | if (childConfirm && row.children != null && row.children.length > 0) { |
| | |
| | | this.isWorking.delete = false |
| | | }) |
| | | }) |
| | | .catch(() => {}) |
| | | .catch(() => { }) |
| | | }, |
| | | /** |
| | | * æ¹éå é¤ï¼ç¹å»æ¹éå 餿¶è§¦åï¼ |
| | | * |
| | | * @param childConfirm å é¤åèç¹æ¶æ¯å¦è¿è¡äºæ¬¡ç¡®è®¤ |
| | | */ |
| | | deleteByIdInBatch (childConfirm = true) { |
| | | deleteByIdInBatch(childConfirm = true) { |
| | | this.__checkApi() |
| | | if (this.tableData.selectedRows.length === 0) { |
| | | this.$tip.warning('请è³å°éæ©ä¸æ¡æ°æ®') |
| | |
| | | this.isWorking.delete = false |
| | | }) |
| | | }) |
| | | .catch(() => {}) |
| | | .catch(() => { }) |
| | | }, |
| | | /** |
| | | * å é¤åå¤çï¼å¨åè¡å 餿å¤è¡å é¤åè°ç¨ |
| | |
| | | * @param deleteCount å 餿°é |
| | | * @private |
| | | */ |
| | | __afterDelete (deleteCount = 1) { |
| | | __afterDelete(deleteCount = 1) { |
| | | this.$tip.apiSuccess('å 餿å') |
| | | // å é¤å½å页æå䏿¡è®°å½æ¶æ¥è¯¢ä¸ä¸é¡µæ°æ® |
| | | if (this.tableData.list.length - deleteCount === 0) { |
| | |
| | | * |
| | | * @private |
| | | */ |
| | | __checkApi () { |
| | | __checkApi() { |
| | | console.log(this.api); |
| | | if (this.api == null) { |
| | | throw new Error('The page is not initialized, you can use method \'this.config\' to initialize this page.') |
| | | } |
| | | }, |
| | | /** |
| | | * æ°åç¸å |
| | | * @param {*} arg1 |
| | | * @param {*} arg2 |
| | | * @returns |
| | | */ |
| | | accAdd(arg1, arg2) { |
| | | return this.changeNum(arg1, arg2) |
| | | }, |
| | | |
| | | /** |
| | | * æ°åç¸å |
| | | * @param {*} arg1 |
| | | * @param {*} arg2 |
| | | * @returns |
| | | */ |
| | | accSub(arg1, arg2) { |
| | | return this.changeNum(arg1, arg2, false) |
| | | }, |
| | | |
| | | /** |
| | | * æ°åç¸ä¹ |
| | | * @param {*} arg1 |
| | | * @param {*} arg2 |
| | | * @returns |
| | | */ |
| | | accMul(arg1, arg2) { |
| | | let m = 0; |
| | | m = accAdd(m, getDecimalLength(arg1)) |
| | | m = accAdd(m, getDecimalLength(arg2)) |
| | | return getNum(arg1) * getNum(arg2) / Math.pow(10, m) |
| | | }, |
| | | |
| | | /** |
| | | * æ°åç¸é¤ |
| | | * @param {*} arg1 |
| | | * @param {*} arg2 |
| | | * @returns |
| | | */ |
| | | accDiv(arg1, arg2) { |
| | | let t1, t2; |
| | | t1 = this.getDecimalLength(arg1) |
| | | t2 = this.getDecimalLength(arg2) |
| | | if (t1 - t2 > 0) { |
| | | return (this.getNum(arg1) / this.getNum(arg2)) / Math.pow(10, t1 - t2) |
| | | } else { |
| | | return (this.getNum(arg1) / this.getNum(arg2)) * Math.pow(10, t2 - t1) |
| | | } |
| | | }, |
| | | |
| | | changeNum(arg1 = '', arg2 = '', isAdd = true) { |
| | | function changeInteger(arg, r, maxR) { |
| | | if (r != maxR) { |
| | | let addZero = '' |
| | | for (let i = 0; i < maxR - r; i++) { |
| | | addZero += '0' |
| | | } |
| | | arg = Number(arg.toString().replace('.', '') + addZero) |
| | | } else { |
| | | arg = this.getNum(arg) |
| | | } |
| | | return arg |
| | | } |
| | | let r1, r2, maxR, m; |
| | | r1 = this.getDecimalLength(arg1) |
| | | r2 = this.getDecimalLength(arg2) |
| | | maxR = Math.max(r1, r2) |
| | | arg1 = changeInteger(arg1, r1, maxR) |
| | | arg2 = changeInteger(arg2, r2, maxR) |
| | | m = Math.pow(10, maxR) |
| | | if (isAdd) { |
| | | return (arg1 + arg2) / m |
| | | } else { |
| | | return (arg1 - arg2) / m |
| | | } |
| | | }, |
| | | |
| | | getDecimalLength(arg = '') { |
| | | try { |
| | | return arg.toString().split(".")[1].length |
| | | } catch (e) { |
| | | return 0 |
| | | } |
| | | }, |
| | | |
| | | getNum(arg = '') { |
| | | return Number(arg.toString().replace(".", "")) |
| | | } |
| | | |
| | | } |
| | | } |
| | | </script> |
| | |
| | | // if (!isEdit) { |
| | | // this.form.materialId = res[0]?res[0].materialId:'' |
| | | // } |
| | | // this.selectMaterial(this.form.materialId) |
| | | if (isEdit) { |
| | | this.selectMaterial(this.form.materialId) |
| | | } |
| | | }) |
| | | .catch(err => { |
| | | console.log(err) |
| | |
| | | layout="total, prev, pager, next, jumper" |
| | | :total="pagination.total" |
| | | @current-change="handlePageChange" |
| | | background> |
| | | </el-pagination> |
| | | background |
| | | ></el-pagination> |
| | | </div> |
| | | </SelectMaterail> |
| | | </GlobalWindow> |
| | |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item label="æå±åå·¥ï¼" prop="userIds"> |
| | | <el-select v-model="form.userIds" multiple clearable filterable placeholder="è¯·éæ©" @change="selectUser"> |
| | | <el-select v-model="form.userIds" reserve-keyword multiple clearable filterable placeholder="è¯·éæ©" @change="selectUser"> |
| | | <el-option |
| | | v-for="(item, index) in select()" |
| | | :key="item.id" |
| | |
| | | <SelectMaterail |
| | | ref="selectMaterail" |
| | | @selectData="selectData" |
| | | > |
| | | </SelectMaterail> |
| | | ></SelectMaterail> |
| | | </GlobalWindow> |
| | | </template> |
| | | |
| | |
| | | }, |
| | | sorts: null |
| | | }).then(res => { |
| | | // console.log('res', res) |
| | | this.pagination.total = res.total |
| | | this.pagination.pageSize = res.capacity |
| | | this.pagination.pageIndex = res.page |
| | | this.tempMaterials = res.records |
| | | this.isSelectMaterial = true |
| | | // console.log('getTempMaterails', this.selectedAllMaterails) |
| | | if (this.selectedAllMaterails[this.pagination.pageIndex]) { |
| | | // debugger |
| | | for (const item of this.selectedAllMaterails[this.pagination.pageIndex]) { |
| | | |
| | | this.$nextTick(() => { |
| | | this.tempMaterials.forEach(tempItem => { |
| | | if (tempItem.id === item.id) { |
| | | console.log(tempItem.mmodelUnionName); |
| | | this.$refs.materials.toggleRowSelection(tempItem, true) |
| | | } |
| | | }) |
| | | }) |
| | | } |
| | | } |
| | | }).catch(err => { |
| | | this.$tip.error(err) |
| | | }) |
| | |
| | | this.getTempMaterails() |
| | | }, |
| | | handleSelectionChange (selectedRows) { |
| | | // console.log(selectedRows) |
| | | console.log(selectedRows) |
| | | this.selectedAllMaterails[this.pagination.pageIndex] = selectedRows |
| | | console.log(this.selectedAllMaterails); |
| | | }, |
| | | selectData () { |
| | | // console.log(this.selectedAllMaterails) |
| | |
| | | this.pagination.pageIndex = res.page |
| | | this.tempMaterials = res.records |
| | | this.isSelectMaterial = true |
| | | if (this.selectedAllMaterails[this.pagination.pageIndex]) { |
| | | for (const item of this.selectedAllMaterails[this.pagination.pageIndex]) { |
| | | this.$nextTick(() => { |
| | | this.tempMaterials.forEach(tempItem => { |
| | | if (tempItem.id === item.id) { |
| | | console.log(tempItem.mmodelUnionName); |
| | | this.$refs.materials.toggleRowSelection(tempItem, true) |
| | | } |
| | | }) |
| | | }) |
| | | } |
| | | } |
| | | }).catch(err => { |
| | | this.$tip.error(err) |
| | | }) |
| | |
| | | handleSelectionChange (selectedRows) { |
| | | // console.log(selectedRows) |
| | | this.selectedAllMaterails[this.pagination.pageIndex] = selectedRows |
| | | console.log(this.selectedMaterails); |
| | | }, |
| | | selectData () { |
| | | console.log(this.selectedAllMaterails) |
| | |
| | | <el-select |
| | | v-model="form.proUserList" |
| | | :disabled="!form.proGroupId" |
| | | reserve-keyword |
| | | multiple |
| | | clearable |
| | | filterable |
| | |
| | | <el-table-column prop="materialName" label="ç©æåç§°" min-width="140px"></el-table-column> |
| | | <el-table-column prop="materialCode" label="ç©æç¼ç " min-width="100px"></el-table-column> |
| | | <el-table-column prop="procedureName" label="å·¥åºåç§°" min-width="100px"></el-table-column> |
| | | <el-table-column prop="salary" label="å·¥èµåä»·ï¼å
)" min-width="100px"></el-table-column> |
| | | <el-table-column prop="salary" label="å·¥èµåä»·ï¼å
)" min-width="100px"> |
| | | <!-- <template slot-scope="{row}"> |
| | | {{ accDiv(row.salary, 100) }} |
| | | </template> --> |
| | | </el-table-column> |
| | | <el-table-column prop="num" label="æ å产åº" min-width="100px"> |
| | | <template slot-scope="{row}"> |
| | | {{ (row.num == 0 || !row.num) ? '-' : row.num }} |
| | |
| | | <keep-alive><TableLayout v-permissions="['ext:plansext:query']"> |
| | | <!-- æç´¢è¡¨å --> |
| | | <el-form slot="search-form" ref="searchForm" :model="searchForm" label-suffix="ï¼" label-width="110px" inline> |
| | | <el-form-item label="æç´¢ä¿¡æ¯" prop="mixParam"> |
| | | <el-input v-model="searchForm.mixParam" placeholder="请è¾å
¥ç©æåç§°/ç¼ç /å·¥åºåç§°" @keypress.enter.native="search"></el-input> |
| | | <el-form-item label="ç©æä¿¡æ¯" prop="mixParam"> |
| | | <el-input v-model="searchForm.mixParam" placeholder="请è¾å
¥ç©æåç§°/ç¼ç " @keypress.enter.native="search"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="æå计å" prop="workPlanCode"> |
| | | <el-input v-model="searchForm.workPlanCode" placeholder="请è¾å
¥æå计åç¼ç " @keypress.enter.native="search"></el-input> |
| | |
| | | <!-- è¡¨æ ¼åå页 --> |
| | | <template v-slot:table-wrap> |
| | | <ul class="toolbar"> |
| | | <!-- <li v-permissions="['ext:plansext:importExcel']"> |
| | | <li v-permissions="['ext:plansext:distribute']"><el-button type="primary" @click="plansDistribute">æ¹éåé
</el-button></li> |
| | | <li v-permissions="['ext:plansext:importExcel']"> |
| | | <ImportButton |
| | | text="导å
¥" |
| | | template-name="plans_import_template.xlsx" |
| | | template-path="template/plans_import_template.xlsx" |
| | | template-path="/template/plans_import_template.xlsx" |
| | | action="/ext/plansExt/importBatch" |
| | | @success="search" |
| | | /> |
| | | </li> --> |
| | | </li> |
| | | <!-- <li v-permissions="['ext:plansext:create']"><el-button type="primary" @click="$refs.operaPlansExtWindow.open('æ°å»ºç产计å')" >æ°å»º</el-button></li> --> |
| | | <!-- <li v-permissions="['ext:plansext:publish']"><el-button type="primary" @click="planRelease" >åå¸</el-button></li> --> |
| | | <li v-permissions="['ext:plansext:distribute']"><el-button type="primary" @click="plansDistribute">æ¹éåé
</el-button></li> |
| | | <li v-permissions="['ext:plansext:exportExcel']"><el-button type="primary" :loading="isWorking.export" @click="exportExcel">导åº</el-button></li> |
| | | <!-- <li v-permissions="['ext:plansext:exportExcel']"><el-button type="primary" :loading="isWorking.export" @click="exportExcel">导åº</el-button></li> --> |
| | | <!-- <li v-permissions="['ext:plansext:planpink']"><el-button type="primary" @click="$refs.operaWTransferExtWindow.open('计å颿')">计å颿</el-button></li> --> |
| | | <!-- <li v-permissions="['ext:plansext:stockpink']"><el-button type="primary" @click="$refs.operaPlanStaock.open('åºå颿')">åºå颿</el-button></li> --> |
| | | <!-- <li v-permissions="['ext:plansext:delete']"><el-button type="danger" plain @click="deleteByIdInBatch">æ¹éå é¤</el-button></li> --> |
| | |
| | | <el-table-column prop="userInfo.departName" label="é¨é¨" min-width="100px"> </el-table-column> |
| | | <el-table-column prop="jijianSalary" label="计件工èµ" min-width="100px"> |
| | | <template slot-scope="{row}"> |
| | | {{ row.jijianSalary / 100 }} |
| | | {{ accDiv(Math.round(row.jijianSalary), 100) }} |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column prop="jishiSalary" label="计æ¶å·¥èµ" min-width="100px"> |
| | | <template slot-scope="{row}"> |
| | | {{ row.jishiSalary / 100 }} |
| | | {{ accDiv(Math.round(row.jishiSalary), 100) }} |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column prop="num" label="æ¥å·¥åæ»æ°" min-width="100px"></el-table-column> |
| | | <el-table-column prop="totalSalary" label="å°è®¡å·¥èµ(å
)" min-width="100px"> |
| | | <template slot-scope="{row}"> |
| | | {{ row.totalSalary / 100 }} |
| | | {{ accDiv(Math.round(row.totalSalary), 100) }} |
| | | </template> |
| | | </el-table-column> |
| | | |
| | |
| | | <span class="long-title-style">{{ row.procedureName }}</span> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column prop="qualifiedNum" label="åæ ¼æ°é" min-width="100px"> |
| | | <!-- <el-table-column prop="qualifiedNum" label="åæ ¼æ°é" min-width="100px"> |
| | | <template slot-scope="{row}"> |
| | | <span class="valid-style">{{ row.qualifiedNum + row.umodel.name }}</span> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column prop="unqualifiedNum" label="ä¸è¯æ°é" min-width="100px"> |
| | | <template slot-scope="{row}"> |
| | | <span class="unvalid-style">{{ row.num + row.umodel.name}}</span> |
| | | <!-- <span :class="row.materialDonetype==0 ? 'valid-style' : ''">{{ row.num + row.umodel.name }}</span> --> |
| | | <span class="unvalid-style">{{ row.unqualifiedNum + row.umodel.name}}</span> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column prop="num" label="æ¥å·¥æ°é" min-width="100px"></el-table-column> |
| | | <!-- <el-table-column prop="amodel.code" label="å·¥è£
å¨å
·" min-width="100px"></el-table-column> --> |
| | | </el-table-column> --> |
| | | <el-table-column prop="doneType" label="è´¨é屿§" min-width="100px"> |
| | | <template slot-scope="{row}"> |
| | | <span v-if="row.materialDonetype==0" class="valid-style">åæ ¼</span> |
| | | <span v-else-if="row.materialDonetype==1" class="unvalid-style">ä¸è¯</span> |
| | | <span v-else>-</span> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column prop="num" label="æ°é" min-width="100px"> |
| | | <template slot-scope="{row}"> |
| | | <span :class="row.materialDonetype==0 ? 'valid-style' : 'unvalid-style'">{{ row.num + row.umodel.name }}</span> |
| | | </template> |
| | | </el-table-column> |
| | | <!-- <el-table-column prop="num" label="æ¥å·¥æ°é" min-width="100px"> |
| | | <template slot-scope="{row}"> |
| | | {{ row.num + row.umodel.name }} |
| | | </template> |
| | | </el-table-column> --> |
| | | <el-table-column prop="deviceCode" label="设å¤" show-overflow-tooltip min-width="100px"> |
| | | <template slot-scope="{row}"> |
| | | <span class="long-title-style" :title="row.deviceCode + ' | ' + row.deviceName">{{ row.deviceCode + ' | ' + row.deviceName}}</span> |
| | |
| | | if (index === 0) { |
| | | sums[index] = 'å计'; |
| | | return; |
| | | } else if (index === 4 || index === 6 || index === 8 || index === 10) { |
| | | } else if (index === 4 || index === 8 || index === 10) { |
| | | // || index === 8 || index === 9 || index === 16 || index === 17 |
| | | sums[index] = '-'; |
| | | return; |