| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295 |
- import { physics } from '@/api/scan/config'
- import http from '@/api/scan/httpUtil'
- /**** 修改 */
- //修改创建维修商
- //生产商修改
- function updateVenderManufacturer(param, success) {
- let url = `${physics}/venders/manufacturer/update`
- http.postJson(url, param, success)
- }
- //保险商修改
- function updateVenderInsurer(param, success) {
- let url = `${physics}/venders/insurance/update`
- http.postJson(url, param, success)
- }
- //保险商修改
- function updateVenderMaintainer(param, success) {
- let url = `${physics}/venders/maintainer/update`
- http.postJson(url, param, success)
- }
- //供应商修改
- function updateVenderSupplier(param, success) {
- let url = `${physics}/venders/supplier/update`
- http.postJson(url, param, success)
- }
- //品牌修改
- function updateVenderBrand(param, success) {
- let url = `${physics}/venders/manufacturer/brand/update`
- http.postJson(url, param, success)
- }
- //型号修改
- function updateVenderSpecification(param, success) {
- let url = `${physics}/venders/manufacturer/specification/update`
- http.postJson(url, param, success)
- }
- /** 获取 */
- function getList(param, success) {
- let url = `${physics}/venders/basic/vender/query`
- http.postJson(url, param, success)
- }
- function getManufacturer(param, success) {
- let url = `${physics}/venders/manufacturer/brand/findOne`
- http.postJson(url, param, success)
- }
- function getSpecification(param, success) {
- let url = `${physics}/venders/manufacturer/specification/findOne`
- http.postJson(url, param, success)
- }
- /** 创建 */
- //创建品牌
- function createBrand(param, success) {
- let url = `${physics}/venders/manufacturer/brand/create`
- http.postJson(url, param, success)
- }
- //创建生产商
- function createManufacturer(param, success) {
- let url = `${physics}/venders/manufacturer/create`
- http.postJson(url, param, success)
- }
- //创建供应商
- function createSupplier(param, success) {
- let url = `${physics}/venders/supplier/create`
- http.postJson(url, param, success)
- }
- //创建保险商
- function createInsurance(param, success) {
- let url = `${physics}/venders/insurance/create`
- http.postJson(url, param, success)
- }
- //创建维修商
- function createMaintainance(param, success) {
- let url = `${physics}/venders/maintainance/create`
- http.postJson(url, param, success)
- }
- //创建产品
- function createProduct(param, success) {
- let url = `${physics}/venders/manufacturer/product/create`
- http.postJson(url, param, success)
- }
- //创建型号
- function createSpecification(param, success) {
- let url = `${physics}/venders/manufacturer/specification/create`
- http.postJson(url, param, success)
- }
- /*** 联系人信息 */
- //添加修改维修商联系信息
- function updateMaintainance(param, success) {
- let url = `${physics}/venders/maintainance/link/create`
- http.postJson(url, param, success)
- }
- //修改创建供应商联系人
- function updateSupplier(param, success) {
- let url = `${physics}/venders/supplier/link/create`
- http.postJson(url, param, success)
- }
- //修改创建保险商联系人
- function updateInsurance(param, success) {
- let url = `${physics}/venders/insurance/link/create`
- http.postJson(url, param, success)
- }
- let arr = [{
- name: "生产商",
- infosArr: ["Manufacturer"],
- createFunc: createManufacturer,
- getList: getList,
- infosKey: "DPManufacturerID",
- update: "",
- updateVender: updateVenderManufacturer,
- options: [{
- key: "vender.name",
- label: "生产商名称",
- optLabel: "Manufacturer",
- type: "Str"
- }]
- },
- {
- name: "品牌",
- infosArr: ["Brand"],
- infosKey: "DPBrandID",
- createFunc: createBrand,
- getList: getManufacturer,
- update: "",
- options: [{
- key: "content.name",
- label: "品牌",
- optLabel: "Brand",
- type: "Str"
- }],
- updateVender: updateVenderBrand
- },
- {
- name: "保险商",
- infosArr: ["Insurer", "InsurerContactor", "InsurerPhone", "InsurerEmail", "InsurerWeb", "InsurerFax"],
- createFunc: createInsurance,
- getList: getList,
- infosKey: "DPInsurerID",
- getWebSite: "",
- updateVender: updateVenderInsurer,
- update: updateInsurance,
- options: [{
- key: "vender.name",
- label: "保险公司名称",
- optLabel: "Insurer",
- type: "Str"
- },
- {
- key: "vender.website",
- label: "保险公司网址",
- optLabel: "InsurerWeb",
- type: "Str"
- },
- {
- key: "contact.name",
- label: "联系人",
- optLabel: "InsurerContactor",
- type: "Str"
- },
- {
- key: "contact.phone",
- label: "联系人电话",
- optLabel: "InsurerPhone",
- type: "Num"
- }, {
- key: "contact.email",
- label: "联系人邮箱",
- optLabel: "InsurerEmail",
- type: "Str"
- }, {
- key: "contact.fax",
- label: "联系人传真",
- optLabel: "InsurerFax",
- type: "Str"
- }
- ],
- },
- {
- name: "维修商",
- infosArr: ["Maintainer", "MaintainerContactor", "MaintainerPhone", "MaintainerEmail", "MaintainerWeb", "MaintainerFax"],
- createFunc: createMaintainance,
- updateVender: updateVenderMaintainer,
- options: [{
- key: "vender.name",
- label: "维修商单位名称",
- optLabel: "Maintainer",
- type: "Str"
- },
- {
- key: "vender.website",
- label: "维修商网址",
- optLabel: "MaintainerWeb",
- type: "Str"
- }, {
- key: "contact.name",
- label: "联系人",
- optLabel: "MaintainerContactor",
- type: "Str"
- },
- {
- key: "contact.phone",
- label: "联系人电话",
- optLabel: "MaintainerPhone",
- type: "Num"
- }, {
- key: "contact.email",
- label: "联系人邮箱",
- optLabel: "MaintainerEmail",
- type: "Str"
- }, {
- key: "contact.fax",
- label: "联系人传真",
- optLabel: "MaintainerFax",
- type: "Str"
- }
- ],
- getList: getList,
- update: updateMaintainance,
- infosKey: "DPMaintainerID",
- getWebSite: "",
- },
- {
- name: "供应商",
- infosArr: ["Supplier", "SupplierContactor", "SupplierPhone", "SupplierEmail", "SupplierWeb", "SupplierFax"],
- createFunc: createSupplier,
- updateVender: updateVenderSupplier,
- options: [{
- key: "vender.name",
- label: "供应商单位名称",
- optLabel: "Supplier",
- type: "Str"
- },
- {
- key: "vender.website",
- label: "供应商网址",
- optLabel: "SupplierWeb",
- type: "Str"
- }, {
- key: "contact.name",
- label: "联系人",
- optLabel: "SupplierContactor",
- type: "Str"
- },
- {
- key: "contact.phone",
- label: "联系人电话",
- optLabel: "SupplierPhone",
- type: "Num"
- }, {
- key: "contact.email",
- label: "联系人邮箱",
- optLabel: "SupplierEmail",
- type: "Str"
- }, {
- key: "contact.fax",
- label: "联系人传真",
- optLabel: "SupplierFax",
- type: "Str"
- }
- ],
- getList: getList,
- update: updateSupplier,
- infosKey: "DPSupplierID",
- getWebSite: "",
- },
- {
- name: "型号",
- infosArr: ["specificationName"],
- getList: getSpecification,
- createFunc: createSpecification,
- createProduct: createProduct,
- update: "",
- options: [],
- updateVender: updateVenderSpecification,
- infosKey: "DPSpecificationID",
- getWebSite: ""
- }
- ]
- export default arr
|